Several AVX512BW and AVX512DQ tests FAIL on Solaris/x86 with the native
assembler.  As detailed in the PR, this is for two reasons:

* Due to a misunderstanding, %k0 isn't accepted as source or destination
  register of some insns.

* {sae} is considered implicit for some insns, so specifying it
  explicitly was deemed unnecessary.

It's unclear if and when this will be fixed, so avx512bw and avx512dq
tests are disabled for now.

Tested on i386-pc-solaris2.11 and x86_64-pc-linux-gnu.

Ok for trunk?

        Rainer

-- 
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University


2025-12-23  Rainer Orth  <[email protected]>

        gcc/testsuite:
        PR target/123415
        * lib/target-supports.exp (check_effective_target_avx512dq):
        Disable with Solaris/x86 as.
        (check_effective_target_avx512bw): Likewise.

# HG changeset patch
# Parent  fdede8676ad94ee36d59d4223de6dbb9d239a9a0
testsuite: i386: Disable AVX512BW/DQ tests with Solaris as

diff --git a/gcc/testsuite/lib/target-supports.exp b/gcc/testsuite/lib/target-supports.exp
--- a/gcc/testsuite/lib/target-supports.exp
+++ b/gcc/testsuite/lib/target-supports.exp
@@ -11688,6 +11688,10 @@ proc check_effective_target_sha { } {
 
 # Return 1 if avx512dq instructions can be compiled.
 proc check_effective_target_avx512dq { } {
+    # PR target/123415: Solaris/x86 doesn't accept {sae} syntax.
+    if { [istarget *-*-solaris2*] && ![check_effective_target_gas] } {
+	return 0;
+    }
     return [check_no_compiler_messages avx512dq object {
 	typedef long long __v8di __attribute__ ((__vector_size__ (64)));
 	__v8di
@@ -11703,6 +11707,11 @@ proc check_effective_target_avx512dq { }
 
 # Return 1 if avx512bw instructions can be compiled.
 proc check_effective_target_avx512bw { } {
+    # PR target/123415: Solaris/x86 doesn't accept %k0 as source/destination
+    # in some cases.
+    if { [istarget *-*-solaris2*] && ![check_effective_target_gas] } {
+	return 0;
+    }
     return [check_no_compiler_messages avx512bw object {
 	typedef short __v32hi __attribute__ ((__vector_size__ (64)));
 	__v32hi

Reply via email to