\hypertarget{btl_8h}{\section{ompi/mca/btl/btl.h File Reference}
\label{btl_8h}\index{ompi/mca/btl/btl.\+h@{ompi/mca/btl/btl.\+h}}
}


Byte Transfer Layer (B\+T\+L)  


{\ttfamily \#include \char`\"{}ompi\+\_\+config.\+h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}opal/mca/mca.\+h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}opal/class/opal\+\_\+bitmap.\+h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}opal/datatype/opal\+\_\+convertor.\+h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}opal/prefetch.\+h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}ompi/mca/mpool/mpool.\+h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}ompi/types.\+h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}opal/types.\+h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}opal/mca/crs/crs.\+h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}opal/mca/crs/base/base.\+h\char`\"{}}\\*
\subsection*{Data Structures}
\begin{DoxyCompactItemize}
\item 
struct \hyperlink{structmca__btl__base__segment__t}{mca\+\_\+btl\+\_\+base\+\_\+segment\+\_\+t}
\begin{DoxyCompactList}\small\item\em Describes a region/segment of memory that is addressable by an B\+T\+L. \end{DoxyCompactList}\item 
struct \hyperlink{structmca__btl__base__descriptor__t}{mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t}
\begin{DoxyCompactList}\small\item\em A descriptor that holds the parameters to a send/put/get operation along w/ a callback routine that is called on completion of the request. \end{DoxyCompactList}\item 
struct \hyperlink{structmca__btl__base__header__t}{mca\+\_\+btl\+\_\+base\+\_\+header\+\_\+t}
\item 
struct \hyperlink{structmca__btl__active__message__callback__t}{mca\+\_\+btl\+\_\+active\+\_\+message\+\_\+callback\+\_\+t}
\item 
struct \hyperlink{structmca__btl__base__component__2__0__0__t}{mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+2\+\_\+0\+\_\+0\+\_\+t}
\begin{DoxyCompactList}\small\item\em B\+T\+L component descriptor. \end{DoxyCompactList}\item 
struct \hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t}
\begin{DoxyCompactList}\small\item\em B\+T\+L module interface functions and attributes. \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Macros}
\begin{DoxyCompactItemize}
\item 
\hypertarget{btl_8h_a231fcaf924efeaa234f1e984a3fdf7eb}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+N\+O\+\_\+\+O\+R\+D\+E\+R}~255}\label{btl_8h_a231fcaf924efeaa234f1e984a3fdf7eb}

\item 
\hypertarget{btl_8h_a74782fa8dce04f3187ae5be49213343b}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+A\+M\+\_\+\+F\+R\+A\+M\+E\+W\+O\+R\+K\+\_\+\+M\+A\+S\+K}~0x\+D0}\label{btl_8h_a74782fa8dce04f3187ae5be49213343b}

\item 
\hypertarget{btl_8h_a873d78651b01641d0d84134636ec240d}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+T\+A\+G\+\_\+\+B\+T\+L}~0x20}\label{btl_8h_a873d78651b01641d0d84134636ec240d}

\item 
\hypertarget{btl_8h_a109b9e6689fc2371125b45cf294c2742}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+T\+A\+G\+\_\+\+F\+T}~0x30}\label{btl_8h_a109b9e6689fc2371125b45cf294c2742}

\item 
\hypertarget{btl_8h_a11c6fbd53901d38b1b9600a08ae57e05}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+T\+A\+G\+\_\+\+P\+M\+L}~0x40}\label{btl_8h_a11c6fbd53901d38b1b9600a08ae57e05}

\item 
\hypertarget{btl_8h_a13d4160668396f361602b0ec4a3e8f25}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+T\+A\+G\+\_\+\+O\+S\+C\+\_\+\+R\+D\+M\+A}~0x60}\label{btl_8h_a13d4160668396f361602b0ec4a3e8f25}

\item 
\hypertarget{btl_8h_ac6218a5b6927f5f2810e6b74164c6946}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+T\+A\+G\+\_\+\+U\+S\+R}~0x80}\label{btl_8h_ac6218a5b6927f5f2810e6b74164c6946}

\item 
\hypertarget{btl_8h_a2043624cd43f25b3507a309b644151fb}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+T\+A\+G\+\_\+\+M\+A\+X}~255 /$\ast$ 1 + highest allowed tag num $\ast$/}\label{btl_8h_a2043624cd43f25b3507a309b644151fb}

\item 
\hypertarget{btl_8h_a2a1b36b082369e08e8cb98edfdc0830c}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+T\+A\+G\+\_\+\+I\+B}~(M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+T\+A\+G\+\_\+\+B\+T\+L + 0)}\label{btl_8h_a2a1b36b082369e08e8cb98edfdc0830c}

\item 
\hypertarget{btl_8h_abe6088465aded6f063a0a44231541285}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+T\+A\+G\+\_\+\+U\+D\+A\+P\+L}~(M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+T\+A\+G\+\_\+\+B\+T\+L + 1)}\label{btl_8h_abe6088465aded6f063a0a44231541285}

\item 
\hypertarget{btl_8h_acc1156483f4d463d371741202053cb73}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+S\+E\+N\+D}~0x0001}\label{btl_8h_acc1156483f4d463d371741202053cb73}

\item 
\hypertarget{btl_8h_a0ae3e2f17d397da54caaa1cadb752b70}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+P\+U\+T}~0x0002}\label{btl_8h_a0ae3e2f17d397da54caaa1cadb752b70}

\item 
\hypertarget{btl_8h_accf5f9ab8bd6d011587797bb3963b8d7}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+G\+E\+T}~0x0004}\label{btl_8h_accf5f9ab8bd6d011587797bb3963b8d7}

\item 
\hypertarget{btl_8h_aa68b3f953c4d22f543ad442dfe3c76a2}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+R\+D\+M\+A}~(M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+G\+E\+T$\vert$M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+P\+U\+T)}\label{btl_8h_aa68b3f953c4d22f543ad442dfe3c76a2}

\item 
\hypertarget{btl_8h_aee02e37209a0ee38a21a0ea71a1a77cd}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+S\+E\+N\+D\+\_\+\+I\+N\+P\+L\+A\+C\+E}~0x0008}\label{btl_8h_aee02e37209a0ee38a21a0ea71a1a77cd}

\item 
\hypertarget{btl_8h_a3f7803d2aec0d97331a4e9bf653e27ae}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+N\+E\+E\+D\+\_\+\+A\+C\+K}~0x0010}\label{btl_8h_a3f7803d2aec0d97331a4e9bf653e27ae}

\item 
\hypertarget{btl_8h_aeaef271467e6adfcfa1bdbe397545a08}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+N\+E\+E\+D\+\_\+\+C\+S\+U\+M}~0x0020}\label{btl_8h_aeaef271467e6adfcfa1bdbe397545a08}

\item 
\#define \hyperlink{btl_8h_a24f87bd99087872806841972d02af911}{M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+R\+D\+M\+A\+\_\+\+M\+A\+T\+C\+H\+E\+D}~0x0040
\begin{DoxyCompactList}\small\item\em R\+D\+M\+A put/get calls must have a matching prepare\+\_\+\{src,dst\} call on the target with the same base (and possibly bound). \end{DoxyCompactList}\item 
\hypertarget{btl_8h_aa7bb008c7bde2041cc190c9e46fb1117}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+R\+D\+M\+A\+\_\+\+C\+O\+M\+P\+L\+E\+T\+I\+O\+N}~0x0080}\label{btl_8h_aa7bb008c7bde2041cc190c9e46fb1117}

\item 
\hypertarget{btl_8h_a572446dda24242f851f549cef9a28f70}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+H\+E\+T\+E\+R\+O\+G\+E\+N\+E\+O\+U\+S\+\_\+\+R\+D\+M\+A}~0x0100}\label{btl_8h_a572446dda24242f851f549cef9a28f70}

