[pypy-svn] r49795 - pypy/branch/lazy-write-barrier/pypy/rpython/memory/gc

arigo at codespeak.net arigo at codespeak.net
Fri Dec 14 17:40:57 CET 2007


Author: arigo
Date: Fri Dec 14 17:40:56 2007
New Revision: 49795

Modified:
   pypy/branch/lazy-write-barrier/pypy/rpython/memory/gc/generation.py
Log:
Oups - cannot use os.write() in the GC, because that allocates RPython strings!
Need to use llop.debug_print().  (Removing the prints now makes sense too.)


Modified: pypy/branch/lazy-write-barrier/pypy/rpython/memory/gc/generation.py
==============================================================================
--- pypy/branch/lazy-write-barrier/pypy/rpython/memory/gc/generation.py	(original)
+++ pypy/branch/lazy-write-barrier/pypy/rpython/memory/gc/generation.py	Fri Dec 14 17:40:56 2007
@@ -38,7 +38,6 @@
                              max_space_size = max_space_size,
                              get_roots = get_roots)
         self.nursery_size = nursery_size
-        self.calls = 0
         assert nursery_size <= space_size // 2
 
     def setup(self):
@@ -295,7 +294,6 @@
             self.remember_young_pointer(addr_struct, newvalue)
 
     def append_to_static_roots(self, pointer, arg):
-        os.write(2, str(self.calls) + "\n")
         self.get_roots.append_static_root(pointer)
 
     def move_to_static_roots(self, addr_struct):
@@ -313,5 +311,4 @@
             oldhdr.tid &= ~GCFLAG_NO_YOUNG_PTRS
         if oldhdr.tid & GCFLAG_NEVER_SET:
             self.move_to_static_roots(addr_struct)
-            self.calls += 1
     remember_young_pointer.dont_inline = True



More information about the Pypy-commit mailing list