summaryrefslogtreecommitdiff
path: root/Modules/CMakeISPCCompilerABI.ispc
diff options
context:
space:
mode:
authorRobert Maynard <robert.maynard@kitware.com>2020-07-16 15:18:55 -0400
committerRobert Maynard <robert.maynard@kitware.com>2020-08-28 11:21:31 -0400
commit34cc6acc81758e29f8c88607c21ab11d8807f87c (patch)
tree38effcd493f057f6148f4d8f58262dfb27afaa24 /Modules/CMakeISPCCompilerABI.ispc
parent419d70d49000e10c36d9615574ff03513f2edf0d (diff)
downloadcmake-34cc6acc81758e29f8c88607c21ab11d8807f87c.tar.gz
Add ISPC compiler support to CMake
Diffstat (limited to 'Modules/CMakeISPCCompilerABI.ispc')
-rw-r--r--Modules/CMakeISPCCompilerABI.ispc20
1 files changed, 20 insertions, 0 deletions
diff --git a/Modules/CMakeISPCCompilerABI.ispc b/Modules/CMakeISPCCompilerABI.ispc
new file mode 100644
index 0000000000..e23abcea6a
--- /dev/null
+++ b/Modules/CMakeISPCCompilerABI.ispc
@@ -0,0 +1,20 @@
+
+export void ispcCompilerABI() {
+
+#if defined(__GNU__) && defined(__ELF__) && defined(__ARM_EABI__)
+ print("INFO:abi[ELF ARMEABI]");
+ static char const info_abi[] =
+#elif defined(__GNU__) && defined(__ELF__) && defined(__ARMEB__)
+ print("INFO:abi[ELF ARM]");
+#elif defined(__GNU__) && defined(__ELF__) && defined(__ARMEL__)
+ print("INFO:abi[ELF ARM]");
+
+#elif defined(__linux__) && defined(__ELF__) && defined(__amd64__) && \
+ defined(__ILP32__)
+print("INFO:abi[ELF X32]");
+
+#elif defined(__ELF__)
+print("INFO:abi[ELF]");
+#endif
+
+}