1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-17 10:26:15 +00:00
freebsd/lib/libthr
Jason Evans d6742bfbd3 Add thread-specific caching for small size classes, based on magazines.
This caching allows for completely lock-free allocation/deallocation in the
steady state, at the expense of likely increased memory use and
fragmentation.

Reduce the default number of arenas to 2*ncpus, since thread-specific
caching typically reduces arena contention.

Modify size class spacing to include ranges of 2^n-spaced, quantum-spaced,
cacheline-spaced, and subpage-spaced size classes.  The advantages are:
fewer size classes, reduced false cacheline sharing, and reduced internal
fragmentation for allocations that are slightly over 512, 1024, etc.

Increase RUN_MAX_SMALL, in order to limit fragmentation for the
subpage-spaced size classes.

Add a size-->bin lookup table for small sizes to simplify translating sizes
to size classes.  Include a hard-coded constant table that is used unless
custom size class spacing is specified at run time.

Add the ability to disable tiny size classes at compile time via
MALLOC_TINY.
2008-08-27 02:00:53 +00:00
..
arch Commit missing mips libthr support that I thought I'd committed earlier 2008-05-11 05:54:52 +00:00
support Use thr_new syscall to create a new thread, obscure context operations 2005-04-23 02:48:59 +00:00
sys __error could be called too early before libthr is initialized, test 2006-07-12 03:44:05 +00:00
thread Add thread-specific caching for small size classes, based on magazines. 2008-08-27 02:00:53 +00:00
libthr.3 - Stop calling libthr alternative as it's now the default 2007-10-22 10:13:38 +00:00
Makefile Enable GCC stack protection (aka Propolice) for userland: 2008-06-25 21:33:28 +00:00
pthread.map Make pthread_cleanup_push() and pthread_cleanup_pop() as a pair of macros, 2008-06-09 01:14:10 +00:00