In article <5065000000080000005B2B0000-999158726000@exchange.ni.com>, Glen
Baker wrote:
> I have a VI that launches several other VI's (using the .vit trick).
> Occasionally when I stop the master VI I get a pop-up message that
> says something like "Resetting VI". At this point
> LabView hangs for a few minutes(windows won't iconify or move, can't
> do anything related to LabView).
The Reset of Death dialog appears when LabVIEW is waiting for all the subVIs
of the top level resetting VI to finish. This can take a while if, for
instance, a DLL being called by via the Call Library Function node is
blocking and not returning to the diagram that called it. If and when it
returns, LV will eventually finish resetting the VI.
> If I wa
it long enough LabView will eventually come back, but I'd
> really like to know what's going on here.
There is a "problem" in LV 5.1 and beyond that is exposed by programs that
open large numbers of references to VIs without closing them. LabVIEW will
automatically clean up these references for you when the VI goes idle (i.e.,
the top level VI stops normally or is aborted). However, this cleanup
mechanism for VI references unexpectedly became an O(n^2) algorithm in LV
5.1 because of some new code invoked during the cleanup to better manage the
usage of memory. For programs that clean up their own references by closing
them after they are no longer needed, the cleanup mechanism is never even
called. For programs that leave open only a few references, the algorithm
never really gets out of hand and the performance degradation when the
program goes idle is not noticeable. For programs that open thousands of
references without closing them, the algorithm iterates millions of times
(1000's
x 1000's) and this takes a noticeable amount of time (possibly
longer than you are willing to wait).
I suggest you look through your code for Open VI Ref calls that are not
balanced with a Close VI Ref call.
Rob Dye