8000 Add debug offsets for free threaded builds by pablogsal · Pull Request #123041 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

Add debug offsets for free threaded builds #123041

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
Aug 15, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fixup! Ensure the debug cookie only appears once in the binary
  • Loading branch information
pablogsal committed Aug 15, 2024
commit 33c25ba878b4b9a7841c9c8efe7920c6e876b338
3 changes: 2 additions & 1 deletion Include/internal/pycore_runtime.h
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,7 @@ typedef struct _Py_DebugOffsets {
struct _list_object {
uint64_t size;
uint64_t ob_item;
uint64_t ob_size;
} list_object;

// PyDict object offset;
Expand Down Expand Up @@ -175,7 +176,7 @@ typedef struct _Py_DebugOffsets {
uint64_t size;
uint64_t state;
uint64_t length;
size_t asciiobject_size;
uint64_t asciiobject_size;
} unicode_object;

// GC runtime state offset;
Expand Down
1 change: 1 addition & 0 deletions Include/internal/pycore_runtime_init.h
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
.debug_offsets = { \
.cookie = debug_cookie, \
.version = PY_VERSION_HEX, \
.free_threaded = Py_GIL_DISABLED, \

Check failure on line 37 in Include/internal/pycore_runtime_init.h

View workflow job for this annotation

GitHub Actions / Hypothesis tests on Ubuntu

‘Py_GIL_DISABLED’ undeclared here (not in a function)

Check failure on line 37 in Include/internal/pycore_runtime_init.h

View workflow job for this annotation

GitHub Actions / Hypothesis tests on Ubuntu

‘Py_GIL_DISABLED’ undeclared here (not in a function)

Check failure on line 37 in Include/internal/pycore_runtime_init.h

View workflow job for this annotation

GitHub Actions / Address sanitizer

‘Py_GIL_DISABLED’ undeclared here (not in a function)

Check failure on line 37 in Include/internal/pycore_runtime_init.h

View workflow job for this annotation

GitHub Actions / Address sanitizer

‘Py_GIL_DISABLED’ undeclared here (not in a function)
.runtime_state = { \
.size = sizeof(_PyRuntimeState), \
.finalizing = offsetof(_PyRuntimeState, _finalizing), \
Expand Down Expand Up @@ -103,6 +103,7 @@
.list_object = { \
.size = sizeof(PyListObject), \
.ob_item = offsetof(PyListObject, ob_item), \
.ob_size = offsetof(PyListObject, ob_base.ob_size), \
}, \
.dict_object = { \
.size = sizeof(PyDictObject), \
Expand Down
Loading
0