Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 9964BCA5FC4 for ; Fri, 2 Oct 2026 18:00:48 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1xChWw-0004b4-Rq; Fri, 02 Oct 2026 13:58:47 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xChSb-0006OG-N8 for qemu-arm@nongnu.org; Fri, 02 Oct 2026 13:54:30 -0400 Received: from mail-dy2-x0f.google.com ([2607:f8b0:4864:36::f]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1xChSU-0007sE-Jt for qemu-arm@nongnu.org; Fri, 02 Oct 2026 13:54:14 -0400 Received: by mail-dy2-x0f.google.com with SMTP id 5a478bee46e88-33e46a15703so7337263eec.0 for ; Fri, 02 Oct 2026 10:54:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1790963649; x=1791568449; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to:content-type; bh=yKl9yArNq3w173PSahK6ICbfpEDWkJ6jn3RpCMJdn7U=; b=f7Wb45arpAD5m4bYFQjl3p90IWp83VfJi8BlSXC5fW14dBTsT6+uscBDddcBSIQPs5 +60zb0vv4fod/fPgObr5iVAJYRXA1h1ynimj35werdAKiAOImehutw7OwR/BUv8Z1rUG acvYddCwwcrVmrtyVtuAgIBbiY2JNBAStN1LlyW55vQVUAg9GvFNSbm0MDOaZNd0Z4Cv dmZWXfKBQcWwG+PE9ttFoxdjrnxrJogKJPI/qmk0hsukZhdNx4etQGEsQrirH7uOa6b0 PMsYHjUY67/3avD5Cv70b/oJDuo92hZodMtvpa8js23Y4ZEg1FELImN5XQ3SLQd6YBYa bYHA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1790963649; x=1791568449; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to:content-type; bh=yKl9yArNq3w173PSahK6ICbfpEDWkJ6jn3RpCMJdn7U=; b=uItS7giiSk7H3sf63kw/W8V8PFfXcbvQhWb4kqGY6N/bAa/fOlq5cfYljJ/sBJJrgS DXMK3qajaUoImnBn+4ATKtrmYLjbqoZNMNhrnr56hncSTpWKn2oaS8c8fJ+0/ea+//W4 xwo7plRy2vpnSyt2i/UoYRkEUzy0dm4kHedJNbFqOWM4Fhnj5ppGb3Z60H2TdV6EXcrZ bGe8vKdvCY/f3jUwir3saCUSA2XsH/JMM8YlMpa9Si0PvIKtmgTTQqTy1eoEeUvQ8jp3 u7n0qciTCQkgLRo2iY9yD4/5fEV9e5C93SVbXjKTQ+TbSnAtxAaVQykzwnq6BPlH1F6Q R92A== X-Forwarded-Encrypted: i=1; AKwUvBx5YKw9EoP1CBomczdI1PgLv935zjkJOKgSsJG33+AhMqNMKZ2cbr84YV+vM90e2d02WWJ2HfJvnw==@nongnu.org X-Gm-Message-State: AFq9FYI+lChIXvVwzM9artj7I1tzK3CWIPtFuCbnesGGlpCdCNJWIdvB YOz9qWk2O0NB99USKKvxhzZtB/Fq5NEz+mILtHgmt7YcnTxbiYyXWaI3 X-Gm-Gg: AYBFou3pQp5fdpGu1u5DGGbkOrbpPa78P3EYVqRvQlC4J4wEJeVRAxGOy4DkuDGO4KU Zz4uKkl0Topc5GUOnNEvRtb5DOpYyMUXh0+BcbSOcK9d+7mTBj/ZasjGHpgaAZj214d0ncOparI D1Wc+CloY4/hHuu6q4p8Ft6kWV32nRY2GEvkyQebLIhKZ7C00aGlwqqDgzwoLTwsFQszhVV+K4v JRgjhWD3Dnhdg4YNZERWI39CMZ+5+o0SfwCCuB0eb2JV2QwgCP5wIldrK7QXaHQIJDGJDBKk5fY bwIttZwQXAMp/rhaS83jQKe7v4h0g6XRW692aKOOaJvgo40w8YHOb8rOUVUlkBu+LrFMh1uu5po J6q8+ilfdw67gsyUqmU6GOFdjRV0rINfyN5NvA5oPTsTtb0IrK67YXegEFm1J1Ndf9oBj86Qh4I q0Tyf/lz4bR6Cx6WDfu+xenxGfao60AcPpPVwDbbwh+48iyj704OXXeYWEUKcFrRMlBMTqxNK/n 0KpwJN6g7hYYbL/F4OGNWTi2X/oeMZa X-Received: by 2002:a05:7301:4547:b0:33b:e75b:cc42 with SMTP id 5a478bee46e88-34f150c2f6amr3129500eec.19.1790963649062; Fri, 02 Oct 2026 10:54:09 -0700 (PDT) Received: from WIN-BH9M8FJACR9 ([103.94.185.75]) by smtp.googlemail.com with ESMTPSA id 5a478bee46e88-34f14f9f2afsm18027361eec.18.2026.10.02.10.54.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 02 Oct 2026 10:54:08 -0700 (PDT) From: Yonggang Luo To: qemu-devel@nongnu.org Cc: Max Filippov , Stafford Horne , Brian Cain , Eric Farman , Song Gao <17746591750@163.com>, qemu-riscv@nongnu.org, Pierrick Bouvier , Aleksandar Rikalo , qemu-s390x@nongnu.org, Palmer Dabbelt , Alistair Francis , Philippe Mathieu-Daude , Mark Cave-Ayland , Michael Rolnik , Harsh Prateek Bora , Nicholas Piggin , Cornelia Huck , Helge Deller , Chinmay Rath , Jiaxun Yang , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , qemu-ppc@nongnu.org, Peter Maydell , Chao Liu , Aurelien Jarno , Richard Henderson , David Hildenbrand , "Edgar E. Iglesias" , Daniel Henrique Barboza , Weiwei Li , Yoshinori Sato , Artyom Tarasenko , Matthew Rosato , Laurent Vivier , qemu-arm@nongnu.org, Paolo Bonzini , Glenn Miles , Ilya Leoshkevich Subject: [PATCH v3 26/27] target/ppc: reuse the error-aware NIP exception path Date: Sat, 3 Oct 2026 01:50:34 +0800 Message-ID: <20261002175037.1747-27-luoyonggang@gmail.com> X-Mailer: git-send-email 2.52.0.windows.1 In-Reply-To: <20261002175037.1747-1-luoyonggang@gmail.com> References: <20261002175037.1747-1-luoyonggang@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=2607:f8b0:4864:36::f; envelope-from=luoyonggang@gmail.com; helo=mail-dy2-x0f.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-arm@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-arm-bounces+qemu-arm=archiver.kernel.org@nongnu.org Sender: qemu-arm-bounces+qemu-arm=archiver.kernel.org@nongnu.org Route gen_exception_nip() through gen_exception_err_nip() with a zero error code, reusing its NIP update and exception-generation path. Signed-off-by: Yonggang Luo --- target/ppc/translate.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/target/ppc/translate.c b/target/ppc/translate.c index 467b8f3d4ec..f1a7039a325 100644 --- a/target/ppc/translate.c +++ b/target/ppc/translate.c @@ -330,12 +330,7 @@ static inline void gen_exception_err(DisasContext *ctx, uint32_t excp, static void gen_exception_nip(DisasContext *ctx, uint32_t excp, target_ulong nip) { - TCGv_i32 t0; - - gen_update_nip(ctx, nip); - t0 = tcg_constant_i32(excp); - gen_helper_raise_exception(tcg_env, t0); - ctx->base.is_jmp = DISAS_NORETURN; + gen_exception_err_nip(ctx, excp, 0, nip); } static inline void gen_exception(DisasContext *ctx, uint32_t excp) -- 2.52.0.windows.1