intel.hpp

Go to the documentation of this file.
00001 //  (C) Copyright John Maddock 2001. 
00002 //  (C) Copyright Peter Dimov 2001. 
00003 //  (C) Copyright Jens Maurer 2001. 
00004 //  (C) Copyright David Abrahams 2002 - 2003. 
00005 //  (C) Copyright Aleksey Gurtovoy 2002 - 2003. 
00006 //  (C) Copyright Guillaume Melquiond 2002 - 2003. 
00007 //  (C) Copyright Beman Dawes 2003. 
00008 //  (C) Copyright Martin Wille 2003. 
00009 //  Use, modification and distribution are subject to the 
00010 //  Boost Software License, Version 1.0. (See accompanying file 
00011 //  LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
00012 
00013 //  See http://www.boost.org for most recent version.
00014 
00015 //  Intel compiler setup:
00016 
00017 #include "sysc/packages/boost/config/compiler/common_edg.hpp"
00018 
00019 #if defined(__INTEL_COMPILER)
00020 #  define BOOST_INTEL_CXX_VERSION __INTEL_COMPILER
00021 #elif defined(__ICL)
00022 #  define BOOST_INTEL_CXX_VERSION __ICL
00023 #elif defined(__ICC)
00024 #  define BOOST_INTEL_CXX_VERSION __ICC
00025 #elif defined(__ECC)
00026 #  define BOOST_INTEL_CXX_VERSION __ECC
00027 #endif
00028 
00029 #define BOOST_COMPILER "Intel C++ version " BOOST_STRINGIZE(BOOST_INTEL_CXX_VERSION)
00030 #define BOOST_INTEL BOOST_INTEL_CXX_VERSION
00031 
00032 #if defined(_WIN32) || defined(_WIN64)
00033 #  define BOOST_INTEL_WIN BOOST_INTEL
00034 #else
00035 #  define BOOST_INTEL_LINUX BOOST_INTEL
00036 #endif
00037 
00038 #if (BOOST_INTEL_CXX_VERSION <= 500) && defined(_MSC_VER)
00039 #  define BOOST_NO_EXPLICIT_FUNCTION_TEMPLATE_ARGUMENTS
00040 #  define BOOST_NO_TEMPLATE_TEMPLATES
00041 #endif
00042 
00043 #if (BOOST_INTEL_CXX_VERSION <= 600)
00044 
00045 #  if defined(_MSC_VER) && (_MSC_VER <= 1300) // added check for <= VC 7 (Peter Dimov)
00046 
00047 // Boost libraries assume strong standard conformance unless otherwise
00048 // indicated by a config macro. As configured by Intel, the EDG front-end
00049 // requires certain compiler options be set to achieve that strong conformance.
00050 // Particularly /Qoption,c,--arg_dep_lookup (reported by Kirk Klobe & Thomas Witt)
00051 // and /Zc:wchar_t,forScope. See boost-root/tools/build/intel-win32-tools.jam for
00052 // details as they apply to particular versions of the compiler. When the
00053 // compiler does not predefine a macro indicating if an option has been set,
00054 // this config file simply assumes the option has been set.
00055 // Thus BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP will not be defined, even if
00056 // the compiler option is not enabled.
00057 
00058 #     define BOOST_NO_SWPRINTF
00059 #  endif
00060 
00061 // Void returns, 64 bit integrals don't work when emulating VC 6 (Peter Dimov)
00062 
00063 #  if defined(_MSC_VER) && (_MSC_VER <= 1200)
00064 #     define BOOST_NO_VOID_RETURNS
00065 #     define BOOST_NO_INTEGRAL_INT64_T
00066 #  endif
00067 
00068 #endif
00069 
00070 #if (BOOST_INTEL_CXX_VERSION <= 710) && defined(_WIN32)
00071 #  define BOOST_NO_POINTER_TO_MEMBER_TEMPLATE_PARAMETERS
00072 #endif
00073 
00074 // See http://aspn.activestate.com/ASPN/Mail/Message/boost/1614864
00075 #if BOOST_INTEL_CXX_VERSION < 600
00076 #  define BOOST_NO_INTRINSIC_WCHAR_T
00077 #else
00078 // We should test the macro _WCHAR_T_DEFINED to check if the compiler
00079 // supports wchar_t natively. *BUT* there is a problem here: the standard
00080 // headers define this macro if they typedef wchar_t. Anyway, we're lucky
00081 // because they define it without a value, while Intel C++ defines it
00082 // to 1. So we can check its value to see if the macro was defined natively 
00083 // or not. 
00084 // Under UNIX, the situation is exactly the same, but the macro _WCHAR_T 
00085 // is used instead.
00086 #  if ((_WCHAR_T_DEFINED + 0) == 0) && ((_WCHAR_T + 0) == 0)
00087 #    define BOOST_NO_INTRINSIC_WCHAR_T
00088 #  endif
00089 #endif
00090 
00091 #if defined(__GNUC__) && !defined(BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL)
00092 //
00093 // Figure out when Intel is emulating this gcc bug:
00094 //
00095 #  if ((__GNUC__ == 3) && (__GNUC_MINOR__ <= 2)) || (BOOST_INTEL <= 900)
00096 #     define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL
00097 #  endif
00098 #endif
00099 
00100 //
00101 // Verify that we have actually got BOOST_NO_INTRINSIC_WCHAR_T
00102 // set correctly, if we don't do this now, we will get errors later
00103 // in type_traits code among other things, getting this correct
00104 // for the Intel compiler is actually remarkably fragile and tricky:
00105 //
00106 #if defined(BOOST_NO_INTRINSIC_WCHAR_T)
00107 #include <cwchar>
00108 template< typename T > struct assert_no_intrinsic_wchar_t;
00109 template<> struct assert_no_intrinsic_wchar_t<wchar_t> { typedef void type; };
00110 // if you see an error here then you need to unset BOOST_NO_INTRINSIC_WCHAR_T
00111 // where it is defined above:
00112 typedef assert_no_intrinsic_wchar_t<unsigned short>::type assert_no_intrinsic_wchar_t_;
00113 #else
00114 template< typename T > struct assert_intrinsic_wchar_t;
00115 template<> struct assert_intrinsic_wchar_t<wchar_t> {};
00116 // if you see an error here then define BOOST_NO_INTRINSIC_WCHAR_T on the command line:
00117 template<> struct assert_intrinsic_wchar_t<unsigned short> {};
00118 #endif
00119 
00120 #if _MSC_VER+0 >= 1000
00121 #  if _MSC_VER >= 1200
00122 #     define BOOST_HAS_MS_INT64
00123 #  endif
00124 #  define BOOST_NO_SWPRINTF
00125 #elif defined(_WIN32)
00126 #  define BOOST_DISABLE_WIN32
00127 #endif
00128 
00129 // I checked version 6.0 build 020312Z, it implements the NRVO.
00130 // Correct this as you find out which version of the compiler
00131 // implemented the NRVO first.  (Daniel Frey)
00132 #if (BOOST_INTEL_CXX_VERSION >= 600)
00133 #  define BOOST_HAS_NRVO
00134 #endif
00135 
00136 //
00137 // versions check:
00138 // we don't support Intel prior to version 5.0:
00139 #if BOOST_INTEL_CXX_VERSION < 500
00140 #  error "Compiler not supported or configured - please reconfigure"
00141 #endif
00142 //
00143 // last known and checked version:
00144 #if (BOOST_INTEL_CXX_VERSION > 900)
00145 #  if defined(BOOST_ASSERT_CONFIG)
00146 #     error "Unknown compiler version - please run the configure tests and report the results"
00147 #  elif defined(_MSC_VER)
00148 #     pragma message("Unknown compiler version - please run the configure tests and report the results")
00149 #  endif
00150 #endif
00151 
00152 
00153 
00154 
00155 

Generated on Wed Jan 21 15:32:09 2009 for SystemC by  doxygen 1.5.5