-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Aws system: integrate 6a/7a configs (#468)
* pull in static 7a/6a configs * class name fix; generate software.yaml properly; reference error to resource dir for packages.yaml; define extra mpirun-like opts * add dry run * quote error; consolidate into one line
- Loading branch information
Showing
4 changed files
with
113 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 14 additions & 0 deletions
14
systems/aws-pcluster/compilers/gcc/00-gcc-7-compilers.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
compilers: | ||
- compiler: | ||
spec: [email protected] | ||
paths: | ||
cc: /usr/bin/gcc | ||
cxx: /usr/bin/g++ | ||
f77: /usr/bin/gfortran | ||
fc: /usr/bin/gfortran | ||
flags: {} | ||
operating_system: alinux2 | ||
target: x86_64 | ||
modules: [] | ||
environment: {} | ||
extra_rpaths: [] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
packages: | ||
tar: | ||
externals: | ||
- spec: [email protected] | ||
prefix: /usr | ||
buildable: false | ||
gmake: | ||
externals: | ||
- spec: [email protected] | ||
prefix: /usr | ||
blas: | ||
externals: | ||
- spec: [email protected] | ||
prefix: /usr | ||
buildable: false | ||
lapack: | ||
externals: | ||
- spec: [email protected] | ||
prefix: /usr | ||
buildable: false | ||
mpi: | ||
buildable: false | ||
openmpi: | ||
externals: | ||
- spec: [email protected]%[email protected] | ||
prefix: /opt/amazon/openmpi | ||
extra_attributes: | ||
ldflags: "-L/opt/amazon/openmpi/lib -lmpi" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,8 @@ | |
# | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
import pathlib | ||
|
||
from benchpark.system import System | ||
from benchpark.directives import variant | ||
|
||
|
@@ -17,21 +19,76 @@ | |
"sys_cores_per_node": 4, | ||
"sys_mem_per_node": 8, | ||
}, | ||
"hpc7a.48xlarge": { | ||
"sys_cores_per_node": 96, | ||
"sys_mem_per_node": 768, | ||
}, | ||
"hpc6a.48xlarge": { | ||
"sys_cores_per_node": 96, | ||
"sys_mem_per_node": 384, | ||
}, | ||
} | ||
|
||
|
||
class Aws(System): | ||
class AwsPcluster(System): | ||
variant( | ||
"instance_type", | ||
values=("c6g.xlarge", "c4.xlarge"), | ||
values=("c6g.xlarge", "c4.xlarge", "hpc7a.48xlarge", "hpc6a.48xlarge"), | ||
default="c4.xlarge", | ||
description="AWS instance type", | ||
) | ||
|
||
def initialize(self): | ||
super().initialize() | ||
self.scheduler = "mpi" | ||
self.scheduler = "slurm" | ||
# TODO: for some reason I have to index to get value, even if multi=False | ||
attrs = id_to_resources.get(self.spec.variants["instance_type"][0]) | ||
for k, v in attrs.items(): | ||
setattr(self, k, v) | ||
|
||
def system_specific_variables(self): | ||
return { | ||
"extra_cmd_opts": '--mpi=pmix --export=ALL,FI_EFA_USE_DEVICE_RDMA=1,FI_PROVIDER="efa",OMPI_MCA_mtl_base_verbose=100', | ||
} | ||
|
||
def external_pkg_configs(self): | ||
externals = AwsPcluster.resource_location / "externals" | ||
|
||
selections = [ | ||
externals / "base" / "00-packages.yaml", | ||
] | ||
|
||
return selections | ||
|
||
def compiler_configs(self): | ||
compilers = AwsPcluster.resource_location / "compilers" | ||
|
||
selections = [ | ||
compilers / "gcc" / "00-gcc-7-compilers.yaml", | ||
] | ||
|
||
return selections | ||
|
||
def generate_description(self, output_dir): | ||
super().generate_description(output_dir) | ||
|
||
sw_description = pathlib.Path(output_dir) / "software.yaml" | ||
|
||
with open(sw_description, "w") as f: | ||
f.write(self.sw_description()) | ||
|
||
def sw_description(self): | ||
return """\ | ||
software: | ||
packages: | ||
default-compiler: | ||
pkg_spec: [email protected] | ||
default-mpi: | ||
pkg_spec: [email protected]%[email protected] | ||
compiler-gcc: | ||
pkg_spec: [email protected] | ||
lapack: | ||
pkg_spec: [email protected] | ||
mpi-gcc: | ||
pkg_spec: [email protected]%[email protected] | ||
""" |