diff options
author | Chris Lattner <sabre@nondot.org> | 2007-01-25 17:38:26 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2007-01-25 17:38:26 +0000 |
commit | 338305b0b6ce21ad2ef0c883afe78d42b4b2911d (patch) | |
tree | 6a8defdd6b8c83745ebeaf8ff415cbfbf0229b91 /lib/Transforms/IPO/ExtractFunction.cpp | |
parent | 1a4a83ca394868b57ad884fc5ddd38d05a66092a (diff) |
Make llvm-extract preserve the callingconv of prototypes in the extracted
code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33500 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/IPO/ExtractFunction.cpp')
-rw-r--r-- | lib/Transforms/IPO/ExtractFunction.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/Transforms/IPO/ExtractFunction.cpp b/lib/Transforms/IPO/ExtractFunction.cpp index 69d0926fb6..a871c4d7f2 100644 --- a/lib/Transforms/IPO/ExtractFunction.cpp +++ b/lib/Transforms/IPO/ExtractFunction.cpp @@ -70,6 +70,7 @@ namespace { Function *New = new Function(I->getFunctionType(), GlobalValue::ExternalLinkage, I->getName()); + New->setCallingConv(I->getCallingConv()); I->setName(""); // Remove Old name // If it's not the named function, delete the body of the function |