> -----Original Message-----
> From: Iain Sandoe <[email protected]>
> Sent: 15 July 2026 20:25
> To: Karl Meakin <[email protected]>; Tamar Christina
> <[email protected]>; [email protected]
> Subject: [PATCH] aarch64: Add dg-requires for BE support where it used.
> 
> Tested on aarch64-linux and aarch64-darwin where this resolves around 40
> fails and over 1400 UNRESOLVED (on cfarm425 as well).  I guess this is
> borderline obvious - but in case I missed something .. OK for trunk?

Hmm the UNRESOLVED come from aarch64/neon/* but the other tests, are
Assemble and compile only tests and most of them avoid using standard headers
such that they work without tripping over glibc's ABI variant thing which is 
what
prevents the header includes to work when using -mbig-endian and the assembler
also supports both (well, gas does).

But for those tests using stdint_types_mbig_endian effective check should work.

So I don't think we want the check for big-endian on the tests outside of
aarch64/neon.

> 
> diff --git a/gcc/testsuite/gcc.target/aarch64/neon/aarch64-neon.exp
> b/gcc/testsuite/gcc.target/aarch64/neon/aarch64-neon.exp
> index e3a48b306a5..258d632797c 100644
> --- a/gcc/testsuite/gcc.target/aarch64/neon/aarch64-neon.exp
> +++ b/gcc/testsuite/gcc.target/aarch64/neon/aarch64-neon.exp
> @@ -35,9 +35,11 @@ dg-init
>  dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/*\[cCs\]]] \
>       " -ansi -pedantic-errors -std=c23 -O2 -march=armv8-a+simd" ""
> 
> -# Again, for big-endian targets.
> -dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/*\[cCs\]]] \
> +if { [istarget be] } then {
> +    # Again, for big-endian targets.
> +    dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/*\[cCs\]]] \
>       " -ansi -pedantic-errors -std=c23 -O2 -march=armv8-a+simd -mbig-
> endian" ""
> +}
> 

I think the change here is all that's needed, but I think we should just remove
this check entirely.

Karl did submit a similar patch to the above for this but I forgot about it 
until now.

But I think we should just remove this, since due to GLIBC's ABI variants it's
very hard to get big endian codegen to work on linux compilers.  As such these
tests will never run on little-endian for most people.

But then on big-endian they'll run twice because the "normal" variant doesn't 
force
little endian. So on Big Endian they'll effectively be the same thing.

A patch to drop the entire " Again, for big-endian targets." Blob in 
aarch64/neon/aarch64-neon.exp

Is thus OK and pre-approved should you want to commit that.

Thanks,
Tamar

Reply via email to