Table Of Contents

Minimizing SubVI Overhead

Version:
Last Modified: August 9, 2019

Inlining a subVI into its calling VIs helps minimize the overhead associated with calling the subVI.

When you inline a subVI, LabVIEW NXG inserts the compiled code of the subVI into the compiled code of the calling VI. If you then make changes to the subVI, LabVIEW NXG 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.
  • Is a dynamic dispatch VI of a LabVIEW class
Complete the following steps to inline a subVI.
  1. On the Document tab, in the Behavior section, click Properties to access the property settings for the subVI.
  2. Place a checkmark in the Inline subVI into calling VIs checkbox.
  3. Set VI Reentrancy to Stateless or Stateful to configure reentrant execution.
  4. Click OK.

Recently Viewed Topics