bscpkgs/garlic/exp/saiph/numcomm.nix

62 lines
1.3 KiB
Nix
Raw Normal View History

2020-09-21 17:30:24 +02:00
{
stdenv
2020-10-09 17:20:50 +02:00
, stdexp
, bsc
, targetMachine
, stages
2020-09-21 17:30:24 +02:00
}:
with stdenv.lib;
let
2020-10-09 17:20:50 +02:00
# Configurations for each unit (using the cartesian product)
confUnit = with bsc; {
numComm = [ 1 2 ];
2020-09-21 17:30:24 +02:00
};
2020-10-09 17:20:50 +02: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 17:30:24 +02:00
2020-10-09 17:20:50 +02:00
# Repeat the execution of each unit 30 times
loops = 100;
2020-09-21 17:30:24 +02:00
2020-10-09 17:20:50 +02:00
# Resources
ntasksPerNode = 2;
nodes = 1;
cpuBind = "sockets,verbose";
2020-09-22 17:39:26 +02:00
};
2020-10-09 17:20:50 +02:00
# Compute the array of configurations
configs = stdexp.buildConfigs {
var = confUnit;
fixed = targetMachine.config // confExperiment;
2020-09-22 17:39:26 +02:00
};
2020-09-21 17:30:24 +02:00
2020-10-09 17:20:50 +02:00
exec = {nextStage, conf, ...}: with conf; stages.exec {
inherit nextStage;
2020-09-23 13:13:51 +02:00
env = ''
2020-10-07 11:38:57 +02:00
export OMP_NUM_THREADS=24
2020-09-23 13:13:51 +02:00
export NANOS6_REPORT_PREFIX="#"
export I_MPI_THREAD_SPLIT=1
2020-10-09 17:20:50 +02:00
export ASAN_SYMBOLIZER_PATH=${bsc.clangOmpss2Unwrapped}/bin/llvm-symbolizer
2020-09-23 13:13:51 +02:00
'';
};
2020-10-09 17:20:50 +02: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 17:30:24 +02:00
2020-10-09 17:20:50 +02:00
pipeline = stdexp.stdStages ++ [ exec program ];
2020-09-21 17:30:24 +02:00
in
2020-10-09 17:20:50 +02:00
stdexp.genExperiment { inherit configs pipeline; }