From patchwork Thu Jan 12 03:00:39 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tom Tromey X-Patchwork-Id: 63065 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 87043384D30E for ; Thu, 12 Jan 2023 03:07:57 +0000 (GMT) X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from gproxy4-pub.mail.unifiedlayer.com (gproxy4-pub.mail.unifiedlayer.com [69.89.23.142]) by sourceware.org (Postfix) with ESMTPS id 7CD1738432CD for ; Thu, 12 Jan 2023 03:01:45 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 7CD1738432CD Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=tromey.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=tromey.com Received: from cmgw10.mail.unifiedlayer.com (unknown [10.0.90.125]) by progateway6.mail.pro1.eigbox.com (Postfix) with ESMTP id 020F610048664 for ; Thu, 12 Jan 2023 03:01:45 +0000 (UTC) Received: from box5379.bluehost.com ([162.241.216.53]) by cmsmtp with ESMTP id FnqaplLzJLXXpFnqap4kXt; Thu, 12 Jan 2023 03:01:44 +0000 X-Authority-Reason: nr=8 X-Authority-Analysis: v=2.4 cv=KvyIZUaN c=1 sm=1 tr=0 ts=63bf7819 a=ApxJNpeYhEAb1aAlGBBbmA==:117 a=ApxJNpeYhEAb1aAlGBBbmA==:17 a=dLZJa+xiwSxG16/P+YVxDGlgEgI=:19 a=RvmDmJFTN0MA:10:nop_rcvd_month_year a=Qbun_eYptAEA:10:endurance_base64_authed_username_1 a=mDV3o1hIAAAA:8 a=izVjsbotl6OHevnGaG4A:9 a=_FVE-zBwftR9WsbkzFJk:22 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tromey.com; s=default; h=Content-Transfer-Encoding:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=WkfrULpZawVhay1YpnZMgR7N2PeYS6kWetfbvNMUezQ=; b=FfNw+WMiZ3Wx7HWOBSJJqvLxie 0URWz17UDXWe3je6tt7NfRqGQBx4BiAi385Y+61zM6gTt2Dd59xm8nTeFhqYBHzbDcyfWJtHbdpY2 WcDt13NWcYDNo1YvoYH3qKuwp; Received: from 97-122-76-186.hlrn.qwest.net ([97.122.76.186]:60786 helo=localhost.localdomain) by box5379.bluehost.com with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.95) (envelope-from ) id 1pFnqa-000mAD-Kh; Wed, 11 Jan 2023 20:01:44 -0700 From: Tom Tromey To: gdb-patches@sourceware.org Cc: Tom Tromey Subject: [PATCH v2 66/79] Rename to allow_hw_watchpoint_access_tests Date: Wed, 11 Jan 2023 20:00:39 -0700 Message-Id: <20230112030052.3306113-67-tom@tromey.com> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230112030052.3306113-1-tom@tromey.com> References: <20230112030052.3306113-1-tom@tromey.com> MIME-Version: 1.0 X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - box5379.bluehost.com X-AntiAbuse: Original Domain - sourceware.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - tromey.com X-BWhitelist: no X-Source-IP: 97.122.76.186 X-Source-L: No X-Exim-ID: 1pFnqa-000mAD-Kh X-Source: X-Source-Args: X-Source-Dir: X-Source-Sender: 97-122-76-186.hlrn.qwest.net (localhost.localdomain) [97.122.76.186]:60786 X-Source-Auth: tom+tromey.com X-Email-Count: 67 X-Source-Cap: ZWx5bnJvYmk7ZWx5bnJvYmk7Ym94NTM3OS5ibHVlaG9zdC5jb20= X-Local-Domain: yes X-Spam-Status: No, score=-3028.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, GIT_PATCH_0, JMQ_SPF_NEUTRAL, KAM_SHORT, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) 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: , Errors-To: gdb-patches-bounces+patchwork=sourceware.org@sourceware.org Sender: "Gdb-patches" This changes skip_hw_watchpoint_access_tests to invert the sense, and renames it to allow_hw_watchpoint_access_tests. --- gdb/testsuite/gdb.base/break-idempotent.exp | 2 +- gdb/testsuite/gdb.base/watch-before-fork.exp | 2 +- gdb/testsuite/gdb.base/watch-read.exp | 2 +- gdb/testsuite/gdb.base/watch_thread_num.exp | 2 +- gdb/testsuite/gdb.base/watchpoint-hw-hit-once.exp | 2 +- gdb/testsuite/gdb.multi/watchpoint-multi.exp | 2 +- gdb/testsuite/gdb.threads/watchthreads-reorder.exp | 2 +- gdb/testsuite/lib/gdb.exp | 10 +++++----- 8 files changed, 12 insertions(+), 12 deletions(-) diff --git a/gdb/testsuite/gdb.base/break-idempotent.exp b/gdb/testsuite/gdb.base/break-idempotent.exp index 058c9327dcd..e967b563dda 100644 --- a/gdb/testsuite/gdb.base/break-idempotent.exp +++ b/gdb/testsuite/gdb.base/break-idempotent.exp @@ -184,7 +184,7 @@ foreach_with_prefix pie { "nopie" "pie" } { test_break $always_inserted "watch" } - if {![skip_hw_watchpoint_access_tests] + if {[allow_hw_watchpoint_access_tests] && ![skip_hw_watchpoint_multi_tests]} { test_break $always_inserted "rwatch" test_break $always_inserted "awatch" diff --git a/gdb/testsuite/gdb.base/watch-before-fork.exp b/gdb/testsuite/gdb.base/watch-before-fork.exp index 41574169e8f..a9e212026bf 100644 --- a/gdb/testsuite/gdb.base/watch-before-fork.exp +++ b/gdb/testsuite/gdb.base/watch-before-fork.exp @@ -18,7 +18,7 @@ # followed by a catchpoint hit. # This test uses "awatch". -require !skip_hw_watchpoint_access_tests +require allow_hw_watchpoint_access_tests standard_testfile diff --git a/gdb/testsuite/gdb.base/watch-read.exp b/gdb/testsuite/gdb.base/watch-read.exp index 6533ee2f14c..2c2e165394e 100644 --- a/gdb/testsuite/gdb.base/watch-read.exp +++ b/gdb/testsuite/gdb.base/watch-read.exp @@ -24,7 +24,7 @@ standard_testfile .c -require !skip_hw_watchpoint_access_tests +require allow_hw_watchpoint_access_tests if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}] } { return -1 diff --git a/gdb/testsuite/gdb.base/watch_thread_num.exp b/gdb/testsuite/gdb.base/watch_thread_num.exp index 799b386a390..28b8581ba5a 100644 --- a/gdb/testsuite/gdb.base/watch_thread_num.exp +++ b/gdb/testsuite/gdb.base/watch_thread_num.exp @@ -23,7 +23,7 @@ # so the test is only meaningful on a system with hardware watchpoints. # More specifically, the implementation of this test uses access # watchpoints, so skip it when those are not available. -require !skip_hw_watchpoint_access_tests +require allow_hw_watchpoint_access_tests standard_testfile .c diff --git a/gdb/testsuite/gdb.base/watchpoint-hw-hit-once.exp b/gdb/testsuite/gdb.base/watchpoint-hw-hit-once.exp index e93391a6512..fa16b3c456c 100644 --- a/gdb/testsuite/gdb.base/watchpoint-hw-hit-once.exp +++ b/gdb/testsuite/gdb.base/watchpoint-hw-hit-once.exp @@ -13,7 +13,7 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . -require !skip_hw_watchpoint_access_tests +require allow_hw_watchpoint_access_tests set test watchpoint-hw-hit-once set srcfile ${test}.c diff --git a/gdb/testsuite/gdb.multi/watchpoint-multi.exp b/gdb/testsuite/gdb.multi/watchpoint-multi.exp index e29e0675d8e..69996ba88d2 100644 --- a/gdb/testsuite/gdb.multi/watchpoint-multi.exp +++ b/gdb/testsuite/gdb.multi/watchpoint-multi.exp @@ -22,7 +22,7 @@ require !use_gdb_stub # Do not use simple hardware watchpoints ("watch") as its false hit may be # unnoticed by GDB if it reads it still has the same value. -require !skip_hw_watchpoint_access_tests +require allow_hw_watchpoint_access_tests if { [gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } { untested "failed to compile" diff --git a/gdb/testsuite/gdb.threads/watchthreads-reorder.exp b/gdb/testsuite/gdb.threads/watchthreads-reorder.exp index 2469b3ada0c..d5de2c68684 100644 --- a/gdb/testsuite/gdb.threads/watchthreads-reorder.exp +++ b/gdb/testsuite/gdb.threads/watchthreads-reorder.exp @@ -25,7 +25,7 @@ # could be assigned during continuation of a thread with pending SIGTRAP to the # different/new watchpoint, just based on the watchpoint/debug register number. -require !skip_hw_watchpoint_access_tests !skip_hw_watchpoint_multi_tests +require allow_hw_watchpoint_access_tests !skip_hw_watchpoint_multi_tests if {![istarget *-*-linux*]} { return 0 } diff --git a/gdb/testsuite/lib/gdb.exp b/gdb/testsuite/lib/gdb.exp index f3f0bfac762..13d1ae881b5 100644 --- a/gdb/testsuite/lib/gdb.exp +++ b/gdb/testsuite/lib/gdb.exp @@ -4081,19 +4081,19 @@ proc skip_hw_watchpoint_multi_tests {} { return 0 } -# Return a 1 if we should skip tests that require read/access watchpoints +# Return a 1 if we should run tests that require read/access watchpoints -proc skip_hw_watchpoint_access_tests {} { +proc allow_hw_watchpoint_access_tests {} { if { [skip_hw_watchpoint_tests] } { - return 1 + return 0 } # These targets support just write watchpoints if { [istarget "s390*-*-*"] } { - return 1 + return 0 } - return 0 + return 1 } # Return 1 if we should skip tests that require the runtime unwinder