From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:56446) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zh9fl-00025T-7k for qemu-devel@nongnu.org; Wed, 30 Sep 2015 01:11:22 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Zh9fk-0004zV-5n for qemu-devel@nongnu.org; Wed, 30 Sep 2015 01:11:21 -0400 Received: from mail-pa0-x22b.google.com ([2607:f8b0:400e:c03::22b]:33591) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zh9fk-0004zL-04 for qemu-devel@nongnu.org; Wed, 30 Sep 2015 01:11:20 -0400 Received: by pacex6 with SMTP id ex6so28407256pac.0 for ; Tue, 29 Sep 2015 22:11:19 -0700 (PDT) Sender: Richard Henderson From: Richard Henderson Date: Wed, 30 Sep 2015 15:09:31 +1000 Message-Id: <1443589786-26929-12-git-send-email-rth@twiddle.net> In-Reply-To: <1443589786-26929-1-git-send-email-rth@twiddle.net> References: <1443589786-26929-1-git-send-email-rth@twiddle.net> Subject: [Qemu-devel] [PATCH v4 11/26] target-cris: Mirror gen_opc_pc into insn_start List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: peter.maydell@linaro.org, aurelien@aurel32.net This perhaps isn't ideal in terms of (ab)using the "pc" field to encode both pc and ppc + delay branch state, as one has to be aware of this when examining opcode dumps. But it preserves existing logic, which will be good for bisection, and it certainly does save storage space. Reviewed-by: Aurelien Jarno Reviewed-by: Peter Maydell Signed-off-by: Richard Henderson --- target-cris/translate.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/target-cris/translate.c b/target-cris/translate.c index 477bddc..3d55a6a 100644 --- a/target-cris/translate.c +++ b/target-cris/translate.c @@ -3174,7 +3174,8 @@ gen_intermediate_code_internal(CRISCPU *cpu, TranslationBlock *tb, tcg_ctx.gen_opc_instr_start[lj] = 1; tcg_ctx.gen_opc_icount[lj] = num_insns; } - tcg_gen_insn_start(dc->pc); + tcg_gen_insn_start(dc->delayed_branch == 1 + ? dc->ppc | 1 : dc->pc); num_insns++; if (unlikely(cpu_breakpoint_test(cs, dc->pc, BP_ANY))) { -- 2.4.3