diff options
author | Richard Earnshaw <rearnsha@arm.com> | 2023-11-03 17:30:35 +0000 |
---|---|---|
committer | Richard Earnshaw <rearnsha@arm.com> | 2023-11-13 14:15:55 +0000 |
commit | 0fcc0eff6521cb28464771b78ba3231e060382c4 (patch) | |
tree | 21ba09cbcffe782a528658357dc6edf371bd1888 /gcc | |
parent | f757ea72edc3d34410a9cb13a01c6b1aaed0e1bc (diff) | |
download | gcc-0fcc0eff6521cb28464771b78ba3231e060382c4.zip gcc-0fcc0eff6521cb28464771b78ba3231e060382c4.tar.gz gcc-0fcc0eff6521cb28464771b78ba3231e060382c4.tar.bz2 |
arm: testsuite: tidy up pre-run check for g2.c
gcc.target/arm/g2.c is an xscale-only test, but the test is quite old
and we have improved the infrastructure for setting up such tests now.
So make use of that to reduce the number of cases where this test fails
to run.
gcc/testsuite:
* lib/target-supports.exp (check_effective_target_arm_arch_FUNC_ok):
Add entry to check for xscale.
* gcc.target/arm/g2.c: Use it.
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/testsuite/gcc.target/arm/g2.c | 10 | ||||
-rw-r--r-- | gcc/testsuite/lib/target-supports.exp | 1 |
2 files changed, 5 insertions, 6 deletions
diff --git a/gcc/testsuite/gcc.target/arm/g2.c b/gcc/testsuite/gcc.target/arm/g2.c index ca5e3cc..04334c9 100644 --- a/gcc/testsuite/gcc.target/arm/g2.c +++ b/gcc/testsuite/gcc.target/arm/g2.c @@ -1,11 +1,9 @@ /* Verify that hardware multiply is preferred on XScale. */ /* { dg-do compile } */ -/* { dg-options "-mcpu=xscale -O2 -marm" } */ -/* { dg-skip-if "Test is specific to the Xscale" { arm*-*-* } { "-march=*" } { "-march=xscale" } } */ -/* { dg-skip-if "Test is specific to the Xscale" { arm*-*-* } { "-mcpu=*" } { "-mcpu=xscale" } } */ -/* { dg-skip-if "Test is specific to ARM mode" { arm*-*-* } { "-mthumb" } { "" } } */ -/* { dg-require-effective-target arm_arch_v5te_arm_ok } */ -/* { dg-require-effective-target arm32 } */ +/* { dg-options "-O2" } */ +/* { dg-require-effective-target arm_arch_xscale_arm_ok } */ +/* { dg-add-options arm_arch_xscale_arm } */ + /* Brett Gaines' test case. */ unsigned BCPL(unsigned) __attribute__ ((naked)); diff --git a/gcc/testsuite/lib/target-supports.exp b/gcc/testsuite/lib/target-supports.exp index 7d83bd8..9d29586 100644 --- a/gcc/testsuite/lib/target-supports.exp +++ b/gcc/testsuite/lib/target-supports.exp @@ -5411,6 +5411,7 @@ foreach { armfunc armflag armdefs } { v5te "-march=armv5te+fp -mfloat-abi=softfp" __ARM_ARCH_5TE__ v5te_arm "-march=armv5te+fp -marm" __ARM_ARCH_5TE__ v5te_thumb "-march=armv5te+fp -mthumb -mfloat-abi=softfp" __ARM_ARCH_5TE__ + xscale_arm "-mcpu=xscale -mfloat-abi=soft -marm" __XSCALE__ v6 "-march=armv6+fp -mfloat-abi=softfp" __ARM_ARCH_6__ v6_arm "-march=armv6+fp -marm" __ARM_ARCH_6__ v6_thumb "-march=armv6+fp -mthumb -mfloat-abi=softfp" __ARM_ARCH_6__ |