diff options
author | Richard Henderson <richard.henderson@linaro.org> | 2021-07-19 10:43:46 -1000 |
---|---|---|
committer | Richard Henderson <richard.henderson@linaro.org> | 2021-07-21 07:47:05 -1000 |
commit | c2ffd7549b14373e9ca68eccd84fab141ffde646 (patch) | |
tree | 0362efe97ae88aa9d357b92c4ff052a142a55ca3 /accel/tcg/translator.c | |
parent | d40c5c79764db01cb7e495bfcec62df9be481bce (diff) | |
download | qemu-c2ffd7549b14373e9ca68eccd84fab141ffde646.zip qemu-c2ffd7549b14373e9ca68eccd84fab141ffde646.tar.gz qemu-c2ffd7549b14373e9ca68eccd84fab141ffde646.tar.bz2 |
accel/tcg: Record singlestep_enabled in tb->cflags
Set CF_SINGLE_STEP when single-stepping is enabled.
This avoids the need to flush all tb's when turning
single-stepping on or off.
Tested-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'accel/tcg/translator.c')
-rw-r--r-- | accel/tcg/translator.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/accel/tcg/translator.c b/accel/tcg/translator.c index b45337f..c53a7f8 100644 --- a/accel/tcg/translator.c +++ b/accel/tcg/translator.c @@ -38,11 +38,6 @@ bool translator_use_goto_tb(DisasContextBase *db, target_ulong dest) return false; } - /* Suppress goto_tb in the case of single-steping. */ - if (db->singlestep_enabled) { - return false; - } - /* Check for the dest on the same page as the start of the TB. */ return ((db->pc_first ^ dest) & TARGET_PAGE_MASK) == 0; } @@ -60,7 +55,7 @@ void translator_loop(const TranslatorOps *ops, DisasContextBase *db, db->is_jmp = DISAS_NEXT; db->num_insns = 0; db->max_insns = max_insns; - db->singlestep_enabled = cpu->singlestep_enabled; + db->singlestep_enabled = cflags & CF_SINGLE_STEP; ops->init_disas_context(db, cpu); tcg_debug_assert(db->is_jmp == DISAS_NEXT); /* no early exit */ |