> On Dec 6, 2016, at 11:04, Jan Vesely <[email protected]> wrote: > > On Tue, 2016-12-06 at 10:52 -0800, Matt Arsenault wrote: >>> On Dec 5, 2016, at 12:42, Jan Vesely <[email protected]> wrote: >>> >>> On Mon, 2016-12-05 at 09:48 -0800, [email protected] >>> <mailto:[email protected]> wrote: >>>> From: Matt Arsenault <[email protected]> >>>> >>>> --- >>>> .../execute/negative-private-base-pointer.cl | 120 >>>> +++++++++++++++++++++ >>>> 1 file changed, 120 insertions(+) >>>> create mode 100644 >>>> tests/cl/program/execute/negative-private-base-pointer.cl >>>> >>>> diff --git a/tests/cl/program/execute/negative-private-base-pointer.cl >>>> b/tests/cl/program/execute/negative-private-base-pointer.cl >>>> new file mode 100644 >>>> index 0000000..7ee528b >>>> --- /dev/null >>>> +++ b/tests/cl/program/execute/negative-private-base-pointer.cl >>>> @@ -0,0 +1,120 @@ >>>> +/*! >>>> +[config] >>>> +name: negative private buffer base index >>>> +clc_version_min: 10 >>>> +dimensions: 1 >>>> + >>>> +[test] >>>> +kernel_name: read_write_private_base_plus_offset >>>> +name: negative base private index >>>> +global_size: 1 0 0 >>>> + >>>> +arg_out: 0 buffer int[16] \ >>>> + 0xab \ >>>> + 0xbc \ >>>> + 0xabcd \ >>>> + 0xdead \ >>>> + \ >>>> + 0xcafe \ >>>> + 0xf00d \ >>>> + 0xababfeed \ >>>> + 0xca00fe \ >>>> + \ >>>> + 0xb00feed \ >>>> + 0xca00fe \ >>>> + 0xfeedbeef \ >>>> + 0xfe \ >>>> + \ >>>> + 0xbe00fe \ >>>> + 0xabcdef \ >>>> + 0xbeef \ >>>> + 0xde >>>> + >>>> + >>>> +arg_in: 1 buffer int[16] \ >>>> + -1 \ >>>> + -1 \ >>>> + -4 \ >>>> + -4 \ >>>> + \ >>>> + -3 \ >>>> + -4 \ >>>> + -2 \ >>>> + -115 \ >>>> + \ >>>> + -109 \ >>>> + -1015 \ >>>> + -1011 \ >>>> + -1020 \ >>>> + \ >>>> + -1014 \ >>>> + -137 \ >>>> + -151 \ >>>> + -40 >>>> + >>>> +!*/ >>>> + >>>> +#if 0 >>>> + 0xab \ >>>> + 0xbc \ >>>> + 0xf00d \ >>>> + 0xdead \ >>>> + 0xcafe \ >>>> + 0xabcd \ >>>> + 0xababfeed \ >>>> + 0xca00fe \ >>>> + 0xb00feed \ >>>> + 0xca00fe \ >>>> + 0xfeedbeef \ >>>> + 0xfe \ >>>> + 0xbe00fe \ >>>> + 0xabcdef \ >>>> + 0xbeef \ >>>> + 0xde >>>> +#endif >>>> + >>>> +kernel void read_write_private_base_plus_offset(global int* out, global >>>> int* in) >>>> +{ >>>> + volatile int alloca[16]; >>> >>> does this need to be volatile? >>> >>> other than that: >>> Reviewed-by: Jan Vesely <[email protected] >>> <mailto:[email protected]>> >>> >>> Jan >> >> Yes, otherwise the private memory access will be trivially optimized >> out defeating the point of the test > > I don't get the trivial part. what would that be optimized to? the > indices are using values from input buffer (therefore unknown), so it > cannot directly match the constants to corresponding position in out > buffer. > > Jan
This could be replaced with a series of selects or hit the move to LDS optimization -Matt _______________________________________________ Piglit mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/piglit
