-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add way to compile ggml with intel mkl #804
Conversation
Signed-off-by: Kevin Hannon <[email protected]>
The cmake BLAS find module is generic and supports different libraries, like mkl. edit: use can use the vendor option to select "Intel"
|
Yea I use that code for llama.cpp but when I was looking at this repo, I noticed that blas was not set up in the same way. Maybe I am confused because I don't exactly follow the relationship between llama.cpp and ggml. In the CMakeFile, there was explict support for each blas option in this repo but in llama.cpp there is a smarter way to detect it. I wasn't sure if refactoring to make it similar as ggml is necessary. I tried to keep the logic similar as what is present in this repo. |
Once upon a time, ggml consisted of two files, |
Is the eventual goal that ggml is used as a tensor library for whisper and llama? It wasn't clear to me if this code is used in llama.cpp. I see that syncing is done manually but I didn't see any linking or compilation of this library. |
ggml is already used as the tensor library of whisper.cpp, llama.cpp and other projects. The changes to ggml usually happen in llama.cpp, but they regularly synced back to this repository. However each project has their own build scripts, there isn't an unified way to build ggml, and that's a problem. |
already done in project kantv:a build script for llama.cpp,whisper.cpp,stablediffusion.cpp, but this script only works for Android |
I have been playing around with ollama and llama.cpp. I have an intel laptop and I wanted to use blas.
llama.cpp supports intel mkl and it seems to perform very well. I wanted to see if I can get this library to also compile with MKL.
I think I got it working.
I have a gnu build where
test-vec1
runs in about 10 seconds while the intel + mkl runs in about 2 seconds.