Re: [PATCH] testsuite: Restore dg-do run on pr116906 and pr78185 tests

2025-06-18 Thread Christophe Lyon
ping? On Mon, 26 May 2025 at 17:26, Christophe Lyon wrote: > > On Mon, 26 May 2025 at 17:14, Christophe Lyon > wrote: > > > > Commit r15-7152-g57b706d141b87c removed > > /* { dg-do run { target*-*-linux* *-*-gnu* *-*-uclinux* } } */ > > > > from these tests, turning them into 'compile' only test

Re: [PATCH] testsuite: Fix pr119160.c for non-glibc targets [PR119862]

2025-06-13 Thread Philipp Tomsich
Thank you, applied to trunk! --Philipp. On Fri, 13 Jun 2025 at 09:30, Konstantinos Eleftheriou wrote: > > On Thu, Jun 12, 2025 at 5:20 PM Jeff Law wrote: > > > > > > > > On 6/10/25 1:09 AM, Konstantinos Eleftheriou wrote: > > > Testcase pr119160.c fails with symbol referencing errors for > > >

Re: [PATCH] testsuite: Fix pr119160.c for non-glibc targets [PR119862]

2025-06-13 Thread Konstantinos Eleftheriou
On Thu, Jun 12, 2025 at 5:20 PM Jeff Law wrote: > > > > On 6/10/25 1:09 AM, Konstantinos Eleftheriou wrote: > > Testcase pr119160.c fails with symbol referencing errors for > > `__cyg_profile_func_enter` and `__cyg_profile_func_exit` on non-glibc > > systems. > > > > This patch adds empty definiti

Re: [PATCH] testsuite: Fix pr119160.c for non-glibc targets [PR119862]

2025-06-12 Thread Jeff Law
On 6/10/25 1:09 AM, Konstantinos Eleftheriou wrote: Testcase pr119160.c fails with symbol referencing errors for `__cyg_profile_func_enter` and `__cyg_profile_func_exit` on non-glibc systems. This patch adds empty definitions for `__cyg_profile_func_enter` and `__cyg_profile_func_exit` in ord

[patch,testsuite,applied] Fix test case for PR117811

2025-06-12 Thread Georg-Johann Lay
The test case for this PR did not work for int < 32 bit. Fixed thusly. Johann -- Fix test case for PR117811 which failed for int < 32 bit. PR middle-end/117811 PR testsuite/52641 gcc/testsuite/ * gcc.dg/torture/pr117811.c: Fix for int < 32 bit. diff

[PATCH] testsuite: Fix pr119160.c for non-glibc targets [PR119862]

2025-06-10 Thread Konstantinos Eleftheriou
Testcase pr119160.c fails with symbol referencing errors for `__cyg_profile_func_enter` and `__cyg_profile_func_exit` on non-glibc systems. This patch adds empty definitions for `__cyg_profile_func_enter` and `__cyg_profile_func_exit` in order to prevent those errors. PR testsuite/119862

Re: [PATCH] testsuite: Add tls_link effective target

2025-06-01 Thread Jeff Law
On 5/27/25 7:36 AM, Christophe Lyon wrote: Some tests have 'dg-do link' but currently require 'tls' which is a compile-only check. In some configurations of arm-none-eabi, the 'tls' effective-target can be successful although these tests fail to link with undefined reference to `__aeabi_read_

Re: [PATCH] testsuite: RISC-V: Fix the typo in param-autovec-mode.c

2025-06-01 Thread Jeff Law
On 5/28/25 7:59 PM, Liao Shihua wrote: This patch fixes the typo in the test case `param-autovec-mode.c` in the RISC-V autovec testsuite. The option `autovec-mode` is changed to `riscv-autovec-mode` to match the expected parameter name. gcc/testsuite/ChangeLog: * gcc.target/riscv

Re: [PATCH] testsuite: RISC-V: Fix the typo in param-autovec-mode.c

2025-05-28 Thread Robin Dapp
This patch fixes the typo in the test case `param-autovec-mode.c` in the RISC-V autovec testsuite. The option `autovec-mode` is changed to `riscv-autovec-mode` to match the expected parameter name. OK of course :) -- Regards Robin

[PATCH] testsuite: RISC-V: Fix the typo in param-autovec-mode.c

2025-05-28 Thread Liao Shihua
This patch fixes the typo in the test case `param-autovec-mode.c` in the RISC-V autovec testsuite. The option `autovec-mode` is changed to `riscv-autovec-mode` to match the expected parameter name. gcc/testsuite/ChangeLog: * gcc.target/riscv/rvv/autovec/param-autovec-mode.c: Change

[PATCH] testsuite: Add tls_link effective target

2025-05-27 Thread Christophe Lyon
Some tests have 'dg-do link' but currently require 'tls' which is a compile-only check. In some configurations of arm-none-eabi, the 'tls' effective-target can be successful although these tests fail to link with undefined reference to `__aeabi_read_tp' This patch as a new tls_link effective targ

[PATCH] testsuite: arm: remove arm32 check from a few effective-targets

2025-05-27 Thread Christophe Lyon
A few arm effective-targets call check_effective_target_arm32 even though they would force an -march=XXX flag which support Arm and/or Thumb-2, thus making the arm32 check useless. This has an impact when the toolchain is configured with a default -march or -mcpu which supports Thumb-1 only: in su

Re: Fwd: [PATCH] testsuite: Fix up dg-do-if

2025-05-26 Thread Alexandre Oliva
On May 26, 2025, Xi Ruoyao wrote: > gcc/testsuite/ChangeLog: > * lib/target-supports-dg.exp (dg-do-if): Pass the line number > to > dg-do. Thanks! I support that fix, FWIW. Indeed, an identical fix was included (but remains unreviewed) in https://gcc.gnu.org/pipermail/gcc-patches/

