[llvm-bugs] [Bug 50654] New: clang 12.0 ICE

via llvm-bugs llvm-bugs at lists.llvm.org
Thu Jun 10 04:57:37 PDT 2021


https://bugs.llvm.org/show_bug.cgi?id=50654

            Bug ID: 50654
           Summary: clang 12.0 ICE
           Product: clang
           Version: 12.0
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: -New Bugs
          Assignee: unassignedclangbugs at nondot.org
          Reporter: navarro.benjamin13 at gmail.com
                CC: htmldeveloper at gmail.com, llvm-bugs at lists.llvm.org,
                    neeilans at live.com, richard-llvm at metafoo.co.uk

I don't really know how to describe the error, just that the compiler crashed
after I added a small portion of code to an existing file. Cleaning the build
folder and recompiling the code solved the issue but I guess the bug report
might still be useful.

Here is the crash report:
Stack dump:
0.      Program arguments: /usr/bin/clang++ -DCATCH_CONFIG_ENABLE_BENCHMARKING
-DEIGEN_DENSEBASE_PLUGIN=<Eigen/dense_base_extensions.h>
-DEIGEN_QUATERNIONBASE_PLUGIN=<Eigen/quaternion_base_extensions.h>
-DPHYSICAL_QUANTITIES_ASSERT_THROWS=OFF
-DPHYSICAL_QUANTITIES_FORCE_SAFETY_CHECKS=OFF
-I/home/idhuser/prog/pidv4-workspace/packages/physical-quantities/include/physical-quantities
-isystem
/home/idhuser/prog/pidv4-workspace/install/x86_64_linux_stdc++11/eigen-extensions/0.13.4/include/Eigen
-isystem
/home/idhuser/prog/pidv4-workspace/install/x86_64_linux_stdc++11/eigen/3.3.9/include
-isystem
/home/idhuser/prog/pidv4-workspace/install/x86_64_linux_stdc++11/eigen-fmt/0.3.0/include/eigen-fmt
-isystem
/home/idhuser/prog/pidv4-workspace/install/x86_64_linux_stdc++11/fmt/7.0.1/include
-isystem
/home/idhuser/prog/pidv4-workspace/install/x86_64_linux_stdc++11/pid-tests/0.1.1/include/pid-tests
-isystem
/home/idhuser/prog/pidv4-workspace/install/x86_64_linux_stdc++11/pid-tests/0.1.1/include/catch2-main
-isystem
/home/idhuser/prog/pidv4-workspace/install/x86_64_linux_stdc++11/catch2/2.13.0/include
-D_GLIBCXX_USE_CXX11_ABI=1 -O3 -DNDEBUG -g -Wall -Wextra -Wshadow
-Wnon-virtual-dtor -Wold-style-cast -Wcast-align -Wunused -Woverloaded-virtual
-Wpedantic -Wconversion -Wsign-conversion -Wnull-dereference -Wdouble-promotion
-Wformat=2 -Werror -std=c++17 -MD -MT
test/CMakeFiles/physical-quantities_spatial.dir/spatial/damping.cpp.o -MF
CMakeFiles/physical-quantities_spatial.dir/spatial/damping.cpp.o.d -o
CMakeFiles/physical-quantities_spatial.dir/spatial/damping.cpp.o -c
/home/idhuser/prog/pidv4-workspace/packages/physical-quantities/test/spatial/damping.cpp
1.      <eof> parser at end of file
2.      Per-file LLVM IR generation
3.     
/home/idhuser/prog/pidv4-workspace/packages/physical-quantities/test/spatial/utils.h:649:6:
Generating code for declaration 'impedanceTermTests'
 #0 0x00007ffb333b0643 (/usr/bin/../lib/libLLVM-12.so+0xb48643)
 #1 0x00007ffb333ae1b4 llvm::sys::CleanupOnSignal(unsigned long)
