12-18-2008 04:54 PM
Hi
I have a VIT and I get the reference using the Open VI reference. When I change (rename) this back to a VI, and get the reference for it, its much faster. Does the open VI reference takes longer for VITs than VIs in obtaining a reference?
Another question is the same VIT, takes lesser time to get the reference using the Open VI reference in LabVIEW 8.5.1. It takes longer in LV8.6. Why is this happening?
Thanks
Vaa San.
12-18-2008 08:52 PM
Personally, I have never really noticed any inherent time difference between opening a VI and a VIT. Any difference would be due to the fact that opening a VIT always makes a new instance of it in memory. On the other hand, opening a VI is a process of opening a reference to an object that (depending upon the application logic) might already be in memory. Can you show an example of the code you are using?
I can't comment on differences between 8.5.1 and 8.6.
Mike...
12-22-2008 04:34 PM
Hi Mike
I created a test project in which I have a class and a front panel VI, NewTemp.vi (inside a library, NewLibrary). To test the timing of the Open VI reference, I use the test.vi. I open the test.vi and type in the path of the vi, NewTemp.vit and run it. I open the Tools-> Profile->Performance and Memory and I press start before I run test.vi. After running, I click on the snapshot button and see the timings. I then rename NewTemp.vit to NewTemp.vi and check the timings again.
When its just a VI, the timing I see less compared to a VIT. Also, when in LV8.5, this timings are very less. I've attached both versions LV8.5 and LV8.6.
Thanks
Vaa San
12-23-2008 09:30 AM
Hmmm... Yes I see the effect you are talking about. I modified your test VI slightly to average a number (1000) of opening/closing cycles and got the following data:
As sent to me:
vit = 0.05645; vi = 0.02774
Curious about the effects of the classes and libraries I tried removing them and got slight improvements:
vit = 0.03590; vi = 0.02312
Finally I closed the project and ran the test VI by itself:
vit = 0.00737; vi = 0.00337
The thing I want to know is why the nearly order of magnitude improvement caused by not having the project open?
Mike...
12-23-2008 03:52 PM
12-26-2008 02:33 PM
Hi Juan & Mike
Thanks for answering. I have another question. Does the Open VI Reference take longer in LV 8.6 than in LV8.5?
Happy Holidays!
Vaa San.
12-26-2008 04:13 PM
Vaa,
I have not tested this comparison. Have you noticed a time difference between the two?
I don't belive the architecture for Open VI Reference has changed between versions but it is possible.
Regards,
12-26-2008 04:20 PM
Hi Juan
I see the difference in timings between LV 8.5.1 and LV 8.6. It was taking about 20ms to open one of my VITs in LV 8.5.1 and it takes about 70ms for the same VIT in LV 8.6. Since its a lot of time and also my project is large, I'm not sure if I should just use LV 8.5.1 and not switch to 8.6.
Thanks
Vaa San.
12-30-2008 02:14 AM
Hello Vaa,
Let me run a set of tests and investigate a little more about this delay. Just to verify, does the delay occur with every single VIT you open in 8.6 compared to 8.5?
Regards,
12-30-2008 12:53 PM
Yes. For all the VITs, the LV 8.6 was slower than LV 8.5 in obtaining references thru the Open VI Reference.
Thanks
Vaa San.