15.2.29 Pure Function Attribute

The pure attribute instructs the compiler to perform more aggressive optimizations around invocations of a function when that function has no side effects other than its return value, and the return value is dependent only on parameters and/or (nonvolatile) global variables. Such functions can be indicated with the pure attribute, for example:
void __attribute__ ((pure)) foo(void);