paraver: add fast version for ordered traces

This commit is contained in:
Rodrigo Arias 2021-11-02 12:42:27 +01:00
parent 08aabfa657
commit c0362b6639
4 changed files with 138 additions and 0 deletions

View File

@ -0,0 +1,48 @@
{
stdenv
, autoreconfHook
, boost
, libxml2
, xml2
, wxpropgrid
, wxGTK28
, autoconf
, automake
}:
let
wx = wxGTK28;
in
stdenv.mkDerivation rec {
pname = "paraverKernelFast";
version = "${src.shortRev}";
src = builtins.fetchGit {
url = "git@bscpm03.bsc.es:rpenacob/paraver-kernel.git";
rev = "76f508095c35528ad89078473dc70b9600e507ff";
ref = "fast";
};
hardeningDisable = [ "all" ];
enableParallelBuilding = true;
dontStrip = true;
preConfigure = ''
export CFLAGS="-O3"
export CXXFLAGS="-std=c++17 -O3"
'';
configureFlags = [
"--with-boost=${boost}"
];
buildInputs = [
autoreconfHook
boost
libxml2.dev
xml2
autoconf
automake
];
}

View File

@ -0,0 +1,75 @@
{
stdenv
, autoreconfHook
, boost
, libxml2
, xml2
, wxpropgrid
, wxGTK28
, autoconf
, automake
, paraverKernelFast
, openssl
}:
let
wx = wxGTK28;
in
stdenv.mkDerivation rec {
pname = "paraverFast";
version = "${src.shortRev}";
src = builtins.fetchGit {
url = "https://github.com/bsc-performance-tools/wxparaver.git";
rev = "9fc61decb6d8d9b1cacb50639c3b2c85788b2292";
ref = "master";
};
hardeningDisable = [ "all" ];
patches = [ ./wxparaver-fast.patch ];
# Fix the PARAVER_HOME variable
postPatch = ''
sed -i 's@^PARAVER_HOME=.*$@PARAVER_HOME='$out'@g' docs/wxparaver
'';
dontStrip = true;
enableParallelBuilding = true;
preConfigure = ''
export CFLAGS="-O3"
export CXXFLAGS="-std=c++17 -O3"
'';
configureFlags = [
"--with-boost=${boost}"
"--with-wx-config=${wx}/bin/wx-config"
"--with-wxpropgrid-dir=${wxpropgrid}"
"--with-paraver=${paraverKernelFast}"
"--with-openssl=${openssl.dev}"
];
buildInputs = [
autoreconfHook
boost
libxml2.dev
xml2
wxpropgrid
wx
autoconf
automake
paraverKernelFast
openssl.dev
];
postInstall = ''
mkdir -p $out/include
mkdir -p $out/lib/paraver-kernel
mkdir -p $out/share/filters-config
cp -p ${paraverKernelFast}/bin/* $out/bin
# cp -p ${paraverKernelFast}/include/* $out/include
cp -a ${paraverKernelFast}/lib/paraver-kernel $out/lib/paraver-kernel
cp -p ${paraverKernelFast}/share/filters-config/* $out/share/filters-config
'';
}

View File

@ -0,0 +1,13 @@
--- a/docs/wxparaver 1970-01-01 01:00:01.000000000 +0100
+++ b/docs/wxparaver 2021-11-02 12:08:54.670700017 +0100
@@ -31,5 +31,10 @@
@inst_LOGIN_NODE_DETECTION@
+echo "WARNING: Using paraver fast, the trace must be ordered!" >&2
+export PARAVER_FAST=1
+
+export LANG=C
+
LD_LIBRARY_PATH="@inst_BOOST_LIBDIR@${PARAVER_HOME}/${LIB_DIR}/paraver-kernel:@inst_WXWIDGETS_LIBDIR@@inst_WXPROPGRID_LIB_PATH@@inst_LIBSSL_LIBDIR@${PARAVER_HOME}/${LIB_DIR}/wxparaver:$LD_LIBRARY_PATH" "${PARAVER_HOME}/bin/wxparaver.bin" "$@"

View File

@ -140,6 +140,8 @@ let
wxpropgrid = callPackage ./bsc/wxpropgrid/default.nix { };
paraver = callPackage ./bsc/paraver/default.nix { };
paraverKernelFast = callPackage ./bsc/paraver/kernel-fast.nix { };
paraverFast = callPackage ./bsc/paraver/wxparaver-fast.nix { };
paraverExtra = bsc.paraver.override { enableMouseLabel = true; };
paraverDebug = bsc.paraver.overrideAttrs (old: {
dontStrip = true;