Author: baldrick Date: Wed Nov 28 11:07:01 2007 New Revision: 44403 URL: http://llvm.org/viewvc/llvm-project?rev=44403&view=rev Log: Add some convenience methods for querying attributes, and use them.
Modified: llvm/trunk/include/llvm/Function.h llvm/trunk/include/llvm/Instructions.h llvm/trunk/include/llvm/Support/CallSite.h llvm/trunk/lib/Analysis/BasicAliasAnalysis.cpp llvm/trunk/lib/AsmParser/llvmAsmParser.cpp.cvs llvm/trunk/lib/AsmParser/llvmAsmParser.y.cvs llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp llvm/trunk/lib/ExecutionEngine/Interpreter/Execution.cpp llvm/trunk/lib/Target/MSIL/MSILWriter.cpp llvm/trunk/lib/Transforms/Scalar/SimplifyCFG.cpp llvm/trunk/lib/VMCore/Function.cpp llvm/trunk/lib/VMCore/Instructions.cpp llvm/trunk/test/Transforms/SimplifyCFG/2007-11-22-InvokeNoUnwind.ll llvm/trunk/tools/llvm-upgrade/UpgradeParser.cpp.cvs llvm/trunk/tools/llvm-upgrade/UpgradeParser.y.cvs Modified: llvm/trunk/include/llvm/Function.h URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Function.h?rev=44403&r1=44402&r2=44403&view=diff ============================================================================== --- llvm/trunk/include/llvm/Function.h (original) +++ llvm/trunk/include/llvm/Function.h Wed Nov 28 11:07:01 2007 @@ -21,6 +21,7 @@ #include "llvm/GlobalValue.h" #include "llvm/BasicBlock.h" #include "llvm/Argument.h" +#include "llvm/ParameterAttributes.h" #include "llvm/Support/Annotation.h" namespace llvm { @@ -152,8 +153,15 @@ /// @brief Set the parameter attributes. void setParamAttrs(const ParamAttrsList *attrs); + /// @brief Determine whether the function has the given attribute. + bool paramHasAttr(uint16_t i, ParameterAttributes attr) const { + return ParamAttrs && ParamAttrs->paramHasAttr(i, attr); + } + /// @brief Determine if the function returns a structure. - bool isStructReturn() const; + bool isStructReturn() const { + return paramHasAttr(1, ParamAttr::StructRet); + } /// deleteBody - This method deletes the body of the function, and converts /// the linkage to external. Modified: llvm/trunk/include/llvm/Instructions.h URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Instructions.h?rev=44403&r1=44402&r2=44403&view=diff ============================================================================== --- llvm/trunk/include/llvm/Instructions.h (original) +++ llvm/trunk/include/llvm/Instructions.h Wed Nov 28 11:07:01 2007 @@ -20,6 +20,7 @@ #include "llvm/InstrTypes.h" #include "llvm/DerivedTypes.h" +#include "llvm/ParameterAttributes.h" namespace llvm { @@ -923,8 +924,14 @@ /// @brief Set the parameter attributes. void setParamAttrs(const ParamAttrsList *attrs); + /// @brief Determine whether the call or the callee has the given attribute. + bool paramHasAttr(uint16_t i, ParameterAttributes attr) const; + /// @brief Determine if the call returns a structure. - bool isStructReturn() const; + bool isStructReturn() const { + // Be friendly and also check the callee. + return paramHasAttr(1, ParamAttr::StructRet); + } /// getCalledFunction - Return the function being called by this instruction /// if it is a direct call. If it is a call through a function pointer, @@ -1701,8 +1708,14 @@ /// @brief Set the parameter attributes. void setParamAttrs(const ParamAttrsList *attrs); + /// @brief Determine whether the call or the callee has the given attribute. + bool paramHasAttr(uint16_t i, ParameterAttributes attr) const; + /// @brief Determine if the call returns a structure. - bool isStructReturn() const; + bool isStructReturn() const { + // Be friendly and also check the callee. + return paramHasAttr(1, ParamAttr::StructRet); + } /// getCalledFunction - Return the function called, or null if this is an /// indirect function invocation. Modified: llvm/trunk/include/llvm/Support/CallSite.h URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/CallSite.h?rev=44403&r1=44402&r2=44403&view=diff ============================================================================== --- llvm/trunk/include/llvm/Support/CallSite.h (original) +++ llvm/trunk/include/llvm/Support/CallSite.h Wed Nov 28 11:07:01 2007 @@ -22,6 +22,7 @@ #include "llvm/Instruction.h" #include "llvm/BasicBlock.h" +#include "llvm/ParameterAttributes.h" namespace llvm { @@ -63,6 +64,9 @@ const ParamAttrsList *getParamAttrs() const; void setParamAttrs(const ParamAttrsList *PAL); + /// paramHasAttr - whether the call or the callee has the given attribute. + bool paramHasAttr(uint16_t i, ParameterAttributes attr) const; + /// getType - Return the type of the instruction that generated this call site /// const Type *getType() const { return I->getType(); } Modified: llvm/trunk/lib/Analysis/BasicAliasAnalysis.cpp URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Analysis/BasicAliasAnalysis.cpp?rev=44403&r1=44402&r2=44403&view=diff ============================================================================== --- llvm/trunk/lib/Analysis/BasicAliasAnalysis.cpp (original) +++ llvm/trunk/lib/Analysis/BasicAliasAnalysis.cpp Wed Nov 28 11:07:01 2007 @@ -839,10 +839,9 @@ return UnknownModRefBehavior; } - const ParamAttrsList *Attrs = F->getParamAttrs(); - if (Attrs && Attrs->paramHasAttr(0, ParamAttr::ReadNone)) + if (F->paramHasAttr(0, ParamAttr::ReadNone)) return DoesNotAccessMemory; - if (Attrs && Attrs->paramHasAttr(0, ParamAttr::ReadOnly)) + if (F->paramHasAttr(0, ParamAttr::ReadOnly)) return OnlyReadsMemory; return UnknownModRefBehavior; Modified: llvm/trunk/lib/AsmParser/llvmAsmParser.cpp.cvs URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/AsmParser/llvmAsmParser.cpp.cvs?rev=44403&r1=44402&r2=44403&view=diff ============================================================================== --- llvm/trunk/lib/AsmParser/llvmAsmParser.cpp.cvs (original) +++ llvm/trunk/lib/AsmParser/llvmAsmParser.cpp.cvs Wed Nov 28 11:07:01 2007 @@ -5161,7 +5161,7 @@ bool isVarArg = ParamTypeList.size() && ParamTypeList.back() == Type::VoidTy; if (isVarArg) ParamTypeList.pop_back(); - ParamAttrsList *PAL = 0; + const ParamAttrsList *PAL = 0; if (!Attrs.empty()) PAL = ParamAttrsList::get(Attrs); @@ -5664,7 +5664,7 @@ GEN_ERROR("Invalid number of parameters detected"); } - ParamAttrsList *PAL = 0; + const ParamAttrsList *PAL = 0; if (!Attrs.empty()) PAL = ParamAttrsList::get(Attrs); @@ -6094,7 +6094,7 @@ } // Finish off the ParamAttrs and check them - ParamAttrsList *PAL = 0; + const ParamAttrsList *PAL = 0; if (!Attrs.empty()) PAL = ParamAttrsList::get(Attrs); Modified: llvm/trunk/lib/AsmParser/llvmAsmParser.y.cvs URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/AsmParser/llvmAsmParser.y.cvs?rev=44403&r1=44402&r2=44403&view=diff ============================================================================== --- llvm/trunk/lib/AsmParser/llvmAsmParser.y.cvs (original) +++ llvm/trunk/lib/AsmParser/llvmAsmParser.y.cvs Wed Nov 28 11:07:01 2007 @@ -2243,7 +2243,7 @@ bool isVarArg = ParamTypeList.size() && ParamTypeList.back() == Type::VoidTy; if (isVarArg) ParamTypeList.pop_back(); - ParamAttrsList *PAL = 0; + const ParamAttrsList *PAL = 0; if (!Attrs.empty()) PAL = ParamAttrsList::get(Attrs); @@ -2645,7 +2645,7 @@ GEN_ERROR("Invalid number of parameters detected"); } - ParamAttrsList *PAL = 0; + const ParamAttrsList *PAL = 0; if (!Attrs.empty()) PAL = ParamAttrsList::get(Attrs); @@ -2977,7 +2977,7 @@ } // Finish off the ParamAttrs and check them - ParamAttrsList *PAL = 0; + const ParamAttrsList *PAL = 0; if (!Attrs.empty()) PAL = ParamAttrsList::get(Attrs); Modified: llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp?rev=44403&r1=44402&r2=44403&view=diff ============================================================================== --- llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp (original) +++ llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp Wed Nov 28 11:07:01 2007 @@ -934,11 +934,11 @@ TmpVT = TLI.getTypeToTransformTo(MVT::i32); else TmpVT = MVT::i32; - const ParamAttrsList *PAL = I.getParent()->getParent()->getParamAttrs(); + const Function *F = I.getParent()->getParent(); ISD::NodeType ExtendKind = ISD::ANY_EXTEND; - if (PAL && PAL->paramHasAttr(0, ParamAttr::SExt)) + if (F->paramHasAttr(0, ParamAttr::SExt)) ExtendKind = ISD::SIGN_EXTEND; - if (PAL && PAL->paramHasAttr(0, ParamAttr::ZExt)) + if (F->paramHasAttr(0, ParamAttr::ZExt)) ExtendKind = ISD::ZERO_EXTEND; RetOp = DAG.getNode(ExtendKind, TmpVT, RetOp); NewValues.push_back(RetOp); @@ -3892,7 +3892,6 @@ /// integrated into SDISel. std::vector<SDOperand> TargetLowering::LowerArguments(Function &F, SelectionDAG &DAG) { - const ParamAttrsList *Attrs = F.getParamAttrs(); // Add CC# and isVararg as operands to the FORMAL_ARGUMENTS node. std::vector<SDOperand> Ops; Ops.push_back(DAG.getRoot()); @@ -3911,15 +3910,15 @@ // FIXME: Distinguish between a formal with no [sz]ext attribute from one // that is zero extended! - if (Attrs && Attrs->paramHasAttr(j, ParamAttr::ZExt)) + if (F.paramHasAttr(j, ParamAttr::ZExt)) Flags &= ~(ISD::ParamFlags::SExt); - if (Attrs && Attrs->paramHasAttr(j, ParamAttr::SExt)) + if (F.paramHasAttr(j, ParamAttr::SExt)) Flags |= ISD::ParamFlags::SExt; - if (Attrs && Attrs->paramHasAttr(j, ParamAttr::InReg)) + if (F.paramHasAttr(j, ParamAttr::InReg)) Flags |= ISD::ParamFlags::InReg; - if (Attrs && Attrs->paramHasAttr(j, ParamAttr::StructRet)) + if (F.paramHasAttr(j, ParamAttr::StructRet)) Flags |= ISD::ParamFlags::StructReturn; - if (Attrs && Attrs->paramHasAttr(j, ParamAttr::ByVal)) { + if (F.paramHasAttr(j, ParamAttr::ByVal)) { Flags |= ISD::ParamFlags::ByVal; const PointerType *Ty = cast<PointerType>(I->getType()); const StructType *STy = cast<StructType>(Ty->getElementType()); @@ -3929,7 +3928,7 @@ Flags |= (StructAlign << ISD::ParamFlags::ByValAlignOffs); Flags |= (StructSize << ISD::ParamFlags::ByValSizeOffs); } - if (Attrs && Attrs->paramHasAttr(j, ParamAttr::Nest)) + if (F.paramHasAttr(j, ParamAttr::Nest)) Flags |= ISD::ParamFlags::Nest; Flags |= (OriginalAlignment << ISD::ParamFlags::OrigAlignmentOffs); @@ -3986,10 +3985,10 @@ case Promote: { SDOperand Op(Result, i++); if (MVT::isInteger(VT)) { - if (Attrs && Attrs->paramHasAttr(Idx, ParamAttr::SExt)) + if (F.paramHasAttr(Idx, ParamAttr::SExt)) Op = DAG.getNode(ISD::AssertSext, Op.getValueType(), Op, DAG.getValueType(VT)); - else if (Attrs && Attrs->paramHasAttr(Idx, ParamAttr::ZExt)) + else if (F.paramHasAttr(Idx, ParamAttr::ZExt)) Op = DAG.getNode(ISD::AssertZext, Op.getValueType(), Op, DAG.getValueType(VT)); Op = DAG.getNode(ISD::TRUNCATE, VT, Op); Modified: llvm/trunk/lib/ExecutionEngine/Interpreter/Execution.cpp URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/ExecutionEngine/Interpreter/Execution.cpp?rev=44403&r1=44402&r2=44403&view=diff ============================================================================== --- llvm/trunk/lib/ExecutionEngine/Interpreter/Execution.cpp (original) +++ llvm/trunk/lib/ExecutionEngine/Interpreter/Execution.cpp Wed Nov 28 11:07:01 2007 @@ -896,18 +896,15 @@ e = SF.Caller.arg_end(); i != e; ++i, ++pNum) { Value *V = *i; ArgVals.push_back(getOperandValue(V, SF)); - if (F) { - // Promote all integral types whose size is < sizeof(i32) into i32. - // We do this by zero or sign extending the value as appropriate - // according to the parameter attributes - const Type *Ty = V->getType(); - if (Ty->isInteger() && (ArgVals.back().IntVal.getBitWidth() < 32)) - if (const ParamAttrsList *PA = F->getParamAttrs()) - if (PA->paramHasAttr(pNum, ParamAttr::ZExt)) - ArgVals.back().IntVal = ArgVals.back().IntVal.zext(32); - else if (PA->paramHasAttr(pNum, ParamAttr::SExt)) - ArgVals.back().IntVal = ArgVals.back().IntVal.sext(32); - } + // Promote all integral types whose size is < sizeof(i32) into i32. + // We do this by zero or sign extending the value as appropriate + // according to the parameter attributes + const Type *Ty = V->getType(); + if (Ty->isInteger() && (ArgVals.back().IntVal.getBitWidth() < 32)) + if (CS.paramHasAttr(pNum, ParamAttr::ZExt)) + ArgVals.back().IntVal = ArgVals.back().IntVal.zext(32); + else if (CS.paramHasAttr(pNum, ParamAttr::SExt)) + ArgVals.back().IntVal = ArgVals.back().IntVal.sext(32); } // To handle indirect calls, we must get the pointer value from the argument Modified: llvm/trunk/lib/Target/MSIL/MSILWriter.cpp URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/MSIL/MSILWriter.cpp?rev=44403&r1=44402&r2=44403&view=diff ============================================================================== --- llvm/trunk/lib/Target/MSIL/MSILWriter.cpp (original) +++ llvm/trunk/lib/Target/MSIL/MSILWriter.cpp Wed Nov 28 11:07:01 2007 @@ -1387,8 +1387,7 @@ void MSILWriter::printFunction(const Function& F) { - const ParamAttrsList *Attrs = F.getParamAttrs(); - bool isSigned = Attrs && Attrs->paramHasAttr(0, ParamAttr::SExt); + bool isSigned = F.paramHasAttr(0, ParamAttr::SExt); Out << "\n.method static "; Out << (F.hasInternalLinkage() ? "private " : "public "); if (F.isVarArg()) Out << "vararg "; @@ -1399,7 +1398,7 @@ unsigned ArgIdx = 1; for (Function::const_arg_iterator I = F.arg_begin(), E = F.arg_end(); I!=E; ++I, ++ArgIdx) { - isSigned = Attrs && Attrs->paramHasAttr(ArgIdx, ParamAttr::SExt); + isSigned = F.paramHasAttr(ArgIdx, ParamAttr::SExt); if (I!=F.arg_begin()) Out << ", "; Out << getTypeName(I->getType(),isSigned) << getValueName(I); } Modified: llvm/trunk/lib/Transforms/Scalar/SimplifyCFG.cpp URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/SimplifyCFG.cpp?rev=44403&r1=44402&r2=44403&view=diff ============================================================================== --- llvm/trunk/lib/Transforms/Scalar/SimplifyCFG.cpp (original) +++ llvm/trunk/lib/Transforms/Scalar/SimplifyCFG.cpp Wed Nov 28 11:07:01 2007 @@ -90,35 +90,6 @@ BB->getInstList().erase(II); } -/// IsNoReturn - Return true if the specified call is to a no-return function. -static bool IsNoReturn(const CallInst *CI) { - if (const ParamAttrsList *Attrs = CI->getParamAttrs()) - if (Attrs->paramHasAttr(0, ParamAttr::NoReturn)) - return true; - - if (const Function *Callee = CI->getCalledFunction()) - if (const ParamAttrsList *Attrs = Callee->getParamAttrs()) - if (Attrs->paramHasAttr(0, ParamAttr::NoReturn)) - return true; - - return false; -} - -/// IsNoUnwind - Return true if the specified invoke is to a no-unwind function. -static bool IsNoUnwind(const InvokeInst *II) { - if (const ParamAttrsList *Attrs = II->getParamAttrs()) - if (Attrs->paramHasAttr(0, ParamAttr::NoUnwind)) - return true; - - if (const Function *Callee = II->getCalledFunction()) - if (const ParamAttrsList *Attrs = Callee->getParamAttrs()) - if (Attrs->paramHasAttr(0, ParamAttr::NoUnwind)) - return true; - - return false; -} - - static bool MarkAliveBlocks(BasicBlock *BB, SmallPtrSet<BasicBlock*, 128> &Reachable) { @@ -137,7 +108,7 @@ // canonicalizes unreachable insts into stores to null or undef. for (BasicBlock::iterator BBI = BB->begin(), E = BB->end(); BBI != E;++BBI){ if (CallInst *CI = dyn_cast<CallInst>(BBI)) { - if (IsNoReturn(CI)) { + if (CI->paramHasAttr(0, ParamAttr::NoReturn)) { // If we found a call to a no-return function, insert an unreachable // instruction after it. Make sure there isn't *already* one there // though. @@ -161,7 +132,7 @@ // Turn invokes that call 'nounwind' functions into ordinary calls. if (InvokeInst *II = dyn_cast<InvokeInst>(BB->getTerminator())) - if (IsNoUnwind(II)) { + if (II->paramHasAttr(0, ParamAttr::NoUnwind)) { ChangeToCall(II); Changed = true; } Modified: llvm/trunk/lib/VMCore/Function.cpp URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/VMCore/Function.cpp?rev=44403&r1=44402&r2=44403&view=diff ============================================================================== --- llvm/trunk/lib/VMCore/Function.cpp (original) +++ llvm/trunk/lib/VMCore/Function.cpp Wed Nov 28 11:07:01 2007 @@ -13,7 +13,6 @@ #include "llvm/Module.h" #include "llvm/DerivedTypes.h" -#include "llvm/ParameterAttributes.h" #include "llvm/IntrinsicInst.h" #include "llvm/CodeGen/ValueTypes.h" #include "llvm/Support/LeakDetector.h" @@ -287,12 +286,6 @@ ParamAttrs = attrs; } -bool Function::isStructReturn() const { - if (ParamAttrs) - return ParamAttrs->paramHasAttr(1, ParamAttr::StructRet); - return false; -} - const FunctionType *Function::getFunctionType() const { return cast<FunctionType>(getType()->getElementType()); } Modified: llvm/trunk/lib/VMCore/Instructions.cpp URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/VMCore/Instructions.cpp?rev=44403&r1=44402&r2=44403&view=diff ============================================================================== --- llvm/trunk/lib/VMCore/Instructions.cpp (original) +++ llvm/trunk/lib/VMCore/Instructions.cpp Wed Nov 28 11:07:01 2007 @@ -47,6 +47,12 @@ else cast<InvokeInst>(I)->setParamAttrs(PAL); } +bool CallSite::paramHasAttr(uint16_t i, ParameterAttributes attr) const { + if (CallInst *CI = dyn_cast<CallInst>(I)) + return CI->paramHasAttr(i, attr); + else + return cast<InvokeInst>(I)->paramHasAttr(i, attr); +} @@ -376,12 +382,14 @@ ParamAttrs = newAttrs; } -bool CallInst::isStructReturn() const { - if (ParamAttrs) - return ParamAttrs->paramHasAttr(1, ParamAttr::StructRet); - return false; +bool CallInst::paramHasAttr(uint16_t i, ParameterAttributes attr) const { + if (ParamAttrs && ParamAttrs->paramHasAttr(i, attr)) + return true; + const Function *F = getCalledFunction(); + return F && F->getParamAttrs() && F->getParamAttrs()->paramHasAttr(i, attr); } + //===----------------------------------------------------------------------===// // InvokeInst Implementation //===----------------------------------------------------------------------===// @@ -451,12 +459,14 @@ ParamAttrs = newAttrs; } -bool InvokeInst::isStructReturn() const { - if (ParamAttrs) - return ParamAttrs->paramHasAttr(1, ParamAttr::StructRet); - return false; +bool InvokeInst::paramHasAttr(uint16_t i, ParameterAttributes attr) const { + if (ParamAttrs && ParamAttrs->paramHasAttr(i, attr)) + return true; + const Function *F = getCalledFunction(); + return F && F->getParamAttrs() && F->getParamAttrs()->paramHasAttr(i, attr); } + //===----------------------------------------------------------------------===// // ReturnInst Implementation //===----------------------------------------------------------------------===// Modified: llvm/trunk/test/Transforms/SimplifyCFG/2007-11-22-InvokeNoUnwind.ll URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Transforms/SimplifyCFG/2007-11-22-InvokeNoUnwind.ll?rev=44403&r1=44402&r2=44403&view=diff ============================================================================== --- llvm/trunk/test/Transforms/SimplifyCFG/2007-11-22-InvokeNoUnwind.ll (original) +++ llvm/trunk/test/Transforms/SimplifyCFG/2007-11-22-InvokeNoUnwind.ll Wed Nov 28 11:07:01 2007 @@ -3,7 +3,7 @@ declare i32 @func(i8*) nounwind define i32 @test() { - invoke i32 @func( i8* null ) nounwind + invoke i32 @func( i8* null ) to label %Cont unwind label %Other ; <i32>:1 [#uses=0] Cont: ; preds = %0 Modified: llvm/trunk/tools/llvm-upgrade/UpgradeParser.cpp.cvs URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-upgrade/UpgradeParser.cpp.cvs?rev=44403&r1=44402&r2=44403&view=diff ============================================================================== --- llvm/trunk/tools/llvm-upgrade/UpgradeParser.cpp.cvs (original) +++ llvm/trunk/tools/llvm-upgrade/UpgradeParser.cpp.cvs Wed Nov 28 11:07:01 2007 @@ -4510,7 +4510,7 @@ bool isVarArg = Params.size() && Params.back() == Type::VoidTy; if (isVarArg) Params.pop_back(); - ParamAttrsList *PAL = 0; + const ParamAttrsList *PAL = 0; if (lastCallingConv == OldCallingConv::CSRet) { ParamAttrsVector Attrs; ParamAttrsWithIndex PAWI; Modified: llvm/trunk/tools/llvm-upgrade/UpgradeParser.y.cvs URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-upgrade/UpgradeParser.y.cvs?rev=44403&r1=44402&r2=44403&view=diff ============================================================================== --- llvm/trunk/tools/llvm-upgrade/UpgradeParser.y.cvs (original) +++ llvm/trunk/tools/llvm-upgrade/UpgradeParser.y.cvs Wed Nov 28 11:07:01 2007 @@ -2055,7 +2055,7 @@ bool isVarArg = Params.size() && Params.back() == Type::VoidTy; if (isVarArg) Params.pop_back(); - ParamAttrsList *PAL = 0; + const ParamAttrsList *PAL = 0; if (lastCallingConv == OldCallingConv::CSRet) { ParamAttrsVector Attrs; ParamAttrsWithIndex PAWI; _______________________________________________ llvm-commits mailing list llvm-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits