From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:38796) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZeU8R-0005E2-Gl for qemu-devel@nongnu.org; Tue, 22 Sep 2015 16:25:56 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZeU8Q-0001A2-E0 for qemu-devel@nongnu.org; Tue, 22 Sep 2015 16:25:55 -0400 Received: from mail-io0-x236.google.com ([2607:f8b0:4001:c06::236]:33589) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZeU8P-00019k-J1 for qemu-devel@nongnu.org; Tue, 22 Sep 2015 16:25:53 -0400 Received: by iofh134 with SMTP id h134so26200713iof.0 for ; Tue, 22 Sep 2015 13:25:53 -0700 (PDT) Sender: Richard Henderson From: Richard Henderson Date: Tue, 22 Sep 2015 13:24:53 -0700 Message-Id: <1442953507-4074-12-git-send-email-rth@twiddle.net> In-Reply-To: <1442953507-4074-1-git-send-email-rth@twiddle.net> References: <1442953507-4074-1-git-send-email-rth@twiddle.net> Subject: [Qemu-devel] [PATCH v3 11/25] 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, alex.bennee@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