llvm / llvm/llvm-project

Clang told me to submit a bug report

Open
#218,104 2 comments 0 reactions 0 assignees View on GitHub
clang:frontend crash incomplete
Dominant language
LLVM
Stars
40.5k
Forks
18.7k
PR merge metrics
PR metrics pending

Description

```console
[1/11] Building CXX object xrParticles/CMakeFiles/xrParticles.dir/cmake_pch.hxx.pch
FAILED: [code=267] xrParticles/CMakeFiles/xrParticles.dir/cmake_pch.hxx.pch
/opt/llvm-mingw/bin/clang++ --target=x86_64-w64-mingw32 -DNDEBUG -DWIN32 -DXRAY_MSVC_COMPAT -DXR_PARTICLES_EXPORTS -D_MBCS -D_MT -D_SECURE_SCL=0 -D_SILENCE_STDEXT_HASH_DEPRECATION_WARNINGS -D_VC80_UPGRADE=0x0710 -D_WIN32_WINNT=0x0A00 -D_WINDOWS -I/home/makar/xray-monolith/src/../src/3rd_party -I/home/makar/xray-monolith/src/3rd_party/icu/include -I/home/makar/xray-monolith/src/../sdk/include -I/home/makar/xray-monolith/src/../sdk/include/OpenAutomate -I/home/makar/xray-monolith/src/../sdk/include/nvapi -I/home/makar/xray-monolith/src/../sdk/include/dxsdk -I/home/makar/xray-monolith/src/xrParticles/../3rd_party/luabind -I/home/makar/xray-monolith/src/xrParticles/../../sdk/include -I/home/makar/xray-monolith/src/xrCore/. -I/home/makar/xray-monolith/src/xrCore/../../sdk/include -I/mnt/hdd/CPM/simde/b3b4 -I/home/makar/xray-monolith/src/xrCPU_Pipe/../../sdk/include -isystem /mnt/hdd/CPM/stdfunc/8a03/include -std=gnu++26 -Wno-c++11-narrowing -Wno-microsoft-cast -Wno-microsoft-enum-value -Wno-invalid-offsetof -fms-extensions -fdelayed-template-parsing -march=native -Wno-error -fno-exceptions -O0 -g -ffunction-sections -fdata-sections -Winvalid-pch -fpch-instantiate-templates -Xclang -emit-pch -Xclang -include -Xclang /home/makar/xray-monolith/src/build_clang_mingw/xrParticles/CMakeFiles/xrParticles.dir/cmake_pch.hxx -x c++-header -MD -MT xrParticles/CMakeFiles/xrParticles.dir/cmake_pch.hxx.pch -MF xrParticles/CMakeFiles/xrParticles.dir/cmake_pch.hxx.pch.d -o xrParticles/CMakeFiles/xrParticles.dir/cmake_pch.hxx.pch -c /home/makar/xray-monolith/src/build_clang_mingw/xrParticles/CMakeFiles/xrParticles.dir/cmake_pch.hxx.cxx
clang++: warning: -fdelayed-template-parsing is deprecated after C++20 [-Wdelayed-template-parsing-in-cxx20]
PLEASE submit a bug report to https://github.com/llvm/llvm-project/issues/ and include the crash backtrace, preprocessed source, and associated run script.
Stack dump:
0. Program arguments: /opt/llvm-mingw/bin/clang++ --target=x86_64-w64-mingw32 -DNDEBUG -DWIN32 -DXRAY_MSVC_COMPAT -DXR_PARTICLES_EXPORTS -D_MBCS -D_MT -D_SECURE_SCL=0 -D_SILENCE_STDEXT_HASH_DEPRECATION_WARNINGS -D_VC80_UPGRADE=0x0710 -D_WIN32_WINNT=0x0A00 -D_WINDOWS -I/home/makar/xray-monolith/src/../src/3rd_party -I/home/makar/xray-monolith/src/3rd_party/icu/include -I/home/makar/xray-monolith/src/../sdk/include -I/home/makar/xray-monolith/src/../sdk/include/OpenAutomate -I/home/makar/xray-monolith/src/../sdk/include/nvapi -I/home/makar/xray-monolith/src/../sdk/include/dxsdk -I/home/makar/xray-monolith/src/xrParticles/../3rd_party/luabind -I/home/makar/xray-monolith/src/xrParticles/../../sdk/include -I/home/makar/xray-monolith/src/xrCore/. -I/home/makar/xray-monolith/src/xrCore/../../sdk/include -I/mnt/hdd/CPM/simde/b3b4 -I/home/makar/xray-monolith/src/xrCPU_Pipe/../../sdk/include -isystem /mnt/hdd/CPM/stdfunc/8a03/include -std=gnu++26 -Wno-c++11-narrowing -Wno-microsoft-cast -Wno-microsoft-enum-value -Wno-invalid-offsetof -fms-extensions -fdelayed-template-parsing -march=native -Wno-error -fno-exceptions -O0 -g -ffunction-sections -fdata-sections -Winvalid-pch -fpch-instantiate-templates -Xclang -emit-pch -Xclang -include -Xclang /home/makar/xray-monolith/src/build_clang_mingw/xrParticles/CMakeFiles/xrParticles.dir/cmake_pch.hxx -x c++-header -MD -MT xrParticles/CMakeFiles/xrParticles.dir/cmake_pch.hxx.pch -MF xrParticles/CMakeFiles/xrParticles.dir/cmake_pch.hxx.pch.d -o xrParticles/CMakeFiles/xrParticles.dir/cmake_pch.hxx.pch -c /home/makar/xray-monolith/src/build_clang_mingw/xrParticles/CMakeFiles/xrParticles.dir/cmake_pch.hxx.cxx
1. parser at end of file
2. /home/makar/xray-monolith/src/xrParticles/../xrEngine/../xrCore/FixedVector.h:48:31: serializing ' #0 0x00007f0dd318fae2 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) (/opt/llvm-mingw/bin/../lib/libLLVM.so.22.1+0x98fae2)
#1 0x00007f0dd318c467 (/opt/llvm-mingw/bin/../lib/libLLVM.so.22.1+0x98c467)
#2 0x00007f0dd2044e70 (/usr/lib/libc.so.6+0x44e70)
#3 0x00007f0dd9f55422 clang::PrettyDeclStackTraceEntry::print(llvm::raw_ostream&) const (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0xf55422)
#4 0x00007f0dd30ae69e (/opt/llvm-mingw/bin/../lib/libLLVM.so.22.1+0x8ae69e)
#5 0x00007f0dd318d354 llvm::sys::CleanupOnSignal(unsigned long) (/opt/llvm-mingw/bin/../lib/libLLVM.so.22.1+0x98d354)
#6 0x00007f0dd30419bc (/opt/llvm-mingw/bin/../lib/libLLVM.so.22.1+0x8419bc)
#7 0x00007f0dd2044e70 (/usr/lib/libc.so.6+0x44e70)
#8 0x00007f0dd9f79d0e clang::Decl::isUsed(bool) const (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0xf79d0e)
#9 0x00007f0ddc4aa6a2 clang::ASTDeclWriter::VisitDecl(clang::Decl*) (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x34aa6a2)
#10 0x00007f0ddc4ac0f1 clang::ASTDeclWriter::VisitNamedDecl(clang::NamedDecl*) (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x34ac0f1)
#11 0x00007f0ddc4ae661 clang::ASTDeclWriter::VisitDeclaratorDecl(clang::DeclaratorDecl*) (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x34ae661)
#12 0x00007f0ddc4af03b clang::ASTDeclWriter::VisitVarDecl(clang::VarDecl*) (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x34af03b)
#13 0x00007f0ddc4af891 clang::ASTDeclWriter::VisitParmVarDecl(clang::ParmVarDecl*) (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x34af891)
#14 0x00007f0ddc4b5411 clang::ASTDeclWriter::Visit(clang::Decl*) (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x34b5411)
#15 0x00007f0ddc4b5802 clang::ASTWriter::WriteDecl(clang::ASTContext&, clang::Decl*) (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x34b5802)
#16 0x00007f0ddc49e075 clang::ASTWriter::WriteDeclAndTypes(clang::ASTContext&) (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x349e075)
#17 0x00007f0ddc49fd98 clang::ASTWriter::WriteASTCore(clang::Sema*, llvm::StringRef, clang::Module*) (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x349fd98)
#18 0x00007f0ddc4a113f clang::ASTWriter::WriteAST(llvm::PointerUnion, llvm::StringRef, clang::Module*, llvm::StringRef, bool) (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x34a113f)
#19 0x00007f0ddc4c8594 clang::PCHGenerator::HandleTranslationUnit(clang::ASTContext&) (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x34c8594)
#20 0x00007f0ddc63cc55 clang::MultiplexConsumer::HandleTranslationUnit(clang::ASTContext&) (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x363cc55)
#21 0x00007f0dd9b7c0d4 clang::ParseAST(clang::Sema&, bool, bool) (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0xb7c0d4)
#22 0x00007f0ddc5e5e13 clang::FrontendAction::Execute() (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x35e5e13)
#23 0x00007f0ddc55a442 clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x355a442)
#24 0x00007f0ddc6b47f2 clang::ExecuteCompilerInvocation(clang::CompilerInstance*) (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x36b47f2)
#25 0x0000560399e0b5cb cc1_main(llvm::ArrayRef, char const*, void*) (/opt/llvm-mingw/bin/clang+++0x145cb)
#26 0x0000560399e02263 (/opt/llvm-mingw/bin/clang+++0xb263)
#27 0x0000560399e022b0 (/opt/llvm-mingw/bin/clang+++0xb2b0)
#28 0x00007f0ddc0bd6a9 (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x30bd6a9)
#29 0x00007f0dd3041ea4 llvm::CrashRecoveryContext::RunSafely(llvm::function_ref) (/opt/llvm-mingw/bin/../lib/libLLVM.so.22.1+0x841ea4)
#30 0x00007f0ddc0bdd84 (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x30bdd84)
#31 0x00007f0ddc070257 clang::driver::Compilation::ExecuteCommand(clang::driver::Command const&, clang::driver::Command const*&, bool) const (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x3070257)
#32 0x00007f0ddc071252 clang::driver::Compilation::ExecuteJobs(clang::driver::JobList const&, llvm::SmallVectorImpl>&, bool) const (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x3071252)
#33 0x00007f0ddc091f5c clang::driver::Driver::ExecuteCompilation(clang::driver::Compilation&, llvm::SmallVectorImpl>&) (/opt/llvm-mingw/bin/../lib/libclang-cpp.so.22.1+0x3091f5c)
#34 0x0000560399e07379 clang_main(int, char**, llvm::ToolContext const&) (/opt/llvm-mingw/bin/clang+++0x10379)
#35 0x0000560399e01adf main (/opt/llvm-mingw/bin/clang+++0xaadf)
#36 0x00007f0dd2027d0e (/usr/lib/libc.so.6+0x27d0e)
#37 0x00007f0dd2027e4b __libc_start_main (/usr/lib/libc.so.6+0x27e4b)
#38 0x0000560399e01b45 _start (/opt/llvm-mingw/bin/clang+++0xab45)
ninja: build stopped: subcommand failed.
```

I did not get any preprocessed source or run script from clang, so not submitting it.

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the reported clang++ C++26 precompiled-header failure using the command shown in the issue, then inspect xrCore/FixedVector.h:48 and the surrounding declarations. Capture the missing preprocessed source and run script if possible; done means identifying a reproducible compiler-crash case and confirming the resulting fix or upstream report.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
compilers
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.