public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] Add extra compile options for dg-final only once.
@ 2015-08-20  9:47 Dominik Vogt
  2015-08-20 11:43 ` Richard Biener
  0 siblings, 1 reply; 2+ messages in thread
From: Dominik Vogt @ 2015-08-20  9:47 UTC (permalink / raw)
  To: gcc-patches; +Cc: Ulrich Weigand

[-- Attachment #1: Type: text/plain, Size: 365 bytes --]

This patch fixes an annoying problem of the dg-final test using the
scan-assembler family of tests (and maybe others).  For a test
file, the option "-ffat-lto-objects" is added to the command line
once for each "scan-assembler" test, eventually resulting in an
unreadable command line.

Can this be committed?

Ciao

Dominik ^_^  ^_^

-- 

Dominik Vogt
IBM Germany

[-- Attachment #2: ChangeLog --]
[-- Type: text/plain, Size: 108 bytes --]

gcc/testsuite/ChangeLog
 
	* lib/gcc-dg.exp: Add extra options for db-final to the command line
	only once.

[-- Attachment #3: 0001-Add-extra-compile-options-for-dg-final-only-once.patch --]
[-- Type: text/x-diff, Size: 1001 bytes --]

From e89aecf367ffd2e89ac6eec7a04edd2eddd2a0da Mon Sep 17 00:00:00 2001
From: Dominik Vogt <vogt@linux.vnet.ibm.com>
Date: Thu, 20 Aug 2015 10:26:17 +0100
Subject: [PATCH] Add extra compile options for dg-final only once.

A file with many scan-assembler* tests used to add -ffat-lto-objects to the
command line many times, eventually rendering it unreadable.
---
 gcc/testsuite/lib/gcc-dg.exp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gcc/testsuite/lib/gcc-dg.exp b/gcc/testsuite/lib/gcc-dg.exp
index 7ce71df..7c1ab85 100644
--- a/gcc/testsuite/lib/gcc-dg.exp
+++ b/gcc/testsuite/lib/gcc-dg.exp
@@ -270,7 +270,7 @@ proc gcc-dg-test-1 { target_compile prog do_what extra_tool_flags } {
 	set finalcmd [lindex $x 0]
 	if { [info procs ${finalcmd}_required_options] != "" } {
 	    set req [${finalcmd}_required_options]
-	    if { $req != "" } {
+	    if { $req != "" && [lsearch -exact $extra_tool_flags $req] == -1 } {
 		lappend extra_tool_flags $req
 	    }
 	}
-- 
2.3.0


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] Add extra compile options for dg-final only once.
  2015-08-20  9:47 [PATCH] Add extra compile options for dg-final only once Dominik Vogt
@ 2015-08-20 11:43 ` Richard Biener
  0 siblings, 0 replies; 2+ messages in thread
From: Richard Biener @ 2015-08-20 11:43 UTC (permalink / raw)
  To: vogt, GCC Patches, Ulrich Weigand

On Thu, Aug 20, 2015 at 11:37 AM, Dominik Vogt <vogt@linux.vnet.ibm.com> wrote:
> This patch fixes an annoying problem of the dg-final test using the
> scan-assembler family of tests (and maybe others).  For a test
> file, the option "-ffat-lto-objects" is added to the command line
> once for each "scan-assembler" test, eventually resulting in an
> unreadable command line.
>
> Can this be committed?


Yes.

Thanks,
Richard.

> Ciao
>
> Dominik ^_^  ^_^
>
> --
>
> Dominik Vogt
> IBM Germany

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-08-20 11:27 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-08-20  9:47 [PATCH] Add extra compile options for dg-final only once Dominik Vogt
2015-08-20 11:43 ` Richard Biener

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).