Skip to content

[executorch][cuda] Optimize short-query INT4 matvec kernels - #21456

Open
Gasoonjia wants to merge 1 commit into
gh/gasoonjia/175/basefrom
gh/gasoonjia/175/head
Open

[executorch][cuda] Optimize short-query INT4 matvec kernels#21456
Gasoonjia wants to merge 1 commit into
gh/gasoonjia/175/basefrom
gh/gasoonjia/175/head

Conversation

@Gasoonjia

@Gasoonjia Gasoonjia commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Stack from ghstack (oldest at bottom):

Add compile-time M=2/3/4 fused short-query kernels while preserving the existing M=1 path. The shared ROWS template was reviewed and benchmarked by KernelAgent; KA found no faster safe rewrite, so the validated template is retained.

A100 kernel microbenchmarks versus main:

  • M1: 0.10226 -> 0.10228 ms (performance neutral; no regression)
  • M2: 0.196 -> 0.127 ms (1.54x)
  • M3: 0.289 -> 0.159 ms (1.82x)
  • M4: 0.383 -> 0.196 ms (1.95x)

Correctness tests cover M=1,2,3,4 with three randomized seeds. ptxas reports zero spills.

Differential Revision: D114032326

[ghstack-poisoned]
@pytorch-bot

pytorch-bot Bot commented Jul 29, 2026

Copy link
Copy Markdown

🔗 Helpful Links

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

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

❌ 3 New Failures, 1 Unclassified Failure

As of commit c5a07ba with merge base e47f373 (image):

NEW FAILURES - The following jobs have failed:

UNCLASSIFIED FAILURE - DrCI could not classify the following job because the workflow did not run on the merge base. The failure may be pre-existing on trunk or introduced by this PR:

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

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Jul 29, 2026
@github-actions

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.

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.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant