[Libclc-dev] [PATCH v3 1/1] R600: Add new intrinsic to read work dimensions

Matt Arsenault Matthew.Arsenault at amd.com
Wed Aug 6 15:21:01 PDT 2014


On 08/06/2014 03:08 PM, Jan Vesely wrote:
> +  case Intrinsic::r600_read_workdim: {
> +    const size_t arg_size = DAG.getMachineFunction().getFunction()->arg_size();
arg_size() returns the number of arguments, not their actual size. You 
can't assume every argument is 4 bytes. There could be larger types, 
vectors, or structs
> +    return LowerParameter(DAG, VT, VT, DL, DAG.getEntryNode(), 36 + (arg_size * 4), false);
> +  }





More information about the Libclc-dev mailing list