https://llvm.org/bugs/show_bug.cgi?id=25299
Bug ID: 25299 Summary: Assertion failure: use_empty() && "Uses remain when a value is destroyed!" Product: libraries Version: trunk Hardware: PC OS: All Status: NEW Severity: normal Priority: P Component: Scalar Optimizations Assignee: unassignedb...@nondot.org Reporter: a...@crichton.co CC: llvm-bugs@lists.llvm.org Classification: Unclassified When running `opt -O2` over the bytecode attached here, this assertion is generated: While deleting: { i8*, i32 } % Use still stuck around after Def is destroyed: %eh.lpad-body = phi { i8*, i32 } [ <badref>, %next.i.i.i.i ], [ <badref>, %unwind_custom_.i.i ], [ %20, %next.i.i.i.18.i ], [ %20, %"_ZN41collections..vec..Vec$LT$ast..TyParam$GT$10drop.5810217h641412e555c9adeeE.exit.i" ], [ %20, %"_ZN41collections..vec..Vec$LT$ast..TyParam$GT$10drop.5810217h641412e555c9adeeE.exit.i" ], [ %20, %clean_custom_.i ] Use still stuck around after Def is destroyed: %eh.lpad-body = phi { i8*, i32 } [ <badref>, %next.i.i.i.i ], [ <badref>, %unwind_custom_.i.i ], [ %20, %next.i.i.i.18.i ], [ %20, %"_ZN41collections..vec..Vec$LT$ast..TyParam$GT$10drop.5810217h641412e555c9adeeE.exit.i" ], [ %20, %"_ZN41collections..vec..Vec$LT$ast..TyParam$GT$10drop.5810217h641412e555c9adeeE.exit.i" ], [ %20, %clean_custom_.i ] opt: ../../../../src/llvm/lib/IR/Value.cpp:82: virtual llvm::Value::~Value(): Assertion `use_empty() && "Uses remain when a value is destroyed!"' failed. Program received signal SIGABRT, Aborted. 0x00007ffff6e09cc9 in __GI_raise (sig=sig@entry=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:56 56 ../nptl/sysdeps/unix/sysv/linux/raise.c: No such file or directory. (gdb) bt #0 0x00007ffff6e09cc9 in __GI_raise (sig=sig@entry=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:56 #1 0x00007ffff6e0d0d8 in __GI_abort () at abort.c:89 #2 0x00007ffff6e02b86 in __assert_fail_base (fmt=0x7ffff6f53830 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=assertion@entry=0x18ae888 "use_empty() && \"Uses remain when a value is destroyed!\"", file=file@entry=0x18ae0a8 "../../../../src/llvm/lib/IR/Value.cpp", line=line@entry=82, function=function@entry=0x21a3cc0 <llvm::Value::~Value()::__PRETTY_FUNCTION__> "virtual llvm::Value::~Value()") at assert.c:92 #3 0x00007ffff6e02c32 in __GI___assert_fail (assertion=0x18ae888 "use_empty() && \"Uses remain when a value is destroyed!\"", file=0x18ae0a8 "../../../../src/llvm/lib/IR/Value.cpp", line=82, function=0x21a3cc0 <llvm::Value::~Value()::__PRETTY_FUNCTION__> "virtual llvm::Value::~Value()") at assert.c:101 #4 0x000000000170eb9f in llvm::Value::~Value() () #5 0x00000000016c0a87 in llvm::LandingPadInst::~LandingPadInst() () #6 0x00000000015c87dc in llvm::BasicBlock::~BasicBlock() () #7 0x00000000015c8909 in llvm::BasicBlock::~BasicBlock() () #8 0x00000000015c6fd2 in llvm::BasicBlock::eraseFromParent() () #9 0x0000000001337685 in (anonymous namespace)::SimplifyCFGOpt::SimplifyResume(llvm::ResumeInst*, llvm::IRBuilder<true, llvm::ConstantFolder, llvm::IRBuilderDefaultInserter<true> >&) [clone .isra.757] () #10 0x0000000001341bc3 in llvm::SimplifyCFG(llvm::BasicBlock*, llvm::TargetTransformInfo const&, unsigned int, llvm::AssumptionCache*) () #11 0x00000000011e417a in simplifyFunctionCFG(llvm::Function&, llvm::TargetTransformInfo const&, llvm::AssumptionCache*, int) () #12 0x00000000016e6bc3 in llvm::FPPassManager::runOnFunction(llvm::Function&) () #13 0x00000000013fd3c0 in (anonymous namespace)::CGPassManager::runOnModule(llvm::Module&) () #14 0x00000000016e728f in llvm::legacy::PassManagerImpl::run(llvm::Module&) () #15 0x0000000000604082 in main () We ended up finding this when trying to upgrade from LLVM 3.7 to the current trunk, and I tried running bugpoint over the bytecode but it unfortunately didn't do too well about minimizing it. If you need any more info though please just let me know! -- You are receiving this mail because: You are on the CC list for the bug.
_______________________________________________ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs