[Beignet] [PATCH] utests: Enhance global constant test case.
Zhigang Gong
zhigang.gong at linux.intel.com
Wed Jul 3 03:12:54 PDT 2013
Homer & Nanhai,
I think the following bug is an essential bug and should be fixed before next release.
It seems it always trigger an assertion if the user use a constant scalar variable which
is quite common use case from my point of view.
I remember Homer mentioned this bug in the last team meeting, and Nanhai thought it's not
high priority comapre to those builtin functions. Now Homer almost finished the builtin
functions, right? And we are approaching our next release very soon. If you can turn fix it,
I will appreciate. Thanks.
On Thu, Jun 20, 2013 at 02:03:00PM +0800, Zhigang Gong wrote:
> Add a normal global constant data definition which is not
> an array. Hit an assertion.
>
> Signed-off-by: Zhigang Gong <zhigang.gong at linux.intel.com>
> ---
> kernels/compiler_global_constant.cl | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/kernels/compiler_global_constant.cl b/kernels/compiler_global_constant.cl
> index af3c7b1..726a1c8 100644
> --- a/kernels/compiler_global_constant.cl
> +++ b/kernels/compiler_global_constant.cl
> @@ -1,8 +1,8 @@
> constant int m[3] = {71,72,73};
> -
> +constant int const1 = 1;
> __kernel void
> compiler_global_constant(__global int *dst, int e, int r)
> {
> int id = (int)get_global_id(0);
> - dst[id] = m[id%3] + e + r;
> + dst[id] = m[id%3] * const1 + e + r;
> }
> --
> 1.7.11.7
>
> _______________________________________________
> Beignet mailing list
> Beignet at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/beignet
More information about the Beignet
mailing list