Skip to content

[executorch][native-aot] Export a prefill method for linear attention - #25505

Open
digantdesai wants to merge 1 commit into
gh/digantdesai/298/basefrom
gh/digantdesai/298/head
Open

digantdesai wants to merge 1 commit into
gh/digantdesai/298/basefrom
gh/digantdesai/298/head

Conversation

@digantdesai

@digantdesai digantdesai commented Nov 22, 2026 •

Copy link
Copy Markdown
Contributor

Stack from ghstack (oldest at bottom):

A linear-attention model on native::gated_delta_rule also exports prefill,
taking 2 to --prefill_tokens prompt tokens per call (default 512, at most
max_seq_length - 1), beside its one-token forward; both read and write the
same states. prefill_calls covers a prompt with full calls, then the rest,
and golden samples record each call on its method. 0 exports forward alone.

transformers' chunked rule loops over a count of chunks, so only the native
op exports for any token count; a prompt otherwise takes a call per token.

Authored with assistance from Claude and Codex.

Differential Revision: D133282478

[ghstack-poisoned]
@pytorch-bot

ghost commented Nov 22, 2026 •

Copy link
Copy Markdown

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/25505

Note: Links to docs will display an error until the docs builds have been completed.

❌ 2 New Failures

As of commit 54445f3 with merge base 8c3f75d (image):

NEW FAILURES - The following jobs have failed:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@github-actions

ghost commented Nov 22, 2026

Copy link
Copy Markdown

This PR needs a release notes: label

If your change should be included in the release notes (i.e. would users of this library care about this change?), please use a label starting with release notes:. This helps us keep track and include your important work in the next release notes.

To add a label, you can comment to pytorchbot, for example
@pytorchbot label "release notes: none"

For more information, see
https://github.com/pytorch/pytorch/wiki/PyTorch-AutoLabel-Bot#why-categorize-for-release-notes-and-how-does-it-work.

This was referenced Nov 22, 2026

This branch was previously deployed

1 inactive deployment
cadence — 54445f33 Deployed Nov 22, 2026 by digantdesai via hifi-op-test / hifi4 #40116
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. meta-exported

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants