The following predefined macros are provided to facilitate porting applications between platforms.

Predefined Macro Name Description
__ALTIVEC__ Defined to 1 by the compiler if VMX support is enabled. Otherwise it is not defined.
_ARCH_403 Defined to 1 if the processor architecture is PowerPC.
_ARCH_602 Defined to 1 if the processor architecture is PowerPC.
_ARCH_603 Defined to 1 if the processor architecture is PowerPC.
_ARCH_604 Defined to 1 if the processor architecture is PowerPC.
_ARCH_COM Defined to 1 if the processor architecture is PowerPC.
_ARCH_P2SC Defined to 1 if the processor architecture is PowerPC.
_ARCH_PPC Defined to 1 if the processor architecture is PowerPC.
_ARCH_PPC64 Defined to 1 if the processor architecture is PowerPC.
_ARCH_PPCGR Defined to 1 if the processor architecture is PowerPC.
_ARCH_PPC64GR Defined to 1 if the processor architecture is PowerPC.
_ARCH_PPC64GRSQ Defined to 1 if the processor architecture is PowerPC.
_ARCH_PWR Defined to 1 if the processor architecture is PowerPC.
_ARCH_PWR2 Defined to 1 if the processor architecture is PowerPC.
_ARCH_PWR2S Defined to 1 if the processor architecture is PowerPC.
_ARCH_PWR3 Defined to 1 if the processor architecture is PowerPC.
_ARCH_PWR4 Defined to 1 if the processor architecture is PowerPC.
_ARCH_PWR5 Defined to 1 if the processor architecture is PowerPC.
_ARCH_PWR5+ Defined to 1 if the processor architecture is PowerPC.
_ARCH_RS64A Defined to 1 if the processor architecture is PowerPC.
_ARCH_RS64B Defined to 1 if the processor architecture is PowerPC.
_ARCH_RS64C Defined to 1 if the processor architecture is PowerPC.
__BASE_FILE__ Defined to the fully qualified filename of the primary source file.
_BIG_ENDIAN Defined to 1.
__BIG_ENDIAN__ Defined to 1.
_CALL_SYSV Defined to 1.
__CHAR_UNSIGNED__ Defined to 1 if the option -qchars=unsigned or #pragma chars(unsigned) is in effect. This macro is undefined if the option -qchars=signed or #pragma chars(signed) is in effect.
__EXCEPTIONS

C++ only

Defined to 1 if the -qeh option is in effect. Otherwise it is not defined.
__OPTIMIZE__ Defined to 2 for optimization level -O or -O2, or to 3 for optimization level -O3 or higher.
__OPTIMIZE_SIZE__ Defined to 1 if the options -qcompact and -O are set. Otherwise it is not defined.
__powerpc Defined to 1.
__powerpc__ Defined to 1.
__powerpc64__ Defined to 1 when compiling in 64-bit mode. Otherwise it is not defined.
__PPC Defined to 1.
__PPC__ Defined to 1.
__PPC64__ Defined to 1 when compiling in 64-bit mode. Otherwise it is not defined.
__SIZE_TYPE__ Defined to the underlying type of size_t on this platform. On this platform, the macro is defined as long unsigned int.In 32-bit mode, the macro is defined as unsigned int. In 64-bit mode, the macro is defined as long int. The compile mode is controlled by the -q32 and -q64 options.
__unix Defined to 1 on all UNIX-like platforms. Otherwise it is not defined.
__unix__ Defined to 1 on all UNIX-like platforms. Otherwise it is not defined.
__VEC__ Defined to 10205 by the compiler if AltiVec support is enabled, indicating that the compiler implements the AltiVec Programming Interface model. Otherwise it is not defined.