ofiwg / libfabric

Open Fabric Interfaces
http://libfabric.org/
Other
581 stars 386 forks source link

Build Checks libfabric Coverity scan build status libfabric main branch AppVeyor CI status libfabric release version openssf scorecard

libfabric

libfabric, also known as Open Fabrics Interfaces (OFI), is a framework focused on exporting high-performance networking services to applications. It specifically targets parallel and distributed applications and middleware.

See the OFI website for more details, including a description and overview of the project, and detailed documentation of the libfabric APIs.

You can join the libfabric mailing lists from www.openfabrics.org (membership in the Open Fabrics Alliance is NOT required to join the mailing lists). libfabric discussions are also available on slack: libfabric.slack.com.

Installing pre-built libfabric packages

On OS X, the latest release of libfabric can be installed using the Homebrew package manager using the following command:

$ brew install libfabric

Libfabric pre-built binaries may be available from other sources, such as Linux distributions.

Building and installing libfabric from source

Distribution tarballs are available from the Github releases tab.

If you are building libfabric from a developer git clone, you must first run the autogen.sh script. This will invoke the GNU Autotools to bootstrap libfabric's configuration and build mechanisms. If you are building libfabric from an official distribution tarball, there is no need to run autogen.sh; libfabric distribution tarballs are already bootstrapped for you.

Libfabric currently supports GNU/Linux, Free BSD, and OS X.

Configure options

The configure script has many built-in options (see ./configure --help). Some useful options are:

--prefix=<directory>

By default make install will place the files in the /usr tree. The --prefix option specifies that libfabric files should be installed into the tree specified by named <directory>. The executables will be located at <directory>/bin.

--with-valgrind=<directory>

Directory where valgrind is installed. If valgrind is found, then valgrind annotations are enabled. This may incur a performance penalty.

--enable-debug

Enable debug code paths. This enables various extra checks and allows for using the highest verbosity logging output that is normally compiled out in production builds.

--enable-<provider>=[yes|no|auto|dl|<directory>]
--disable-<provider>

This enables or disables the provider named <provider>. Valid options are:

Examples

Consider the following example:

$ ./configure --prefix=/opt/libfabric --disable-sockets && make -j 32 && sudo make install

This will tell libfabric to disable the sockets provider, and install libfabric in the /opt/libfabric tree. All other providers will be enabled if possible and all debug features will be disabled.

Alternatively:

$ ./configure --prefix=/opt/libfabric --enable-debug --enable-psm3=dl && make -j 32 && sudo make install

This will tell libfabric to enable the psm3 provider as a loadable library, enable all debug code paths, and install libfabric to the /opt/libfabric tree. All other providers will be enabled if possible.

Validate installation

The fi_info utility can be used to validate the libfabric and provider installation and provide details about provider support and available interfaces. See fi_info(1) man page for details on using the fi_info utility. fi_info is installed as part of the libfabric package.

A more comprehensive test package is available via the fabtests package.

Providers

opx


The OPX provider is an updated Libfabric provider for Omni-Path HPC fabrics. The other provider for Omni-Path is PSM2.

The OPX provider began as a fork of the libfabric BGQ provider, with the hardware-specific parts re-written for the Omni-Path hfi1 fabric interface card. Therefore OPX inherits several desirable characteristics of the BGQ driver, and analysis of instruction counts and cache line footprints of most HPC operations show OPX being lighter weight than PSM2 on the host software stack, leading to better overall performance.

See the fi_opx(7) man page for more details. See Cornelis Customer Center for support information.

psm2


The psm2 provider runs over the PSM 2.x interface that is supported by the Intel Omni-Path Fabric. PSM 2.x has all the PSM 1.x features plus a set of new functions with enhanced capabilities. Since PSM 1.x and PSM 2.x are not ABI compatible, the psm2 provider only works with PSM 2.x and doesn't support Intel TrueScale Fabric.

See the fi_psm2(7) man page for more details.

psm3


The psm3 provider provides optimized performance and scalability for most verbs UD and sockets devices. Additional features and optimizations can be enabled when running over Intel's E810 Ethernet NICs and/or using Intel's rendezvous kernel module (rv). PSM 3.x fully integrates the OFI provider and the underlying PSM3 protocols/implementation and only exports the OFI APIs.

See fi_psm3(7) for more details.

rxm


The ofi_rxm provider is an utility provider that supports RDM endpoints emulated over MSG endpoints of a core provider.

See fi_rxm(7) for more information.

sockets


The sockets provider has been deprecated in favor of the tcp, udp, and utility providers, which provide improved performance and stability.

The sockets provider is a general-purpose provider that can be used on any system that supports TCP sockets. The provider is not intended to provide performance improvements over regular TCP sockets, but rather to allow developers to write, test, and debug application code even on platforms that do not have high-performance fabric hardware. The sockets provider supports all libfabric provider requirements and interfaces.

See the fi_sockets(7) man page for more details.

tcp


The tcp provider is an optimized socket based provider that supports reliable connected endpoints. The current version is the redesigned one previously called the net provider. This version supports both MSG endpoints and RDM endpoints. It can also work in conjunction with the rxm provider for apps that need similar RDM behavior as the old tcp provider. The tcp provider targets replacing the sockets provider for applications using standard networking hardware.

See the fi_tcp(7) man page for more details.

udp


The udp provider is a basic provider that can be used on any system that supports UDP sockets. The provider is not intended to provide performance improvements over regular UDP sockets, but rather allow applications and provider developers to write, test, and debug their code. The udp provider forms the foundation of a utility provider that enables the implementation of libfabric features over any hardware.

See the fi_udp(7) man page for more details.

usnic


The usnic provider is designed to run over the Cisco VIC (virtualized NIC) hardware on Cisco UCS servers. It utilizes the Cisco usnic (userspace NIC) capabilities of the VIC to enable ultra low latency and other offload capabilities on Ethernet networks.

See the fi_usnic(7) man page for more details.

Dependencies

Configure options

--with-libnl=<directory>

If specified, look for libnl support. If it is not found, the usnic provider will not be built. If <directory> is specified, then check in the directory and check for libnl version 3. If version 3 is not found, then check for version 1. If no <directory> argument is specified, then this option is redundant with --with-usnic.

verbs


The verbs provider enables applications using OFI to be run over any verbs hardware (Infiniband, iWarp, and RoCE). It uses the Linux Verbs API for network transport and translates OFI calls to appropriate verbs API calls. It uses librdmacm for communication management and libibverbs for other control and data transfer operations.

The verbs provider can also be built on Windows using the Microsoft Network Direct SPI for network transport.

See the fi_verbs(7) man page for more details.

Dependencies

shm


The shm provider enables applications using OFI to be run over shared memory.

See the fi_shm(7) man page for more details.

Dependencies

efa


The efa provider enables the use of libfabric-enabled applications on Amazon EC2 Elastic Fabric Adapter (EFA), a custom-built OS bypass hardware interface for inter-instance communication on EC2.

See fi_efa(7) for more information.

WINDOWS Instructions

It is possible to compile and link libfabric with windows applications.

cxi

The CXI provider enables libfabric on Cray's Slingshot network. Slingshot is comprised of the Rosetta switch and Cassini NIC. Slingshot is an Ethernet-compliant network. However, The provider takes advantage of proprietary extensions to support HPC applications.

The CXI provider supports reliable, connection-less endpoint semantics. It supports two-sided messaging interfaces with message matching offloaded by the Cassini NIC. It also supports one-sided RMA and AMO interfaces, light-weight counting events, triggered operations (via the deferred work API), and fabric-accelerated small reductions.

See the fi_cxi(7) man page for more details.

Dependencies