[Bug 278089] Crash with clang++ 16 building stockfish-official
Date: Mon, 01 Apr 2024 07:15:36 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=278089 Bug ID: 278089 Summary: Crash with clang++ 16 building stockfish-official Product: Base System Version: 14.0-RELEASE Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: bin Assignee: bugs@FreeBSD.org Reporter: pjfloyd@wanadoo.fr I wanted to try to reproduce a Valgrind issue https://bugs.kde.org/show_bug.cgi?id=484742 The steps that I took were git clone https://github.com/official-stockfish/Stockfish.git cd Stockfish/ cd src gmake profile-build ARCH=armv8-dotprod MAKE=gmake CC=clang CXX=clang++ -j 4 Here is the terminal output clang++ -Wall -Wcast-qual -fno-exceptions -std=c++17 -fprofile-instr-use=stockfish.profdata -pedantic -Wextra -Wshadow -Wmissing-declarations -DUSE_PTHREADS -DNDEBUG -O3 -funroll-loops -DIS_64BIT -DUSE_POPCNT -DUSE_NEON=8 -march=armv8.2-a+dotprod -DUSE_NEON_DOTPROD -DGIT_SHA=c964942d -DGIT_DATE=20240330 -DARCH=armv8-dotprod -flto=full -c -o main.o main.cpp Expected<T> must be checked before access or destruction. Expected<T> value was in success state. (Note: Expected<T> values in success mode must still be checked prior to being destroyed). PLEASE submit a bug report to https://bugs.freebsd.org/submit/ and include the crash backtrace, preprocessed source, and associated run script. Stack dump: 0. Program arguments: clang++ -Wall -Wcast-qual -fno-exceptions -std=c++17 -fprofile-instr-use=stockfish.profdata -pedantic -Wextra -Wshadow -Wmissing-declarations -DUSE_PTHREADS -DNDEBUG -O3 -fExpected<T> must be checked before access or destruction. unroll-loops -DIS_64BIT -DUSE_POPCNT -DUSE_NEON=8 -march=armv8.2-a+dotprod -DUSE_NEON_DOTPROD -DGIT_SHA=c964942d -DGIT_DATE=20240330 -DARCH=armv8-dotprod -flto=full -c -o benchmark.o benchmark.cpp Expected<T> value was in success state. (Note: Expected<T> values in success mode must still be checked prior to being destroyed). PLEASE submit a bug report to https://bugs.freebsd.org/submit/ and include the crash backtrace, preprocessed source, and associated run script. Stack dump: 0. Program arguments: clang++ -Wall -Wcast-qual -fno-exceptions -std=c++17 -fprofile-instr-use=stockfish.profdata -pedantic -Wextra -Wshadow -Wmissing-declarations -DUSE_PTHREADS -DNDEBUG -O3 -funroll-loops -DIS_64BIT -DUSE_POPCNT -DUSE_NEON=8 -march=armv8.2-a+dotprod -DUSE_NEON_DOTPROD -DGIT_SHA=c964942d -DGIT_DATE=20240330 -DARCH=armv8-dotprod -flto=full -c -o bitboard.o bitboard.cpp Expected<T> must be checked before access or destruction. Expected<T> value was in success state. (Note: Expected<T> values in success mode must still be checked prior to being destroyed). PLEASE submit a bug report to https://bugs.freebsd.org/submit/ and include the crash backtrace, preprocessed source, and associated run script. Stack dump: 0. Program arguments: clang++ -Wall -Wcast-qual -fno-exceptions -std=c++17 -fprofile-instr-use=stockfish.profdata -pedantic -Wextra -Wshadow -Wmissing-declarations -DUSE_PTHREADS -DNDEBUG -O3 -funroll-loops -DIS_64BIT -DUSE_POPCNT -DUSE_NEON=8 -march=armv8.2-a+dotprod -DUSE_NEON_DOTPROD -DGIT_SHA=c964942d -DGIT_DATE=20240330 -DARCH=armv8-dotprod -flto=full -c -o evaluate.o evaluate.cpp Expected<T> must be checked before access or destruction. Expected<T> value was in success state. (Note: Expected<T> values in success mode must still be checked prior to being destroyed). PLEASE submit a bug report to https://bugs.freebsd.org/submit/ and include the crash backtrace, preprocessed source, and associated run script. Stack dump: 0. Program arguments: clang++ -Wall -Wcast-qual -fno-exceptions -std=c++17 -fprofile-instr-use=stockfish.profdata -pedantic -Wextra -Wshadow -Wmissing-declarations -DUSE_PTHREADS -DNDEBUG -O3 -funroll-loops -DIS_64BIT -DUSE_POPCNT -DUSE_NEON=8 -march=armv8.2-a+dotprod -DUSE_NEON_DOTPROD -DGIT_SHA=c964942d -DGIT_DATE=20240330 -DARCH=armv8-dotprod -flto=full -c -o main.o main.cpp #0 #0 #0#00x0000000004a3a0e80x0000000004a3a0e8 0x0000000004a3a0e8PrintStackTrace PrintStackTrace/usr/src/contrib/llvm-project/llvm/lib/Support/Unix/Signals.inc:567:13 PrintStackTrace /usr/src/contrib/llvm-project/llvm/lib/Support/Unix/Signals.inc:567:13#1 /usr/src/contrib/llvm-project/llvm/lib/Support/Unix/Signals.inc:567:13#1 0x0000000004a384c4 #1__cxx_atomic_store<CallbackAndCookie::Status> 0x0000000004a3a0e8 /usr/obj/usr/src/arm64.aarch64/tmp/usr/include/c++/v1/atomic:950:50x0000000004a384c4 __cxx_atomic_store<CallbackAndCookie::Status> /usr/obj/usr/src/arm64.aarch64/tmp/usr/include/c++/v1/atomic:950:5 #20x0000000004a384c4 0x0000000004a384c4__cxx_atomic_store<CallbackAndCookie::Status> store/usr/obj/usr/src/arm64.aarch64/tmp/usr/include/c++/v1/atomic:950:5 /usr/obj/usr/src/arm64.aarch64/tmp/usr/include/c++/v1/atomic:1543:10#2#2 0x0000000004a384c40x0000000004a384c4 storestore /usr/obj/usr/src/arm64.aarch64/tmp/usr/include/c++/v1/atomic:1543:10/usr/obj/usr/src/arm64.aarch64/tmp/usr/include/c++/v1/atomic:1543:10 PrintStackTrace#3 /usr/src/contrib/llvm-project/llvm/lib/Support/Unix/Signals.inc:567:13 #1 0x0000000004a384c4#3 __cxx_atomic_store<CallbackAndCookie::Status>0x0000000004a384c4 /usr/obj/usr/src/arm64.aarch64/tmp/usr/include/c++/v1/atomic:950:5RunSignalHandlers /usr/src/contrib/llvm-project/llvm/lib/Support/Signals.cpp:106:16#2 #30x0000000004a384c4#4 RunSignalHandlers 0x00000000049e99f4 0x0000000004a384c4/usr/src/contrib/llvm-project/llvm/lib/Support/Signals.cpp:106:16 RunSignalHandlers /usr/src/contrib/llvm-project/llvm/lib/Support/Signals.cpp:106:16#4 0x00000000049e99f4 HandleCrash#40x0000000004a384c4 store0x00000000049e99f4HandleCrash HandleCrash/usr/obj/usr/src/arm64.aarch64/tmp/usr/include/c++/v1/atomic:1543:10 /usr/src/contrib/llvm-project/llvm/lib/Support/CrashRecoveryContext.cpp:73:5 #3 0x0000000004a384c4 /usr/src/contrib/llvm-project/llvm/lib/Support/CrashRecoveryContext.cpp:73:5 /usr/src/contrib/llvm-project/llvm/lib/Support/CrashRecoveryContext.cpp:73:5RunSignalHandlers#5 #5 #50x00000000049e99f4 0x00000000049e99f4CrashRecoverySignalHandler CrashRecoverySignalHandler/usr/src/contrib/llvm-project/llvm/lib/Support/CrashRecoveryContext.cpp:390:51 /usr/src/contrib/llvm-project/llvm/lib/Support/CrashRecoveryContext.cpp:390:51 #6 #60x000000008af85034 0x00000000049e99f40x000000008a3b0034 CrashRecoverySignalHandlerhandle_signal /usr/src/contrib/llvm-project/llvm/lib/Support/CrashRecoveryContext.cpp:390:51/usr/src/lib/libthr/thread/thr_sig.c:0:3 #6handle_signal 0x0000000089be3034/usr/src/lib/libthr/thread/thr_sig.c:0:3 handle_signal /usr/src/lib/libthr/thread/thr_sig.c:0:3 /usr/src/contrib/llvm-project/llvm/lib/Support/Signals.cpp:106:16 #4 0x00000000049e99f4 HandleCrash /usr/src/contrib/llvm-project/llvm/lib/Support/CrashRecoveryContext.cpp:73:5 #5 0x00000000049e99f4 CrashRecoverySignalHandler /usr/src/contrib/llvm-project/llvm/lib/Support/CrashRecoveryContext.cpp:390:51 #6 0x000000008aa0e034 handle_signal /usr/src/lib/libthr/thread/thr_sig.c:0:3 clang++clang++: clang++error: clang++: : error: error: clang frontend command failed with exit code 134 (use -v to see invocation)clang frontend command failed with exit code 134 (use -v to see invocation) : error: clang frontend command failed with exit code 134 (use -v to see invocation) FreeBSD clang version 16.0.6 (https://github.com/llvm/llvm-project.git llvmorg-16.0.6-0-g7cbf1a259152)FreeBSD clang version 16.0.6 (https://github.com/llvm/llvm-project.git llvmorg-16.0.6-0-g7cbf1a259152) FreeBSD clang version 16.0.6 (https://github.com/llvm/llvm-project.git llvmorg-16.0.6-0-g7cbf1a259152)Target: aarch64-unknown-freebsd14.0clang frontend command failed with exit code 134 (use -v to see invocation) Target: Thread model: posix aarch64-unknown-freebsd14.0Target: aarch64-unknown-freebsd14.0 Thread model: posix InstalledDir: /usr/binInstalledDir: FreeBSD clang version 16.0.6 (https://github.com/llvm/llvm-project.git llvmorg-16.0.6-0-g7cbf1a259152) Target: /usr/binThread model: aarch64-unknown-freebsd14.0 posix Thread model: posix InstalledDir: /usr/bin InstalledDir: /usr/bin clang++: note: diagnostic msg: ******************** PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT: Preprocessed source(s) and associated run script(s) are located at: clang++: note: diagnostic msg: /tmp/bitboard-8d5a24.cpp clang++: note: diagnostic msg: /tmp/bitboard-8d5a24.sh clang++: note: diagnostic msg: ******************** gmake[2]: *** [<builtin>: bitboard.o] Error 1 gmake[2]: *** Waiting for unfinished jobs.... clang++: note: diagnostic msg: ******************** PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT: Preprocessed source(s) and associated run script(s) are located at: clang++: note: diagnostic msg: /tmp/benchmark-d729e3.cpp clang++: note: diagnostic msg: /tmp/benchmark-d729e3.sh clang++: note: diagnostic msg: ******************** gmake[2]: *** [<builtin>: benchmark.o] Error 1 clang++: note: diagnostic msg: ******************** PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT: Preprocessed source(s) and associated run script(s) are located at: clang++: note: diagnostic msg: /tmp/main-ba395b.cpp clang++: note: diagnostic msg: /tmp/main-ba395b.sh clang++: note: diagnostic msg: ******************** clang++: note: diagnostic msg: ******************** PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT: Preprocessed source(s) and associated run script(s) are located at: clang++: note: diagnostic msg: /tmp/evaluate-d100a2.cpp clang++: note: diagnostic msg: /tmp/evaluate-d100a2.sh clang++: note: diagnostic msg: ******************** gmake[2]: *** [<builtin>: main.o] Error 1 gmake[2]: *** [<builtin>: evaluate.o] Error 1 gmake[2]: Leaving directory '/home/paulf/scratch/Stockfish/src' gmake[1]: *** [Makefile:1065: clang-profile-use] Error 2 gmake[1]: Leaving directory '/home/paulf/scratch/Stockfish/src' gmake: *** [Makefile:894: profile-build] Error 2 -- You are receiving this mail because: You are the assignee for the bug.