\item 
\hypertarget{btl_8h_aebef1c74fc0c6bb6d3a41f30d7ea3e03}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+F\+A\+I\+L\+O\+V\+E\+R\+\_\+\+S\+U\+P\+P\+O\+R\+T}~0x0200}\label{btl_8h_aebef1c74fc0c6bb6d3a41f30d7ea3e03}

\item 
\hypertarget{btl_8h_af56e26394975e7a914ff7095827a3afe}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+C\+U\+D\+A\+\_\+\+P\+U\+T}~0x0400}\label{btl_8h_af56e26394975e7a914ff7095827a3afe}

\item 
\hypertarget{btl_8h_aa3a923907bdb53753c0a90855c0b3bb5}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+C\+U\+D\+A\+\_\+\+G\+E\+T}~0x0800}\label{btl_8h_aa3a923907bdb53753c0a90855c0b3bb5}

\item 
\hypertarget{btl_8h_ab7311cdf7e594435752e0e54bbb2a058}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+C\+U\+D\+A\+\_\+\+R\+D\+M\+A}~(M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+C\+U\+D\+A\+\_\+\+G\+E\+T$\vert$M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+C\+U\+D\+A\+\_\+\+P\+U\+T)}\label{btl_8h_ab7311cdf7e594435752e0e54bbb2a058}

\item 
\hypertarget{btl_8h_afe7226f68534c36d4e60fb25c77e34c8}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+E\+X\+C\+L\+U\+S\+I\+V\+I\+T\+Y\+\_\+\+H\+I\+G\+H}~(64$\ast$1024) /$\ast$ internal loopback $\ast$/}\label{btl_8h_afe7226f68534c36d4e60fb25c77e34c8}

\item 
\hypertarget{btl_8h_a089878876596a8fa7661b55ad1099d9d}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+E\+X\+C\+L\+U\+S\+I\+V\+I\+T\+Y\+\_\+\+D\+E\+F\+A\+U\+L\+T}~1024      /$\ast$ G\+M/I\+B/etc. $\ast$/}\label{btl_8h_a089878876596a8fa7661b55ad1099d9d}

\item 
\hypertarget{btl_8h_a56878324928ed8163eaf22fa72c8ebd8}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+E\+X\+C\+L\+U\+S\+I\+V\+I\+T\+Y\+\_\+\+L\+O\+W}~0         /$\ast$ T\+C\+P used as a last resort $\ast$/}\label{btl_8h_a56878324928ed8163eaf22fa72c8ebd8}

\item 
\hypertarget{btl_8h_a640663fdbeb782402e864436642dd1cc}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+E\+R\+R\+O\+R\+\_\+\+F\+L\+A\+G\+S\+\_\+\+F\+A\+T\+A\+L}~0x1}\label{btl_8h_a640663fdbeb782402e864436642dd1cc}

\item 
\hypertarget{btl_8h_a65a4604dbbde9cd701b9d3ddd7c892f3}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+E\+R\+R\+O\+R\+\_\+\+F\+L\+A\+G\+S\+\_\+\+N\+O\+N\+F\+A\+T\+A\+L}~0x2}\label{btl_8h_a65a4604dbbde9cd701b9d3ddd7c892f3}

\item 
\hypertarget{btl_8h_a88efe065bf83fbed0f52a1e28a639abf}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+D\+E\+S\+\_\+\+F\+L\+A\+G\+S\+\_\+\+P\+R\+I\+O\+R\+I\+T\+Y}~0x0001}\label{btl_8h_a88efe065bf83fbed0f52a1e28a639abf}

\item 
\hypertarget{btl_8h_ad69fc62b2be5e6990a40565c8583eba9}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+D\+E\+S\+\_\+\+F\+L\+A\+G\+S\+\_\+\+B\+T\+L\+\_\+\+O\+W\+N\+E\+R\+S\+H\+I\+P}~0x0002}\label{btl_8h_ad69fc62b2be5e6990a40565c8583eba9}

\item 
\hypertarget{btl_8h_aad433e1b960bf3c6457255fbc660bb30}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+D\+E\+S\+\_\+\+S\+E\+N\+D\+\_\+\+A\+L\+W\+A\+Y\+S\+\_\+\+C\+A\+L\+L\+B\+A\+C\+K}~0x0004}\label{btl_8h_aad433e1b960bf3c6457255fbc660bb30}

\item 
\hypertarget{btl_8h_ae2cdbe811a233d0ec37631aa237b660c}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+D\+E\+S\+\_\+\+F\+L\+A\+G\+S\+\_\+\+P\+U\+T}~0x0010}\label{btl_8h_ae2cdbe811a233d0ec37631aa237b660c}

\item 
\hypertarget{btl_8h_abca4b532ce87349be82265280ef83a31}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+D\+E\+S\+\_\+\+F\+L\+A\+G\+S\+\_\+\+G\+E\+T}~0x0020}\label{btl_8h_abca4b532ce87349be82265280ef83a31}

\item 
\hypertarget{btl_8h_a7fce271b6d2f354917e4ffe3d9cff910}{\#define \hyperlink{btl_8h_a7fce271b6d2f354917e4ffe3d9cff910}{M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+D\+E\+S\+\_\+\+M\+A\+X\+\_\+\+S\+E\+G\+M\+E\+N\+T\+S}~16}\label{btl_8h_a7fce271b6d2f354917e4ffe3d9cff910}

\begin{DoxyCompactList}\small\item\em Maximum number of allowed segments in src/dst fields of a descriptor. \end{DoxyCompactList}\item 
\hypertarget{btl_8h_a3999878daca10d85963b69fbc32a56b0}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+B\+A\+S\+E\+\_\+\+H\+E\+A\+D\+E\+R\+\_\+\+H\+T\+O\+N}(hdr)}\label{btl_8h_a3999878daca10d85963b69fbc32a56b0}

\item 
\hypertarget{btl_8h_ac07070c52d63bcdbc7e0a929e712b863}{\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+B\+A\+S\+E\+\_\+\+H\+E\+A\+D\+E\+R\+\_\+\+N\+T\+O\+H}(hdr)}\label{btl_8h_ac07070c52d63bcdbc7e0a929e712b863}

\item 
\#define {\bfseries M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+B\+A\+S\+E\+\_\+\+V\+E\+R\+S\+I\+O\+N\+\_\+2\+\_\+0\+\_\+0}
\end{DoxyCompactItemize}
\subsection*{Typedefs}
\begin{DoxyCompactItemize}
\item 
\hypertarget{btl_8h_a153def461c44a8f80f28c82cd87fedb1}{typedef uint8\+\_\+t {\bfseries mca\+\_\+btl\+\_\+base\+\_\+tag\+\_\+t}}\label{btl_8h_a153def461c44a8f80f28c82cd87fedb1}

