https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103636
--- Comment #7 from hubicka at kam dot mff.cuni.cz --- I use cmake -G "Unix Makefiles" /home/jh/llvm-project/llvm -DCLANG_TABLEGEN=/home/jh/llvm-project/llvm/out/stage1/bin/clang-tblgen -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_COMPILER=/home/jh/trunk-install/bin/g++ -DCMAKE_C_COMPILER=/home/jh/trunk-install/bin/gcc -DLL VM_BINUTILS_INCDIR=/home/jh/binutils-install/include/ -DLLVM_BUILD_RUNTIME=No -DLLVM_ENABLE_PROJECTS="clang;compiler-rt;lld" -DLL VM_TABLEGEN=/home/jh/llvm-project/llvm/out/stage1/bin/llvm-tblgen -DLLVM_TARGETS_TO_BUILD=X86 -DCMAKE_C_FLAGS_RELEASE="-O2 -fno-s trict-aliasing -flifetime-dse=1 -flto=auto -fno-semantic-interposition -fprofile-generate -DNDEBUG" -DCMAKE_CXX_FLAGS_RELEASE="- O2 -flto=auto -fno-strict-aliasing -flifetime-dse=1 -fno-semantic-interposition -fprofile-generate -DNDEBUG" I already checked that with that hunk in can_inline_edge_p commented out the clang build and training run works. Sadly clang segfaults with either strict aliasing or lifetime-dse enabled.