Installation of Nanos6¶
Nanos6 is a runtime that implements the OmpSs-2 parallel programming model, developed by the Programming Models group at the Barcelona Supercomputing Center.
Nanos6 can be obtained from the GitHub public repository or by contacting us at pm-tools@bsc.es.
Note
Although Nanos6 is still maintained, its development has stopped. We recommend installing the reference implementation of OmpSs-2 through the nOS-V and NODES runtimes instead.
Build requirements¶
To install Nanos6 the following tools and libraries must be installed:
Optional libraries and tools¶
In addition to the build requirements, the following libraries and tools enable additional features:
Extrae to generate execution traces for offline performance analysis with Paraver
CUDA to enable CUDA tasks
PGI or NVIDIA HPC-SDK to enable OpenACC tasks
PAPI to generate real-time statistics of hardware counters
PQOS to generate real-time statistics of hardware counters
DLB to enable dynamic management and sharing of computing resources
jemalloc to use jemalloc as the default memory allocator, providing better performance than the default glibc implementation. Jemalloc software must be compiled with
--enable-stats
and--with-jemalloc-prefix=nanos6_je_
to link with the runtimeovni (>= 1.5.0) to generate execution traces for performance analysis with Paraver
Build procedure¶
Nanos6 uses the standard GNU automake and libtool toolchain. When cloning from a repository, the building environment must be prepared through the command below. When the code is distributed through a tarball, it usually does not need that command.
$ ./autogen.sh
Note
The autogen.sh
script was recently introduced. Please use this script instead
of the autoreconf
command; otherwise the autotools configuration will fail.
Then execute the following commands:
$ ./configure --prefix=$INSTALLATION_PREFIX ...other options...
$ make
$ make install
where $INSTALLATION_PREFIX
is the directory into which to install Nanos6.
The configure script accepts the following options:
--with-nanos6-clang=prefix
to specify the prefix of the LLVM/Clang installation that supports OmpSs-2--with-nanos6-mercurium=prefix
to specify the prefix of the Mercurium installation--with-boost=prefix
to specify the prefix of the Boost installation--with-papi=prefix
to specify the prefix of the PAPI installation--with-libnuma=prefix
to specify the prefix of the numactl installation--with-extrae=prefix
to specify the prefix of the extrae installation--with-dlb=prefix
to specify the prefix of the DLB installation--with-papi=prefix
to specify the prefix of the PAPI installation--with-pqos=prefix
to specify the prefix of the PQoS installation--with-cuda[=prefix]
to enable support for CUDA tasks--enable-openacc
to enable support for OpenACC tasks; requires PGI compilers--with-pgi=prefix
to specify the prefix of the PGI compilers installation, in case they are not in$PATH
--enable-monitoring
to enable monitoring and predictions of task/CPU/thread statistics--enable-chrono-arch
to enable an architecture-based timer for the monitoring infrastructure--with-ovni=prefix
to specify the prefix of the ovni installation and enable the ovni instrumentation
The hwloc dependency is mandatory, and, by default, an internal hwloc is embedded to the Nanos6 library. This behavior can be modified through the –with-hwloc option, which can take the following values:
--with-hwloc=embedded
: The hwloc is built and embedded into the Nanos6 library as an internal module. This is useful when user programs may have third-party software (e.g., MPI libraries) that depend on a different hwloc version and may conflict with the one used by Nanos6. In this way, the hwloc library is internal and is only used by Nanos6. This is the default behavior if the option is not present, or no value is provided. See Embedding software dependencies for more information--with-hwloc=pkgconfig
: The hwloc is an external installation and Nanos6 should discover it through the pkg-config tool. Make sure to set thePKG_CONFIG_PATH
if the hwloc is not installed in non-standard directories--with-hwloc=<prefix>
: A prefix of an external hwloc installation
The jemalloc dependency is optional but highly recommended. This allocator
significantly improves the performance of the Nanos6 runtime by optimizing the
memory allocations. By default, an internal jemalloc is embedded to the Nanos6
library. This behavior can be modified through the --with-jemalloc
option,
which can take the following values:
--with-jemalloc=embedded
: The jemalloc is built and embedded into Nanos6 as an internal library. The building process installs the jemalloc headers and libraries in$INSTALLATION_PREFIX/deps/nanos6/jemalloc
and dynamically links our runtime against the jemalloc library. This is the default behavior if the option is not provided. See Embedding software dependencies for more information--with-jemalloc=<prefix>
: A prefix of an external jemalloc installation configured with the--enable-stats
and--with-jemalloc-prefix=nanos6_je_
options--with-jemalloc=no
or--without-jemalloc
: Disable the jemalloc allocator (not recommended)
The location of an external hwloc can be retrieved through pkg-config when specifying
--with-hwloc=pkgconfig
. If it is installed in a non-standard location, pkg-config
can be told where to find it through the PKG_CONFIG_PATH
environment variable. For
instance:
$ export PKG_CONFIG_PATH=/apps/HWLOC/2.0.0/INTEL/lib/pkgconfig:$PKG_CONFIG_PATH
The --with-cuda
flag is needed to enable CUDA tasks. The location of CUDA
can be retrieved automatically, if it is in standard system locations (/usr/lib
,
/usr/include
, etc), or through pkg-config. Alternatively, for non-standard
installation paths, it can be specified using the optional =prefix
of the
parameter.
The --enable-openacc
flag is needed to enable OpenACC tasks. The location of
PGI compilers can be retrieved from the $PATH
variable, if it is not specified
through the --with-pgi
parameter.
Optionally, if you passed any valid LLVM/Clang or Mercurium installation, you can execute the Nanos6 tests by running:
$ make check
Embedding software dependencies¶
As mentioned above, there are some software dependencies that may be embedded
into Nanos6. This is the case for hwloc and jemalloc, which will be embedded by
default. The sources of these embedded dependencies are taken from the deps
sub-directory in this repository. Inside the sub-directory, there is a default
hwloc and jemalloc source tarballs. These tarballs are automatically extracted
into deps/hwloc
and deps/jemalloc
by our autogen.sh
script.
These are the source packages that are then built when choosing --with-hwloc=embedded
or --with-jemalloc=embedded
. You may change the embedded software version by
placing the desired tarball inside the deps
folder and re-running autogen.sh
with the option --embed-<SOFTWARE> <VERSION>
. Currently, <SOFTWARE>
can be
hwloc
or jemalloc
and <VERSION>
should be the desired version number
of that software. For instance, a valid option could be:
./autogen.sh --embed-jemalloc 5.3.0
For the moment, the tarballs must follow the format deps/<SOFTWARE>-<VERSION>.tar.gz
.