Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 09:48:05

0001 /*
0002 Copyright Benjamin Worpitz 2018
0003 Distributed under the Boost Software License, Version 1.0.
0004 (See accompanying file LICENSE_1_0.txt or copy at
0005 http://www.boost.org/LICENSE_1_0.txt)
0006 */
0007 
0008 #ifndef BOOST_PREDEF_LANGUAGE_CUDA_H
0009 #define BOOST_PREDEF_LANGUAGE_CUDA_H
0010 
0011 #include <boost/predef/version_number.h>
0012 #include <boost/predef/make.h>
0013 
0014 /* tag::reference[]
0015 = `BOOST_LANG_CUDA`
0016 
0017 https://en.wikipedia.org/wiki/CUDA[CUDA C/{CPP}] language.
0018 If available, the version is detected as VV.RR.P.
0019 
0020 [options="header"]
0021 |===
0022 | {predef_symbol} | {predef_version}
0023 
0024 | `+__CUDACC__+` | {predef_detection}
0025 | `+__CUDA__+` | {predef_detection}
0026 
0027 | `CUDA_VERSION` | VV.RR.P
0028 |===
0029 */ // end::reference[]
0030 
0031 #define BOOST_LANG_CUDA BOOST_VERSION_NUMBER_NOT_AVAILABLE
0032 
0033 #if defined(__CUDACC__) || defined(__CUDA__)
0034 #   undef BOOST_LANG_CUDA
0035 #   include <cuda.h>
0036 #   if defined(CUDA_VERSION)
0037 #       define BOOST_LANG_CUDA BOOST_PREDEF_MAKE_10_VVRRP(CUDA_VERSION)
0038 #   else
0039 #       define BOOST_LANG_CUDA BOOST_VERSION_NUMBER_AVAILABLE
0040 #   endif
0041 #endif
0042 
0043 #if BOOST_LANG_CUDA
0044 #   define BOOST_LANG_CUDA_AVAILABLE
0045 #endif
0046 
0047 #define BOOST_LANG_CUDA_NAME "CUDA C/C++"
0048 
0049 
0050 #endif
0051 
0052 #include <boost/predef/detail/test.h>
0053 BOOST_PREDEF_DECLARE_TEST(BOOST_LANG_CUDA,BOOST_LANG_CUDA_NAME)