-
Notifications
You must be signed in to change notification settings - Fork 15.1k
Open
Labels
clang:codegenIR generation bugs: mangling, exceptions, etc.IR generation bugs: mangling, exceptions, etc.confirmedVerified by a second partyVerified by a second partycrashPrefer [crash-on-valid] or [crash-on-invalid]Prefer [crash-on-valid] or [crash-on-invalid]generated by fuzzer
Description
Compiler Explorer: https://godbolt.org/z/9fE8sP7PG
- It crashed on clang
Trunk - generated by fuzzer
Console:
typedef _Bool bool512 __attribute__((ext_vector_type(187553262)));
bool512 b;Assertion:
clang: /root/llvm-project/llvm/lib/IR/Type.cpp:321: static llvm::IntegerType* llvm::IntegerType::get(llvm::LLVMContext&, unsigned int): Assertion `NumBits <= MAX_INT_BITS && "bitwidth too large"' failed.Backtrace:
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-trunk/bin/clang -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 <source>
1. <eof> parser at end of file
#0 0x0000000004224288 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0x4224288)
#1 0x00000000042216b4 llvm::sys::CleanupOnSignal(unsigned long) (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0x42216b4)
#2 0x0000000004165908 CrashRecoverySignalHandler(int) CrashRecoveryContext.cpp:0:0
#3 0x000072a639c42520 (/lib/x86_64-linux-gnu/libc.so.6+0x42520)
#4 0x000072a639c969fc pthread_kill (/lib/x86_64-linux-gnu/libc.so.6+0x969fc)
#5 0x000072a639c42476 gsignal (/lib/x86_64-linux-gnu/libc.so.6+0x42476)
#6 0x000072a639c287f3 abort (/lib/x86_64-linux-gnu/libc.so.6+0x287f3)
#7 0x000072a639c2871b (/lib/x86_64-linux-gnu/libc.so.6+0x2871b)
#8 0x000072a639c39e96 (/lib/x86_64-linux-gnu/libc.so.6+0x39e96)
#9 0x0000000003b93fea llvm::IntegerType::get(llvm::LLVMContext&, unsigned int) (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0x3b93fea)
#10 0x00000000045db4a1 clang::CodeGen::CodeGenModule::EmitNullConstant(clang::QualType) (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0x45db4a1)
#11 0x00000000047da037 clang::CodeGen::CodeGenModule::EmitGlobalVarDefinition(clang::VarDecl const*, bool) (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0x47da037)
#12 0x00000000047dac03 clang::CodeGen::CodeGenModule::EmitTentativeDefinition(clang::VarDecl const*) (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0x47dac03)
#13 0x0000000006acc9a6 clang::Sema::ActOnEndOfTranslationUnit() (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0x6acc9a6)
#14 0x0000000006933ff5 clang::Parser::ParseTopLevelDecl(clang::OpaquePtr<clang::DeclGroupRef>&, clang::Sema::ModuleImportState&) (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0x6933ff5)
#15 0x00000000069155aa clang::ParseAST(clang::Sema&, bool, bool) (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0x69155aa)
#16 0x0000000004b6f288 clang::CodeGenAction::ExecuteAction() (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0x4b6f288)
#17 0x0000000004e5c665 clang::FrontendAction::Execute() (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0x4e5c665)
#18 0x0000000004ddd63e clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0x4ddd63e)
#19 0x0000000004f5369d clang::ExecuteCompilerInvocation(clang::CompilerInstance*) (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0x4f5369d)
#20 0x0000000000dcf7b0 cc1_main(llvm::ArrayRef<char const*>, char const*, void*) (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0xdcf7b0)
#21 0x0000000000dc631a ExecuteCC1Tool(llvm::SmallVectorImpl<char const*>&, llvm::ToolContext const&, llvm::IntrusiveRefCntPtr<llvm::vfs::FileSystem>) driver.cpp:0:0
#22 0x0000000000dc649d int llvm::function_ref<int (llvm::SmallVectorImpl<char const*>&)>::callback_fn<clang_main(int, char**, llvm::ToolContext const&)::'lambda'(llvm::SmallVectorImpl<char const*>&)>(long, llvm::SmallVectorImpl<char const*>&) driver.cpp:0:0
#23 0x0000000004bd8649 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
#24 0x0000000004165da4 llvm::CrashRecoveryContext::RunSafely(llvm::function_ref<void ()>) (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0x4165da4)
#25 0x0000000004bd8c5f 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
#26 0x0000000004b99d72 clang::driver::Compilation::ExecuteCommand(clang::driver::Command const&, clang::driver::Command const*&, bool) const (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0x4b99d72)
#27 0x0000000004b9ad1e clang::driver::Compilation::ExecuteJobs(clang::driver::JobList const&, llvm::SmallVectorImpl<std::pair<int, clang::driver::Command const*>>&, bool) const (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0x4b9ad1e)
#28 0x0000000004ba2455 clang::driver::Driver::ExecuteCompilation(clang::driver::Compilation&, llvm::SmallVectorImpl<std::pair<int, clang::driver::Command const*>>&) (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0x4ba2455)
#29 0x0000000000dcbcd9 clang_main(int, char**, llvm::ToolContext const&) (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0xdcbcd9)
#30 0x0000000000c7a954 main (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0xc7a954)
#31 0x000072a639c29d90 (/lib/x86_64-linux-gnu/libc.so.6+0x29d90)
#32 0x000072a639c29e40 __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x29e40)
#33 0x0000000000dc5db5 _start (/opt/compiler-explorer/clang-assertions-trunk/bin/clang+0xdc5db5)
clang: error: clang frontend command failed with exit code 134 (use -v to see invocation)
Compiler returned: 134Code:
typedef _Bool bool512 __attribute__((ext_vector_type(187553262)));
bool512 b;Metadata
Metadata
Assignees
Labels
clang:codegenIR generation bugs: mangling, exceptions, etc.IR generation bugs: mangling, exceptions, etc.confirmedVerified by a second partyVerified by a second partycrashPrefer [crash-on-valid] or [crash-on-invalid]Prefer [crash-on-valid] or [crash-on-invalid]generated by fuzzer