|
From: | John W. Eaton |
Subject: | Re: Finding Octave's memory use breakdown |
Date: | Mon, 25 Apr 2016 09:06:34 -0400 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Icedove/38.5.0 |
On 04/24/2016 11:42 PM, LachlanA wrote:
Greetings all, Is there a way to find out where Octave is using memory? I often find that Octave is using say 2GB, but "whos" shows only a few hundred megabytes in variables. I assume that much of it is in the libraries, some is in Octave's own code, some of it is in overhead for variables (like field names in an array of structs), some of it is in parse trees, etc..
What are you looking at to determine that the overall memory usage is 2GB? If I start Octave (running the GUI and built from current development sources with debug symbols) it looks to me like it takes about 100 MB to run, with 80 MB of that being shared. That's the resident and shared memory sizes reported by top. The total virtual size is a little over 1 GB. That doesn't seem terribly large. Are you concerned that it is?
The thing that triggered this post was Kai's suggestion to replace printf by a .m file. The main advantage I can see is to reduce the size of the executable, which got me wondering where the memory all goes.
You might slightly reduce the size of the executable, but there are other considerations, which I have already covered. I really don't think it is worth changing things for this function.
jwe
[Prev in Thread] | Current Thread | [Next in Thread] |