Discussion:
[Bug python/23615] New: release the GIL in execute_command
tromey at sourceware dot org
2018-09-07 17:44:40 UTC
Permalink
https://sourceware.org/bugzilla/show_bug.cgi?id=23615

Bug ID: 23615
Summary: release the GIL in execute_command
Product: gdb
Version: HEAD
Status: NEW
Severity: normal
Priority: P2
Component: python
Assignee: unassigned at sourceware dot org
Reporter: tromey at sourceware dot org
Target Milestone: ---

This comes from
https://stackoverflow.com/questions/52098116/gdb-execute-blocks-all-the-threads-in-python-scripts

gdb.execute_command is called with the GIL and does not release it.
This means that other Python threads will be blocked by the gdb operation.

It would be better to release the GIL when re-entering gdb and
then re-acquire it when re-entering Python.

This should probably apply to parse_and_eval as well.
--
You are receiving this mail because:
You are on the CC list for the bug.
tromey at sourceware dot org
2018-09-07 17:45:46 UTC
Permalink
https://sourceware.org/bugzilla/show_bug.cgi?id=23615

Tom Tromey <tromey at sourceware dot org> changed:

What |Removed |Added
----------------------------------------------------------------------------
Summary|release the GIL in |release the GIL in
|execute_command |python.c:execute_gdb_comman
| |d
--
You are receiving this mail because:
You are on the CC list for the bug.
tromey at sourceware dot org
2018-09-07 17:45:59 UTC
Permalink
https://sourceware.org/bugzilla/show_bug.cgi?id=23615

--- Comment #1 from Tom Tromey <tromey at sourceware dot org> ---
Oops, I meant "gdb.execute".
--
You are receiving this mail because:
You are on the CC list for the bug.
tromey at sourceware dot org
2018-09-08 09:10:32 UTC
Permalink
https://sourceware.org/bugzilla/show_bug.cgi?id=23615

Tom Tromey <tromey at sourceware dot org> changed:

What |Removed |Added
----------------------------------------------------------------------------
Assignee|unassigned at sourceware dot org |tromey at sourceware dot org
--
You are receiving this mail because:
You are on the CC list for the bug.
tromey at sourceware dot org
2018-09-11 04:06:23 UTC
Permalink
https://sourceware.org/bugzilla/show_bug.cgi?id=23615

--- Comment #2 from Tom Tromey <tromey at sourceware dot org> ---
I have a patch but I'm struggling to write a non-racy test case.
--
You are receiving this mail because:
You are on the CC list for the bug.
Loading...