Additional Predefined Macros

The compiler supports the predefined macros listed in the table below. The compiler also includes predefined macros specified by the ISO/ANSI standard.

Unless otherwise stated, the macros are supported on systems based on Intel® 64 architectures.

Macro Description

__AVX__

On Linux*, defined as '1' when option -march=corei7-avx, or higher processor targeting options are specified.

Note

Available only for compilations targeting Intel® 64 architecture.

__AVX2__

( Linux)

On Linux, defined as '1' when option -march=core-avx2, or higher processor targeting options are specified.

Note

Available only for compilations targeting Intel® 64 architecture.

__AVX512BW__

(Windows*, Linux)

Defined as '1' for processors that support Intel® Advanced Vector Extensions 512 (Intel® AVX-512) Byte and Word instructions.

__AVX512CD__

(Windows*, Linux)

Defined as '1' for processors that support Intel® Advanced Vector Extensions 512 (Intel® AVX-512) Conflict Detection instructions.

__AVX512DQ__

(Windows*, Linux)

Defined as '1' for processors that support Intel® Advanced Vector Extensions 512 (Intel® AVX-512) Doubleword and Quadword instructions.

__AVX512ER__

(Windows*, Linux)

Defined as '1' for processors that support Intel® Advanced Vector Extensions 512 (Intel® AVX-512) Exponential and Reciprocal instructions.

__AVX512F__

(Windows*, Linux)

Defined as '1' for processors that support Intel® Advanced Vector Extensions 512 (Intel® AVX-512) Foundation instructions.

__AVX512PF__

(Windows*, Linux)

Defined as '1' for processors that support Intel® Advanced Vector Extensions 512 (Intel® AVX-512) Prefetch instructions.

__AVX512VL__

(Windows*, Linux)

Defined as '1' for processors that support Intel® Advanced Vector Extensions 512 (Intel® AVX-512) Vector Length extensions.

__BASE_FILE__

(Linux)

Name of source file

__COUNTER__

(Windows)

Defined as '0'.

__cplusplus

(Linux)

Defined as '1' (for the Intel® oneAPI DPC++ Compiler).

__ELF__

(Linux)

Defined as '1' at the start of compilation.

__EXCEPTIONS

(Linux)

Defined as '1' when option fno-exceptions is not used.

__gnu_linux__

(Linux)

Defined as '1' at the start of compilation.

__GNUC__

(Linux)

The major version number of gcc* installed on the system.

__GNUC_MINOR__

(Linux)

The minor version number of gcc* or g++* installed on the system.

__GNUC_PATCHLEVEL__

(Linux)

The patch level version number of gcc* or g++* installed on the system.

__GNUG__

(Linux)

The major version number of g++* installed on the system.

_INTEGRAL_MAX_BITS

(Windows)

64

__INTEL_COMPILER

(Windows*, Linux)

The version of the compiler.

__INTEL_COMPILER_BUILD_DATE

(Windows*, Linux)

The compiler build date. It takes the form YYYYMMDD, where YYYY is the year, MM is the month, and DD is the day.

__INTEL_MS_COMPAT_LEVEL

(Windows)

Defined as '1'.

__linux__

__linux

linux

(Linux)

Defined as '1' at the start of compilation.

__LONG_MAX__

(Linux)

9223372036854775807L

Note

Available only for compilations targeting Intel® 64 architecture.

__LP64__ (Linux)

__LP64 (Linux)

Defined as '1'.

Note

Available only for compilations targeting Intel® 64 architecture.

_M_IX86

(Windows)

700

_M_X64

(Windows)

Defined as '1' while building code targeting Intel® 64 architecture.

__MMX__

(Linux)

Defined as '1'.

On Linux, it is available only on systems based on Intel® 64 architecture.

_MSC_EXTENSIONS

(Windows)

This macro is defined when Microsoft extensions are enabled.

_MSC_FULL_VER

(Windows)

The Visual C++* version being used.

_MSC_VER

(Windows)

The Visual C++* version being used.

_MT

(Windows)

On Windows, defined as '1' when a multithreaded DLL or library is used (when option /MD[d] or /MT[d] is specified).

__NO_MATH_INLINES

__NO_STRING_INLINES

(Linux)

Defined as '1'.

__OPTIMIZE__

(Linux)

Defined as '1'.

__pentium4

__pentium4__

(Linux)

Defined as '1'.

__PIC__

__pic__

(Linux)

On Linux, defined as '1' when option fPIC is specified.

__PTRDIFF_TYPE__

(Linux)

On Linux, defined as long on Intel® 64 architecture.

__QMSPP_

(Windows)

Defined as '1'.

__REGISTER_PREFIX__

(Linux)

 

__SIGNED_CHARS__

(Windows, Linux)

Defined as '1'.

_SIZE_T_DEFINED

(Windows)

Defined, no value.

__SIZE_TYPE__

(Linux)

On Linux, defined as unsigned long on Intel® 64 architecture.

__SSE__

(Windows, Linux)

On Linux, defined as '1' for processors that support SSE instructions.

On Windows, defined as '1'.

__SSE2__

(Windows, Linux)

On Linux, defined as '1' for processors that support Intel® SSE2 instructions.

__SSE3__

(Windows, Linux)

On Linux, defined as '1' for processors that support Intel® SSE3 instructions.

__SSE4_1__

(Windows, Linux)

On Linux, defined as '1' for processors that support Intel® SSE4 instructions.

__SSE4_2__

(Windows, Linux)

On Linux, defined as '1' for processors that support SSSE4 instructions.

__SSSE3__

(Windows, Linux)

On Linux, defined as '1' for processors that support SSSE3 instructions.

unix

__unix

__unix__

(Linux)

Defined as '1'.

__USER_LABEL_PREFIX__

(Linux)

 

_VA_LIST_DEFINED

(Windows)

Defined, no value.

__VERSION__

(Linux)

The compiler version string

__w64

(Windows)

Defined, no value.

__WCHAR_T

(Linux)

Defined as '1'.

_WCHAR_T_DEFINED

(Windows)

Defined when option /Zc:wchar_t is specified or "wctype_t" is defined in the header file.

__WCHAR_TYPE__

(Linux)

On Linux, defined as int on Intel® 64 architecture.

_WCTYPE_T_DEFINED

(Windows)

Defined when "wctype_t" is defined in the header file.

_WIN32

(Windows)

Defined as '1' while building code targeting Intel® 64 architecture.

_WIN64

(Windows)

Defined as '1' while building code targeting Intel® 64 architecture.

__WINT_TYPE__

(Linux)

Defined as unsigned int.

__x86_64

__x86_64__

(Linux)

Defined as '1' while building code targeting Intel® 64 architecture.