### inline_depth

Controls how many passes are used to expand inline function calls.

##### Syntax

#pragma inline_depth(n)
#pragma inline_depth(smart)

##### Parameters

n

> Sets the number of passes used to expand inline function calls. The number n is an integer from 0 to 1024 or the smart specifier. It also represents the distance allowed in the call chain from the last function up. For example, if d is the total depth of a call chain, then functions below (d-n) are inlined if they do not exceed the following size settings:

> #pragma inline_max_size(n)
> #pragma inline_max_total_size(n)

> The first pragma sets the maximum function size to be considered for inlining; the second sets the maximum size to which a function is allowed to grow after the functions it calls are inlined. Here, n is the number of statements, operands, and operators in the function, which turns out to be roughly twice the number of instructions generated by the function. However, this number can vary from function to function. For the inline_max_size pragma, the default value of n is 256; for the pragma inline_max_total_size, the default value of n is 10000.

smart

> The smart specifier is the default mode, with four passes where the passes 2-4 are limited to small inline functions. All inlineable functions are expanded if inline_depth is set to 1-1024.

##### Targets

All platforms.

##### Remarks

The pragmas dont_inline and always_inline override this pragma. This pragma corresponds to the Inline Depth setting . The default setting is off.