Closed llvmbot closed 2 years ago
mentioned in issue llvm/llvm-bugzilla-archive#36604
Fixed in r326404.
Here is the proposed fix: https://reviews.llvm.org/D43695
Minimal LLVM IR file Minimal test case
Looks like SSCP is a culprit again:
BISECT: running pass (8) Interprocedural Sparse Conditional Constant Propagation on module (./test/tmp/otherwise-skip.ll)
...
musttail call result must be returned ret i8 bitcast (i8 (i8, i8, i32) @llparse__n_start to i8) musttail call result must be returned ret i8 bitcast (i8 (i8, i8, i32) @llparse__n_start to i8)
Here goes Debug build assertion:
Assertion failed: (i_nocapture < OperandTraits
PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:
Preprocessed source(s) and associated run script(s) are located at:
clang-7.0: note: diagnostic msg: /var/folders/7l/34nn743x7hv3pwhp4pjplxxc3kfgkf/T/fixture-e9643f.c
clang-7.0: note: diagnostic msg: /var/folders/7l/34nn743x7hv3pwhp4pjplxxc3kfgkf/T/extra-fad3b8.c
clang-7.0: note: diagnostic msg: /var/folders/7l/34nn743x7hv3pwhp4pjplxxc3kfgkf/T/fixture-e9643f.sh
clang-7.0: note: diagnostic msg: Crash backtrace is located in
clang-7.0: note: diagnostic msg: /Users/findutnyy/Library/Logs/DiagnosticReports/clang-7.0
Going to take a look at it myself. Any hints are welcome!
Extended Description
0 clang-5.0 0x00000001075c31e7 llvm::sys::PrintStackTrace(llvm::raw_ostream&) + 37 1 clang-5.0 0x00000001075c26ea llvm::sys::RunSignalHandlers() + 83 2 clang-5.0 0x00000001075c360e SignalHandler(int) + 239 3 libsystem_platform.dylib 0x00007fff784cef5a _sigtramp + 26 4 libsystem_platform.dylib 000000000000000000 _sigtramp + 2276659392 5 clang-5.0 0x0000000107553049 getCommonReturnValue(llvm::ReturnInst, llvm::CallInst) + 120 6 clang-5.0 0x000000010755280a eliminateRecursiveTailCall(llvm::CallInst, llvm::ReturnInst, llvm::BasicBlock&, bool&, llvm::SmallVectorImpl<llvm::PHINode>&, llvm::AAResults) + 735 7 clang-5.0 0x00000001075517b6 eliminateTailRecursion(llvm::Function&, llvm::TargetTransformInfo const, llvm::AAResults) + 2287 8 clang-5.0 0x000000010729c2b4 llvm::FPPassManager::runOnFunction(llvm::Function&) + 276 9 clang-5.0 0x0000000106f7cb71 (anonymous namespace)::CGPassManager::runOnModule(llvm::Module&) + 661 10 clang-5.0 0x000000010729c7a5 llvm::legacy::PassManagerImpl::run(llvm::Module&) + 579 11 clang-5.0 0x00000001076e9df8 clang::EmitBackendOutput(clang::DiagnosticsEngine&, clang::HeaderSearchOptions const&, clang::CodeGenOptions const&, clang::TargetOptions const&, clang::LangOptions const&, llvm::DataLayout const&, llvm::Module, clang::BackendAction, std::__1::unique_ptr<llvm::raw_pwrite_stream, std::__1::default_delete >) + 9714
12 clang-5.0 0x000000010781fe97 clang::CodeGenAction::ExecuteAction() + 973
13 clang-5.0 0x00000001079986db clang::FrontendAction::Execute() + 73
14 clang-5.0 0x000000010796980b clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) + 625
15 clang-5.0 0x00000001079c5a66 clang::ExecuteCompilerInvocation(clang::CompilerInstance) + 2438
16 clang-5.0 0x00000001066f0411 cc1_main(llvm::ArrayRef<char const>, char const, void) + 1169
17 clang-5.0 0x00000001066eee70 main + 8127
18 libdyld.dylib 0x00007fff7824e145 start + 1
19 libdyld.dylib 0x0000000000000033 start + 2279284463
Stack dump: