Raymond Hettinger wrote: > 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. I object to the notion that Python does "thread switching". It doesn't. Instead, it releases the GIL under certain circumstances, which might make the operating system switch threads. Whether the operating system does that is its own choice. I don't see a value to disabling the "release the GIL from time to time". This does *not* mean there couldn't be thread-switching, anymore. E.g. inside a PRINT_* opcode, thread-switching may still occur, as file_write releases the GIL around the fwrite() call. So if you set the checkinterval to "no check", you cannot trust that there won't be any thread switching. Regards, Martin
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