[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 30/32] target/arm: Move ss check to init_disas_contex
From: |
Richard Henderson |
Subject: |
[Qemu-devel] [PULL 30/32] target/arm: Move ss check to init_disas_context |
Date: |
Wed, 6 Sep 2017 09:06:10 -0700 |
From: Richard Henderson <address@hidden>
We can check for single-step just once.
Reviewed-by: Emilio G. Cota <address@hidden>
Reviewed-by: LluĂs Vilanova <address@hidden>
Signed-off-by: Richard Henderson <address@hidden>
---
target/arm/translate.c | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
diff --git a/target/arm/translate.c b/target/arm/translate.c
index dabd5eb89a..0dd24aad90 100644
--- a/target/arm/translate.c
+++ b/target/arm/translate.c
@@ -11883,6 +11883,11 @@ static int arm_tr_init_disas_context(DisasContextBase
*dcbase,
dc->next_page_start =
(dc->base.pc_first & TARGET_PAGE_MASK) + TARGET_PAGE_SIZE;
+ /* If architectural single step active, limit to 1. */
+ if (is_singlestepping(dc)) {
+ max_insns = 1;
+ }
+
cpu_F0s = tcg_temp_new_i32();
cpu_F1s = tcg_temp_new_i32();
cpu_F0d = tcg_temp_new_i64();
@@ -12037,11 +12042,9 @@ static void arm_tr_translate_insn(DisasContextBase
*dcbase, CPUState *cpu)
* Also stop translation when a page boundary is reached. This
* ensures prefetch aborts occur at the right place. */
- if (is_singlestepping(dc)) {
- dc->base.is_jmp = DISAS_TOO_MANY;
- } else if ((dc->pc >= dc->next_page_start) ||
- ((dc->pc >= dc->next_page_start - 3) &&
- insn_crosses_page(env, dc))) {
+ if (dc->pc >= dc->next_page_start ||
+ (dc->pc >= dc->next_page_start - 3 &&
+ insn_crosses_page(env, dc))) {
/* We want to stop the TB if the next insn starts in a new page,
* or if it spans between this page and the next. This means that
* if we're looking at the last halfword in the page we need to
--
2.13.5
- [Qemu-devel] [PULL 15/32] target/arm: [tcg] Port to DisasContextBase, (continued)
- [Qemu-devel] [PULL 15/32] target/arm: [tcg] Port to DisasContextBase, Richard Henderson, 2017/09/06
- [Qemu-devel] [PULL 24/32] target/arm: [tcg] Port to tb_stop, Richard Henderson, 2017/09/06
- [Qemu-devel] [PULL 26/32] target/arm: [tcg] Port to disas_log, Richard Henderson, 2017/09/06
- [Qemu-devel] [PULL 17/32] target/arm: [tcg, a64] Port to init_disas_context, Richard Henderson, 2017/09/06
- [Qemu-devel] [PULL 22/32] target/arm: [tcg] Port to translate_insn, Richard Henderson, 2017/09/06
- [Qemu-devel] [PULL 21/32] target/arm: [tcg, a64] Port to breakpoint_check, Richard Henderson, 2017/09/06
- [Qemu-devel] [PULL 28/32] target/arm: [tcg] Port to generic translation framework, Richard Henderson, 2017/09/06
- [Qemu-devel] [PULL 23/32] target/arm: [tcg, a64] Port to translate_insn, Richard Henderson, 2017/09/06
- [Qemu-devel] [PULL 29/32] target/arm: [a64] Move page and ss checks to init_disas_context, Richard Henderson, 2017/09/06
- [Qemu-devel] [PULL 27/32] target/arm: [tcg,a64] Port to disas_log, Richard Henderson, 2017/09/06
- [Qemu-devel] [PULL 30/32] target/arm: Move ss check to init_disas_context,
Richard Henderson <=
- [Qemu-devel] [PULL 32/32] target/arm: Perform per-insn cross-page check only for Thumb, Richard Henderson, 2017/09/06
- [Qemu-devel] [PULL 31/32] target/arm: Split out thumb_tr_translate_insn, Richard Henderson, 2017/09/06
- Re: [Qemu-devel] [PULL 00/32] tcg generic translate loop, Peter Maydell, 2017/09/07