Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Multithreaded scaling regression in 3.13.1t #131988

@colesbury

Description

@colesbury

Bug report

Bug description:

#127114 changed the logic to immortalize certain objects when the first thread is created instead of the first non-main thread.

3.13.0:

sgross@devfair0453:/raid/sgross/clean-cpython/Tools/ftscalingbench$ uv run -p 3.13.0t ftscalingbench.py
Running benchmarks with 20 threads
object_cfunction          14.3x faster
cmodule_function          14.3x faster
object_lookup_special     14.3x faster
mult_constant             13.8x faster
generator                 13.8x faster
pymethod                  14.3x faster
pyfunction                14.0x faster
module_function           14.2x faster
load_string_const          2.5x slower
load_tuple_const          13.5x faster
create_pyobject           14.0x faster
create_closure            14.0x faster
create_dict               13.0x faster
thread_local_read          3.0x slower

3.13.1:

sgross@devfair0453:/raid/sgross/clean-cpython/Tools/ftscalingbench$ uv run -p 3.13.1t ftscalingbench.py
Running benchmarks with 20 threads
object_cfunction           1.6x slower
cmodule_function           1.9x slower
object_lookup_special      1.7x slower
mult_constant             14.3x faster
generator                  2.7x faster
pymethod                   2.3x slower
pyfunction                 3.1x slower
module_function            2.1x slower
load_string_const          2.1x slower
load_tuple_const          13.1x faster
create_pyobject            3.6x slower
create_closure             4.3x slower
create_dict               15.0x faster
thread_local_read          3.0x slower

CPython versions tested on:

3.13

Operating systems tested on:

No response

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions