diff options
-rw-r--r-- | llvm/lib/CodeGen/DwarfEHPrepare.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/llvm/lib/CodeGen/DwarfEHPrepare.cpp b/llvm/lib/CodeGen/DwarfEHPrepare.cpp index 6a53e693370..873ddd20b8c 100644 --- a/llvm/lib/CodeGen/DwarfEHPrepare.cpp +++ b/llvm/lib/CodeGen/DwarfEHPrepare.cpp @@ -532,13 +532,14 @@ bool DwarfEHPrepare::LowerUnwindsAndResumes() { if (isa<UnwindInst>(RI)) new UnreachableInst(RI->getContext(), RI); - // Nuke the resume instruction. - RI->eraseFromParent(); - if (isa<UnwindInst>(RI)) ++NumUnwindsLowered; else ++NumResumesLowered; + + // Nuke the resume instruction. + RI->eraseFromParent(); + Changed = true; } |