\item 
typedef void($\ast$ \hyperlink{btl_8h_a197dacf7e88d7dc13de19b9819960b18}{mca\+\_\+btl\+\_\+base\+\_\+completion\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$module, struct \hyperlink{structmca__btl__base__endpoint__t}{mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$endpoint, struct \hyperlink{structmca__btl__base__descriptor__t}{mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} $\ast$descriptor, int status)
\begin{DoxyCompactList}\small\item\em Asynchronous callback function on completion of an operation. \end{DoxyCompactList}\item 
\hypertarget{btl_8h_ac615f3f4dda61ae629026bda52cd71dc}{typedef struct \\*
\hyperlink{structmca__btl__base__segment__t}{mca\+\_\+btl\+\_\+base\+\_\+segment\+\_\+t} {\bfseries mca\+\_\+btl\+\_\+base\+\_\+segment\+\_\+t}}\label{btl_8h_ac615f3f4dda61ae629026bda52cd71dc}

\item 
\hypertarget{btl_8h_a69a1f7f1c1549f725c47aace4e3373ca}{typedef struct \\*
\hyperlink{structmca__btl__base__descriptor__t}{mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} {\bfseries mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t}}\label{btl_8h_a69a1f7f1c1549f725c47aace4e3373ca}

\item 
\hypertarget{btl_8h_aa59e011b82b0a37c409884110e33bdaf}{typedef struct \\*
\hyperlink{structmca__btl__base__header__t}{mca\+\_\+btl\+\_\+base\+\_\+header\+\_\+t} {\bfseries mca\+\_\+btl\+\_\+base\+\_\+header\+\_\+t}}\label{btl_8h_aa59e011b82b0a37c409884110e33bdaf}

\item 
typedef struct \\*
\hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$$\ast$($\ast$ \hyperlink{btl_8h_a652401b8fa4d6939cdbe1ac9d371cb79}{mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+init\+\_\+fn\+\_\+t} )(int $\ast$num\+\_\+btls, bool enable\+\_\+progress\+\_\+threads, bool enable\+\_\+mpi\+\_\+threads)
\begin{DoxyCompactList}\small\item\em M\+C\+A-\/$>$B\+T\+L Initializes the B\+T\+L component and creates specific B\+T\+L module(s). \end{DoxyCompactList}\item 
typedef int($\ast$ \hyperlink{btl_8h_a84cff85041ce4b291b96698b8b4d9008}{mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+progress\+\_\+fn\+\_\+t} )(void)
\begin{DoxyCompactList}\small\item\em M\+C\+A-\/$>$B\+T\+L Called to progress outstanding requests for non-\/threaded polling environments. \end{DoxyCompactList}\item 
typedef void($\ast$ \hyperlink{btl_8h_a6b39783709e482be956466e3a5847eff}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+recv\+\_\+cb\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, mca\+\_\+btl\+\_\+base\+\_\+tag\+\_\+t tag, \hyperlink{structmca__btl__base__descriptor__t}{mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} $\ast$descriptor, void $\ast$cbdata)
\begin{DoxyCompactList}\small\item\em Callback function that is called asynchronously on receipt of data by the transport layer. \end{DoxyCompactList}\item 
\hypertarget{btl_8h_a7d25b59b6ff9220df094ef1b2cb9a70a}{typedef struct \\*
\hyperlink{structmca__btl__active__message__callback__t}{mca\+\_\+btl\+\_\+active\+\_\+message\+\_\+callback\+\_\+t} {\bfseries mca\+\_\+btl\+\_\+active\+\_\+message\+\_\+callback\+\_\+t}}\label{btl_8h_a7d25b59b6ff9220df094ef1b2cb9a70a}

\item 
\hypertarget{btl_8h_adcfe54c4da170e2a5de56fe65e3edbb7}{typedef struct \\*
\hyperlink{structmca__btl__base__component__2__0__0__t}{mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+2\+\_\+0\+\_\+0\+\_\+t} {\bfseries mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+2\+\_\+0\+\_\+0\+\_\+t}}\label{btl_8h_adcfe54c4da170e2a5de56fe65e3edbb7}

\item 
\hypertarget{btl_8h_af89ecda895f721d900221d86c28f6f0e}{typedef struct \\*
\hyperlink{structmca__btl__base__component__2__0__0__t}{mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+2\+\_\+0\+\_\+0\+\_\+t} {\bfseries mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+t}}\label{btl_8h_af89ecda895f721d900221d86c28f6f0e}

\item 
\hypertarget{btl_8h_ace97e7ecb19fd1537e3b8bed34c71375}{typedef struct \\*
\hyperlink{structmca__btl__base__component__2__0__0__t}{mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+2\+\_\+0\+\_\+0\+\_\+t} {\bfseries mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+1\+\_\+0\+\_\+1\+\_\+t}}\label{btl_8h_ace97e7ecb19fd1537e3b8bed34c71375}

\item 
\hypertarget{btl_8h_a79ec8531c8770db197b20444c77c6402}{typedef struct \\*
\hyperlink{structmca__btl__base__component__2__0__0__t}{mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+2\+\_\+0\+\_\+0\+\_\+t} {\bfseries mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+1\+\_\+0\+\_\+0\+\_\+t}}\label{btl_8h_a79ec8531c8770db197b20444c77c6402}

\item 
typedef int($\ast$ \hyperlink{btl_8h_aba941e2a9712252b7b9010a2fce7ceda}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+finalize\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl)
\begin{DoxyCompactList}\small\item\em M\+C\+A-\/$>$B\+T\+L Clean up any resources held by B\+T\+L module before the module is unloaded. \end{DoxyCompactList}\item 
typedef int($\ast$ \hyperlink{btl_8h_a6d8cb1121f910e62336a0c0bb2150a3c}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+add\+\_\+procs\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, size\+\_\+t nprocs, struct \hyperlink{structompi__proc__t}{ompi\+\_\+proc\+\_\+t} $\ast$$\ast$procs, struct \hyperlink{structmca__btl__base__endpoint__t}{mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$$\ast$endpoints, struct \hyperlink{structopal__bitmap__t}{opal\+\_\+bitmap\+\_\+t} $\ast$reachable)
\begin{DoxyCompactList}\small\item\em B\+M\+L-\/$>$B\+T\+L notification of change in the process list. \end{DoxyCompactList}\item 
typedef int($\ast$ \hyperlink{btl_8h_add0747ed24ac5e6119ed2c6e36320b5f}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+del\+\_\+procs\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, size\+\_\+t nprocs, struct \hyperlink{structompi__proc__t}{ompi\+\_\+proc\+\_\+t} $\ast$$\ast$procs, struct \hyperlink{structmca__btl__base__endpoint__t}{mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$$\ast$peer)
\begin{DoxyCompactList}\small\item\em Notification of change to the process list. \end{DoxyCompactList}\item 
typedef int($\ast$ \hyperlink{btl_8h_ae05729c42406594aed526627cccad4ae}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+register\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, mca\+\_\+btl\+\_\+base\+\_\+tag\+\_\+t tag, \hyperlink{btl_8h_a6b39783709e482be956466e3a5847eff}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+recv\+\_\+cb\+\_\+fn\+\_\+t} cbfunc, void $\ast$cbdata)
\begin{DoxyCompactList}\small\item\em Register a callback function that is called on receipt of a fragment. \end{DoxyCompactList}\item 
typedef void($\ast$ \hyperlink{btl_8h_a3ed06ffadaf8a729d41091a671819d59}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+error\+\_\+cb\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, int32\+\_\+t flags, struct \hyperlink{structompi__proc__t}{ompi\+\_\+proc\+\_\+t} $\ast$errproc, char $\ast$btlinfo)
\begin{DoxyCompactList}\small\item\em Callback function that is called asynchronously on receipt of an error from the transport layer. \end{DoxyCompactList}\item 
typedef int($\ast$ \hyperlink{btl_8h_a0a44e6c722541e91e7d946f23fe4f135}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+register\+\_\+error\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, \hyperlink{btl_8h_a3ed06ffadaf8a729d41091a671819d59}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+error\+\_\+cb\+\_\+fn\+\_\+t} cbfunc)
\begin{DoxyCompactList}\small\item\em Register a callback function that is called on receipt of an error. \end{DoxyCompactList}\item 
typedef \\*
\hyperlink{structmca__btl__base__descriptor__t}{mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} $\ast$($\ast$ \hyperlink{btl_8h_a28c3dd78fbd254efb5805b242d8c36bb}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+alloc\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, struct \hyperlink{structmca__btl__base__endpoint__t}{mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$endpoint, uint8\+\_\+t order, size\+\_\+t size, uint32\+\_\+t flags)
\begin{DoxyCompactList}\small\item\em Allocate a descriptor with a segment of the requested size. \end{DoxyCompactList}\item 
typedef int($\ast$ \hyperlink{btl_8h_aff0a7ac49cdbab8b5db747aa2537629d}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+free\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, \hyperlink{structmca__btl__base__descriptor__t}{mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} $\ast$descriptor)
\begin{DoxyCompactList}\small\item\em Return a descriptor allocated from this B\+T\+L via alloc/prepare. \end{DoxyCompactList}\item 
typedef struct \\*
\hyperlink{structmca__btl__base__descriptor__t}{mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} $\ast$($\ast$ \hyperlink{btl_8h_afc7f235e9e15d48929d2b9b79e382022}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+prepare\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, struct \hyperlink{structmca__btl__base__endpoint__t}{mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$endpoint, \hyperlink{structmca__mpool__base__registration__t}{mca\+\_\+mpool\+\_\+base\+\_\+registration\+\_\+t} $\ast$registration, struct \hyperlink{structopal__convertor__t}{opal\+\_\+convertor\+\_\+t} $\ast$convertor, uint8\+\_\+t order, size\+\_\+t reserve, size\+\_\+t $\ast$size, uint32\+\_\+t flags)
\begin{DoxyCompactList}\small\item\em Prepare a descriptor for send/put/get using the supplied convertor. \end{DoxyCompactList}\item 
typedef int($\ast$ \hyperlink{btl_8h_a1ea008e4d1733998a83032d8c392f0e3}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+send\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, struct \hyperlink{structmca__btl__base__endpoint__t}{mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$endpoint, struct \hyperlink{structmca__btl__base__descriptor__t}{mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} $\ast$descriptor, mca\+\_\+btl\+\_\+base\+\_\+tag\+\_\+t tag)
\begin{DoxyCompactList}\small\item\em Initiate an asynchronous send. \end{DoxyCompactList}\item 
typedef int($\ast$ \hyperlink{btl_8h_a7ab217077e81c7a35c3524ab91a199f9}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+sendi\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, struct \hyperlink{structmca__btl__base__endpoint__t}{mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$endpoint, struct \hyperlink{structopal__convertor__t}{opal\+\_\+convertor\+\_\+t} $\ast$convertor, void $\ast$header, size\+\_\+t header\+\_\+size, size\+\_\+t payload\+\_\+size, uint8\+\_\+t order, uint32\+\_\+t flags, mca\+\_\+btl\+\_\+base\+\_\+tag\+\_\+t tag, \hyperlink{structmca__btl__base__descriptor__t}{mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} $\ast$$\ast$descriptor)
\begin{DoxyCompactList}\small\item\em Initiate an immediate blocking send. \end{DoxyCompactList}\item 
typedef int($\ast$ \hyperlink{btl_8h_a208be2d3632a2fb234e05889e19a870d}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+put\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, struct \hyperlink{structmca__btl__base__endpoint__t}{mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$endpoint, struct \hyperlink{structmca__btl__base__descriptor__t}{mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} $\ast$descriptor)
\begin{DoxyCompactList}\small\item\em Initiate an asynchronous put. \end{DoxyCompactList}\item 
typedef int($\ast$ \hyperlink{btl_8h_a71f73209e00308db469930dda24a69f3}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+get\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, struct \hyperlink{structmca__btl__base__endpoint__t}{mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$endpoint, struct \hyperlink{structmca__btl__base__descriptor__t}{mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} $\ast$descriptor)
\begin{DoxyCompactList}\small\item\em Initiate an asynchronous get. \end{DoxyCompactList}\item 
typedef void($\ast$ \hyperlink{btl_8h_abe428476958712b2baa7f366c078d290}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+dump\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, struct \hyperlink{structmca__btl__base__endpoint__t}{mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$endpoint, int verbose)
\begin{DoxyCompactList}\small\item\em Diagnostic dump of btl state. \end{DoxyCompactList}\item 
typedef int($\ast$ \hyperlink{btl_8h_aacee18187984a0f86a7aba1fe64b4003}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+ft\+\_\+event\+\_\+fn\+\_\+t} )(int state)
\begin{DoxyCompactList}\small\item\em Fault Tolerance Event Notification \hyperlink{structFunction}{Function}. \end{DoxyCompactList}\item 
\hypertarget{btl_8h_a6d8039c06c7c4eee312d7ef078d49495}{typedef struct \\*
\hyperlink{structmca__btl__base__module__t}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} {\bfseries mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t}}\label{btl_8h_a6d8039c06c7c4eee312d7ef078d49495}

\end{DoxyCompactItemize}
\subsection*{Functions}
\begin{DoxyCompactItemize}
\item 
\hypertarget{btl_8h_a5fd5df48ef40cd05b0ed9989043dc951}{O\+M\+P\+I\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C {\bfseries O\+B\+J\+\_\+\+C\+L\+A\+S\+S\+\_\+\+D\+E\+C\+L\+A\+R\+A\+T\+I\+O\+N} (\hyperlink{structmca__btl__base__descriptor__t}{mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t})}\label{btl_8h_a5fd5df48ef40cd05b0ed9989043dc951}

\end{DoxyCompactItemize}
\subsection*{Variables}
\begin{DoxyCompactItemize}
\item 
\hypertarget{btl_8h_abe74a55c403f058979383364c72da79c}{O\+M\+P\+I\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C \\*
\hyperlink{structmca__btl__active__message__callback__t}{mca\+\_\+btl\+\_\+active\+\_\+message\+\_\+callback\+\_\+t} {\bfseries mca\+\_\+btl\+\_\+base\+\_\+active\+\_\+message\+\_\+trigger} \mbox{[}M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+T\+A\+G\+\_\+\+M\+A\+X\mbox{]}}\label{btl_8h_abe74a55c403f058979383364c72da79c}

\end{DoxyCompactItemize}


\subsection{Detailed Description}
Byte Transfer Layer (B\+T\+L) 

B\+T\+L Initialization\+:

During library initialization, all available B\+T\+L components are loaded and opened via their mca\+\_\+base\+\_\+open\+\_\+component\+\_\+fn\+\_\+t function. The B\+T\+L open function should register any mca parameters used to tune/adjust the behaviour of the B\+T\+L (\hyperlink{mca__base__param_8h_a66fd2603b63658f054f7a6a54891c0c2}{mca\+\_\+base\+\_\+param\+\_\+register\+\_\+int()}, \hyperlink{mca__base__param_8h_a475d552a8bfa1f2690d9b5add80cda31}{mca\+\_\+base\+\_\+param\+\_\+register\+\_\+string()}). Note that the open function may fail if the resources (e.\+g. shared libraries, etc) required by the network transport are not available.

The \hyperlink{btl_8h_a652401b8fa4d6939cdbe1ac9d371cb79}{mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+init\+\_\+fn\+\_\+t()} is then called for each of the components that are succesfully opened. The component init function may return either\+:

(1) a N\+U\+L\+L list of B\+T\+L modules if the transport is not available, (2) a list containing a one or more single B\+T\+L modules, where the B\+T\+L provides a layer of abstraction over one or more physical devices (e.\+g. N\+I\+Cs),

During module initialization, the module should post any addressing information required by its peers. An example would be the T\+C\+P listen port opened by the T\+C\+P module for incoming connection requests. This information is published to peers via the \hyperlink{ompi__module__exchange_8h_a2b9a27750560e4fc316a31514a1da589}{ompi\+\_\+modex\+\_\+send()} interface. Note that peer information is not guaranteed to be available via \hyperlink{ompi__module__exchange_8h_a359e0023ca30f1604e9af688bcc2033b}{ompi\+\_\+modex\+\_\+recv()} during the module's init function. However, it will be available during B\+T\+L selection (mca\+\_\+btl\+\_\+base\+\_\+add\+\_\+proc\+\_\+fn\+\_\+t()).

B\+T\+L Selection\+:

The upper layer builds an ordered list of the available B\+T\+L modules sorted by their exclusivity ranking. This is a relative ranking that is used to determine the set of B\+T\+Ls that may be used to reach a given destination. During startup the B\+T\+L modules are queried via their mca\+\_\+btl\+\_\+base\+\_\+add\+\_\+proc\+\_\+fn\+\_\+t() to determine if they are able to reach a given destination. The B\+T\+L module with the highest ranking that returns success is selected. Subsequent B\+T\+L modules are selected only if they have the same exclusivity ranking.

An example of how this might be used\+:

B\+T\+L Exclusivity Comments 

 L\+O 100 Selected exclusively for local process S\+M 50 Selected exclusively for other processes on host I\+B 0 Selected based on network reachability I\+B 0 Selected based on network reachability T\+C\+P 0 Selected based on network reachability T\+C\+P 0 Selected based on network reachability

When mca\+\_\+btl\+\_\+base\+\_\+add\+\_\+proc\+\_\+fn\+\_\+t() is called on a B\+T\+L module, the B\+T\+L will populate an O\+U\+T variable with \hyperlink{structmca__btl__base__endpoint__t}{mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} pointers. Each pointer is treated as an opaque handle by the upper layer and is returned to the B\+T\+L on subsequent data transfer calls to the corresponding destination process. The actual contents of the data structure are defined on a per B\+T\+L basis, and may be used to cache addressing or connection information, such as a T\+C\+P socket or I\+B queue pair.

\hyperlink{structProgress}{Progress}\+:

By default, the library provides for polling based progress of outstanding requests. The B\+T\+L component exports an interface function (btl\+\_\+progress) that is called in a polling mode by the P\+M\+L during calls into the M\+P\+I library. Note that the btl\+\_\+progress() function is called on the B\+T\+L component rather than each B\+T\+L module. This implies that the B\+T\+L author is responsible for iterating over the pending operations in each of the B\+T\+L modules associated with the component.

On platforms where threading support is provided, the library provides the option of building with asynchronous threaded progress. In this case, the B\+T\+L author is responsible for providing a thread to progress pending operations. A thread is associated with the B\+T\+L component/module such that transport specific functionality/\+A\+P\+Is may be used to block the thread until a pending operation completes. This thread M\+U\+S\+T N\+O\+T poll for completion as this would oversubscribe the C\+P\+U.

Note that in the threaded case the P\+M\+L may choose to use a hybrid approach, such that polling is implemented from the user thread for a fixed number of cycles before relying on the background thread(s) to complete requests. If possible the B\+T\+L should support the use of both modes concurrently. 

\subsection{Macro Definition Documentation}
\hypertarget{btl_8h_a730e487942cba6c70ba6e0eefc0abaae}{\index{btl.\+h@{btl.\+h}!M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+B\+A\+S\+E\+\_\+\+V\+E\+R\+S\+I\+O\+N\+\_\+2\+\_\+0\+\_\+0@{M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+B\+A\+S\+E\+\_\+\+V\+E\+R\+S\+I\+O\+N\+\_\+2\+\_\+0\+\_\+0}}
\index{M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+B\+A\+S\+E\+\_\+\+V\+E\+R\+S\+I\+O\+N\+\_\+2\+\_\+0\+\_\+0@{M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+B\+A\+S\+E\+\_\+\+V\+E\+R\+S\+I\+O\+N\+\_\+2\+\_\+0\+\_\+0}!btl.\+h@{btl.\+h}}
\subsubsection[{M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+B\+A\+S\+E\+\_\+\+V\+E\+R\+S\+I\+O\+N\+\_\+2\+\_\+0\+\_\+0}]{\setlength{\rightskip}{0pt plus 5cm}\#define M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+B\+A\+S\+E\+\_\+\+V\+E\+R\+S\+I\+O\+N\+\_\+2\+\_\+0\+\_\+0}}\label{btl_8h_a730e487942cba6c70ba6e0eefc0abaae}
{\bfseries Value\+:}
\begin{DoxyCode}
MCA\_BASE\_VERSION\_2\_0\_0, \(\backslash\)
  \textcolor{stringliteral}{"btl"}, 2, 0, 0
\end{DoxyCode}
\hypertarget{btl_8h_a24f87bd99087872806841972d02af911}{\index{btl.\+h@{btl.\+h}!M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+R\+D\+M\+A\+\_\+\+M\+A\+T\+C\+H\+E\+D@{M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+R\+D\+M\+A\+\_\+\+M\+A\+T\+C\+H\+E\+D}}
\index{M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+R\+D\+M\+A\+\_\+\+M\+A\+T\+C\+H\+E\+D@{M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+R\+D\+M\+A\+\_\+\+M\+A\+T\+C\+H\+E\+D}!btl.\+h@{btl.\+h}}
\subsubsection[{M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+R\+D\+M\+A\+\_\+\+M\+A\+T\+C\+H\+E\+D}]{\setlength{\rightskip}{0pt plus 5cm}\#define M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+R\+D\+M\+A\+\_\+\+M\+A\+T\+C\+H\+E\+D~0x0040}}\label{btl_8h_a24f87bd99087872806841972d02af911}


R\+D\+M\+A put/get calls must have a matching prepare\+\_\+\{src,dst\} call on the target with the same base (and possibly bound). 



\subsection{Typedef Documentation}
\hypertarget{btl_8h_a197dacf7e88d7dc13de19b9819960b18}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+completion\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+completion\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+completion\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+completion\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+completion\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef void($\ast$ mca\+\_\+btl\+\_\+base\+\_\+completion\+\_\+fn\+\_\+t)(struct {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$module, struct {\bf mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$endpoint, struct {\bf mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} $\ast$descriptor, int status)}}\label{btl_8h_a197dacf7e88d7dc13de19b9819960b18}


Asynchronous callback function on completion of an operation. 

Completion Semantics\+: The descriptor can be reused or returned to the B\+T\+L via mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+free\+\_\+fn\+\_\+t. The operation has been queued to the network device or will otherwise make asynchronous progress without subsequent calls to btl\+\_\+progress.


\begin{DoxyParams}{Parameters}
{\em I\+N\mbox{]}} & module the B\+T\+L module \\
\hline
{\em I\+N\mbox{]}} & endpoint the B\+T\+L endpoint \\
\hline
{\em I\+N\mbox{]}} & descriptor the B\+T\+L descriptor \\
\hline
\end{DoxyParams}
\hypertarget{btl_8h_a652401b8fa4d6939cdbe1ac9d371cb79}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+init\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+init\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+init\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+init\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+init\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef struct {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t}$\ast$$\ast$($\ast$ mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+init\+\_\+fn\+\_\+t)(int $\ast$num\+\_\+btls, bool enable\+\_\+progress\+\_\+threads, bool enable\+\_\+mpi\+\_\+threads)}}\label{btl_8h_a652401b8fa4d6939cdbe1ac9d371cb79}


M\+C\+A-\/$>$B\+T\+L Initializes the B\+T\+L component and creates specific B\+T\+L module(s). 


\begin{DoxyParams}{Parameters}
{\em num\+\_\+btls} & (O\+U\+T) Returns the number of btl modules created, or 0 if the transport is not available.\\
\hline
{\em enable\+\_\+progress\+\_\+threads} & (I\+N) Whether this component is allowed to run a hidden/progress thread or not.\\
\hline
{\em enable\+\_\+mpi\+\_\+threads} & (I\+N) Whether support for multiple M\+P\+I threads is enabled or not (i.\+e., M\+P\+I\+\_\+\+T\+H\+R\+E\+A\+D\+\_\+\+M\+U\+L\+T\+I\+P\+L\+E), which indicates whether multiple threads may invoke this component simultaneously or not.\\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
Array of pointers to B\+T\+L modules, or N\+U\+L\+L if the transport is not available.
\end{DoxyReturn}
During component initialization, the B\+T\+L component should discover the physical devices that are available for the given transport, and create a B\+T\+L module to represent each device. Any addressing information required by peers to reach the device should be published during this function via the \hyperlink{ompi__module__exchange_8h_a2b9a27750560e4fc316a31514a1da589}{ompi\+\_\+modex\+\_\+send()} interface. \hypertarget{btl_8h_a84cff85041ce4b291b96698b8b4d9008}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+progress\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+progress\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+progress\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+progress\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+progress\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef int($\ast$ mca\+\_\+btl\+\_\+base\+\_\+component\+\_\+progress\+\_\+fn\+\_\+t)(void)}}\label{btl_8h_a84cff85041ce4b291b96698b8b4d9008}


M\+C\+A-\/$>$B\+T\+L Called to progress outstanding requests for non-\/threaded polling environments. 

\begin{DoxyReturn}{Returns}
Count of \char`\"{}completions\char`\"{}, a metric of how many items where completed in the call to progress. 
\end{DoxyReturn}
\hypertarget{btl_8h_a6d8cb1121f910e62336a0c0bb2150a3c}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+add\+\_\+procs\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+add\+\_\+procs\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+add\+\_\+procs\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+add\+\_\+procs\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+add\+\_\+procs\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef int($\ast$ mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+add\+\_\+procs\+\_\+fn\+\_\+t)(struct {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, size\+\_\+t nprocs, struct {\bf ompi\+\_\+proc\+\_\+t} $\ast$$\ast$procs, struct {\bf mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$$\ast$endpoints, struct {\bf opal\+\_\+bitmap\+\_\+t} $\ast$reachable)}}\label{btl_8h_a6d8cb1121f910e62336a0c0bb2150a3c}


B\+M\+L-\/$>$B\+T\+L notification of change in the process list. 


\begin{DoxyParams}{Parameters}
{\em btl} & (I\+N) B\+T\+L module \\
\hline
{\em nprocs} & (I\+N) Number of processes \\
\hline
{\em procs} & (I\+N) Array of processes \\
\hline
{\em endpoint} & (O\+U\+T) Array of \hyperlink{structmca__btl__base__endpoint__t}{mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} structures by B\+T\+L. \\
\hline
{\em reachable} & (O\+U\+T) Bitmask indicating set of peer processes that are reachable by this B\+T\+L. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
O\+M\+P\+I\+\_\+\+S\+U\+C\+C\+E\+S\+S or error status on failure.
\end{DoxyReturn}
The \hyperlink{btl_8h_a6d8cb1121f910e62336a0c0bb2150a3c}{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+add\+\_\+procs\+\_\+fn\+\_\+t()} is called by the B\+M\+L to determine the set of B\+T\+Ls that should be used to reach each process. Any addressing information exported by the peer via the \hyperlink{ompi__module__exchange_8h_a2b9a27750560e4fc316a31514a1da589}{ompi\+\_\+modex\+\_\+send()} function should be available during this call via the corresponding \hyperlink{ompi__module__exchange_8h_a359e0023ca30f1604e9af688bcc2033b}{ompi\+\_\+modex\+\_\+recv()} function. The B\+T\+L may utilize this information to determine reachability of each peer process.

For each process that is reachable by the B\+T\+L, the bit corresponding to the index into the proc array (nprocs) should be set in the reachable bitmask. The B\+T\+L will return an array of pointers to a data structure defined by the B\+T\+L that is then returned to the B\+T\+L on subsequent calls to the B\+T\+L data transfer functions (e.\+g btl\+\_\+send). This may be used by the B\+T\+L to cache any addressing or connection information (e.\+g. T\+C\+P socket, I\+B queue pair). \hypertarget{btl_8h_a28c3dd78fbd254efb5805b242d8c36bb}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+alloc\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+alloc\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+alloc\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+alloc\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+alloc\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef {\bf mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t}$\ast$($\ast$ mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+alloc\+\_\+fn\+\_\+t)(struct {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, struct {\bf mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$endpoint, uint8\+\_\+t order, size\+\_\+t size, uint32\+\_\+t flags)}}\label{btl_8h_a28c3dd78fbd254efb5805b242d8c36bb}


Allocate a descriptor with a segment of the requested size. 

Note that the B\+T\+L layer may choose to return a smaller size if it cannot support the request. The order tag value ensures that operations on the descriptor that is allocated will be ordered w.\+r.\+t. a previous operation on a particular descriptor. Ordering is only guaranteed if the previous descriptor had its local completion callback function called and the order tag of that descriptor is only valid upon the local completion callback function.


\begin{DoxyParams}{Parameters}
{\em btl} & (I\+N) B\+T\+L module \\
\hline
{\em size} & (I\+N) \hyperlink{classRequest}{Request} segment size. \\
\hline
{\em order} & (I\+N) The ordering tag (may be M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+N\+O\+\_\+\+O\+R\+D\+E\+R) \\
\hline
\end{DoxyParams}
\hypertarget{btl_8h_add0747ed24ac5e6119ed2c6e36320b5f}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+del\+\_\+procs\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+del\+\_\+procs\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+del\+\_\+procs\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+del\+\_\+procs\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+del\+\_\+procs\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef int($\ast$ mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+del\+\_\+procs\+\_\+fn\+\_\+t)(struct {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, size\+\_\+t nprocs, struct {\bf ompi\+\_\+proc\+\_\+t} $\ast$$\ast$procs, struct {\bf mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$$\ast$peer)}}\label{btl_8h_add0747ed24ac5e6119ed2c6e36320b5f}


Notification of change to the process list. 


\begin{DoxyParams}{Parameters}
{\em btl} & (I\+N) B\+T\+L module \\
\hline
{\em nprocs} & (I\+N) Number of processes \\
\hline
{\em proc} & (I\+N) Set of processes \\
\hline
{\em peer} & (I\+N) Set of peer addressing information. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
\hyperlink{classStatus}{Status} indicating if cleanup was successful
\end{DoxyReturn}
When the process list changes, the B\+M\+L notifies the B\+T\+L of the change, to provide the opportunity to cleanup or release any resources associated with the peer. \hypertarget{btl_8h_abe428476958712b2baa7f366c078d290}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+dump\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+dump\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+dump\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+dump\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+dump\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef void($\ast$ mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+dump\+\_\+fn\+\_\+t)(struct {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, struct {\bf mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$endpoint, int verbose)}}\label{btl_8h_abe428476958712b2baa7f366c078d290}


Diagnostic dump of btl state. 


\begin{DoxyParams}{Parameters}
{\em btl} & (I\+N) B\+T\+L module \\
\hline
{\em endpoint} & (I\+N) B\+T\+L endpoint \\
\hline
{\em verbose} & (I\+N) Verbosity level \\
\hline
\end{DoxyParams}
\hypertarget{btl_8h_a3ed06ffadaf8a729d41091a671819d59}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+error\+\_\+cb\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+error\+\_\+cb\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+error\+\_\+cb\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+error\+\_\+cb\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+error\+\_\+cb\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef void($\ast$ mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+error\+\_\+cb\+\_\+fn\+\_\+t)(struct {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, int32\+\_\+t flags, struct {\bf ompi\+\_\+proc\+\_\+t} $\ast$errproc, char $\ast$btlinfo)}}\label{btl_8h_a3ed06ffadaf8a729d41091a671819d59}


Callback function that is called asynchronously on receipt of an error from the transport layer. 


\begin{DoxyParams}{Parameters}
{\em I\+N\mbox{]}} & btl B\+T\+L module \\
\hline
{\em I\+N\mbox{]}} & flags type of error \\
\hline
{\em I\+N\mbox{]}} & errproc process that had an error \\
\hline
{\em I\+N\mbox{]}} & btlinfo descriptive string from the B\+T\+L \\
\hline
\end{DoxyParams}
\hypertarget{btl_8h_aba941e2a9712252b7b9010a2fce7ceda}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+finalize\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+finalize\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+finalize\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+finalize\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+finalize\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef int($\ast$ mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+finalize\+\_\+fn\+\_\+t)(struct {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl)}}\label{btl_8h_aba941e2a9712252b7b9010a2fce7ceda}


