Changeset View
Changeset View
Standalone View
Standalone View
source/lib/sysdep/compiler.h
/* Copyright (c) 2019 Wildfire Games. | /* Copyright (c) 2020 Wildfire Games. | ||||
* | * | ||||
* Permission is hereby granted, free of charge, to any person obtaining | * Permission is hereby granted, free of charge, to any person obtaining | ||||
* a copy of this software and associated documentation files (the | * a copy of this software and associated documentation files (the | ||||
* "Software"), to deal in the Software without restriction, including | * "Software"), to deal in the Software without restriction, including | ||||
* without limitation the rights to use, copy, modify, merge, publish, | * without limitation the rights to use, copy, modify, merge, publish, | ||||
* distribute, sublicense, and/or sell copies of the Software, and to | * distribute, sublicense, and/or sell copies of the Software, and to | ||||
* permit persons to whom the Software is furnished to do so, subject to | * permit persons to whom the Software is furnished to do so, subject to | ||||
* the following conditions: | * the following conditions: | ||||
Show All 28 Lines | |||||
#endif | #endif | ||||
// .. ICC (VC-compatible, GCC-compatible) | // .. ICC (VC-compatible, GCC-compatible) | ||||
#if defined(__INTEL_COMPILER) | #if defined(__INTEL_COMPILER) | ||||
# define ICC_VERSION __INTEL_COMPILER | # define ICC_VERSION __INTEL_COMPILER | ||||
#else | #else | ||||
# define ICC_VERSION 0 | # define ICC_VERSION 0 | ||||
#endif | #endif | ||||
// .. LCC (VC-compatible) | // .. LCC (VC-compatible) | ||||
#if defined(__LCC__) | // LCC-Win32 and MCST lcc compilers define same identifier (__LCC__). | ||||
// Have been added check of MCST Elbrus 2000 (e2k) architecture. | |||||
#if defined(__LCC__) && !defined(__e2k__) | |||||
# define LCC_VERSION __LCC__ | # define LCC_VERSION __LCC__ | ||||
#else | #else | ||||
# define LCC_VERSION 0 | # define LCC_VERSION 0 | ||||
#endif | #endif | ||||
// .. MCST LCC (eLbrus C Compiler) | |||||
#if defined(__LCC__) && defined(__e2k__) | |||||
# define MCST_LCC_VERSION (__LCC__*100 + __LCC_MINOR__) | |||||
#else | |||||
# define MCST_LCC_VERSION 0 | |||||
#endif | |||||
// .. GCC | // .. GCC | ||||
#ifdef __GNUC__ | #ifdef __GNUC__ | ||||
# define GCC_VERSION (__GNUC__*100 + __GNUC_MINOR__) | # define GCC_VERSION (__GNUC__*100 + __GNUC_MINOR__) | ||||
#else | #else | ||||
# define GCC_VERSION 0 | # define GCC_VERSION 0 | ||||
#endif | #endif | ||||
// .. Clang/LLVM (GCC-compatible) | // .. Clang/LLVM (GCC-compatible) | ||||
// use Clang's feature checking macros to check for availability of features | // use Clang's feature checking macros to check for availability of features | ||||
▲ Show 20 Lines • Show All 62 Lines • Show Last 20 Lines |
Wildfire Games · Phabricator