[pypy-commit] stmgc c8-adaptive-trx-length: Make sequential transactions inevitable

tobweber pypy.commits at gmail.com
Tue May 2 10:34:27 EDT 2017


Author: Tobias Weber <tobias_weber89 at gmx.de>
Branch: c8-adaptive-trx-length
Changeset: r2047:ffbfa75ef055
Date: 2017-04-29 13:56 +0200
http://bitbucket.org/pypy/stmgc/changeset/ffbfa75ef055/

Log:	Make sequential transactions inevitable

diff --git a/c8/stm/core.c b/c8/stm/core.c
--- a/c8/stm/core.c
+++ b/c8/stm/core.c
@@ -1166,6 +1166,9 @@
     }
     _do_start_transaction(tl);
 
+    if (number_of_segments_in_use() < 2) {
+        stm_become_inevitable(tl, "single thread mode");
+    }
     if (repeat_count == 0) {  /* else, 'nursery_mark' was already set
                                  in abort_data_structures_from_segment_num() */
         stm_update_transaction_length();


More information about the pypy-commit mailing list