Search All of the Math Forum:
Views expressed in these public forums are not endorsed by
Drexel University or The Math Forum.
|
|
ben
Posts:
111
Registered:
12/9/05
|
|
Re: Memory leak in Matlab
Posted:
May 15, 2008 3:45 AM
|
|
Thanks for your suggestion. Still, the problem persists. The problem must have something to do with jvm, but its not the totalMemory used by JVM which is just a neglible 200Mb and stays rather constant. I am loosing 100Mb of mem with each function call!
Bye Ben
On May 15, 12:35 am, "us " <u...@neurol.unizh.ch> wrote: > ben: > <SNIP (jvm?) memory problems... > > > I tested R2007b and R2008a. Strangely enough, the problem > > did not occur when the java virtual machine was not loaded. > > > Which tests would you suggest... > > one of the (possible) solutions > > % try to look at and free some jvm memory > hdr={ > 'max = mem JVM will try to use:' > 'total = mem in JVM:' > 'free = mem in system:' > 'delta = mem freed' > }; > import java.lang.*; > r=Runtime.getRuntime; > mem1=[r.maxMemory,r.totalMemory,r.freeMemory,0]; > disp([hdr,num2cell(mem1).']); > disp('> GARBAGE COLLECTING...'); > r.gc; > mem2=[r.maxMemory,r.totalMemory,r.freeMemory,0]; > mem2(end)=mem2(3)-mem1(3); > disp([hdr,num2cell(mem2).']); > > just a thought... > us
|
|
|
Date
|
Subject
|
Author
|
|
5/14/08
|
|
ben
|
|
5/14/08
|
|
us
|
|
5/15/08
|
|
ben
|
|
5/15/08
|
|
ML
|
|
|