8000 gh-115103: Implement delayed memory reclamation (QSBR) by colesbury · Pull Request #115180 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

gh-115103: Implement delayed memory reclamation (QSBR) #115180

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 9 commits into from
Feb 16, 2024
Merged
Prev Previous commit
Next Next commit
Add comment about QSBR_LT/QSBR_LEQ
  • Loading branch information
colesbury committed Feb 15, 2024
commit 69d56690165e9992429e5371298aded06ab8423e
4 changes: 3 additions & 1 deletion Python/qsbr.c
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,9 @@
#include "pycore_pystate.h" // _PyThreadState_GET()


// Wrap-around safe comparison
// Wrap-around safe comparison. This is a holdover from the FreeBSD
// implementation, which uses 32-bit sequence numbers. We currently use 64-bit
// sequence numbers, so wrap-around is unlikely.
#define QSBR_LT(a, b) ((int64_t)((a)-(b)) < 0)
#define QSBR_LEQ(a, b) ((int64_t)((a)-(b)) <= 0)

Expand Down
0