diff mbox

gcc.dg/torture/ cleanup

Message ID yddppe23jn9.fsf@lokon.CeBiTec.Uni-Bielefeld.DE
State New
Headers show

Commit Message

Rainer Orth Oct. 8, 2014, 11:06 a.m. UTC
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.

Comments

Marek Polacek Oct. 8, 2014, 12:02 p.m. UTC | #1
On Wed, Oct 08, 2014 at 01:06:50PM +0200, Rainer Orth wrote:
> 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 ;-(

Sorry about that.  I haven't seen any fail on x86/ppc64, so I missed
this one.

	Marek
diff mbox

Patch

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