public inbox for gdb-cvs@sourceware.org help / color / mirror / Atom feed
From: Tom Tromey <tromey@sourceware.org> To: gdb-cvs@sourceware.org Subject: [binutils-gdb] Rename skip_power_isa_3_1_tests to allow form Date: Wed, 25 Jan 2023 16:21:12 +0000 (GMT) [thread overview] Message-ID: <20230125162112.129863858C53@sourceware.org> (raw) https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=ad1046e1cbf611718dc06a2d7154231e023d9296 commit ad1046e1cbf611718dc06a2d7154231e023d9296 Author: Tom Tromey <tom@tromey.com> Date: Sun Jan 22 09:12:30 2023 -0700 Rename skip_power_isa_3_1_tests to allow form This renames skip_power_isa_3_1_tests to allow_power_isa_3_1_tests and updates its users to use require. Diff: --- gdb/testsuite/gdb.arch/powerpc-plxv-nonrel.exp | 3 ++- gdb/testsuite/gdb.reverse/ppc_record_test_isa_3_1.exp | 3 ++- gdb/testsuite/lib/gdb.exp | 18 +++++++++--------- 3 files changed, 13 insertions(+), 11 deletions(-) diff --git a/gdb/testsuite/gdb.arch/powerpc-plxv-nonrel.exp b/gdb/testsuite/gdb.arch/powerpc-plxv-nonrel.exp index a1aacb05070..1ad3ea8bde4 100644 --- a/gdb/testsuite/gdb.arch/powerpc-plxv-nonrel.exp +++ b/gdb/testsuite/gdb.arch/powerpc-plxv-nonrel.exp @@ -16,10 +16,11 @@ # Test to see if gdb is properly single stepping over the # displaced plxv instruction. -if { ![istarget powerpc*-*] || [skip_power_isa_3_1_tests] } { +if { ![istarget powerpc*-*] } { verbose "Skipping powerpc ISA 3.1 plxv test." return } +require allow_power_isa_3_1_tests set retval 0 diff --git a/gdb/testsuite/gdb.reverse/ppc_record_test_isa_3_1.exp b/gdb/testsuite/gdb.reverse/ppc_record_test_isa_3_1.exp index f6bf4857fdf..7a291aaa49d 100644 --- a/gdb/testsuite/gdb.reverse/ppc_record_test_isa_3_1.exp +++ b/gdb/testsuite/gdb.reverse/ppc_record_test_isa_3_1.exp @@ -37,10 +37,11 @@ standard_testfile set gen_src record_test_isa_3_1.c set executable record_test_isa_3_1 -if {![istarget "powerpc*"] || [skip_power_isa_3_1_tests]} { +if {![istarget "powerpc*"]} { verbose "Skipping PowerPC ISA 3.1 instruction record_test." return } +require allow_power_isa_3_1_tests set options [list additional_flags=-mcpu=power10 debug] if {[build_executable "failed to prepare" $executable $srcfile $options] == -1} { diff --git a/gdb/testsuite/lib/gdb.exp b/gdb/testsuite/lib/gdb.exp index 2c53ebe7774..5425ae74cb9 100644 --- a/gdb/testsuite/lib/gdb.exp +++ b/gdb/testsuite/lib/gdb.exp @@ -3525,10 +3525,10 @@ gdb_caching_proc allow_altivec_tests { } # Run a test on the power target to see if it supports ISA 3.1 instructions -gdb_caching_proc skip_power_isa_3_1_tests { +gdb_caching_proc allow_power_isa_3_1_tests { global srcdir subdir gdb_prompt inferior_exited_re - set me "skip_power_isa_3_1_tests" + set me "allow_power_isa_3_1_tests" # Compile a test program containing ISA 3.1 instructions. set src { @@ -3540,7 +3540,7 @@ gdb_caching_proc skip_power_isa_3_1_tests { } if {![gdb_simple_compile $me $src executable ]} { - return 1 + return 0 } # No error message, compilation succeeded so now run it via gdb. @@ -3553,22 +3553,22 @@ gdb_caching_proc skip_power_isa_3_1_tests { gdb_expect { -re ".*Illegal instruction.*${gdb_prompt} $" { verbose -log "\n$me Power ISA 3.1 hardware not detected" - set skip_power_isa_3_1_tests 1 + set allow_power_isa_3_1_tests 0 } -re ".*$inferior_exited_re normally.*${gdb_prompt} $" { verbose -log "\n$me: Power ISA 3.1 hardware detected" - set skip_power_isa_3_1_tests 0 + set allow_power_isa_3_1_tests 1 } default { - warning "\n$me: default case taken" - set skip_power_isa_3_1_tests 1 + warning "\n$me: default case taken" + set allow_power_isa_3_1_tests 0 } } gdb_exit remote_file build delete $obj - verbose "$me: returning $skip_power_isa_3_1_tests" 2 - return $skip_power_isa_3_1_tests + verbose "$me: returning $allow_power_isa_3_1_tests" 2 + return $allow_power_isa_3_1_tests } # Run a test on the target to see if it supports vmx hardware. Return 0 if so,
reply other threads:[~2023-01-25 16:21 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20230125162112.129863858C53@sourceware.org \ --to=tromey@sourceware.org \ --cc=gdb-cvs@sourceware.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).