Re: memory allocations.



On Fri, 2002-03-01 at 14:03, Havoc Pennington wrote:
> Sander Vesik <sv117949 ireland sun com> writes: 
> > Well, as I see it the problem with optimising malloc for startup times is
> > that according to my profiling, at most 1% time of total is spent in
> > malloc during startup of say gedit, while in real use - I opened a 300KB+
> > text file and page-downed to the end - the use grew to 3% of time. 
> 
> If this is gedit2 could you post the top of the profile? (Does it have
> call graph info?)

Havoc et al, I'm a little curious why the fascination with memory
allocation behavior.  As Sander points out, for gedit the total time
spent in malloc is less than 3%.  I would guess this is true across the
board for Gnome apps.. I know it has been for my apps that I've profiled
(including Gnucash).  There's really not that much room for improvement;
even if you decrease total time spent in malloc and friends by 25% you
will only improve overall performance by a fraction of a percent. 

Seems like reducing the number of redundant font loads, repeated network
fetches of the same piece of info, constant path walking to find a
library, etc., provide much more "low-hanging fruit".  I agree that
chunking related allocations can help with fragmentation concerns, but
that seems not to be the focus of this thread. 

Am I missing something?

Thanks,
Bill Gribble







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