Get the Benchmarking Right (Real-Time Module)

LabVIEW 2017 Real-Time Module Help

Edition Date: March 2017

Part Number: 370622R-01

»View Product Info
Download Help (Windows Only)

Before deploying a real-time application, you need to know that the application meets your timing requirements consistently over an extended execution period. This topic describes best practices for benchmarking the performance and determinism of an RT application.

Note  Avoid execution highlighting while analyzing execution times. Execution highlighting significantly slows execution.

Benchmark with Deployment Settings

Before benchmarking an RT application, switch to deployment settings to ensure that your benchmarks accurately reflect the performance of the final application.

Using the RT Benchmarking Example

National Instruments recommends benchmarking the entire contents of a time-sensitive loop before deploying your application. Use the RT Benchmark example project as a starting point when benchmarking code that will be included in a time-sensitive loop. The RT Benchmark example is designed to provide accurate average-case and worst-case jitter execution time over thousands of iterations. Refer to the Benchmark Project.lvproj in the labview\examples\Real-Time Module\RT Benchmarking directory.

National Instruments created the RT Benchmark example project as a tool for benchmarking code that needs to run deterministically. You also can use this project to benchmark non-time-critical code. However, first change the priority of the benchmarking VI to match the priority at which the code will run in your application. Use the Priority pull-down menu on the Execution page of the VI Properties dialog box to set the priority of a VI.

Note  To benchmark non-looping code, use the RT Get Timestamp VI or the Tick Count VI. To benchmark a Timed Structure, use the built-in timing terminals of the structure.

Using the Real-Time Trace Viewer

Use the Real-Time Trace Viewer VIs to capture the timing and execution data of VI and thread events for applications running on an RT target. The Real-Time Trace Viewer displays the timing and event data, or trace session, on the host computer. In LabVIEW, select Tools»Real-Time Module»Trace Viewer to display the Real-Time Trace Viewer.

For a mapping of thread names across different operating systems, refer to the KnowledgeBase.

Using the NI Distributed System Manager

Use the NI Distributed System Manager to monitor CPU and memory usage, alerts, VI states, and shared variables on an RT target. Select Tools»Distributed System Manager to display the NI Distributed System Manager.


Not Helpful