[pypy-commit] stmgc c8-card-marking: add fastpath for card marking

Raemi noreply at buildbot.pypy.org
Sat Feb 28 12:13:44 CET 2015


Author: Remi Meier <remi.meier at gmail.com>
Branch: c8-card-marking
Changeset: r1685:8ca689687bfa
Date: 2015-02-28 12:14 +0100
http://bitbucket.org/pypy/stmgc/changeset/8ca689687bfa/

Log:	add fastpath for card marking

diff --git a/c8/stm/core.c b/c8/stm/core.c
--- a/c8/stm/core.c
+++ b/c8/stm/core.c
@@ -978,6 +978,9 @@
     struct stm_read_marker_s *cards = get_read_marker(STM_SEGMENT->segment_base,
                                                       (uintptr_t)obj);
     uintptr_t card_index = get_index_to_card_index(index);
+    if (cards[card_index].rm == CARD_MARKED)
+        return;
+
     if (!IS_OVERFLOW_OBJ(STM_PSEGMENT, obj)
         && !(cards[card_index].rm == CARD_MARKED
              || cards[card_index].rm == STM_SEGMENT->transaction_read_version)) {


More information about the pypy-commit mailing list