[Beignet] [PATCH] utests: Enhance global constant test case.

Zhigang Gong zhigang.gong at linux.intel.com
Wed Jun 19 23:03:00 PDT 2013


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



More information about the Beignet mailing list