Repository navigation
Commit 8ccfda4
committed
TypedPython: fill a fresh New's slots by direct release stores (#125)
tp_new_fixed no longer goes through PyMember_SetOne for each slot of the object it has just
allocated. The store is the one SetOne makes for a Py_T_OBJECT_EX slot (release store of a new
reference) without the per-object critical section and the release of the old value, which is
NULL after tp_alloc. Nothing between tp_alloc and the last store reaches a safepoint, so no
stop-the-world can hand the object to another thread before it is filled. The design note also
records why a freelist and later GC tracking were not done.1 parent 9394936 commit 8ccfda4
4 files changed
Lines changed: 64 additions & 3 deletions
File tree
- docs/design
- python-multiplatform-ksp/src
- main/python/typedpython/runtime
- test/python
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
221 | 221 | | |
222 | 222 | | |
223 | 223 | | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
224 | 252 | | |
225 | 253 | | |
226 | 254 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
389 | 389 | | |
390 | 390 | | |
391 | 391 | | |
392 | | - | |
| 392 | + | |
| 393 | + | |
393 | 394 | | |
394 | 395 | | |
395 | 396 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2756 | 2756 | | |
2757 | 2757 | | |
2758 | 2758 | | |
2759 | | - | |
| 2759 | + | |
| 2760 | + | |
| 2761 | + | |
| 2762 | + | |
| 2763 | + | |
| 2764 | + | |
| 2765 | + | |
| 2766 | + | |
| 2767 | + | |
| 2768 | + | |
| 2769 | + | |
| 2770 | + | |
| 2771 | + | |
| 2772 | + | |
| 2773 | + | |
| 2774 | + | |
2760 | 2775 | | |
2761 | 2776 | | |
2762 | 2777 | | |
| |||
2767 | 2782 | | |
2768 | 2783 | | |
2769 | 2784 | | |
2770 | | - | |
| 2785 | + | |
| 2786 | + | |
2771 | 2787 | | |
2772 | 2788 | | |
2773 | 2789 | | |
| 2790 | + | |
| 2791 | + | |
2774 | 2792 | | |
2775 | 2793 | | |
2776 | 2794 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
428 | 428 | | |
429 | 429 | | |
430 | 430 | | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
| 434 | + | |
| 435 | + | |
| 436 | + | |
| 437 | + | |
| 438 | + | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
| 442 | + | |
| 443 | + | |
| 444 | + | |
431 | 445 | | |
432 | 446 | | |
433 | 447 | | |
| |||
0 commit comments