hwloc  2.4.1
About: hwloc (Portable Hardware Locality) aims at helping applications with gathering information about modern computing hardware (including NUMA memory nodes, sockets, shared caches, cores and simultaneous multithreading) so as to exploit it accordingly and efficiently.
  Fossies Dox: hwloc-2.4.1.tar.bz2  ("unofficial" and yet experimental doxygen-generated source code documentation)  

hwloc Documentation

Some Fossies usage hints in advance:

  1. To see the Doxygen generated documentation please click on one of the items in the steelblue colored "quick index" bar above or use the side panel at the left which displays a hierarchical tree-like index structure and is adjustable in width.
  2. If you want to search for something by keyword rather than browse for it you can use the client side search facility (using Javascript and DHTML) that provides live searching, i.e. the search results are presented and adapted as you type in the Search input field at the top right.
  3. Doxygen doesn't incorporate all member files but just a definable subset (basically the main project source code files that are written in a supported language). So to search and browse all member files you may visit the Fossies hwloc-2.4.1.tar.bz2 contents page and use the Fossies standard member browsing features (also with source code highlighting and additionally with optional code folding).

The Hardware Locality (hwloc) software project aims at easing the process of
discovering hardware resources in parallel architectures. It offers
command-line tools and a C API for consulting these resources, their locality,
attributes, and interconnection. hwloc primarily aims at helping
high-performance computing (HPC) applications, but is also applicable to any
project seeking to exploit code and/or data locality on modern computing

hwloc is actually made of two subprojects distributed together:

  * The original hwloc project for describing the internals of computing nodes.
 It is described in details starting at section Hardware Locality (hwloc)
  * The network-oriented companion called netloc (Network Locality), described
 in details starting with section Network Locality (netloc).

See also the Related pages tab above for links to other sections.

Netloc may be disabled, but the original hwloc cannot. Both hwloc and netloc
APIs are documented after these sections.


hwloc (https://www.open-mpi.org/projects/hwloc/) is available under the BSD
license. It is hosted as a sub-project of the overall Open MPI project (https:/
/www.open-mpi.org/). Note that hwloc does not require any functionality from
Open MPI -- it is a wholly separate (and much smaller!) project and code base.
It just happens to be hosted as part of the overall Open MPI project.

Basic Installation

Installation is the fairly common GNU-based process:

shell$ ./configure --prefix=...
shell$ make
shell$ make install

hwloc- and netloc-specific configure options and requirements are documented in
sections hwloc Installation and Netloc Installation respectively.

Also note that if you install supplemental libraries in non-standard locations,
hwloc's configure script may not be able to find them without some help. You
may need to specify additional CPPFLAGS, LDFLAGS, or PKG_CONFIG_PATH values on
the configure command line.

For example, if libpciaccess was installed into /opt/pciaccess, hwloc's
configure script may not find it be default. Try adding PKG_CONFIG_PATH to the
./configure command line, like this:

./configure PKG_CONFIG_PATH=/opt/pciaccess/lib/pkgconfig ...

Running the "lstopo" tool is a good way to check as a graphical output whether
hwloc properly detected the architecture of your node. Netloc command-line
tools can be used to display the network topology interconnecting your nodes.

Installing from a Git clone

Additionally, the code can be directly cloned from Git:

shell$ git clone https://github.com/open-mpi/hwloc.git
shell$ cd hwloc
shell$ ./autogen.sh

Note that GNU Autoconf >=2.63, Automake >=1.11 and Libtool >=2.2.6 are required
when building from a Git clone.

Nightly development snapshots are available on the web site, they can be
configured and built without any need for Git or GNU Autotools.

Questions and Bugs

Bugs should be reported in the tracker (https://github.com/open-mpi/hwloc/
issues). Opening a new issue automatically displays lots of hints about how to
debug and report issues.

Questions may be sent to the users or developers mailing lists (https://

There is also a #hwloc IRC channel on Freenode (irc.freenode.net).

See https://www.open-mpi.org/projects/hwloc/doc/ for more hwloc documentation.