[pypy-svn] r68430 - pypy/branch/inline-fastpath-malloc/pypy/jit/backend/llsupport

fijal at codespeak.net fijal at codespeak.net
Wed Oct 14 12:37:59 CEST 2009


Author: fijal
Date: Wed Oct 14 12:37:58 2009
New Revision: 68430

Modified:
   pypy/branch/inline-fastpath-malloc/pypy/jit/backend/llsupport/gc.py
Log:
(arigo, fijal)
Bugfixes. Good, this fixes zrpy_gc tests.


Modified: pypy/branch/inline-fastpath-malloc/pypy/jit/backend/llsupport/gc.py
==============================================================================
--- pypy/branch/inline-fastpath-malloc/pypy/jit/backend/llsupport/gc.py	(original)
+++ pypy/branch/inline-fastpath-malloc/pypy/jit/backend/llsupport/gc.py	Wed Oct 14 12:37:58 2009
@@ -12,7 +12,7 @@
 from pypy.jit.backend.llsupport.descr import GcCache, get_field_descr
 from pypy.jit.backend.llsupport.descr import GcPtrFieldDescr
 from pypy.jit.backend.llsupport.descr import get_call_descr
-from pypy.rlib.rarithmetic import r_ulonglong
+from pypy.rlib.rarithmetic import r_ulonglong, r_uint
 
 # ____________________________________________________________
 
@@ -400,17 +400,19 @@
             gcref = llop1.do_malloc_fixedsize_clear(llmemory.GCREF,
                                         0, size, True, False, False)
             res = rffi.cast(lltype.Signed, gcref)
-            nurs_free = llop1.gc_adr_of_nursery_free(lltype.Signed)
-            return r_ulonglong(nurs_free) << 32 | r_ulonglong(res)
+            nurs_free = llop1.gc_adr_of_nursery_free(llmemory.Address).signed[0]
+            return r_ulonglong(nurs_free) << 32 | r_ulonglong(r_uint(res))
         self.malloc_fixedsize_slowpath = malloc_fixedsize_slowpath
         self.MALLOC_FIXEDSIZE_SLOWPATH = lltype.FuncType([lltype.Signed],
                                                  lltype.UnsignedLongLong)
 
     def get_nursery_free_addr(self):
-        return llop.gc_adr_of_nursery_free(lltype.Signed)
+        nurs_addr = llop.gc_adr_of_nursery_free(llmemory.Address)
+        return rffi.cast(lltype.Signed, nurs_addr)
 
     def get_nursery_top_addr(self):
-        return llop.gc_adr_of_nursery_top(lltype.Signed)
+        nurs_top_addr = llop.gc_adr_of_nursery_top(llmemory.Address)
+        return rffi.cast(lltype.Signed, nurs_top_addr)
 
     def get_malloc_fixedsize_slowpath_addr(self):
         fptr = llhelper(lltype.Ptr(self.MALLOC_FIXEDSIZE_SLOWPATH),



More information about the Pypy-commit mailing list