This fixes a logical inconsistency with the SVE2 ACLE tests where the SVE2 tests
are checking for SVE support in the assembler instead of SVE2.
This makes all these tests fail when the user has an SVE enabled assembler but
not an SVE2 one.
gcc/testsuite/ChangeLog:
* lib/target-supports.exp
(check_effective_target_aarch64_asm_sve2_ok): New.
* g++.target/aarch64/sve2/acle/aarch64-sve2-acle-asm.exp: Use it.
* gcc.target/aarch64/sve2/acle/aarch64-sve2-acle-asm.exp: Likewise.
# Main loop.
set files [glob -nocomplain $srcdir/$gcc_subdir/asm/*.c]
set save-dg-do-what-default ${dg-do-what-default}
-if { [check_effective_target_aarch64_asm_sve_ok]
+if { [check_effective_target_aarch64_asm_sve2_ok]
&& [check_effective_target_aarch64_variant_pcs] } {
set dg-do-what-default assemble
} else {
# Main loop.
set files [glob -nocomplain $srcdir/$subdir/asm/*.c]
set save-dg-do-what-default ${dg-do-what-default}
-if { [check_effective_target_aarch64_asm_sve_ok]
+if { [check_effective_target_aarch64_asm_sve2_ok]
&& [check_effective_target_aarch64_variant_pcs] } {
set dg-do-what-default assemble
} else {
# various architecture extensions via the .arch_extension pseudo-op.
foreach { aarch64_ext } { "fp" "simd" "crypto" "crc" "lse" "dotprod" "sve"
- "i8mm" "f32mm" "f64mm" "bf16" "sb" } {
+ "i8mm" "f32mm" "f64mm" "bf16" "sb" "sve2" } {
eval [string map [list FUNC $aarch64_ext] {
proc check_effective_target_aarch64_asm_FUNC_ok { } {
if { [istarget aarch64*-*-*] } {