]> git.proxmox.com Git - mirror_qemu.git/commitdiff
target-i386: Don't modify env->eflags around cpu_dump_state
authorRichard Henderson <rth@twiddle.net>
Tue, 19 Mar 2013 19:11:56 +0000 (12:11 -0700)
committerBlue Swirl <blauwirbel@gmail.com>
Sat, 23 Mar 2013 14:30:12 +0000 (14:30 +0000)
We can compute the value in cpu_dump_state anyway, and gratuitous
modifications to eflags creates heisenbugs.

Cc: Blue Swirl <blauwirbel@gmail.com>
Signed-off-by: Richard Henderson <rth@twiddle.net>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
cpu-exec.c
target-i386/helper.c

index b87c1c07c65a429992877d06c8c03c2cf8ce22d3..e74e55656a4028579562615b010472d999d3176a 100644 (file)
@@ -571,10 +571,7 @@ int cpu_exec(CPUArchState *env)
                 if (qemu_loglevel_mask(CPU_LOG_TB_CPU)) {
                     /* restore flags in standard format */
 #if defined(TARGET_I386)
-                    env->eflags = env->eflags | cpu_cc_compute_all(env, CC_OP)
-                        | (DF & DF_MASK);
                     log_cpu_state(env, CPU_DUMP_CCOP);
-                    env->eflags &= ~(DF_MASK | CC_O | CC_S | CC_Z | CC_A | CC_P | CC_C);
 #elif defined(TARGET_M68K)
                     cpu_m68k_flush_flags(env, env->cc_op);
                     env->cc_op = CC_OP_FLAGS;
index 9449a0c49dcae7ebe2463f12d0deb0c723da810c..282494fcad37ebb65c94c15753e5a1bb2abadeb3 100644 (file)
@@ -189,7 +189,7 @@ void cpu_dump_state(CPUX86State *env, FILE *f, fprintf_function cpu_fprintf,
 
     cpu_synchronize_state(env);
 
-    eflags = env->eflags;
+    eflags = cpu_compute_eflags(env);
 #ifdef TARGET_X86_64
     if (env->hflags & HF_CS64_MASK) {
         cpu_fprintf(f,