summaryrefslogtreecommitdiff
path: root/target-sh4/translate.c
diff options
context:
space:
mode:
authoraurel32 <aurel32@c046a42c-6fe2-441c-8c8c-71466251a162>2008-10-12 23:32:48 +0000
committeraurel32 <aurel32@c046a42c-6fe2-441c-8c8c-71466251a162>2008-10-12 23:32:48 +0000
commit895c7462f7424db6adb7deca718a23aaae080998 (patch)
treee45dfeec37141eea30703f29132fd3bf161d2b7c /target-sh4/translate.c
parent2abb98d73966f05f9d7685ebd6e58d5f73942996 (diff)
downloadqemu-895c7462f7424db6adb7deca718a23aaae080998.tar.gz
qemu-895c7462f7424db6adb7deca718a23aaae080998.tar.bz2
qemu-895c7462f7424db6adb7deca718a23aaae080998.zip
SH4: fix single-stepping
* target-sh/translate.c (gen_intermediate_code_internal): If singlestep is enabled, update PC before stopping. (Vladimir Prus) git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5472 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'target-sh4/translate.c')
-rw-r--r--target-sh4/translate.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/target-sh4/translate.c b/target-sh4/translate.c
index ced761f2a5..4972450dbe 100644
--- a/target-sh4/translate.c
+++ b/target-sh4/translate.c
@@ -1867,6 +1867,7 @@ gen_intermediate_code_internal(CPUState * env, TranslationBlock * tb,
if (tb->cflags & CF_LAST_IO)
gen_io_end();
if (env->singlestep_enabled) {
+ tcg_gen_movi_i32(cpu_pc, ctx.pc);
tcg_gen_helper_0_0(helper_debug);
} else {
switch (ctx.bstate) {