Begin moving bsc packages to root attribute
This commit is contained in:
parent
fd766d8ff8
commit
51dcc6896e
@ -1,8 +1,7 @@
|
||||
{
|
||||
stdenv
|
||||
llvmPackages_latest
|
||||
, fetchFromGitHub
|
||||
, cmake
|
||||
, lld
|
||||
, bash
|
||||
, python3
|
||||
, perl
|
||||
@ -14,7 +13,9 @@
|
||||
, enableDebug ? false
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
let
|
||||
stdenv = llvmPackages_latest.stdenv;
|
||||
in stdenv.mkDerivation rec {
|
||||
version = "2023.05.1";
|
||||
pname = "clang-ompss2";
|
||||
|
||||
@ -43,7 +44,7 @@ stdenv.mkDerivation rec {
|
||||
python3
|
||||
perl
|
||||
cmake
|
||||
lld
|
||||
llvmPackages_latest.lld
|
||||
elfutils
|
||||
libffi
|
||||
pkg-config
|
||||
|
@ -1,10 +1,9 @@
|
||||
{
|
||||
stdenv
|
||||
, gcc
|
||||
, rt
|
||||
, clangOmpss2Unwrapped
|
||||
, wrapCCWith
|
||||
, llvmPackages
|
||||
, llvmPackages_latest
|
||||
}:
|
||||
|
||||
|
||||
@ -13,16 +12,12 @@ let
|
||||
# We need to replace the lld linker from bintools with our linker just built,
|
||||
# otherwise we run into incompatibility issues when mixing compiler and linker
|
||||
# versions.
|
||||
bintools-unwrapped = llvmPackages.tools.bintools-unwrapped.override {
|
||||
bintools-unwrapped = llvmPackages_latest.tools.bintools-unwrapped.override {
|
||||
lld = clangOmpss2Unwrapped;
|
||||
};
|
||||
bintools = llvmPackages.tools.bintools.override {
|
||||
bintools = llvmPackages_latest.tools.bintools.override {
|
||||
bintools = bintools-unwrapped;
|
||||
};
|
||||
|
||||
homevar = if rt.pname == "nanos6" then "NANOS6_HOME" else "NODES_HOME";
|
||||
rtname = if rt.pname == "nanos6" then "libnanos6" else "libnodes";
|
||||
|
||||
targetConfig = stdenv.targetPlatform.config;
|
||||
inherit gcc;
|
||||
cc = clangOmpss2Unwrapped;
|
||||
@ -43,10 +38,6 @@ in wrapCCWith {
|
||||
|
||||
echo "--gcc-toolchain=${gcc}" >> $out/nix-support/cc-cflags
|
||||
|
||||
# Setup NANOS6_HOME or NODES_HOME, based on the runtime.
|
||||
echo "export ${homevar}=${rt}" >> $out/nix-support/setup-hook
|
||||
echo "export OMPSS2_RUNTIME=${rtname}" >> $out/nix-support/setup-hook
|
||||
|
||||
wrap clang++ $wrapper $ccPath/clang++
|
||||
'';
|
||||
}
|
||||
|
@ -13,7 +13,7 @@
|
||||
, ovni
|
||||
, enableDebug ? false
|
||||
, enableJemalloc ? true
|
||||
, jemalloc ? null
|
||||
, jemallocNanos6 ? null
|
||||
, cachelineBytes ? 64
|
||||
, enableGlibcxxDebug ? false
|
||||
, useGit ? false
|
||||
@ -22,7 +22,7 @@
|
||||
, gitCommit ? "58712e669ac02f721fb841247361ea54f53a6a47"
|
||||
}:
|
||||
|
||||
assert enableJemalloc -> (jemalloc != null);
|
||||
assert enableJemalloc -> (jemallocNanos6 != null);
|
||||
|
||||
with lib;
|
||||
|
||||
@ -73,7 +73,7 @@ in
|
||||
"--enable-ovni-instrumentation"
|
||||
"--with-ovni=${ovni}"
|
||||
] ++
|
||||
(optional enableJemalloc "--with-jemalloc=${jemalloc}") ++
|
||||
(optional enableJemalloc "--with-jemalloc=${jemallocNanos6}") ++
|
||||
(optional enableGlibcxxDebug "CXXFLAGS=-D_GLIBCXX_DEBUG");
|
||||
|
||||
postConfigure = lib.optionalString (!enableDebug) ''
|
||||
@ -99,4 +99,10 @@ in
|
||||
papi
|
||||
ovni
|
||||
];
|
||||
|
||||
# Create a script that sets NANOS6_HOME
|
||||
postInstall = ''
|
||||
mkdir -p $out/nix-support
|
||||
echo "export NANOS6_HOME=$out" >> $out/nix-support/setup-hook
|
||||
'';
|
||||
}
|
||||
|
@ -21,7 +21,7 @@ let
|
||||
repo = "ovni";
|
||||
rev = "${version}";
|
||||
sha256 = "sha256-4ulohGnbQwAZ/qnm5bmceoMhTuAHlCfLAWEodZ9YMP0=";
|
||||
};
|
||||
} // { shortRev = "b6903bc4"; };
|
||||
};
|
||||
|
||||
git = rec {
|
||||
@ -40,5 +40,6 @@ in
|
||||
inherit (source) src version;
|
||||
buildInputs = [ cmake mpi ];
|
||||
cmakeBuildType = if (enableDebug) then "Debug" else "Release";
|
||||
cmakeFlags = [ "-DOVNI_GIT_COMMIT=${src.shortRev}" ];
|
||||
dontStrip = true;
|
||||
}
|
||||
|
@ -1,7 +1,5 @@
|
||||
{
|
||||
inputs = {
|
||||
nixpkgs.url = "nixpkgs";
|
||||
};
|
||||
inputs.nixpkgs.url = "nixpkgs";
|
||||
|
||||
outputs = { self, nixpkgs, ...}:
|
||||
let
|
||||
@ -14,6 +12,6 @@
|
||||
{
|
||||
bscOverlay = import ./overlay.nix;
|
||||
overlays.default = self.bscOverlay;
|
||||
packages.x86_64-linux = pkgs;
|
||||
legacyPackages.x86_64-linux = pkgs;
|
||||
};
|
||||
}
|
||||
|
803
overlay.nix
803
overlay.nix
@ -15,407 +15,420 @@ let
|
||||
# BSC Packages
|
||||
# ===================================================================
|
||||
|
||||
_bsc = makeExtensible (bsc:
|
||||
let
|
||||
callPackage = callPackageWith (self // bsc // bsc.garlic);
|
||||
in
|
||||
{
|
||||
inherit callPackage;
|
||||
# _bsc = makeExtensible (bsc:
|
||||
# let
|
||||
# callPackage = callPackageWith (self // bsc // bsc.garlic);
|
||||
# in
|
||||
# {
|
||||
# inherit callPackage;
|
||||
#
|
||||
# # =================================================================
|
||||
# # Compilers
|
||||
# # =================================================================
|
||||
#
|
||||
# # Default C (and C++) compiler to use. It will be overwritten by the
|
||||
# # experiments.
|
||||
# cc = bsc.icc;
|
||||
#
|
||||
# # By default we use Intel compiler 2020 update 1
|
||||
# intelLicense = callPackage ./bsc/intel-compiler/license.nix { };
|
||||
# iccUnwrapped = bsc.icc2020Unwrapped;
|
||||
# icc2020Unwrapped = callPackage ./bsc/intel-compiler/icc2020.nix {
|
||||
# intel-mpi = bsc.intelMpi;
|
||||
# };
|
||||
#
|
||||
# icc2021Unwrapped = callPackage ./bsc/intel-compiler/icc2021.nix { };
|
||||
#
|
||||
# intel-oneapi-2023 = callPackage ./bsc/intel-oneapi/2023.nix {
|
||||
# libffi = self.libffi_3_3;
|
||||
# };
|
||||
#
|
||||
# intel2023 = {
|
||||
# inherit (bsc.intel-oneapi-2023)
|
||||
# stdenv icx stdenv-ifort ifort
|
||||
# # Deprecated in mid 2023
|
||||
# stdenv-icc icc;
|
||||
# };
|
||||
#
|
||||
# intel2022 = {
|
||||
# icc = bsc.icc2021;
|
||||
# };
|
||||
#
|
||||
# intel2021 = {
|
||||
# icc = bsc.icc2021;
|
||||
# };
|
||||
#
|
||||
# # A wrapper script that puts all the flags and environment vars
|
||||
# # properly and calls the intel compiler binary
|
||||
# icc2020 = appendPasstru (callPackage ./bsc/intel-compiler/default.nix {
|
||||
# iccUnwrapped = bsc.iccUnwrapped;
|
||||
# intelLicense = bsc.intelLicense;
|
||||
# }) { CC = "icc"; CXX = "icpc"; };
|
||||
#
|
||||
# icc2021 = appendPasstru (callPackage ./bsc/intel-compiler/wrapper2021.nix {
|
||||
# iccUnwrapped = bsc.icc2021Unwrapped;
|
||||
# }) { CC = "icx"; CXX = "icpx"; };
|
||||
#
|
||||
# ifort2022 = callPackage ./bsc/intel-compiler/default.nix {
|
||||
# iccUnwrapped = bsc.ifort2022Unwrapped;
|
||||
# intelLicense = bsc.intelLicense;
|
||||
# };
|
||||
#
|
||||
# icx = bsc.intel2023.icx;
|
||||
# icc = bsc.intel2023.icc;
|
||||
# ifort = bsc.intel2023.ifort;
|
||||
#
|
||||
# # We need to set the cc.CC and cc.CXX attributes, in order to
|
||||
# # determine the name of the compiler
|
||||
# gcc = appendPasstru self.gcc { CC = "gcc"; CXX = "g++"; };
|
||||
#
|
||||
# # Last llvm release by default
|
||||
# llvmPackages = self.llvmPackages_latest // {
|
||||
# clang = appendPasstru self.llvmPackages_latest.clang {
|
||||
# CC = "clang"; CXX = "clang++";
|
||||
# };
|
||||
# };
|
||||
#
|
||||
# lld = bsc.llvmPackages.lld;
|
||||
#
|
||||
# clangOmpss2Unwrapped = callPackage ./bsc/llvm-ompss2/clang.nix {
|
||||
# stdenv = bsc.llvmPackages.stdenv;
|
||||
# };
|
||||
#
|
||||
# clangOmpss2UnwrappedGit = bsc.clangOmpss2Unwrapped.overrideAttrs (old: rec {
|
||||
# src = builtins.fetchGit {
|
||||
# url = "ssh://git@bscpm03.bsc.es/llvm-ompss/llvm-mono.git";
|
||||
# ref = "master";
|
||||
# };
|
||||
# version = src.shortRev;
|
||||
# });
|
||||
#
|
||||
# clangOmpss2 = appendPasstru (
|
||||
# callPackage ./bsc/llvm-ompss2/default.nix {
|
||||
# rt = bsc.nanos6;
|
||||
# llvmPackages = bsc.llvmPackages;
|
||||
# clangOmpss2Unwrapped = bsc.clangOmpss2Unwrapped;
|
||||
# }) { CC = "clang"; CXX = "clang++"; };
|
||||
#
|
||||
# clangOmpss2Git = appendPasstru (
|
||||
# callPackage ./bsc/llvm-ompss2/default.nix {
|
||||
# rt = bsc.nanos6;
|
||||
# llvmPackages = bsc.llvmPackages;
|
||||
# clangOmpss2Unwrapped = bsc.clangOmpss2UnwrappedGit;
|
||||
# }) { CC = "clang"; CXX = "clang++"; };
|
||||
#
|
||||
# stdenvClangOmpss2 = self.stdenv.override {
|
||||
# cc = bsc.clangOmpss2;
|
||||
# allowedRequisites = null;
|
||||
# };
|
||||
#
|
||||
# clangNodes = bsc.clangOmpss2.override {
|
||||
# rt = bsc.nodes;
|
||||
# };
|
||||
#
|
||||
# stdenvClangNodes = self.stdenv.override {
|
||||
# cc = bsc.clangNodes;
|
||||
# allowedRequisites = null;
|
||||
# };
|
||||
#
|
||||
# mcxx = bsc.mcxxRelease;
|
||||
# mcxxRelease = callPackage ./bsc/mcxx/default.nix { };
|
||||
# mcxxGit = callPackage ./bsc/mcxx/git.nix { };
|
||||
# mcxxRarias = callPackage ./bsc/mcxx/rarias.nix {
|
||||
# bison = self.bison_3_5;
|
||||
# };
|
||||
#
|
||||
# # =================================================================
|
||||
# # MPI
|
||||
# # =================================================================
|
||||
#
|
||||
# # Default MPI implementation to use. Will be overwritten by the
|
||||
# # experiments.
|
||||
# mpi = bsc.impi;
|
||||
#
|
||||
# # ParaStation MPI
|
||||
# pscom = callPackage ./bsc/parastation/pscom.nix { };
|
||||
# psmpi = callPackage ./bsc/parastation/psmpi.nix { };
|
||||
#
|
||||
# # MPICH
|
||||
# #mpich_3 = callPackage ./bsc/mpich/default.nix { };
|
||||
# #mpichDebug_3 = bsc.mpich.override { enableDebug = true; };
|
||||
# mpich = super.mpich.overrideAttrs (old: {
|
||||
# buildInputs = old.buildInputs ++ [ self.libfabric ];
|
||||
# configureFlags = old.configureFlags ++ [
|
||||
# "--with-device=ch4:ofi"
|
||||
# "--with-libfabric=${self.libfabric}"
|
||||
# ];
|
||||
# hardeningDisable = [ "all" ];
|
||||
# });
|
||||
#
|
||||
# impi = bsc.intel-mpi;
|
||||
# # The version of MPI for 2023 is labeled 2021.9 ...
|
||||
# intel-mpi = bsc.intel-oneapi-2023.intel-mpi;
|
||||
# # Old releases
|
||||
# intel-mpi-2019 = callPackage ./bsc/intel-mpi/default.nix { };
|
||||
#
|
||||
# # OpenMPI
|
||||
# openmpi = bsc.openmpi-mn4;
|
||||
# openmpi-mn4 = callPackage ./bsc/openmpi/default.nix {
|
||||
# pmix = bsc.pmix2;
|
||||
# pmi2 = bsc.slurm17-libpmi2;
|
||||
# enableCxx = true;
|
||||
# };
|
||||
#
|
||||
# # =================================================================
|
||||
# # GASPI
|
||||
# # =================================================================
|
||||
# gpi-2 = callPackage ./bsc/gpi-2/default.nix { };
|
||||
#
|
||||
# # Use GPI-2 as the default implementation for GASPI
|
||||
# gaspi = bsc.gpi-2;
|
||||
#
|
||||
# tagaspi = callPackage ./bsc/tagaspi/default.nix { };
|
||||
#
|
||||
# # =================================================================
|
||||
# # Tracing
|
||||
# # =================================================================
|
||||
#
|
||||
# # We should maintain these...
|
||||
# paraverKernelFast = callPackage ./bsc/paraver/kernel-fast.nix { };
|
||||
# wxparaverFast = callPackage ./bsc/paraver/wxparaver-fast.nix { };
|
||||
#
|
||||
# extrae = callPackage ./bsc/extrae/default.nix {
|
||||
# libdwarf = super.libdwarf_20210528;
|
||||
# };
|
||||
# otf = callPackage ./bsc/otf/default.nix { };
|
||||
# vite = self.qt5.callPackage ./bsc/vite/default.nix { };
|
||||
# babeltrace = callPackage ./bsc/babeltrace/default.nix { };
|
||||
# babeltrace2 = callPackage ./bsc/babeltrace2/default.nix { };
|
||||
#
|
||||
# # Perf for MN4 kernel
|
||||
# perf = callPackage ./bsc/perf/default.nix {
|
||||
# kernel = self.linuxPackages_4_9.kernel;
|
||||
# systemtap = self.linuxPackages_4_9.systemtap;
|
||||
# };
|
||||
#
|
||||
# cn6 = callPackage ./bsc/cn6/default.nix { };
|
||||
#
|
||||
# # =================================================================
|
||||
# # MN4 specific
|
||||
# # =================================================================
|
||||
#
|
||||
# lmbench = callPackage ./bsc/lmbench/default.nix { };
|
||||
# pmix2 = callPackage ./bsc/pmix/pmix2.nix { };
|
||||
# slurm17 = callPackage ./bsc/slurm/default.nix {
|
||||
# pmix = bsc.pmix2;
|
||||
# };
|
||||
# slurm17-libpmi2 = callPackage ./bsc/slurm/pmi2.nix {
|
||||
# pmix = bsc.pmix2;
|
||||
# };
|
||||
#
|
||||
# pmix4 =
|
||||
# let
|
||||
# libevent-all = with final; symlinkJoin {
|
||||
# name = "${libevent.name}-all";
|
||||
# paths = [ libevent.dev libevent.out ];
|
||||
# };
|
||||
# in
|
||||
# prev.pmix.overrideAttrs (old: rec {
|
||||
# version = "4.2.3";
|
||||
# # Don't use fetchFromGitHub as is not a release!
|
||||
# src = builtins.fetchTarball {
|
||||
# url = "https://github.com/openpmix/openpmix/releases/download/v${version}/pmix-${version}.tar.gz";
|
||||
# sha256 = "sha256:1iakrjkgydjz2f17if4cpyk1ldjff2790x4z787zdbbdnisxhdz2";
|
||||
# };
|
||||
# configureFlags = [
|
||||
# "--with-munge=${self.munge}"
|
||||
# "--with-hwloc=${self.hwloc.dev}"
|
||||
# ];
|
||||
# # libevent is not working, so use libev
|
||||
# buildInputs = old.buildInputs ++ [ self.python3 libevent-all ];
|
||||
# nativeBuildInputs = old.nativeBuildInputs ++ [ self.pkgconfig ];
|
||||
# });
|
||||
#
|
||||
# slurm-16-05-8-1 = callPackage ./bsc/slurm/16.05.8.1/default.nix {
|
||||
# hwloc = bsc.hwloc-1-11-6;
|
||||
# };
|
||||
#
|
||||
# hwloc-1-11-6 = callPackage ./bsc/hwloc/1.11.6/default.nix {};
|
||||
#
|
||||
# # Use a slurm compatible with MN4
|
||||
# slurm = bsc.slurm17;
|
||||
# # We need the unstable branch to get the fallocate problem fixed, as it is
|
||||
# # not yet in stable nix, see:
|
||||
# # https://pm.bsc.es/gitlab/rarias/bscpkgs/-/issues/83
|
||||
# nix-mn4 = self.nixUnstable;
|
||||
# # Our custom version that lacks the binaries. Disabled by default.
|
||||
# #rdma-core = callPackage ./bsc/rdma-core/default.nix { };
|
||||
#
|
||||
# # =================================================================
|
||||
# # Patched from upstream
|
||||
# # =================================================================
|
||||
#
|
||||
# groff = callPackage ./bsc/groff/default.nix { };
|
||||
# fftw = callPackage ./bsc/fftw/default.nix { };
|
||||
# vtk = callPackage ./bsc/vtk/default.nix {
|
||||
# inherit (self.xorg) libX11 xorgproto libXt;
|
||||
# };
|
||||
#
|
||||
# busybox = self.busybox.override {
|
||||
# enableStatic = true;
|
||||
# };
|
||||
#
|
||||
# # =================================================================
|
||||
# # Misc
|
||||
# # =================================================================
|
||||
#
|
||||
# dummy = callPackage ./bsc/dummy/default.nix { };
|
||||
# mpptest = callPackage ./bsc/mpptest/default.nix { };
|
||||
# cpuid = callPackage ./bsc/cpuid/default.nix { };
|
||||
#
|
||||
# # =================================================================
|
||||
# # Garlic benchmark
|
||||
# # =================================================================
|
||||
#
|
||||
# nixtools = callPackage ./bsc/nixtools/default.nix { };
|
||||
#
|
||||
# garlicTools = callPackage ./garlic/tools.nix {};
|
||||
#
|
||||
# # Aliases bsc.apps -> bsc.garlic.apps
|
||||
# inherit (bsc.garlic) apps fig exp ds;
|
||||
#
|
||||
# garlic = import ./garlic/index.nix {
|
||||
# inherit self super bsc callPackage;
|
||||
# };
|
||||
#
|
||||
# test = rec {
|
||||
## hwloc = callPackage ./test/bugs/hwloc.nix { };
|
||||
# sigsegv = callPackage ./test/reproducers/sigsegv.nix { };
|
||||
# compilers.hello-c = callPackage ./test/compilers/hello-c.nix { };
|
||||
# compilers.hello-cpp = callPackage ./test/compilers/hello-cpp.nix { };
|
||||
# compilers.hello-f = callPackage ./test/compilers/hello-f.nix { };
|
||||
# compilers.lto = callPackage ./test/compilers/lto.nix { };
|
||||
# compilers.asan = callPackage ./test/compilers/asan.nix { };
|
||||
# compilers.intel2023.icx.c = compilers.hello-c.override {
|
||||
# stdenv = bsc.intel2023.stdenv;
|
||||
# };
|
||||
# compilers.intel2023.icc.c = compilers.hello-c.override {
|
||||
# stdenv = bsc.intel2023.stdenv-icc;
|
||||
# };
|
||||
# compilers.intel2023.icx.cpp = compilers.hello-cpp.override {
|
||||
# stdenv = bsc.intel2023.stdenv;
|
||||
# };
|
||||
# compilers.intel2023.icc.cpp = compilers.hello-cpp.override {
|
||||
# stdenv = bsc.intel2023.stdenv-icc;
|
||||
# };
|
||||
# compilers.intel2023.ifort = compilers.hello-f.override {
|
||||
# stdenv = bsc.intel2023.stdenv-ifort;
|
||||
# };
|
||||
# compilers.clangOmpss2.lto = compilers.lto.override {
|
||||
# stdenv = bsc.stdenvClangOmpss2;
|
||||
# };
|
||||
# compilers.clangOmpss2.asan = compilers.asan.override {
|
||||
# stdenv = bsc.stdenvClangOmpss2;
|
||||
# };
|
||||
# compilers.clangOmpss2.task = callPackage ./test/compilers/ompss2.nix {
|
||||
# stdenv = bsc.stdenvClangOmpss2;
|
||||
# };
|
||||
# compilers.clangNodes.task = callPackage ./test/compilers/ompss2.nix {
|
||||
# stdenv = bsc.stdenvClangNodes;
|
||||
# };
|
||||
# };
|
||||
#
|
||||
# ci = import ./test/ci.nix {
|
||||
# inherit self super bsc callPackage;
|
||||
# };
|
||||
#
|
||||
# testAll = with bsc.test; [
|
||||
# compilers.intel2023.icx.c
|
||||
# compilers.intel2023.icc.c
|
||||
# compilers.intel2023.icx.cpp
|
||||
# compilers.intel2023.icc.cpp
|
||||
# compilers.intel2023.ifort
|
||||
# compilers.clangOmpss2.lto
|
||||
# compilers.clangOmpss2.task
|
||||
# compilers.clangOmpss2.asan
|
||||
# compilers.clangNodes.task
|
||||
# ];
|
||||
#
|
||||
# });
|
||||
|
||||
# =================================================================
|
||||
# Compilers
|
||||
# =================================================================
|
||||
callPackage = super.callPackage;
|
||||
|
||||
# Default C (and C++) compiler to use. It will be overwritten by the
|
||||
# experiments.
|
||||
cc = bsc.icc;
|
||||
in {
|
||||
ovni = callPackage ./bsc/ovni/default.nix { };
|
||||
ovniGit = self.ovni.override { useGit = true; };
|
||||
nanos6 = callPackage ./bsc/nanos6/default.nix { };
|
||||
nanos6Debug = self.nanos6.override { enableDebug = true; };
|
||||
jemallocNanos6 = super.jemalloc.overrideAttrs (old: {
|
||||
configureFlags = old.configureFlags ++ [
|
||||
"--with-jemalloc-prefix=nanos6_je_"
|
||||
"--enable-stats"
|
||||
];
|
||||
hardeningDisable = [ "all" ];
|
||||
});
|
||||
nosv = callPackage ./bsc/nosv/default.nix { };
|
||||
nodes = callPackage ./bsc/nodes/default.nix { };
|
||||
bench6 = callPackage ./bsc/bench6/default.nix { };
|
||||
nix-wrap = callPackage ./bsc/nix-wrap/default.nix { };
|
||||
osumb = callPackage ./bsc/osu/default.nix { };
|
||||
paraverKernel = callPackage ./bsc/paraver/kernel.nix { };
|
||||
wxparaver = callPackage ./bsc/paraver/default.nix { };
|
||||
tampi = callPackage ./bsc/tampi/default.nix { };
|
||||
sonar = callPackage ./bsc/sonar/default.nix { };
|
||||
clangOmpss2Unwrapped = callPackage ./bsc/llvm-ompss2/clang.nix { };
|
||||
clangOmpss2 = callPackage ./bsc/llvm-ompss2/default.nix { };
|
||||
stdenvClangOmpss2 = self.stdenv.override {
|
||||
cc = self.clangOmpss2;
|
||||
allowedRequisites = null;
|
||||
};
|
||||
|
||||
# By default we use Intel compiler 2020 update 1
|
||||
intelLicense = callPackage ./bsc/intel-compiler/license.nix { };
|
||||
iccUnwrapped = bsc.icc2020Unwrapped;
|
||||
icc2020Unwrapped = callPackage ./bsc/intel-compiler/icc2020.nix {
|
||||
intel-mpi = bsc.intelMpi;
|
||||
};
|
||||
|
||||
icc2021Unwrapped = callPackage ./bsc/intel-compiler/icc2021.nix { };
|
||||
|
||||
intel-oneapi-2023 = callPackage ./bsc/intel-oneapi/2023.nix {
|
||||
libffi = self.libffi_3_3;
|
||||
};
|
||||
|
||||
intel2023 = {
|
||||
inherit (bsc.intel-oneapi-2023)
|
||||
stdenv icx stdenv-ifort ifort
|
||||
# Deprecated in mid 2023
|
||||
stdenv-icc icc;
|
||||
};
|
||||
|
||||
intel2022 = {
|
||||
icc = bsc.icc2021;
|
||||
};
|
||||
|
||||
intel2021 = {
|
||||
icc = bsc.icc2021;
|
||||
};
|
||||
|
||||
# A wrapper script that puts all the flags and environment vars
|
||||
# properly and calls the intel compiler binary
|
||||
icc2020 = appendPasstru (callPackage ./bsc/intel-compiler/default.nix {
|
||||
iccUnwrapped = bsc.iccUnwrapped;
|
||||
intelLicense = bsc.intelLicense;
|
||||
}) { CC = "icc"; CXX = "icpc"; };
|
||||
|
||||
icc2021 = appendPasstru (callPackage ./bsc/intel-compiler/wrapper2021.nix {
|
||||
iccUnwrapped = bsc.icc2021Unwrapped;
|
||||
}) { CC = "icx"; CXX = "icpx"; };
|
||||
|
||||
ifort2022 = callPackage ./bsc/intel-compiler/default.nix {
|
||||
iccUnwrapped = bsc.ifort2022Unwrapped;
|
||||
intelLicense = bsc.intelLicense;
|
||||
};
|
||||
|
||||
icx = bsc.intel2023.icx;
|
||||
icc = bsc.intel2023.icc;
|
||||
ifort = bsc.intel2023.ifort;
|
||||
|
||||
# We need to set the cc.CC and cc.CXX attributes, in order to
|
||||
# determine the name of the compiler
|
||||
gcc = appendPasstru self.gcc { CC = "gcc"; CXX = "g++"; };
|
||||
|
||||
# Last llvm release by default
|
||||
llvmPackages = self.llvmPackages_latest // {
|
||||
clang = appendPasstru self.llvmPackages_latest.clang {
|
||||
CC = "clang"; CXX = "clang++";
|
||||
};
|
||||
};
|
||||
|
||||
lld = bsc.llvmPackages.lld;
|
||||
|
||||
clangOmpss2Unwrapped = callPackage ./bsc/llvm-ompss2/clang.nix {
|
||||
stdenv = bsc.llvmPackages.stdenv;
|
||||
};
|
||||
|
||||
clangOmpss2UnwrappedGit = bsc.clangOmpss2Unwrapped.overrideAttrs (old: rec {
|
||||
src = builtins.fetchGit {
|
||||
url = "ssh://git@bscpm03.bsc.es/llvm-ompss/llvm-mono.git";
|
||||
ref = "master";
|
||||
};
|
||||
version = src.shortRev;
|
||||
});
|
||||
|
||||
clangOmpss2 = appendPasstru (
|
||||
callPackage ./bsc/llvm-ompss2/default.nix {
|
||||
rt = bsc.nanos6;
|
||||
llvmPackages = bsc.llvmPackages;
|
||||
clangOmpss2Unwrapped = bsc.clangOmpss2Unwrapped;
|
||||
}) { CC = "clang"; CXX = "clang++"; };
|
||||
|
||||
clangOmpss2Git = appendPasstru (
|
||||
callPackage ./bsc/llvm-ompss2/default.nix {
|
||||
rt = bsc.nanos6;
|
||||
llvmPackages = bsc.llvmPackages;
|
||||
clangOmpss2Unwrapped = bsc.clangOmpss2UnwrappedGit;
|
||||
}) { CC = "clang"; CXX = "clang++"; };
|
||||
|
||||
stdenvClangOmpss2 = self.stdenv.override {
|
||||
cc = bsc.clangOmpss2;
|
||||
allowedRequisites = null;
|
||||
};
|
||||
|
||||
clangNodes = bsc.clangOmpss2.override {
|
||||
rt = bsc.nodes;
|
||||
};
|
||||
|
||||
stdenvClangNodes = self.stdenv.override {
|
||||
cc = bsc.clangNodes;
|
||||
allowedRequisites = null;
|
||||
};
|
||||
|
||||
mcxx = bsc.mcxxRelease;
|
||||
mcxxRelease = callPackage ./bsc/mcxx/default.nix { };
|
||||
mcxxGit = callPackage ./bsc/mcxx/git.nix { };
|
||||
mcxxRarias = callPackage ./bsc/mcxx/rarias.nix {
|
||||
bison = self.bison_3_5;
|
||||
};
|
||||
|
||||
# =================================================================
|
||||
# nanos6
|
||||
# =================================================================
|
||||
nanos6 = bsc.nanos6Release;
|
||||
nanos6Release = callPackage ./bsc/nanos6/default.nix { };
|
||||
nanos6Git = callPackage ./bsc/nanos6/default.nix { useGit = true; };
|
||||
nanos6-icx = bsc.nanos6.override {
|
||||
stdenv = bsc.intel2023.stdenv;
|
||||
};
|
||||
nanos6-icc = bsc.nanos6.override {
|
||||
stdenv = bsc.intel2023.stdenv-icc;
|
||||
};
|
||||
|
||||
nanos6Debug = bsc.nanos6.overrideAttrs (old: {
|
||||
dontStrip = true;
|
||||
enableDebugging = true;
|
||||
});
|
||||
|
||||
nanos6GlibcxxDebug = bsc.nanos6Debug.override {
|
||||
enableGlibcxxDebug = true;
|
||||
};
|
||||
|
||||
jemalloc = self.jemalloc.overrideAttrs (old:
|
||||
{
|
||||
# Custom nanos6 configure options
|
||||
configureFlags = old.configureFlags ++ [
|
||||
"--with-jemalloc-prefix=nanos6_je_"
|
||||
"--enable-stats"
|
||||
# Internal for our tests
|
||||
bsc-ci = {
|
||||
pkgs = super.runCommand "ci-pkgs" {
|
||||
buildInputs = with self; [
|
||||
ovni nanos6 nosv nodes nix-wrap osumb wxparaver tampi sonar
|
||||
clangOmpss2 bench6
|
||||
];
|
||||
|
||||
hardeningDisable = [ "all" ];
|
||||
});
|
||||
|
||||
nodes = bsc.nodesRelease;
|
||||
nodesRelease = callPackage ./bsc/nodes/default.nix { };
|
||||
nodesGit = callPackage ./bsc/nodes/default.nix { useGit = true; };
|
||||
nodesWithOvni = bsc.nodes.override { enableOvni = true; };
|
||||
|
||||
# =================================================================
|
||||
# nosv
|
||||
# =================================================================
|
||||
nosv = callPackage ./bsc/nosv/default.nix { };
|
||||
|
||||
# =================================================================
|
||||
# MPI
|
||||
# =================================================================
|
||||
|
||||
# Default MPI implementation to use. Will be overwritten by the
|
||||
# experiments.
|
||||
mpi = bsc.impi;
|
||||
|
||||
# ParaStation MPI
|
||||
pscom = callPackage ./bsc/parastation/pscom.nix { };
|
||||
psmpi = callPackage ./bsc/parastation/psmpi.nix { };
|
||||
|
||||
# MPICH
|
||||
#mpich_3 = callPackage ./bsc/mpich/default.nix { };
|
||||
#mpichDebug_3 = bsc.mpich.override { enableDebug = true; };
|
||||
mpich = super.mpich.overrideAttrs (old: {
|
||||
buildInputs = old.buildInputs ++ [ self.libfabric ];
|
||||
configureFlags = old.configureFlags ++ [
|
||||
"--with-device=ch4:ofi"
|
||||
"--with-libfabric=${self.libfabric}"
|
||||
];
|
||||
hardeningDisable = [ "all" ];
|
||||
});
|
||||
|
||||
impi = bsc.intel-mpi;
|
||||
# The version of MPI for 2023 is labeled 2021.9 ...
|
||||
intel-mpi = bsc.intel-oneapi-2023.intel-mpi;
|
||||
# Old releases
|
||||
intel-mpi-2019 = callPackage ./bsc/intel-mpi/default.nix { };
|
||||
|
||||
# OpenMPI
|
||||
openmpi = bsc.openmpi-mn4;
|
||||
openmpi-mn4 = callPackage ./bsc/openmpi/default.nix {
|
||||
pmix = bsc.pmix2;
|
||||
pmi2 = bsc.slurm17-libpmi2;
|
||||
enableCxx = true;
|
||||
};
|
||||
|
||||
# TAMPI
|
||||
tampi = bsc.tampiRelease;
|
||||
tampiRelease = callPackage ./bsc/tampi/default.nix { };
|
||||
tampiGit = callPackage ./bsc/tampi/git.nix { };
|
||||
|
||||
# Sonar
|
||||
sonar = callPackage ./bsc/sonar/default.nix { };
|
||||
|
||||
# =================================================================
|
||||
# GASPI
|
||||
# =================================================================
|
||||
gpi-2 = callPackage ./bsc/gpi-2/default.nix { };
|
||||
|
||||
# Use GPI-2 as the default implementation for GASPI
|
||||
gaspi = bsc.gpi-2;
|
||||
|
||||
tagaspi = callPackage ./bsc/tagaspi/default.nix { };
|
||||
|
||||
# =================================================================
|
||||
# Tracing
|
||||
# =================================================================
|
||||
|
||||
paraverKernel = callPackage ./bsc/paraver/kernel.nix { };
|
||||
wxparaver = callPackage ./bsc/paraver/default.nix { };
|
||||
|
||||
# We should maintain these...
|
||||
paraverKernelFast = callPackage ./bsc/paraver/kernel-fast.nix { };
|
||||
wxparaverFast = callPackage ./bsc/paraver/wxparaver-fast.nix { };
|
||||
|
||||
extrae = callPackage ./bsc/extrae/default.nix {
|
||||
libdwarf = super.libdwarf_20210528;
|
||||
};
|
||||
otf = callPackage ./bsc/otf/default.nix { };
|
||||
vite = self.qt5.callPackage ./bsc/vite/default.nix { };
|
||||
babeltrace = callPackage ./bsc/babeltrace/default.nix { };
|
||||
babeltrace2 = callPackage ./bsc/babeltrace2/default.nix { };
|
||||
|
||||
# Perf for MN4 kernel
|
||||
perf = callPackage ./bsc/perf/default.nix {
|
||||
kernel = self.linuxPackages_4_9.kernel;
|
||||
systemtap = self.linuxPackages_4_9.systemtap;
|
||||
};
|
||||
|
||||
cn6 = callPackage ./bsc/cn6/default.nix { };
|
||||
ovni = callPackage ./bsc/ovni/default.nix { };
|
||||
|
||||
# =================================================================
|
||||
# MN4 specific
|
||||
# =================================================================
|
||||
|
||||
osumb = callPackage ./bsc/osu/default.nix { };
|
||||
lmbench = callPackage ./bsc/lmbench/default.nix { };
|
||||
pmix2 = callPackage ./bsc/pmix/pmix2.nix { };
|
||||
slurm17 = callPackage ./bsc/slurm/default.nix {
|
||||
pmix = bsc.pmix2;
|
||||
};
|
||||
slurm17-libpmi2 = callPackage ./bsc/slurm/pmi2.nix {
|
||||
pmix = bsc.pmix2;
|
||||
};
|
||||
|
||||
pmix4 =
|
||||
let
|
||||
libevent-all = with final; symlinkJoin {
|
||||
name = "${libevent.name}-all";
|
||||
paths = [ libevent.dev libevent.out ];
|
||||
};
|
||||
in
|
||||
prev.pmix.overrideAttrs (old: rec {
|
||||
version = "4.2.3";
|
||||
# Don't use fetchFromGitHub as is not a release!
|
||||
src = builtins.fetchTarball {
|
||||
url = "https://github.com/openpmix/openpmix/releases/download/v${version}/pmix-${version}.tar.gz";
|
||||
sha256 = "sha256:1iakrjkgydjz2f17if4cpyk1ldjff2790x4z787zdbbdnisxhdz2";
|
||||
};
|
||||
configureFlags = [
|
||||
"--with-munge=${self.munge}"
|
||||
"--with-hwloc=${self.hwloc.dev}"
|
||||
];
|
||||
# libevent is not working, so use libev
|
||||
buildInputs = old.buildInputs ++ [ self.python3 libevent-all ];
|
||||
nativeBuildInputs = old.nativeBuildInputs ++ [ self.pkgconfig ];
|
||||
});
|
||||
|
||||
slurm-16-05-8-1 = callPackage ./bsc/slurm/16.05.8.1/default.nix {
|
||||
hwloc = bsc.hwloc-1-11-6;
|
||||
};
|
||||
|
||||
hwloc-1-11-6 = callPackage ./bsc/hwloc/1.11.6/default.nix {};
|
||||
|
||||
# Use a slurm compatible with MN4
|
||||
slurm = bsc.slurm17;
|
||||
# We need the unstable branch to get the fallocate problem fixed, as it is
|
||||
# not yet in stable nix, see:
|
||||
# https://pm.bsc.es/gitlab/rarias/bscpkgs/-/issues/83
|
||||
nix-mn4 = self.nixUnstable;
|
||||
# Our custom version that lacks the binaries. Disabled by default.
|
||||
#rdma-core = callPackage ./bsc/rdma-core/default.nix { };
|
||||
|
||||
# =================================================================
|
||||
# Patched from upstream
|
||||
# =================================================================
|
||||
|
||||
groff = callPackage ./bsc/groff/default.nix { };
|
||||
fftw = callPackage ./bsc/fftw/default.nix { };
|
||||
vtk = callPackage ./bsc/vtk/default.nix {
|
||||
inherit (self.xorg) libX11 xorgproto libXt;
|
||||
};
|
||||
|
||||
busybox = self.busybox.override {
|
||||
enableStatic = true;
|
||||
};
|
||||
|
||||
# =================================================================
|
||||
# Misc
|
||||
# =================================================================
|
||||
|
||||
dummy = callPackage ./bsc/dummy/default.nix { };
|
||||
mpptest = callPackage ./bsc/mpptest/default.nix { };
|
||||
cpuid = callPackage ./bsc/cpuid/default.nix { };
|
||||
bench6 = callPackage ./bsc/bench6/default.nix { };
|
||||
|
||||
nix-wrap = callPackage ./bsc/nix-wrap/default.nix { };
|
||||
|
||||
# =================================================================
|
||||
# Garlic benchmark
|
||||
# =================================================================
|
||||
|
||||
nixtools = callPackage ./bsc/nixtools/default.nix { };
|
||||
|
||||
garlicTools = callPackage ./garlic/tools.nix {};
|
||||
|
||||
# Aliases bsc.apps -> bsc.garlic.apps
|
||||
inherit (bsc.garlic) apps fig exp ds;
|
||||
|
||||
garlic = import ./garlic/index.nix {
|
||||
inherit self super bsc callPackage;
|
||||
};
|
||||
} "printf '%s\n' $buildInputs > $out";
|
||||
|
||||
test = rec {
|
||||
# hwloc = callPackage ./test/bugs/hwloc.nix { };
|
||||
sigsegv = callPackage ./test/reproducers/sigsegv.nix { };
|
||||
compilers.hello-c = callPackage ./test/compilers/hello-c.nix { };
|
||||
compilers.hello-cpp = callPackage ./test/compilers/hello-cpp.nix { };
|
||||
compilers.hello-f = callPackage ./test/compilers/hello-f.nix { };
|
||||
compilers.lto = callPackage ./test/compilers/lto.nix { };
|
||||
compilers.asan = callPackage ./test/compilers/asan.nix { };
|
||||
compilers.intel2023.icx.c = compilers.hello-c.override {
|
||||
stdenv = bsc.intel2023.stdenv;
|
||||
};
|
||||
compilers.intel2023.icc.c = compilers.hello-c.override {
|
||||
stdenv = bsc.intel2023.stdenv-icc;
|
||||
};
|
||||
compilers.intel2023.icx.cpp = compilers.hello-cpp.override {
|
||||
stdenv = bsc.intel2023.stdenv;
|
||||
};
|
||||
compilers.intel2023.icc.cpp = compilers.hello-cpp.override {
|
||||
stdenv = bsc.intel2023.stdenv-icc;
|
||||
};
|
||||
compilers.intel2023.ifort = compilers.hello-f.override {
|
||||
stdenv = bsc.intel2023.stdenv-ifort;
|
||||
};
|
||||
compilers.clangOmpss2.lto = compilers.lto.override {
|
||||
stdenv = bsc.stdenvClangOmpss2;
|
||||
};
|
||||
compilers.clangOmpss2.asan = compilers.asan.override {
|
||||
stdenv = bsc.stdenvClangOmpss2;
|
||||
};
|
||||
compilers.clangOmpss2.task = callPackage ./test/compilers/ompss2.nix {
|
||||
stdenv = bsc.stdenvClangOmpss2;
|
||||
};
|
||||
compilers.clangNodes.task = callPackage ./test/compilers/ompss2.nix {
|
||||
stdenv = bsc.stdenvClangNodes;
|
||||
hello-c = callPackage ./test/compilers/hello-c.nix { };
|
||||
hello-cpp = callPackage ./test/compilers/hello-cpp.nix { };
|
||||
hello-f = callPackage ./test/compilers/hello-f.nix { };
|
||||
lto = callPackage ./test/compilers/lto.nix { };
|
||||
asan = callPackage ./test/compilers/asan.nix { };
|
||||
#intel2023.icx.c = hello-c.override {
|
||||
# stdenv = bsc.intel2023.stdenv;
|
||||
#};
|
||||
#intel2023.icc.c = hello-c.override {
|
||||
# stdenv = bsc.intel2023.stdenv-icc;
|
||||
#};
|
||||
#intel2023.icx.cpp = hello-cpp.override {
|
||||
# stdenv = bsc.intel2023.stdenv;
|
||||
#};
|
||||
#intel2023.icc.cpp = hello-cpp.override {
|
||||
# stdenv = bsc.intel2023.stdenv-icc;
|
||||
#};
|
||||
#intel2023.ifort = hello-f.override {
|
||||
# stdenv = bsc.intel2023.stdenv-ifort;
|
||||
#};
|
||||
clangOmpss2.lto = lto.override { stdenv = self.stdenvClangOmpss2; };
|
||||
clangOmpss2.asan = asan.override { stdenv = self.stdenvClangOmpss2; };
|
||||
clangOmpss2.task = callPackage ./test/compilers/ompss2.nix {
|
||||
stdenv = self.stdenvClangOmpss2;
|
||||
};
|
||||
#clangNodes.task = callPackage ./test/compilers/ompss2.nix {
|
||||
# stdenv = bsc.stdenvClangNodes;
|
||||
#};
|
||||
};
|
||||
|
||||
testAll = with bsc.test; [
|
||||
compilers.intel2023.icx.c
|
||||
compilers.intel2023.icc.c
|
||||
compilers.intel2023.icx.cpp
|
||||
compilers.intel2023.icc.cpp
|
||||
compilers.intel2023.ifort
|
||||
compilers.clangOmpss2.lto
|
||||
compilers.clangOmpss2.task
|
||||
compilers.clangOmpss2.asan
|
||||
compilers.clangNodes.task
|
||||
];
|
||||
|
||||
ci = import ./test/ci.nix {
|
||||
inherit self super bsc callPackage;
|
||||
};
|
||||
});
|
||||
|
||||
in
|
||||
{
|
||||
bsc = _bsc;
|
||||
garlic = _bsc.garlic;
|
||||
|
||||
# Aliases apps -> bsc.garlic.apps
|
||||
inherit (_bsc.garlic) apps fig exp ds;
|
||||
}
|
||||
all = super.runCommand "ci-all" {
|
||||
buildInputs = with self.bsc-ci.test; [
|
||||
clangOmpss2.lto
|
||||
clangOmpss2.task
|
||||
clangOmpss2.asan
|
||||
];
|
||||
} "printf '%s\n' $buildInputs > $out";
|
||||
};
|
||||
}
|
||||
|
20
test/ci.nix
20
test/ci.nix
@ -1,4 +1,4 @@
|
||||
{ self, super, bsc, callPackage }:
|
||||
{ self, super, bsc, testPkgs }:
|
||||
|
||||
let
|
||||
stdenv = self.stdenv;
|
||||
@ -10,23 +10,7 @@ stdenv.mkDerivation rec {
|
||||
dontUnpack = true;
|
||||
|
||||
# Just build some packages
|
||||
buildInputs = with bsc; [
|
||||
# Compilers
|
||||
icc
|
||||
clangOmpss2
|
||||
mcxx
|
||||
# MPI
|
||||
impi
|
||||
mpich
|
||||
openmpi
|
||||
tampi
|
||||
# Tools
|
||||
ovni
|
||||
# extrae # Broken
|
||||
wxparaver
|
||||
# Runtimes
|
||||
nanos6
|
||||
] ++ bsc.testAll;
|
||||
buildInputs = testPkgs;
|
||||
|
||||
buildPhase = ''
|
||||
if [ -e /boot ]; then
|
||||
|
@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
|
||||
dontConfigure = true;
|
||||
hardeningDisable = [ "all" ];
|
||||
#NIX_DEBUG = 1;
|
||||
buildInputs = [ strace gdb ];
|
||||
buildInputs = [ ]; #strace gdb;
|
||||
# NODES requires access to /sys/devices to request NUMA information. It will
|
||||
# fail to run otherwise, so we disable the sandbox for this test.
|
||||
__noChroot = true;
|
||||
|
Loading…
Reference in New Issue
Block a user