summaryrefslogtreecommitdiff
path: root/lib/CodeGen/SjLjEHPrepare.cpp
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2011-08-23 22:55:03 +0000
committerBill Wendling <isanbard@gmail.com>2011-08-23 22:55:03 +0000
commitfc8713ff74c2ed83d453057b24c578a0709fc180 (patch)
tree9532bee5afefd8a7b371b097a814c8d9ce84c468 /lib/CodeGen/SjLjEHPrepare.cpp
parentcfcccef926bd142c885dfa3f506bff933939350c (diff)
downloadllvm-fc8713ff74c2ed83d453057b24c578a0709fc180.tar.gz
llvm-fc8713ff74c2ed83d453057b24c578a0709fc180.tar.bz2
llvm-fc8713ff74c2ed83d453057b24c578a0709fc180.tar.xz
Don't replace *all* uses with the new stuff.
This is not necessarily the first or dominating use of the EH values. The IR breaks if it's not. So replace the specific value in the instruction with the new value. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138406 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/SjLjEHPrepare.cpp')
-rw-r--r--lib/CodeGen/SjLjEHPrepare.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/CodeGen/SjLjEHPrepare.cpp b/lib/CodeGen/SjLjEHPrepare.cpp
index 02c1049385..be491b1383 100644
--- a/lib/CodeGen/SjLjEHPrepare.cpp
+++ b/lib/CodeGen/SjLjEHPrepare.cpp
@@ -347,7 +347,7 @@ static void ReplaceLandingPadVal(Function &F, Instruction *Inst, Value *ExnAddr,
continue;
}
- Inst->replaceAllUsesWith(CreateLandingPadLoad(F, ExnAddr, SelAddr, I));
+ I->replaceUsesOfWith(Inst, CreateLandingPadLoad(F, ExnAddr, SelAddr, I));
}
}