[pypy-svn] pypy 32ptr-on-64bit: Initially clearing the nursery: this was lost during the merge.

arigo commits-noreply at bitbucket.org
Sat Jan 29 15:36:44 CET 2011


Author: Armin Rigo <arigo at tunes.org>
Branch: 32ptr-on-64bit
Changeset: r41442:cee7f380bfa2
Date: 2011-01-28 17:51 +0100
http://bitbucket.org/pypy/pypy/changeset/cee7f380bfa2/

Log:	Initially clearing the nursery: this was lost during the merge.

diff --git a/pypy/rpython/memory/gc/minimark.py b/pypy/rpython/memory/gc/minimark.py
--- a/pypy/rpython/memory/gc/minimark.py
+++ b/pypy/rpython/memory/gc/minimark.py
@@ -376,9 +376,11 @@
         # the nursery than really needed, to simplify pointer arithmetic
         # in malloc_fixedsize_clear().  The few extra pages are never used
         # anyway so it doesn't even count.
-        nursery = self.ac.allocate_big_chunk(self._nursery_memory_size())
+        fullsize = self._nursery_memory_size()
+        nursery = self.ac.allocate_big_chunk(fullsize)
         if not nursery:
             raise MemoryError("cannot allocate nursery")
+        llarena.arena_reset(nursery, fullsize, 2)
         return nursery
 
     def allocate_nursery(self):


More information about the Pypy-commit mailing list