https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118538
--- Comment #7 from Disservin <disservin.social at gmail dot com> --- (In reply to Andrew Pinski from comment #6) > Note on the trunk I get: > [apinski@xeond2 upstream-cross-aarch64]$ > QEMU_LD_PREFIX=./install/aarch64-linux-gnu/sysroot/ > ./install-qemu/bin/qemu-aarch64 a.out > terminate called after throwing an instance of 'int' > qemu: uncaught target signal 6 (Aborted) - core dumped > Aborted (core dumped) > > Which is correct. > > > Are you sure you are not getting a message like: > terminate called after throwing an instance of 'int' Yes I am sure. See g++ vs clang++ g++-14 -O0 -std=c++17 -Wall -Wextra -Wpedantic -Wuninitialized -fno-strict-aliasing -fwrapv -g3 test.cpp && ./a.out test.cpp: In function ‘int main()’: test.cpp:55:10: warning: variable ‘reader’ set but not used [-Wunused-but-set-variable] 55 | auto reader = Reader("file", 1); | ^~~~~~ [1] 505165 segmentation fault (core dumped) ./a.out clang++ -O0 -std=c++17 -Wall -Wextra -Wpedantic -Wuninitialized -fno-strict-aliasing -fwrapv -g3 test.cpp && ./a.out test.cpp:51:9: warning: private field 'l_' is not used [-Wunused-private-field] 51 | int l_; | ^ 1 warning generated. terminate called after throwing an instance of 'int' [1] 505364 abort (core dumped) ./a.out I also have confirmation that this happens for someone else too with my reproduction attachment on another pi5, see See https://github.com/Disservin/fastchess/issues/786#issuecomment-2599189683.