[pypy-commit] pypy gc-forkfriendly: Initialize the GC remote_flags pointer...
devin.jeanpierre
pypy.commits at gmail.com
Thu Jun 2 01:58:12 EDT 2016
Author: Devin Jeanpierre <jeanpierreda at gmail.com>
Branch: gc-forkfriendly
Changeset: r84875:bbf96bee2300
Date: 2016-06-01 21:46 -0700
http://bitbucket.org/pypy/pypy/changeset/bbf96bee2300/
Log: Initialize the GC remote_flags pointer...
diff --git a/rpython/memory/gc/incminimark_remoteheader.py b/rpython/memory/gc/incminimark_remoteheader.py
--- a/rpython/memory/gc/incminimark_remoteheader.py
+++ b/rpython/memory/gc/incminimark_remoteheader.py
@@ -31,11 +31,12 @@
def init_gc_object(self, adr, typeid16, flags=0):
incminimark.IncrementalMiniMarkGCBase.init_gc_object(self, adr, typeid16, flags)
+ hdr = llmemory.cast_adr_to_ptr(adr, lltype.Ptr(self.HDR))
# This gets compiled to nonsense like (&pypy_g_header_1433.h_tid)
- # at the top level (global variable initialization). Instead, we leave
- # it as NULL and lazily initialize it later.
- #hdr = llmemory.cast_adr_to_ptr(adr, lltype.Ptr(self.HDR))
- #hdr.remote_flags = lltype.direct_fieldptr(hdr, 'tid')
+ # at the top level (global variable initialization). Instead, we set
+ # it to NULL and lazily initialize it later.
+ ## hdr.remote_flags = lltype.direct_fieldptr(hdr, 'tid')
+ hdr.remote_flags = lltype.nullptr(SIGNEDP.TO)
def make_forwardstub(self, obj, forward_to):
assert (self.header(obj).remote_flags
diff --git a/rpython/translator/c/test/test_newgc.py b/rpython/translator/c/test/test_newgc.py
--- a/rpython/translator/c/test/test_newgc.py
+++ b/rpython/translator/c/test/test_newgc.py
@@ -1760,5 +1760,5 @@
class TestIncrementalMiniMarkGCMostCompact(TaggedPointersTest, TestIncrementalMiniMarkGC):
removetypeptr = True
-class TestIncrementalMiniMarkGCMostCompact(TaggedPointersTest, TestIncrementalMiniMarkRemoteHeadersGC):
+class TestIncrementalMiniMarkRemoteHeadersGCMostCompact(TaggedPointersTest, TestIncrementalMiniMarkRemoteHeadersGC):
removetypeptr = True
More information about the pypy-commit
mailing list