summaryrefslogtreecommitdiff
path: root/kernels/builtin_global_id.cl
diff options
context:
space:
mode:
Diffstat (limited to 'kernels/builtin_global_id.cl')
-rw-r--r--kernels/builtin_global_id.cl4
1 files changed, 4 insertions, 0 deletions
diff --git a/kernels/builtin_global_id.cl b/kernels/builtin_global_id.cl
new file mode 100644
index 00000000..5b82f9f1
--- /dev/null
+++ b/kernels/builtin_global_id.cl
@@ -0,0 +1,4 @@
+kernel void builtin_global_id( __global int *ret) {
+ int id = get_global_id(0) + get_global_id(1)*3 + get_global_id(2)*3*4;
+ ret[id] = id;
+}