[Piglit] Maybe some mistake in cl builtin-char-abs-1.0.generated

He Junyan junyan.he at inbox.com
Fri Jun 28 19:58:59 PDT 2013


Thanks, you are right and I will modify my implement


On 06/29/2013 02:47 AM, Aaron Watry wrote:
> abs() always produces an unsigned output type.  So your example below should end up using:
>
>> vstore2(uchar2 vect,  int offset,  uchar* out);
> --Aaron
>
> On Jun 28, 2013, at 3:59 AM, He Junyan <junyan.he at inbox.com> wrote:
>
>> about test case "builtin-char-abs-1.0.generated"
>>
>> The kernel will generate as:
>>
>> kernel void test_2_abs_char(global uchar* out, global char* in0){
>>    vstore2(abs(vload2(0, in0)), 0, out);
>> }
>>
>> Which will cause the vstore function fail.
>>
>> here, I think the vstore2 will have the prototype:
>> vstore2(char2 vect,  int offset,  uchar* out);
>>
>> but the spec says:
>> void vstoren (gentypen data, size_t offset, __local gentype *p)
>>
>> So the gentype must be same, and there is no builtin conversion rule between uchar2 to char2 or uchar * to char *,
>> this case will always fail.
>>
>> Please uniform the in and out type
>>
>>
>> _______________________________________________
>> Piglit mailing list
>> Piglit at lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/piglit





More information about the Piglit mailing list