osu: add multithread benchmark
This commit is contained in:
parent
8373751f67
commit
a36d912022
@ -95,7 +95,10 @@
|
||||
test = callPackage ./lulesh/test.nix { };
|
||||
};
|
||||
|
||||
osu = {
|
||||
osu = rec {
|
||||
latency = callPackage ./osu/latency.nix { };
|
||||
latencyShm = latency.override { interNode = false; };
|
||||
latencyMt = latency.override { enableMultithread = true; };
|
||||
latencyMtShm = latency.override { enableMultithread = true; interNode = true; };
|
||||
};
|
||||
}
|
||||
|
@ -7,9 +7,16 @@
|
||||
|
||||
# Should we test the network (true) or the shared memory (false)?
|
||||
, interNode ? true
|
||||
, enableMultithread ? false
|
||||
}:
|
||||
|
||||
with builtins;
|
||||
with stdenv.lib;
|
||||
|
||||
let
|
||||
|
||||
machineConfig = targetMachine.config;
|
||||
|
||||
# Initial variable configuration
|
||||
varConf = with bsc; {
|
||||
mpi = [ impi bsc.openmpi mpich ]; #psmpi ];
|
||||
@ -17,9 +24,10 @@ let
|
||||
|
||||
# Generate the complete configuration for each unit
|
||||
genConf = with bsc; c: targetMachine.config // rec {
|
||||
inherit (machineConfig) hw;
|
||||
nodes = if interNode then 2 else 1;
|
||||
ntasksPerNode = if interNode then 1 else 2;
|
||||
cpusPerTask = 1;
|
||||
cpusPerTask = if (enableMultithread) then hw.cpusPerSocket else 1;
|
||||
time = "00:10:00";
|
||||
qos = "debug";
|
||||
loops = 30;
|
||||
@ -27,6 +35,7 @@ let
|
||||
unitName = expName;
|
||||
jobName = expName;
|
||||
inherit (c) mpi;
|
||||
inherit enableMultithread;
|
||||
};
|
||||
|
||||
# Compute the array of configurations
|
||||
@ -36,8 +45,15 @@ let
|
||||
|
||||
exec = {nextStage, conf, ...}: with conf; stages.exec {
|
||||
inherit nextStage;
|
||||
# We simply run the osu_latency test
|
||||
program = "${nextStage}/bin/osu_latency";
|
||||
|
||||
program = if (enableMultithread) then
|
||||
"${nextStage}/bin/osu_latency_mt"
|
||||
else
|
||||
"${nextStage}/bin/osu_latency";
|
||||
|
||||
argv = optionals (enableMultithread) [
|
||||
"-t" "${toString conf.cpusPerTask}:${toString conf.cpusPerTask}"
|
||||
];
|
||||
};
|
||||
|
||||
program = {nextStage, conf, ...}: bsc.osumb.override {
|
||||
|
Loading…
Reference in New Issue
Block a user