-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Patch ARPACK for fortran calling convention to be consistent with MKL. #5303
Conversation
elseif blas == :mkl | ||
if Base.USE_BLAS64 | ||
ENV["MKL_INTERFACE_LAYER"] = "ILP64" | ||
end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the indentation here is a bit weird
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was some emacs mode weirdness, but I already fixed it.
Cc: @vtjnash |
@vtjnash Would we be better off just compiling all our fortran code with |
@ViralBShah yes, it's better to compile with it seems that this patch only patches half of the issue -- it neglects to correct the calling convention return types for sasum, scasum, scnrm2, sdot, sdsdot, and snrm2 for which there is no way to specify the f2c calling convention using gfortran. plus, it neglects to patch any calls into lapack (although since we have our own lapack, that's less of a problem) I would suggest making separate binaries |
How about just always compiling everything fortran with |
Yes. Although (a) we need Julia to support the intel calling convention #2167 (b) we need to check that the other libraries (arpack, fftw, suitesparse) are aware of the f2c calling convention and ILP64 interface. |
The ARPACK patch from macports does not crash our ARPACK tests. Using Does Intel have a different fortran calling convention and not use f2c? |
Would this work with Accelerate if we disable gfortblas? |
If we manage to use |
Agree. |
Pass JFFLAGS to ARPACK and openspecfun.
I have pared down this PR to include some small fixes. Will try linking to the gfortran version of libmkl in a separate PR. |
Patch ARPACK for fortran calling convention to be consistent with MKL.
This patch was obtained from macports: http://trac.macports.org/ticket/35508
This also sets the environment variable for the ILP64 MKL upon startup, if
USE_BLAS64=1
See #3928 JuliaLang/LinearAlgebra.jl#53