Repository navigation
Enable fused K64 projections for model 8 on AVX-VNNI - #25
Open
varyagnord wants to merge 1 commit into
Open
varyagnord wants to merge 1 commit into
varyagnord wants to merge 1 commit into
Conversation
Reuse the validated four-row VNNI assembly for eligible batch and paired projections while preserving model 2, AVX2, and the public ABI. Extend the existing fused contract to run directly in the model-8 VNNI namespace and cover independent FTZ and DAZ combinations. Validation: 35 native PGO, 34 static ASan/UBSan and 28 AVX2-only CTests passed.
This branch has not been deployed
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
Enable the existing four-row fused AVX-VNNI assembly for eligible model-8 K64 batch and paired projections. The kernel combines the packed integer dot products with the existing FP32 scale and bias epilogue. Hardware selection uses the existing runtime dispatch. Model 2, the AVX2 kernel selection, exact quantization, model weights, and the seven-symbol public ABI are preserved.
This is a standalone change against the current
optimized-inferencebranch. It applies independently of #22 and #23. Both combinations were checked for merge conflicts. The earlier channel-major qualification found about 0.80–1.21% lower times in six qualifying model-8 conditions. That study used a different baseline.New measurement against current upstream
Fresh, independently trained native PGO builds of
98df765and this change ran on one Ryzen core with its SMT sibling parked, the L3 domain reserved, and frequency verified near 2 GHz. The fixed continuous model-8 test used two inputs, 16 identical-binary A/A pairs and 16 A/B pairs of fresh processes, and 512 timed calls per process.The paired inference-time reduction was 1.186% (95% CI 1.107–1.264%). The A/A interval was −0.047% to +0.099%. All 32,768 timed calls completed within 10 ms. Four separate PMU runs recorded 100% counter scheduling. The laboratory restoration audit passed. This benchmark covers continuous inference on this host at the fixed frequency. The earlier Boost and complete-audio results remain scoped to their measured configurations.
Correctness