Commit 30d6cb8479163676bf27bf73464a899db985f1f9

Authored by bellard
1 parent 6f970bd9

correct MIPS state restoring (Daniel Jacobowitz)


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1686 c046a42c-6fe2-441c-8c8c-71466251a162
Showing 2 changed files with 5 additions and 0 deletions
exec-all.h
... ... @@ -62,6 +62,7 @@ extern target_ulong gen_opc_npc[OPC_BUF_SIZE];
62 62 extern uint8_t gen_opc_cc_op[OPC_BUF_SIZE];
63 63 extern uint8_t gen_opc_instr_start[OPC_BUF_SIZE];
64 64 extern target_ulong gen_opc_jump_pc[2];
  65 +extern uint32_t gen_opc_hflags[OPC_BUF_SIZE];
65 66  
66 67 typedef void (GenOpFunc)(void);
67 68 typedef void (GenOpFunc1)(long);
... ...
translate-all.c
... ... @@ -53,6 +53,8 @@ uint8_t gen_opc_cc_op[OPC_BUF_SIZE];
53 53 #elif defined(TARGET_SPARC)
54 54 target_ulong gen_opc_npc[OPC_BUF_SIZE];
55 55 target_ulong gen_opc_jump_pc[2];
  56 +#elif defined(TARGET_MIPS)
  57 +uint32_t gen_opc_hflags[OPC_BUF_SIZE];
56 58 #endif
57 59  
58 60 int code_copy_enabled = 1;
... ... @@ -302,6 +304,8 @@ int cpu_restore_state(TranslationBlock *tb,
302 304 }
303 305 #elif defined(TARGET_MIPS)
304 306 env->PC = gen_opc_pc[j];
  307 + env->hflags &= ~MIPS_HFLAG_BMASK;
  308 + env->hflags |= gen_opc_hflags[j];
305 309 #endif
306 310 return 0;
307 311 }
... ...