M\+C\+A-\/$>$B\+T\+L Clean up any resources held by B\+T\+L module before the module is unloaded. 


\begin{DoxyParams}{Parameters}
{\em btl} & (I\+N) B\+T\+L module. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
O\+M\+P\+I\+\_\+\+S\+U\+C\+C\+E\+S\+S or error status on failure.
\end{DoxyReturn}
Prior to unloading a B\+T\+L module, the M\+C\+A framework will call the B\+T\+L finalize method of the module. Any resources held by the B\+T\+L should be released and if required the memory corresponding to the B\+T\+L module freed. \hypertarget{btl_8h_aff0a7ac49cdbab8b5db747aa2537629d}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+free\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+free\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+free\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+free\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+free\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef int($\ast$ mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+free\+\_\+fn\+\_\+t)(struct {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, {\bf mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} $\ast$descriptor)}}\label{btl_8h_aff0a7ac49cdbab8b5db747aa2537629d}


Return a descriptor allocated from this B\+T\+L via alloc/prepare. 

A descriptor can only be deallocated after its local completion callback function has called for all send/put/get operations.


\begin{DoxyParams}{Parameters}
{\em btl} & (I\+N) B\+T\+L module \\
\hline
{\em segment} & (I\+N) Descriptor allocated from the B\+T\+L \\
\hline
\end{DoxyParams}
\hypertarget{btl_8h_aacee18187984a0f86a7aba1fe64b4003}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+ft\+\_\+event\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+ft\+\_\+event\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+ft\+\_\+event\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+ft\+\_\+event\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+ft\+\_\+event\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef int($\ast$ mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+ft\+\_\+event\+\_\+fn\+\_\+t)(int state)}}\label{btl_8h_aacee18187984a0f86a7aba1fe64b4003}


