mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-14 00:32:55 +00:00
Let SRETPromotion properly preserve the function name instead of (implicitly)
postfixing it with a number. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54468 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
a7bab2c81c
commit
7d942001fa
@ -228,7 +228,8 @@ Function *SRETPromotion::cloneFunctionBody(Function *F,
|
||||
}
|
||||
|
||||
FunctionType *NFTy = FunctionType::get(STy, Params, FTy->isVarArg());
|
||||
Function *NF = Function::Create(NFTy, F->getLinkage(), F->getName());
|
||||
Function *NF = Function::Create(NFTy, F->getLinkage());
|
||||
NF->takeName(F);
|
||||
NF->copyAttributesFrom(F);
|
||||
NF->setParamAttrs(PAListPtr::get(ParamAttrsVec.begin(), ParamAttrsVec.end()));
|
||||
F->getParent()->getFunctionList().insert(F, NF);
|
||||
|
Loading…
x
Reference in New Issue
Block a user