aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilippe Mathieu-Daudé <philmd@linaro.org>2025-03-12 10:18:42 +0100
committerPhilippe Mathieu-Daudé <philmd@linaro.org>2025-04-25 00:10:26 +0200
commit9ce6caa0d94a52a0ada77f494e8e23e62198aef0 (patch)
tree6eb8366745cd869a25cfb91077b6477af3969ac5
parentbeb38fda0f007b034ea7ff624b9f1db7699aa883 (diff)
downloadqemu-9ce6caa0d94a52a0ada77f494e8e23e62198aef0.zip
qemu-9ce6caa0d94a52a0ada77f494e8e23e62198aef0.tar.gz
qemu-9ce6caa0d94a52a0ada77f494e8e23e62198aef0.tar.bz2
target/i386: Replace MO_TE* -> MO_LE*
The x86 architecture is only implemented as little-endian. The MO_TE definition always expands to MO_LE. Replace: - MO_TEUQ -> MO_LEUQ - MO_TE -> MO_LE Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> Message-Id: <20250312142124.15138-1-philmd@linaro.org>
-rw-r--r--target/i386/tcg/emit.c.inc6
1 files changed, 3 insertions, 3 deletions
diff --git a/target/i386/tcg/emit.c.inc b/target/i386/tcg/emit.c.inc
index 4e09e96..ca6bc2e 100644
--- a/target/i386/tcg/emit.c.inc
+++ b/target/i386/tcg/emit.c.inc
@@ -1813,7 +1813,7 @@ static void gen_CMPXCHG(DisasContext *s, X86DecodedInsn *decode)
static void gen_CMPXCHG16B(DisasContext *s, X86DecodedInsn *decode)
{
#ifdef TARGET_X86_64
- MemOp mop = MO_TE | MO_128 | MO_ALIGN;
+ MemOp mop = MO_LE | MO_128 | MO_ALIGN;
TCGv_i64 t0, t1;
TCGv_i128 cmp, val;
@@ -1870,10 +1870,10 @@ static void gen_CMPXCHG8B(DisasContext *s, X86DecodedInsn *decode)
/* Only require atomic with LOCK; non-parallel handled in generator. */
if (s->prefix & PREFIX_LOCK) {
- tcg_gen_atomic_cmpxchg_i64(old, s->A0, cmp, val, s->mem_index, MO_TEUQ);
+ tcg_gen_atomic_cmpxchg_i64(old, s->A0, cmp, val, s->mem_index, MO_LEUQ);
} else {
tcg_gen_nonatomic_cmpxchg_i64(old, s->A0, cmp, val,
- s->mem_index, MO_TEUQ);
+ s->mem_index, MO_LEUQ);
}
/* Compute the required value of Z. */