LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Underperforming LabVIEW compiler when it comes to buffer allocations

Thanks tst for the links to the other theads - this is obviously a known concern and one has to make sure you use the 'show buffer allocations' often to ensure efficient code.  Especially the second thread where there seemed to be a difference between 7.1 and 8.2 was concerning.  I am eagerly waiting for the next version of LabVIEW to see what it does with this.

I have never tried VI Analyzer - it could be that this also gives tips regarding buffer allocations.

Message Edited by Support on 06-22-2007 08:43 AM

0 Kudos
Message 11 of 15
(1,318 Views)
Here is an example of a different case - a buffer allocation is performed on the entry shift register of a loop.  One can move this outside the loop by simply placing a case statement around the loop that is always true.  See the attached images.  Now I am not sure whether this buffer allocation happens on every cycle or only on the first entry into the loop - if it happens once only this is obviously not an issue.
Download All
0 Kudos
Message 12 of 15
(1,302 Views)
Discusions of performance and buffer allocations and in-placeness require more time than I have at the moment to analyze fully.
 
So lacking time let me share an idea that has worked well for me.
 
I have borrowed the idea of using a "key" to do quick searches.
 
If I am designing my data structures for an application and I see that one of the elements of a cluster will be used to control wether or not I operate on the other elements of the cluster, I'll keep the "key" value in a sepearte array (usually in a shift register).
 
This lets me do seraches on the array of "key" values and then use the results of that search to only opearte on the selected "records" (I am showing my age by using that term!).
 
Ben
Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
Message 13 of 15
(1,280 Views)
This was reported to R&D (# 4BAAPJXP) for further investigation.  A workaround for now is to continue to use "Show Buffer Allocations" and try and remove as many "dots" as possible.
 
Thanks!!
 
Dan
Daniel Eaton
National Instruments
Systems Engineering
Embedded and Industrial Control
Message 14 of 15
(1,023 Views)
I tested the slowdown described in this thread and it appears to have disappeared in LabVIEW 8.6. 

-D
Message 15 of 15
(763 Views)