A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2006-March/062373.html below:

[Python-Dev] Threading idea -- exposing a global thread lock

[Python-Dev] Threading idea -- exposing a global thread lock [Python-Dev] Threading idea -- exposing a global thread lockRaymond Hettinger raymond.hettinger at verizon.net
Tue Mar 14 19:30:54 CET 2006
[Nice analysis from Michael Chermside]
> The concept of a "critical section" makes great sense when there is
> effectively only one CPU: just stop switching threads. But if code
> is using multiple CPUs, what does it mean? Shut down the other CPUs?
 . . .
> I think it is unwise to build such a
> feature into the Python language. Supporting it in CPython only
> requires (I think) no more than a very simple C extension. I think
> it should stay as an extension and not become part of the language.

That makes sense.

Once place where we already have CPython specific support is in 
sys.setcheckinterval().  That suggests adapting that function or adding a new 
one to  temporarily stop switching, almost the same as 
sys.setcheckinterval(sys.maxint) but continuing to perform other periodic checks 
for control-break and such.


Raymond

More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4