[Libclc-dev] [PATCH] Add bitselect builtin
Tom Stellard
tom at stellard.net
Fri Jun 28 15:32:46 PDT 2013
From: Tom Stellard <thomas.stellard at amd.com>
---
generic/include/clc/clc.h | 1 +
generic/include/clc/relational/bitselect.h | 1 +
2 files changed, 2 insertions(+)
create mode 100644 generic/include/clc/relational/bitselect.h
diff --git a/generic/include/clc/clc.h b/generic/include/clc/clc.h
index 10d30e0..1ce97ad 100644
--- a/generic/include/clc/clc.h
+++ b/generic/include/clc/clc.h
@@ -82,6 +82,7 @@
/* 6.11.6 Relational Functions */
#include <clc/relational/any.h>
+#include <clc/relational/bitselect.h>
#include <clc/relational/select.h>
/* 6.11.8 Synchronization Functions */
diff --git a/generic/include/clc/relational/bitselect.h b/generic/include/clc/relational/bitselect.h
new file mode 100644
index 0000000..e91cbfd
--- /dev/null
+++ b/generic/include/clc/relational/bitselect.h
@@ -0,0 +1 @@
+#define bitselect(x, y, z) ((x) ^ ((z) & ((y) ^ (x))))
--
1.8.1.5
More information about the Libclc-dev
mailing list