mirror of
https://github.com/izzy2lost/xemu.git
synced 2026-07-06 00:20:22 -07:00
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>
This commit is contained in:
@@ -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;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user