https://gcc.gnu.org/g:0c93e3522a9728207c9c90a4053890686a0f24cb
commit r17-2495-g0c93e3522a9728207c9c90a4053890686a0f24cb Author: Jeff Law <[email protected]> Date: Fri Jul 17 07:14:13 2026 -0600 Fix signed char test assumption [Was Re: [Linaro-TCWG-CI] gcc-17-2261-g649b2a6d9f9f: 7 regressions on arm] > Dear contributor, > > Our automatic CI has detected problems related to your patch(es). Please find some details below. > > In armv8l-unknown-linux-gnueabihf native, after: > | commit gcc-17-2261-g649b2a6d9f9f > | Author: Jeff Law <[email protected]> > | Date: Wed Jul 8 12:30:56 2026 -0600 > | > | [PR rtl-optimization/126136] Fix dest = cond ? x : -1 when STORE_FLAG_VALUE is -1 > | > | So a while back I added support for selecting x/-1 into the ifcvt.cc by using > | scc and a couple ALU operations. That code explicitly rejects STORE_FLAG_VALUE > | if it is not 1 or -1. > | ... 20 lines of the commit log omitted. > > Produces 7 regressions: > | > | regressions.sum: > | Running gcc:gcc.dg/torture/dg-torture.exp ... > | FAIL: gcc.dg/torture/pr126136.c -O0 execution test > | FAIL: gcc.dg/torture/pr126136.c -O1 execution test > | FAIL: gcc.dg/torture/pr126136.c -O2 execution test > | FAIL: gcc.dg/torture/pr126136.c -O2 -flto -fno-use-linker-plugin -flto-partition=none execution test > | ... and 3 more > > Used configuration : > *CI config* tcwg_gcc_check armv8l-unknown-linux-gnueabihf > *configure and test flags:* none, autodetected on armv8l-unknown-linux-gnueabihf--disable-multilib --with-float=hard --with-mode=thumb --with-tune=cortex-a9 --with-arch=armv7-a --with-fpu=neon-fp-armv8 > > We track this bug report under https://linaro.atlassian.net/browse/GNU-1959. (Require Linaro login) Please let us know if you have a fix. As others noted, this is a case where the test assumed signed chars. The patch makes the signedness explicit. Bootstrapped and regression tested on armv7 and verified the test now passes on that platform. Pushing to the trunk. gcc/testsuite * gcc.dg/torture/pr126136.c: Make chars explicitly signed. Diff: --- gcc/testsuite/gcc.dg/torture/pr126136.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/testsuite/gcc.dg/torture/pr126136.c b/gcc/testsuite/gcc.dg/torture/pr126136.c index cc270f51ca2d..0ab01a45d49b 100644 --- a/gcc/testsuite/gcc.dg/torture/pr126136.c +++ b/gcc/testsuite/gcc.dg/torture/pr126136.c @@ -3,7 +3,7 @@ int i; __attribute__ ((noipa,noclone,noinline)) -char foo(char val) +signed char foo(signed char val) { i++; if (i > 1)
