Controlling Inline Expansion of User Functions

The compiler enables you to control the amount of inline function expansion, with the options shown in the following summary.

Option

Effect

-ip_no_inlining

This option is only useful if -ip or -ipo is also specified. In such case, -ip_no_inlining disables inlining that would result from the -ip interprocedural optimizations, but has no effect on other interprocedural optimizations.

-inline_debug_info

Preserve the source position of inlined code instead of assigning the call-site source position to inlined code.

-Ob{0|1|2}

Controls the compiler's inline expansion. The amount of inline expansion performed varies as follows:

-Ob0: disables inline expansion of user-defined functions; however, statement functions are always inlined.

-Ob1: disables inlining unless -ip or -Ob2 is specified. Enables inlining of functions (routines). This is the default.

-Ob2: enables inlining of any routine at the compiler's direction: the compiler decides which functions are inlined. This option enables interprocedural optimizations and has the same effect as specifying the -ip option.

IA-32 only:
-ip_no_pinlining

Disables partial inlining; can be used if -ip or -ipo is also specified.