From: Ezio Melotti Date: Fri, 18 Jan 2013 17:58:47 +0000 (+0200) Subject: #16978: merge with 3.2. X-Git-Tag: v3.4.0a1~1580^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=6d043fc7813a4d15f1d801e692245b0c1b6759cf;p=python #16978: merge with 3.2. --- 6d043fc7813a4d15f1d801e692245b0c1b6759cf diff --cc Doc/library/threading.rst index 05863a0e73,4a01211687..ec235046ce --- a/Doc/library/threading.rst +++ b/Doc/library/threading.rst @@@ -306,18 -368,6 +306,18 @@@ since it is impossible to detect the te property instead. +.. impl-detail:: + - Due to the :term:`Global Interpreter Lock`, in CPython only one thread ++ In CPython, due to the :term:`Global Interpreter Lock`, only one thread + can execute Python code at once (even though certain performance-oriented + libraries might overcome this limitation). - If you want your application to make better of use of the computational ++ If you want your application to make better use of the computational + resources of multi-core machines, you are advised to use + :mod:`multiprocessing` or :class:`concurrent.futures.ProcessPoolExecutor`. + However, threading is still an appropriate model if you want to run + multiple I/O-bound tasks simultaneously. + + .. _lock-objects: Lock Objects