29.12.2014 Views

RealView Compilation Tools Compiler Reference Guide - ARM ...

RealView Compilation Tools Compiler Reference Guide - ARM ...

RealView Compilation Tools Compiler Reference Guide - ARM ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>Compiler</strong>-specific Features<br />

Table 4-18 Predefined macros (continued)<br />

Name Value When defined<br />

__MODULE__ mod Contains the filename part of the value of __FILE__.<br />

__NO_INLINE__ – When you specify the --no_inline option in GNU mode.<br />

__OPTIMISE_LEVEL num Always set to 2 by default, unless you change the optimization level using the<br />

-Onum option.<br />

__OPTIMISE_SPACE – When you specify the -Ospace option.<br />

__OPTIMISE_TIME – When you specify the -Otime option.<br />

__OPTIMIZE__ – When -O1 or -O2 is specified in GNU mode.<br />

__OPTIMIZE_SIZE__ – When -Ospace is specified in GNU mode.<br />

__PLACEMENT_DELETE – In C++ mode to specify that placement delete (that is, an operator delete<br />

corresponding to a placement operator new, to be called if the constructor<br />

throws an exception) is enabled. This is only relevant when using exceptions.<br />

__PTRDIFF_TYPE__ – In GNU mode. It defines the correct underlying type for the ptrdiff_t typedef.<br />

__RTTI – In C++ mode when RTTI is enabled.<br />

__sizeof_int 4 For sizeof(int), but available in preprocessor expressions.<br />

__sizeof_long 4 For sizeof(long), but available in preprocessor expressions.<br />

__sizeof_ptr 4 For sizeof(void *), but available in preprocessor expressions.<br />

__SIZE_TYPE__ – In GNU mode. It defines the correct underlying type for the size_t typedef.<br />

__SOFTFP__ – If compiling to use the software floating-point calling standard and library. Set<br />

when you specify the --fpu=softvfp option for <strong>ARM</strong> or Thumb, or when you<br />

specify --fpu=softvfp+vfpv2 for Thumb.<br />

__STDC__ – In all compiler modes.<br />

__STDC_VERSION__ – Standard version information.<br />

__STRICT_ANSI__ – When you specify the --strict option.<br />

__TARGET_ARCH_<strong>ARM</strong> num The number of the <strong>ARM</strong> base architecture of the target CPU irrespective of<br />

whether the compiler is compiling for <strong>ARM</strong> or Thumb.<br />

__TARGET_ARCH_THUMB num The number of the Thumb base architecture of the target CPU irrespective of<br />

whether the compiler is compiling for <strong>ARM</strong> or Thumb. The value is defined as<br />

zero if the target does not support Thumb.<br />

<strong>ARM</strong> DUI 0348A Copyright © 2007, 2010 <strong>ARM</strong> Limited. All rights reserved. 4-105<br />

Non-Confidential

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!