Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Andrew Burgess <andrew.burgess@embecosm.com>
To: gdb-patches@sourceware.org
Cc: Andrew Burgess <andrew.burgess@embecosm.com>
Subject: [PATCH 1/2] gdb: Minor cleanup in some gdb.arch/* tests
Date: Thu, 22 Mar 2018 12:57:00 -0000	[thread overview]
Message-ID: <e07d3806010beef5c6f1a7a0ad97229e726ec174.1521722330.git.andrew.burgess@embecosm.com> (raw)
In-Reply-To: <cover.1521722330.git.andrew.burgess@embecosm.com>
In-Reply-To: <cover.1521722330.git.andrew.burgess@embecosm.com>

A small number of tests incorrectly tried to pass -Wa,-g through to
GCC as an extra compile time flag, either to gdb_compile or
prepare_for_testing.

There were two mistakes, first, the 'debug' flag was already being
passed, this will cause GCC to add a suitable -g flag, which should
then be propagated to the assembler.  Secondly, in order to pass
additional compiler flags, the syntax would be
'additional_flags=-Wa,-g'.  As it was, the flag was just being
ignored.

Given that all these tests pass 'debug', and the invalid flag has been
ignored for some time, I'm just removing the flags in this commit.

There should be no change in the test results after this commit.

gdb/testsuite/ChangeLog:

	* gdb.arch/amd64-disp-step-avx.exp: Remove unneeded assembler
	flag option, syntax was wrong anyway.
	* gdb.arch/amd64-disp-step.exp: Likewise.
	* gdb.arch/arm-disp-step.exp: Likewise.
	* gdb.arch/i386-disp-step.exp: Likewise.
	* gdb.arch/sparc64-regs.exp: Likewise.
---
 gdb/testsuite/ChangeLog                        | 9 +++++++++
 gdb/testsuite/gdb.arch/amd64-disp-step-avx.exp | 4 +---
 gdb/testsuite/gdb.arch/amd64-disp-step.exp     | 4 +---
 gdb/testsuite/gdb.arch/arm-disp-step.exp       | 4 +---
 gdb/testsuite/gdb.arch/i386-disp-step.exp      | 5 ++---
 gdb/testsuite/gdb.arch/sparc64-regs.exp        | 4 +---
 6 files changed, 15 insertions(+), 15 deletions(-)

diff --git a/gdb/testsuite/gdb.arch/amd64-disp-step-avx.exp b/gdb/testsuite/gdb.arch/amd64-disp-step-avx.exp
index 5c20aeb35b4..362ed7b7b3a 100644
--- a/gdb/testsuite/gdb.arch/amd64-disp-step-avx.exp
+++ b/gdb/testsuite/gdb.arch/amd64-disp-step-avx.exp
@@ -25,10 +25,8 @@ if { ![istarget x86_64-*-* ] || ![is_lp64_target] } {
 
 standard_testfile .S
 
-set additional_flags "-Wa,-g"
-
 if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \
-	  [list debug $additional_flags]] } {
+	  [list debug]] } {
     return -1
 }
 
diff --git a/gdb/testsuite/gdb.arch/amd64-disp-step.exp b/gdb/testsuite/gdb.arch/amd64-disp-step.exp
index 84f7e69e40e..2731f04dc70 100644
--- a/gdb/testsuite/gdb.arch/amd64-disp-step.exp
+++ b/gdb/testsuite/gdb.arch/amd64-disp-step.exp
@@ -27,9 +27,7 @@ set newline "\[\r\n\]*"
 
 standard_testfile .S
 
-set additional_flags "-Wa,-g"
-
-if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list debug $additional_flags]] != "" } {
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list debug]] != "" } {
     untested "failed to compile"
     return -1
 }
diff --git a/gdb/testsuite/gdb.arch/arm-disp-step.exp b/gdb/testsuite/gdb.arch/arm-disp-step.exp
index 760d392885e..7268105f2dc 100644
--- a/gdb/testsuite/gdb.arch/arm-disp-step.exp
+++ b/gdb/testsuite/gdb.arch/arm-disp-step.exp
@@ -24,9 +24,7 @@ if {![is_aarch32_target]} then {
 
 standard_testfile .S
 
-set additional_flags "-Wa,-g"
-
-if { [prepare_for_testing "failed to prepare" $testfile $srcfile [list debug $additional_flags]] } {
+if { [prepare_for_testing "failed to prepare" $testfile $srcfile [list debug]] } {
     return -1
 }
 
diff --git a/gdb/testsuite/gdb.arch/i386-disp-step.exp b/gdb/testsuite/gdb.arch/i386-disp-step.exp
index ff0713cef96..c4bed320743 100644
--- a/gdb/testsuite/gdb.arch/i386-disp-step.exp
+++ b/gdb/testsuite/gdb.arch/i386-disp-step.exp
@@ -25,9 +25,8 @@ if { ![is_x86_like_target] } then {
 
 standard_testfile .S
 
-set additional_flags "-Wa,-g"
-
-if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list debug $additional_flags]] != "" } {
+if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" \
+	  executable [list debug]] != "" } {
     untested "failed to compile"
     return -1
 }
diff --git a/gdb/testsuite/gdb.arch/sparc64-regs.exp b/gdb/testsuite/gdb.arch/sparc64-regs.exp
index 3e84de6dd01..9fece51dda2 100644
--- a/gdb/testsuite/gdb.arch/sparc64-regs.exp
+++ b/gdb/testsuite/gdb.arch/sparc64-regs.exp
@@ -25,10 +25,8 @@ if ![istarget "sparc64*-*-linux*"] then {
 
 standard_testfile .S
 
-set additional_flags "-Wa,-g"
-
 if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \
-        [list debug $additional_flags]] } {
+	 [list debug]] } {
     return -1
 }
 
-- 
2.14.3


  reply	other threads:[~2018-03-22 12:57 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-03-22 12:57 [PATCH 0/2] Test fix in " Andrew Burgess
2018-03-22 12:57 ` Andrew Burgess [this message]
2018-03-22 13:51   ` [PATCH 1/2] gdb: Minor cleanup in some " Pedro Alves
2018-03-22 22:59     ` Andrew Burgess
2018-03-23 10:13       ` Pedro Alves
2018-03-22 12:57 ` [PATCH 2/2] gdb: Fix testsuite issue in gdb.arch/amd64-disp-step-avx.exp Andrew Burgess
2018-03-22 13:44   ` Pedro Alves
2018-03-22 23:01     ` Andrew Burgess
2018-03-23 10:13       ` Pedro Alves

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=e07d3806010beef5c6f1a7a0ad97229e726ec174.1521722330.git.andrew.burgess@embecosm.com \
    --to=andrew.burgess@embecosm.com \
    --cc=gdb-patches@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: link
Be 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