Re: Low memory hacks



Bastien Nocera wrote:
On Mon, 2008-03-17 at 00:56 +0000, Simos Xenitellis wrote:
On Sun, Mar 16, 2008 at 11:25 PM, Bastien Nocera <hadess hadess net> wrote:
 On Sun, 2008-03-16 at 14:02 +0000, Simos Xenitellis wrote:
 <snip>

That is a saving of at least 3M in memory.
 >
 > The stripping of "unneeded" messages is good, and should happen at the
 > package generation level (not in GNOME, or when creating tarballs).

 You talk about memory savings, but do calculations based on file sizes.
 That's doesn't work.
Aren't mo files mapped to memory?

Yes, they're mapped. That doesn't result in actual memory usage. The
kernel will make sure they're only read into memory as needed.
Is there a tool that shows which pages are in memory and which are in swap?
I do not know of such a tool, so I would expect the worst case scenario of all pages being in memory.

The messages in a .mo file are in no specific order, so I would expect that within a page there should be at least a message an application requires at any time.

The important part, however, is that when a translation is exactly the same with the original message, then this entry is not required to exist in the MO file; the running application can find the original message withing the application itself. By stripping the MO file of such messages, the file size reduces and most probably there is reduction in memory use (between 0 to .mo file size).

Is this description clear? Do you think that the savings would be so minimal that one would not need to bother working on this?

Simos



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]