(/usr/bin/../lib/libLLVM-12.so+0xb461b4)
 #2 0x00007ffb332bf1e9 (/usr/bin/../lib/libLLVM-12.so+0xa571e9)
 #3 0x00007ffb324c2da0 __restore_rt (/usr/bin/../lib/libc.so.6+0x3cda0)
 #4 0x00007ffb3931ca36 clang::SourceManager::getColumnNumber(clang::FileID,
unsigned int, bool*) const (/usr/bin/../lib/libclang-cpp.so.12+0x81aa36)
 #5 0x00007ffb39321660
clang::SourceManager::getPresumedLoc(clang::SourceLocation, bool) const
(/usr/bin/../lib/libclang-cpp.so.12+0x81f660)
 #6 0x00007ffb3a4ec40a
clang::CodeGen::CGDebugInfo::setLocation(clang::SourceLocation)
(/usr/bin/../lib/libclang-cpp.so.12+0x19ea40a)
 #7 0x00007ffb3a4ec5fb
clang::CodeGen::CGDebugInfo::EmitLocation(clang::CodeGen::CGBuilderTy&,
clang::SourceLocation) (/usr/bin/../lib/libclang-cpp.so.12+0x19ea5fb)
 #8 0x00007ffb3a52679b (/usr/bin/../lib/libclang-cpp.so.12+0x1a2479b)
 #9 0x00007ffb3a5276b3 clang::CodeGen::CodeGenFunction::getInvokeDestImpl()
