Skip to content

perf(metal): optimize SSM scan and convolution - #1173

Merged
0xShug0 merged 1 commit into
mainfrom
perf/metal-ssm-optimizations
Nov 2, 2026
Merged

0xShug0 merged 1 commit into
mainfrom
perf/metal-ssm-optimizations

Conversation

@0xShug0

@0xShug0 0xShug0 commented Nov 2, 2026

Copy link
Copy Markdown
Owner

Summary

  • Add an opt-in register-resident Metal SSM scan kernel for 16-element states.
  • Add opt-in tiled SSM convolution and IM2COL kernels with coalesced memory access.
  • Keep existing kernels as the default and enable the new lowerings at the model call site.

Validation

  • Rebuilt against current main on Apple M4 Pro.
  • All six Metal extended tests pass, including independent numerical references and legacy Metal comparisons.
  • Full-length inference and speech-content checks pass.

@0xShug0
0xShug0 merged commit cc21c9e into main Nov 2, 2026
7 checks passed
@0xShug0
0xShug0 deleted the perf/metal-ssm-optimizations branch November 2, 2026 07:47
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