Driver-level programming

From HP-SEE Wiki

Jump to: navigation, search

Myrinet Express (MX)

Contributed by IFIN-HH

The minimum requirement for using Myrinet cards is the installation of the MX-1.2.1 package, that contains the Myrinet module and a high-performance low-level message-passing software interface. This is provided by Myricom [myrc] in order to take advantage of the full power and performance of the Myrinet NIC. It implements IP over MX, emulating Ethernet with very low overhead, and an optimized API for software development.

MX can be used for the optimization of the parallel code on a Myrinet cluster, such as IFIN_Bio, by rewriting code that speeds up some essential time-consuming parts, such that some of the CPU load is transfered to the Myrinet card.

The MX API is similar to MPI, but it is working at the lower level of the driver. It can be even be used to create virtual network topologies better adapted to a specific code.

The library must be initialized at the beginning of the code using the mx_init() function, and terminated at the end with the mx_finalize(), as follows:

 #include "myriexpress.h"
 int main(void)
 {
 mx_return_t return_code;
 return_code = mx_init();
 ...
 return_code = mx_finalize();
 return 0;
 }

The full description of the MX functions is covered by the MX documentation at [mymx].

REFERENCES

[myrc] http://www.myricom.com [mymx] MX API manual, http://www.myri.org/scs/MX/doc/mx.pdf