diff mbox series

disable some aapcs/vfp*.c test if not arm_fp16_alternative_ok

Message ID orv9ctfr7z.fsf@lxoliva.fsfla.org
State New
Headers show
Series disable some aapcs/vfp*.c test if not arm_fp16_alternative_ok | expand

Commit Message

Alexandre Oliva Dec. 22, 2020, 9:47 p.m. UTC
The tests use -mfp16-format=alternative, and so should not be run
if that option isn't supported.

Regstrapped on x86_64-linux-gnu, and tested with -x-arm-wrs-vxworks7r2.
Ok to install?


from Joel Brobecker <brobecker@adacore.com>
for  gcc/testsuite/ChangeLog

	* lib/target-supports.exp
	(check_effective_target_arm_fp16_alternative_ok_nocache):
	Return zero for *-*-vxworks7r* targets.
	* gcc.target/arm/aapcs/vfp22.c: Require arm_fp16_alternative_ok.
	* gcc.target/arm/aapcs/vfp22.c: Likewise.
	* gcc.target/arm/aapcs/vfp24.c: Likewise.
	* gcc.target/arm/aapcs/vfp25.c: Likewise.
---
 gcc/testsuite/gcc.target/arm/aapcs/vfp22.c |    1 +
 gcc/testsuite/gcc.target/arm/aapcs/vfp23.c |    1 +
 gcc/testsuite/gcc.target/arm/aapcs/vfp24.c |    1 +
 gcc/testsuite/gcc.target/arm/aapcs/vfp25.c |    1 +
 gcc/testsuite/lib/target-supports.exp      |    4 ++++
 5 files changed, 8 insertions(+)

Comments

Mike Stump Dec. 29, 2020, 7:25 p.m. UTC | #1
On Dec 22, 2020, at 1:47 PM, Alexandre Oliva <oliva@adacore.com> wrote:
> 
> The tests use -mfp16-format=alternative, and so should not be run
> if that option isn't supported.
> 
> Regstrapped on x86_64-linux-gnu, and tested with -x-arm-wrs-vxworks7r2.
> Ok to install?

Ok.
diff mbox series

Patch

diff --git a/gcc/testsuite/gcc.target/arm/aapcs/vfp22.c b/gcc/testsuite/gcc.target/arm/aapcs/vfp22.c
index 1944bb592a869..fc22792eb7937 100644
--- a/gcc/testsuite/gcc.target/arm/aapcs/vfp22.c
+++ b/gcc/testsuite/gcc.target/arm/aapcs/vfp22.c
@@ -3,6 +3,7 @@ 
 /* { dg-do run { target arm_eabi } }  */
 /* { dg-require-effective-target arm_hard_vfp_ok }  */
 /* { dg-require-effective-target arm_fp16_hw }  */
+/* { dg-require-effective-target arm_fp16_alternative_ok } */
 /* { dg-add-options arm_fp16_alternative }  */
 
 #ifndef IN_FRAMEWORK
diff --git a/gcc/testsuite/gcc.target/arm/aapcs/vfp23.c b/gcc/testsuite/gcc.target/arm/aapcs/vfp23.c
index bcacf9f37c863..469aabd14a001 100644
--- a/gcc/testsuite/gcc.target/arm/aapcs/vfp23.c
+++ b/gcc/testsuite/gcc.target/arm/aapcs/vfp23.c
@@ -3,6 +3,7 @@ 
 /* { dg-do run { target arm_eabi } }  */
 /* { dg-require-effective-target arm_hard_vfp_ok }  */
 /* { dg-require-effective-target arm_fp16_hw }  */
+/* { dg-require-effective-target arm_fp16_alternative_ok } */
 /* { dg-add-options arm_fp16_alternative }  */
 
 #ifndef IN_FRAMEWORK
diff --git a/gcc/testsuite/gcc.target/arm/aapcs/vfp24.c b/gcc/testsuite/gcc.target/arm/aapcs/vfp24.c
index ef36bb7b52bc2..80a46821946f9 100644
--- a/gcc/testsuite/gcc.target/arm/aapcs/vfp24.c
+++ b/gcc/testsuite/gcc.target/arm/aapcs/vfp24.c
@@ -3,6 +3,7 @@ 
 /* { dg-do run { target arm_eabi } }  */
 /* { dg-require-effective-target arm_hard_vfp_ok }  */
 /* { dg-require-effective-target arm_fp16_hw }  */
+/* { dg-require-effective-target arm_fp16_alternative_ok } */
 /* { dg-add-options arm_fp16_alternative }  */
 
 #ifndef IN_FRAMEWORK
diff --git a/gcc/testsuite/gcc.target/arm/aapcs/vfp25.c b/gcc/testsuite/gcc.target/arm/aapcs/vfp25.c
index 3c796ca044ff5..649c1750f85b7 100644
--- a/gcc/testsuite/gcc.target/arm/aapcs/vfp25.c
+++ b/gcc/testsuite/gcc.target/arm/aapcs/vfp25.c
@@ -3,6 +3,7 @@ 
 /* { dg-do run { target arm_eabi } }  */
 /* { dg-require-effective-target arm_hard_vfp_ok }  */
 /* { dg-require-effective-target arm_fp16_hw }  */
+/* { dg-require-effective-target arm_fp16_alternative_ok } */
 /* { dg-add-options arm_fp16_alternative }  */
 
 #ifndef IN_FRAMEWORK
diff --git a/gcc/testsuite/lib/target-supports.exp b/gcc/testsuite/lib/target-supports.exp
index 6b1d13b105da7..16252243aa980 100644
--- a/gcc/testsuite/lib/target-supports.exp
+++ b/gcc/testsuite/lib/target-supports.exp
@@ -4367,6 +4367,10 @@  proc add_options_for_aarch64_sve { flags } {
 # set et_arm_neon_fp16_flags to the best options to add.
 
 proc check_effective_target_arm_fp16_alternative_ok_nocache { } {
+    if { [istarget *-*-vxworks7*] } {
+	# Not supported by the target system.
+	return 0
+    }
     global et_arm_neon_fp16_flags
     set et_arm_neon_fp16_flags ""
     if { [check_effective_target_arm32] } {