RE: [Evolution-hackers] mmap() for the summary file



Hi Philip and others, 

>-----Original Message-----
>From: evolution-hackers-bounces gnome org 
>[mailto:evolution-hackers-bounces gnome org] On Behalf Of ext 
>Philip Van Hoof
>Sent: Sunday, June 11, 2006 16:56
>To: evolution-hackers
>Subject: [Evolution-hackers] mmap() for the summary file

>I've been trying to replace the fread()/fopen() implementation 
>in camel-folder-summary.c with an mmap() one.
>
>I know camel-file-utils.c will put duplicate strings in a 
>hashtable and that way reduce memory usage for the summary 
>information. Because a lot mail boxes have duplicate strings 
>for the From and To headers. I know why and how this is 
>implemented. And I understand that this already reduces memory 
>usage a lot.

Hmmmm... I am not really convinced yet; I mean even when I have
100 mails with the same email address in my Inbox (which seems 
a lot from one person!). The email-address would be 20 chars; now having
'm all in one string saves me, even in this extreme case, only
about 2Kb, event forgetting about the overhead of the hash tables etc.

>However. On a small device with few memory resources, the 
>kernel knows better when to allocate and when to deallocate 
>uncachable data like this summary information.
>
>Therefore I propose to replace the implementation with mmap(). 
>Not only I propose it, I also already tried it myself.

[ string proposal ]

Sounds good :-) 

>But anyway ;)

What about having an camel-session at GUADEC, to see what people's
ideas are etc.; recently, it seems more and more people are using
camel directly (without evo), it would be good to sit down and
see how we can streamline this stuff.

Best wishes,
Dirk.



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