9.62 __attribute__((noinline)) constant variable attribute

The noinline variable attribute prevents the compiler from making any use of a constant data value for optimization purposes, without affecting its placement in the object.

This feature can be used for patchable constants, that is, data that is later patched to a different value. It is an error to try to use such constants in a context where a constant value is required. For example, an array dimension.

Examples

__attribute__((noinline)) const int m = 1;
Related reference
9.39 __attribute__((noinline)) function attribute
9.85 #pragma inline, #pragma no_inline
9.25 __declspec(noinline)
Non-ConfidentialPDF file icon PDF versionARM DUI0375E
Copyright © 2007, 2008, 2011, 2012, 2014 ARM. All rights reserved.