perf(math): accelerate FHT with SIMD - #33
Merged
Merged
Conversation
Deploying with
|
| Status | Name | Latest Commit | Updated (UTC) |
|---|---|---|---|
| ❌ Deployment failed View logs |
xvec | e41b494 | Aug 31 2026, 10:28 AM |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #33 +/- ##
==========================================
- Coverage 82.39% 82.38% -0.01%
==========================================
Files 121 122 +1
Lines 26011 26066 +55
==========================================
+ Hits 21431 21474 +43
- Misses 4580 4592 +12 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
zhangzhenghao
force-pushed
the
perf/fht-simd
branch
from
August 31, 2026 09:45
c912bcc to
f43a80e
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
internal/ailego/mathand add runtime-dispatched AVX2, AVX-512, and NEON kernelsinternal/ailego/math/src, following the layout used byinternal/floatsnoasm, unsupported CPUs, short inputs, and architecture-safe AVX-512 fallback pathsVerification
go test ./... -count=1go test -tags noasm ./... -count=1go vet ./...GODEBUG=cpu.avx2=off go test ./internal/ailego/math -run '^TestFHTAVX512ScalarFallback$' -count=1TestFHTNEONinternal/ailego/mathandinternal/core/algorithmmake -C internal/ailego/math generatefollowed by a clean generated diffBenchmark (1024 floats, amd64 AVX2 host)
FHTInPlace: ~3.76 µs SIMD vs ~7.51 µs scalar (noasm)FHTKacWalk: ~72.7 ns SIMD vs ~550 ns scalar (noasm)