Fault Tolerance Event Notification \hyperlink{structFunction}{Function}. 


\begin{DoxyParams}{Parameters}
{\em state} & Checkpoint \hyperlink{classStatus}{Status} \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
O\+M\+P\+I\+\_\+\+S\+U\+C\+C\+E\+S\+S or failure status 
\end{DoxyReturn}
\hypertarget{btl_8h_a71f73209e00308db469930dda24a69f3}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+get\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+get\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+get\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+get\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+get\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef int($\ast$ mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+get\+\_\+fn\+\_\+t)(struct {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, struct {\bf mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$endpoint, struct {\bf mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} $\ast$descriptor)}}\label{btl_8h_a71f73209e00308db469930dda24a69f3}


Initiate an asynchronous get. 

Completion Semantics\+: the descriptor has been queued for a get operation the B\+T\+L now controls the descriptor until local completion callback is made on the descriptor

B\+T\+Ls that do not have the M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+R\+D\+M\+A\+\_\+\+M\+A\+T\+C\+H\+E\+D flag set allow multiple concurrent get operations on the same descriptor. B\+T\+Ls that do have the M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+R\+D\+M\+A\+\_\+\+M\+A\+T\+C\+H\+E\+D flag set require a corresponding prepare\+\_\+src/dst call for each get operation and therefore prohibit multiple concurrent get operations.


