Skip to content

Commit 9217084

Browse files
authored
Merge branch 'main' into combine_cc_targets
2 parents 0e2a31f + 3550881 commit 9217084

4 files changed

Lines changed: 24 additions & 2 deletions

File tree

eb_hooks.py

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1058,6 +1058,27 @@ def pre_prepare_hook_pytorch(self, *args, **kwargs):
10581058
raise EasyBuildError("PyTorch-specific hook triggered for non-PyTorch easyconfig?!")
10591059

10601060

1061+
def pre_prepare_hook_LAMMPS_kokkos_CUDA_families(self, *args, **kwargs):
1062+
"""
1063+
Kokkos does not have support building for GPU families.
1064+
This cause problems for EasyBuild cuda sanity check for CUDA Compute Capalities such as 9.0a, 10.0f, 12.0f etc.
1065+
This hook strips the suffixes when building LAMMPS with kokkos.
1066+
"""
1067+
if self.name == 'LAMMPS':
1068+
if self.version in ['22Jul2025']:
1069+
if self.cfg['kokkos']:
1070+
cuda_cc = build_option('cuda_compute_capabilities')
1071+
if cuda_cc and '9.0a' in cuda_cc:
1072+
updated_cuda_cc = [v.replace('9.0a', '9.0') for v in cuda_cc]
1073+
update_build_option('cuda_compute_capabilities', updated_cuda_cc)
1074+
elif cuda_cc and '10.0f' in cuda_cc:
1075+
updated_cuda_cc = [v.replace('10.0f', '10.0') for v in cuda_cc]
1076+
update_build_option('cuda_compute_capabilities', updated_cuda_cc)
1077+
elif cuda_cc and '12.0f' in cuda_cc:
1078+
updated_cuda_cc = [v.replace('12.0f', '12.0') for v in cuda_cc]
1079+
update_build_option('cuda_compute_capabilities', updated_cuda_cc)
1080+
1081+
10611082
def post_prepare_hook_llvm_a64fx(self, *args, **kwargs):
10621083
"""
10631084
Post-prepare hook for LLVM 14 and 15 on A64FX to reset optarch build option.
@@ -2076,6 +2097,7 @@ def post_easyblock_hook(self, *args, **kwargs):
20762097
PRE_PREPARE_HOOKS = {
20772098
'cuDNN': pre_prepare_hook_cudnn,
20782099
'Highway': pre_prepare_hook_highway_handle_test_compilation_issues,
2100+
'LAMMPS': pre_prepare_hook_LAMMPS_kokkos_CUDA_families,
20792101
'LLVM': pre_prepare_hook_llvm_a64fx,
20802102
'PyTorch': pre_prepare_hook_pytorch,
20812103
'Rust': pre_prepare_hook_llvm_a64fx,

scripts/cfg_files.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,13 +39,13 @@ function cfg_load {
3939
local cur_val=""
4040
IFS=
4141
while read -r line; do
42-
new_section=$(cfg_get_section $line)
42+
new_section=$(cfg_get_section "${line}")
4343
# got a new section
4444
if [[ -n "$new_section" ]]; then
4545
cur_section=$new_section
4646
# not a section, try a key value
4747
else
48-
val=$(cfg_get_key_value $line)
48+
val=$(cfg_get_key_value "${line}")
4949
# trim leading and trailing spaces as well
5050
cur_key=$(echo $val | cut -f1 -d'=' | cfg_trim_spaces)
5151
cur_val=$(echo $val | cut -f2 -d'=' | cfg_trim_spaces)

scripts/gpu_support/nvidia/easystacks/2023.06/eessi-2023.06-eb-4.9.4-2023a-CUDA-host-injections.yml renamed to scripts/gpu_support/nvidia/easystacks/2023.06/eessi-2023.06-eb-5.3.0-2023a-CUDA-host-injections.yml

File renamed without changes.

scripts/gpu_support/nvidia/easystacks/2023.06/eessi-2023.06-eb-4.9.4-2023b-CUDA-host-injections.yml renamed to scripts/gpu_support/nvidia/easystacks/2023.06/eessi-2023.06-eb-5.3.0-2023b-CUDA-host-injections.yml

File renamed without changes.

0 commit comments

Comments
 (0)