| |||
| Home > ARM Compiler Reference > GNU extensions to the ARM compiler > Builtin functions | |||
This section describes the GNU builtin functions that are supported:
You can use the builtin function __builtin_constant_p to
determine if a value is known to be constant at compile-time. The
argument of the function is the value to test. The function returns
the integer 1 if the argument is known to be a compile-time constant and
0 if it is not known to be a compile-time constant. A return of
0 does not indicate that the value is not a constant, but that the
compiler cannot prove it is a constant with the specified value
of the -O option.
int Other_Builtins_2(int a)
{
const int aconst =10;
int notconst =20;
static int aresult ;
static int notresult;
aresult= aconst;
aresult += notconst;
aresult = __builtin_constant_p (aconst);
notresult = __builtin_constant_p (notconst);
return (aresult+notresult);
}
Supported in GNU mode only.
See Return and frame addresses for details.
See Return and frame addresses for details.