Skip to content

[API](feat) Deprecate legacy sync block APIs - #1909

Draft
Misaka19280hw wants to merge 1 commit into
triton-lang:main-devfrom
Misaka19280hw:deprecate-legacy-sync-block-apis
Draft

[API](feat) Deprecate legacy sync block APIs#1909
Misaka19280hw wants to merge 1 commit into
triton-lang:main-devfrom
Misaka19280hw:deprecate-legacy-sync-block-apis

Conversation

@Misaka19280hw

Copy link
Copy Markdown
Contributor

Why

The legacy triton.language.sync_block_all, sync_block_set, and sync_block_wait wrappers still use ad-hoc DeprecationWarning calls. Standardize their sunset behavior with the _deprecated mechanism introduced for main-dev, and point users to the public Ascend extension APIs.

What

  • Decorate the three legacy wrappers with _deprecated.
  • Use the full triton.language.extra.cann.extension.sync_block_* replacement paths.
  • Remove the old inline warning code without changing the synchronization bodies.
  • Add backend-independent tests for the warning message, builtin marker, and builder argument forwarding.

Validation

  • pre-commit run --from-ref origin/main-dev --to-ref HEAD
  • git diff origin/main-dev..HEAD --check
  • python -m pytest --collect-only -q third_party/ascend/unittest/pytest_ut/test_aux_ops_deprecation.py (3 tests collected)
  • Source-level checks verified the three decorator arguments and removal of the inline warnings.
  • The tests were not executed against the locally installed wheel because it predates the current _semantic protocol; CI builds and installs the current checkout before running pytest_ut.

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-dev --to-ref HEAD.
  • I have added Python tests under third_party/ascend/unittest/pytest_ut.
  • I have not added any lit tests.

@github-actions github-actions Bot added python Changes to Python runtime or bindings ascend-backend Changes to the Ascend NPU backend labels Sep 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ascend-backend Changes to the Ascend NPU backend python Changes to Python runtime or bindings

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant