bscpkgs/garlic/exp/saiph/numcomm.nix

62 lines
1.3 KiB
Nix
Raw Normal View History

2020-09-21 23:30:24 +08:00
{
stdenv
2020-10-09 23:20:50 +08:00
, stdexp
, bsc
, targetMachine
, stages
2020-09-21 23:30:24 +08:00
}:
with stdenv.lib;
let
2020-10-09 23:20:50 +08:00
# Configurations for each unit (using the cartesian product)
confUnit = with bsc; {
numComm = [ 1 2 ];
2020-09-21 23:30:24 +08:00
};
2020-10-09 23:20:50 +08:00
# Configuration for the complete experiment
confExperiment = with bsc; {
# saiph options
devMode = false;
mpi = impi;
gitBranch = "garlic/tampi+isend+oss+task+simd";
2020-09-21 23:30:24 +08:00
2020-10-09 23:20:50 +08:00
# Repeat the execution of each unit 30 times
loops = 100;
2020-09-21 23:30:24 +08:00
2020-10-09 23:20:50 +08:00
# Resources
ntasksPerNode = 2;
nodes = 1;
cpuBind = "sockets,verbose";
2020-09-22 23:39:26 +08:00
};
2020-10-09 23:20:50 +08:00
# Compute the array of configurations
configs = stdexp.buildConfigs {
var = confUnit;
fixed = targetMachine.config // confExperiment;
2020-09-22 23:39:26 +08:00
};
2020-09-21 23:30:24 +08:00
2020-10-09 23:20:50 +08:00
exec = {nextStage, conf, ...}: with conf; stages.exec {
inherit nextStage;
2020-09-23 19:13:51 +08:00
env = ''
2020-10-07 17:38:57 +08:00
export OMP_NUM_THREADS=24
2020-09-23 19:13:51 +08:00
export NANOS6_REPORT_PREFIX="#"
export I_MPI_THREAD_SPLIT=1
2020-10-09 23:20:50 +08:00
export ASAN_SYMBOLIZER_PATH=${bsc.clangOmpss2Unwrapped}/bin/llvm-symbolizer
2020-09-23 19:13:51 +08:00
'';
};
2020-10-09 23:20:50 +08:00
program = {nextStage, conf, ...}: with conf;
let
customPkgs = stdexp.replaceMpi conf.mpi;
in
customPkgs.apps.saiph.override {
inherit devMode numComm mpi gitBranch;
};
2020-09-21 23:30:24 +08:00
2020-10-09 23:20:50 +08:00
pipeline = stdexp.stdStages ++ [ exec program ];
2020-09-21 23:30:24 +08:00
in
2020-10-09 23:20:50 +08:00
stdexp.genExperiment { inherit configs pipeline; }