]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
[3.12] gh-102024: Reduced _idle_semaphore.release calls (GH-102025) (#104959)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Fri, 26 May 2023 06:21:15 +0000 (23:21 -0700)
committerGitHub <noreply@github.com>
Fri, 26 May 2023 06:21:15 +0000 (06:21 +0000)
commit8010cefc45d6763fea0c5950db9237ce42776516
tree20757c8dc986d22a5636e33b9737753260eab962
parent5c2971b78f7e2bdf8ed6073c7470cdfe2a4b7a69
[3.12] gh-102024: Reduced _idle_semaphore.release calls (GH-102025) (#104959)

gh-102024: Reduced _idle_semaphore.release calls (GH-102025)

Reduced _idle_semaphore.release calls in concurrent.futures.thread._worker
_idle_semaphore.release() is now only called if only work_queue is empty.

---------

(cherry picked from commit 0242e9a57aa87ed0b5cac526f65631c654a39054)

Co-authored-by: Andrii Kuzmin <jack.cvr@gmail.com>
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
Lib/concurrent/futures/thread.py
Misc/NEWS.d/next/Library/2023-02-18-22-55-48.gh-issue-102024.RUmg_D.rst [new file with mode: 0644]