summaryrefslogtreecommitdiff
path: root/kernels
diff options
context:
space:
mode:
authorHomer Hsing <homer.xing@intel.com>2013-09-13 09:41:02 +0800
committerZhigang Gong <zhigang.gong@linux.intel.com>2013-09-17 13:12:46 +0800
commit3ae20b67ab88bd595a6dca9814dd642c5d056d9f (patch)
tree9acb48e9075aa4bd0feb2690e25d6892c33777b7 /kernels
parent041867b623ee068b3a3b00f407f9fd01318e3736 (diff)
support converting 64-bit integer to 32-bit float
version 2: improve algorithm to convert signed integer fix source operand type in llvm_gen_backend enable predicate in addWithCarry change test case to test signed integer Signed-off-by: Homer Hsing <homer.xing@intel.com> Reviewed-by: "Yang, Rong R" <rong.r.yang@intel.com>
Diffstat (limited to 'kernels')
-rw-r--r--kernels/compiler_long_convert.cl5
1 files changed, 5 insertions, 0 deletions
diff --git a/kernels/compiler_long_convert.cl b/kernels/compiler_long_convert.cl
index 03df1472..e5f7939b 100644
--- a/kernels/compiler_long_convert.cl
+++ b/kernels/compiler_long_convert.cl
@@ -12,3 +12,8 @@ kernel void compiler_long_convert_2(global char *dst1, global short *dst2, globa
dst2[i] = src[i];
dst3[i] = src[i];
}
+
+kernel void compiler_long_convert_to_float(global float *dst, global long *src) {
+ int i = get_global_id(0);
+ dst[i] = src[i];
+}