Skip to content

Commit

Permalink
run_init_hooks() if MPI already initialized
Browse files Browse the repository at this point in the history
Fixes #746
  • Loading branch information
simonbyrne authored Jul 16, 2023
1 parent 2a2bd68 commit a6bca29
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/MPI.jl
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,11 @@ function __init__()
@require AMDGPU="21141c5a-9bdb-4563-92ae-f87d6854732e" include("../ext/AMDGPUExt.jl")
@require CUDA="052768ef-5323-5732-b1bb-66c8b64840ba" include("../ext/CUDAExt.jl")
end

if MPI.Initialized()
# if MPI initialized elsewhere, e.g. when building a library
MPI.run_init_hooks()
end
end


Expand Down

0 comments on commit a6bca29

Please sign in to comment.