[ssbuffer](fix) Delay ops with yield users in topological ordering#774
Merged
Conversation
Skyminers
approved these changes
Jun 24, 2026
|
📂 Code Owners — the following files under code ownership were modified. Please review:
🤖 Generated by labeler workflow |
WuTYSFG
approved these changes
Jun 25, 2026
hongziqi
approved these changes
Jun 25, 2026
210ec3b
into
triton-lang:release/3.2.2-dev
38 of 39 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Title: Delay ops with yield users in topological ordering
Summary
Modify the group selection strategy in
computeTopologicalOrderto prioritize groups whose operations do not havescf.yieldusers. This delays operations that update yield arguments to execute as late as possible in the schedule.Changes
groupOpsmember toGroupAdjacencyGraphto track operations belonging to each groupselectGroup()method that iterates through ready groups and selects the first group where all operations have no yield userscomputeTopologicalOrder()to useselectGroup()instead ofpop_back_val()Motivation
Operations that feed
scf.yieldarguments represent values that need to persist across loop iterations. By scheduling these operations later, we can potentially improve register pressure and enable more optimization opportunities.New contributor declaration
I am not making a trivial change, such as fixing a typo in a comment.
I have written a PR description following these
rules.
I have run
pre-commit run --from-ref origin/main --to-ref HEAD.Select one of the following.
/testforlittests/unittestfor C++ tests/python/testfor end-to-end testsFILL THIS IN.Select one of the following.
littests.littests I have added follow these best practices,including the "tests should be minimal" section. (Usually running Python code
and using the instructions it generates is not minimal.)