aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Include/internal/pycore_debug_offsets.h
diff options
context:
space:
mode:
Diffstat (limited to 'Include/internal/pycore_debug_offsets.h')
-rw-r--r--Include/internal/pycore_debug_offsets.h17
1 files changed, 16 insertions, 1 deletions
diff --git a/Include/internal/pycore_debug_offsets.h b/Include/internal/pycore_debug_offsets.h
index 1a265c59ff8..1b59fa2ef60 100644
--- a/Include/internal/pycore_debug_offsets.h
+++ b/Include/internal/pycore_debug_offsets.h
@@ -54,11 +54,13 @@ extern "C" {
# define _Py_Debug_Free_Threaded 1
# define _Py_Debug_code_object_co_tlbc offsetof(PyCodeObject, co_tlbc)
# define _Py_Debug_interpreter_frame_tlbc_index offsetof(_PyInterpreterFrame, tlbc_index)
+# define _Py_Debug_interpreter_state_tlbc_generation offsetof(PyInterpreterState, tlbc_indices.tlbc_generation)
#else
# define _Py_Debug_gilruntimestate_enabled 0
# define _Py_Debug_Free_Threaded 0
# define _Py_Debug_code_object_co_tlbc 0
# define _Py_Debug_interpreter_frame_tlbc_index 0
+# define _Py_Debug_interpreter_state_tlbc_generation 0
#endif
@@ -89,6 +91,8 @@ typedef struct _Py_DebugOffsets {
uint64_t gil_runtime_state_enabled;
uint64_t gil_runtime_state_locked;
uint64_t gil_runtime_state_holder;
+ uint64_t code_object_generation;
+ uint64_t tlbc_generation;
} interpreter_state;
// Thread state offset;
@@ -216,6 +220,11 @@ typedef struct _Py_DebugOffsets {
uint64_t gi_frame_state;
} gen_object;
+ struct _llist_node {
+ uint64_t next;
+ uint64_t prev;
+ } llist_node;
+
struct _debugger_support {
uint64_t eval_breaker;
uint64_t remote_debugger_support;
@@ -251,6 +260,8 @@ typedef struct _Py_DebugOffsets {
.gil_runtime_state_enabled = _Py_Debug_gilruntimestate_enabled, \
.gil_runtime_state_locked = offsetof(PyInterpreterState, _gil.locked), \
.gil_runtime_state_holder = offsetof(PyInterpreterState, _gil.last_holder), \
+ .code_object_generation = offsetof(PyInterpreterState, _code_object_generation), \
+ .tlbc_generation = _Py_Debug_interpreter_state_tlbc_generation, \
}, \
.thread_state = { \
.size = sizeof(PyThreadState), \
@@ -347,13 +358,17 @@ typedef struct _Py_DebugOffsets {
.gi_iframe = offsetof(PyGenObject, gi_iframe), \
.gi_frame_state = offsetof(PyGenObject, gi_frame_state), \
}, \
+ .llist_node = { \
+ .next = offsetof(struct llist_node, next), \
+ .prev = offsetof(struct llist_node, prev), \
+ }, \
.debugger_support = { \
.eval_breaker = offsetof(PyThreadState, eval_breaker), \
.remote_debugger_support = offsetof(PyThreadState, remote_debugger_support), \
.remote_debugging_enabled = offsetof(PyInterpreterState, config.remote_debug), \
.debugger_pending_call = offsetof(_PyRemoteDebuggerSupport, debugger_pending_call), \
.debugger_script_path = offsetof(_PyRemoteDebuggerSupport, debugger_script_path), \
- .debugger_script_path_size = MAX_SCRIPT_PATH_SIZE, \
+ .debugger_script_path_size = Py_MAX_SCRIPT_PATH_SIZE, \
}, \
}