[Beignet] [PATCH 2/2] utests: Enable double for vload/store test case.

Zhigang Gong zhigang.gong at linux.intel.com
Fri Jun 21 00:33:10 PDT 2013


Signed-off-by: Zhigang Gong <zhigang.gong at linux.intel.com>
---
 kernels/compiler_vector_load_store.cl | 6 ++++--
 utests/compiler_vector_load_store.cpp | 2 +-
 2 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/kernels/compiler_vector_load_store.cl b/kernels/compiler_vector_load_store.cl
index 30f0e1e..d2cb277 100644
--- a/kernels/compiler_vector_load_store.cl
+++ b/kernels/compiler_vector_load_store.cl
@@ -1,5 +1,7 @@
 /* test OpenCL 1.1 Vector Data Load/Store Functions (section 6.11.7) */
 
+#pragma OPENCL EXTENSION cl_khr_fp64 : enable
+
 #define OFFSET2(type)  (type ##2) {(type)1, (type)2}
 #define OFFSET3(type)  (type ##3) {(type)1, (type)2, (type)3}
 #define OFFSET4(type)  (type ##4) {(type)1, (type)2, (type)3, (type)4}
@@ -24,10 +26,10 @@ __kernel void test_##type ##n(__global type *pin, \
   TEST_TYPE(ushort,n)\
   TEST_TYPE(int,n)   \
   TEST_TYPE(uint,n)  \
-  TEST_TYPE(float,n)
+  TEST_TYPE(float,n) \
+  TEST_TYPE(double,n)
 
 #if 0
-  TEST_TYPE(double,n)
   TEST_TYPE(long,n)
   TEST_TYPE(ulong,n)
   TEST_TYPE(half,n)
diff --git a/utests/compiler_vector_load_store.cpp b/utests/compiler_vector_load_store.cpp
index 79f284f..0d5b1b3 100644
--- a/utests/compiler_vector_load_store.cpp
+++ b/utests/compiler_vector_load_store.cpp
@@ -54,6 +54,6 @@ test_all_vector(uint16_t, ushort)
 test_all_vector(int32_t, int)
 test_all_vector(uint32_t, uint)
 test_all_vector(float, float)
-//test_all_vector(double, double)
+test_all_vector(double, double)
 //test_all_vector(int64_t, long)
 //test_all_vector(uint64_t, ulong)
-- 
1.7.11.7



More information about the Beignet mailing list