[PATCH] testsuite: arm: add needed -mcpu / -march to arm_crypto_ok

2025-05-26 Thread Christophe Lyon
This effective target implicitly expects -march=armv8-a, otherwise with a toolchain configured for instance with --with-cpu=cortex-m0 --with-float=soft, it fails even when trying -mfpu=crypto-neon-fp-armv8 -mfloat-abi=softfp: arm_neon.h:45:2: error: #error "NEON intrinsics not available with the s

[PATCH] testsuite, arm: factorize arm_v8_neon_ok flags

2025-05-26 Thread Christophe Lyon
Like we do in other effective-targets, add "-mcpu=unset -march=armv8-a" directly when setting et_arm_v8_neon_flags in arm_v8_neon_ok_nocache, to avoid having to add these two flags in all users of arm_v8_neon_ok. This avoids duplication and possible typos. gcc/testsuite/ChangeLog: * lib/t

Re: [PATCH] testsuite: Restore dg-do run on pr116906 and pr78185 tests

2025-05-26 Thread Christophe Lyon
On Mon, 26 May 2025 at 17:14, Christophe Lyon wrote: > > Commit r15-7152-g57b706d141b87c removed > /* { dg-do run { target*-*-linux* *-*-gnu* *-*-uclinux* } } */ > > from these tests, turning them into 'compile' only tests, even when > they could be executed. > > This patch adds > /* { dg-do run }

[PATCH] testsuite: Restore dg-do run on pr116906 and pr78185 tests

2025-05-26 Thread Christophe Lyon
Commit r15-7152-g57b706d141b87c removed /* { dg-do run { target*-*-linux* *-*-gnu* *-*-uclinux* } } */ from these tests, turning them into 'compile' only tests, even when they could be executed. This patch adds /* { dg-do run } */ which is OK since the tests are correctly skipped if needed thank

Re: [PATCH] testsuite: Fix pr101145inf*.c testcases [PR117494]

2025-05-26 Thread Andrew Pinski
> > To: Andrew Pinski (QUIC) > > > Cc: gcc-patches@gcc.gnu.org > > > Subject: Re: [PATCH] testsuite: Fix pr101145inf*.c testcases > > > [PR117494] > > > > > > Hi Andrew, > > > > > > On Sun, 17 Nov 2024 at 22:49, Andrew Pinski > &g

Re: [PATCH] testsuite: Fix pr101145inf*.c testcases [PR117494]

2025-05-26 Thread Christophe Lyon
,, On Mon, 26 May 2025 at 12:54, Andrew Pinski (QUIC) wrote: > > > -Original Message- > > From: Christophe Lyon > > Sent: Monday, May 26, 2025 3:09 AM > > To: Andrew Pinski (QUIC) > > Cc: gcc-patches@gcc.gnu.org > > Subject: Re: [PATCH]

RE: [PATCH] testsuite: Fix pr101145inf*.c testcases [PR117494]

2025-05-26 Thread Andrew Pinski (QUIC)
> -Original Message- > From: Christophe Lyon > Sent: Monday, May 26, 2025 3:09 AM > To: Andrew Pinski (QUIC) > Cc: gcc-patches@gcc.gnu.org > Subject: Re: [PATCH] testsuite: Fix pr101145inf*.c testcases > [PR117494] > > Hi Andrew, > > On Sun, 17 Nov 2024

Re: [PATCH] testsuite: Fix pr101145inf*.c testcases [PR117494]

2025-05-26 Thread Christophe Lyon
Hi Andrew, On Sun, 17 Nov 2024 at 22:49, Andrew Pinski wrote: > > Instead of doing a dg-run with a specific target check for linux. > Use signal as the effective-target since this requires the use > of ALARM signal to do the testing. > Also use check_vect in the main and renames main to main1 to

Fwd: [PATCH] testsuite: Fix up dg-do-if

2025-05-26 Thread Xi Ruoyao
I forgot to send this to the list :(. Forwarded Message From: Xi Ruoyao To: Alexandre Oliva Cc: Xi Ruoyao Subject: [PATCH] testsuite: Fix up dg-do-if Date: 05/26/25 17:59:32 The line number needs to be passed to dg-do, instead of being stripped. Fixes 'compile: syntax

Re: [PATCH] testsuite: Fix typo in parse_ctx.cc

2025-05-23 Thread Stefan Schulze Frielinghaus
On Wed, May 21, 2025 at 07:34:27PM +0200, Stefan Schulze Frielinghaus wrote: > libstdc++-v3/ChangeLog: > > * testsuite/std/format/parse_ctx.cc: Fix typo for bfloat16 guard. > --- > Ok for mainline? Just realized that I can use my super powers ;-) and pushed as obvious in commit 08b4f6198de

Re: [PATCH] testsuite: RISC-V: Update the cset-sext-sfb/zba-slliuw test optimization level.

2025-05-21 Thread Dongyan Chen
Thanks. I will pay attention to this. Dongyan Chen 在 2025/5/22 11:49, Jeff Law 写道: On 5/21/25 9:16 PM, Dongyan Chen wrote: Failed testcases occurred in the regression test of gcc: cset-sext-sfb.c failed the -Oz test, and zba-slliuw.c failed the -Og test. This patch solves the problem by ski

Re: [PATCH] testsuite: RISC-V: Update the cset-sext-sfb/zba-slliuw test optimization level.

2025-05-21 Thread Jeff Law
On 5/21/25 9:16 PM, Dongyan Chen wrote: Failed testcases occurred in the regression test of gcc: cset-sext-sfb.c failed the -Oz test, and zba-slliuw.c failed the -Og test. This patch solves the problem by skipping the optimization. gcc/testsuite/ChangeLog: * gcc.target/riscv/cset-sex

[PATCH] testsuite: RISC-V: Update the cset-sext-sfb/zba-slliuw test optimization level.

