[Bug c/96165] New: internal compiler error during IPA pass: fnsummary
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96165 Bug ID: 96165 Summary: internal compiler error during IPA pass: fnsummary Product: gcc Version: 10.1.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: jpalus+gcc at fastmail dot com Target Milestone: --- Created attachment 48863 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=48863&action=edit preprocessed source file During Mesa compilation gcc segfaults with: during IPA pass: fnsummary ../src/gallium/drivers/softpipe/sp_tex_sample.c: In function ‘sample_compare’: ../src/gallium/drivers/softpipe/sp_tex_sample.c:3862:1: internal compiler error: Segmentation fault Confirmed on both aarch64 and x86_64, note that issue occurs only if -O flag was passed. Attached source file after preprocessor. Command to reproduce: gcc -O2 -c test.c -o test.o
[Bug target/104707] gcc on riscv64 isn't passing entire library path to the linker
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104707 --- Comment #3 from Jan Palus --- I doubt this has anything to do with riscv or multilib. It's just gcc that assumes all linkers should lookup /lib and /usr/lib and skips them when passing library paths to linker: https://gcc.gnu.org/git/?p=gcc.git;a=blob;f=gcc/gcc.cc;h=bb07cc244e30fbeccc701816db888f497d65eb08;hb=refs/heads/master#l7931 I had the same issue on arm (32-bit) so no riscv, no multilib and dropping this logic fixes the issue.
[Bug target/104707] gcc on riscv64 isn't passing entire library path to the linker
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104707 --- Comment #5 from Jan Palus --- > Arm linux multilib is just as complex as riscvs really. Perhaps my understanding of multilib is wrong but I meant pure 32bit, single arch environment.
[Bug c/121044] New: False positive -Warray-bounds iwith GCC 14 and NEON intrinsics
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=121044 Bug ID: 121044 Summary: False positive -Warray-bounds iwith GCC 14 and NEON intrinsics Product: gcc Version: 14.3.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: jpalus+gcc at fastmail dot com Target Milestone: --- Created attachment 61846 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=61846&action=edit reproducer Based on mbedtls build failure (upstream report https://github.com/Mbed-TLS/mbedtls/issues/9003) attached reproducer for false positive -Warray-bounds when targeting aarch64: $ gcc -O2 -Warray-bounds repro.c -c -o repro.o In function ‘xor’, inlined from ‘foo’ at repro.c:27:5: repro.c:19:17: warning: array subscript 48 is outside array bounds of ‘unsigned char[48]’ [-Warray-bounds=] 19 | r[i] = a[i] ^ b[i]; |~^~~ repro.c: In function ‘foo’: repro.c:25:19: note: at offset 48 into object ‘tmp’ of size 48 25 | unsigned char tmp[48] = { 0 }; | ^~~ In function ‘xor’, inlined from ‘foo’ at repro.c:27:5: repro.c:19:14: warning: array subscript 48 is outside array bounds of ‘unsigned char[48]’ [-Warray-bounds=] 19 | r[i] = a[i] ^ b[i]; | ~^ repro.c: In function ‘foo’: repro.c:25:19: note: at offset 48 into object ‘tmp’ of size 48 25 | unsigned char tmp[48] = { 0 }; | ^~~ Note that it appears to affect GCC 14.x only (13.x/15.x seem to work fine according to godbolt).
[Bug target/121044] [14 Regression] False positive -Warray-bounds iwith GCC 14 and NEON intrinsics
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=121044 --- Comment #2 from Jan Palus --- Some weird observations from reproducer minimazation: - memcpy() needs to be there otherwise it's not reproduced (although it's completely unrelated?) - memcpy() needs to copy into array which is struct's member. plain array does not trigger issue - struct with array member needs to be passed as function argument
[Bug target/121044] [14 Regression] False positive -Warray-bounds with GCC 14 and vectors
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=121044 --- Comment #8 from Jan Palus --- Bisect results: Regression between 13 and 14 started to appear with: a291237b628f419d7f7ac264dd7b42947b565222 is the first bad commit commit a291237b628f419d7f7ac264dd7b42947b565222 Author: Andrew MacLeod Date: Tue Oct 31 16:51:34 2023 Remove simple ranges from trailing zero bitmasks. Later fixed between 14 and 15 with: 74ee12ff68243bb177fb8653474dff80c3792139 is the first new commit commit 74ee12ff68243bb177fb8653474dff80c3792139 Author: Andrew MacLeod Date: Wed Jun 5 21:12:27 2024 Move array_bounds warnings into a separate pass.