[pypy-svn] r65041 - in pypy/branch/tagged-pointers-framework/pypy: config rpython/memory/gc

cfbolz at codespeak.net cfbolz at codespeak.net
Mon May 4 23:35:44 CEST 2009


Author: cfbolz
Date: Mon May  4 23:35:44 2009
New Revision: 65041

Modified:
   pypy/branch/tagged-pointers-framework/pypy/config/pypyoption.py
   pypy/branch/tagged-pointers-framework/pypy/rpython/memory/gc/base.py
Log:
In theory, this should be enough. In practise, it obviously segfaults.


Modified: pypy/branch/tagged-pointers-framework/pypy/config/pypyoption.py
==============================================================================
--- pypy/branch/tagged-pointers-framework/pypy/config/pypyoption.py	(original)
+++ pypy/branch/tagged-pointers-framework/pypy/config/pypyoption.py	Mon May  4 23:35:44 2009
@@ -186,8 +186,7 @@
 
         BoolOption("withsmallint", "use tagged integers",
                    default=False,
-                   requires=[("translation.gc", "boehm"),
-                             ("objspace.std.withprebuiltint", False)]),
+                   requires=[("objspace.std.withprebuiltint", False)]),
 
         BoolOption("withprebuiltint", "prebuild commonly used int objects",
                    default=False),

Modified: pypy/branch/tagged-pointers-framework/pypy/rpython/memory/gc/base.py
==============================================================================
--- pypy/branch/tagged-pointers-framework/pypy/rpython/memory/gc/base.py	(original)
+++ pypy/branch/tagged-pointers-framework/pypy/rpython/memory/gc/base.py	Mon May  4 23:35:44 2009
@@ -178,7 +178,7 @@
 
     def points_to_valid_gc_object(self, addr):
         pointsto = addr.address[0]
-        return pointsto != NULL
+        return pointsto != NULL and llmemory.cast_adr_to_int(pointsto) & 1 == 0
 
     def debug_check_consistency(self):
         """To use after a collection.  If self.DEBUG is set, this



More information about the Pypy-commit mailing list