[pypy-commit] pypy miniscan: Comment.
arigo
noreply at buildbot.pypy.org
Tue Feb 28 14:09:37 CET 2012
Author: Armin Rigo <arigo at tunes.org>
Branch: miniscan
Changeset: r52977:c5c715bfac2b
Date: 2012-02-28 14:09 +0100
http://bitbucket.org/pypy/pypy/changeset/c5c715bfac2b/
Log: Comment.
diff --git a/pypy/rpython/memory/gc/minimark.py b/pypy/rpython/memory/gc/minimark.py
--- a/pypy/rpython/memory/gc/minimark.py
+++ b/pypy/rpython/memory/gc/minimark.py
@@ -116,6 +116,10 @@
TID_MASK = (first_gcflag << 7) - 1
+# The remaining unused bits (GCFLAG_HIGH_MASK) are set to a known pattern
+# in all objects (GCFLAG_HIGH). From a random address in the nursery, it
+# let us know if it points to a valid object: either "definitely not", or
+# "very likely". We can't be sure, though, so be careful.
GCFLAG_HIGH_MASK = intmask(~TID_MASK)
assert GCFLAG_HIGH_MASK < 0 and not (GCFLAG_HIGH_MASK & GCFLAG_CARDS_SET)
GCFLAG_HIGH = intmask(0x5555555555555555 & GCFLAG_HIGH_MASK)
More information about the pypy-commit
mailing list