Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash on usage incomplete type with __is_trivially_destructible #114802

Open
JVApen opened this issue Nov 4, 2024 · 3 comments
Open

Crash on usage incomplete type with __is_trivially_destructible #114802

JVApen opened this issue Nov 4, 2024 · 3 comments
Labels
clang:frontend Language frontend issues, e.g. anything involving "Sema" confirmed Verified by a second party crash Prefer [crash-on-valid] or [crash-on-invalid] regression:15 Regression in 15 release

Comments

@JVApen
Copy link

JVApen commented Nov 4, 2024

This problem was found while using clangd and was reduced from std::optional in the MSVC STL.
Problem was discovered on LLVM 16, though is reproducible on LLVM trunk.

class IncompleteType;

template<bool b>
struct ForceCalculate
{
   using type = IncompleteType;
};

template<typename t>
struct RequiresCompleteType
{
   static constexpr bool value = __is_trivially_destructible(t);
};

template<typename t>
using Base = typename ForceCalculate<RequiresCompleteType<t>::value>::type;

template<typename t>
struct Redirect : Base<t>
{
   using Base<t>::operator*;
};

void f(Redirect<IncompleteType> &a)
{
   *a;
}

Compiler-explorer link

Compiler output:

<source>:14:34: error: incomplete type 'IncompleteType' used in type trait expression
   14 |    static constexpr bool value = __is_trivially_destructible(t);
      |                                  ^
<source>:18:63: note: in instantiation of static data member 'RequiresCompleteType<IncompleteType>::value' requested here
   18 | using Base = typename ForceCalculate<RequiresCompleteType<t>::value>::type;
      |                                                               ^
<source>:21:19: note: in instantiation of template type alias 'Base' requested here
   21 | struct Redirect : Base<t>
      |                   ^
<source>:28:4: note: in instantiation of template class 'Redirect<IncompleteType>' requested here
   28 |    *a;
      |    ^
<source>:3:7: note: forward declaration of 'IncompleteType'
    3 | class IncompleteType;
      |       ^
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-trunk/bin/clang++ -gdwarf-4 -g -o /app/output.s -mllvm --x86-asm-syntax=intel -fno-verbose-asm -S --gcc-toolchain=/opt/compiler-explorer/gcc-snapshot -fcolor-diagnostics -fno-crash-diagnostics -std=c++20 <source>
1.	<source>:28:6: current parser token ';'
2.	<source>:27:1: parsing function body 'f'
3.	<source>:27:1: in compound statement ('{}')
 #0 0x0000000003988e88 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x3988e88)
 #1 0x0000000003986fd4 llvm::sys::CleanupOnSignal(unsigned long) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x3986fd4)
 #2 0x00000000038d7ac8 CrashRecoverySignalHandler(int) CrashRecoveryContext.cpp:0:0
 #3 0x00007f70c2642520 (/lib/x86_64-linux-gnu/libc.so.6+0x42520)
 #4 0x0000000000bb19a2 clang::Sema::AddMethodCandidate(clang::CXXMethodDecl*, clang::DeclAccessPair, clang::CXXRecordDecl*, clang::QualType, clang::Expr::Classification, llvm::ArrayRef<clang::Expr*>, clang::OverloadCandidateSet&, bool, bool, llvm::MutableArrayRef<clang::ImplicitConversionSequence>, clang::OverloadCandidateParamOrder) (.cold) SemaOverload.cpp:0:0
 #5 0x0000000006d8a571 clang::Sema::AddMethodCandidate(clang::DeclAccessPair, clang::QualType, clang::Expr::Classification, llvm::ArrayRef<clang::Expr*>, clang::OverloadCandidateSet&, bool, clang::OverloadCandidateParamOrder) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6d8a571)
 #6 0x0000000006d8a76a clang::Sema::AddMemberOperatorCandidates(clang::OverloadedOperatorKind, clang::SourceLocation, llvm::ArrayRef<clang::Expr*>, clang::OverloadCandidateSet&, clang::OverloadCandidateParamOrder) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6d8a76a)
 #7 0x0000000006d9523f clang::Sema::CreateOverloadedUnaryOp(clang::SourceLocation, clang::UnaryOperatorKind, clang::UnresolvedSetImpl const&, clang::Expr*, bool) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6d9523f)
 #8 0x000000000691db72 clang::Sema::BuildUnaryOp(clang::Scope*, clang::SourceLocation, clang::UnaryOperatorKind, clang::Expr*, bool) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x691db72)
 #9 0x000000000637f8ae clang::Parser::ParseCastExpression(clang::Parser::CastParseKind, bool, bool&, clang::Parser::TypeCastState, bool, bool*) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x637f8ae)
