[Prev][Next][Index][Thread]

Re: Request for suggestions



Just my two cents on the malloc thing:

While your malloc/free performance may not be doing well, the linked
list malloc serves its original purpose quite well. At the level of
device buffer space allocation, one doesn't see a lot of malloc/free
behavior, and minimal space overhead is much to be desired. You are now
introducing an application that has different requirements.

What I want to suggest is that this may be an appropriate place for
layering. While your app needs a different malloc implementation, it
doesn't necessarily follow that the underlying one should be replaced.
Perhaps the new malloc should be build by using the old one to obtain
the malloc arenas?

Alternatively, if you are going to go to the trouble of introducing a
new malloc implementation, I would *strongly* encourage you to look at
the slab allocator, and in particular at the revised version that will
shortly be published in the upcoming USENIX conference (paper by Bonwick
and Adams), which has some wonderful multiprocessor and locality
implications.  We nearly adopted it into EROS, but in the end decided to
dekernelize instead.


Jonathan

References: