Add test and close #1477

This commit is contained in:
lazymio
2021-11-03 21:40:13 +01:00
parent 1a82248292
commit 67e2386da6
2 changed files with 31 additions and 0 deletions

View File

@ -380,6 +380,10 @@ static inline bool cpu_handle_exception(CPUState *cpu, int *ret)
// Unicorn: Imported from https://github.com/unicorn-engine/unicorn/pull/1098
CPUMIPSState *env = &(MIPS_CPU(cpu)->env);
env->active_tc.PC = uc->next_pc;
#endif
#if defined(TARGET_RISCV)
CPURISCVState *env = &(RISCV_CPU(uc->cpu)->env);
env->pc += 4;
#endif
// Unicorn: call registered interrupt callbacks
catched = false;