Author: Tobias Weber <tobias_webe...@gmx.de>
Branch: c8-tcp-style-trx-length
Changeset: r2113:003bd8a738d7
Date: 2017-07-14 17:57 +0200
http://bitbucket.org/pypy/stmgc/changeset/003bd8a738d7/

Log:    Merge fix of commit signalling fix

diff --git a/c8/stm/core.c b/c8/stm/core.c
--- a/c8/stm/core.c
+++ b/c8/stm/core.c
@@ -1178,6 +1178,7 @@
     _do_start_transaction(tl);
     continue_timer();
 
+    STM_PSEGMENT->commit_if_not_atomic = false;
     STM_SEGMENT->nursery_mark = ((stm_char *)_stm_nursery_start +
                                         stm_get_transaction_length(tl));
 
diff --git a/c8/stm/nursery.c b/c8/stm/nursery.c
--- a/c8/stm/nursery.c
+++ b/c8/stm/nursery.c
@@ -549,8 +549,9 @@
     pseg->pub.nursery_current = (stm_char *)_stm_nursery_start;
     pseg->pub.nursery_mark -= nursery_used;
 
+    assert((pseg->transaction_state == TS_INEVITABLE) || 
!pseg->commit_if_not_atomic);
     if (pseg->commit_if_not_atomic
-        // && pseg->transaction_state == TS_INEVITABLE // TODO why does this 
break the mechanism?
+        && pseg->transaction_state == TS_INEVITABLE
         && pseg->pub.running_thread->self_or_0_if_atomic != 0) {
         // transaction is inevitable, not atomic, and commit has been 
signalled by waiting thread: commit immediately
         pseg->pub.nursery_mark = 0;
_______________________________________________
pypy-commit mailing list
pypy-commit@python.org
https://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to