-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
96f27e9
commit 4f75cad
Showing
4 changed files
with
160 additions
and
21 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,23 @@ | ||
#!/usr/bin/env python3 | ||
# -*- coding: utf-8 -*- | ||
"""Manually construct run configurations via the Python DSL interface.""" | ||
""" | ||
Manually construct run configurations via the Python DSL interface. | ||
# | ||
# def get_cpp_reference_impl() -> RunConfiguration: | ||
# """Build a run configuration for the reference implementation.""" | ||
# run.sbatch_config = { | ||
# "ntasks-per-node": "1", | ||
# "cpus-per-task": "1", | ||
# "mem-per-cpu": "3700", # max on avon? | ||
```python | ||
from hpc_multibench.configuration import RunConfiguration | ||
def get_cpp_reference_impl() -> RunConfiguration: | ||
'''Build a run configuration for the reference implementation.''' | ||
run = RunConfiguration("./test_HPCCG") | ||
run.build_commands = ["make -j 8"] | ||
run.sbatch_config = { | ||
"nodes": "1", | ||
"ntasks-per-node": "1", | ||
"cpus-per-task": "1", | ||
"mem-per-cpu": "3700", # max on avon? | ||
} | ||
run.module_loads = ["GCC/11.3.0"] | ||
run.directory = Path("../0_cpp_versions/0_ref") | ||
return run | ||
``` | ||
""" |
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
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,126 @@ | ||
#defaults: | ||
# "default name": | ||
executables: | ||
"cpp_reference": | ||
sbatch_config: | ||
"nodes": 1 | ||
"ntasks-per-node": 1 | ||
"cpus-per-task": 1 | ||
"mem-per-cpu": 3700 | ||
module_loads: | ||
- "GCC/11.3.0" | ||
environment_variables: {} | ||
directory: "../0_cpp_versions/0_ref" | ||
build_commands: | ||
- "make -j 8" | ||
run_command: "./test_HPCCG" | ||
|
||
"cpp_openmp": | ||
sbatch_config: | ||
"nodes": 1 | ||
"ntasks-per-node": 1 | ||
"cpus-per-task": 16 | ||
"mem-per-cpu": 3700 | ||
module_loads: | ||
- "GCC/11.3.0" | ||
environment_variables: | ||
"OMP_NUM_THREADS": 16 | ||
directory: "../0_cpp_versions/1_openmp" | ||
build_commands: | ||
- "make -j 8" | ||
run_command: "./test_HPCCG" | ||
|
||
"cpp_mpi": | ||
sbatch_config: | ||
"nodes": 2 | ||
"ntasks-per-node": 8 | ||
"cpus-per-task": 1 | ||
"mem-per-cpu": 3700 | ||
module_loads: | ||
- "GCC/11.3.0" | ||
- "OpenMPI/4.1.4" | ||
environment_variables: {} | ||
directory: "../0_cpp_versions/2_mpi" | ||
build_commands: | ||
- "make -j 8" | ||
run_command: "mpirun -n 2 ./test_HPCCG" | ||
|
||
"cpp_hybrid": | ||
sbatch_config: | ||
"nodes": 2 | ||
"ntasks-per-node": 4 | ||
"cpus-per-task": 2 | ||
"mem-per-cpu": 3700 | ||
module_loads: | ||
- "GCC/11.3.0" | ||
- "OpenMPI/4.1.4" | ||
environment_variables: | ||
"OMP_NUM_THREADS": 2 | ||
directory: "../0_cpp_versions/3_hybrid" | ||
build_commands: | ||
- "make -j 8" | ||
run_command: "mpirun -n 2 ./test_HPCCG" | ||
|
||
"rust_reference": | ||
sbatch_config: | ||
"nodes": 1 | ||
"ntasks-per-node": 1 | ||
"cpus-per-task": 1 | ||
"mem-per-cpu": 3700 | ||
module_loads: | ||
- "GCC/11.3.0" | ||
- "Clang/13.0.1" | ||
environment_variables: {} | ||
directory: "../5_iterators" | ||
build_commands: | ||
- "cargo build --release" | ||
run_command: "cargo run --release" | ||
|
||
"rust_rayon": | ||
sbatch_config: | ||
"nodes": 1 | ||
"ntasks-per-node": 1 | ||
"cpus-per-task": 16 | ||
"mem-per-cpu": 3700 | ||
module_loads: | ||
- "GCC/11.3.0" | ||
- "Clang/13.0.1" | ||
environment_variables: | ||
"OMP_NUM_THREADS": 16 | ||
directory: "../6_parallel" | ||
build_commands: | ||
- "cargo build --release" | ||
run_command: "cargo run --release" | ||
|
||
"rust_mpi": | ||
sbatch_config: | ||
"nodes": 2 | ||
"ntasks-per-node": 8 | ||
"cpus-per-task": 1 | ||
"mem-per-cpu": 3700 | ||
module_loads: | ||
- "GCC/11.3.0" | ||
- "Clang/13.0.1" | ||
- "OpenMPI/4.1.4" | ||
environment_variables: {} | ||
directory: "../6_mpi" | ||
build_commands: | ||
- "cargo build --release" | ||
run_command: "mpirun -n 2 cargo run --release" | ||
|
||
benches: | ||
"cpp_rust_comp": | ||
executables: | ||
- "cpp_reference" | ||
- "cpp_openmp" | ||
# - "cpp_mpi" | ||
# - "cpp_hybrid" | ||
- "rust_reference" | ||
# - "rust_rayon" | ||
# - "rust_mpi" | ||
matrix: | ||
- args: | ||
- "50 50 50" | ||
- "100 100 100" | ||
- environment_variables: | ||
- OMP_NUM_THREADS: 8 |
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 |
---|---|---|
@@ -1,25 +1,26 @@ | ||
#- defaults: | ||
# - "default name": | ||
#defaults: | ||
# "default name": | ||
executables: | ||
"executable name": | ||
sbatch_config: | ||
"nodes": 1 | ||
"ntasks-per-node": 1 | ||
"cpus-per-task": "1" | ||
"mem-per-cpu": "3700" | ||
"cpus-per-task": 1 | ||
"mem-per-cpu": 3700 | ||
module_loads: | ||
- "GCC/11.3.0" | ||
environment_variables: {} | ||
directory: "../0_cpp_versions/0_ref" | ||
build_commands: | ||
- "make -j 8" | ||
run_command: "./test_HPCCG" | ||
|
||
benches: | ||
"bench name": | ||
executables: ["executable name"] | ||
matrix: | ||
- args: | ||
- "50 50 50" | ||
- "100 100 100" | ||
- environment_variables: | ||
- OMP_NUM_THREADS: 8 | ||
"bench name": | ||
executables: ["executable name"] | ||
matrix: | ||
- args: | ||
- "50 50 50" | ||
- "100 100 100" | ||
- environment_variables: | ||
- OMP_NUM_THREADS: 8 |