From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2126) id 42E973858425; Fri, 13 Jan 2023 20:39:46 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 42E973858425 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1673642386; bh=E5sHUq8GxR1L6hwjZSHs91tCjwAzGDljGjha6IYAvJw=; h=From:To:Subject:Date:From; b=gSsC09+4ay0fJ6GW5x9zRt8exX01BBfVdmBMS3Uym2a0D6iU9A3odGUtU+OGBZKBY PVh1z1JLxr4L0BvzmIa/4wF5rNY3KSNmkOSJTs9pHysk5x6DpIudmsgUVGevJLHEix 4sIBwZPREi2A8fA/RjLQqVsh8VeFlW3Cfa4yAY9A= Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Tom Tromey To: gdb-cvs@sourceware.org Subject: [binutils-gdb] Rename to allow_opencl_tests X-Act-Checkin: binutils-gdb X-Git-Author: Tom Tromey X-Git-Refname: refs/heads/master X-Git-Oldrev: 4675859351582f017b495ff13fb2ea72a99834af X-Git-Newrev: afb754730e6c118eab8a96305c1c4675f4442869 Message-Id: <20230113203946.42E973858425@sourceware.org> Date: Fri, 13 Jan 2023 20:39:46 +0000 (GMT) List-Id: https://sourceware.org/git/gitweb.cgi?p=3Dbinutils-gdb.git;h=3Dafb754730e6c= 118eab8a96305c1c4675f4442869 commit afb754730e6c118eab8a96305c1c4675f4442869 Author: Tom Tromey Date: Sun Jan 8 11:42:26 2023 -0700 Rename to allow_opencl_tests =20 This changes skip_opencl_tests to invert the sense, and renames it to allow_opencl_tests. Diff: --- gdb/testsuite/gdb.opencl/callfuncs.exp | 2 +- gdb/testsuite/gdb.opencl/convs_casts.exp | 2 +- gdb/testsuite/gdb.opencl/datatypes.exp | 2 +- gdb/testsuite/gdb.opencl/operators.exp | 2 +- gdb/testsuite/gdb.opencl/vec_comps.exp | 2 +- gdb/testsuite/lib/opencl.exp | 16 ++++++++-------- 6 files changed, 13 insertions(+), 13 deletions(-) diff --git a/gdb/testsuite/gdb.opencl/callfuncs.exp b/gdb/testsuite/gdb.ope= ncl/callfuncs.exp index 98b34ab08cd..1fa3f8abcb0 100644 --- a/gdb/testsuite/gdb.opencl/callfuncs.exp +++ b/gdb/testsuite/gdb.opencl/callfuncs.exp @@ -19,7 +19,7 @@ =20 load_lib opencl.exp =20 -require !skip_opencl_tests +require allow_opencl_tests =20 set testfile "callfuncs" set clprogram [remote_download target ${srcdir}/${subdir}/${testfile}.cl] diff --git a/gdb/testsuite/gdb.opencl/convs_casts.exp b/gdb/testsuite/gdb.o= pencl/convs_casts.exp index 9764d75fcb5..d648b7f6f0d 100644 --- a/gdb/testsuite/gdb.opencl/convs_casts.exp +++ b/gdb/testsuite/gdb.opencl/convs_casts.exp @@ -19,7 +19,7 @@ =20 load_lib opencl.exp =20 -require !skip_opencl_tests +require allow_opencl_tests =20 set testfile "convs_casts" set clprogram [remote_download target ${srcdir}/${subdir}/${testfile}.cl] diff --git a/gdb/testsuite/gdb.opencl/datatypes.exp b/gdb/testsuite/gdb.ope= ncl/datatypes.exp index 69d07e7b695..b59567f65e2 100644 --- a/gdb/testsuite/gdb.opencl/datatypes.exp +++ b/gdb/testsuite/gdb.opencl/datatypes.exp @@ -19,7 +19,7 @@ =20 load_lib opencl.exp =20 -require !skip_opencl_tests +require allow_opencl_tests =20 set testfile "datatypes" set clprogram [remote_download target ${srcdir}/${subdir}/${testfile}.cl] diff --git a/gdb/testsuite/gdb.opencl/operators.exp b/gdb/testsuite/gdb.ope= ncl/operators.exp index 31a7ee87873..a70e169112d 100644 --- a/gdb/testsuite/gdb.opencl/operators.exp +++ b/gdb/testsuite/gdb.opencl/operators.exp @@ -19,7 +19,7 @@ =20 load_lib opencl.exp =20 -require !skip_opencl_tests +require allow_opencl_tests =20 set testfile "operators" set clprogram [remote_download target ${srcdir}/${subdir}/${testfile}.cl] diff --git a/gdb/testsuite/gdb.opencl/vec_comps.exp b/gdb/testsuite/gdb.ope= ncl/vec_comps.exp index 1ea2bd9d7ec..4c9f8012b79 100644 --- a/gdb/testsuite/gdb.opencl/vec_comps.exp +++ b/gdb/testsuite/gdb.opencl/vec_comps.exp @@ -19,7 +19,7 @@ =20 load_lib opencl.exp =20 -require !skip_opencl_tests +require allow_opencl_tests =20 set testfile "vec_comps" set clprogram [remote_download target ${srcdir}/${subdir}/${testfile}.cl] diff --git a/gdb/testsuite/lib/opencl.exp b/gdb/testsuite/lib/opencl.exp index 3f1b364fa00..4c66d2a9ecd 100644 --- a/gdb/testsuite/lib/opencl.exp +++ b/gdb/testsuite/lib/opencl.exp @@ -27,13 +27,13 @@ proc gdb_compile_opencl_hostapp {clsource executable op= tions} { return [gdb_compile ${src} ${binfile} "executable" ${options_opencl}] } =20 -# Run a test on the target to check if it supports OpenCL. Return 0 if so,= 1 if +# Run a test on the target to check if it supports OpenCL. Return 1 if so,= 0 if # it does not. -gdb_caching_proc skip_opencl_tests { +gdb_caching_proc allow_opencl_tests { global srcdir objdir subdir gdb_prompt global inferior_exited_re =20 - set me "skip_opencl_tests" + set me "allow_opencl_tests" =20 # Set up, compile, and execute an OpenCL program. Include the current # process ID in the file name of the executable to prevent conflicts w= ith @@ -46,8 +46,8 @@ gdb_caching_proc skip_opencl_tests { =20 if { [gdb_compile_opencl_hostapp "${clprogram}" "${executable}" "${com= pile_flags}" ] !=3D "" } { remote_file target delete ${clprogram} - verbose "$me: compiling OpenCL binary failed, returning 1" 2 - return 1 + verbose "$me: compiling OpenCL binary failed, returning 0" 2 + return 0 } =20 # Compilation succeeded so now run it via gdb. @@ -56,15 +56,15 @@ gdb_caching_proc skip_opencl_tests { gdb_expect 30 { -re ".*$inferior_exited_re normally.*${gdb_prompt} $" { verbose -log "\n$me: OpenCL support detected" - set result 0 + set result 1 } -re ".*$inferior_exited_re with code.*${gdb_prompt} $" { verbose -log "\n$me: OpenCL support not detected" - set result 1 + set result 0 } default { verbose -log "\n$me OpenCL support not detected (default case)" - set result 1 + set result 0 } } gdb_exit