LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Confusing output from LabVIEW profiler

Solved!
Go to solution

I'm trying to profile the timing of a certain VI and getting very confusing results.

The VI is supposed to do something fairly basic: turn on the output of a lock-in amplifier, sweep through some frequencies on that lock-in, plot the results, and turn the lock-in off again.  I'm attaching screenshots of the front panel and back panel.

 

This VI sweeps more slowly than a program supplied by the lock-in manufacturers and I'm trying to figure out why, so I decided to use the profiling tool.

 

This is the confusing part: the VI takes over a minute to run, but the profiler says the run time is under a second, including subVIs.  Am I completely misunderstanding what the profile readout means?  Any help is appreciated!

Download All
0 Kudos
Message 1 of 5
(3,246 Views)
Solution
Accepted by topic author sylviakl

I'm pretty sure the value you see in the Profile is "CPU time used" not "execution time".

 

Basically that means your program is sitting idle waiting for something external the vast majority of the time.

 

As such, either your program is spending a lot of time idling and waiting for some sort of communication from the hardware, or it's using external DLLs to do processing which I don't think that tracks.

0 Kudos
Message 2 of 5
(3,230 Views)

Ah, that makes sense.  Do you know if there's a simple way to profile the hardware communication time?  If that's the major time-sink, I want to figure out how to improve it.

0 Kudos
Message 3 of 5
(3,214 Views)

Open up your SubVIs and use this method around different parts of the code to see what has the longest wait times.

 

 

Message 4 of 5
(3,209 Views)

Thank you!

0 Kudos
Message 5 of 5
(3,183 Views)