bscpkgs/garlic/exp/hpcg/oss.nix

77 lines
1.8 KiB
Nix
Raw Normal View History

2020-10-22 13:32:20 +02:00
{
stdenv
, stdexp
, bsc
, targetMachine
, stages
}:
with stdenv.lib;
let
# Initial variable configuration
varConf = with bsc; {
2020-11-05 19:46:34 +01:00
# FIXME: Temporally reduce the input size until we can load a precomputed
# input in each run, otherwise the execution time is very large.
n = [ { x = 104; y = 104; z = 104; } ];
#n = [ { x = 256; y = 288; z = 288; } ];
nblocks = [ 12 24 48 96 192 384 ];
2020-10-22 13:32:20 +02:00
};
# Generate the complete configuration for each unit
genConf = with bsc; c: targetMachine.config // rec {
2020-11-02 10:59:36 +01:00
expName = "hpcg.oss";
unitName = "${expName}.nb${toString nblocks}";
2020-10-22 13:32:20 +02:00
# hpcg options
n = c.n;
nblocks = c.nblocks;
cc = bsc.icc;
mcxx = bsc.mcxx;
nanos6 = bsc.nanos6;
mpi = null; # TODO: Remove this for oss
gitBranch = "garlic/oss";
# Repeat the execution of each unit 30 times
loops = 30;
# Resources
qos = "debug";
2020-10-23 10:06:23 +02:00
ntasksPerNode = 1;
2020-10-22 13:32:20 +02:00
nodes = 1;
time = "02:00:00";
# task in one socket
cpuBind = "verbose,mask_cpu:0xffffff";
jobName = "hpcg-${toString n.x}-${toString n.y}-${toString n.z}-${gitBranch}";
2020-10-22 13:32:20 +02:00
};
# Compute the array of configurations
configs = stdexp.buildConfigs {
inherit varConf genConf;
};
exec = {nextStage, conf, ...}: with conf; stages.exec {
inherit nextStage;
env = "NANOS6_DEPENDENCIES=discrete";
2020-10-22 13:32:20 +02:00
argv = [
"--nx=${toString n.x}"
"--ny=${toString n.y}"
"--nz=${toString n.z}"
2020-10-22 13:32:20 +02:00
"--nblocks=${toString nblocks}"
];
};
program = {nextStage, conf, ...}: with conf;
let
customPkgs = stdexp.replaceMpi conf.mpi;
in
customPkgs.apps.hpcg.override {
inherit cc nanos6 mcxx gitBranch;
};
pipeline = stdexp.stdPipeline ++ [ exec program ];
in
stdexp.genExperiment { inherit configs pipeline; }