[pypy-commit] pypy stmgc-c7: Account for the usleep(1) we do after an abort

arigo noreply at buildbot.pypy.org
Sun Jan 18 15:30:23 CET 2015


Author: Armin Rigo <arigo at tunes.org>
Branch: stmgc-c7
Changeset: r75426:97e19da50a69
Date: 2015-01-18 15:30 +0100
http://bitbucket.org/pypy/pypy/changeset/97e19da50a69/

Log:	Account for the usleep(1) we do after an abort

diff --git a/pypy/stm/print_stm_log.py b/pypy/stm/print_stm_log.py
--- a/pypy/stm/print_stm_log.py
+++ b/pypy/stm/print_stm_log.py
@@ -32,6 +32,8 @@
 
 _STM_EVENT_N  = 15
 
+PAUSE_AFTER_ABORT   = 0.000001      # usleep(1) after every abort
+
 
 event_name = {}
 for _key, _value in globals().items():
@@ -108,6 +110,7 @@
         if self._conflict and entry.event == STM_TRANSACTION_ABORT:
             c = self._conflict[1]
             c.aborted_time += transaction_time
+            c.paused_time += PAUSE_AFTER_ABORT
             self._conflict = None
 
     def transaction_pause(self, entry):


More information about the pypy-commit mailing list