[NVIDIA] Lower warp-specialization barriers with NVVM#10939
Open
ajit283 wants to merge 1 commit into
Open
Conversation
ajit283
force-pushed
the
nvidia-nvvm-barriers-fences
branch
from
July 17, 2026 21:50
b9831f2 to
ef22e93
Compare
ajit283
force-pushed
the
nvidia-nvvm-barriers-fences
branch
from
July 20, 2026 10:16
ef22e93 to
cd19679
Compare
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.
Summary
Use the NVVM dialect for the remaining NVIDIA non-mbarrier barrier path instead of manually constructing an LLVM intrinsic call.
Warp-specialization switch loops currently emit
llvm.nvvm.barrier.cta.sync.allby name. Emittingnvvm.barrierkeeps the target operation represented in MLIR, uses the dialect verifier, and delegates LLVM intrinsic selection to NVVM translation.CTA barriers, warp barriers, and cluster arrive/wait barriers elsewhere already use NVVM dialect operations. This change makes the warp-specialization all-participant named barriers consistent with them.
At Triton's pinned LLVM revision,
nvvm.barriertranslates to the samellvm.nvvm.barrier.cta.sync.allintrinsic and NVPTX backend instruction, so the emittedbar.syncsemantics are unchanged.Testing
pre-commit run --from-ref origin/main --to-ref HEADmakelit -v test/Conversion(81/81 passed)pytest -s --tb=short python/test/unit/language/test_compile_only.py::test_compile_only_dotNew 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.I have added tests.
/testforlittests/unittestfor C++ tests/python/testfor end-to-end testsI have not added any
littests.