mirror of
https://github.com/pybind/pybind11.git
synced 2024-11-25 06:35:12 +00:00
Documentation: explicitly call out that the GIL is held (#615)
This commit is contained in:
parent
ec009a7ca2
commit
18d7df5efd
@ -19,6 +19,7 @@ another name and use it in the macro to avoid this problem.
|
||||
Global Interpreter Lock (GIL)
|
||||
=============================
|
||||
|
||||
When calling a C++ function from Python, the GIL is always held.
|
||||
The classes :class:`gil_scoped_release` and :class:`gil_scoped_acquire` can be
|
||||
used to acquire and release the global interpreter lock in the body of a C++
|
||||
function call. In this way, long-running C++ code can be parallelized using
|
||||
|
Loading…
Reference in New Issue
Block a user