-
Notifications
You must be signed in to change notification settings - Fork 18
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
Detect interface type for LAPACK #35
Comments
We probably need to fix this so that we can use Accelerate on macOS, essential for M1. |
Here's on MacOS with BLAS forwards for Accelerate:
Will Apple BLAS + Yggdrasil built LAPACK work together? cc @giordano @staticfloat |
You need to load Apple Accelerate first: On Apple Silicon (which has no complex return style problems)
On x86_64 (which does have complex return style problems)
|
Is it possible that LAPACK on the same platform (arm macos) has different settings (on complex return type and such) than what Apple ships in Accelerate? |
Doesn't work for me.
|
With JuliaLang/julia#82 this works. Is it a problem that the different libraries (BLAS From Accelerate and LAPACK from Ygg) have different fortran calling conventions and different complex return style?
|
Doesn't seem to work though. Just after doing the BLAS forwards to Accelerate, and trying to run peakflops:
|
I don't think it should be a problem, as Accelerate should call its own symbols internally. We expose a "gfortran" calling convention and "normal" complex return style, so LBT will automatically translate Accelerate to conform to that, allowing LAPACK to call Accelerate without problems. If we had a library that called into LBT expecting a non-gfortran calling convention, that would be a problem.
Your Julia is trying to call ILP64 symbols which you cleared out. Julia will never use Accelerate, since Accelerate is LP64-only. You would need to build Julia to use LP64 instead. |
I see - with MKL, we have ILP64, and we just forward the symbols. I suppose if we had a solution to JuliaLang/LinearAlgebra.jl#891, we could use Accelerate seamlessly. Otherwise, it is unlikely we will. |
@perrutquist I guess this is where SetBlasInt.jl could come in handy. In theory, we now have a full LP64 Accelerate BLAS + LAPACK that we can use through SetBlasInt on the mac. It's all a bit of a hack, but should probably work. |
I think we are ok without this. The original reason was Apple's BLAS, but we have ILP64 on macOS now: https://discourse.julialang.org/t/appleaccelerate-jl-v0-4-0/99351 |
This is using the LAPACK that is registered in Yggdrasil. I suppose we only have a BLAS test for detecting the interface type, and we should probably do it with an LAPACK function as well.
We need to do this so that we can load BLAS and LAPACK separately (as the case will be if we use a BLIS provided BLAS). Currently we have only tested OpenBLAS and MKL, both of which ship both BLAS and LAPACK.
The text was updated successfully, but these errors were encountered: