jasone 2008-03-07 22:39:39 UTC FreeBSD src repository
Modified files: (Branch: RELENG_7) lib/libc/gen Symbol.map lib/libc/stdlib malloc.3 malloc.c lib/libkse kse.map lib/libkse/sys lock.c lock.h lib/libkse/thread thr_cond.c thr_init.c thr_kern.c thr_mutex.c thr_rtld.c lib/libthr pthread.map lib/libthr/thread thr_mutex.c Log: MFC: Merge malloc(3) improvements and fixes. The highlights are: * Avoid re-zeroing memory in calloc() when possible. * Use pthread mutexes where possible instead of libc "spinlocks", and actually spin some during contention before blocking. * Implement dynamic load balancing of thread-->arena mapping. * Avoid floating point math in order to avoid increased context switch overhead for applications that otherwise would not use floating point math. * Restructure how sbrk() and mmap() are used to acquire memory mappings. This provides a way to force malloc to only use sbrk(), which can be useful in the context of resource limits. * Reduce the number of mmap() calls typically necessary when allocating a chunk. * Track dirty unused pages so that they can be purged if they exceed a threshold. * Try to realloc() large objects in place. * Manage page runs with trees instead of chunk maps, which allows logarithmic-time run allocation. Revision Changes Path 1.6.2.1 +1 -0 src/lib/libc/gen/Symbol.map 1.73.2.1 +95 -36 src/lib/libc/stdlib/malloc.3 1.147.2.2 +2283 -1341 src/lib/libc/stdlib/malloc.c 1.1.2.1 +1 -0 src/lib/libkse/kse.map 1.11.2.2 +4 -3 src/lib/libkse/sys/lock.c 1.8.2.1 +1 -1 src/lib/libkse/sys/lock.h 1.57.2.1 +1 -1 src/lib/libkse/thread/thr_cond.c 1.76.2.1 +4 -4 src/lib/libkse/thread/thr_init.c 1.125.2.2 +5 -5 src/lib/libkse/thread/thr_kern.c 1.53.2.2 +30 -7 src/lib/libkse/thread/thr_mutex.c 1.7.2.1 +1 -1 src/lib/libkse/thread/thr_rtld.c 1.18.2.1 +1 -0 src/lib/libthr/pthread.map 1.54.2.3 +23 -6 src/lib/libthr/thread/thr_mutex.c _______________________________________________ cvs-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/cvs-all To unsubscribe, send any mail to "[EMAIL PROTECTED]"