From nobody Mon Feb 9 18:43:58 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (208.118.235.17 [208.118.235.17]) by mx.zohomail.com with SMTPS id 1513317566232108.62291600978995; Thu, 14 Dec 2017 21:59:26 -0800 (PST) Received: from localhost ([::1]:44595 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ePj1Z-0007bN-7U for importer@patchew.org; Fri, 15 Dec 2017 00:59:09 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:53061) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ePixI-0003Zv-Mu for qemu-devel@nongnu.org; Fri, 15 Dec 2017 00:54:45 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ePixH-0004aO-Qz for qemu-devel@nongnu.org; Fri, 15 Dec 2017 00:54:44 -0500 Received: from ozlabs.org ([2401:3900:2:1::2]:59755) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1ePixH-0004WH-Fz; Fri, 15 Dec 2017 00:54:43 -0500 Received: by ozlabs.org (Postfix, from userid 1007) id 3yyflM2wTlz9t2Z; Fri, 15 Dec 2017 16:54:39 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gibson.dropbear.id.au; s=201602; t=1513317279; bh=W1xnHzpgZc+mTZlXqGmfBhnmOc/XJTeaxjxw0mIGZdY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=EU5wqqhQL26Pki0wvFgeDX+yHhURk9kw7PqesMuwGoQ9HD1wmqf7YdqjjxIiX97m5 HHVW0M46f9Txem8Ti6ejlsJVJbbwAnt+WkCiBb6EkJt7bi1A/mQhnO1Njlm4uK/PWy GcrSLsIqLCrV0QpKZj+Dpk1IpWrv2fG7//zlZNLQ= From: David Gibson To: peter.maydell@linaro.org Date: Fri, 15 Dec 2017 16:54:12 +1100 Message-Id: <20171215055435.24204-2-david@gibson.dropbear.id.au> X-Mailer: git-send-email 2.14.3 In-Reply-To: <20171215055435.24204-1-david@gibson.dropbear.id.au> References: <20171215055435.24204-1-david@gibson.dropbear.id.au> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2401:3900:2:1::2 Subject: [Qemu-devel] [PULL 01/24] target/ppc: Use tcg_gen_lookup_and_goto_ptr X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: lvivier@redhat.com, agraf@suse.de, mdroth@linux.vnet.ibm.com, qemu-devel@nongnu.org, groug@kaod.org, qemu-ppc@nongnu.org, David Gibson , Richard Henderson Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZohoMail: RDKM_2 RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" From: Richard Henderson Signed-off-by: Richard Henderson Reviewed-by: Daniel Henrique Barboza Signed-off-by: David Gibson --- target/ppc/translate.c | 23 ++++++++--------------- 1 file changed, 8 insertions(+), 15 deletions(-) diff --git a/target/ppc/translate.c b/target/ppc/translate.c index 998fbed848..4075fc8589 100644 --- a/target/ppc/translate.c +++ b/target/ppc/translate.c @@ -3419,7 +3419,7 @@ static inline bool use_goto_tb(DisasContext *ctx, tar= get_ulong dest) } =20 /*** Branch = ***/ -static inline void gen_goto_tb(DisasContext *ctx, int n, target_ulong dest) +static void gen_goto_tb(DisasContext *ctx, int n, target_ulong dest) { if (NARROW_MODE(ctx)) { dest =3D (uint32_t) dest; @@ -3441,7 +3441,7 @@ static inline void gen_goto_tb(DisasContext *ctx, int= n, target_ulong dest) gen_debug_exception(ctx); } } - tcg_gen_exit_tb(0); + tcg_gen_lookup_and_goto_ptr(); } } =20 @@ -3479,7 +3479,7 @@ static void gen_b(DisasContext *ctx) #define BCOND_CTR 2 #define BCOND_TAR 3 =20 -static inline void gen_bcond(DisasContext *ctx, int type) +static void gen_bcond(DisasContext *ctx, int type) { uint32_t bo =3D BO(ctx->opcode); TCGLabel *l1; @@ -3543,26 +3543,19 @@ static inline void gen_bcond(DisasContext *ctx, int= type) } else { gen_goto_tb(ctx, 0, li); } - if ((bo & 0x14) !=3D 0x14) { - gen_set_label(l1); - gen_goto_tb(ctx, 1, ctx->nip); - } } else { if (NARROW_MODE(ctx)) { tcg_gen_andi_tl(cpu_nip, target, (uint32_t)~3); } else { tcg_gen_andi_tl(cpu_nip, target, ~3); } - tcg_gen_exit_tb(0); - if ((bo & 0x14) !=3D 0x14) { - gen_set_label(l1); - gen_update_nip(ctx, ctx->nip); - tcg_gen_exit_tb(0); - } - } - if (type =3D=3D BCOND_LR || type =3D=3D BCOND_CTR || type =3D=3D BCOND= _TAR) { + tcg_gen_lookup_and_goto_ptr(); tcg_temp_free(target); } + if ((bo & 0x14) !=3D 0x14) { + gen_set_label(l1); + gen_goto_tb(ctx, 1, ctx->nip); + } } =20 static void gen_bc(DisasContext *ctx) --=20 2.14.3