GBE: add some macros for atom_xxx builtin functions.
authorZhigang Gong <zhigang.gong@linux.intel.com>
Fri, 30 Aug 2013 03:16:23 +0000 (11:16 +0800)
committerZhigang Gong <zhigang.gong@linux.intel.com>
Mon, 2 Sep 2013 03:30:55 +0000 (11:30 +0800)
The atom_xxx APIs are on OpenCL spec 1.0, but the conformance test suite
will tes them anyway.

Signed-off-by: Zhigang Gong <zhigang.gong@linux.intel.com>
Reviewed-by: "Lu, Guanqun" <guanqun.lu@intel.com>
backend/src/ocl_stdlib.tmpl.h

index ac1999d..1cde116 100644 (file)
@@ -2078,6 +2078,21 @@ DECL_ATOMIC_OP(cmpxchg)
 #undef DECL_ATOMIC_OP_TYPE
 #undef DECL_ATOMIC_OP_SPACE
 
+// XXX for conformance test
+// The following atom_xxx api is on OpenCL spec 1.0.
+// But the conformance test suite will test them anyway.
+#define atom_add atomic_add
+#define atom_sub atomic_sub
+#define atom_and atomic_and
+#define atom_or atomic_or
+#define atom_xor atomic_xor
+#define atom_xchg atomic_xchg
+#define atom_min atomic_min
+#define atom_max atomic_max
+#define atom_inc atomic_inc
+#define atom_dec atomic_dec
+#define atom_cmpxchg atomic_cmpxchg
+
 /////////////////////////////////////////////////////////////////////////////
 // Force the compilation to SIMD8 or SIMD16
 /////////////////////////////////////////////////////////////////////////////