From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.baldwin.cx (bigwig.baldwin.cx [IPv6:2607:f138:0:13::2]) by sourceware.org (Postfix) with ESMTPS id 521D3394FC2F for ; Wed, 16 Mar 2022 20:19:45 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 521D3394FC2F Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=FreeBSD.org Authentication-Results: sourceware.org; spf=fail smtp.mailfrom=FreeBSD.org Received: from ralph.com (ralph.baldwin.cx [66.234.199.215]) by mail.baldwin.cx (Postfix) with ESMTPSA id AF64E1A84C6B for ; Wed, 16 Mar 2022 16:19:44 -0400 (EDT) From: John Baldwin To: gdb-patches@sourceware.org Subject: [PATCH v2 01/12] Remove USE_SIGTRAP_SIGINFO condition for FreeBSD/x86 debug regs support. Date: Wed, 16 Mar 2022 13:19:12 -0700 Message-Id: <20220316201923.89694-2-jhb@FreeBSD.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220316201923.89694-1-jhb@FreeBSD.org> References: <20220316201923.89694-1-jhb@FreeBSD.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.6.4 (mail.baldwin.cx [0.0.0.0]); Wed, 16 Mar 2022 16:19:45 -0400 (EDT) X-Virus-Scanned: clamav-milter 0.103.1 at mail.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-12.3 required=5.0 tests=BAYES_00, FORGED_SPF_HELO, GIT_PATCH_0, KAM_DMARC_STATUS, KHOP_HELO_FCRDNS, SPF_HELO_PASS, SPF_SOFTFAIL, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 16 Mar 2022 20:19:46 -0000 For BSD x86 targets, stopped_by_hw_breakpoint doesn't check siginfo_t but inspects the DR6 register directly via PT_GETDBREGS. --- gdb/amd64-fbsd-nat.c | 4 ++-- gdb/i386-fbsd-nat.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/gdb/amd64-fbsd-nat.c b/gdb/amd64-fbsd-nat.c index 98a1af03a66..368f4c10786 100644 --- a/gdb/amd64-fbsd-nat.c +++ b/gdb/amd64-fbsd-nat.c @@ -46,7 +46,7 @@ class amd64_fbsd_nat_target final const struct target_desc *read_description () override; -#if defined(HAVE_PT_GETDBREGS) && defined(USE_SIGTRAP_SIGINFO) +#if defined(HAVE_PT_GETDBREGS) bool supports_stopped_by_hw_breakpoint () override; #endif }; @@ -348,7 +348,7 @@ amd64_fbsd_nat_target::read_description () return i386_target_description (X86_XSTATE_SSE_MASK, true); } -#if defined(HAVE_PT_GETDBREGS) && defined(USE_SIGTRAP_SIGINFO) +#if defined(HAVE_PT_GETDBREGS) /* Implement the supports_stopped_by_hw_breakpoints method. */ bool diff --git a/gdb/i386-fbsd-nat.c b/gdb/i386-fbsd-nat.c index a6ced66250c..023f24bab37 100644 --- a/gdb/i386-fbsd-nat.c +++ b/gdb/i386-fbsd-nat.c @@ -46,7 +46,7 @@ class i386_fbsd_nat_target final void resume (ptid_t, int, enum gdb_signal) override; -#if defined(HAVE_PT_GETDBREGS) && defined(USE_SIGTRAP_SIGINFO) +#if defined(HAVE_PT_GETDBREGS) bool supports_stopped_by_hw_breakpoint () override; #endif }; @@ -361,7 +361,7 @@ i386_fbsd_nat_target::read_description () return i386_target_description (X86_XSTATE_X87_MASK, true); } -#if defined(HAVE_PT_GETDBREGS) && defined(USE_SIGTRAP_SIGINFO) +#if defined(HAVE_PT_GETDBREGS) /* Implement the supports_stopped_by_hw_breakpoints method. */ bool -- 2.34.1