diff options
author | Richard Henderson <rth@twiddle.net> | 2012-08-22 13:15:10 -0700 |
---|---|---|
committer | Richard Henderson <rth@twiddle.net> | 2013-01-05 12:18:39 -0800 |
commit | d8fe4a9c284f244679ab251637bff81126d91dfe (patch) | |
tree | 7f842b24f0da5e25fe8ac6683937eb15f6cb6e08 /target-s390x/mem_helper.c | |
parent | 97c3ab61c46c1c0194657b8bead3d499600d8aab (diff) | |
download | qemu-d8fe4a9c284f244679ab251637bff81126d91dfe.zip |
target-s390: Convert LRA
Note that truncating the store to r1 based on PSW_MASK_64
is incorrect. We always modify the entire register.
Signed-off-by: Richard Henderson <rth@twiddle.net>
Diffstat (limited to 'target-s390x/mem_helper.c')
-rw-r--r-- | target-s390x/mem_helper.c | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/target-s390x/mem_helper.c b/target-s390x/mem_helper.c index 1b63259351..dcaa5a59d7 100644 --- a/target-s390x/mem_helper.c +++ b/target-s390x/mem_helper.c @@ -1127,7 +1127,7 @@ void HELPER(stura)(CPUS390XState *env, uint64_t addr, uint32_t v1) } /* load real address */ -uint32_t HELPER(lra)(CPUS390XState *env, uint64_t addr, uint32_t r1) +uint64_t HELPER(lra)(CPUS390XState *env, uint64_t addr) { uint32_t cc = 0; int old_exc = env->exception_index; @@ -1151,14 +1151,7 @@ uint32_t HELPER(lra)(CPUS390XState *env, uint64_t addr, uint32_t r1) } env->exception_index = old_exc; - if (!(env->psw.mask & PSW_MASK_64)) { - env->regs[r1] = (env->regs[r1] & 0xffffffff00000000ULL) | - (ret & 0xffffffffULL); - } else { - env->regs[r1] = ret; - } - - return cc; + env->cc_op = cc; + return ret; } - #endif |