[pypy-commit] pypy concurrent-marksweep: Fix.
arigo
noreply at buildbot.pypy.org
Fri Oct 7 17:36:20 CEST 2011
Author: Armin Rigo <arigo at tunes.org>
Branch: concurrent-marksweep
Changeset: r47862:da95bbaf2858
Date: 2011-10-07 17:33 +0200
http://bitbucket.org/pypy/pypy/changeset/da95bbaf2858/
Log: Fix.
diff --git a/pypy/rpython/memory/gc/concurrentms.py b/pypy/rpython/memory/gc/concurrentms.py
--- a/pypy/rpython/memory/gc/concurrentms.py
+++ b/pypy/rpython/memory/gc/concurrentms.py
@@ -289,8 +289,8 @@
if not block:
raise MemoryError
llarena.arena_reserve(block, size_of_addr)
- block.address[0] = self.free_lists[0]
- self.free_lists[0] = block
+ block.address[0] = self.nonfree_pages[0]
+ self.nonfree_pages[0] = block
result = block + size_of_addr
#
llarena.arena_reserve(result, totalsize)
@@ -395,12 +395,17 @@
# Grab the results of the last collection: read the collector's
# 'collect_heads/collect_tails' and merge them with the mutator's
# 'free_lists'.
- n = 0
+ n = 1
while n < self.pagelists_length:
if self.collect_tails[n] != NULL:
self.collect_tails[n].address[0] = self.free_lists[n]
self.free_lists[n] = self.collect_heads[n]
n += 1
+ #
+ # Do the same with 'collect_heads[0]/collect_tails[0]'.
+ if self.collect_tails[0] != NULL:
+ self.collect_tails[0].address[0] = self.nonfree_pages[0]
+ self.nonfree_pages[0] = self.collect_heads[0]
def collect(self, gen=0):
More information about the pypy-commit
mailing list