I can confirm this for 2.1.55 on OS X:
for t=1:10000000, y=1; doit2; end
where doit2.m contains:
x = y;
By running top in another terminal, I see the memory consumption
increasing with time.
Paul Kienzle
address@hidden
On May 15, 2004, at 2:49 PM, David J.C. MacKay wrote:
octave memory leak
There is a memory leak problem in octave versions 2.1.33 and 2.0.16.
To experience the problem, create the following three files (also
available in the test.tar file in
http://www.inference.phy.cam.ac.uk/mackay/octave/index.html) and run
test0 in octave.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%
% test0.m Program to demonstrate memory leak in octave
versions 2.1.33 and 2.0.16
% This is one of three files: test0.m, doit.m, and
doit2.m
% To demonstrate the memory leak, please run
% octave:> test0
% David MacKay address@hidden
T=10000000;
for t=1:T
doit;
endfor
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% doit.m
y=1;
doit2;
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% doit2.m
x=y;
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
--
-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
David J.C. MacKay address@hidden
http://www.inference.phy.cam.ac.uk/mackay/
Cavendish Laboratory, Madingley Road, Cambridge CB3 0HE. U.K.
(01223) 339852 | fax: 354599 | home: 740511 international: +44 1223
-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.
Octave's home on the web: http://www.octave.org
How to fund new projects: http://www.octave.org/funding.html
Subscription information: http://www.octave.org/archive.html
-------------------------------------------------------------
-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.
Octave's home on the web: http://www.octave.org
How to fund new projects: http://www.octave.org/funding.html
Subscription information: http://www.octave.org/archive.html
-------------------------------------------------------------