Re: [Evolution-hackers] ... and how camel should be



On Tue, 2006-02-14 at 21:15 +0100, Philip Van Hoof wrote:
> On Tue, 2006-02-14 at 14:03 -0500, Lee Revell wrote:

> > Do you think that's a problem?
> 
> For evolution, it might be a lesser problem than for camel. I'd like to
> start using camel on mobile devices.

Let me illustrate this specific case . . .

Imagine .. a mobile device as 50 MB ram (that's a lot for some devices).

Now your library has a function like this:

GPtrArray *give_ids (void);

It will return pointers to 7MB  of strings like this:

"0", "1", "2", ... "10000"

Wouldn't it be better if I could simply do this then?

gint give_length (void);

for (int a=0; a < give_length(); a++)
{
	/* or whatever fast implementation */
	gchar *id = g_strdup_printf ("%d", a);

	/* my stuff */

	g_free (id); 
}

No? Because, that would safe me a 7 MB allocation on a device that has
50 MB of ram it REALLY wants to use for other purposes (believe me, if
on such a device you don't have to waste it like that, you DON'T waste
it like that).

Now .. I payed money for the memory in my desktop. Imagine EVERY
application wasting 7MB of memory. At this moment I have 24 applications
running. If they would all start doing things like that only ONCE, it
would waste +- 168 MB of ram. That's +- 15 euros.

Now lets take a look at the "One Laptop Per Child" project. 

We can save some euros by fixing this flaw. We can make it possible to
give poor children a very good E-mail client that uses camel.

Is it still not worth fixing?


I "strongly" disagree.


-- 
Philip Van Hoof, software developer at x-tend 
home: me at pvanhoof dot be 
gnome: pvanhoof at gnome dot org 
work: vanhoof at x-tend dot be 
http://www.pvanhoof.be - http://www.x-tend.be




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