mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-01 08:28:19 +00:00
Getting ADCE to interact well with unreachable instructions seems like a nontrivial
exercise that I'm not interested in tackling right now. Just punt and treat them like unwind's. This 'fixes' test/Regression/Transforms/ADCE/unreachable-function.ll llvm-svn: 17106
This commit is contained in:
parent
215d4c9d22
commit
44a7cf480d
@ -233,8 +233,9 @@ bool ADCE::doADCE() {
|
||||
markInstructionLive(I);
|
||||
}
|
||||
} else if (I->mayWriteToMemory() || isa<ReturnInst>(I) ||
|
||||
isa<UnwindInst>(I)) {
|
||||
// Unreachable instructions are not marked intrinsically live here.
|
||||
isa<UnwindInst>(I) || isa<UnreachableInst>(I)) {
|
||||
// FIXME: Unreachable instructions should not be marked intrinsically
|
||||
// live here.
|
||||
markInstructionLive(I);
|
||||
} else if (isInstructionTriviallyDead(I)) {
|
||||
// Remove the instruction from it's basic block...
|
||||
|
Loading…
Reference in New Issue
Block a user