Commit 1fcf409
authored
gh-131988: Fix a multithreaded scaling regression
The 3.13 free threaded build immortalizes certain objects to avoid
reference count contention. In gh-127114 the condition was
unintentionally changed to happen when the first thread was created
instead of the first non-main thread. The `interp->gc.immortalize` field
is then cleared again during `_PyGC_Init()`.
Change the condition so that we check if we should immortalize objects
using deferred reference counting whenever a non-main thread is created.
1 parent bd2f518 commit 1fcf409
File tree
2 files changed
+4
-2
lines changed- Misc/NEWS.d/next/Core_and_Builtins
- Python
2 files changed
+4
-2
lines changedLines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1587 | 1587 | | |
1588 | 1588 | | |
1589 | 1589 | | |
1590 | | - | |
| 1590 | + | |
1591 | 1591 | | |
1592 | 1592 | | |
1593 | | - | |
| 1593 | + | |
1594 | 1594 | | |
1595 | 1595 | | |
1596 | 1596 | | |
| |||
0 commit comments