10-10-2008 11:21 AM - edited 10-10-2008 11:27 AM
LabVIEW Gurus,
I am continually running into some serious performance hits using property nodes to update attributes of FP objects. Attached is a classic example.
I have 8 XY plots that are being fed 600 SGL points every 200 msec - a very modest data rate. Each plot is a dynamically instanciated .vit placed into one of 8 subpanels in a container VI. The container VI also acts as the data server for the charts, sending each one their data in their own single element queue. The entire architecture runs great (~4% CPU load, see attached picture) until I being updating a property node to display the value of the cursor y-value. When I enable the "Caption.Text" property node of the XY Graph to display the cursor value, the CPU usage soars to over 30%.
As an aside, I am developing on a dual core 2.1GHz platform with 4G memory with LV8.5.1, and the target machine is not nearly as beefy. That's why 30% CPU on my powerhouse is an issue - it basically brings the embedded target to its knees.
I have included an example VI for you to run on your machine. Consider it "representative" of my bigger issues. The VI runs about 10% CPU without the caption update, and 20% with the caption updates.
Finally, I have tried putting the VIs into the UI execution system. I have also tried Defer Panel Updates, but this actually slows down performance.
Best regards,
Jack Dunaway
With Captions

Without Captions:

Solved! Go to Solution.
10-10-2008 11:34 AM
Use captions only for non cyclic display. Using a text indicator should solve the problem.
10-10-2008 11:56 AM
Chris,
Excellent solution - it elegant enough solution to fix my problem. However, I am still perplexed as to why a single property node bumped my CPU from 4% to 33%, even though that PN is only being updated every 200msec (times 8 graphs). Can anyone explain?
Jack
10-10-2008 11:57 AM - edited 10-10-2008 11:58 AM
Yes, property nodes force synchronous execution and if you do that too often, other things suffer.
The above solution is good. You can simplify things even more by removing all that unneeded extra code that just complicates things.
Here's a quick draft. Let me know if you have questions.

10-10-2008 12:01 PM
10-10-2008 12:08 PM
It may also be OS related. When I ran the VI on my Mac I found about 10-11% CPU with the caption updating on and 13-14% with it off. I added a string indicator and it ran at about 8-9% CPU.
LV 8.5 MacPro (Intel) OS X 10.5.5.
Lynn
10-10-2008 12:58 PM - edited 10-10-2008 12:59 PM
Don't forget that the original code has 8 graphs and 8 captions, and thus needs to deal with 8 individual property nodes with each loop iteration. 😮
10-10-2008 01:12 PM
Lynn,
Your performance seems backwards - you mean it runs faster than when it's not updating? Thanks for the feedback - It's good to know that I have some willing benchmarkers.
Christian,
Thank you for your sage advice once again. 10k - money!
and finally Chris,
Thanks again for your solution.
Regards to all,
Jack Dunaway