05-16-2017 04:11 PM
It's possible that the compiler allocates the memory for the default version of the thing that the DVR refers to. IOW, the memory is available all the time.
At runtime, if the DVR is valid, then the real data is used in place.
If the DVR is NOT value, the preallocated empty space is used, so that the code inside the IPE has something to work with.
When it's time to close the IPE, if the DVR is valid, then the MuTex is released.
If the DVR wasn't valid, then the result is simply discarded.
It depends on whether the time to allocate is worth more than the space wasted.
Blog for (mostly LabVIEW) programmers: Tips And Tricks
05-16-2017 07:39 PM
Look at this thread for more DVR wierdness.
http://forums.ni.com/t5/LabVIEW/LabVIEW-2015-Buffer-Allocation-Bug/m-p/3300392
cheers
mcduff