#10 0x00000000063813ba clang::Parser::ParseCastExpression(clang::Parser::CastParseKind, bool, clang::Parser::TypeCastState, bool, bool*) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x63813ba)
#11 0x0000000006381589 clang::Parser::ParseAssignmentExpression(clang::Parser::TypeCastState) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6381589)
#12 0x00000000063867d9 clang::Parser::ParseExpression(clang::Parser::TypeCastState) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x63867d9)
#13 0x0000000006411b67 clang::Parser::ParseExprStatement(clang::Parser::ParsedStmtContext) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6411b67)
#14 0x0000000006406111 clang::Parser::ParseStatementOrDeclarationAfterAttributes(llvm::SmallVector<clang::Stmt*, 32u>&, clang::Parser::ParsedStmtContext, clang::SourceLocation*, clang::ParsedAttributes&, clang::ParsedAttributes&) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6406111)
#15 0x0000000006406b8d clang::Parser::ParseStatementOrDeclaration(llvm::SmallVector<clang::Stmt*, 32u>&, clang::Parser::ParsedStmtContext, clang::SourceLocation*) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6406b8d)
#16 0x0000000006407ea4 clang::Parser::ParseCompoundStatementBody(bool) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6407ea4)
#17 0x000000000640a11a clang::Parser::ParseFunctionStatementBody(clang::Decl*, clang::Parser::ParseScope&) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x640a11a)
#18 0x0000000006306426 clang::Parser::ParseFunctionDefinition(clang::ParsingDeclarator&, clang::Parser::ParsedTemplateInfo const&, clang::Parser::LateParsedAttrList*) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6306426)
#19 0x000000000634ffcf clang::Parser::ParseDeclGroup(clang::ParsingDeclSpec&, clang::DeclaratorContext, clang::ParsedAttributes&, clang::Parser::ParsedTemplateInfo&, clang::SourceLocation*, clang::Parser::ForRangeInit*) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x634ffcf)
#20 0x00000000062fe9d7 clang::Parser::ParseDeclOrFunctionDefInternal(clang::ParsedAttributes&, clang::ParsedAttributes&, clang::ParsingDeclSpec&, clang::AccessSpecifier) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x62fe9d7)
#21 0x00000000062ff7f3 clang::Parser::ParseDeclarationOrFunctionDefinition(clang::ParsedAttributes&, clang::ParsedAttributes&, clang::ParsingDeclSpec*, clang::AccessSpecifier) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x62ff7f3)
#22 0x00000000063090e2 clang::Parser::ParseExternalDeclaration(clang::ParsedAttributes&, clang::ParsedAttributes&, clang::ParsingDeclSpec*) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x63090e2)
#23 0x000000000630a978 clang::Parser::ParseTopLevelDecl(clang::OpaquePtr<clang::DeclGroupRef>&, clang::Sema::ModuleImportState&) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x630a978)
#24 0x00000000062f904a clang::ParseAST(clang::Sema&, bool, bool) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x62f904a)
#25 0x00000000042d03a5 clang::CodeGenAction::ExecuteAction() (/opt/compiler-explorer/clang-trunk/bin/clang+++0x42d03a5)
#26 0x00000000045996e1 clang::FrontendAction::Execute() (/opt/compiler-explorer/clang-trunk/bin/clang+++0x45996e1)
#27 0x000000000451968b clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x451968b)
#28 0x000000000467db73 clang::ExecuteCompilerInvocation(clang::CompilerInstance*) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x467db73)
#29 0x0000000000cee39c cc1_main(llvm::ArrayRef<char const*>, char const*, void*) (/opt/compiler-explorer/clang-trunk/bin/clang+++0xcee39c)
#30 0x0000000000ce6dfd ExecuteCC1Tool(llvm::SmallVectorImpl<char const*>&, llvm::ToolContext const&) driver.cpp:0:0
#31 0x0000000004318289 void llvm::function_ref<void ()>::callback_fn<clang::driver::CC1Command::Execute(llvm::ArrayRef<std::optional<llvm::StringRef>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>*, bool*) const::'lambda'()>(long) Job.cpp:0:0
#32 0x00000000038d7ef3 llvm::CrashRecoveryContext::RunSafely(llvm::function_ref<void ()>) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x38d7ef3)
#33 0x00000000043184a9 clang::driver::CC1Command::Execute(llvm::ArrayRef<std::optional<llvm::StringRef>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>*, bool*) const (.part.0) Job.cpp:0:0
#34 0x00000000042dfd8d clang::driver::Compilation::ExecuteCommand(clang::driver::Command const&, clang::driver::Command const*&, bool) const (/opt/compiler-explorer/clang-trunk/bin/clang+++0x42dfd8d)
#35 0x00000000042e0d8d clang::driver::Compilation::ExecuteJobs(clang::driver::JobList const&, llvm::SmallVectorImpl<std::pair<int, clang::driver::Command const*>>&, bool) const (/opt/compiler-explorer/clang-trunk/bin/clang+++0x42e0d8d)
#36 0x00000000042ea33c clang::driver::Driver::ExecuteCompilation(clang::driver::Compilation&, llvm::SmallVectorImpl<std::pair<int, clang::driver::Command const*>>&) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x42ea33c)
#37 0x0000000000ceb0f1 clang_main(int, char**, llvm::ToolContext const&) (/opt/compiler-explorer/clang-trunk/bin/clang+++0xceb0f1)
#38 0x0000000000bbc204 main (/opt/compiler-explorer/clang-trunk/bin/clang+++0xbbc204)
#39 0x00007f70c2629d90 (/lib/x86_64-linux-gnu/libc.so.6+0x29d90)
#40 0x00007f70c2629e40 __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x29e40)
#41 0x0000000000ce689e _start (/opt/compiler-explorer/clang-trunk/bin/clang+++0xce689e)
clang++: error: clang frontend command failed with exit code 139 (use -v to see invocation)
Compiler returned: 139
@EugeneZelenko EugeneZelenko added clang:frontend Language frontend issues, e.g. anything involving "Sema" crash Prefer [crash-on-valid] or [crash-on-invalid] and removed new issue labels Nov 4, 2024
@llvmbot
Copy link
Collaborator

