bscpkgs/garlic/exp/saiph/numcomm.nix

68 lines
1.4 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-10 01:40:49 +08:00
# Initial variable configuration
varConf = with bsc; {
2020-10-09 23:20:50 +08:00
numComm = [ 1 2 ];
2020-09-21 23:30:24 +08:00
};
2020-10-10 01:40:49 +08:00
# Generate the complete configuration for each unit
genConf = with bsc; c: targetMachine.config // rec {
expName = "saiph.numcomm";
unitName = "${expName}.nc-${toString numComm}";
inherit (targetMachine.config) hw;
2020-10-09 23:20:50 +08:00
# saiph options
2020-10-10 01:40:49 +08:00
inherit (c) numComm;
2020-10-09 23:20:50 +08:00
mpi = impi;
gitBranch = "garlic/tampi+isend+oss+task+simd";
2020-09-21 23:30:24 +08:00
2020-10-10 01:40:49 +08:00
# Repeat the execution of each unit 100 times
2020-10-09 23:20:50 +08:00
loops = 100;
2020-09-21 23:30:24 +08:00
2020-10-09 23:20:50 +08:00
# Resources
2020-10-10 01:40:49 +08:00
qos = "debug";
time = "02:00:00";
2020-10-09 23:20:50 +08:00
ntasksPerNode = 2;
nodes = 1;
cpusPerTask = hw.cpusPerSocket;
2020-10-10 01:40:49 +08:00
jobName = "saiph-${toString numComm}-${gitBranch}";
2020-09-22 23:39:26 +08:00
};
2020-10-09 23:20:50 +08:00
# Compute the array of configurations
configs = stdexp.buildConfigs {
2020-10-10 01:40:49 +08:00
inherit varConf genConf;
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
2020-10-10 01:40:49 +08:00
customPkgs.apps.saiph.override {
2020-11-13 02:10:43 +08:00
inherit numComm mpi gitBranch;
2020-10-10 01:40:49 +08:00
};
2020-09-21 23:30:24 +08:00
2020-10-10 01:40:49 +08:00
pipeline = stdexp.stdPipeline ++ [ exec program ];
2020-09-21 23:30:24 +08:00
in
2020-10-09 23:20:50 +08:00
stdexp.genExperiment { inherit configs pipeline; }