Minimizing SubVI Overhead
- Updated2023-02-17
- 1 minute(s) read
Minimizing SubVI Overhead
Inlining a subVI into its calling VIs helps minimize the overhead associated with calling the subVI.
When you inline a subVI, G Web Development Software inserts the compiled code of the subVI into the compiled code of the calling VI. If you then make changes to the subVI, G Web Development Software recompiles all calling VIs of that subVI to include those changes. Essentially, inlining a subVI removes the need to call the subVI at run time. Instead, the subVI code executes inside the compiled code of the calling VI.
A subVI that you want to inline cannot have any of the following characteristics:
- Contains recursion
- Contains certain diagram nodes, such as control references. These nodes generate edit-time error messages if you enable subVI inlining.
- On the Document tab, in the Behavior section, click Properties to access the property settings for the subVI.
- Place a checkmark in the Inline subVI into calling VIs checkbox.
- Set VI Reentrancy to Stateless or Stateful to configure reentrant execution.
- Click OK.