From: Homer Hsing Date: Thu, 29 Nov 2012 01:40:50 +0000 (+0800) Subject: test OpenCL 1.1 Async Copies and Prefetch Functions X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=2effbb15a60e8acabb8faea95cb032fdf58d0e51;p=contrib%2Fbeignet.git test OpenCL 1.1 Async Copies and Prefetch Functions --- diff --git a/kernels/compiler_async_copy_and_prefetch.cl b/kernels/compiler_async_copy_and_prefetch.cl new file mode 100644 index 0000000..7489bb0 --- /dev/null +++ b/kernels/compiler_async_copy_and_prefetch.cl @@ -0,0 +1,9 @@ +/* test OpenCL 1.1 Async Copies and Prefetch Functions (section 6.11.10) */ +kernel void compiler_async_copy_and_prefetch(__global float *p) { + prefetch(p, 10); + local float l[10]; + event_t e[2]; + async_work_group_copy(l, p, 10, 0); + async_work_group_copy(p, l, 10, 0); + wait_group_events(2, e); +} diff --git a/utests/compiler_async_copy_and_prefetch.cpp b/utests/compiler_async_copy_and_prefetch.cpp new file mode 100644 index 0000000..323faf9 --- /dev/null +++ b/utests/compiler_async_copy_and_prefetch.cpp @@ -0,0 +1,10 @@ +#include "utest_helper.hpp" + +void compiler_async_copy_and_prefetch(void) +{ + OCL_CREATE_KERNEL("compiler_async_copy_and_prefetch"); +} + +MAKE_UTEST_FROM_FUNCTION(compiler_async_copy_and_prefetch); + +