From nobody Wed Feb 11 01:08:56 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1622059261; cv=none; d=zohomail.com; s=zohoarc; b=npUqXNSnRuNqNmZ0wISYV1RbLw9vo6dzr4OGVpDe2mUeRr5InHiP2SJaAI+++eVcUNS40pgSmioFz0gWplYIi4BpT8G+iUgXdIihNzR/UFMhEVvAFZAaAjkL1YFl3n4TMkiBuKBG6k+ZJEatMR5hF5MUbOUk3nlkok5sH8UMJkU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1622059261; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=yJOfUM/8mgDa8HdDsVl+C/Y23yiFxtHhYOEA5Fk2J74=; b=EpP2i6bDXGqf9/WSs/iWwKfWzcoEbKidzESjUuxBsu0grFLMTLkOOE7J+bJrknuonOM0YqdLOJ72O7PirjKk336ON/YRoktH62gLR44wOmzHb354xwbIhwlwALjsmLLYJSPSHyPDLYU9I9pKDhjl117YhSbq2yoqZoc1EuNjTEc= ARC-Authentication-Results: i=1; mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1622059261032615.6347884264636; Wed, 26 May 2021 13:01:01 -0700 (PDT) Received: from localhost ([::1]:50164 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1llzi7-0006zP-9v for importer@patchew.org; Wed, 26 May 2021 16:00:59 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:50082) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1llzf5-0004Hf-4z for qemu-devel@nongnu.org; Wed, 26 May 2021 15:57:51 -0400 Received: from mout.kundenserver.de ([212.227.126.130]:43619) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1llzf2-0006YO-Nr for qemu-devel@nongnu.org; Wed, 26 May 2021 15:57:50 -0400 Received: from quad ([82.142.6.50]) by mrelayeu.kundenserver.de (mreue011 [212.227.15.167]) with ESMTPSA (Nemesis) id 1MirX2-1lFypC2gvk-00ew7a; Wed, 26 May 2021 21:57:46 +0200 From: Laurent Vivier To: qemu-devel@nongnu.org Subject: [PULL 2/4] target/m68k: call gen_raise_exception() directly if single-stepping in gen_jmp_tb() Date: Wed, 26 May 2021 21:57:42 +0200 Message-Id: <20210526195744.227346-3-laurent@vivier.eu> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210526195744.227346-1-laurent@vivier.eu> References: <20210526195744.227346-1-laurent@vivier.eu> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:ce0uu3ip48g5g++iuQO9lvrI2s5usCEKvIvvKINYXiSAH8B1jEl 2j5xd7ln0qSM8L3wUPEsSlGRlrtP+65ya4hsm2b/8yBWIbUX/Qnv9OTVP0fLXJx5iPDQuba Ld3YmjIx6uWx5wcbs3LALrpZWqdYrQH+t6UZiGFcdY4e/7tbbasbBNXAR56HG2hbRpVTj2r 1dV/j5BfPo10OmXnkFO2Q== X-UI-Out-Filterresults: notjunk:1;V03:K0:VM7QzHX22OU=:A5vRlDd5XbNFwaVQkyxEwr 3miXnVRHZ/wqYHc3v1w/SiI4j42IPnWPccm1/z3n54gmp99oIc52+SXnR7cmUnklbz96Jpj1a m3a9SsD1EF8fqsvymqWsGCxjxSB4uLAeXI3lbJtEZn92KeJoBzPT1yXzjEOUYlleg6/ytEvpM iwpFiCkvGMLTf8+ln4rOMH6TOzTl1EUnMV7h3CkhHN4l0hw0JrIIhTIDIvHMFGUXyGv+oQ68p 4OV12qthwhY/hJfiO/xCb8eGQXxsONXiTjwEGPpzXtPSPKcNYYyxJqfeAkLgv4M+znKG4Uwb1 3iIUr3Ti+kX7N5BEO/TUqjSyvc/qxvUklaCY+lYeOKZqPIjCqnxXzksHEDjOr67wtudqlGYTY 4E7iADGbVuO4ZL3qvHdR62347RB9smpEGkWFoZkvdJHjRUER/SjE9lh0/GhnCXAMbOdZ1mC4E hpm6o3V99DFuBJbRYd8/fLXTcPNEWEopLjtBlSauEXCgq/VV0fwzF86SOTIqA77Am+cEyaW1n Hc5lphirc87T1d+lDQXxZ0= Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: none client-ip=212.227.126.130; envelope-from=laurent@vivier.eu; helo=mout.kundenserver.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_NONE=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Richard Henderson , Mark Cave-Ayland , Laurent Vivier Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" From: Mark Cave-Ayland In order to consolidate the single-step exception handling into a single helper, change gen_jmp_tb() so that it calls gen_raise_exception() directly instead of gen_exception(). This ensures that all single-step exceptions are now handled directly by gen_raise_exception(). Signed-off-by: Mark Cave-Ayland Reviewed-by: Richard Henderson Message-Id: <20210519142917.16693-3-mark.cave-ayland@ilande.co.uk> Signed-off-by: Laurent Vivier --- target/m68k/translate.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/target/m68k/translate.c b/target/m68k/translate.c index c774f2e8f0fc..f14ecab5a502 100644 --- a/target/m68k/translate.c +++ b/target/m68k/translate.c @@ -1518,7 +1518,9 @@ static inline bool use_goto_tb(DisasContext *s, uint3= 2_t dest) static void gen_jmp_tb(DisasContext *s, int n, uint32_t dest) { if (unlikely(is_singlestepping(s))) { - gen_exception(s, dest, EXCP_DEBUG); + update_cc_op(s); + tcg_gen_movi_i32(QREG_PC, dest); + gen_raise_exception(EXCP_DEBUG); } else if (use_goto_tb(s, dest)) { tcg_gen_goto_tb(n); tcg_gen_movi_i32(QREG_PC, dest); --=20 2.31.1