aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2024-08-14 13:44:47 +0200
committerPaolo Bonzini <pbonzini@redhat.com>2024-10-31 18:28:33 +0100
commit44d58e938b649a3d73af9b12aba491ebc39e5f7c (patch)
treebd713b029601c10f0d0094902f934edf7b2ebf4c
parentcea677e821c5d4efad5e25e504e935751fa61c95 (diff)
target/i386: add a note about gen_jcc1
Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
-rw-r--r--target/i386/tcg/translate.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/target/i386/tcg/translate.c b/target/i386/tcg/translate.c
index 6e89d4faef..5d729e68c9 100644
--- a/target/i386/tcg/translate.c
+++ b/target/i386/tcg/translate.c
@@ -1193,6 +1193,10 @@ static inline void gen_jcc1(DisasContext *s, int b, TCGLabel *l1)
{
CCPrepare cc = gen_prepare_cc(s, b, NULL);
+ /*
+ * Note that this must be _after_ gen_prepare_cc, because it
+ * can change the cc_op from CC_OP_DYNAMIC to CC_OP_EFLAGS!
+ */
gen_update_cc_op(s);
if (cc.use_reg2) {
tcg_gen_brcond_tl(cc.cond, cc.reg, cc.reg2, l1);