This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] gcc.dg/torture/ cleanup


Marek Polacek <polacek@redhat.com> writes:

> This patch is a cleanup of tests in gcc.dg/torture directory.
> See https://gcc.gnu.org/ml/gcc-patches/2014-09/msg02656.html for more info.
>
> Tested on x86_64-linux: vanilla results == results with this patch ==
> results with this patch and gnu11 as a default.
>
> Ok?
>
> 2014-10-02  Marek Polacek  <polacek@redhat.com>
>
> 	* gcc.dg/torture/pr24626-2.c: Add function declarations.  Fix
> 	defaulting to int.
[...]
> 	* gcc.dg/torture/stackalign/builtin-apply-4.c: Use -fgnu89-inline.
[...]
> diff --git gcc/gcc/testsuite/gcc.dg/torture/stackalign/builtin-apply-4.c gcc/gcc/testsuite/gcc.dg/torture/stackalign/builtin-apply-4.c
> index 28dc610..d958293 100644
> --- gcc/gcc/testsuite/gcc.dg/torture/stackalign/builtin-apply-4.c
> +++ gcc/gcc/testsuite/gcc.dg/torture/stackalign/builtin-apply-4.c
> @@ -1,5 +1,6 @@
>  /* PR tree-optimization/20076 */
>  /* { dg-do run } */
> +/* { dg-options "-fgnu89-inline" } */
>  
>  extern void abort (void);
>  

This patch completely broke the builtin-apply-4.c execution tests on
Solaris 11/x86 (and undoubtedly on many other platforms).
stackalign.exp has this comment:

# default_flags are replaced by a dg-options test directive, or appended
# to by using dg-additional-options.  Use default_flags for options that
# are used in all of the torture sets to limit the amount of noise in
# test summaries.
set default_flags ""

and by using dg-options in the testcase, you override everything in
default_flags ;-(

Switching to dg-additional-options fixes the problem, as tested with the
appropriate runtest invocation on i386-pc-solaris2.11.

Installed on mainline.

	Rainer


2014-10-08  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>

	* gcc.dg/torture/stackalign/builtin-apply-4.c: Use
	dg-additional-options.

diff --git a/gcc/testsuite/gcc.dg/torture/stackalign/builtin-apply-4.c b/gcc/testsuite/gcc.dg/torture/stackalign/builtin-apply-4.c
--- a/gcc/testsuite/gcc.dg/torture/stackalign/builtin-apply-4.c
+++ b/gcc/testsuite/gcc.dg/torture/stackalign/builtin-apply-4.c
@@ -1,6 +1,6 @@
 /* PR tree-optimization/20076 */
 /* { dg-do run } */
-/* { dg-options "-fgnu89-inline" } */
+/* { dg-additional-options "-fgnu89-inline" } */
 
 extern void abort (void);
 
-- 
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]