llvmbot commented Nov 4, 2024

@llvm/issue-subscribers-clang-frontend

Author: None (JVApen)

This problem was found while using clangd and was reduced from `std::optional` in the MSVC STL. Problem was discovered on LLVM 16, though is reproducible on LLVM trunk.
class IncompleteType;

template&lt;bool b&gt;
struct ForceCalculate
{
   using type = IncompleteType;
};

template&lt;typename t&gt;
struct RequiresCompleteType
{
   static constexpr bool value = __is_trivially_destructible(t);
};

template&lt;typename t&gt;
using Base = typename ForceCalculate&lt;RequiresCompleteType&lt;t&gt;::value&gt;::type;

template&lt;typename t&gt;
struct Redirect : Base&lt;t&gt;
{
   using Base&lt;t&gt;::operator*;
};

void f(Redirect&lt;IncompleteType&gt; &amp;a)
{
   *a;
}

Compiler-explorer link

Compiler output:

&lt;source&gt;:14:34: error: incomplete type 'IncompleteType' used in type trait expression
   14 |    static constexpr bool value = __is_trivially_destructible(t);
      |                                  ^
&lt;source&gt;:18:63: note: in instantiation of static data member 'RequiresCompleteType&lt;IncompleteType&gt;::value' requested here
   18 | using Base = typename ForceCalculate&lt;RequiresCompleteType&lt;t&gt;::value&gt;::type;
      |                                                               ^
