Skip to content
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

InitError on Julia 1.3 with system MPI #455

Closed
jipolanco opened this issue Mar 15, 2021 · 1 comment · Fixed by #456
Closed

InitError on Julia 1.3 with system MPI #455

jipolanco opened this issue Mar 15, 2021 · 1 comment · Fixed by #456

Comments

@jipolanco
Copy link
Contributor

jipolanco commented Mar 15, 2021

For some reason that I don't really understand, MPI.jl 0.17 throws an InitError when loaded using Julia 1.3 on Unix (or at least Linux) systems, when using the system MPI libraries.

See here for an example, that I have also reproduced locally on Fedora 33. I also tested on Julia 1.5, 1.6 and nightly, where the issue does not appear.

The issue seems to be related to #451. The problem is that ccall does not seem to find MPI_Get_library_version. I managed to workaround the issue by adding an exception for this specific function in the @mpicall macro.

My workaround can be seen here, and I can open a PR if this is a proper solution.

Here is a minimum example:

➜  MPI git:(master) ~/opt/julia-1.3/bin/julia --project -e 'using MPI'
ERROR: InitError: ccall: could not find function MPI_Get_library_version
Stacktrace:
 [1] Get_library_version() at /home/jipolanco/.julia/dev/MPI/src/implementations.jl:36
 [2] __init__deps() at /home/jipolanco/.julia/dev/MPI/deps/deps.jl:11
 [3] __init__() at /home/jipolanco/.julia/dev/MPI/src/MPI.jl:67
 [4] _include_from_serialized(::String, ::Array{Any,1}) at ./loading.jl:692
 [5] _require_from_serialized(::String) at ./loading.jl:743
 [6] _require(::Base.PkgId) at ./loading.jl:1034
 [7] require(::Base.PkgId) at ./loading.jl:922
 [8] require(::Module, ::Symbol) at ./loading.jl:917
during initialization of module MPI
@simonbyrne
Copy link
Member

simonbyrne commented Mar 16, 2021

I'm not sure why that would happen, but I'm happy to accept a PR if you need Julia 1.3 support.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants