Author: Richard Plangger <planri...@gmail.com> Branch: Changeset: r83761:aacade14ae52 Date: 2016-04-19 09:55 +0200 http://bitbucket.org/pypy/pypy/changeset/aacade14ae52/
Log: print the progress uppon test failure (test_gil), increased the time it sleeps while checking the progress diff --git a/pypy/module/thread/test/test_gil.py b/pypy/module/thread/test/test_gil.py --- a/pypy/module/thread/test/test_gil.py +++ b/pypy/module/thread/test/test_gil.py @@ -1,5 +1,7 @@ import time from pypy.module.thread import gil +from rpython.rtyper.lltypesystem.lloperation import llop +from rpython.rtyper.lltypesystem import lltype from rpython.rlib import rgil from rpython.rlib.test import test_rthread from rpython.rlib import rthread as thread @@ -81,10 +83,13 @@ while len(state.data) < 2*N: debug_print(len(state.data)) if not still_waiting: + llop.debug_print(lltype.Void, "timeout. progress: " + "%d of 2*N (= %f%%)" % \ + (len(state.data), 2*N, 100*len(state.data)/(2.0*N))) raise ValueError("time out") still_waiting -= 1 if not we_are_translated(): rgil.release() - time.sleep(0.01) + time.sleep(0.1) if not we_are_translated(): rgil.acquire() debug_print("leaving!") i1 = i2 = 0 _______________________________________________ pypy-commit mailing list pypy-commit@python.org https://mail.python.org/mailman/listinfo/pypy-commit