llvm / llvm-project

The LLVM Project is a collection of modular and reusable compiler and toolchain technologies.
http://llvm.org
Other
29.05k stars 11.98k forks source link

[clang++] Assertion trunk crashes at clang::Expr::EvaluateWithSubstitution(clang::APValue&, clang::ASTContext&, clang::FunctionDecl const*, llvm::ArrayRef<clang::Expr const*>, clang::Expr const*) const #111692

Open yijan4845 opened 1 month ago

yijan4845 commented 1 month ago

This testcase is generated by a fuzzer.

Compiler Explorer: https://godbolt.org/z/dd68fnKnq

This assertion only fails when there are many compilation errors before the main code. It seems that this goes back to clang-14.

This is the code:

#define _diagnose_if(...) __attribute__((diagnose_if(__VA_ARGS__)))

void many_errors() {
  f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1);
  f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1);
}

template <typename T>
struct S {
  T s;
};

struct Foo {
  Foo(S<int> l)
    _diagnose_if(l.s, "oh no", "error") {}
};

void run() {
  Foo{S<int>{}};
}

Stack dump:

clang++: /root/llvm-project/clang/lib/AST/ExprConstant.cpp:15722: bool clang::Expr::EvaluateWithSubstitution(clang::APValue&, clang::ASTContext&, const clang::FunctionDecl*, llvm::ArrayRef<const clang::Expr*>, const clang::Expr*) const: Assertion `!isValueDependent() && "Expression evaluator can't be called on a dependent expression."' failed.
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/compiler-explorer/clang-assertions-14.0.0/bin/clang++ -gdwarf-4 -g -o /app/output.s -mllvm --x86-asm-syntax=intel -fno-verbose-asm -S --gcc-toolchain=/opt/compiler-explorer/gcc-11.2.0 -fcolor-diagnostics -fno-crash-diagnostics <source>
1.  <source>:19:16: current parser token ';'
2.  <source>:18:12: parsing function body 'run'
3.  <source>:18:12: in compound statement ('{}')
 #0 0x000057a3ae4af0f4 PrintStackTraceSignalHandler(void*) Signals.cpp:0:0
 #1 0x000057a3ae4acf04 llvm::sys::CleanupOnSignal(unsigned long) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x3c9cf04)
 #2 0x000057a3ae3dd0f8 CrashRecoverySignalHandler(int) CrashRecoveryContext.cpp:0:0
 #3 0x00007f77cfc42520 (/lib/x86_64-linux-gnu/libc.so.6+0x42520)
 #4 0x00007f77cfc969fc pthread_kill (/lib/x86_64-linux-gnu/libc.so.6+0x969fc)
 #5 0x00007f77cfc42476 gsignal (/lib/x86_64-linux-gnu/libc.so.6+0x42476)
 #6 0x00007f77cfc287f3 abort (/lib/x86_64-linux-gnu/libc.so.6+0x287f3)
 #7 0x00007f77cfc2871b (/lib/x86_64-linux-gnu/libc.so.6+0x2871b)
 #8 0x00007f77cfc39e96 (/lib/x86_64-linux-gnu/libc.so.6+0x39e96)
 #9 0x000057a3b16fe6d4 clang::Expr::EvaluateWithSubstitution(clang::APValue&, clang::ASTContext&, clang::FunctionDecl const*, llvm::ArrayRef<clang::Expr const*>, clang::Expr const*) const (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x6eee6d4)
#10 0x000057a3b0f4b721 clang::Sema::diagnoseArgDependentDiagnoseIfAttrs(clang::FunctionDecl const*, clang::Expr const*, llvm::ArrayRef<clang::Expr const*>, clang::SourceLocation)::'lambda'(clang::DiagnoseIfAttr const*)::operator()(clang::DiagnoseIfAttr const*) const SemaOverload.cpp:0:0
#11 0x000057a3b0f6fb95 bool diagnoseDiagnoseIfAttrsWith<clang::Sema::diagnoseArgDependentDiagnoseIfAttrs(clang::FunctionDecl const*, clang::Expr const*, llvm::ArrayRef<clang::Expr const*>, clang::SourceLocation)::'lambda'(clang::DiagnoseIfAttr const*)>(clang::Sema&, clang::NamedDecl const*, bool, clang::SourceLocation, clang::Sema::diagnoseArgDependentDiagnoseIfAttrs(clang::FunctionDecl const*, clang::Expr const*, llvm::ArrayRef<clang::Expr const*>, clang::SourceLocation)::'lambda'(clang::DiagnoseIfAttr const*)&&) (.constprop.0) SemaOverload.cpp:0:0
#12 0x000057a3b0f6fd6a clang::Sema::diagnoseArgDependentDiagnoseIfAttrs(clang::FunctionDecl const*, clang::Expr const*, llvm::ArrayRef<clang::Expr const*>, clang::SourceLocation) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x675fd6a)
#13 0x000057a3b0989d4a clang::Sema::checkCall(clang::NamedDecl*, clang::FunctionProtoType const*, clang::Expr const*, llvm::ArrayRef<clang::Expr const*>, bool, clang::SourceLocation, clang::SourceRange, clang::Sema::VariadicCallType) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x6179d4a)
#14 0x000057a3b098b6ed clang::Sema::CheckConstructorCall(clang::FunctionDecl*, clang::QualType, llvm::ArrayRef<clang::Expr const*>, clang::FunctionProtoType const*, clang::SourceLocation) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x617b6ed)
#15 0x000057a3b0b1730e clang::Sema::CompleteConstructorCall(clang::CXXConstructorDecl*, clang::QualType, llvm::MutableArrayRef<clang::Expr*>, clang::SourceLocation, llvm::SmallVectorImpl<clang::Expr*>&, bool, bool) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x630730e)
#16 0x000057a3b0dd7918 PerformConstructorInitialization(clang::Sema&, clang::InitializedEntity const&, clang::InitializationKind const&, llvm::MutableArrayRef<clang::Expr*>, clang::InitializationSequence::Step const&, bool&, bool, bool, clang::SourceLocation, clang::SourceLocation) SemaInit.cpp:0:0
#17 0x000057a3b0df1164 clang::InitializationSequence::Perform(clang::Sema&, clang::InitializedEntity const&, clang::InitializationKind const&, llvm::MutableArrayRef<clang::Expr*>, clang::QualType*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x65e1164)
#18 0x000057a3b0d0d03d clang::Sema::BuildCXXTypeConstructExpr(clang::TypeSourceInfo*, clang::SourceLocation, llvm::MutableArrayRef<clang::Expr*>, clang::SourceLocation, bool) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x64fd03d)
#19 0x000057a3b0d945d2 clang::Sema::ActOnCXXTypeConstructExpr(clang::OpaquePtr<clang::QualType>, clang::SourceLocation, llvm::MutableArrayRef<clang::Expr*>, clang::SourceLocation, bool) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x65845d2)
#20 0x000057a3b08187e8 clang::Parser::ParseCXXTypeConstructExpression(clang::DeclSpec const&) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x60087e8)
#21 0x000057a3b080822b clang::Parser::ParseCastExpression(clang::Parser::CastParseKind, bool, bool&, clang::Parser::TypeCastState, bool, bool*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5ff822b)
#22 0x000057a3b080995b clang::Parser::ParseCastExpression(clang::Parser::CastParseKind, bool, clang::Parser::TypeCastState, bool, bool*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5ff995b)
#23 0x000057a3b08099fd clang::Parser::ParseAssignmentExpression(clang::Parser::TypeCastState) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5ff99fd)
#24 0x000057a3b080cf5d clang::Parser::ParseExpression(clang::Parser::TypeCastState) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5ffcf5d)
#25 0x000057a3b087a17e clang::Parser::ParseExprStatement(clang::Parser::ParsedStmtContext) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x606a17e)
#26 0x000057a3b0871192 clang::Parser::ParseStatementOrDeclarationAfterAttributes(llvm::SmallVector<clang::Stmt*, 32u>&, clang::Parser::ParsedStmtContext, clang::SourceLocation*, clang::ParsedAttributesWithRange&) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x6061192)
#27 0x000057a3b0871c1a clang::Parser::ParseStatementOrDeclaration(llvm::SmallVector<clang::Stmt*, 32u>&, clang::Parser::ParsedStmtContext, clang::SourceLocation*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x6061c1a)
#28 0x000057a3b0872a91 clang::Parser::ParseCompoundStatementBody(bool) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x6062a91)
#29 0x000057a3b087543a clang::Parser::ParseFunctionStatementBody(clang::Decl*, clang::Parser::ParseScope&) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x606543a)
#30 0x000057a3b07b4c92 clang::Parser::ParseFunctionDefinition(clang::ParsingDeclarator&, clang::Parser::ParsedTemplateInfo const&, clang::Parser::LateParsedAttrList*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5fa4c92)
#31 0x000057a3b07e2130 clang::Parser::ParseDeclGroup(clang::ParsingDeclSpec&, clang::DeclaratorContext, clang::SourceLocation*, clang::Parser::ForRangeInit*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5fd2130)
#32 0x000057a3b07af496 clang::Parser::ParseDeclOrFunctionDefInternal(clang::ParsedAttributesWithRange&, clang::ParsingDeclSpec&, clang::AccessSpecifier) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5f9f496)
#33 0x000057a3b07afa81 clang::Parser::ParseDeclarationOrFunctionDefinition(clang::ParsedAttributesWithRange&, clang::ParsingDeclSpec*, clang::AccessSpecifier) (.part.0) Parser.cpp:0:0
#34 0x000057a3b07b687c clang::Parser::ParseExternalDeclaration(clang::ParsedAttributesWithRange&, clang::ParsingDeclSpec*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5fa687c)
#35 0x000057a3b07b781e clang::Parser::ParseTopLevelDecl(clang::OpaquePtr<clang::DeclGroupRef>&, bool) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5fa781e)
#36 0x000057a3b07aa059 clang::ParseAST(clang::Sema&, bool, bool) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5f9a059)
#37 0x000057a3af68fe98 clang::CodeGenAction::ExecuteAction() (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x4e7fe98)
#38 0x000057a3aef6a5f9 clang::FrontendAction::Execute() (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x475a5f9)
#39 0x000057a3aeef786e clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x46e786e)
#40 0x000057a3af0470b3 clang::ExecuteCompilerInvocation(clang::CompilerInstance*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x48370b3)
#41 0x000057a3abaef01a cc1_main(llvm::ArrayRef<char const*>, char const*, void*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x12df01a)
#42 0x000057a3abaeb3c8 ExecuteCC1Tool(llvm::SmallVectorImpl<char const*>&) driver.cpp:0:0
#43 0x000057a3aed777e9 void llvm::function_ref<void ()>::callback_fn<clang::driver::CC1Command::Execute(llvm::ArrayRef<llvm::Optional<llvm::StringRef> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >*, bool*) const::'lambda'()>(long) Job.cpp:0:0
#44 0x000057a3ae3dd27c llvm::CrashRecoveryContext::RunSafely(llvm::function_ref<void ()>) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x3bcd27c)
#45 0x000057a3aed77eff clang::driver::CC1Command::Execute(llvm::ArrayRef<llvm::Optional<llvm::StringRef> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >*, bool*) const (.part.0) Job.cpp:0:0
#46 0x000057a3aed46fab clang::driver::Compilation::ExecuteCommand(clang::driver::Command const&, clang::driver::Command const*&) const (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x4536fab)
#47 0x000057a3aed47ab9 clang::driver::Compilation::ExecuteJobs(clang::driver::JobList const&, llvm::SmallVectorImpl<std::pair<int, clang::driver::Command const*> >&) const (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x4537ab9)
#48 0x000057a3aed51a89 clang::driver::Driver::ExecuteCompilation(clang::driver::Compilation&, llvm::SmallVectorImpl<std::pair<int, clang::driver::Command const*> >&) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x4541a89)
#49 0x000057a3aba103aa main (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x12003aa)
#50 0x00007f77cfc29d90 (/lib/x86_64-linux-gnu/libc.so.6+0x29d90)
#51 0x00007f77cfc29e40 __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x29e40)
#52 0x000057a3abaeaf3e _start (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x12daf3e)
clang-14: error: clang frontend command failed with exit code 134 (use -v to see invocation)
Compiler returned: 134
llvmbot commented 1 month ago

@llvm/issue-subscribers-clang-frontend

Author: Yihan Yang (yijan4845)

**This testcase is generated by a fuzzer.** Compiler Explorer: [https://godbolt.org/z/dd68fnKnq](https://godbolt.org/z/dd68fnKnq) This assertion only fails when there are many compilation errors before the main code. It seems that this goes back to clang-14. This is the code: ```cpp #define _diagnose_if(...) __attribute__((diagnose_if(__VA_ARGS__))) void many_errors() { f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1); f(1); } template <typename T> struct S { T s; }; struct Foo { Foo(S<int> l) _diagnose_if(l.s, "oh no", "error") {} }; void run() { Foo{S<int>{}}; } ``` Stack dump: ``` clang++: /root/llvm-project/clang/lib/AST/ExprConstant.cpp:15722: bool clang::Expr::EvaluateWithSubstitution(clang::APValue&, clang::ASTContext&, const clang::FunctionDecl*, llvm::ArrayRef<const clang::Expr*>, const clang::Expr*) const: Assertion `!isValueDependent() && "Expression evaluator can't be called on a dependent expression."' failed. 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/compiler-explorer/clang-assertions-14.0.0/bin/clang++ -gdwarf-4 -g -o /app/output.s -mllvm --x86-asm-syntax=intel -fno-verbose-asm -S --gcc-toolchain=/opt/compiler-explorer/gcc-11.2.0 -fcolor-diagnostics -fno-crash-diagnostics <source> 1. <source>:19:16: current parser token ';' 2. <source>:18:12: parsing function body 'run' 3. <source>:18:12: in compound statement ('{}') #0 0x000057a3ae4af0f4 PrintStackTraceSignalHandler(void*) Signals.cpp:0:0 #1 0x000057a3ae4acf04 llvm::sys::CleanupOnSignal(unsigned long) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x3c9cf04) #2 0x000057a3ae3dd0f8 CrashRecoverySignalHandler(int) CrashRecoveryContext.cpp:0:0 #3 0x00007f77cfc42520 (/lib/x86_64-linux-gnu/libc.so.6+0x42520) #4 0x00007f77cfc969fc pthread_kill (/lib/x86_64-linux-gnu/libc.so.6+0x969fc) #5 0x00007f77cfc42476 gsignal (/lib/x86_64-linux-gnu/libc.so.6+0x42476) #6 0x00007f77cfc287f3 abort (/lib/x86_64-linux-gnu/libc.so.6+0x287f3) #7 0x00007f77cfc2871b (/lib/x86_64-linux-gnu/libc.so.6+0x2871b) #8 0x00007f77cfc39e96 (/lib/x86_64-linux-gnu/libc.so.6+0x39e96) #9 0x000057a3b16fe6d4 clang::Expr::EvaluateWithSubstitution(clang::APValue&, clang::ASTContext&, clang::FunctionDecl const*, llvm::ArrayRef<clang::Expr const*>, clang::Expr const*) const (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x6eee6d4) #10 0x000057a3b0f4b721 clang::Sema::diagnoseArgDependentDiagnoseIfAttrs(clang::FunctionDecl const*, clang::Expr const*, llvm::ArrayRef<clang::Expr const*>, clang::SourceLocation)::'lambda'(clang::DiagnoseIfAttr const*)::operator()(clang::DiagnoseIfAttr const*) const SemaOverload.cpp:0:0 #11 0x000057a3b0f6fb95 bool diagnoseDiagnoseIfAttrsWith<clang::Sema::diagnoseArgDependentDiagnoseIfAttrs(clang::FunctionDecl const*, clang::Expr const*, llvm::ArrayRef<clang::Expr const*>, clang::SourceLocation)::'lambda'(clang::DiagnoseIfAttr const*)>(clang::Sema&, clang::NamedDecl const*, bool, clang::SourceLocation, clang::Sema::diagnoseArgDependentDiagnoseIfAttrs(clang::FunctionDecl const*, clang::Expr const*, llvm::ArrayRef<clang::Expr const*>, clang::SourceLocation)::'lambda'(clang::DiagnoseIfAttr const*)&&) (.constprop.0) SemaOverload.cpp:0:0 #12 0x000057a3b0f6fd6a clang::Sema::diagnoseArgDependentDiagnoseIfAttrs(clang::FunctionDecl const*, clang::Expr const*, llvm::ArrayRef<clang::Expr const*>, clang::SourceLocation) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x675fd6a) #13 0x000057a3b0989d4a clang::Sema::checkCall(clang::NamedDecl*, clang::FunctionProtoType const*, clang::Expr const*, llvm::ArrayRef<clang::Expr const*>, bool, clang::SourceLocation, clang::SourceRange, clang::Sema::VariadicCallType) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x6179d4a) #14 0x000057a3b098b6ed clang::Sema::CheckConstructorCall(clang::FunctionDecl*, clang::QualType, llvm::ArrayRef<clang::Expr const*>, clang::FunctionProtoType const*, clang::SourceLocation) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x617b6ed) #15 0x000057a3b0b1730e clang::Sema::CompleteConstructorCall(clang::CXXConstructorDecl*, clang::QualType, llvm::MutableArrayRef<clang::Expr*>, clang::SourceLocation, llvm::SmallVectorImpl<clang::Expr*>&, bool, bool) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x630730e) #16 0x000057a3b0dd7918 PerformConstructorInitialization(clang::Sema&, clang::InitializedEntity const&, clang::InitializationKind const&, llvm::MutableArrayRef<clang::Expr*>, clang::InitializationSequence::Step const&, bool&, bool, bool, clang::SourceLocation, clang::SourceLocation) SemaInit.cpp:0:0 #17 0x000057a3b0df1164 clang::InitializationSequence::Perform(clang::Sema&, clang::InitializedEntity const&, clang::InitializationKind const&, llvm::MutableArrayRef<clang::Expr*>, clang::QualType*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x65e1164) #18 0x000057a3b0d0d03d clang::Sema::BuildCXXTypeConstructExpr(clang::TypeSourceInfo*, clang::SourceLocation, llvm::MutableArrayRef<clang::Expr*>, clang::SourceLocation, bool) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x64fd03d) #19 0x000057a3b0d945d2 clang::Sema::ActOnCXXTypeConstructExpr(clang::OpaquePtr<clang::QualType>, clang::SourceLocation, llvm::MutableArrayRef<clang::Expr*>, clang::SourceLocation, bool) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x65845d2) #20 0x000057a3b08187e8 clang::Parser::ParseCXXTypeConstructExpression(clang::DeclSpec const&) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x60087e8) #21 0x000057a3b080822b clang::Parser::ParseCastExpression(clang::Parser::CastParseKind, bool, bool&, clang::Parser::TypeCastState, bool, bool*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5ff822b) #22 0x000057a3b080995b clang::Parser::ParseCastExpression(clang::Parser::CastParseKind, bool, clang::Parser::TypeCastState, bool, bool*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5ff995b) #23 0x000057a3b08099fd clang::Parser::ParseAssignmentExpression(clang::Parser::TypeCastState) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5ff99fd) #24 0x000057a3b080cf5d clang::Parser::ParseExpression(clang::Parser::TypeCastState) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5ffcf5d) #25 0x000057a3b087a17e clang::Parser::ParseExprStatement(clang::Parser::ParsedStmtContext) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x606a17e) #26 0x000057a3b0871192 clang::Parser::ParseStatementOrDeclarationAfterAttributes(llvm::SmallVector<clang::Stmt*, 32u>&, clang::Parser::ParsedStmtContext, clang::SourceLocation*, clang::ParsedAttributesWithRange&) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x6061192) #27 0x000057a3b0871c1a clang::Parser::ParseStatementOrDeclaration(llvm::SmallVector<clang::Stmt*, 32u>&, clang::Parser::ParsedStmtContext, clang::SourceLocation*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x6061c1a) #28 0x000057a3b0872a91 clang::Parser::ParseCompoundStatementBody(bool) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x6062a91) #29 0x000057a3b087543a clang::Parser::ParseFunctionStatementBody(clang::Decl*, clang::Parser::ParseScope&) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x606543a) #30 0x000057a3b07b4c92 clang::Parser::ParseFunctionDefinition(clang::ParsingDeclarator&, clang::Parser::ParsedTemplateInfo const&, clang::Parser::LateParsedAttrList*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5fa4c92) #31 0x000057a3b07e2130 clang::Parser::ParseDeclGroup(clang::ParsingDeclSpec&, clang::DeclaratorContext, clang::SourceLocation*, clang::Parser::ForRangeInit*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5fd2130) #32 0x000057a3b07af496 clang::Parser::ParseDeclOrFunctionDefInternal(clang::ParsedAttributesWithRange&, clang::ParsingDeclSpec&, clang::AccessSpecifier) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5f9f496) #33 0x000057a3b07afa81 clang::Parser::ParseDeclarationOrFunctionDefinition(clang::ParsedAttributesWithRange&, clang::ParsingDeclSpec*, clang::AccessSpecifier) (.part.0) Parser.cpp:0:0 #34 0x000057a3b07b687c clang::Parser::ParseExternalDeclaration(clang::ParsedAttributesWithRange&, clang::ParsingDeclSpec*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5fa687c) #35 0x000057a3b07b781e clang::Parser::ParseTopLevelDecl(clang::OpaquePtr<clang::DeclGroupRef>&, bool) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5fa781e) #36 0x000057a3b07aa059 clang::ParseAST(clang::Sema&, bool, bool) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x5f9a059) #37 0x000057a3af68fe98 clang::CodeGenAction::ExecuteAction() (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x4e7fe98) #38 0x000057a3aef6a5f9 clang::FrontendAction::Execute() (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x475a5f9) #39 0x000057a3aeef786e clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x46e786e) #40 0x000057a3af0470b3 clang::ExecuteCompilerInvocation(clang::CompilerInstance*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x48370b3) #41 0x000057a3abaef01a cc1_main(llvm::ArrayRef<char const*>, char const*, void*) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x12df01a) #42 0x000057a3abaeb3c8 ExecuteCC1Tool(llvm::SmallVectorImpl<char const*>&) driver.cpp:0:0 #43 0x000057a3aed777e9 void llvm::function_ref<void ()>::callback_fn<clang::driver::CC1Command::Execute(llvm::ArrayRef<llvm::Optional<llvm::StringRef> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >*, bool*) const::'lambda'()>(long) Job.cpp:0:0 #44 0x000057a3ae3dd27c llvm::CrashRecoveryContext::RunSafely(llvm::function_ref<void ()>) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x3bcd27c) #45 0x000057a3aed77eff clang::driver::CC1Command::Execute(llvm::ArrayRef<llvm::Optional<llvm::StringRef> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >*, bool*) const (.part.0) Job.cpp:0:0 #46 0x000057a3aed46fab clang::driver::Compilation::ExecuteCommand(clang::driver::Command const&, clang::driver::Command const*&) const (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x4536fab) #47 0x000057a3aed47ab9 clang::driver::Compilation::ExecuteJobs(clang::driver::JobList const&, llvm::SmallVectorImpl<std::pair<int, clang::driver::Command const*> >&) const (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x4537ab9) #48 0x000057a3aed51a89 clang::driver::Driver::ExecuteCompilation(clang::driver::Compilation&, llvm::SmallVectorImpl<std::pair<int, clang::driver::Command const*> >&) (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x4541a89) #49 0x000057a3aba103aa main (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x12003aa) #50 0x00007f77cfc29d90 (/lib/x86_64-linux-gnu/libc.so.6+0x29d90) #51 0x00007f77cfc29e40 __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x29e40) #52 0x000057a3abaeaf3e _start (/opt/compiler-explorer/clang-assertions-14.0.0/bin/clang+++0x12daf3e) clang-14: error: clang frontend command failed with exit code 134 (use -v to see invocation) Compiler returned: 134 ```