Re: jemalloc design.

From: Channa <channa.kad_at_gmail.com>
Date: Wed, 26 Nov 2008 18:39:06 +0530
Hi,
Thank you very much for the response.
I have a small doubt as you mentioned "All small objects within each
particular run are of the same size class"
This "run" is inturn a tree ?
And for different size classes different trees are maintained or there
is only one tree root?

I am just trying to understand the code so some doubts.
If could clarify some of these doubts it will be great help for me.

Also i have just ported it to my own library where i checked the performace
of jemalloc on a single processor system.

I observed the performance of linux malloc is good. I have commented all the
debug options in the jemalloc code.

The mailing list discussion below gives more details.

http://www.nabble.com/FreeBSD-performance-on-single-CPU.-td20581044.html

Please help me in this regard.

Thanks in Advance,
Channa


2008/11/26 Jason Evans <jasone_at_freebsd.org>:
> Channa wrote:
>>
>> With small allocations i wanted to know how the bins are arranged??
>> The sentence from the above pdf : "Small allocations are segregated
>> such that each run manages a single size class"
>> means that all the memory regions for
>>  eg: of size 4KB are maintained as a single run in the form of red black
>> tree?
>
> The quoted text is talking about small objects, which are packed together in
> run objects.  All small objects within each particular run are of the same
> size class.  So, one run may contain an array of 16-byte objects, another
> may contain an array of 24-byte objects, and so on.
>
> The small objects within each run are tracked by bitmaps at the beginning of
> each run.  Page runs are tracked by red-black trees.
>
> Jason
>
Received on Wed Nov 26 2008 - 12:09:08 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:38 UTC