\begin{DoxyParams}{Parameters}
{\em btl} & (I\+N) B\+T\+L module \\
\hline
{\em endpoint} & (I\+N) B\+T\+L addressing information \\
\hline
{\em descriptor} & (I\+N) Description of the data to be transferred\\
\hline
\end{DoxyParams}

\begin{DoxyRetVals}{Return values}
{\em O\+M\+P\+I\+\_\+\+S\+U\+C\+C\+E\+S\+S} & The descriptor was successfully queued for a get \\
\hline
{\em O\+M\+P\+I\+\_\+\+E\+R\+R\+O\+R} & The descriptor was N\+O\+T successfully queued for a get \\
\hline
\end{DoxyRetVals}
\hypertarget{btl_8h_afc7f235e9e15d48929d2b9b79e382022}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+prepare\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+prepare\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+prepare\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+prepare\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+prepare\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef struct {\bf mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t}$\ast$($\ast$ mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+prepare\+\_\+fn\+\_\+t)(struct {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, struct {\bf mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$endpoint, {\bf mca\+\_\+mpool\+\_\+base\+\_\+registration\+\_\+t} $\ast$registration, struct {\bf opal\+\_\+convertor\+\_\+t} $\ast$convertor, uint8\+\_\+t order, size\+\_\+t reserve, size\+\_\+t $\ast$size, uint32\+\_\+t flags)}}\label{btl_8h_afc7f235e9e15d48929d2b9b79e382022}


