From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:40232) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W7rxh-0001N3-Mm for qemu-devel@nongnu.org; Mon, 27 Jan 2014 14:35:22 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1W7rxY-0001UK-1w for qemu-devel@nongnu.org; Mon, 27 Jan 2014 14:35:13 -0500 Message-ID: <52E6B4D7.9070405@gmail.com> Date: Mon, 27 Jan 2014 13:34:47 -0600 From: Tom Musta MIME-Version: 1.0 References: <1390845264-2532-1-git-send-email-tommusta@gmail.com> <1390845264-2532-4-git-send-email-tommusta@gmail.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [Qemu-ppc] [PATCH 3/8] target-ppc: Add bctar Instruction List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Alexander Graf Cc: PowerPC , QEMU Developers On 1/27/2014 12:46 PM, Alexander Graf wrote: >> static inline void gen_bcond(DisasContext *ctx, int type) >> > { >> > @@ -3756,10 +3757,12 @@ static inline void gen_bcond(DisasContext *ctx, int type) >> > TCGv target; >> > >> > ctx->exception = POWERPC_EXCP_BRANCH; >> > - if (type == BCOND_LR || type == BCOND_CTR) { >> > + if (type == BCOND_LR || type == BCOND_CTR || type == BCOND_TAR) { >> > target = tcg_temp_local_new(); >> > if (type == BCOND_CTR) >> > tcg_gen_mov_tl(target, cpu_ctr); >> > + else if (type == BCOND_TAR) >> > + gen_load_spr(target, SPR_TAR); > How frequently is this used in generated code? Would it make sense to make it a global TCG variable? > I have not yet seen a case of this being generated by the newer compilers. But it is certainly not difficult or much more code to make it be a global.