On Thu, Mar 26, 2026 at 6:40 PM Alexandre Oliva <[email protected]> wrote:
>
>
> !a-b-c is not the same as ! a-b-c. In !a-b-c, the '!' is part of the
> triplet that istarget attempts to match. Fix all occurrences, except
> for gcc.dg/vect/vect-93.c, that is taken care of separately.
>
> Regstrapped on x86_64-linux-gnu. Also tested with ppc-vx7r2,
> ppc64-vx7r2, arm-vx7r2, and aarch64-vx7r2. Ok to install?
Ok.
>
>
> for gcc/testsuite/ChangeLog
>
> * gcc.dg/debug/btf/btf-variables-5.c: Separate ! from triplet.
> * gcc.dg/hoist-register-pressure-1.c: Likewise.
> * gcc.dg/hoist-register-pressure-2.c: Likewise.
> * gcc.dg/hoist-register-pressure-3.c: Likewise.
> * gcc.target/powerpc/safe-indirect-jump-1.c: Likewise.
> * gfortran.dg/gomp/declare-variant-14.f90: Likewise.
> ---
> gcc/testsuite/gcc.dg/debug/btf/btf-variables-5.c | 2 +-
> gcc/testsuite/gcc.dg/hoist-register-pressure-1.c | 2 +-
> gcc/testsuite/gcc.dg/hoist-register-pressure-2.c | 2 +-
> gcc/testsuite/gcc.dg/hoist-register-pressure-3.c | 2 +-
> .../gcc.target/powerpc/safe-indirect-jump-1.c | 4 ++--
> .../gfortran.dg/gomp/declare-variant-14.f90 | 2 +-
> 6 files changed, 7 insertions(+), 7 deletions(-)
>
> diff --git a/gcc/testsuite/gcc.dg/debug/btf/btf-variables-5.c
> b/gcc/testsuite/gcc.dg/debug/btf/btf-variables-5.c
> index a08130cfc0725..1d8d7778d273d 100644
> --- a/gcc/testsuite/gcc.dg/debug/btf/btf-variables-5.c
> +++ b/gcc/testsuite/gcc.dg/debug/btf/btf-variables-5.c
> @@ -14,7 +14,7 @@
> /* Expect 2 array types, one of which is unsized. For BPF target,
> -gprune-btf
> is the default and will remove the unsized array type. */
> /* { dg-final { scan-assembler-times "\[\t \]0x4\[\t \]+\[^\n\]*bta_nelems"
> 1 } } */
> -/* { dg-final { scan-assembler-times "\[\t \]0\[\t \]+\[^\n\]*bta_nelems" 1
> { target { !bpf-*-* } } } } */
> +/* { dg-final { scan-assembler-times "\[\t \]0\[\t \]+\[^\n\]*bta_nelems" 1
> { target { ! bpf-*-* } } } } */
> /* { dg-final { scan-assembler-times "\[\t \]0\[\t \]+\[^\n\]*bta_nelems" 0
> { target { bpf-*-* } } } } */
>
> extern const char FOO[];
> diff --git a/gcc/testsuite/gcc.dg/hoist-register-pressure-1.c
> b/gcc/testsuite/gcc.dg/hoist-register-pressure-1.c
> index 6e566da4dba4b..516357d3c9201 100644
> --- a/gcc/testsuite/gcc.dg/hoist-register-pressure-1.c
> +++ b/gcc/testsuite/gcc.dg/hoist-register-pressure-1.c
> @@ -3,7 +3,7 @@
> be assigned without clobbering cc. For a PLUS rtx on S/390 this
> requires a load address instruction which is fine on 64 bit but
> cannot be used on 31 bit since it does a 31 bit add only. */
> -/* { dg-final { scan-rtl-dump "PRE/HOIST: end of bb .* copying expression"
> "hoist" { target { { !s390*-*-* || lp64 } && nonpic } } } } */
> +/* { dg-final { scan-rtl-dump "PRE/HOIST: end of bb .* copying expression"
> "hoist" { target { { { ! s390*-*-* } || lp64 } && nonpic } } } } */
>
> #define BUF 100
> long a[BUF];
> diff --git a/gcc/testsuite/gcc.dg/hoist-register-pressure-2.c
> b/gcc/testsuite/gcc.dg/hoist-register-pressure-2.c
> index 05ffd8d93f0ab..2e1283233788b 100644
> --- a/gcc/testsuite/gcc.dg/hoist-register-pressure-2.c
> +++ b/gcc/testsuite/gcc.dg/hoist-register-pressure-2.c
> @@ -3,7 +3,7 @@
> be assigned without clobbering cc. For a PLUS rtx on S/390 this
> requires a load address instruction which is fine on 64 bit but
> cannot be used on 31 bit since it does a 31 bit add only. */
> -/* { dg-final { scan-rtl-dump "PRE/HOIST: end of bb .* copying expression"
> "hoist" { target { !s390*-*-* || lp64 } } } } */
> +/* { dg-final { scan-rtl-dump "PRE/HOIST: end of bb .* copying expression"
> "hoist" { target { { ! s390*-*-* } || lp64 } } } } */
>
> #define BUF 100
> long a[BUF];
> diff --git a/gcc/testsuite/gcc.dg/hoist-register-pressure-3.c
> b/gcc/testsuite/gcc.dg/hoist-register-pressure-3.c
> index f274fa1334544..0a705edd79cf3 100644
> --- a/gcc/testsuite/gcc.dg/hoist-register-pressure-3.c
> +++ b/gcc/testsuite/gcc.dg/hoist-register-pressure-3.c
> @@ -3,7 +3,7 @@
> be assigned without clobbering cc. For a PLUS rtx on S/390 this
> requires a load address instruction which is fine on 64 bit but
> cannot be used on 31 bit since it does a 31 bit add only. */
> -/* { dg-final { scan-rtl-dump "PRE/HOIST: end of bb .* copying expression"
> "hoist" { target { !s390*-*-* || lp64 } } } } */
> +/* { dg-final { scan-rtl-dump "PRE/HOIST: end of bb .* copying expression"
> "hoist" { target { { ! s390*-*-* } || lp64 } } } } */
>
> #define BUF 100
> long a[BUF];
> diff --git a/gcc/testsuite/gcc.target/powerpc/safe-indirect-jump-1.c
> b/gcc/testsuite/gcc.target/powerpc/safe-indirect-jump-1.c
> index b9ad8c1dd36a6..adecb3cd67233 100644
> --- a/gcc/testsuite/gcc.target/powerpc/safe-indirect-jump-1.c
> +++ b/gcc/testsuite/gcc.target/powerpc/safe-indirect-jump-1.c
> @@ -18,5 +18,5 @@ int bar ()
> /* { dg-final { scan-assembler "beqctrl-" { target { lp64 || {
> powerpc*-*-aix* } } } } } */
>
> /* The other ABIs do allow a sibcall. */
> -/* { dg-final { scan-assembler "beqctr-" { target { ilp32 &&
> !powerpc*-*-aix* } } } } */
> -/* { dg-final { scan-assembler {b \$} { target { ilp32 && !powerpc*-*-aix* }
> } } } */
> +/* { dg-final { scan-assembler "beqctr-" { target { ilp32 && { !
> powerpc*-*-aix* } } } } } */
> +/* { dg-final { scan-assembler {b \$} { target { ilp32 && { !
> powerpc*-*-aix* } } } } } */
> diff --git a/gcc/testsuite/gfortran.dg/gomp/declare-variant-14.f90
> b/gcc/testsuite/gfortran.dg/gomp/declare-variant-14.f90
> index 71b66cb5d0869..0ac172d571c7f 100644
> --- a/gcc/testsuite/gfortran.dg/gomp/declare-variant-14.f90
> +++ b/gcc/testsuite/gfortran.dg/gomp/declare-variant-14.f90
> @@ -36,7 +36,7 @@ contains
> integer :: a, b
>
> ! At gimplification time, we can't decide yet which function to call.
> - ! { dg-final { scan-tree-dump-times "f04 \\\(x" 2 "gimple" { target {
> !aarch64*-*-* } } } }
> + ! { dg-final { scan-tree-dump-times "f04 \\\(x" 2 "gimple" { target { !
> aarch64*-*-* } } } }
> ! After simd clones are created, the original non-clone test1 shall
> ! call f03 (score 6), the sse2/avx/avx2 clones too, but avx512f clones
> ! shall call f01 with score 8.
>
>
> --
> Alexandre Oliva, happy hacker https://blog.lx.oliva.nom.br/
> Free Software Activist FSFLA co-founder GNU Toolchain Engineer
> More tolerance and less prejudice are key for inclusion and diversity.
> Excluding neuro-others for not behaving ""normal"" is *not* inclusive!