08-11-2008 08:12 AM
08-11-2008 11:00 AM
08-11-2008 12:30 PM
I would suggest simply testing it with a large array.
Based on experience with the way these things work in LabVIEW, I wouldn't be surprised if both cases were optimized not to cause data copies. If memory serves (I don't feel like looking it up and I may very well be wrong), an array has the dimension sizes together and then a pointer to the actual data. If that's true, then there shouldn't be a problem splitting it (or deleting either from the start or the end) in-place. You should try looking up the documentation for how LV holds arrays in memory.
This of course might be different for arrays where the elements have variable sizes (e.g. strings, variants, pink clusters).
If you do this research, post back to tell us the results. It might be interesting.
P.S. I seem to remember something about a bug in an older version which caused LabVIEW to leak memory if the bottom output of the Delete primitive was unwired, although I don't remember the specifics. Presumably, this was fixed, and if you don't wire the array out its memory should be freed (within the general memory handling behavior of LabVIEW, of course. If you want to make sure, use the Request Deallocation primitive).
08-11-2008 02:28 PM - edited 08-11-2008 02:30 PM
08-12-2008 04:10 AM
08-12-2008 06:21 AM - edited 08-12-2008 06:27 AM
08-12-2008 08:24 AM
It looks like your system is quite unreliable.
I would suggest getting rid of the smaller arrays. They don't give enough accuracy anyway.
Also, I would advise wiring each of the outputs into an index array and wiring an indicator out of that to have consistent memory allocation.
Additionally, either closing LabVIEW or allocating a large amount of memory for LabVIEW in advance might help.
If you post the VIs, other people can test this too.
08-12-2008 10:48 AM - edited 08-12-2008 10:49 AM
08-12-2008 11:54 AM
08-12-2008 12:53 PM