From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Timed loop/timed sequence memory leak question

Hello all,

 

I'm using a timed loop to execute image acquisitions at a fixed interval - using Labview 8.5.1.  My app is leaking (slow drip) memory and I'm trying to determine if this might be it.

 

I read from NI that timed structures may leak memory (ref 43026 4FIIUH7N, http://zone.ni.com/devzone/cda/tut/p/id/8192#43026_by_Date) and the corrective action is resolved in version 8.6.1 (which isn't practical right now to upgrade) so I would like to work around if needed.  My question is twofold:

   1) Is the DLL used by the timed structure the same used by the timed loop?

   2) If I call the attached sub VI every 5 seconds or so, am I truly loading the DLL everytime this VI is called?  (I don't think I am...)

 

I've attached the sub VI (note that I dispose of the created image references outside of this sub VI).

 

Any help is appreciated - thanks.

 

VG

 

 

0 Kudos
Message 1 of 3
(2,392 Views)

Update - I ran a test overnight and observed thru the Profile Performance and Memory Window that the max bytes from on of my sub VIs spiked big (but the minimum and average were steady??)  Smiley Indifferent  I've also attached screenshot (don't have the entire file, sorry).

 

I guess I'm unclear (and this might be better served in a different thread) on how to interpret the information from the performance window:

 

Does this spike in max bytes necessarily indicate a memory "leak" (or stack)?

 

Thanks,

 

VG

 

 

Message Edited by VisionGumby on 02-03-2010 09:38 AM
Message Edited by VisionGumby on 02-03-2010 09:38 AM
Download All
0 Kudos
Message 2 of 3
(2,373 Views)

Hello VG,

 

I don't know about the memory leak but I do know that the timed loop will have no effect on the system as far as limiting the acquisition to a certain time interval. There will be one limiting factor which will either allow the loop to run at a certain rate or slow it down. That is the time required for processing the images.

 

If all that happens in the loop is acquisition, it will go at the rate desired. If there is processing in the loop and that processing goes faster than the acquisition than it will continue at the desired rate of acquisition. If the processing goes slower than the desired rate then it will have to be done in another loop in order to not slow down the acquisition.

 

If processing is done in a different loop, precautions must be taken to prevent images from getting lost or overwritten.

Vince M
Applications Engineer
0 Kudos
Message 3 of 3
(2,306 Views)