diff mbox series

[5/5] testsuite: [arm/mve] Include arm_mve.h in arm_v8_1m_mve_ok

Message ID 20200410135553.3848-5-christophe.lyon@linaro.org
State New
Headers show
Series [1/5] testsuite: [arm] Add arm_softfp_ok and arm_hard_ok effective targets. | expand

Commit Message

Li, Pan2 via Gcc-patches April 10, 2020, 1:55 p.m. UTC
Since arm_mve.h includes stdint.h, its use requires the presence of
the right gnu/stub-*.h, so make sure to include it when checking the
arm_v8_1m_mve_ok_nocache effective target, otherwise we can decide MVE
is supported while it's not really. This makes several tests
unsupported rather than fail.

2020-04-10  Christophe Lyon  <christophe.lyon@linaro.org>

	gcc/testsuite/
	* lib/target-supports.exp
	(check_effective_target_arm_v8_1m_mve_ok_nocache): Include
	arm_mve.h.
---
 gcc/testsuite/lib/target-supports.exp | 1 +
 1 file changed, 1 insertion(+)

Comments

Andre Vieira (lists) April 14, 2020, 8:39 a.m. UTC | #1
On 10/04/2020 14:55, Christophe Lyon via Gcc-patches wrote:
> Since arm_mve.h includes stdint.h, its use requires the presence of
> the right gnu/stub-*.h, so make sure to include it when checking the
> arm_v8_1m_mve_ok_nocache effective target, otherwise we can decide MVE
> is supported while it's not really. This makes several tests
> unsupported rather than fail.
Hi Christophe,

LGTM, but you need to wait for maintainer approval.

Cheers,
Andre
>
> 2020-04-10  Christophe Lyon  <christophe.lyon@linaro.org>
>
> 	gcc/testsuite/
> 	* lib/target-supports.exp
> 	(check_effective_target_arm_v8_1m_mve_ok_nocache): Include
> 	arm_mve.h.
> ---
>   gcc/testsuite/lib/target-supports.exp | 1 +
>   1 file changed, 1 insertion(+)
>
> diff --git a/gcc/testsuite/lib/target-supports.exp b/gcc/testsuite/lib/target-supports.exp
> index 6c8dd01..d16498d 100644
> --- a/gcc/testsuite/lib/target-supports.exp
> +++ b/gcc/testsuite/lib/target-supports.exp
> @@ -4965,6 +4965,7 @@ proc check_effective_target_arm_v8_1m_mve_ok_nocache { } {
>   	    #if __ARM_BIG_ENDIAN
>   	    #error "MVE intrinsics are not supported in Big-Endian mode."
>   	    #endif
> +	    #include <arm_mve.h>
>           } "$flags -mthumb"] } {
>               set et_arm_v8_1m_mve_flags "$flags -mthumb --save-temps"
>               return 1
Kyrylo Tkachov April 22, 2020, 1:29 p.m. UTC | #2
> -----Original Message-----
> From: Gcc-patches <gcc-patches-bounces@gcc.gnu.org> On Behalf Of Andre
> Vieira (lists)
> Sent: 14 April 2020 09:40
> To: Christophe Lyon <christophe.lyon@linaro.org>
> Cc: gcc-patches@gcc.gnu.org
> Subject: Re: [PATCH 5/5] testsuite: [arm/mve] Include arm_mve.h in
> arm_v8_1m_mve_ok
> 
> 
> On 10/04/2020 14:55, Christophe Lyon via Gcc-patches wrote:
> > Since arm_mve.h includes stdint.h, its use requires the presence of
> > the right gnu/stub-*.h, so make sure to include it when checking the
> > arm_v8_1m_mve_ok_nocache effective target, otherwise we can decide
> MVE
> > is supported while it's not really. This makes several tests
> > unsupported rather than fail.
> Hi Christophe,
> 
> LGTM, but you need to wait for maintainer approval.

Ok.
Thanks,
Kyrill

> 
> Cheers,
> Andre
> >
> > 2020-04-10  Christophe Lyon  <christophe.lyon@linaro.org>
> >
> > 	gcc/testsuite/
> > 	* lib/target-supports.exp
> > 	(check_effective_target_arm_v8_1m_mve_ok_nocache): Include
> > 	arm_mve.h.
> > ---
> >   gcc/testsuite/lib/target-supports.exp | 1 +
> >   1 file changed, 1 insertion(+)
> >
> > diff --git a/gcc/testsuite/lib/target-supports.exp b/gcc/testsuite/lib/target-
> supports.exp
> > index 6c8dd01..d16498d 100644
> > --- a/gcc/testsuite/lib/target-supports.exp
> > +++ b/gcc/testsuite/lib/target-supports.exp
> > @@ -4965,6 +4965,7 @@ proc
> check_effective_target_arm_v8_1m_mve_ok_nocache { } {
> >   	    #if __ARM_BIG_ENDIAN
> >   	    #error "MVE intrinsics are not supported in Big-Endian mode."
> >   	    #endif
> > +	    #include <arm_mve.h>
> >           } "$flags -mthumb"] } {
> >               set et_arm_v8_1m_mve_flags "$flags -mthumb --save-temps"
> >               return 1
diff mbox series

Patch

diff --git a/gcc/testsuite/lib/target-supports.exp b/gcc/testsuite/lib/target-supports.exp
index 6c8dd01..d16498d 100644
--- a/gcc/testsuite/lib/target-supports.exp
+++ b/gcc/testsuite/lib/target-supports.exp
@@ -4965,6 +4965,7 @@  proc check_effective_target_arm_v8_1m_mve_ok_nocache { } {
 	    #if __ARM_BIG_ENDIAN
 	    #error "MVE intrinsics are not supported in Big-Endian mode."
 	    #endif
+	    #include <arm_mve.h>
         } "$flags -mthumb"] } {
             set et_arm_v8_1m_mve_flags "$flags -mthumb --save-temps"
             return 1