summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/compat
diff options
context:
space:
mode:
authoruros <uros@138bc75d-0d04-0410-961f-82ee72b054a4>2010-07-23 11:33:19 +0000
committeruros <uros@138bc75d-0d04-0410-961f-82ee72b054a4>2010-07-23 11:33:19 +0000
commit9704d177a19e24211c50b0a8a6e8c231091e1012 (patch)
tree864361e650ba529aa3cdf3faf3469f92fb3c0727 /gcc/testsuite/gcc.dg/compat
parent4efe5044ae78d6599df7917fcbcbc807b020ee2e (diff)
downloadgcc-9704d177a19e24211c50b0a8a6e8c231091e1012.tar.gz
* lib/target-supports.exp (check_avx_hw_available): New procedure.
(check_effective_target_avx_runtime): New procedure. (check_effective_target_sse2_runtime): Add check_effective_target_sse2. (check_effective_target_sse_runtime): Add check_effective_target_sse. * gcc.dg/compat/pr38736_main.c: Use avx_runtime effective target. * gcc.dg/compat/vector-1b_main.c: Ditto. Remove cpuid.h include and __get_cpuid test. * gcc.dg/compat/vector-2b_main.c: Ditto. * gcc.target/i386/avx-check.h (main): Also check bit_OSXSAVE. * gcc.dg/20020418-1.c: Do not require sse2 effective target for compile-time only test. * gcc.dg/pr32716.c: Ditto. * gcc.dg/pr34856.c: Ditto. * gcc.dg/pr36997.c: Ditto. * gcc.dg/prefetch-loop-arrays-1.c: Ditto. * gfortran.dg/pr28158.f90: Ditto. * gfortran.dg/pr30667.f: Ditto. * gcc.dg/vect/vect.exp: Use check_effective_target_sse2_runtime for i?86-*-* and x86_64-*-* targets to disable execution on targets without sse2 runtime support. * g++.dg/vect/vect.exp: Ditto. * gfortran.dg/vect/vect.exp: Ditto. * gcc.dg/pr36584.c: Remove now redundant sse2 effective target check. * gcc.dg/pr37544.c: Ditto. * gcc.dg/pr40550.c: Ditto. * gcc.dg/compat/union-m128-1_main.c: Ditto. * gcc.dg/compat/vector-1a_main.c: Ditto. * gcc.dg/compat/vector-2a_main.c: Ditto. * gcc.dg/torture/pr16104-1.c: Ditto. * gcc.dg/torture/pr35771-1.c: Ditto. * gcc.dg/torture/pr35771-2.c: Ditto. * gcc.dg/torture/pr35771-3.c: Ditto. * gcc.dg/torture/stackalign/alloca-2.c: Ditto. * gcc.dg/torture/stackalign/alloca-3.c: Ditto. * gcc.dg/torture/stackalign/push-1.c: Ditto. * gcc.dg/torture/stackalign/vararg-3.c: Ditto. * g++.dg/other/i386-1.C: Ditto. * g++.dg/other/pr40446.C: Ditto. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@162456 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite/gcc.dg/compat')
-rw-r--r--gcc/testsuite/gcc.dg/compat/pr38736_main.c2
-rw-r--r--gcc/testsuite/gcc.dg/compat/union-m128-1_main.c1
-rw-r--r--gcc/testsuite/gcc.dg/compat/vector-1a_main.c1
-rw-r--r--gcc/testsuite/gcc.dg/compat/vector-1b_main.c14
-rw-r--r--gcc/testsuite/gcc.dg/compat/vector-2a_main.c1
-rw-r--r--gcc/testsuite/gcc.dg/compat/vector-2b_main.c14
6 files changed, 5 insertions, 28 deletions
diff --git a/gcc/testsuite/gcc.dg/compat/pr38736_main.c b/gcc/testsuite/gcc.dg/compat/pr38736_main.c
index 88c3586db4b..8f221083c90 100644
--- a/gcc/testsuite/gcc.dg/compat/pr38736_main.c
+++ b/gcc/testsuite/gcc.dg/compat/pr38736_main.c
@@ -1,6 +1,6 @@
/* PR target/38736 */
/* { dg-skip-if "attribute ((aligned))" { ! { i?86-*-* x86_64-*-* } } } */
-/* { dg-require-effective-target avx } */
+/* { dg-require-effective-target avx_runtime } */
/* Test compatibility of attribute ((aligned)) with and without -mavx. */
diff --git a/gcc/testsuite/gcc.dg/compat/union-m128-1_main.c b/gcc/testsuite/gcc.dg/compat/union-m128-1_main.c
index 602acf8c112..59e68d96c7a 100644
--- a/gcc/testsuite/gcc.dg/compat/union-m128-1_main.c
+++ b/gcc/testsuite/gcc.dg/compat/union-m128-1_main.c
@@ -1,6 +1,5 @@
/* { dg-skip-if "test SSE2 support" { ! { i?86-*-* x86_64-*-* } } } */
/* { dg-options "-O" } */
-/* { dg-require-effective-target sse2 } */
/* { dg-require-effective-target sse2_runtime } */
/* Test function argument passing. PR target/15301. */
diff --git a/gcc/testsuite/gcc.dg/compat/vector-1a_main.c b/gcc/testsuite/gcc.dg/compat/vector-1a_main.c
index 11b4511749e..608f5dd9b85 100644
--- a/gcc/testsuite/gcc.dg/compat/vector-1a_main.c
+++ b/gcc/testsuite/gcc.dg/compat/vector-1a_main.c
@@ -1,5 +1,4 @@
/* { dg-skip-if "test SSE2 vector" { ! { i?86-*-* x86_64-*-* } } } */
-/* { dg-require-effective-target sse2 } */
/* { dg-require-effective-target sse2_runtime } */
/* Test compatibility of vector types: layout between separately-compiled
diff --git a/gcc/testsuite/gcc.dg/compat/vector-1b_main.c b/gcc/testsuite/gcc.dg/compat/vector-1b_main.c
index fb5a5a93d79..427e8caf38b 100644
--- a/gcc/testsuite/gcc.dg/compat/vector-1b_main.c
+++ b/gcc/testsuite/gcc.dg/compat/vector-1b_main.c
@@ -1,12 +1,10 @@
/* { dg-skip-if "test AVX vector" { ! { i?86-*-* x86_64-*-* } } } */
-/* { dg-require-effective-target avx } */
+/* { dg-require-effective-target avx_runtime } */
/* Test compatibility of vector types: layout between separately-compiled
modules, parameter passing, and function return. This test uses
vectors of integer values. */
-#include "cpuid.h"
-
extern void vector_1_x (void);
extern void exit (int);
int fails;
@@ -14,14 +12,6 @@ int fails;
int
main ()
{
- unsigned int eax, ebx, ecx, edx;
-
- if (!__get_cpuid (1, &eax, &ebx, &ecx, &edx))
- return 0;
-
- /* Run AVX vector test only if host has AVX support. */
- if (ecx & bit_AVX)
- vector_1_x ();
-
+ vector_1_x ();
exit (0);
}
diff --git a/gcc/testsuite/gcc.dg/compat/vector-2a_main.c b/gcc/testsuite/gcc.dg/compat/vector-2a_main.c
index 8457e5aedc3..e957faf90d2 100644
--- a/gcc/testsuite/gcc.dg/compat/vector-2a_main.c
+++ b/gcc/testsuite/gcc.dg/compat/vector-2a_main.c
@@ -1,5 +1,4 @@
/* { dg-skip-if "test SSE2 support" { ! { i?86-*-* x86_64-*-* } } } */
-/* { dg-require-effective-target sse2 } */
/* { dg-require-effective-target sse2_runtime } */
/* Test compatibility of vector types: layout between separately-compiled
diff --git a/gcc/testsuite/gcc.dg/compat/vector-2b_main.c b/gcc/testsuite/gcc.dg/compat/vector-2b_main.c
index c5a9300c8ac..2c195764249 100644
--- a/gcc/testsuite/gcc.dg/compat/vector-2b_main.c
+++ b/gcc/testsuite/gcc.dg/compat/vector-2b_main.c
@@ -1,12 +1,10 @@
/* { dg-skip-if "test AVX support" { ! { i?86-*-* x86_64-*-* } } } */
-/* { dg-require-effective-target avx } */
+/* { dg-require-effective-target avx_runtime } */
/* Test compatibility of vector types: layout between separately-compiled
modules, parameter passing, and function return. This test uses
vectors of floating points values. */
-#include "cpuid.h"
-
extern void vector_2_x (void);
extern void exit (int);
int fails;
@@ -14,14 +12,6 @@ int fails;
int
main ()
{
- unsigned int eax, ebx, ecx, edx;
-
- if (!__get_cpuid (1, &eax, &ebx, &ecx, &edx))
- return 0;
-
- /* Run AVX vector test only if host has AVX support. */
- if (ecx & bit_AVX)
- vector_2_x ();
-
+ vector_2_x ();
exit (0);
}