&lt;source&gt;:21:19: note: in instantiation of template type alias 'Base' requested here
   21 | struct Redirect : Base&lt;t&gt;
      |                   ^
&lt;source&gt;:28:4: note: in instantiation of template class 'Redirect&lt;IncompleteType&gt;' requested here
   28 |    *a;
      |    ^
&lt;source&gt;:3:7: note: forward declaration of 'IncompleteType'
    3 | class IncompleteType;
      |       ^
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-trunk/bin/clang++ -gdwarf-4 -g -o /app/output.s -mllvm --x86-asm-syntax=intel -fno-verbose-asm -S --gcc-toolchain=/opt/compiler-explorer/gcc-snapshot -fcolor-diagnostics -fno-crash-diagnostics -std=c++20 &lt;source&gt;
1.	&lt;source&gt;:28:6: current parser token ';'
2.	&lt;source&gt;:27:1: parsing function body 'f'
3.	&lt;source&gt;:27:1: in compound statement ('{}')
 #<!-- -->0 0x0000000003988e88 llvm::sys::PrintStackTrace(llvm::raw_ostream&amp;, int) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x3988e88)
 #<!-- -->1 0x0000000003986fd4 llvm::sys::CleanupOnSignal(unsigned long) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x3986fd4)
 #<!-- -->2 0x00000000038d7ac8 CrashRecoverySignalHandler(int) CrashRecoveryContext.cpp:0:0
 #<!-- -->3 0x00007f70c2642520 (/lib/x86_64-linux-gnu/libc.so.6+0x42520)
 #<!-- -->4 0x0000000000bb19a2 clang::Sema::AddMethodCandidate(clang::CXXMethodDecl*, clang::DeclAccessPair, clang::CXXRecordDecl*, clang::QualType, clang::Expr::Classification, llvm::ArrayRef&lt;clang::Expr*&gt;, clang::OverloadCandidateSet&amp;, bool, bool, llvm::MutableArrayRef&lt;clang::ImplicitConversionSequence&gt;, clang::OverloadCandidateParamOrder) (.cold) SemaOverload.cpp:0:0
 #<!-- -->5 0x0000000006d8a571 clang::Sema::AddMethodCandidate(clang::DeclAccessPair, clang::QualType, clang::Expr::Classification, llvm::ArrayRef&lt;clang::Expr*&gt;, clang::OverloadCandidateSet&amp;, bool, clang::OverloadCandidateParamOrder) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6d8a571)
 #<!-- -->6 0x0000000006d8a76a clang::Sema::AddMemberOperatorCandidates(clang::OverloadedOperatorKind, clang::SourceLocation, llvm::ArrayRef&lt;clang::Expr*&gt;, clang::OverloadCandidateSet&amp;, clang::OverloadCandidateParamOrder) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6d8a76a)
 #<!-- -->7 0x0000000006d9523f clang::Sema::CreateOverloadedUnaryOp(clang::SourceLocation, clang::UnaryOperatorKind, clang::UnresolvedSetImpl const&amp;, clang::Expr*, bool) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6d9523f)
 #<!-- -->8 0x000000000691db72 clang::Sema::BuildUnaryOp(clang::Scope*, clang::SourceLocation, clang::UnaryOperatorKind, clang::Expr*, bool) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x691db72)
 #<!-- -->9 0x000000000637f8ae clang::Parser::ParseCastExpression(clang::Parser::CastParseKind, bool, bool&amp;, clang::Parser::TypeCastState, bool, bool*) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x637f8ae)
