[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[qemu-s390x] [PULL 10/35] s390x/tcg: Fix max_byte detection for stfle
From: |
Cornelia Huck |
Subject: |
[qemu-s390x] [PULL 10/35] s390x/tcg: Fix max_byte detection for stfle |
Date: |
Fri, 7 Jun 2019 11:52:12 +0200 |
From: David Hildenbrand <address@hidden>
used_stfl_bytes is 0, before initialized via prepare_stfl() on the
first invocation. We have to move the calculation of max_bytes after
prepare_stfl().
Reviewed-by: Richard Henderson <address@hidden>
Signed-off-by: David Hildenbrand <address@hidden>
---
target/s390x/misc_helper.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/target/s390x/misc_helper.c b/target/s390x/misc_helper.c
index ee67c1fa0c51..34476134a407 100644
--- a/target/s390x/misc_helper.c
+++ b/target/s390x/misc_helper.c
@@ -669,7 +669,7 @@ uint32_t HELPER(stfle)(CPUS390XState *env, uint64_t addr)
{
const uintptr_t ra = GETPC();
const int count_bytes = ((env->regs[0] & 0xff) + 1) * 8;
- const int max_bytes = ROUND_UP(used_stfl_bytes, 8);
+ int max_bytes;
int i;
if (addr & 0x7) {
@@ -677,6 +677,7 @@ uint32_t HELPER(stfle)(CPUS390XState *env, uint64_t addr)
}
prepare_stfl();
+ max_bytes = ROUND_UP(used_stfl_bytes, 8);
for (i = 0; i < count_bytes; ++i) {
cpu_stb_data_ra(env, addr + i, stfl_bytes[i], ra);
}
--
2.20.1
- [qemu-s390x] [PULL 00/35] s390x updates, Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 03/35] s390x/tcg: Implement VECTOR FIND ANY ELEMENT EQUAL, Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 05/35] s390x/tcg: Implement VECTOR FIND ELEMENT NOT EQUAL, Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 02/35] vfio-ccw: support async command subregion, Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 01/35] MAINTAINERS: cover tests/migration/s390x/, Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 08/35] s390x: Align vector registers to 16 bytes, Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 04/35] s390x/tcg: Implement VECTOR FIND ELEMENT EQUAL, Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 06/35] s390x/tcg: Implement VECTOR ISOLATE STRING, Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 07/35] s390x/tcg: Implement VECTOR STRING RANGE COMPARE, Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 10/35] s390x/tcg: Fix max_byte detection for stfle,
Cornelia Huck <=
- [qemu-s390x] [PULL 11/35] s390x/tcg: Store only the necessary amount of doublewords for STFLE, Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 09/35] s390x: Use uint64_t for vector registers, Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 12/35] s390x/tcg: Introduce tcg_s390_vector_exception(), Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 13/35] s390x/tcg: Export float_comp_to_cc() and float(32|64|128)_dcmask(), Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 15/35] s390x/tcg: Implement VECTOR FP COMPARE (AND SIGNAL) SCALAR, Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 14/35] s390x/tcg: Implement VECTOR FP ADD, Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 16/35] s390x/tcg: Implement VECTOR FP COMPARE (EQUAL|HIGH|HIGH OR EQUAL), Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 17/35] s390x/tcg: Implement VECTOR FP CONVERT FROM FIXED 64-BIT, Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 18/35] s390x/tcg: Implement VECTOR FP CONVERT FROM LOGICAL 64-BIT, Cornelia Huck, 2019/06/07
- [qemu-s390x] [PULL 19/35] s390x/tcg: Implement VECTOR FP CONVERT TO FIXED 64-BIT, Cornelia Huck, 2019/06/07