[Mono-dev] Use eglib as a default for mono 2.6

Miguel de Icaza miguel at novell.com
Thu Apr 23 16:56:14 EDT 2009


Hello,

> > glib today features a very powerful slab allocator, and this slab
> > allocator does have a performance gain in things like the mcs bootstrap
> > test.
> 
> I'm not familiar with glib, but is that allocator some rocket science
> that can't be matched in performance by using some other allocators
> (dlmalloc, nedmalloc, hoard, ...)?

I do not think we need to be rocket scientists, we just need to be good
artisans and make sure that we do not regress.

Slab allocators typically work by having a stronger relationship between
the client and the allocator.   Instead of the trivial API "Give me N
bytes", the API is "I will be allocating lots of structures of size X",
so these allocators are turned for allocating blocks of a fixed size.

This happens for example when allocating lots of nodes for a hashtable,
or a linked list for example.     This paper describes the original
introduction of Slab allocation into the Solaris kernel, where it became
popular:

http://www.sagecertification.org/publications/library/proceedings/bos94/full_papers/bonwick.ps

Miguel.



More information about the Mono-devel-list mailing list