Re: memory allocations.
- From: Chris Chabot <chabotc reviewboard com>
- To: Havoc Pennington <hp redhat com>
- Cc: iain <iain ximian com>, gnome-hackers gnome org
- Subject: Re: memory allocations.
- Date: Wed, 27 Feb 2002 20:03:31 +0100
Havoc Pennington wrote:
iain <iain ximian com> writes:
I'm not sure where this could go, possibly in g_thread_init add a call
to g_mem_set_vtable which switches to the faster malloc?
That would make malloc unthreadsafe as soon as you turned on
threading. ;-) Maybe not a great idea...
However, looking at the amount of mallocs happening duing the startup of
even the simplest gnome2 app, does indicate this could be a big
For example, a few malloc counts, for just starting up an app, measured
yelp: 55000 (!)
gedit: 19000 (plus 7 a second when the window is active (?))
(!!) gnome-system-monitor, in process view, generates 2500 mallocs per
second (!!), this is kinda silly and asking for large memory fragmentation?
btw, by comparisment, starting up gdict (gnome1 version) generates 6000
mallocs. this is less then 50% of the malloc count for its gnome2 version.
] [Thread Prev