#<!-- -->10 0x00000000063813ba clang::Parser::ParseCastExpression(clang::Parser::CastParseKind, bool, clang::Parser::TypeCastState, bool, bool*) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x63813ba)
#<!-- -->11 0x0000000006381589 clang::Parser::ParseAssignmentExpression(clang::Parser::TypeCastState) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6381589)
#<!-- -->12 0x00000000063867d9 clang::Parser::ParseExpression(clang::Parser::TypeCastState) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x63867d9)
#<!-- -->13 0x0000000006411b67 clang::Parser::ParseExprStatement(clang::Parser::ParsedStmtContext) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6411b67)
#<!-- -->14 0x0000000006406111 clang::Parser::ParseStatementOrDeclarationAfterAttributes(llvm::SmallVector&lt;clang::Stmt*, 32u&gt;&amp;, clang::Parser::ParsedStmtContext, clang::SourceLocation*, clang::ParsedAttributes&amp;, clang::ParsedAttributes&amp;) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6406111)
#<!-- -->15 0x0000000006406b8d clang::Parser::ParseStatementOrDeclaration(llvm::SmallVector&lt;clang::Stmt*, 32u&gt;&amp;, clang::Parser::ParsedStmtContext, clang::SourceLocation*) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6406b8d)
#<!-- -->16 0x0000000006407ea4 clang::Parser::ParseCompoundStatementBody(bool) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6407ea4)
#<!-- -->17 0x000000000640a11a clang::Parser::ParseFunctionStatementBody(clang::Decl*, clang::Parser::ParseScope&amp;) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x640a11a)
#<!-- -->18 0x0000000006306426 clang::Parser::ParseFunctionDefinition(clang::ParsingDeclarator&amp;, clang::Parser::ParsedTemplateInfo const&amp;, clang::Parser::LateParsedAttrList*) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x6306426)
#<!-- -->19 0x000000000634ffcf clang::Parser::ParseDeclGroup(clang::ParsingDeclSpec&amp;, clang::DeclaratorContext, clang::ParsedAttributes&amp;, clang::Parser::ParsedTemplateInfo&amp;, clang::SourceLocation*, clang::Parser::ForRangeInit*) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x634ffcf)
#<!-- -->20 0x00000000062fe9d7 clang::Parser::ParseDeclOrFunctionDefInternal(clang::ParsedAttributes&amp;, clang::ParsedAttributes&amp;, clang::ParsingDeclSpec&amp;, clang::AccessSpecifier) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x62fe9d7)
#<!-- -->21 0x00000000062ff7f3 clang::Parser::ParseDeclarationOrFunctionDefinition(clang::ParsedAttributes&amp;, clang::ParsedAttributes&amp;, clang::ParsingDeclSpec*, clang::AccessSpecifier) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x62ff7f3)
#<!-- -->22 0x00000000063090e2 clang::Parser::ParseExternalDeclaration(clang::ParsedAttributes&amp;, clang::ParsedAttributes&amp;, clang::ParsingDeclSpec*) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x63090e2)
#<!-- -->23 0x000000000630a978 clang::Parser::ParseTopLevelDecl(clang::OpaquePtr&lt;clang::DeclGroupRef&gt;&amp;, clang::Sema::ModuleImportState&amp;) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x630a978)
#<!-- -->24 0x00000000062f904a clang::ParseAST(clang::Sema&amp;, bool, bool) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x62f904a)
#<!-- -->25 0x00000000042d03a5 clang::CodeGenAction::ExecuteAction() (/opt/compiler-explorer/clang-trunk/bin/clang+++0x42d03a5)
#<!-- -->26 0x00000000045996e1 clang::FrontendAction::Execute() (/opt/compiler-explorer/clang-trunk/bin/clang+++0x45996e1)
#<!-- -->27 0x000000000451968b clang::CompilerInstance::ExecuteAction(clang::FrontendAction&amp;) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x451968b)
#<!-- -->28 0x000000000467db73 clang::ExecuteCompilerInvocation(clang::CompilerInstance*) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x467db73)
#<!-- -->29 0x0000000000cee39c cc1_main(llvm::ArrayRef&lt;char const*&gt;, char const*, void*) (/opt/compiler-explorer/clang-trunk/bin/clang+++0xcee39c)
#<!-- -->30 0x0000000000ce6dfd ExecuteCC1Tool(llvm::SmallVectorImpl&lt;char const*&gt;&amp;, llvm::ToolContext const&amp;) driver.cpp:0:0
#<!-- -->31 0x0000000004318289 void llvm::function_ref&lt;void ()&gt;::callback_fn&lt;clang::driver::CC1Command::Execute(llvm::ArrayRef&lt;std::optional&lt;llvm::StringRef&gt;&gt;, std::__cxx11::basic_string&lt;char, std::char_traits&lt;char&gt;, std::allocator&lt;char&gt;&gt;*, bool*) const::'lambda'()&gt;(long) Job.cpp:0:0
#<!-- -->32 0x00000000038d7ef3 llvm::CrashRecoveryContext::RunSafely(llvm::function_ref&lt;void ()&gt;) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x38d7ef3)
#<!-- -->33 0x00000000043184a9 clang::driver::CC1Command::Execute(llvm::ArrayRef&lt;std::optional&lt;llvm::StringRef&gt;&gt;, std::__cxx11::basic_string&lt;char, std::char_traits&lt;char&gt;, std::allocator&lt;char&gt;&gt;*, bool*) const (.part.0) Job.cpp:0:0
#<!-- -->34 0x00000000042dfd8d clang::driver::Compilation::ExecuteCommand(clang::driver::Command const&amp;, clang::driver::Command const*&amp;, bool) const (/opt/compiler-explorer/clang-trunk/bin/clang+++0x42dfd8d)
#<!-- -->35 0x00000000042e0d8d clang::driver::Compilation::ExecuteJobs(clang::driver::JobList const&amp;, llvm::SmallVectorImpl&lt;std::pair&lt;int, clang::driver::Command const*&gt;&gt;&amp;, bool) const (/opt/compiler-explorer/clang-trunk/bin/clang+++0x42e0d8d)
#<!-- -->36 0x00000000042ea33c clang::driver::Driver::ExecuteCompilation(clang::driver::Compilation&amp;, llvm::SmallVectorImpl&lt;std::pair&lt;int, clang::driver::Command const*&gt;&gt;&amp;) (/opt/compiler-explorer/clang-trunk/bin/clang+++0x42ea33c)
#<!-- -->37 0x0000000000ceb0f1 clang_main(int, char**, llvm::ToolContext const&amp;) (/opt/compiler-explorer/clang-trunk/bin/clang+++0xceb0f1)
#<!-- -->38 0x0000000000bbc204 main (/opt/compiler-explorer/clang-trunk/bin/clang+++0xbbc204)
#<!-- -->39 0x00007f70c2629d90 (/lib/x86_64-linux-gnu/libc.so.6+0x29d90)
#<!-- -->40 0x00007f70c2629e40 __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x29e40)
#<!-- -->41 0x0000000000ce689e _start (/opt/compiler-explorer/clang-trunk/bin/clang+++0xce689e)
clang++: error: clang frontend command failed with exit code 139 (use -v to see invocation)
Compiler returned: 139

@shafik
Copy link
Collaborator

shafik commented Nov 4, 2024

Looks like this goes back to clang-15: https://compiler-explorer.com/z/MxEhMn4ba

@shafik shafik added confirmed Verified by a second party regression:15 Regression in 15 release labels Nov 4, 2024
@shafik
Copy link
Collaborator

shafik commented Nov 5, 2024

CC @hokein git bisect points to ba6c71b as the cause of this regression

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clang:frontend Language frontend issues, e.g. anything involving "Sema" confirmed Verified by a second party crash Prefer [crash-on-valid] or [crash-on-invalid] regression:15 Regression in 15 release
Projects
None yet
Development

No branches or pull requests

4 participants