OSDN Git Service

Eliminate the post-zygote heap and reuse the zygote allocation heap
authorCarl Shapiro <cshapiro@google.com>
Fri, 5 Feb 2010 03:12:55 +0000 (19:12 -0800)
committerCarl Shapiro <cshapiro@google.com>
Fri, 5 Feb 2010 23:46:50 +0000 (15:46 -0800)
commitc8e06c8dba30f01d3cf6506c553041c340b312af
tree343dde0f9a8113ec2e735790d6d2df94f2f56d44
parentafec3ea90946f8676105b097a33eb318743b5b10
Eliminate the post-zygote heap and reuse the zygote allocation heap
for application allocations.  Previously, applications were given
their own heap separate from the zygote.  However, the zygote never
allocates more than 10s of objects most of which quickly become
garbage.  After an application fork, these objects are reclaimed,
dirtying the pages they and their malloc structures reside on.  This
is a further win for the GC as it results in one fewer mspace to
considered for range checks and bitmap traversals.
vm/alloc/Alloc.c
vm/alloc/Heap.c
vm/alloc/Heap.h
vm/alloc/HeapSource.c
vm/alloc/HeapSource.h