Skip to content

[Ascend] Add opt-in zero-burst DMA emission for T.copy - #1

Closed
Denverjin wants to merge 1 commit into
mainfrom
codex/ascend-copy-emit-zero-burst
Closed

Denverjin wants to merge 1 commit into
mainfrom
codex/ascend-copy-emit-zero-burst

Conversation

@Denverjin

Copy link
Copy Markdown
Owner

Allow eligible Ascend GM-to-UB copies to issue a DMA call when the runtime burst count is zero via T.copy(..., annotations={"emit_zero_burst": True}). This supports pair gathers with a runtime count of 0 or 2 without the surrounding count guard; zero bursts preserve existing UB contents.

The option uses the existing annotation decoder and requires an unpadded copy outside SimtVF, fixed positive row bytes, and a row count that captures every empty-region condition. Callers supply hardware-valid counts and address/stride expressions safe to evaluate for zero rows. Default copy behavior is unchanged.

Validation:

  • Ascend copy lowering and bounds tests: 94 passed.
  • Ascend DMA tests on dav-3510 / CANN 9.2.0: 11 passed, including zero-burst preservation with runtime strides.
  • Linked ELF inspection through asckit/Bisheng: the opt-in copy retains the DMA instruction and removes its conditional jump.
  • Repository formatting and static checks passed for all five changed files.

PR229 end-to-end performance was not remeasured.

@Denverjin Denverjin closed this Oct 14, 2026
@Denverjin
Denverjin deleted the codex/ascend-copy-emit-zero-burst branch October 14, 2026 05:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant