[llvm-commits] [llvm] r129846 - /llvm/trunk/lib/Target/PTX/PTXMachineFunctionInfo.h

Benjamin Kramer benny.kra at googlemail.com
Wed Apr 20 09:07:04 PDT 2011


On 20.04.2011, at 11:27, Che-Liang Chiou wrote:

> Author: clchiou
> Date: Wed Apr 20 04:27:19 2011
> New Revision: 129846
> 
> URL: http://llvm.org/viewvc/llvm-project?rev=129846&view=rev
> Log:
> ptx: fix parameter ordering
> 
> Patched by Dan Bailey
> 
> Modified:
>    llvm/trunk/lib/Target/PTX/PTXMachineFunctionInfo.h
> 
> Modified: llvm/trunk/lib/Target/PTX/PTXMachineFunctionInfo.h
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/PTX/PTXMachineFunctionInfo.h?rev=129846&r1=129845&r2=129846&view=diff
> ==============================================================================
> --- llvm/trunk/lib/Target/PTX/PTXMachineFunctionInfo.h (original)
> +++ llvm/trunk/lib/Target/PTX/PTXMachineFunctionInfo.h Wed Apr 20 04:27:19 2011
> @@ -42,7 +42,6 @@
>   void setRetReg(unsigned reg) { reg_ret = reg; }
> 
>   void doneAddArg(void) {
> -    std::sort(reg_arg.begin(), reg_arg.end());
>     _isDoneAddArg = true;
>   }
>   void doneAddLocalVar(void) {

This breaks the std::binary_search below, which requires reg_arg to be sorted.
It would also be nice to commit changes like this with a test case.



More information about the llvm-commits mailing list