aboutsummaryrefslogtreecommitdiff
path: root/tools/llvm-upgrade/UpgradeParser.cpp.cvs
diff options
context:
space:
mode:
Diffstat (limited to 'tools/llvm-upgrade/UpgradeParser.cpp.cvs')
-rw-r--r--tools/llvm-upgrade/UpgradeParser.cpp.cvs12
1 files changed, 6 insertions, 6 deletions
diff --git a/tools/llvm-upgrade/UpgradeParser.cpp.cvs b/tools/llvm-upgrade/UpgradeParser.cpp.cvs
index 70ff399bbe..cee36df230 100644
--- a/tools/llvm-upgrade/UpgradeParser.cpp.cvs
+++ b/tools/llvm-upgrade/UpgradeParser.cpp.cvs
@@ -929,7 +929,7 @@ ResolveDefinitions(std::map<const Type*,ValueList> &LateResolvers,
if (const FunctionType *FTy =
dyn_cast<FunctionType>(PTy->getElementType()))
if (Function *OtherF =
- CurModule.CurrentModule->getNamedFunction(DID.getName()))
+ CurModule.CurrentModule->getFunction(DID.getName()))
if (FuncTysDifferOnlyBySRet(FTy,OtherF->getFunctionType())) {
V->replaceAllUsesWith(ConstantExpr::getBitCast(OtherF, PTy));
fixed = true;
@@ -1677,10 +1677,10 @@ Module* UpgradeAssembly(const std::string &infile, std::istream& in,
//Not all functions use vaarg, so make a second check for ObsoleteVarArgs
{
Function* F;
- if ((F = Result->getNamedFunction("llvm.va_start"))
+ if ((F = Result->getFunction("llvm.va_start"))
&& F->getFunctionType()->getNumParams() == 0)
ObsoleteVarArgs = true;
- if((F = Result->getNamedFunction("llvm.va_copy"))
+ if((F = Result->getFunction("llvm.va_copy"))
&& F->getFunctionType()->getNumParams() == 1)
ObsoleteVarArgs = true;
}
@@ -1691,7 +1691,7 @@ Module* UpgradeAssembly(const std::string &infile, std::istream& in,
}
if(ObsoleteVarArgs) {
- if(Function* F = Result->getNamedFunction("llvm.va_start")) {
+ if(Function* F = Result->getFunction("llvm.va_start")) {
if (F->arg_size() != 0) {
error("Obsolete va_start takes 0 argument");
return 0;
@@ -1720,7 +1720,7 @@ Module* UpgradeAssembly(const std::string &infile, std::istream& in,
Result->getFunctionList().erase(F);
}
- if(Function* F = Result->getNamedFunction("llvm.va_end")) {
+ if(Function* F = Result->getFunction("llvm.va_end")) {
if(F->arg_size() != 1) {
error("Obsolete va_end takes 1 argument");
return 0;
@@ -1746,7 +1746,7 @@ Module* UpgradeAssembly(const std::string &infile, std::istream& in,
Result->getFunctionList().erase(F);
}
- if(Function* F = Result->getNamedFunction("llvm.va_copy")) {
+ if(Function* F = Result->getFunction("llvm.va_copy")) {
if(F->arg_size() != 1) {
error("Obsolete va_copy takes 1 argument");
return 0;