public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] arm: [testsuite] fix lob tests for -mfloat-abi=hard
@ 2020-11-26 13:53 Andrea Corallo
  2020-11-26 14:34 ` Richard Earnshaw (lists)
  2020-11-26 14:34 ` [PATCH] " Kyrylo Tkachov
  0 siblings, 2 replies; 9+ messages in thread
From: Andrea Corallo @ 2020-11-26 13:53 UTC (permalink / raw)
  To: gcc-patches; +Cc: Kyrylo Tkachov, Richard Earnshaw, nd

[-- Attachment #1: Type: text/plain, Size: 349 bytes --]

Hi all,

I'd like to submit the following simple patch to clean some Low Loop
Overhead test failing on hard float configurations.

lob2.c and lob5.c are failing with: "'-mfloat-abi=hard': selected 
processor lacks an FPU".

lob3.c and lob5.c got "-mfloat-abi=soft and -mfloat-abi=hard may not
be used together".

Okay for trunk?

Thanks
  Andrea
  

[-- Attachment #2: 0001-arm-testsuite-fix-lob-tests-for-mfloat-abi-hard.patch --]
[-- Type: text/plain, Size: 3439 bytes --]

From ac47dfed0230d9fe596d27331b04ef194633927d Mon Sep 17 00:00:00 2001
From: Andrea Corallo <andrea.corallo@arm.com>
Date: Thu, 26 Nov 2020 12:33:18 +0100
Subject: [PATCH] arm: [testsuite] fix lob tests for -mfloat-abi=hard

2020-11-26  Andrea Corallo  <andrea.corallo@arm.com>

	* gcc.target/arm/lob2.c: Add '-mfpu=fp-armv8' flag.
	* gcc.target/arm/lob3.c: Skip with '-mfloat-abi=hard'.
	* gcc.target/arm/lob4.c: Likewise.
	* gcc.target/arm/lob5.c: Add '-mfpu=fp-armv8' flag.
---
 gcc/testsuite/gcc.target/arm/lob2.c | 2 +-
 gcc/testsuite/gcc.target/arm/lob3.c | 2 +-
 gcc/testsuite/gcc.target/arm/lob4.c | 2 +-
 gcc/testsuite/gcc.target/arm/lob5.c | 2 +-
 4 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/gcc/testsuite/gcc.target/arm/lob2.c b/gcc/testsuite/gcc.target/arm/lob2.c
index fdeb2686f51..2a7e2fd3d89 100644
--- a/gcc/testsuite/gcc.target/arm/lob2.c
+++ b/gcc/testsuite/gcc.target/arm/lob2.c
@@ -2,7 +2,7 @@
    if a non-inlineable function call takes place inside the loop.  */
 /* { dg-do compile } */
 /* { dg-skip-if "avoid conflicting multilib options" { *-*-* } { "-marm" "-mcpu=*" } } */
-/* { dg-options "-march=armv8.1-m.main -mthumb -O3 --save-temps" } */
+/* { dg-options "-march=armv8.1-m.main -mfpu=fp-armv8 -mthumb -O3 --save-temps" } */
 #include <stdlib.h>
 #include "lob.h"
 
diff --git a/gcc/testsuite/gcc.target/arm/lob3.c b/gcc/testsuite/gcc.target/arm/lob3.c
index 70314ea84b3..f5290063f28 100644
--- a/gcc/testsuite/gcc.target/arm/lob3.c
+++ b/gcc/testsuite/gcc.target/arm/lob3.c
@@ -1,7 +1,7 @@
 /* Check that GCC does not generate Armv8.1-M low over head loop instructions
    if causes VFP emulation library calls to happen inside the loop.  */
 /* { dg-do compile } */
-/* { dg-skip-if "avoid conflicting multilib options" { *-*-* } { "-marm" "-mcpu=*" } } */
+/* { dg-skip-if "avoid conflicting multilib options" { *-*-* } { "-marm" "-mcpu=*" "-mfloat-abi=hard" } } */
 /* { dg-options "-march=armv8.1-m.main -mthumb -O3 --save-temps -mfloat-abi=soft" } */
 /* { dg-require-effective-target arm_softfloat } */
 #include <stdlib.h>
diff --git a/gcc/testsuite/gcc.target/arm/lob4.c b/gcc/testsuite/gcc.target/arm/lob4.c
index 792f352d682..86c774e1b57 100644
--- a/gcc/testsuite/gcc.target/arm/lob4.c
+++ b/gcc/testsuite/gcc.target/arm/lob4.c
@@ -1,7 +1,7 @@
 /* Check that GCC does not generate Armv8.1-M low over head loop instructions
    if LR is modified within the loop.  */
 /* { dg-do compile } */
-/* { dg-skip-if "avoid conflicting multilib options" { *-*-* } { "-marm" "-mcpu=*" } } */
+/* { dg-skip-if "avoid conflicting multilib options" { *-*-* } { "-marm" "-mcpu=*" "-mfloat-abi=hard" } } */
 /* { dg-options "-march=armv8.1-m.main -mthumb -O3 --save-temps -mfloat-abi=soft" } */
 /* { dg-require-effective-target arm_softfloat } */
 #include <stdlib.h>
diff --git a/gcc/testsuite/gcc.target/arm/lob5.c b/gcc/testsuite/gcc.target/arm/lob5.c
index 1a6adf1e28e..ea8523d3c77 100644
--- a/gcc/testsuite/gcc.target/arm/lob5.c
+++ b/gcc/testsuite/gcc.target/arm/lob5.c
@@ -3,7 +3,7 @@
    therefore is not optimizable.  Outer loops are not optimized.  */
 /* { dg-do compile } */
 /* { dg-skip-if "avoid conflicting multilib options" { *-*-* } { "-marm" "-mcpu=*" } } */
-/* { dg-options "-march=armv8.1-m.main -mthumb -O3 --save-temps" } */
+/* { dg-options "-march=armv8.1-m.main -mfpu=fp-armv8 -mthumb -O3 --save-temps" } */
 #include <stdlib.h>
 #include "lob.h"
 
-- 
2.20.1


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2020-12-11 14:26 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-26 13:53 [PATCH] arm: [testsuite] fix lob tests for -mfloat-abi=hard Andrea Corallo
2020-11-26 14:34 ` Richard Earnshaw (lists)
2020-11-26 16:48   ` Andrea Corallo
2020-11-27 10:31     ` Andrea Corallo
2020-12-01 10:12       ` [PATCH V2] " Andrea Corallo
2020-12-08 11:09         ` Andrea Corallo
2020-12-11 11:21         ` Kyrylo Tkachov
2020-12-11 14:25           ` Andrea Corallo
2020-11-26 14:34 ` [PATCH] " Kyrylo Tkachov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).