Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

RemoveTIER_ONE andTIER_TWO from bytecodes.c #108614

Closed
Labels
3.13bugs and security fixesinterpreter-core(Objects, Python, Grammar, and Parser dirs)
@markshannon

Description

@markshannon

TheTIER_ONE andTIER_TWO macros cause a few problems:

Their presence in the bytecode definitions means that anyone maintaining the interpreter or adding new instructions needs to understand the internals of the multiple execution layers and how they differ.
This makes the entry barrier for contribution, which is already high for these components, even higher.

It makes reasoning about the correctness of optimizations harder.

It prevents the addition of new execution tiers, or changing the design of the current tiers much harder.

We can remove theTIER_ONE andTIER_TWO macros by making modifications to internal execution engine state explicit, without describing how that state is implemented.
For example, rather than modifyingnext_instr in the tier 1 interpreter, we can useJUMP_BY orSAVE_IP macros.
Seefaster-cpython/ideas#618

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    3.13bugs and security fixesinterpreter-core(Objects, Python, Grammar, and Parser dirs)

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp