diff options
author | Richard Henderson <richard.henderson@linaro.org> | 2025-01-17 22:05:48 -0800 |
---|---|---|
committer | Richard Henderson <richard.henderson@linaro.org> | 2025-04-28 13:40:17 -0700 |
commit | 1f049cc5fda405c46de94f9328f0e3f84c0c993b (patch) | |
tree | 875000cadf3027fc60df95bd9bbbee0c74aaa697 | |
parent | 7a89deae635ceaf687973dd95e4714af27a3f9d2 (diff) | |
download | qemu-1f049cc5fda405c46de94f9328f0e3f84c0c993b.zip qemu-1f049cc5fda405c46de94f9328f0e3f84c0c993b.tar.gz qemu-1f049cc5fda405c46de94f9328f0e3f84c0c993b.tar.bz2 |
tcg/i386: Honor carry_live in tcg_out_movi
Do not clobber flags if they're live. Required in order
to perform register allocation on add/sub carry opcodes.
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
-rw-r--r-- | tcg/i386/tcg-target.c.inc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tcg/i386/tcg-target.c.inc b/tcg/i386/tcg-target.c.inc index 04e31ca..8e0ccbc 100644 --- a/tcg/i386/tcg-target.c.inc +++ b/tcg/i386/tcg-target.c.inc @@ -1092,7 +1092,7 @@ static void tcg_out_movi_int(TCGContext *s, TCGType type, { tcg_target_long diff; - if (arg == 0) { + if (arg == 0 && !s->carry_live) { tgen_arithr(s, ARITH_XOR, ret, ret); return; } |