2025-05-21 Thread Dongyan Chen
Failed testcases occurred in the regression test of gcc: cset-sext-sfb.c failed the -Oz test, and zba-slliuw.c failed the -Og test. This patch solves the problem by skipping the optimization. gcc/testsuite/ChangeLog: * gcc.target/riscv/cset-sext-sfb.c: Skip for -Oz. * gcc.target/r

[PATCH] testsuite: Fix typo in parse_ctx.cc

2025-05-21 Thread Stefan Schulze Frielinghaus
libstdc++-v3/ChangeLog: * testsuite/std/format/parse_ctx.cc: Fix typo for bfloat16 guard. --- Ok for mainline? libstdc++-v3/testsuite/std/format/parse_ctx.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libstdc++-v3/testsuite/std/format/parse_ctx.cc b/libstdc++-v

Re: [PATCH] [testsuite] [x86] double copysign requires -msse2

2025-05-21 Thread Alexandre Oliva
On May 20, 2025, Alexandre Oliva wrote: > (This patch, as posted, applies on top of this: > https://gcc.gnu.org/pipermail/gcc-patches/2025-May/683066.html > plus the missing bit in the followup I've just posted) Since the ppc bits are not approved (yet?), I've rebased the x86 bits approved by Ur

Re: [PATCH] [testsuite] [x86] memcpy-6 needs -msse2

2025-05-21 Thread Alexandre Oliva
On May 20, 2025, Alexandre Oliva wrote: > * memcpy-6.c: Bump to -msse2. I'd missed gcc.dg/ in the ChangeLog, and the checker was adamant that I ought to fix it ;-) -- Alexandre Oliva, happy hackerhttps://blog.lx.oliva.nom.br/ Free Software Activist FSFLA co-founder GN

Re: [PATCH] [testsuite] tolerate missing std::stold

2025-05-21 Thread Alexandre Oliva
On May 20, 2025, Jonathan Wakely wrote: > On Tue, 20 May 2025, 05:00 Alexandre Oliva, wrote: > OK Thanks > Maybe we should just define it in terms of std::stod, so it always exists > but might not support the full accuracy of long double. That sounds desirable to me, FWIW, but from past exper

Re: [PATCH] [testsuite] [aarch64] match alt cache clear names in sme nonlocal_goto tests

2025-05-21 Thread Alexandre Oliva
On May 20, 2025, Richard Sandiford wrote: > Alexandre Oliva writes: >> -** bl __clear_cache >> +** bl .*ache.* > .* matches newlines, so how about: > bl [^\n]*[cC]ache[^\n]* > instead? OK if that works. Sure, thanks! Here's what I've installed: [testsuite] [aarch64

Re: [PATCH] testsuite: aarch64: arm: Fix -mcpu=unset support in shared effective targets

2025-05-21 Thread Andrew Pinski
On Tue, May 20, 2025, 1:47 PM Christophe Lyon wrote: > Many tests became unsupported on aarch64 when -mcpu=unset was added to > several arm_* effective targets, because this flag is only supported > on arm. > > Since these effective targets are used on arm and aarch64, the patch > adds -mcpu=unse

Re: [PATCH] testsuite: aarch64: arm: Fix -mcpu=unset support in shared effective targets

2025-05-21 Thread Christophe Lyon
On Wed, 21 May 2025 at 10:56, Richard Sandiford wrote: > > Christophe Lyon writes: > > Many tests became unsupported on aarch64 when -mcpu=unset was added to > > several arm_* effective targets, because this flag is only supported > > on arm. > > > > Since these effective targets are used on arm

Re: [PATCH] testsuite: aarch64: arm: Fix -mcpu=unset support in shared effective targets

2025-05-21 Thread Richard Sandiford
Christophe Lyon writes: > Many tests became unsupported on aarch64 when -mcpu=unset was added to > several arm_* effective targets, because this flag is only supported > on arm. > > Since these effective targets are used on arm and aarch64, the patch > adds -mcpu=unset on arm only, and restores ""

[PATCH] testsuite: aarch64: arm: Fix -mcpu=unset support in shared effective targets

2025-05-20 Thread Christophe Lyon
Many tests became unsupported on aarch64 when -mcpu=unset was added to several arm_* effective targets, because this flag is only supported on arm. Since these effective targets are used on arm and aarch64, the patch adds -mcpu=unset on arm only, and restores "" on aarch64. This re-enables lots o

Re: [PATCH] [testsuite] [aarch64] match alt cache clear names in sme nonlocal_goto tests

2025-05-20 Thread Richard Sandiford
Alexandre Oliva writes: > vxworks calls cacheTextUpdate instead of __clear_cache. > > Adjust the sme/nonlocal_goto_*.c tests for inexact matches. > > Regstrapped on x86_64-linux-gnu. Also tested with gcc-14 on aarch64-, > arm-, x86-, and x86_64-vxworks7r2. Ok to install? > > > for gcc/testsuite

Re: [PATCH] [testsuite] [aarch64] use uint64_t in rwsr tests

2025-05-20 Thread Richard Sandiford
Alexandre Oliva writes: > stdint.h defines uint64_t instead of __uint64_t, so use the former. > __uint64_t is not available on e.g. vxworks. > > Regstrapped on x86_64-linux-gnu. Also tested with gcc-14 on aarch64-, > arm-, x86-, and x86_64-vxworks7r2. Ok to install? > > > for gcc/testsuite/Chan

Re: [PATCH] [testsuite] [arm] adjust fp16-aapcs for gcc-14

2025-05-20 Thread Christophe Lyon
On Tue, 20 May 2025 at 06:30, Alexandre Oliva wrote: > > > (The backport I've only just posted is not enough for the tests to pass; > there's another problem) > > r14-10824 is a backport of r15-4549, that rewrote and extended into > check-function-bodies the save/restore expectations introduced in

Re: [PATCH] [testsuite] tolerate missing std::stold

2025-05-20 Thread Jonathan Wakely
On Tue, 20 May 2025, 05:00 Alexandre Oliva, wrote: > > basic_string.h doesn't define the non-w string version of std::stold > when certain conditions aren't met, and then a couple of tests fail to > compile. > > Guard the portions of the tests that depend on std::stold with the > conditions for i

Re: [PATCH] [testsuite] add missing require vect_early_break_hw for vect-tsvc

2025-05-19 Thread Uros Bizjak
LGTM for the whole series. Thanks, Uros. On Tue, May 20, 2025 at 6:17 AM Alexandre Oliva wrote: > > > Some tsvc tests add vect_early_break options without requiring the > feature to be available. Add the requirements. > > Regstrapped on x86_64-linux-gnu. Also tested with gcc-14 on aarch64-, >

[PATCH] [testsuite] [x86] memcpy-6 needs -msse2

2025-05-19 Thread Alexandre Oliva
The 8-byte memory operations will only be inlined on ia32 with -msse2. Bump it. Regstrapped on x86_64-linux-gnu. Also tested with gcc-14 on aarch64-, arm-, x86-, and x86_64-vxworks7r2. Ok to install? for gcc/testsuite/ChangeLog * memcpy-6.c: Bump to -msse2. --- gcc/testsuite/gcc.

Re: [PATCH] [testsuite] add missing require vect_early_break_hw for vect-tsvc

2025-05-19 Thread Richard Biener
OK On Tue, May 20, 2025 at 6:20 AM Alexandre Oliva wrote: > > > Some tsvc tests add vect_early_break options without requiring the > feature to be available. Add the requirements. > > Regstrapped on x86_64-linux-gnu. Also tested with gcc-14 on aarch64-, > arm-, x86-, and x86_64-vxworks7r2. Ok

[PATCH] [testsuite] add missing require vect_early_break_hw for vect-tsvc

2025-05-19 Thread Alexandre Oliva
Some tsvc tests add vect_early_break options without requiring the feature to be available. Add the requirements. Regstrapped on x86_64-linux-gnu. Also tested with gcc-14 on aarch64-, arm-, x86-, and x86_64-vxworks7r2. Ok to install? for gcc/testsuite/ChangeLog * gcc.dg/vect/tsvc/

[PATCH] [testsuite] [x86] forwprop-41 needs -msse

2025-05-19 Thread Alexandre Oliva
The vector operations are only turned into BIT_INSERT_EXPR with -msse on ia32. Regstrapped on x86_64-linux-gnu. Also tested with gcc-14 on aarch64-, arm-, x86-, and x86_64-vxworks7r2. Ok to install? for gcc/testsuite/ChangeLog * gcc.dg/tree-ssa/forwprop-41.c: Add -msse on x86. ---

[PATCH] [testsuite] [x86] vect-simd-clone-1[678]e.c adjust

2025-05-19 Thread Alexandre Oliva
Since r13-6296, we haven't got 4 simdclone calls for these tests on ia32 without avx_runtime. With avx_runtime, we get 3 such calls even on ia32, but we didn't test for anything on ia32 with avx_runtime. Adjust and simplify the expectations and comments. Regstrapped on x86_64-linux-gnu. Also t

[PATCH] [testsuite] [x86] no-callee-saved-16.c needs -fomit-frame-pointer

2025-05-19 Thread Alexandre Oliva
If the toolchain is built with --enable-frame-pointer, gcc.target/i386/no-callee-saved-16.c will not get the expected optimization without -fomit-frame-pointer, that would be enabled by -O2 without the configure flag. Add it. Regstrapped on x86_64-linux-gnu. Also tested with gcc-14 on aarch64-

[PATCH] [testsuite] [arm] adjust fp16-aapcs for gcc-14

2025-05-19 Thread Alexandre Oliva
(The backport I've only just posted is not enough for the tests to pass; there's another problem) r14-10824 is a backport of r15-4549, that rewrote and extended into check-function-bodies the save/restore expectations introduced in r15-2160. Alas, r15-2160 mentions an insn_propagation patch tha

[PATCH] [testsuite] [x86] pr31985.c needs -fomit-frame-pointer to match movl count

2025-05-19 Thread Alexandre Oliva
On an --enable-frame-pointer toolchain, pr31985.c gets an extra movl and fails. Enable -fomit-frame-pointer explicitly. Regstrapped on x86_64-linux-gnu. Also tested with gcc-14 on aarch64-, arm-, x86-, and x86_64-vxworks7r2. Ok to install? for gcc/testsuite/ChangeLog * gcc.target/

[PATCH] [testsuite] [x86] pr108938-3.c needs -msse2 for bswap in foo2 with -m32

2025-05-19 Thread Alexandre Oliva
Without SSE2, we don't combine the separate loads in foo2 and get separate rotates, instead of a bswap. Regstrapped on x86_64-linux-gnu. Also tested with gcc-14 on aarch64-, arm-, x86-, and x86_64-vxworks7r2. Ok to install? for gcc/testsuite/ChangeLog * gcc.target/i386/pr108938-3.c

[PATCH] [testsuite] [x86] strlenopt-80 needs -msse2 on ia32

2025-05-19 Thread Alexandre Oliva
The string length optimizations at 8-byte blocks requires -msse2; -msse is not enough. Bump it. Regstrapped on x86_64-linux-gnu. Also tested with gcc-14 on aarch64-, arm-, x86-, and x86_64-vxworks7r2. Ok to install? for gcc/testsuite/ChangeLog * gcc.dg/strlenopt-80.c: Bump to -mss

[PATCH] [testsuite] [x86] double copysign requires -msse2

2025-05-19 Thread Alexandre Oliva
SSE_FLOAT_MODE_P only holds for DFmode with SSE2, and that's a condition for copysign3 to be available under TARGET_SSE_MATH. Various copysign testcases use -msse -mfpmath=sse on ia32 to enable the copysign builtins and patterns, but that would only be enough if the tests were limited to floats.

Re: [PATCH] [testsuite] [ppc] add -mpowerpc-gfxopt or -mcmpb to copysign tests

2025-05-19 Thread Alexandre Oliva
On May 8, 2025, Alexandre Oliva wrote: > * gcc.dg/fold-copysign-1.c: Add -mcmpb on ppc. Uhh, sorry, I've accidentally dropped this bit from the patch posted a couple of weeks ago. Here it is. BTW, Ping? https://gcc.gnu.org/pipermail/gcc-patches/2025-May/683066.html diff --git a/gcc/te

[PATCH] [testsuite] require sysconf for vect-early-break_109-pr113588.c

2025-05-19 Thread Alexandre Oliva
The test calls sysconf but it doesn't require it as it should. Regstrapped on x86_64-linux-gnu. Also tested with gcc-14 on aarch64-, arm-, x86-, and x86_64-vxworks7r2. Ok to install? for gcc/testsuite/ChangeLog * gcc.dg/vect/vect-early-break_109-pr113588.c: Require sysconf. --- ..

[PATCH] [testsuite] [aarch64] match alt cache clear names in sme nonlocal_goto tests

2025-05-19 Thread Alexandre Oliva
vxworks calls cacheTextUpdate instead of __clear_cache. Adjust the sme/nonlocal_goto_*.c tests for inexact matches. Regstrapped on x86_64-linux-gnu. Also tested with gcc-14 on aarch64-, arm-, x86-, and x86_64-vxworks7r2. Ok to install? for gcc/testsuite/ChangeLog * gcc.target/aarc

[PATCH] [testsuite] [aarch64] use uint64_t in rwsr tests

2025-05-19 Thread Alexandre Oliva
stdint.h defines uint64_t instead of __uint64_t, so use the former. __uint64_t is not available on e.g. vxworks. Regstrapped on x86_64-linux-gnu. Also tested with gcc-14 on aarch64-, arm-, x86-, and x86_64-vxworks7r2. Ok to install? for gcc/testsuite/ChangeLog * gcc.target/aarch64/

[PATCH] [testsuite] tolerate missing std::stold

2025-05-19 Thread Alexandre Oliva
basic_string.h doesn't define the non-w string version of std::stold when certain conditions aren't met, and then a couple of tests fail to compile. Guard the portions of the tests that depend on std::stold with the conditions for it to be defined. Regstrapped on x86_64-linux-gnu. Also tested

[PATCH] [testsuite] [arm] require fpic for pr115485

2025-05-19 Thread Alexandre Oliva
The pr115485.C testcase uses -fPIE, so it needs to state a PIC requirement. Regstrapped on x86_64-linux-gnu. Also tested with gcc-14 on aarch64-, arm-, x86-, and x86_64-vxworks7r2. Ok to install? for gcc/testsuite/ChangeLog * g++.target/arm/pr115485.C: Require a pic effective targe

[PATCH] [testsuite] [arm] add -mno-long-calls

2025-05-19 Thread Alexandre Oliva
Various arm tests, specifically epilog-1.c and fp16-aapcs-*.c, need -mno-long-calls to match the expected asm outputs on targets that default to -mlong-calls. fp16-aapcs-2.c has that flag already. Regstrapped on x86_64-linux-gnu. Also tested with gcc-14 on aarch64-, arm-, x86-, and x86_64-vxwo

[PATCH] [testsuite] [vxworks] tolerate missing __atomic_feraiseexcept

2025-05-19 Thread Alexandre Oliva
vxworks' libatomic comes from its libc, and it's missing __atomic_feraiseexcept. ARM and AArch64 ports call it implicitly in c11-atomic-exec-[23].c, so these tests fail. No exceptions are expected to be raised by these tests, so I'm working around and silencing the failures by defining the miss

Re: [PATCH] [testsuite] [vxworks] netinet includes atomic, reqs c++11

2025-05-12 Thread David Malcolm
On Thu, 2025-05-08 at 23:29 -0300, Alexandre Oliva wrote: > > On vxworks, the included netinet/in.h header indirectly includes > , that fails on C++ <11.  Skip the test. > > Tested with gcc-14 targeting ppc-vx7r2 and ppc64-vx7r2.  Also tested > with trunk on ppc64le-linux-gnu, and with gcc-14 tar

Re: [PATCH] [testsuite] [analyzer] [vxworks] define __STDC_WANT_LIB_EXT1__ to 1

2025-05-12 Thread David Malcolm
On Thu, 2025-05-08 at 23:31 -0300, Alexandre Oliva wrote: > > vxworks' headers use #if instead of #ifdef to test for > __STDC_WANT_LIB_EXT1__, so the definition in the analyzer test > strotok-cppreference.c catches a bug there, but not something it's > meant to catch or that we could fix in GCC, s

Re: [PATCH] testsuite: arm: Fix unsigned-extend-2.c [PR116445]

2025-05-12 Thread Richard Earnshaw (lists)
On 11/04/2025 17:36, Christophe Lyon wrote: > The test was designed to pass with thumb2, but code generation changed > with the introduction of Low Overhead Loops, so the test can fail if > one overrides the flags when running the testsuite. > > In addition, useless subtract / extension instructio

[PATCH] testsuite/120222 - adjust gcc.dg/tree-ssa/gen-vect-28.c for inlining change

2025-05-12 Thread Richard Biener
We now inline main_1, confusing the expected number of vectorizations. Pushed. PR testsuite/120222 * gcc.dg/tree-ssa/gen-vect-28.c: Use noipa on main_1. --- gcc/testsuite/gcc.dg/tree-ssa/gen-vect-28.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gcc/tests

[PATCH] testsuite: Fix pr119131-1.c for targets which emit a psabi warning for vectors of DFP [PR119909]

2025-05-10 Thread Andrew Pinski
On PowerPC, there is a psabi warning for argument passing of a DFP vector. We are not expecting this warning and we get a failure due to it. Adding -Wno-psabi fixes the testcase. Committed as obvious after a quick test. gcc/testsuite/ChangeLog: PR testsuite/119909 * gcc.dg/tortur

Re: [PATCH] [testsuite] [ppc] pr87600, pr89313: test for __PPC__ as well

2025-05-09 Thread Alexandre Oliva
On Apr 16, 2025, Alexandre Oliva wrote: > On Apr 14, 2025, Peter Bergner wrote: >> On 4/11/25 1:03 PM, Alexandre Oliva wrote: >>> gcc.dg/pr87600.h and gcc.dg/pr89313.c test for __powerpc__ and >>> __POWERPC__ to choose ppc register names, but ppc-elf defines neither; >>> it defines __PPC__, so t

Re: [PATCH] [testsuite] [ppc] block-cmp-8 should require powerpc64

2025-05-09 Thread Alexandre Oliva
On Apr 11, 2025, Alexandre Oliva wrote: > * gcc.target/powerpc/block-cmp-8.c: Require powerpc64 > instruction execution support. > --- a/gcc/testsuite/gcc.target/powerpc/block-cmp-8.c > +++ b/gcc/testsuite/gcc.target/powerpc/block-cmp-8.c > -/* { dg-require-effective-target has_arch_p

[PATCH] [testsuite] [ppc] pr110071 requires power6 for shrink-wrapping

2025-05-08 Thread Alexandre Oliva
The test's expectation of shrink-wrapping is only met starting at power6. At earlier CPUs, the register allocator prefers to preserve an incoming argument around a call in a call-saved register, rather than in a stack slot, and that prevents shrink-wrapping. Tested with gcc-14 targeting ppc-vx7

[PATCH] [testsuite] [ppc] adjust vsx-builtin-7.c xxpermdi/rldic counts

2025-05-08 Thread Alexandre Oliva
xxpermdi (and rldic) instruction counts are slightly lower than expected, because icf turns insert_di_0_v2 into a insert_di_0 tail call. Adjust. Tested with gcc-14 targeting ppc-vx7r2 and ppc64-vx7r2. Also tested with trunk on ppc64le-linux-gnu, and with gcc-14 targeting powerpc-elf. Ok to ins

[PATCH] [testsuite] [ppc] add -mpowerpc-gfxopt or -mcmpb to copysign tests

2025-05-08 Thread Alexandre Oliva
When it comes to ifn_copysign on ppc, for SFmode and DFmode, the conditions are quite elaborate. It takes hard_float in addition to any of -mcmpb, vsx vectors for the mode, or -mpowerpc-gfxopt with fast-math (-ffinith-math-only and -fno-signed-zeros). A number of ifn_copysign tests add custom o

Re: [PATCH] [testsuite] [ppc] require float128 available for copysign

2025-05-08 Thread Alexandre Oliva
On Apr 11, 2025, Alexandre Oliva wrote: > for gcc/testsuite/ChangeLog > * lib/target-supports.exp (check_effective_target_ifn_copysign): > Require float128 on ppc. I hereby withdraw this patch, it was based on a misunderstanding. -- Alexandre Oliva, happy hackerhttps:

[PATCH] [testsuite] [vxworks] skip macros from implicitly-included vxConfig.h

2025-05-08 Thread Alexandre Oliva
On vxworks, vxConfig.h is implicitly included, and it defines multiple macros in the namespace reserved for the implementation. g++.dg/modules/macro-5_a.H tests that macros from the command-line do not make the module output, but it can't tell them from macros from implicitly-included headers, s

[PATCH] [testsuite] [ppc] expect vectorization in gen-vect-11c.c

2025-05-08 Thread Alexandre Oliva
The first loop in main gets stores "vectorized" on powerpc into full-word stores, even without any vector instruction support, so the test's expectation of no loop vectorization is not met. Tested with gcc-14 targeting ppc-vx7r2 and ppc64-vx7r2. Also tested with trunk on ppc64le-linux-gnu, and

[PATCH] [testsuite] [ppc] disable strict align for block-cmp-[14].c

2025-05-08 Thread Alexandre Oliva
The expected memcmp inline expansion assumes -mno-strict-align, so make it explicit in case strict-align is enabled by default. Tested with gcc-14 targeting ppc-vx7r2 and ppc64-vx7r2. Also tested with trunk on ppc64le-linux-gnu, and with gcc-14 targeting powerpc-elf. Ok to install? for gcc/t

[PATCH] [testsuite] [vxworks] add -gno-strict-dwarf to pr111409.c

2025-05-08 Thread Alexandre Oliva
The expected macro debug information is not issued with -gstrict-dwarf, and ports such as vxworks default to that. Allow non-strict dwarf for the test. Tested with gcc-14 targeting ppc-vx7r2 and ppc64-vx7r2. Also tested with trunk on ppc64le-linux-gnu, and with gcc-14 targeting powerpc-elf. Ok

[PATCH] [testsuite] [analyzer] [vxworks] define __STDC_WANT_LIB_EXT1__ to 1

2025-05-08 Thread Alexandre Oliva
vxworks' headers use #if instead of #ifdef to test for __STDC_WANT_LIB_EXT1__, so the definition in the analyzer test strotok-cppreference.c catches a bug there, but not something it's meant to catch or that we could fix in GCC, so amend the definition to sidestep the libc bug. Tested with gcc-1

[PATCH] [testsuite] [vxworks] netinet includes atomic, reqs c++11

2025-05-08 Thread Alexandre Oliva
On vxworks, the included netinet/in.h header indirectly includes , that fails on C++ <11. Skip the test. Tested with gcc-14 targeting ppc-vx7r2 and ppc64-vx7r2. Also tested with trunk on ppc64le-linux-gnu, and with gcc-14 targeting powerpc-elf. Ok to install? for gcc/testsuite/ChangeLog

Re: [PATCH] testsuite: g++.dg/cpp2a/decomp2.C requires tls_runtime

2025-05-08 Thread Jakub Jelinek
On Thu, May 08, 2025 at 03:07:29PM +0200, Christophe Lyon wrote: > Ping? > > Le jeu. 17 avr. 2025, 11:21, Christophe Lyon a > écrit : > > > Since this test is a 'dg-do run', it requires tls_runtime rather than > > just tls. > > > > This makes the test UNSUPPORTED on targets such as arm-non-eabi,

Re: [PATCH] testsuite: g++.dg/cpp2a/constinit16.C requires tls

2025-05-08 Thread Jakub Jelinek
On Thu, May 08, 2025 at 03:07:50PM +0200, Christophe Lyon wrote: > Ping? > > Le jeu. 17 avr. 2025, 11:21, Christophe Lyon a > écrit : > > > This test is 'dg-do compile', so require tls instead of tls_runtime. > > > > This enables it on targets such as arm-none-eabi configured with > > --enable-t

Re: [PATCH] testsuite: arm: Fix unsigned-extend-2.c [PR116445]

2025-05-08 Thread Christophe Lyon
Ping? Le ven. 11 avr. 2025, 18:36, Christophe Lyon a écrit : > The test was designed to pass with thumb2, but code generation changed > with the introduction of Low Overhead Loops, so the test can fail if > one overrides the flags when running the testsuite. > > In addition, useless subtract / e

Re: [PATCH] testsuite: g++.dg/cpp2a/decomp2.C requires tls_runtime

2025-05-08 Thread Christophe Lyon
Ping? Le jeu. 17 avr. 2025, 11:21, Christophe Lyon a écrit : > Since this test is a 'dg-do run', it requires tls_runtime rather than > just tls. > > This makes the test UNSUPPORTED on targets such as arm-non-eabi, > instead of FAIL/UNRESOLVED because __aeabi_read_tp is not provided > (e.g. when

Re: [PATCH] testsuite: g++.dg/cpp2a/constinit16.C requires tls

2025-05-08 Thread Christophe Lyon
Ping? Le jeu. 17 avr. 2025, 11:21, Christophe Lyon a écrit : > This test is 'dg-do compile', so require tls instead of tls_runtime. > > This enables it on targets such as arm-none-eabi configured with > --enable-threads=no. > > gcc/testsuite/ChangeLog: > > * g++.dg/cpp2a/constinit16.C: R

Re: [PATCH] testsuite: Skip pr119160 for RISC-V backend.

2025-05-08 Thread Richard Biener
On Thu, May 8, 2025 at 10:02 AM Jiawei wrote: > > RISC-V backend don't support '-mgeneral-regs-only' option, skip it. > https://godbolt.org/z/38M8vPW74 The test should instead use /* { dg-additional-options "-mgeneral-regs-only" { target { x86_64-*-* i?86-*-* } } } */ OK with that change. Rich

Re: [PATCH] testsuite: Skip pr119160 for RISC-V backend.

2025-05-08 Thread Konstantinos Eleftheriou
Hi, This should be restricted to arm/aarch64 and x86. So it should be: /* { dg-additional-options "-mgeneral-regs-only" { target { x86_64-*-* i?86-*-* aarch64*-*-* arm*-*-* } } } */ Konstantinos On Thu, May 8, 2025 at 11:36 AM jiawei wrote: > > > 在 2025/5/8 16:25, Richard Biener 写道: > > On Thu,

Re: [PATCH] testsuite: Limit option '-mgeneral-regs-only' backends in pr119160.

2025-05-08 Thread Richard Biener
On Thu, May 8, 2025 at 11:04 AM Jiawei wrote: > > Limit option '-mgeneral-regs-only' to those in supported backends. > > Version log: > https://patchwork.sourceware.org/project/gcc/patch/20250508080102.1340059-1-jia...@iscas.ac.cn/ OK. > gcc/testsuite/ChangeLog: > > * gcc.dg/pr11

[PATCH] testsuite: Limit option '-mgeneral-regs-only' backends in pr119160.

2025-05-08 Thread Jiawei
Limit option '-mgeneral-regs-only' to those in supported backends. Version log: https://patchwork.sourceware.org/project/gcc/patch/20250508080102.1340059-1-jia...@iscas.ac.cn/ gcc/testsuite/ChangeLog: * gcc.dg/pr119160.c: Limit backends. --- gcc/testsuite/gcc.dg/pr119160.c | 3

Re: [PATCH] testsuite: Skip pr119160 for RISC-V backend.

2025-05-08 Thread jiawei
在 2025/5/8 16:25, Richard Biener 写道: On Thu, May 8, 2025 at 10:02 AM Jiawei wrote: RISC-V backend don't support '-mgeneral-regs-only' option, skip it. https://godbolt.org/z/38M8vPW74 The test should instead use /* { dg-additional-options "-mgeneral-regs-only" { target { x86_64-*-* i?86-*-*

Re: [PATCH] testsuite: Skip pr119160 for RISC-V backend.

2025-05-08 Thread Philipp Tomsich
+Konstantinos Eleftheriou On Thu, 8 May 2025 at 10:30, Andreas Schwab wrote: > > On Mai 08 2025, Richard Biener wrote: > > > On Thu, May 8, 2025 at 10:02 AM Jiawei wrote: > >> > >> RISC-V backend don't support '-mgeneral-regs-only' option, skip it. > >> https://godbolt.org/z/38M8vPW74 > > > > T

Re: [PATCH] testsuite: Skip pr119160 for RISC-V backend.

2025-05-08 Thread Andreas Schwab
On Mai 08 2025, Richard Biener wrote: > On Thu, May 8, 2025 at 10:02 AM Jiawei wrote: >> >> RISC-V backend don't support '-mgeneral-regs-only' option, skip it. >> https://godbolt.org/z/38M8vPW74 > > The test should instead use > > /* { dg-additional-options "-mgeneral-regs-only" { target { x86_64

Re: [PATCH] testsuite: Skip pr119160 for RISC-V backend.

2025-05-08 Thread Andreas Schwab
On Mai 08 2025, Jiawei wrote: > RISC-V backend don't support '-mgeneral-regs-only' option, skip it. Almost all backends do not support it. It should be used only on those few that do. -- Andreas Schwab, SUSE Labs, sch...@suse.de GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE 1748 E4D4 88E3 0E

[PATCH] testsuite: Skip pr119160 for RISC-V backend.

2025-05-08 Thread Jiawei
RISC-V backend don't support '-mgeneral-regs-only' option, skip it. https://godbolt.org/z/38M8vPW74 gcc/testsuite/ChangeLog: * gcc.dg/pr119160.c: Skip for RISC-V backend. --- gcc/testsuite/gcc.dg/pr119160.c | 1 + 1 file changed, 1 insertion(+) diff --git a/gcc/testsuite/gcc.dg

[PATCH] testsuite/120084 - adjust gcc.dg/lto/pr60779_0.c

2025-05-05 Thread Richard Biener
Require the linker plugin so functions are properly detected as unused when inlined. Pushed. PR testsuite/120084 * gcc.dg/lto/pr60779_0.c: Require linker-plugin. --- gcc/testsuite/gcc.dg/lto/pr60779_0.c | 1 + 1 file changed, 1 insertion(+) diff --git a/gcc/testsuite/gcc.dg/lto/

Re: [PATCH] testsuite: Skip tests incompatible with generic thunk support

2025-04-25 Thread Dimitar Dimitrov
On Thu, Apr 24, 2025 at 11:56:52PM +0200, Bernhard Reutner-Fischer wrote: > > >>* lib/target-supports.exp > >>(check_effective_target_variadic_mi_thunk): New function. > >OK. > >jeff > > > > Please document new effective_target checks in sourcebuild.texi > > thanks Pushed with added doc

Re: [PATCH] testsuite: Add require target for SJLJ exception implementation

2025-04-24 Thread Jeff Law
On 4/24/25 12:22 PM, Dimitar Dimitrov wrote: Testcases for musttail call optimization fail on pru-unknown-elf: FAIL: c-c++-common/musttail14.c -std=gnu++17 (test for excess errors) Excess errors: .../gcc/gcc/testsuite/c-c++-common/musttail14.c:37:14: error: cannot tail-call: caller

Re: [PATCH] testsuite: Skip tests incompatible with generic thunk support

2025-04-24 Thread Bernhard Reutner-Fischer
>> * lib/target-supports.exp >> (check_effective_target_variadic_mi_thunk): New function. >OK. >jeff > Please document new effective_target checks in sourcebuild.texi thanks

Re: [PATCH] testsuite: Skip tests incompatible with generic thunk support

2025-04-24 Thread Jeff Law
On 4/24/25 12:23 PM, Dimitar Dimitrov wrote: Some backends do not define TARGET_ASM_OUTPUT_MI_THUNK. But the generic thunk support cannot emit code for calling variadic methods of multiple-inheritance classes. Example error for pru-unknown-elf: .../gcc/gcc/testsuite/g++.dg/ipa/pr83549.C:7

[PATCH] testsuite: Skip tests incompatible with generic thunk support

2025-04-24 Thread Dimitar Dimitrov
Some backends do not define TARGET_ASM_OUTPUT_MI_THUNK. But the generic thunk support cannot emit code for calling variadic methods of multiple-inheritance classes. Example error for pru-unknown-elf: .../gcc/gcc/testsuite/g++.dg/ipa/pr83549.C:7:24: error: generic thunk code fails for method 'v

[PATCH] testsuite: Add require target for SJLJ exception implementation

2025-04-24 Thread Dimitar Dimitrov
Testcases for musttail call optimization fail on pru-unknown-elf: FAIL: c-c++-common/musttail14.c -std=gnu++17 (test for excess errors) Excess errors: .../gcc/gcc/testsuite/c-c++-common/musttail14.c:37:14: error: cannot tail-call: caller uses sjlj exceptions Silence these errors by disabli

Re: [PATCH] testsuite: AMDGCN test for vect-early-break_38.c as well to consistent architecture [PR119286]

2025-04-23 Thread Richard Biener
On Wed, 23 Apr 2025, Tamar Christina wrote: > Hi All, > > I had missed this one during the AMDGCN test failures. > > Like vect-early-break_18.c this test is also scalaring the > loads and thus leading to unexpected vectorization for this > testcase. > > Bootstrapped Regtested on aarch64-none-li

[PATCH] testsuite: AMDGCN test for vect-early-break_38.c as well to consistent architecture [PR119286]

2025-04-22 Thread Tamar Christina
Hi All, I had missed this one during the AMDGCN test failures. Like vect-early-break_18.c this test is also scalaring the loads and thus leading to unexpected vectorization for this testcase. Bootstrapped Regtested on aarch64-none-linux-gnu and no issues. Cross checked the failing case on amdgc

Re: [PATCH] testsuite: Use sigsetjmp in gcc.misc-tests/gcov-31.c

2025-04-22 Thread Jørgen Kvalsvik
Hi, Thanks for fixing this. I just checked glibc, which implements __sigsetjmp as: # define sigsetjmp(env, savemask) __sigsetjmp (env, savemask) So I would think this is fine. I leave the ack to the Jakub, Richard et al, of course. Thanks, Jørgen On 2025-04-22 10:33, Rainer Orth wrote: T

  1   2   3   4   5   6   7   8   9   10   >