s/MethodType/FunctionType

llvm-svn: 2115
diff --git a/llvm/lib/Target/Sparc/SparcInstrSelection.cpp b/llvm/lib/Target/Sparc/SparcInstrSelection.cpp
index 18b4a0a..7b6e597 100644
--- a/llvm/lib/Target/Sparc/SparcInstrSelection.cpp
+++ b/llvm/lib/Target/Sparc/SparcInstrSelection.cpp
@@ -327,9 +327,9 @@
   MachineOpCode opCode = INVALID_OPCODE;
   
   if (resultType->isIntegral() ||
-      resultType->isPointerType() ||
-      resultType->isLabelType() ||
-      isa<MethodType>(resultType) ||
+      isa<PointerType>(resultType) ||
+      isa<FunctionType>(resultType) ||
+      resultType == Type::LabelTy ||
       resultType == Type::BoolTy)
     {
       opCode = ADD;
diff --git a/llvm/lib/Target/Sparc/SparcRegInfo.cpp b/llvm/lib/Target/Sparc/SparcRegInfo.cpp
index 434816e..8ec2399 100644
--- a/llvm/lib/Target/Sparc/SparcRegInfo.cpp
+++ b/llvm/lib/Target/Sparc/SparcRegInfo.cpp
@@ -264,10 +264,8 @@
   const MachineOperand & calleeOp = CallMI->getOperand(0);
   Value *calleeVal =  calleeOp.getVRegValue();
 
-  PointerType *PT =  cast<PointerType> (calleeVal->getType());
-  MethodType  *MT = cast<MethodType>(PT->getElementType());
-
-  return MT->isVarArg();
+  PointerType *PT =  cast<PointerType>(calleeVal->getType());
+  return cast<FunctionType>(PT->getElementType())->isVarArg();
 }