Repository navigation
ggml-cpu(s390x): refactor repack helper functions - #30588
Merged
Merged
Conversation
Signed-off-by: Aaron Teo <aaron.teo1@ibm.com>
Member
|
Let's merge this after the release today - I've already started the ggml sync: ggml-org/ggml#1657 |
edwardyoon
pushed a commit
to edwardyoon/focus-llama
that referenced
this pull request
Oct 24, 2026
Signed-off-by: Aaron Teo <aaron.teo1@ibm.com>
auRose94
pushed a commit
to auRose94/llama.cpp
that referenced
this pull request
Oct 28, 2026
Signed-off-by: Aaron Teo <aaron.teo1@ibm.com>
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.
Overview
cont: #28667 (comment)
This PR refactors the repack helpers into
ggml-cpu-impl.hwhere the other inline helpers are currently located at. Fixes the problem that #28775 reported as well.Along with this refactor, we introduce a helper function that converts FP16 -> FP32 via vector intrinsics. However, this helper function has limitations where
infis mapped to65536.0fand likewiseNaNinto a finite number which would throw off Flash Attention. This helper is currently only recommended to be used for weight quants.Additional information
Some performance improvement is seen from using the new FP16 -> FP32 vector intrinsic conversion.
Requirements