Skip to content
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

Further speed up Python-to-Python calls. #89914

Closed
markshannon opened this issue Nov 8, 2021 · 3 comments
Closed

Further speed up Python-to-Python calls. #89914

markshannon opened this issue Nov 8, 2021 · 3 comments
Assignees
Labels
3.12 bugs and security fixes interpreter-core (Objects, Python, Grammar, and Parser dirs) performance Performance or resource usage

Comments

@markshannon
Copy link
Member

BPO 45753
Nosy @markshannon, @brandtbucher
PRs
  • bpo-45753: Move function object struct to an internal header. #29516
  • bpo-45753: Make recursion checks more efficient. #29524
  • bpo-45753: Interpreter internal tweaks #29575
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = 'https://github.com/markshannon'
    closed_at = None
    created_at = <Date 2021-11-08.17:17:55.336>
    labels = ['interpreter-core', '3.11', 'performance']
    title = 'Further speed up Python-to-Python calls.'
    updated_at = <Date 2021-12-01.12:09:41.057>
    user = 'https://github.com/markshannon'

    bugs.python.org fields:

    activity = <Date 2021-12-01.12:09:41.057>
    actor = 'Mark.Shannon'
    assignee = 'Mark.Shannon'
    closed = False
    closed_date = None
    closer = None
    components = ['Interpreter Core']
    creation = <Date 2021-11-08.17:17:55.336>
    creator = 'Mark.Shannon'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 45753
    keywords = ['patch']
    message_count = 3.0
    messages = ['405970', '406397', '407445']
    nosy_count = 2.0
    nosy_names = ['Mark.Shannon', 'brandtbucher']
    pr_nums = ['29516', '29524', '29575']
    priority = 'normal'
    resolution = None
    stage = 'patch review'
    status = 'open'
    superseder = None
    type = 'performance'
    url = 'https://bugs.python.org/issue45753'
    versions = ['Python 3.11']

    @markshannon
    Copy link
    Member Author

    There are three things we want to do:

    1. Speed up pushing and popping frames. See Speed up frame handling in Python-to-Python calls. faster-cpython/ideas#111 for details.
    2. Avoid tracing and other admin overhead on entering and leaving. See Reduce the overhead of tracing, profiling and quickening checks for calls. faster-cpython/ideas#112.
    3. Keep the remaining recursion depth in the cframe, to reduce the work for a recursion check from
      ++tstate->recursion_depth > tstate->interp->ceval.recursion_limit
      to
      cframe.recursion_overhead-- > 0

    @markshannon markshannon added the 3.11 only security fixes label Nov 8, 2021
    @markshannon markshannon self-assigned this Nov 8, 2021
    @markshannon markshannon added interpreter-core (Objects, Python, Grammar, and Parser dirs) performance Performance or resource usage 3.11 only security fixes labels Nov 8, 2021
    @markshannon markshannon self-assigned this Nov 8, 2021
    @markshannon markshannon added interpreter-core (Objects, Python, Grammar, and Parser dirs) performance Performance or resource usage labels Nov 8, 2021
    @markshannon
    Copy link
    Member Author

    New changeset b931077 by Mark Shannon in branch 'main':
    bpo-45753: Make recursion checks more efficient. (GH-29524)
    b931077

    @markshannon
    Copy link
    Member Author

    New changeset 49444fb by Mark Shannon in branch 'main':
    bpo-45753: Interpreter internal tweaks (GH-29575)
    49444fb

    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    @iritkatriel iritkatriel added 3.12 bugs and security fixes and removed 3.11 only security fixes labels Sep 13, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    3.12 bugs and security fixes interpreter-core (Objects, Python, Grammar, and Parser dirs) performance Performance or resource usage
    Projects
    None yet
    Development

    No branches or pull requests

    2 participants