Prepare a descriptor for send/put/get using the supplied convertor. 

If the convertor references data that is contiguous, the descriptor may simply point to the user buffer. Otherwise, this routine is responsible for allocating buffer space and packing if required.

The descriptor returned can be used in multiple concurrent operations (send/put/get) unless the B\+T\+L has the M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+R\+D\+M\+A\+\_\+\+M\+A\+T\+C\+H\+E\+D flag set in which case a corresponding prepare call must accompany the put/get call in addition, the address and length that is put/get must match the address and length which is prepared.

The order tag value ensures that operations on the descriptor that is prepared will be ordered w.\+r.\+t. a previous operation on a particular descriptor. Ordering is only guaranteed if the previous descriptor had its local completion callback function called and the order tag of that descriptor is only valid upon the local completion callback function.


\begin{DoxyParams}{Parameters}
{\em btl} & (I\+N) B\+T\+L module \\
\hline
{\em endpoint} & (I\+N) B\+T\+L peer addressing \\
\hline
{\em registration} & (I\+N) Memory registration \\
\hline
{\em convertor} & (I\+N) Data type convertor \\
\hline
{\em order} & (I\+N) The ordering tag (may be M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+N\+O\+\_\+\+O\+R\+D\+E\+R) \\
\hline
{\em reserve} & (I\+N) Additional bytes requested by upper layer to precede user data \\
\hline
{\em size} & (I\+N/\+O\+U\+T) Number of bytes to prepare (I\+N), number of bytes actually prepared (O\+U\+T) \\
\hline
\end{DoxyParams}
\hypertarget{btl_8h_a208be2d3632a2fb234e05889e19a870d}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+put\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+put\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+put\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+put\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+put\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef int($\ast$ mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+put\+\_\+fn\+\_\+t)(struct {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, struct {\bf mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$endpoint, struct {\bf mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} $\ast$descriptor)}}\label{btl_8h_a208be2d3632a2fb234e05889e19a870d}


Initiate an asynchronous put. 

Completion Semantics\+: the descriptor has been queued for a put operation the B\+T\+L now controls the descriptor until local completion callback is made on the descriptor

B\+T\+Ls that do not have the M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+R\+D\+M\+A\+\_\+\+M\+A\+T\+C\+H\+E\+D flag set allow multiple concurrent put operations on the same descriptor. B\+T\+Ls that do have the M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+R\+D\+M\+A\+\_\+\+M\+A\+T\+C\+H\+E\+D flag set require a corresponding prepare\+\_\+src/dst call for each put operation and therefore prohibit multiple concurrent put operations.


\begin{DoxyParams}{Parameters}
{\em btl} & (I\+N) B\+T\+L module \\
\hline
{\em endpoint} & (I\+N) B\+T\+L addressing information \\
\hline
{\em descriptor} & (I\+N) Description of the data to be transferred\\
\hline
\end{DoxyParams}

\begin{DoxyRetVals}{Return values}
{\em O\+M\+P\+I\+\_\+\+S\+U\+C\+C\+E\+S\+S} & The descriptor was successfully queued for a put \\
\hline
{\em O\+M\+P\+I\+\_\+\+E\+R\+R\+O\+R} & The descriptor was N\+O\+T successfully queued for a put \\
\hline
\end{DoxyRetVals}
\hypertarget{btl_8h_a6b39783709e482be956466e3a5847eff}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+recv\+\_\+cb\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+recv\+\_\+cb\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+recv\+\_\+cb\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+recv\+\_\+cb\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+recv\+\_\+cb\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef void($\ast$ mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+recv\+\_\+cb\+\_\+fn\+\_\+t)(struct {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, mca\+\_\+btl\+\_\+base\+\_\+tag\+\_\+t tag, {\bf mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} $\ast$descriptor, void $\ast$cbdata)}}\label{btl_8h_a6b39783709e482be956466e3a5847eff}


Callback function that is called asynchronously on receipt of data by the transport layer. 

Note that the the \hyperlink{structmca__btl__base__descriptor__t}{mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} is only valid within the completion function, this implies that all data payload in the \hyperlink{structmca__btl__base__descriptor__t}{mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} must be copied out within this callback or forfeited back to the B\+T\+L.


