Ajout de l'ensemble du workspace.
[GPU.git] / WCudaMSE / BilatTools_Cuda / src / core / cudatools / header / both / both_define.h
diff --git a/WCudaMSE/BilatTools_Cuda/src/core/cudatools/header/both/both_define.h b/WCudaMSE/BilatTools_Cuda/src/core/cudatools/header/both/both_define.h
new file mode 100755 (executable)
index 0000000..63229d0
--- /dev/null
@@ -0,0 +1,67 @@
+#ifndef BOTH_SMART_CBI_H_\r
+#define BOTH_SMART_CBI_H_\r
+\r
+\r
+/*----------------------------------------------------------------------*\\r
+ |*            Pre-defined Compiler Macros                     *|\r
+ \*---------------------------------------------------------------------*/\r
+\r
+// http://sourceforge.net/p/predef/wiki/Compilers/\r
+\r
+// http://msdn.microsoft.com/en-us/library/b0084kay.aspx\r
+// https://gcc.gnu.org/onlinedocs/cpp/Common-Predefined-Macros.html\r
+// http://sourceforge.net/p/predef/wiki/Home/\r
+\r
+// #ifdef __GNUC__\r
+// #if defined(_MSC_VER)\r
+// #ifdef __CBI_CUDA__\r
+\r
+/*----------------------------------------------------------------------*\\r
+ |*                    Declaration                                     *|\r
+ \*---------------------------------------------------------------------*/\r
+\r
+/*--------------------------------------*\\r
+ |*            Public                  *|\r
+ \*-------------------------------------*/\r
+\r
+// Note\r
+//     Value of\r
+//\r
+//             __CUDACC__\r
+//\r
+//     is\r
+//\r
+//        true         for code in a   .cu file, ie code compil with nvcc (host or device side)\r
+//        false        for code in a   .cpp file, meme si nvcc est le compilateur used\r
+//\r
+\r
+// But:\r
+//     Autoriser l'utilisation de code\r
+//             __device__ __host__\r
+//     sur le host, meme dans un fichier cpp\r
+\r
+#ifdef __CUDACC__\r
+\r
+#define __BOTH__  __device__ __host__\r
+#define __HOST__  __host__\r
+\r
+#else\r
+\r
+// vide\r
+#define __BOTH__\r
+#define __HOST__\r
+\r
+//# warning __BOTH__  --> empty\r
+//# warning __HOST__  --> empty\r
+\r
+#endif\r
+\r
+// A tester\r
+//#include "cuda_runtime.h"\r
+//#include "code utilisant __host__.h"\r
+\r
+#endif \r
+\r
+/*----------------------------------------------------------------------*\\r
+ |*                    End                                             *|\r
+ \*---------------------------------------------------------------------*/\r