Skip to content

Allow recording uops after specializing uops #148285

Description

@markshannon

Currently, this is illegal in bytecodes.c:

macro(TO_BOOL) = 
    _SPECIALIZE_TO_BOOL +
    _RECORD_TOS_TYPE +
    unused/2 +
   _TO_BOOL;

because both specializing and recording uops must be first. Since specializing uops are only present in tier 1, and recording uops are only present in tier 2, there should be no conflict.

We should fix Tools/cases_generator/analyzer.py to allow a recording uop to follow a specializing uop.

Linked PRs

Activity

  1. added
    interpreter-core(Objects, Python, Grammar, and Parser dirs)
    3.15bugs and security fixes
    on Apr 9, 2026
  2. adityakrmishra commented on Apr 11, 2026

    @adityakrmishra

    Hi @markshannon I'd like to take this on.

    I see that the validation logic in Tools/cases_generator/analyzer.py currently rejects a recording uop following a specializing uop Since specializing is restricted to Tier 1 and recording to Tier 2, there shouldn't be a conflict. I can update the analyzer's parsing/validation rules to permit this sequence

    Could you assign this to me? I'll spin up a PR with the fix shortly

  3. kumaraditya303 commented on Apr 11, 2026

    @kumaraditya303
    Contributor

    We do not assign issues to non-core devs, if you have a fix feel free to propose a PR.

  4. adityakrmishra commented on Apr 11, 2026

    @adityakrmishra

    Thanks for the heads-up! I've started working on the analyzer.py fix locally and will open a PR with the proposed changes shortly.

  5. added 4 commits that reference this issue on Apr 11, 2026
  6. NekoAsakura commented on Apr 12, 2026

    @NekoAsakura
    Member

    I'm on it.

  7. added a commit that references this issue on Apr 13, 2026
  8. added a commit that references this issue on Apr 13, 2026
  9. Fidget-Spinner commented on Apr 13, 2026

    @Fidget-Spinner
    Member

    Done.

  10. added a commit that references this issue on Apr 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    3.15bugs 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