(/usr/bin/../lib/libclang-cpp.so.12+0x1a256b3)
#10 0x00007ffb3a4bd59e
clang::CodeGen::CodeGenFunction::EmitCall(clang::CodeGen::CGFunctionInfo
const&, clang::CodeGen::CGCallee const&, clang::CodeGen::ReturnValueSlot,
clang::CodeGen::CallArgList const&, llvm::CallBase**, clang::SourceLocation)
(/usr/bin/../lib/libclang-cpp.so.12+0x19bb59e)
#11 0x00007ffb3a4d0721
clang::CodeGen::CodeGenFunction::EmitCXXConstructorCall(clang::CXXConstructorDecl
const*, clang::CXXCtorType, bool, bool, clang::CodeGen::Address,
clang::CodeGen::CallArgList&, clang::CodeGen::AggValueSlot::Overlap_t,
clang::SourceLocation, bool) (/usr/bin/../lib/libclang-cpp.so.12+0x19ce721)
#12 0x00007ffb3a4d186b
clang::CodeGen::CodeGenFunction::EmitCXXConstructorCall(clang::CXXConstructorDecl
const*, clang::CXXCtorType, bool, bool, clang::CodeGen::AggValueSlot,
clang::CXXConstructExpr const*) (/usr/bin/../lib/libclang-cpp.so.12+0x19cf86b)
#13 0x00007ffb3a54fc27 (/usr/bin/../lib/libclang-cpp.so.12+0x1a4dc27)
#14 0x00007ffb3a555df1 (/usr/bin/../lib/libclang-cpp.so.12+0x1a53df1)
#15 0x00007ffb3a556f25 clang::CodeGen::CodeGenFunction::EmitAggExpr(clang::Expr
const*, clang::CodeGen::AggValueSlot)
(/usr/bin/../lib/libclang-cpp.so.12+0x1a54f25)
#16 0x00007ffb3a548551
clang::CodeGen::CodeGenFunction::EmitAnyExprToMem(clang::Expr const*,
clang::CodeGen::Address, clang::Qualifiers, bool)
(/usr/bin/../lib/libclang-cpp.so.12+0x1a46551)
#17 0x00007ffb3a54f25c
clang::CodeGen::CodeGenFunction::EmitMaterializeTemporaryExpr(clang::MaterializeTemporaryExpr
const*) (/usr/bin/../lib/libclang-cpp.so.12+0x1a4d25c)
#18 0x00007ffb3a543e06 clang::CodeGen::CodeGenFunction::EmitLValue(clang::Expr
const*) (/usr/bin/../lib/libclang-cpp.so.12+0x1a41e06)
#19 0x00007ffb3a54ca5e
clang::CodeGen::CodeGenFunction::EmitReferenceBindingToExpr(clang::Expr const*)
(/usr/bin/../lib/libclang-cpp.so.12+0x1a4aa5e)
#20 0x00007ffb3a4b16a7
clang::CodeGen::CodeGenFunction::EmitCallArg(clang::CodeGen::CallArgList&,
clang::Expr const*, clang::QualType)
(/usr/bin/../lib/libclang-cpp.so.12+0x19af6a7)
#21 0x00007ffb3a4b2bea
clang::CodeGen::CodeGenFunction::EmitCallArgs(clang::CodeGen::CallArgList&,
clang::CodeGen::CodeGenFunction::PrototypeWrapper,
llvm::iterator_range<clang::Stmt::CastIterator<clang::Expr, clang::Expr const*
const, clang::Stmt const* const> >,
clang::CodeGen::CodeGenFunction::AbstractCallee, unsigned int,
clang::CodeGen::CodeGenFunction::EvaluationOrder)
(/usr/bin/../lib/libclang-cpp.so.12+0x19b0bea)
#22 0x00007ffb3a53c91a
clang::CodeGen::CodeGenFunction::EmitCall(clang::QualType,
clang::CodeGen::CGCallee const&, clang::CallExpr const*,
clang::CodeGen::ReturnValueSlot, llvm::Value*)
(/usr/bin/../lib/libclang-cpp.so.12+0x1a3a91a)
#23 0x00007ffb3a54d23e
clang::CodeGen::CodeGenFunction::EmitCallExpr(clang::CallExpr const*,
clang::CodeGen::ReturnValueSlot) (/usr/bin/../lib/libclang-cpp.so.12+0x1a4b23e)
#24 0x00007ffb3a554050 (/usr/bin/../lib/libclang-cpp.so.12+0x1a52050)
#25 0x00007ffb3a55484b (/usr/bin/../lib/libclang-cpp.so.12+0x1a5284b)
#26 0x00007ffb3a555df1 (/usr/bin/../lib/libclang-cpp.so.12+0x1a53df1)
#27 0x00007ffb3a556f25 clang::CodeGen::CodeGenFunction::EmitAggExpr(clang::Expr
const*, clang::CodeGen::AggValueSlot)
(/usr/bin/../lib/libclang-cpp.so.12+0x1a54f25)
#28 0x00007ffb3a548551
clang::CodeGen::CodeGenFunction::EmitAnyExprToMem(clang::Expr const*,
clang::CodeGen::Address, clang::Qualifiers, bool)
(/usr/bin/../lib/libclang-cpp.so.12+0x1a46551)
#29 0x00007ffb3a54f25c
clang::CodeGen::CodeGenFunction::EmitMaterializeTemporaryExpr(clang::MaterializeTemporaryExpr
const*) (/usr/bin/../lib/libclang-cpp.so.12+0x1a4d25c)
#30 0x00007ffb3a543e06 clang::CodeGen::CodeGenFunction::EmitLValue(clang::Expr
const*) (/usr/bin/../lib/libclang-cpp.so.12+0x1a41e06)
#31 0x00007ffb3a54ca5e
clang::CodeGen::CodeGenFunction::EmitReferenceBindingToExpr(clang::Expr const*)
(/usr/bin/../lib/libclang-cpp.so.12+0x1a4aa5e)
#32 0x00007ffb3a4b16a7
clang::CodeGen::CodeGenFunction::EmitCallArg(clang::CodeGen::CallArgList&,
clang::Expr const*, clang::QualType)
(/usr/bin/../lib/libclang-cpp.so.12+0x19af6a7)
#33 0x00007ffb3a4b2bea
clang::CodeGen::CodeGenFunction::EmitCallArgs(clang::CodeGen::CallArgList&,
clang::CodeGen::CodeGenFunction::PrototypeWrapper,
llvm::iterator_range<clang::Stmt::CastIterator<clang::Expr, clang::Expr const*
const, clang::Stmt const* const> >,
clang::CodeGen::CodeGenFunction::AbstractCallee, unsigned int,
clang::CodeGen::CodeGenFunction::EvaluationOrder)
(/usr/bin/../lib/libclang-cpp.so.12+0x19b0bea)
#34 0x00007ffb3a4d1824
clang::CodeGen::CodeGenFunction::EmitCXXConstructorCall(clang::CXXConstructorDecl
const*, clang::CXXCtorType, bool, bool, clang::CodeGen::AggValueSlot,
clang::CXXConstructExpr const*) (/usr/bin/../lib/libclang-cpp.so.12+0x19cf824)
#35 0x00007ffb3a54fc27 (/usr/bin/../lib/libclang-cpp.so.12+0x1a4dc27)
#36 0x00007ffb3a555df1 (/usr/bin/../lib/libclang-cpp.so.12+0x1a53df1)
#37 0x00007ffb3a556f25 clang::CodeGen::CodeGenFunction::EmitAggExpr(clang::Expr
const*, clang::CodeGen::AggValueSlot)
(/usr/bin/../lib/libclang-cpp.so.12+0x1a54f25)
#38 0x00007ffb3a548551
clang::CodeGen::CodeGenFunction::EmitAnyExprToMem(clang::Expr const*,
clang::CodeGen::Address, clang::Qualifiers, bool)
(/usr/bin/../lib/libclang-cpp.so.12+0x1a46551)
#39 0x00007ffb3a54f25c
clang::CodeGen::CodeGenFunction::EmitMaterializeTemporaryExpr(clang::MaterializeTemporaryExpr
const*) (/usr/bin/../lib/libclang-cpp.so.12+0x1a4d25c)
#40 0x00007ffb3a543e06 clang::CodeGen::CodeGenFunction::EmitLValue(clang::Expr
const*) (/usr/bin/../lib/libclang-cpp.so.12+0x1a41e06)
#41 0x00007ffb3a54ca5e
clang::CodeGen::CodeGenFunction::EmitReferenceBindingToExpr(clang::Expr const*)
(/usr/bin/../lib/libclang-cpp.so.12+0x1a4aa5e)
#42 0x00007ffb3a4b16a7
clang::CodeGen::CodeGenFunction::EmitCallArg(clang::CodeGen::CallArgList&,
clang::Expr const*, clang::QualType)
(/usr/bin/../lib/libclang-cpp.so.12+0x19af6a7)
#43 0x00007ffb3a4b2bea
clang::CodeGen::CodeGenFunction::EmitCallArgs(clang::CodeGen::CallArgList&,
clang::CodeGen::CodeGenFunction::PrototypeWrapper,
llvm::iterator_range<clang::Stmt::CastIterator<clang::Expr, clang::Expr const*
const, clang::Stmt const* const> >,
clang::CodeGen::CodeGenFunction::AbstractCallee, unsigned int,
clang::CodeGen::CodeGenFunction::EvaluationOrder)
(/usr/bin/../lib/libclang-cpp.so.12+0x19b0bea)
#44 0x00007ffb3a4d1824
clang::CodeGen::CodeGenFunction::EmitCXXConstructorCall(clang::CXXConstructorDecl
const*, clang::CXXCtorType, bool, bool, clang::CodeGen::AggValueSlot,
clang::CXXConstructExpr const*) (/usr/bin/../lib/libclang-cpp.so.12+0x19cf824)
#45 0x00007ffb3a54fc27 (/usr/bin/../lib/libclang-cpp.so.12+0x1a4dc27)
#46 0x00007ffb3a556b1c (/usr/bin/../lib/libclang-cpp.so.12+0x1a54b1c)
#47 0x00007ffb3a556f25 clang::CodeGen::CodeGenFunction::EmitAggExpr(clang::Expr
const*, clang::CodeGen::AggValueSlot)
(/usr/bin/../lib/libclang-cpp.so.12+0x1a54f25)
#48 0x00007ffb3a548551
clang::CodeGen::CodeGenFunction::EmitAnyExprToMem(clang::Expr const*,
clang::CodeGen::Address, clang::Qualifiers, bool)
(/usr/bin/../lib/libclang-cpp.so.12+0x1a46551)
#49 0x00007ffb3a54f25c
clang::CodeGen::CodeGenFunction::EmitMaterializeTemporaryExpr(clang::MaterializeTemporaryExpr
const*) (/usr/bin/../lib/libclang-cpp.so.12+0x1a4d25c)
#50 0x00007ffb3a543e06 clang::CodeGen::CodeGenFunction::EmitLValue(clang::Expr
const*) (/usr/bin/../lib/libclang-cpp.so.12+0x1a41e06)
#51 0x00007ffb3a5440ba clang::CodeGen::CodeGenFunction::EmitLValue(clang::Expr
const*) (/usr/bin/../lib/libclang-cpp.so.12+0x1a420ba)
#52 0x00007ffb3a54ca5e
clang::CodeGen::CodeGenFunction::EmitReferenceBindingToExpr(clang::Expr const*)
(/usr/bin/../lib/libclang-cpp.so.12+0x1a4aa5e)
#53 0x00007ffb3a509879
clang::CodeGen::CodeGenFunction::EmitExprAsInit(clang::Expr const*,
clang::ValueDecl const*, clang::CodeGen::LValue, bool)
(/usr/bin/../lib/libclang-cpp.so.12+0x1a07879)
#54 0x00007ffb3a51287d
clang::CodeGen::CodeGenFunction::EmitAutoVarInit(clang::CodeGen::CodeGenFunction::AutoVarEmission
const&) (/usr/bin/../lib/libclang-cpp.so.12+0x1a1087d)
#55 0x00007ffb3a51414c
clang::CodeGen::CodeGenFunction::EmitVarDecl(clang::VarDecl const&)
(/usr/bin/../lib/libclang-cpp.so.12+0x1a1214c)
#56 0x00007ffb3a5142ad clang::CodeGen::CodeGenFunction::EmitDecl(clang::Decl
const&) (/usr/bin/../lib/libclang-cpp.so.12+0x1a122ad)
#57 0x00007ffb3a6c5c39
clang::CodeGen::CodeGenFunction::EmitIfStmt(clang::IfStmt const&)
(/usr/bin/../lib/libclang-cpp.so.12+0x1bc3c39)
#58 0x00007ffb3a6c62aa
clang::CodeGen::CodeGenFunction::EmitCompoundStmtWithoutScope(clang::CompoundStmt
const&, bool, clang::CodeGen::AggValueSlot)
(/usr/bin/../lib/libclang-cpp.so.12+0x1bc42aa)
#59 0x00007ffb3a71e99e
clang::CodeGen::CodeGenFunction::EmitFunctionBody(clang::Stmt const*)
(/usr/bin/../lib/libclang-cpp.so.12+0x1c1c99e)
#60 0x00007ffb3a72ef53
clang::CodeGen::CodeGenFunction::GenerateCode(clang::GlobalDecl,
llvm::Function*, clang::CodeGen::CGFunctionInfo const&)
(/usr/bin/../lib/libclang-cpp.so.12+0x1c2cf53)
#61 0x00007ffb3a76c5d7
clang::CodeGen::CodeGenModule::EmitGlobalFunctionDefinition(clang::GlobalDecl,
llvm::GlobalValue*) (/usr/bin/../lib/libclang-cpp.so.12+0x1c6a5d7)
#62 0x00007ffb3a768545
clang::CodeGen::CodeGenModule::EmitGlobalDefinition(clang::GlobalDecl,
llvm::GlobalValue*) (/usr/bin/../lib/libclang-cpp.so.12+0x1c66545)
#63 0x00007ffb3a76ff7b clang::CodeGen::CodeGenModule::EmitDeferred()
(/usr/bin/../lib/libclang-cpp.so.12+0x1c6df7b)
#64 0x00007ffb3a76ff93 clang::CodeGen::CodeGenModule::EmitDeferred()
(/usr/bin/../lib/libclang-cpp.so.12+0x1c6df93)
#65 0x00007ffb3a77025c clang::CodeGen::CodeGenModule::Release()
(/usr/bin/../lib/libclang-cpp.so.12+0x1c6e25c)
#66 0x00007ffb3a7dd13b (/usr/bin/../lib/libclang-cpp.so.12+0x1cdb13b)
#67 0x00007ffb3a7193c5 (/usr/bin/../lib/libclang-cpp.so.12+0x1c173c5)
#68 0x00007ffb39439659 clang::ParseAST(clang::Sema&, bool, bool)
(/usr/bin/../lib/libclang-cpp.so.12+0x937659)
#69 0x00007ffb3ae84249 clang::FrontendAction::Execute()
(/usr/bin/../lib/libclang-cpp.so.12+0x2382249)
#70 0x00007ffb3ae1b54e
clang::CompilerInstance::ExecuteAction(clang::FrontendAction&)
(/usr/bin/../lib/libclang-cpp.so.12+0x231954e)
#71 0x00007ffb3af04929
clang::ExecuteCompilerInvocation(clang::CompilerInstance*)
(/usr/bin/../lib/libclang-cpp.so.12+0x2402929)
#72 0x000055b2b82c48de cc1_main(llvm::ArrayRef<char const*>, char const*,
void*) (/usr/bin/clang+++0x128de)
#73 0x000055b2b82c1ee8 (/usr/bin/clang+++0xfee8)
#74 0x00007ffb3aaecfd5 (/usr/bin/../lib/libclang-cpp.so.12+0x1feafd5)
#75 0x00007ffb332bf2f3
llvm::CrashRecoveryContext::RunSafely(llvm::function_ref<void ()>)
(/usr/bin/../lib/libLLVM-12.so+0xa572f3)
#76 0x00007ffb3aaed380 (/usr/bin/../lib/libclang-cpp.so.12+0x1feb380)
#77 0x00007ffb3aac1298
clang::driver::Compilation::ExecuteCommand(clang::driver::Command const&,
clang::driver::Command const*&) const
(/usr/bin/../lib/libclang-cpp.so.12+0x1fbf298)
#78 0x00007ffb3aac1d29
clang::driver::Compilation::ExecuteJobs(clang::driver::JobList const&,
llvm::SmallVectorImpl<std::pair<int, clang::driver::Command const*> >&) const
(/usr/bin/../lib/libclang-cpp.so.12+0x1fbfd29)
#79 0x00007ffb3aad1c5a
clang::driver::Driver::ExecuteCompilation(clang::driver::Compilation&,
llvm::SmallVectorImpl<std::pair<int, clang::driver::Command const*> >&)
(/usr/bin/../lib/libclang-cpp.so.12+0x1fcfc5a)
#80 0x000055b2b82bfc13 main (/usr/bin/clang+++0xdc13)
#81 0x00007ffb324adb25 __libc_start_main (/usr/bin/../lib/libc.so.6+0x27b25)
#82 0x000055b2b82c186e _start (/usr/bin/clang+++0xf86e)
clang-12: error: clang frontend command failed with exit code 135 (use -v to
see invocation)
clang version 12.0.0
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/bin
clang-12: note: diagnostic msg: 
********************

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20210610/1c545986/attachment-0001.html>


More information about the llvm-bugs mailing list