Inliner crashes in ValueHandleBase::ValueIsDeleted
| Bugzilla Link | 26865 |
| Resolution | FIXED |
| Resolved on | Jun 20, 2017 08:28 |
| Version | trunk |
| OS | Linux |
| Attachments | Reduced reproducer |
| CC | @hfinkel,@uabjean |
Extended Description
The attached file crashes opt like this:
opt -S -globals-aa -jump-threading -inline -o /dev/null bugpoint-reduced-simplified.ll -debug-pass=Arguments
Pass Arguments: -targetlibinfo -tti -assumption-cache-tracker -basiccg -globals-aa -lazy-value-info -jump-threading -basiccg -inline -verify -print-module
While deleting: i16 (i16, i16, i16)* %check_i An asserting value handle still pointed to this value! UNREACHABLE executed at ../lib/IR/Value.cpp:740! 0 opt 0x00000000023cec4e llvm::sys::PrintStackTrace(llvm::raw_ostream&) + 46 1 opt 0x00000000023cf059 2 opt 0x00000000023cd963 llvm::sys::RunSignalHandlers() + 131 3 opt 0x00000000023cf49f 4 libpthread.so.0 0x00007ff74739e340 5 libc.so.6 0x00007ff7465c6cc9 gsignal + 57 6 libc.so.6 0x00007ff7465ca0d8 abort + 328 7 opt 0x0000000002351a86 8 opt 0x0000000001e36baa llvm::ValueHandleBase::ValueIsDeleted(llvm::Value*) + 714 9 opt 0x0000000001e3674c llvm::Value::~Value() + 60 10 opt 0x0000000001ce3225 11 opt 0x0000000001ce2ea5 12 opt 0x0000000001d7e95b 13 opt 0x0000000001d7d371 14 opt 0x0000000001d773f8 llvm::Function::~Function() + 152 15 opt 0x0000000001d775a9 llvm::Function::~Function() + 25 16 opt 0x0000000001ed0d5a llvm::Inliner::runOnSCC(llvm::CallGraphSCC&) + 5418 17 opt 0x0000000001ece297 18 opt 0x0000000001726d56 19 opt 0x00000000017267ec 20 opt 0x000000000172612b 21 opt 0x0000000001dcf3d1 22 opt 0x0000000001dceecb llvm::legacy::PassManagerImpl::run(llvm::Module&) + 347 23 opt 0x0000000001dcf911 llvm::legacy::PassManager::run(llvm::Module&) + 33 24 opt 0x000000000092226c main + 8588 25 libc.so.6 0x00007ff7465b1ec5 __libc_start_main + 245 26 opt 0x00000000008f6578 Stack dump: 0. Program arguments: build-master/bin/opt -S -globals-aa -jump-threading -inline -o /dev/null bugpoint-reduced-simplified.ll -debug-pass=Arguments
-
Running pass 'CallGraph Pass Manager' on module 'bugpoint-reduced-simplified.ll'.
Aborted
check_i is the name of the function that was inlined at the only call. When the inliner tries to delete it it crashes.
This problem was fixed or went into hiding after commit 55856262329: [PH] Replace uses of AssertingVH from members of analysis results with a lazy-asserting PoisoningVH.
I think the core issue remains, but I'm closing this issue.