• Tim Peters's avatar
    Issue 18984: Remove ._stopped Event from Thread internals. · c363a23e
    Tim Peters yazdı
    The fix for issue 18808 left us checking two things to be sure a Thread
    was done:  an Event (._stopped) and a mutex (._tstate_lock).  Clumsy &
    brittle.  This patch removes the Event, leaving just a happy lock :-)
    
    The bulk of the patch removes two excruciating tests, which were
    verifying sanity of the internals of the ._stopped Event after a fork.
    Thanks to Antoine Pitrou for verifying that's the only real value
    these tests had.
    
    One consequence of moving from an Event to a mutex:  waiters (threads
    calling Thread.join()) used to block each on their own unique mutex
    (internal to the ._stopped event), but now all contend on the same
    mutex (._tstate_lock).  These approaches have different performance
    characteristics on different platforms.  I don't think it matters in
    this context.
    c363a23e
Adı
Son kayıt (commit)
Son güncelleme
Doc Loading commit data...
Grammar Loading commit data...
Include Loading commit data...
Lib Loading commit data...
Mac Loading commit data...
Misc Loading commit data...
Modules Loading commit data...
Objects Loading commit data...
PC Loading commit data...
PCbuild Loading commit data...
Parser Loading commit data...
Python Loading commit data...
Tools Loading commit data...
.bzrignore Loading commit data...
.gitignore Loading commit data...
.hgeol Loading commit data...
.hgignore Loading commit data...
.hgtags Loading commit data...
.hgtouch Loading commit data...
LICENSE Loading commit data...
Makefile.pre.in Loading commit data...
README Loading commit data...
config.guess Loading commit data...
config.sub Loading commit data...
configure Loading commit data...
configure.ac Loading commit data...
install-sh Loading commit data...
pyconfig.h.in Loading commit data...
setup.py Loading commit data...