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/2018-July/154652.html below:

[Python-Dev] Const access to CPython objects outside of GIL?

[Python-Dev] Const access to CPython objects outside of GIL? [Python-Dev] Const access to CPython objects outside of GIL?Antoine Pitrou solipsis at pitrou.net
Tue Jul 17 04:27:27 EDT 2018
On Tue, 17 Jul 2018 00:15:04 -0500
Tim Peters <tim.peters at gmail.com> wrote:
> > More generally, what is the CPython 2.7/3.5 contract regarding (lack of)
> > object mutation, and the need for reference counting and synchronization
> > via GIL?
> 
> There is no intention to support GIL-free access to any Python objects.  So
> that's the contract:  "All warranties are null & void if you do just about
> anything while not holding the GIL".

Actually, accessing a Py_buffer that's been obtained in the regular way
(e.g. with PyObject_GetBuffer) is safe even without the GIL.

Regards

Antoine.


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