projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1d63d92
)
Fix SRETPromotion, it was generating functions without returns statements since
author
Matthijs Kooijman
<matthijs@stdin.nl>
Thu, 7 Aug 2008 15:58:09 +0000
(15:58 +0000)
committer
Matthijs Kooijman
<matthijs@stdin.nl>
Thu, 7 Aug 2008 15:58:09 +0000
(15:58 +0000)
r53941 (but this was not noticed due to the lack of a basic test for
SRETPromotion).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54467
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/Transforms/IPO/StructRetPromotion.cpp
patch
|
blob
|
history
diff --git
a/lib/Transforms/IPO/StructRetPromotion.cpp
b/lib/Transforms/IPO/StructRetPromotion.cpp
index 314d1b987119dd9de0eea6a3fa0f7e538e06fb94..ae6d55f06d0234c0ad25709afe7fdb814f44189b 100644
(file)
--- a/
lib/Transforms/IPO/StructRetPromotion.cpp
+++ b/
lib/Transforms/IPO/StructRetPromotion.cpp
@@
-121,7
+121,7
@@
bool SRETPromotion::PromoteReturn(CallGraphNode *CGN) {
++BI;
if (isa<ReturnInst>(I)) {
Value *NV = new LoadInst(TheAlloca, "mrv.ld", I);
- ReturnInst *NR = ReturnInst::Create(NV);
+ ReturnInst *NR = ReturnInst::Create(NV
, I
);
I->replaceAllUsesWith(NR);
I->eraseFromParent();
}