From f8e89d9f4de143d03bc7994709bdec5766d8ad91 Mon Sep 17 00:00:00 2001 From: Tom de Vries Date: Tue, 30 Jun 2015 12:22:04 +0000 Subject: [PATCH] Run testsuite/libgomp.c++/c++.exp at -O2 by default 2015-06-30 Tom de Vries * testsuite/libgomp.c++/c++.exp: Set DEFAULT_CFLAGS to -O2 if not already set. Use DEFAULT_CFLAGS in dg-runtest. * testsuite/libgomp.c++/atomic-16.C: Remove dg-options "-O2 -fopenmp". * testsuite/libgomp.c++/pr64824.C: Same. * testsuite/libgomp.c++/pr64868.C: Same. * testsuite/libgomp.c++/pr66199-1.C: Same. * testsuite/libgomp.c++/pr66199-2.C: Same. * testsuite/libgomp.c++/target-2.C: Same. * testsuite/libgomp.c++/for-7.C: Use dg-additional-options for -std= option. * testsuite/libgomp.c++/udr-11.C: Same. * testsuite/libgomp.c++/udr-12.C: Same. * testsuite/libgomp.c++/udr-13.C: Same. * testsuite/libgomp.c++/udr-14.C: Same. * testsuite/libgomp.c++/udr-15.C: Same. * testsuite/libgomp.c++/udr-16.C: Same. * testsuite/libgomp.c++/udr-17.C: Same. * testsuite/libgomp.c++/udr-18.C: Same. * testsuite/libgomp.c++/udr-19.C: Same. * testsuite/libgomp.c++/atomic-1.C: Remove dg-options "-O2". * testsuite/libgomp.c++/simd-1.C: Same. * testsuite/libgomp.c++/simd-2.C: Same. * testsuite/libgomp.c++/simd-3.C: Same. * testsuite/libgomp.c++/simd-4.C: Same. * testsuite/libgomp.c++/simd-5.C: Same. * testsuite/libgomp.c++/simd-6.C: Same. * testsuite/libgomp.c++/simd-7.C: Same. * testsuite/libgomp.c++/simd-8.C: Same. * testsuite/libgomp.c++/simd-9.C: Same. * testsuite/libgomp.c++/simd10.C: Same. * testsuite/libgomp.c++/simd11.C: Same. * testsuite/libgomp.c++/simd12.C: Same. * testsuite/libgomp.c++/simd13.C: Same. From-SVN: r225181 --- libgomp/ChangeLog | 36 +++++++++++++++++++++++ libgomp/testsuite/libgomp.c++/atomic-1.C | 1 - libgomp/testsuite/libgomp.c++/atomic-16.C | 1 - libgomp/testsuite/libgomp.c++/c++.exp | 7 ++++- libgomp/testsuite/libgomp.c++/for-7.C | 2 +- libgomp/testsuite/libgomp.c++/pr64824.C | 1 - libgomp/testsuite/libgomp.c++/pr64868.C | 1 - libgomp/testsuite/libgomp.c++/pr66199-1.C | 1 - libgomp/testsuite/libgomp.c++/pr66199-2.C | 1 - libgomp/testsuite/libgomp.c++/simd-1.C | 1 - libgomp/testsuite/libgomp.c++/simd-2.C | 1 - libgomp/testsuite/libgomp.c++/simd-3.C | 1 - libgomp/testsuite/libgomp.c++/simd-4.C | 1 - libgomp/testsuite/libgomp.c++/simd-5.C | 1 - libgomp/testsuite/libgomp.c++/simd-6.C | 1 - libgomp/testsuite/libgomp.c++/simd-7.C | 1 - libgomp/testsuite/libgomp.c++/simd-8.C | 1 - libgomp/testsuite/libgomp.c++/simd-9.C | 1 - libgomp/testsuite/libgomp.c++/simd10.C | 1 - libgomp/testsuite/libgomp.c++/simd11.C | 1 - libgomp/testsuite/libgomp.c++/simd12.C | 1 - libgomp/testsuite/libgomp.c++/simd13.C | 1 - libgomp/testsuite/libgomp.c++/target-2.C | 1 - libgomp/testsuite/libgomp.c++/udr-11.C | 2 +- libgomp/testsuite/libgomp.c++/udr-12.C | 2 +- libgomp/testsuite/libgomp.c++/udr-13.C | 2 +- libgomp/testsuite/libgomp.c++/udr-14.C | 2 +- libgomp/testsuite/libgomp.c++/udr-15.C | 2 +- libgomp/testsuite/libgomp.c++/udr-16.C | 2 +- libgomp/testsuite/libgomp.c++/udr-17.C | 2 +- libgomp/testsuite/libgomp.c++/udr-18.C | 2 +- libgomp/testsuite/libgomp.c++/udr-19.C | 2 +- 32 files changed, 52 insertions(+), 31 deletions(-) diff --git a/libgomp/ChangeLog b/libgomp/ChangeLog index 2f1346de106..efd08f3cf43 100644 --- a/libgomp/ChangeLog +++ b/libgomp/ChangeLog @@ -1,3 +1,39 @@ +2015-06-30 Tom de Vries + + * testsuite/libgomp.c++/c++.exp: Set DEFAULT_CFLAGS to -O2 if not + already set. Use DEFAULT_CFLAGS in dg-runtest. + * testsuite/libgomp.c++/atomic-16.C: Remove dg-options "-O2 -fopenmp". + * testsuite/libgomp.c++/pr64824.C: Same. + * testsuite/libgomp.c++/pr64868.C: Same. + * testsuite/libgomp.c++/pr66199-1.C: Same. + * testsuite/libgomp.c++/pr66199-2.C: Same. + * testsuite/libgomp.c++/target-2.C: Same. + * testsuite/libgomp.c++/for-7.C: Use dg-additional-options for + -std= option. + * testsuite/libgomp.c++/udr-11.C: Same. + * testsuite/libgomp.c++/udr-12.C: Same. + * testsuite/libgomp.c++/udr-13.C: Same. + * testsuite/libgomp.c++/udr-14.C: Same. + * testsuite/libgomp.c++/udr-15.C: Same. + * testsuite/libgomp.c++/udr-16.C: Same. + * testsuite/libgomp.c++/udr-17.C: Same. + * testsuite/libgomp.c++/udr-18.C: Same. + * testsuite/libgomp.c++/udr-19.C: Same. + * testsuite/libgomp.c++/atomic-1.C: Remove dg-options "-O2". + * testsuite/libgomp.c++/simd-1.C: Same. + * testsuite/libgomp.c++/simd-2.C: Same. + * testsuite/libgomp.c++/simd-3.C: Same. + * testsuite/libgomp.c++/simd-4.C: Same. + * testsuite/libgomp.c++/simd-5.C: Same. + * testsuite/libgomp.c++/simd-6.C: Same. + * testsuite/libgomp.c++/simd-7.C: Same. + * testsuite/libgomp.c++/simd-8.C: Same. + * testsuite/libgomp.c++/simd-9.C: Same. + * testsuite/libgomp.c++/simd10.C: Same. + * testsuite/libgomp.c++/simd11.C: Same. + * testsuite/libgomp.c++/simd12.C: Same. + * testsuite/libgomp.c++/simd13.C: Same. + 2015-06-30 Jakub Jelinek PR middle-end/66702 diff --git a/libgomp/testsuite/libgomp.c++/atomic-1.C b/libgomp/testsuite/libgomp.c++/atomic-1.C index 73f6e7c4059..9eecfbbe77d 100644 --- a/libgomp/testsuite/libgomp.c++/atomic-1.C +++ b/libgomp/testsuite/libgomp.c++/atomic-1.C @@ -1,6 +1,5 @@ // PR c++/33894 // { dg-do run } -// { dg-options "-O2" } extern "C" void abort (); diff --git a/libgomp/testsuite/libgomp.c++/atomic-16.C b/libgomp/testsuite/libgomp.c++/atomic-16.C index afccd52bb66..432d36dd7da 100644 --- a/libgomp/testsuite/libgomp.c++/atomic-16.C +++ b/libgomp/testsuite/libgomp.c++/atomic-16.C @@ -1,5 +1,4 @@ // PR c/64824 // { dg-do run } -// { dg-options "-O2 -fopenmp" } #include "../libgomp.c/atomic-18.c" diff --git a/libgomp/testsuite/libgomp.c++/c++.exp b/libgomp/testsuite/libgomp.c++/c++.exp index da42e6213b0..0454f95588e 100644 --- a/libgomp/testsuite/libgomp.c++/c++.exp +++ b/libgomp/testsuite/libgomp.c++/c++.exp @@ -11,6 +11,11 @@ if [info exists lang_include_flags] then { unset lang_include_flags } +# If a testcase doesn't have special options, use these. +if ![info exists DEFAULT_CFLAGS] then { + set DEFAULT_CFLAGS "-O2" +} + # Initialize dg. dg-init @@ -60,7 +65,7 @@ if { $lang_test_file_found } { } # Main loop. - dg-runtest $tests "" $libstdcxx_includes + dg-runtest $tests "" "$libstdcxx_includes $DEFAULT_CFLAGS" } # All done. diff --git a/libgomp/testsuite/libgomp.c++/for-7.C b/libgomp/testsuite/libgomp.c++/for-7.C index 9d626c028df..256a1312e4f 100644 --- a/libgomp/testsuite/libgomp.c++/for-7.C +++ b/libgomp/testsuite/libgomp.c++/for-7.C @@ -1,6 +1,6 @@ // PR c++/ // { dg-do run } -// { dg-options "-std=c++0x -fopenmp" } +// { dg-additional-options "-std=c++0x" } extern "C" void abort (); int cnt; diff --git a/libgomp/testsuite/libgomp.c++/pr64824.C b/libgomp/testsuite/libgomp.c++/pr64824.C index 348f6d6e0c2..00f23bb728c 100644 --- a/libgomp/testsuite/libgomp.c++/pr64824.C +++ b/libgomp/testsuite/libgomp.c++/pr64824.C @@ -1,5 +1,4 @@ // PR c/64824 // { dg-do run } -// { dg-options "-O2 -fopenmp" } #include "../libgomp.c/pr64824.c" diff --git a/libgomp/testsuite/libgomp.c++/pr64868.C b/libgomp/testsuite/libgomp.c++/pr64868.C index 2d730ac4924..661ec232dd3 100644 --- a/libgomp/testsuite/libgomp.c++/pr64868.C +++ b/libgomp/testsuite/libgomp.c++/pr64868.C @@ -1,5 +1,4 @@ // PR c/64868 // { dg-do run } -// { dg-options "-O2 -fopenmp" } #include "../libgomp.c/pr64868.c" diff --git a/libgomp/testsuite/libgomp.c++/pr66199-1.C b/libgomp/testsuite/libgomp.c++/pr66199-1.C index 2139e11b51c..cb86a60fa26 100644 --- a/libgomp/testsuite/libgomp.c++/pr66199-1.C +++ b/libgomp/testsuite/libgomp.c++/pr66199-1.C @@ -1,5 +1,4 @@ // PR middle-end/66199 // { dg-do run } -// { dg-options "-O2 -fopenmp" } #include "../libgomp.c/pr66199-1.c" diff --git a/libgomp/testsuite/libgomp.c++/pr66199-2.C b/libgomp/testsuite/libgomp.c++/pr66199-2.C index 36392da270a..1dbccb6c0e5 100644 --- a/libgomp/testsuite/libgomp.c++/pr66199-2.C +++ b/libgomp/testsuite/libgomp.c++/pr66199-2.C @@ -1,5 +1,4 @@ // PR middle-end/66199 // { dg-do run } -// { dg-options "-O2 -fopenmp" } #include "../libgomp.c/pr66199-2.c" diff --git a/libgomp/testsuite/libgomp.c++/simd-1.C b/libgomp/testsuite/libgomp.c++/simd-1.C index 16ef159b827..139386f085a 100644 --- a/libgomp/testsuite/libgomp.c++/simd-1.C +++ b/libgomp/testsuite/libgomp.c++/simd-1.C @@ -1,5 +1,4 @@ // { dg-do run } -// { dg-options "-O2" } // { dg-additional-options "-msse2" { target sse2_runtime } } // { dg-additional-options "-mavx" { target avx_runtime } } diff --git a/libgomp/testsuite/libgomp.c++/simd-2.C b/libgomp/testsuite/libgomp.c++/simd-2.C index 6b12415bdce..8205d6449c8 100644 --- a/libgomp/testsuite/libgomp.c++/simd-2.C +++ b/libgomp/testsuite/libgomp.c++/simd-2.C @@ -1,5 +1,4 @@ // { dg-do run } -// { dg-options "-O2" } // { dg-additional-options "-msse2" { target sse2_runtime } } // { dg-additional-options "-mavx" { target avx_runtime } } diff --git a/libgomp/testsuite/libgomp.c++/simd-3.C b/libgomp/testsuite/libgomp.c++/simd-3.C index 1c6d8e01af9..195261d820e 100644 --- a/libgomp/testsuite/libgomp.c++/simd-3.C +++ b/libgomp/testsuite/libgomp.c++/simd-3.C @@ -1,5 +1,4 @@ // { dg-do run } -// { dg-options "-O2" } // { dg-additional-options "-msse2" { target sse2_runtime } } // { dg-additional-options "-mavx" { target avx_runtime } } diff --git a/libgomp/testsuite/libgomp.c++/simd-4.C b/libgomp/testsuite/libgomp.c++/simd-4.C index bdfacc65264..b81f230b25d 100644 --- a/libgomp/testsuite/libgomp.c++/simd-4.C +++ b/libgomp/testsuite/libgomp.c++/simd-4.C @@ -1,5 +1,4 @@ // { dg-do run } -// { dg-options "-O2" } // { dg-additional-options "-msse2" { target sse2_runtime } } // { dg-additional-options "-mavx" { target avx_runtime } } diff --git a/libgomp/testsuite/libgomp.c++/simd-5.C b/libgomp/testsuite/libgomp.c++/simd-5.C index 6c4627e210a..e7cea84548c 100644 --- a/libgomp/testsuite/libgomp.c++/simd-5.C +++ b/libgomp/testsuite/libgomp.c++/simd-5.C @@ -1,5 +1,4 @@ // { dg-do run } -// { dg-options "-O2" } // { dg-additional-options "-msse2" { target sse2_runtime } } // { dg-additional-options "-mavx" { target avx_runtime } } diff --git a/libgomp/testsuite/libgomp.c++/simd-6.C b/libgomp/testsuite/libgomp.c++/simd-6.C index cfc13d0a0f9..fa93dfd5989 100644 --- a/libgomp/testsuite/libgomp.c++/simd-6.C +++ b/libgomp/testsuite/libgomp.c++/simd-6.C @@ -1,5 +1,4 @@ // { dg-do run } -// { dg-options "-O2" } // { dg-additional-options "-msse2" { target sse2_runtime } } // { dg-additional-options "-mavx" { target avx_runtime } } diff --git a/libgomp/testsuite/libgomp.c++/simd-7.C b/libgomp/testsuite/libgomp.c++/simd-7.C index 5a6f4cef7c1..a0bdac5e1b7 100644 --- a/libgomp/testsuite/libgomp.c++/simd-7.C +++ b/libgomp/testsuite/libgomp.c++/simd-7.C @@ -1,5 +1,4 @@ // { dg-do run } -// { dg-options "-O2" } // { dg-additional-options "-msse2" { target sse2_runtime } } // { dg-additional-options "-mavx" { target avx_runtime } } diff --git a/libgomp/testsuite/libgomp.c++/simd-8.C b/libgomp/testsuite/libgomp.c++/simd-8.C index 7c758328529..bc13254fdd3 100644 --- a/libgomp/testsuite/libgomp.c++/simd-8.C +++ b/libgomp/testsuite/libgomp.c++/simd-8.C @@ -1,6 +1,5 @@ // PR libgomp/58482 // { dg-do run } -// { dg-options "-O2" } // { dg-additional-options "-msse2" { target sse2_runtime } } // { dg-additional-options "-mavx" { target avx_runtime } } diff --git a/libgomp/testsuite/libgomp.c++/simd-9.C b/libgomp/testsuite/libgomp.c++/simd-9.C index 3c567b31c3e..8f21bf2209a 100644 --- a/libgomp/testsuite/libgomp.c++/simd-9.C +++ b/libgomp/testsuite/libgomp.c++/simd-9.C @@ -1,5 +1,4 @@ // { dg-do run } -// { dg-options "-O2" } // { dg-additional-options "-msse2" { target sse2_runtime } } // { dg-additional-options "-mavx" { target avx_runtime } } diff --git a/libgomp/testsuite/libgomp.c++/simd10.C b/libgomp/testsuite/libgomp.c++/simd10.C index 390e65ffea3..6fab68852a4 100644 --- a/libgomp/testsuite/libgomp.c++/simd10.C +++ b/libgomp/testsuite/libgomp.c++/simd10.C @@ -1,5 +1,4 @@ // { dg-do run } -// { dg-options "-O2" } // { dg-additional-options "-msse2" { target sse2_runtime } } // { dg-additional-options "-mavx" { target avx_runtime } } diff --git a/libgomp/testsuite/libgomp.c++/simd11.C b/libgomp/testsuite/libgomp.c++/simd11.C index b9668685601..fde22034a60 100644 --- a/libgomp/testsuite/libgomp.c++/simd11.C +++ b/libgomp/testsuite/libgomp.c++/simd11.C @@ -1,5 +1,4 @@ // { dg-do run } -// { dg-options "-O2" } // { dg-additional-options "-msse2" { target sse2_runtime } } // { dg-additional-options "-mavx" { target avx_runtime } } diff --git a/libgomp/testsuite/libgomp.c++/simd12.C b/libgomp/testsuite/libgomp.c++/simd12.C index ecfc912aeea..7596cad8571 100644 --- a/libgomp/testsuite/libgomp.c++/simd12.C +++ b/libgomp/testsuite/libgomp.c++/simd12.C @@ -1,5 +1,4 @@ // { dg-do run } -// { dg-options "-O2" } // { dg-additional-options "-msse2" { target sse2_runtime } } // { dg-additional-options "-mavx" { target avx_runtime } } diff --git a/libgomp/testsuite/libgomp.c++/simd13.C b/libgomp/testsuite/libgomp.c++/simd13.C index f7496209680..67a0f70ff16 100644 --- a/libgomp/testsuite/libgomp.c++/simd13.C +++ b/libgomp/testsuite/libgomp.c++/simd13.C @@ -1,5 +1,4 @@ // { dg-do run } -// { dg-options "-O2" } // { dg-additional-options "-msse2" { target sse2_runtime } } // { dg-additional-options "-mavx" { target avx_runtime } } diff --git a/libgomp/testsuite/libgomp.c++/target-2.C b/libgomp/testsuite/libgomp.c++/target-2.C index 83207cd51cd..35e910acc2e 100644 --- a/libgomp/testsuite/libgomp.c++/target-2.C +++ b/libgomp/testsuite/libgomp.c++/target-2.C @@ -1,4 +1,3 @@ -// { dg-options "-O2 -fopenmp" } // { dg-additional-sources "target-2-aux.cc" } extern "C" void abort (void); diff --git a/libgomp/testsuite/libgomp.c++/udr-11.C b/libgomp/testsuite/libgomp.c++/udr-11.C index 5d014467a9d..ee4bde319ad 100644 --- a/libgomp/testsuite/libgomp.c++/udr-11.C +++ b/libgomp/testsuite/libgomp.c++/udr-11.C @@ -1,4 +1,4 @@ // { dg-do run } -// { dg-options "-fopenmp -std=c++11" } +// { dg-additional-options "-std=c++11" } #include "udr-1.C" diff --git a/libgomp/testsuite/libgomp.c++/udr-12.C b/libgomp/testsuite/libgomp.c++/udr-12.C index 58112eb6995..1d661baba56 100644 --- a/libgomp/testsuite/libgomp.c++/udr-12.C +++ b/libgomp/testsuite/libgomp.c++/udr-12.C @@ -1,4 +1,4 @@ // { dg-do run } -// { dg-options "-fopenmp -std=c++11" } +// { dg-additional-options "-std=c++11" } #include "udr-2.C" diff --git a/libgomp/testsuite/libgomp.c++/udr-13.C b/libgomp/testsuite/libgomp.c++/udr-13.C index a9c8c600ca2..8e24ffd5007 100644 --- a/libgomp/testsuite/libgomp.c++/udr-13.C +++ b/libgomp/testsuite/libgomp.c++/udr-13.C @@ -1,4 +1,4 @@ // { dg-do run } -// { dg-options "-fopenmp -std=c++11" } +// { dg-additional-options "-std=c++11" } #include "udr-3.C" diff --git a/libgomp/testsuite/libgomp.c++/udr-14.C b/libgomp/testsuite/libgomp.c++/udr-14.C index 6cb48293286..49fabcbbdfc 100644 --- a/libgomp/testsuite/libgomp.c++/udr-14.C +++ b/libgomp/testsuite/libgomp.c++/udr-14.C @@ -1,4 +1,4 @@ // { dg-do run } -// { dg-options "-fopenmp -std=c++11" } +// { dg-additional-options "-std=c++11" } #include "udr-4.C" diff --git a/libgomp/testsuite/libgomp.c++/udr-15.C b/libgomp/testsuite/libgomp.c++/udr-15.C index d6aaf872029..e55101a0052 100644 --- a/libgomp/testsuite/libgomp.c++/udr-15.C +++ b/libgomp/testsuite/libgomp.c++/udr-15.C @@ -1,4 +1,4 @@ // { dg-do run } -// { dg-options "-fopenmp -std=c++11" } +// { dg-additional-options "-std=c++11" } #include "udr-5.C" diff --git a/libgomp/testsuite/libgomp.c++/udr-16.C b/libgomp/testsuite/libgomp.c++/udr-16.C index acf4ff2028d..50fe6724bb2 100644 --- a/libgomp/testsuite/libgomp.c++/udr-16.C +++ b/libgomp/testsuite/libgomp.c++/udr-16.C @@ -1,4 +1,4 @@ // { dg-do run } -// { dg-options "-fopenmp -std=c++11" } +// { dg-additional-options "-std=c++11" } #include "udr-6.C" diff --git a/libgomp/testsuite/libgomp.c++/udr-17.C b/libgomp/testsuite/libgomp.c++/udr-17.C index a5b62f8c67f..770b50d764d 100644 --- a/libgomp/testsuite/libgomp.c++/udr-17.C +++ b/libgomp/testsuite/libgomp.c++/udr-17.C @@ -1,4 +1,4 @@ // { dg-do run } -// { dg-options "-fopenmp -std=c++11" } +// { dg-additional-options "-std=c++11" } #include "udr-7.C" diff --git a/libgomp/testsuite/libgomp.c++/udr-18.C b/libgomp/testsuite/libgomp.c++/udr-18.C index 5911e8e9a82..fb1f10c7508 100644 --- a/libgomp/testsuite/libgomp.c++/udr-18.C +++ b/libgomp/testsuite/libgomp.c++/udr-18.C @@ -1,4 +1,4 @@ // { dg-do run } -// { dg-options "-fopenmp -std=c++11" } +// { dg-additional-options "-std=c++11" } #include "udr-8.C" diff --git a/libgomp/testsuite/libgomp.c++/udr-19.C b/libgomp/testsuite/libgomp.c++/udr-19.C index 801cab4342e..40d2eb9aeed 100644 --- a/libgomp/testsuite/libgomp.c++/udr-19.C +++ b/libgomp/testsuite/libgomp.c++/udr-19.C @@ -1,4 +1,4 @@ // { dg-do run } -// { dg-options "-fopenmp -std=c++11" } +// { dg-additional-options "-std=c++11" } #include "udr-9.C" -- 2.30.2