From: Juergen Ributzka Date: Mon, 15 Sep 2014 22:07:44 +0000 (+0000) Subject: [FastISel] Fix a bug in FastISel::CallLoweringInfo. X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=7d8b5f7777735d4f78d97348c23906d4d9e83732;p=oota-llvm.git [FastISel] Fix a bug in FastISel::CallLoweringInfo. This fixes a bug in FastISel::CallLoweringInfo, where the number of arguments was obtained from the argument vector before it had been initialized. Test case follows in another commit. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@217832 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/llvm/CodeGen/FastISel.h b/include/llvm/CodeGen/FastISel.h index 9fc3a875125..80b3a40017d 100644 --- a/include/llvm/CodeGen/FastISel.h +++ b/include/llvm/CodeGen/FastISel.h @@ -103,8 +103,8 @@ public: RetZExt = Call.paramHasAttr(0, Attribute::ZExt); CallConv = Call.getCallingConv(); - NumFixedArgs = FuncTy->getNumParams(); Args = std::move(ArgsList); + NumFixedArgs = FuncTy->getNumParams(); CS = &Call; @@ -127,8 +127,8 @@ public: RetZExt = Call.paramHasAttr(0, Attribute::ZExt); CallConv = Call.getCallingConv(); - NumFixedArgs = (FixedArgs == ~0U) ? FuncTy->getNumParams() : FixedArgs; Args = std::move(ArgsList); + NumFixedArgs = (FixedArgs == ~0U) ? FuncTy->getNumParams() : FixedArgs; CS = &Call;