[Beignet] [VER_2 3/5] random input value for testing math functions
Homer Hsing
homer.xing at intel.com
Wed May 8 20:20:38 PDT 2013
Signed-off-by: Homer Hsing <homer.xing at intel.com>
---
utests/compiler_math.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/utests/compiler_math.cpp b/utests/compiler_math.cpp
index 4915469..efc7160 100644
--- a/utests/compiler_math.cpp
+++ b/utests/compiler_math.cpp
@@ -37,7 +37,7 @@ static void compiler_math(void)
OCL_MAP_BUFFER(1);
for (uint32_t i = 0; i < 32; ++i)
- cpu_src[i] = ((float*)buf_data[1])[i] = float(i);
+ cpu_src[i] = ((float*)buf_data[1])[i] = .1f * (rand() & 15);
OCL_UNMAP_BUFFER(1);
OCL_NDRANGE(1);
--
1.8.1.2
More information about the Beignet
mailing list