Company Events Academic Community Support Solutions Products & Services Contact NI MyNI

Mass Compiling VIs

LabVIEW 2013 Help

Edition Date: June 2013

Part Number: 371361K-01

»View Product Info

When you mass compile VIs, LabVIEW verifies the existence of any subVIs and relinks the subVIs to the main VI. Relinking subVIs to the main VI decreases loading time because LabVIEW does not have to search for those VIs. LabVIEW also updates VIs to the version of LabVIEW you use. LabVIEW detects and reports corrupted VIs, which LabVIEW cannot load. If LabVIEW locates corrupted VIs, you can restore them from a backup.

Certain circumstances, such as upgrading a VI to a newer version of LabVIEW, require LabVIEW to recompile a VI when the VI first loads. LabVIEW continues to recompile the VI each time the VI loads until you save the VI. If you expect LabVIEW to recompile many VIs on load, you might want to compile and save all the VIs at the same time to avoid these tasks at a later time. When you simultaneously compile and save a collection of VIs, you are mass compiling the VIs.

Complete the following steps to mass compile a directory of VIs or an LLB.

  1. Select Tools»Advanced»Mass Compile to display the Mass Compile dialog box.
  2. Navigate to the directory of VIs or LLB you want to compile.
    • Navigate into a folder and click the Current Folder button to update all the VIs and LLBs in that folder.
    • Select a .llb file to update all the VIs in that LLB. Select the open folder icon labeled VI with a single period to the right and click the Select button.
  3. (Optional) Place a checkmark in the Log Results checkbox and select the desired location to store a log of the mass compile operation.
  4. (Optional) Place a checkmark in the Cache VIs checkbox and enter the number of VIs you want LabVIEW to store in memory. Caching VIs can significantly decrease the execution time of a mass compile because LabVIEW does not have to load cached VIs when you compile a top-level VI.
  5. Click the Mass Compile button to mass compile the VIs.
    Note  If you receive messages under the Status tab, open the VI listed. If the VI has an error, fix the error in the VI before trying to mass compile again.
  6. Click the Done button to return to LabVIEW.

When you mass compile VIs, the Status tab of the Mass Compile dialog box displays a log of warning messages for the mass compile operation. For example, the log can report corrupted VIs and VIs that were loaded from the search directories instead of the path specified in the calling VI. You can mass compile to detect unexpected behavior in VIs you compile, such as VIs that break or load from unexpected locations.

You also can use the Mass Compile method to load and compile VIs in a directory programmatically.

Mass Compile Operation Order

LabVIEW mass compiles only VIs last saved in a previous version of LabVIEW and VIs with unsaved changes that would result in a recompile when you open them. When LabVIEW mass compiles a directory of VIs, it processes files in the following order at each level of the directory hierarchy:

  • LabVIEW project files—When LabVIEW encounters a project, LabVIEW processes the project file, then all files owned by the project in the order they appear in the project tree of the Project Explorer window. Project- and target-specific settings defined by the project such as conditional disable symbols can affect how the files are compiled, such as by specifying the platforms or processor LabVIEW uses to execute the VI.
  • Files within subdirectories—LabVIEW processes subdirectories one by one in alphabetical order. For example, if a directory contains folders B and F, LabVIEW processes the files in B in alphabetical order, then the files in F in alphabetical order.
  • Any remaining files at that level of the directory, in alphabetical order

 

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
Add Comments 1 2 3 4 5 submit