Author: Armin Rigo <ar...@tunes.org> Branch: stmgc-c7 Changeset: r70308:c1aa7aff6a7e Date: 2014-03-27 15:50 +0100 http://bitbucket.org/pypy/pypy/changeset/c1aa7aff6a7e/
Log: Some more transaction-safety. diff --git a/rpython/rtyper/module/ll_time.py b/rpython/rtyper/module/ll_time.py --- a/rpython/rtyper/module/ll_time.py +++ b/rpython/rtyper/module/ll_time.py @@ -85,11 +85,13 @@ if self.GETTIMEOFDAY_NO_TZ: c_gettimeofday = self.llexternal('gettimeofday', [self.TIMEVALP], rffi.INT, - _nowrapper=True, releasegil=False) + _nowrapper=True, releasegil=False, + transactionsafe=True) else: c_gettimeofday = self.llexternal('gettimeofday', [self.TIMEVALP, rffi.VOIDP], rffi.INT, - _nowrapper=True, releasegil=False) + _nowrapper=True, releasegil=False, + transactionsafe=True) c_ftime = None # We have gettimeofday(2), so force ftime(3) OFF. else: c_gettimeofday = None @@ -99,12 +101,14 @@ self.configure(CConfigForFTime) c_ftime = self.llexternal(FTIME, [lltype.Ptr(self.TIMEB)], lltype.Void, - _nowrapper=True, releasegil=False) + _nowrapper=True, releasegil=False, + transactionsafe=True) else: c_ftime = None # to not confuse the flow space c_time = self.llexternal('time', [rffi.VOIDP], rffi.TIME_T, - _nowrapper=True, releasegil=False) + _nowrapper=True, releasegil=False, + transactionsafe=True) def time_time_llimpl(): void = lltype.nullptr(rffi.VOIDP.TO) @@ -142,10 +146,10 @@ A = lltype.FixedSizeArray(lltype.SignedLongLong, 1) QueryPerformanceCounter = self.llexternal( 'QueryPerformanceCounter', [lltype.Ptr(A)], lltype.Void, - releasegil=False) + releasegil=False, transactionsafe=True) QueryPerformanceFrequency = self.llexternal( 'QueryPerformanceFrequency', [lltype.Ptr(A)], rffi.INT, - releasegil=False) + releasegil=False, transactionsafe=True) class State(object): pass state = State() @@ -168,7 +172,8 @@ c_getrusage = self.llexternal('getrusage', [rffi.INT, lltype.Ptr(RUSAGE)], lltype.Void, - releasegil=False) + releasegil=False, + transactionsafe=True) def time_clock_llimpl(): a = lltype.malloc(RUSAGE, flavor='raw') c_getrusage(RUSAGE_SELF, a) _______________________________________________ pypy-commit mailing list pypy-commit@python.org https://mail.python.org/mailman/listinfo/pypy-commit