From: Florian Krohm Date: Sat, 22 Mar 2025 18:51:04 +0000 (+0000) Subject: s390x: Fix BZ 498632 X-Git-Tag: VALGRIND_3_25_0~92 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=fc40fe4f6472fef88ef78515782deb24e585aea3;p=thirdparty%2Fvalgrind.git s390x: Fix BZ 498632 IR generation for LNGFR was broken. Now fixed. Fixes https://bugs.kde.org/show_bug.cgi?id=498632 --- diff --git a/NEWS b/NEWS index 741ea7319..4ae8bde25 100644 --- a/NEWS +++ b/NEWS @@ -55,6 +55,7 @@ are not entered into bugzilla tend to get forgotten about or ignored. even though it's generated by --gen-suppressions=yes 498422 s390x: Fix VLRL and VSTRL insns 498492 none/tests/amd64/lzcnt64 crashes on FreeBSD compiled with clang +498632 s390x: Fix LNGFR insn 498942 s390x: Rework s390_disasm interface 499183 FreeBSD: differences in avx-vmovq output 499212 mmap() with MAP_ALIGNED() returns unaligned pointer diff --git a/VEX/priv/guest_s390_toIR.c b/VEX/priv/guest_s390_toIR.c index db8cea1e8..3bebca53a 100644 --- a/VEX/priv/guest_s390_toIR.c +++ b/VEX/priv/guest_s390_toIR.c @@ -8477,12 +8477,12 @@ s390_irgen_LNGR(UChar r1, UChar r2) } static const HChar * -s390_irgen_LNGFR(UChar r1, UChar r2 __attribute__((unused))) +s390_irgen_LNGFR(UChar r1, UChar r2) { IRTemp op2 = newTemp(Ity_I64); IRTemp result = newTemp(Ity_I64); - assign(op2, unop(Iop_32Sto64, get_gpr_w1(r1))); + assign(op2, unop(Iop_32Sto64, get_gpr_w1(r2))); assign(result, mkite(binop(Iop_CmpLE64S, mkexpr(op2), mkU64(0)), mkexpr(op2), binop(Iop_Sub64, mkU64(0), mkexpr(op2)))); put_gpr_dw0(r1, mkexpr(result));