[Beignet] [PATCH OpenCL 2.0] Backend: Update the workgroup instructions for llvm backend to gen.
junyan.he at inbox.com
junyan.he at inbox.com
Mon Mar 23 23:40:01 PDT 2015
From: Junyan He <junyan.he at linux.intel.com>
Signed-off-by: Junyan He <junyan.he at linux.intel.com>
---
backend/src/llvm/llvm_gen_ocl_function.hxx | 87 ++++++++++++++++++++++++++++
1 file changed, 87 insertions(+)
diff --git a/backend/src/llvm/llvm_gen_ocl_function.hxx b/backend/src/llvm/llvm_gen_ocl_function.hxx
index 9536a3c..947fadc 100644
--- a/backend/src/llvm/llvm_gen_ocl_function.hxx
+++ b/backend/src/llvm/llvm_gen_ocl_function.hxx
@@ -160,3 +160,90 @@ DECL_LLVM_GEN_FUNCTION(REGION, __gen_ocl_region)
// printf function
DECL_LLVM_GEN_FUNCTION(PRINTF, __gen_ocl_printf)
+
+// work group function
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_INT_1D, _Z30__gen_ocl_work_group_broadcastij)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_INT_2D, _Z30__gen_ocl_work_group_broadcastijj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_INT_3D, _Z30__gen_ocl_work_group_broadcastijjj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_UINT_1D, _Z30__gen_ocl_work_group_broadcastjj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_UINT_2D, _Z30__gen_ocl_work_group_broadcastjjj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_UINT_3D, _Z30__gen_ocl_work_group_broadcastjjjj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_LONG_1D, _Z30__gen_ocl_work_group_broadcastlj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_LONG_2D, _Z30__gen_ocl_work_group_broadcastljj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_lONG_3D, _Z30__gen_ocl_work_group_broadcastljjj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_ULONG_1D, _Z30__gen_ocl_work_group_broadcastmj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_ULONG_2D, _Z30__gen_ocl_work_group_broadcastmjj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_ULONG_3D, _Z30__gen_ocl_work_group_broadcastmjjj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_FLOAT_1D, _Z30__gen_ocl_work_group_broadcastfj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_FLOAT_2D, _Z30__gen_ocl_work_group_broadcastfjj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_FLOAT_3D, _Z30__gen_ocl_work_group_broadcastfjjj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_DOUBLE_1D, _Z30__gen_ocl_work_group_broadcastdj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_DOUBLE_2D, _Z30__gen_ocl_work_group_broadcastdjj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_BROADCAST_DOUBLE_3D, _Z30__gen_ocl_work_group_broadcastdjjj)
+
+// work group reduce
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_ADD_DOUBLE, _Z31__gen_ocl_work_group_reduce_addd)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_ADD_FLOAT, _Z31__gen_ocl_work_group_reduce_addf)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_ADD_INT, _Z31__gen_ocl_work_group_reduce_addi)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_ADD_UINT, _Z31__gen_ocl_work_group_reduce_addj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_ADD_LONG, _Z31__gen_ocl_work_group_reduce_addl)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_ADD_ULONG, _Z31__gen_ocl_work_group_reduce_addm)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_MAXD, _Z31__gen_ocl_work_group_reduce_maxd)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_MAXF, _Z31__gen_ocl_work_group_reduce_maxf)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_MAXI, _Z31__gen_ocl_work_group_reduce_maxi)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_MAXJ, _Z31__gen_ocl_work_group_reduce_maxj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_MAXL, _Z31__gen_ocl_work_group_reduce_maxl)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_MAXM, _Z31__gen_ocl_work_group_reduce_maxm)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_MIND, _Z31__gen_ocl_work_group_reduce_mind)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_MINF, _Z31__gen_ocl_work_group_reduce_minf)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_MINI, _Z31__gen_ocl_work_group_reduce_mini)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_MINJ, _Z31__gen_ocl_work_group_reduce_minj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_MINL, _Z31__gen_ocl_work_group_reduce_minl)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_REDUCE_MINM, _Z31__gen_ocl_work_group_reduce_minm)
+
+// work group scan_exclusive
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_ADD_DOUBLE, _Z39__gen_ocl_work_group_scan_exclusive_addd)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_ADD_FLOAT, _Z39__gen_ocl_work_group_scan_exclusive_addf)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_ADD_INT, _Z39__gen_ocl_work_group_scan_exclusive_addi)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_ADD_UINT, _Z39__gen_ocl_work_group_scan_exclusive_addj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_ADD_LONG, _Z39__gen_ocl_work_group_scan_exclusive_addl)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_ADD_ULONG, _Z39__gen_ocl_work_group_scan_exclusive_addm)
+
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_MAX_DOUBLE, _Z39__gen_ocl_work_group_scan_exclusive_maxd)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_MAX_FLOAT, _Z39__gen_ocl_work_group_scan_exclusive_maxf)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_MAX_INT, _Z39__gen_ocl_work_group_scan_exclusive_maxi)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_MAX_UINT, _Z39__gen_ocl_work_group_scan_exclusive_maxj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_MAX_LONG, _Z39__gen_ocl_work_group_scan_exclusive_maxl)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_MAXM_ULONG, _Z39__gen_ocl_work_group_scan_exclusive_maxm)
+
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_MIN_DOUBLE, _Z39__gen_ocl_work_group_scan_exclusive_mind)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_MIN_FLOAT, _Z39__gen_ocl_work_group_scan_exclusive_minf)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_MIN_INT, _Z39__gen_ocl_work_group_scan_exclusive_mini)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_MIN_UINT, _Z39__gen_ocl_work_group_scan_exclusive_minj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_MIN_LONG, _Z39__gen_ocl_work_group_scan_exclusive_minl)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_EXCLUSIVE_MIN_ULONG, _Z39__gen_ocl_work_group_scan_exclusive_minm)
+
+// work group scan_inclusive
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_ADD_DOUBLE, _Z39__gen_ocl_work_group_scan_inclusive_addd)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_ADD_FLOAT, _Z39__gen_ocl_work_group_scan_inclusive_addf)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_ADD_INT, _Z39__gen_ocl_work_group_scan_inclusive_addi)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_ADD_UINT, _Z39__gen_ocl_work_group_scan_inclusive_addj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_ADD_LONG, _Z39__gen_ocl_work_group_scan_inclusive_addl)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_ADD_ULONG, _Z39__gen_ocl_work_group_scan_inclusive_addm)
+
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_MAX_DOUBLE, _Z39__gen_ocl_work_group_scan_inclusive_maxd)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_MAX_FLOAT, _Z39__gen_ocl_work_group_scan_inclusive_maxf)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_MAX_INT, _Z39__gen_ocl_work_group_scan_inclusive_maxi)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_MAX_UINT, _Z39__gen_ocl_work_group_scan_inclusive_maxj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_MAX_LONG, _Z39__gen_ocl_work_group_scan_inclusive_maxl)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_MAX_ULONG, _Z39__gen_ocl_work_group_scan_inclusive_maxm)
+
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_MIN_DOUBLE, _Z39__gen_ocl_work_group_scan_inclusive_mind)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_MIN_FLOAT, _Z39__gen_ocl_work_group_scan_inclusive_minf)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_MIN_INT, _Z39__gen_ocl_work_group_scan_inclusive_mini)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_MIN_UINT, _Z39__gen_ocl_work_group_scan_inclusive_minj)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_MIN_LONG, _Z39__gen_ocl_work_group_scan_inclusive_minl)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_SCAN_INCLUSIVE_MIN_ULONG, _Z39__gen_ocl_work_group_scan_inclusive_minm)
+
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_ALL, __gen_ocl_work_group_all)
+DECL_LLVM_GEN_FUNCTION(WORK_GROUP_ANY, __gen_ocl_work_group_any)
--
1.7.9.5
More information about the Beignet
mailing list