\begin{DoxyParams}{Parameters}
{\em I\+N\mbox{]}} & btl B\+T\+L module \\
\hline
{\em I\+N\mbox{]}} & tag The active message receive callback tag value \\
\hline
{\em I\+N\mbox{]}} & descriptor The B\+T\+L descriptor (contains the receive payload) \\
\hline
{\em I\+N\mbox{]}} & cbdata Opaque callback data \\
\hline
\end{DoxyParams}
\hypertarget{btl_8h_a0a44e6c722541e91e7d946f23fe4f135}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+register\+\_\+error\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+register\+\_\+error\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+register\+\_\+error\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+register\+\_\+error\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+register\+\_\+error\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef int($\ast$ mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+register\+\_\+error\+\_\+fn\+\_\+t)(struct {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+error\+\_\+cb\+\_\+fn\+\_\+t} cbfunc)}}\label{btl_8h_a0a44e6c722541e91e7d946f23fe4f135}


Register a callback function that is called on receipt of an error. 


\begin{DoxyParams}{Parameters}
{\em I\+N\mbox{]}} & btl B\+T\+L module \\
\hline
{\em I\+N\mbox{]}} & cbfunc The callback function\\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
O\+M\+P\+I\+\_\+\+S\+U\+C\+C\+E\+S\+S The callback was registered successfully 

O\+M\+P\+I\+\_\+\+E\+R\+R\+O\+R The callback was N\+O\+T registered successfully 
\end{DoxyReturn}
\hypertarget{btl_8h_ae05729c42406594aed526627cccad4ae}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+register\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+register\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+register\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+register\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+register\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef int($\ast$ mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+register\+\_\+fn\+\_\+t)(struct {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, mca\+\_\+btl\+\_\+base\+\_\+tag\+\_\+t tag, {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+recv\+\_\+cb\+\_\+fn\+\_\+t} cbfunc, void $\ast$cbdata)}}\label{btl_8h_ae05729c42406594aed526627cccad4ae}


Register a callback function that is called on receipt of a fragment. 


\begin{DoxyParams}{Parameters}
{\em I\+N\mbox{]}} & btl B\+T\+L module \\
\hline
{\em I\+N\mbox{]}} & tag tag value of this callback (specified on subsequent send operations) \\
\hline
{\em I\+N\mbox{]}} & cbfunc The callback function \\
\hline
{\em I\+N\mbox{]}} & cbdata Opaque callback data\\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
O\+M\+P\+I\+\_\+\+S\+U\+C\+C\+E\+S\+S The callback was registered successfully 

O\+M\+P\+I\+\_\+\+E\+R\+R\+O\+R The callback was N\+O\+T registered successfully 
\end{DoxyReturn}
\hypertarget{btl_8h_a1ea008e4d1733998a83032d8c392f0e3}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+send\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+send\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+send\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+send\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+send\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef int($\ast$ mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+send\+\_\+fn\+\_\+t)(struct {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, struct {\bf mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$endpoint, struct {\bf mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} $\ast$descriptor, mca\+\_\+btl\+\_\+base\+\_\+tag\+\_\+t tag)}}\label{btl_8h_a1ea008e4d1733998a83032d8c392f0e3}


Initiate an asynchronous send. 

Completion Semantics\+: the descriptor has been queued for a send operation the B\+T\+L now controls the descriptor until local completion callback is made on the descriptor

All B\+T\+Ls allow multiple concurrent asynchronous send operations on a descriptor


\begin{DoxyParams}{Parameters}
{\em btl} & (I\+N) B\+T\+L module \\
\hline
{\em endpoint} & (I\+N) B\+T\+L addressing information \\
\hline
{\em descriptor} & (I\+N) Description of the data to be transfered \\
\hline
{\em tag} & (I\+N) The tag value used to notify the peer.\\
\hline
\end{DoxyParams}

\begin{DoxyRetVals}{Return values}
{\em O\+M\+P\+I\+\_\+\+S\+U\+C\+C\+E\+S\+S} & The descriptor was successfully queued for a send \\
\hline
{\em O\+M\+P\+I\+\_\+\+E\+R\+R\+O\+R} & The descriptor was N\+O\+T successfully queued for a send \\
\hline
{\em O\+M\+P\+I\+\_\+\+E\+R\+R\+\_\+\+U\+N\+R\+E\+A\+C\+H} & The endpoint is not reachable \\
\hline
\end{DoxyRetVals}
\hypertarget{btl_8h_a7ab217077e81c7a35c3524ab91a199f9}{\index{btl.\+h@{btl.\+h}!mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+sendi\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+sendi\+\_\+fn\+\_\+t}}
\index{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+sendi\+\_\+fn\+\_\+t@{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+sendi\+\_\+fn\+\_\+t}!btl.\+h@{btl.\+h}}
\subsubsection[{mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+sendi\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef int($\ast$ mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+sendi\+\_\+fn\+\_\+t)(struct {\bf mca\+\_\+btl\+\_\+base\+\_\+module\+\_\+t} $\ast$btl, struct {\bf mca\+\_\+btl\+\_\+base\+\_\+endpoint\+\_\+t} $\ast$endpoint, struct {\bf opal\+\_\+convertor\+\_\+t} $\ast$convertor, void $\ast$header, size\+\_\+t header\+\_\+size, size\+\_\+t payload\+\_\+size, uint8\+\_\+t order, uint32\+\_\+t flags, mca\+\_\+btl\+\_\+base\+\_\+tag\+\_\+t tag, {\bf mca\+\_\+btl\+\_\+base\+\_\+descriptor\+\_\+t} $\ast$$\ast$descriptor)}}\label{btl_8h_a7ab217077e81c7a35c3524ab91a199f9}


Initiate an immediate blocking send. 

Completion Semantics\+: the B\+T\+L will make a best effort to send the header and \char`\"{}size\char`\"{} bytes from the datatype using the convertor. The header is guaranteed to be delivered entirely in the first segment. Should the B\+T\+L be unable to deliver the data due to resource constraints the B\+T\+L will return a descriptor (via the O\+U\+T param) of size \char`\"{}payload\+\_\+size + header\+\_\+size\char`\"{}.


\begin{DoxyParams}{Parameters}
{\em btl} & (I\+N) B\+T\+L module \\
\hline
{\em endpoint} & (I\+N) B\+T\+L addressing information \\
\hline
{\em convertor} & (I\+N) Data type convertor \\
\hline
{\em header} & (I\+N) Pointer to header. \\
\hline
{\em header\+\_\+size} & (I\+N) Size of header. \\
\hline
{\em payload\+\_\+size} & (I\+N) Size of payload (from convertor). \\
\hline
{\em order} & (I\+N) The ordering tag (may be M\+C\+A\+\_\+\+B\+T\+L\+\_\+\+N\+O\+\_\+\+O\+R\+D\+E\+R) \\
\hline
{\em flags} & (I\+N) Flags. \\
\hline
{\em tag} & (I\+N) The tag value used to notify the peer. \\
\hline
{\em descriptor} & (O\+U\+T) The descriptor to be returned unable to be sent immediately\\
\hline
\end{DoxyParams}

\begin{DoxyRetVals}{Return values}
{\em O\+M\+P\+I\+\_\+\+S\+U\+C\+C\+E\+S\+S} & The send was successfully queued \\
\hline
{\em O\+M\+P\+I\+\_\+\+E\+R\+R\+O\+R} & The send failed \\
\hline
{\em O\+M\+P\+I\+\_\+\+E\+R\+R\+\_\+\+U\+N\+R\+E\+A\+C\+H} & The endpoint is not reachable \\
\hline
{\em O\+M\+P\+I\+\_\+\+E\+R\+R\+\_\+\+R\+E\+S\+O\+U\+R\+C\+E\+\_\+\+B\+U\+S\+Y} & The B\+T\+L is busy a descriptor will be returned (via the O\+U\+T param) if descriptors are available \\
\hline
\end{DoxyRetVals}
