Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 11 additions & 4 deletions create_lmodrc.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
return content
end

local function cuda_enabled_load_hook(t)
local function eessi_cuda_enabled_load_hook(t)
local frameStk = require("FrameStk"):singleton()
local mt = frameStk:mt()
local simpleName = string.match(t.modFullName, "(.-)/")
Expand Down Expand Up @@ -94,7 +94,7 @@
end
end

local function openmpi_load_hook(t)
local function eessi_openmpi_load_hook(t)
-- disable smcuda BTL when loading OpenMPI module for aarch64/neoverse_v1,
-- to work around hang/crash due to bug in OpenMPI;
-- see https://gitlab.com/eessi/support/-/issues/41
Expand All @@ -114,8 +114,15 @@
end
end

hook.register("load", cuda_enabled_load_hook)
hook.register("load", openmpi_load_hook)
-- Combine both functions into a single one, as we can only register one function as load hook in lmod
-- Also: make it non-local, so it can be imported and extended by other lmodrc files if needed
function eessi_load_hook(t)
eessi_cuda_enabled_load_hook(t)
eessi_openmpi_load_hook(t)
end


hook.register("load", eessi_load_hook)
"""

def error(msg):
Expand Down