LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Labview 2013 runaway memory usage

Solved!
Go to solution

Hello all,

 

I have run into a spot of bother with one of my VIs...

Anytime I edit my VIs block diagram memory usage as viewed in task manager increases by approx 200MB until i get an error message stating there is not enough memory to complete this operation (in task manager LabVIEW is show to be using 3.3 GB of memory!).

 

The VI isn't even running it is when I am editing!!

 

My version of LabVIEW is LabVIEW 13.0.1f5 running on a Dell Inspiron-17 i5 CPU with 8GB Ram Windows 10 Home.

 

I have attached a few images showing memory usage increasing as I place an Add function to the block diagram.

 

I am pulling my hair out trying to work out what is going on?  Has anyone come across anything like this before?? 

 

Thanks for looking!

 

Iain 

 

Download All
0 Kudos
Message 1 of 12
(2,501 Views)

Does the same thing happen with a new, empty VI?  If so, I would say you need to reinstall LabVIEW.  If not, I suspect something in your VI is corrupt.  I see some sort of toolkit is being used.  Maybe one of those VIs is corrupt.  You could try deleting those and see what happens.  You might also try recreating the VI.

aputman
------------------
Heads up! NI has moved LabVIEW to a mandatory SaaS subscription policy, along with a big price increase. Make your voice heard.
0 Kudos
Message 2 of 12
(2,459 Views)

Hello,

A new VI doesn't appear to have the problem. I have been trying to systematically remove sub VIs from the main VI but that is proving to be quite difficult as deleting wires/sub VIs causes the memory usage to shoot through the roof and I quickly get the out of memory error. 

I don't particularly want to have to rebuild the VI from scratch, but maybe i'll have to if i can't find the offending article!

0 Kudos
Message 3 of 12
(2,440 Views)

What are you ultimately trying to do here? Is the project you working in a project? If so you can simply do a save as and save the vi structure to a new location. This will take all of the relevant vi's to the new location. This will get rid of any vi's that you are no longer using or have no callers. You need to be a little cautious thought. There may be vi's that are used but are called dynamically.

 

Just a thought.

Tim
GHSP
0 Kudos
Message 4 of 12
(2,433 Views)

I have literally just found the offending item....

I have a waveform chart and when I deleted that saved/re-opened the VI the memory usage had dropped right down to 200MB with no discernible increase when editing the block diagram.

 

I will have to look into why my chart was causing this issue. maybe it holds on to it's data if it's not re-initialised when the VI loads/runs?!

 

0 Kudos
Message 5 of 12
(2,429 Views)

What was the size of the chart history and how many traces does it have?

Message 6 of 12
(2,424 Views)

Hello,

 

The chart has only one plot and using the property node History Data for the chart wired to an array the array is empty when the VI is run.

 

0 Kudos
Message 7 of 12
(2,414 Views)

@Goomba79 wrote:

The chart has only one plot and using the property node History Data for the chart wired to an array the array is empty when the VI is run.


That just clears the history. You can only configure the history size at edit time (right-click..chart history length (default is 1024)) and it determines how much memory gets allocated to for the history data, cleared or not.

What is the datatype? (scalar, waveform, dynamic, etc.)

0 Kudos
Message 8 of 12
(2,404 Views)

Overall, your code scares me. 😮 [Event structure inside case structure inside while loop inside case structure inside while loop] is just not something I would probably do. I am sure there is a better way.

0 Kudos
Message 9 of 12
(2,401 Views)

Hello,

Apologies for my slow response. I had a long weekend and am not allowed to take my work laptop off site!

I have set the chart history length to the lowest possible value (10) as I do not need to keep a history of the data that is being displayed.

The datatype that I am displaying are U16 values produced by an A to D converter on a radio receiver I read over an SPI link.

Thanks,

 

Iain 

0 Kudos
Message 10 of 12
(2,355 Views)