Rodrigo Arias Mallo
71c06d02da
This workaround stage prevents srun from returning 0 to the upper stages when a signal happens after MPI_Finalize. It writes the return code to a file named .srun.rc.$rank and later checks that exists and contains a 0. When the program is killed, exits with non-zero and the error is propagated to the baywatch stage, which aborts immediately without creating the rc file.
139 lines
3.6 KiB
Nix
139 lines
3.6 KiB
Nix
{
|
|
super
|
|
, self
|
|
, bsc
|
|
, callPackage
|
|
}:
|
|
|
|
{
|
|
develop = let
|
|
commonPackages = with self; [
|
|
coreutils htop procps-ng vim which strace
|
|
tmux gdb kakoune universal-ctags bashInteractive
|
|
glibcLocales ncurses git screen curl boost
|
|
# Add more nixpkgs packages here...
|
|
];
|
|
bscPackages = with bsc; [
|
|
slurm clangOmpss2 icc mcxx perf tampi impi vtk paraver
|
|
# Add more bsc packages here...
|
|
];
|
|
packages = commonPackages ++ bscPackages;
|
|
in
|
|
bsc.garlic.stages.exec rec {
|
|
nextStage = bsc.garlic.stages.isolate {
|
|
nextStage = bsc.garlic.unsafeDevelop.override {
|
|
extraInputs = packages;
|
|
};
|
|
nixPrefix = bsc.garlic.targetMachine.config.nixPrefix;
|
|
extraMounts = [ "/tmp:$TMPDIR" ];
|
|
};
|
|
nixPrefix = bsc.garlic.targetMachine.config.nixPrefix;
|
|
# This hack uploads all dependencies to MN4
|
|
pre = let
|
|
nixPrefix = bsc.garlic.targetMachine.config.nixPrefix;
|
|
stageProgram = bsc.garlicTools.stageProgram;
|
|
in
|
|
''
|
|
# Hack to upload this to MN4: @upload-to-mn@
|
|
|
|
# Create a link to the develop script
|
|
ln -fs ${nixPrefix}${stageProgram nextStage} .nix-develop
|
|
'';
|
|
post = "\n";
|
|
};
|
|
|
|
unsafeDevelop = callPackage ./develop/default.nix { };
|
|
|
|
# Configuration for the machines
|
|
machines = callPackage ./machines.nix { };
|
|
|
|
report = callPackage ./report.nix {
|
|
fig = bsc.garlic.fig;
|
|
};
|
|
|
|
sedReport = callPackage ./sedReport.nix {
|
|
fig = bsc.garlic.fig;
|
|
};
|
|
|
|
bundleReport = callPackage ./bundleReport.nix {
|
|
fig = bsc.garlic.fig;
|
|
};
|
|
|
|
reportTar = callPackage ./reportTar.nix {
|
|
fig = bsc.garlic.fig;
|
|
};
|
|
|
|
# Use the configuration for the following target machine
|
|
targetMachine = bsc.garlic.machines.mn4;
|
|
|
|
# Load some helper functions to generate app variants
|
|
|
|
stdexp = callPackage ./stdexp.nix {
|
|
inherit (bsc.garlic) targetMachine stages pp;
|
|
};
|
|
|
|
# Execution stages
|
|
stages = {
|
|
sbatch = callPackage ./stages/sbatch.nix { };
|
|
srun = callPackage ./stages/srun.nix { };
|
|
baywatch = callPackage ./stages/baywatch.nix { };
|
|
control = callPackage ./stages/control.nix { };
|
|
exec = callPackage ./stages/exec.nix { };
|
|
script = callPackage ./stages/script.nix { };
|
|
extrae = callPackage ./stages/extrae.nix { };
|
|
valgrind = callPackage ./stages/valgrind.nix { };
|
|
perf = callPackage ./stages/perf.nix { };
|
|
isolate = callPackage ./stages/isolate { };
|
|
runexp = callPackage ./stages/runexp { };
|
|
trebuchet = callPackage ./stages/trebuchet.nix { };
|
|
strace = callPackage ./stages/strace.nix { };
|
|
unit = callPackage ./stages/unit.nix { };
|
|
experiment = callPackage ./stages/experiment.nix { };
|
|
};
|
|
|
|
# Tests (move to bsc ?)
|
|
mpptest = callPackage ./mpptest { };
|
|
|
|
ppong = callPackage ./ppong {
|
|
mpi = bsc.mpi;
|
|
};
|
|
|
|
hist = callPackage ./pp/hist { };
|
|
|
|
tool = callPackage ./sh/default.nix {
|
|
sshHost = "mn1";
|
|
};
|
|
|
|
# Post processing
|
|
pp = {
|
|
store = callPackage ./pp/store.nix { };
|
|
rPlot = callPackage ./pp/rplot.nix { };
|
|
mergeDatasets = callPackage ./pp/merge.nix { };
|
|
};
|
|
|
|
garlicd = callPackage ./garlicd/default.nix {
|
|
garlicTool = bsc.garlic.tool;
|
|
};
|
|
|
|
# Apps for Garlic
|
|
apps = callPackage ./apps/index.nix {
|
|
inherit self super bsc;
|
|
};
|
|
|
|
# Experiments
|
|
exp = callPackage ./exp/index.nix {
|
|
inherit self super bsc;
|
|
};
|
|
|
|
# Dataset generators from resultTree
|
|
ds = callPackage ./ds/index.nix {
|
|
inherit self super bsc;
|
|
};
|
|
|
|
# Figures generated from the datasets
|
|
fig = callPackage ./fig/index.nix {
|
|
inherit self super bsc;
|
|
};
|
|
|
|
}
|