[pypy-issue] [issue1340] stm-thread-2: Double acquire of lock when atomic

Armin Rigo tracker at bugs.pypy.org
Mon Dec 10 02:01:34 CET 2012


Armin Rigo <armin.rigo at gmail.com> added the comment:

It's unclear what we can do about it.  We're in an atomic transaction, so we
can't wait until another thread puts an item in the Queue --- from the point of
view of the programmer, no other thread can run concurrently with an atomic block.

What we could imagine would be to abort the whole transaction and wait until the
lock is released before restarting it.  But aborting a transaction cannot be
done if it is also inevitable, e.g. because of a "print" before...

----------
nosy: +arigo
status: unread -> chatting

________________________________________
PyPy bug tracker <tracker at bugs.pypy.org>
<https://bugs.pypy.org/issue1340>
________________________________________


More information about the pypy-issue mailing list