https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101384

--- Comment #7 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
E.g. p8, on gcc112.fsffrance.org, vanilla gcc configured with
../configure --enable-languages=all,obj-c++,lto,go,d
--enable-checking=yes,rtl,extra
with the https://gcc.gnu.org/pipermail/gcc-patches/2021-July/575118.html
testsuite/gcc.dg/pr101384.c testcase:
./xgcc -B ./ -O2 -o pr101384{,.c}; ./pr101384; echo $?
Aborted
134
or
./xgcc -B ./ -O2 -mcpu=power8 -o pr101384{,.c}; ./pr101384; echo $?
Aborted
134
It works fine with the 4.8 system gcc:
gcc -o pr101384{,.c} -std=c99 -Dnoipa='noinline,noclone' -O2; ./pr101384; echo
$?
0
And with the patched compiler:
./xgcc -B ./ -O2 -o pr101384{,.c}; ./pr101384; echo $?
0
The broken compilers will not load the { 0x80, 0xff, 0xff, 0xff, 0x80, 0xff,
0xff, 0xff, 0x80, 0xff, 0xff, 0xff, 0x80, 0xff, 0xff, 0xff } vector (and the
other one too) from .rodata, but computes it using vspltisw reg,-1; vslb
reg,reg,reg but that constructs { 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80,
0x80,  0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80 } vector instead.

Reply via email to