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


Copyright (c) 2004-\/2007 The Trustees of Indiana University and Indiana University Research and Technology Corporation.  


{\ttfamily \#include \char`\"{}ompi\+\_\+config.\+h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}opal/mca/mca.\+h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}ompi/info/info.\+h\char`\"{}}\\*
{\ttfamily \#include \char`\"{}ompi/class/ompi\+\_\+free\+\_\+list.\+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__mpool__base__registration__t}{mca\+\_\+mpool\+\_\+base\+\_\+registration\+\_\+t}
\item 
struct \hyperlink{structmca__mpool__base__component__2__0__0__t}{mca\+\_\+mpool\+\_\+base\+\_\+component\+\_\+2\+\_\+0\+\_\+0\+\_\+t}
\begin{DoxyCompactList}\small\item\em mpool component descriptor. \end{DoxyCompactList}\item 
struct \hyperlink{structmca__mpool__base__module__t}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t}
\begin{DoxyCompactList}\small\item\em mpool module descriptor. \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Macros}
\begin{DoxyCompactItemize}
\item 
\hypertarget{mpool_8h_a4eee75ceab019df10406bb1e07f6ab3d}{\#define {\bfseries M\+C\+A\+\_\+\+M\+P\+O\+O\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+C\+A\+C\+H\+E\+\_\+\+B\+Y\+P\+A\+S\+S}~0x1}\label{mpool_8h_a4eee75ceab019df10406bb1e07f6ab3d}

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

\item 
\hypertarget{mpool_8h_aeb8d9c3895dac0323d924fa0a02cd63d}{\#define {\bfseries M\+C\+A\+\_\+\+M\+P\+O\+O\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+M\+P\+I\+\_\+\+A\+L\+L\+O\+C\+\_\+\+M\+E\+M}~0x4}\label{mpool_8h_aeb8d9c3895dac0323d924fa0a02cd63d}

\item 
\hypertarget{mpool_8h_ac9af9f8a26c162bfe69e7bf8be046708}{\#define {\bfseries M\+C\+A\+\_\+\+M\+P\+O\+O\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+I\+N\+V\+A\+L\+I\+D}~0x8}\label{mpool_8h_ac9af9f8a26c162bfe69e7bf8be046708}

\item 
\hypertarget{mpool_8h_a77ca639e3f549a94c69191da8943153a}{\#define {\bfseries M\+C\+A\+\_\+\+M\+P\+O\+O\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+S\+O\+\_\+\+M\+E\+M}~0x10}\label{mpool_8h_a77ca639e3f549a94c69191da8943153a}

\item 
\hypertarget{mpool_8h_ae7ff8fefb59cc383f38a1af8397923fa}{\#define {\bfseries M\+C\+A\+\_\+\+M\+P\+O\+O\+L\+\_\+\+F\+L\+A\+G\+S\+\_\+\+C\+U\+D\+A\+\_\+\+R\+E\+G\+I\+S\+T\+E\+R\+\_\+\+M\+E\+M}~0x20}\label{mpool_8h_ae7ff8fefb59cc383f38a1af8397923fa}

\item 
\#define \hyperlink{mpool_8h_a9c6354a6838b885829a834e4ac19e8f9}{M\+C\+A\+\_\+\+M\+P\+O\+O\+L\+\_\+\+B\+A\+S\+E\+\_\+\+V\+E\+R\+S\+I\+O\+N\+\_\+2\+\_\+0\+\_\+0}
\begin{DoxyCompactList}\small\item\em Macro for use in components that are of type mpool. \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Typedefs}
\begin{DoxyCompactItemize}
\item 
\hypertarget{mpool_8h_a25aeb0bb473b6586ff959746e8766e96}{typedef struct \\*
\hyperlink{structmca__mpool__base__registration__t}{mca\+\_\+mpool\+\_\+base\+\_\+registration\+\_\+t} {\bfseries mca\+\_\+mpool\+\_\+base\+\_\+registration\+\_\+t}}\label{mpool_8h_a25aeb0bb473b6586ff959746e8766e96}

\item 
\hypertarget{mpool_8h_a9ea30875f896e2c7c4d6fe984ffe7819}{typedef struct \\*
\hyperlink{structmca__mpool__base__module__t}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t} $\ast$($\ast$ \hyperlink{mpool_8h_a9ea30875f896e2c7c4d6fe984ffe7819}{mca\+\_\+mpool\+\_\+base\+\_\+component\+\_\+init\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__mpool__base__resources__t}{mca\+\_\+mpool\+\_\+base\+\_\+resources\+\_\+t} $\ast$)}\label{mpool_8h_a9ea30875f896e2c7c4d6fe984ffe7819}

\begin{DoxyCompactList}\small\item\em component initialize \end{DoxyCompactList}\item 
\hypertarget{mpool_8h_aa7630294cda7ae4ca305bc7bef11d148}{typedef void $\ast$($\ast$ \hyperlink{mpool_8h_aa7630294cda7ae4ca305bc7bef11d148}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+alloc\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__mpool__base__module__t}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t} $\ast$mpool, size\+\_\+t size, size\+\_\+t align, uint32\+\_\+t flags, \hyperlink{structmca__mpool__base__registration__t}{mca\+\_\+mpool\+\_\+base\+\_\+registration\+\_\+t} $\ast$$\ast$registration)}\label{mpool_8h_aa7630294cda7ae4ca305bc7bef11d148}

\begin{DoxyCompactList}\small\item\em allocate function typedef \end{DoxyCompactList}\item 
\hypertarget{mpool_8h_a22b338992ea20936a7fa58bcc2fc86ca}{typedef void $\ast$($\ast$ \hyperlink{mpool_8h_a22b338992ea20936a7fa58bcc2fc86ca}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+realloc\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__mpool__base__module__t}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t} $\ast$mpool, void $\ast$addr, size\+\_\+t size, \hyperlink{structmca__mpool__base__registration__t}{mca\+\_\+mpool\+\_\+base\+\_\+registration\+\_\+t} $\ast$$\ast$registration)}\label{mpool_8h_a22b338992ea20936a7fa58bcc2fc86ca}

\begin{DoxyCompactList}\small\item\em realloc function typedef \end{DoxyCompactList}\item 
\hypertarget{mpool_8h_a6764f2ce62cdc15b684d96e4301ddfef}{typedef void($\ast$ \hyperlink{mpool_8h_a6764f2ce62cdc15b684d96e4301ddfef}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+free\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__mpool__base__module__t}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t} $\ast$mpool, void $\ast$addr, \hyperlink{structmca__mpool__base__registration__t}{mca\+\_\+mpool\+\_\+base\+\_\+registration\+\_\+t} $\ast$registration)}\label{mpool_8h_a6764f2ce62cdc15b684d96e4301ddfef}

\begin{DoxyCompactList}\small\item\em free function typedef \end{DoxyCompactList}\item 
\hypertarget{mpool_8h_a18b1a7b704435036f4eaee3d3d508a9b}{typedef int($\ast$ \hyperlink{mpool_8h_a18b1a7b704435036f4eaee3d3d508a9b}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+register\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__mpool__base__module__t}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t} $\ast$mpool, void $\ast$addr, size\+\_\+t size, uint32\+\_\+t flags, \hyperlink{structmca__mpool__base__registration__t}{mca\+\_\+mpool\+\_\+base\+\_\+registration\+\_\+t} $\ast$$\ast$registration)}\label{mpool_8h_a18b1a7b704435036f4eaee3d3d508a9b}

\begin{DoxyCompactList}\small\item\em register memory \end{DoxyCompactList}\item 
\hypertarget{mpool_8h_a9803113d74bc94f06d1babcfbfc1d113}{typedef int($\ast$ \hyperlink{mpool_8h_a9803113d74bc94f06d1babcfbfc1d113}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+deregister\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__mpool__base__module__t}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t} $\ast$mpool, \hyperlink{structmca__mpool__base__registration__t}{mca\+\_\+mpool\+\_\+base\+\_\+registration\+\_\+t} $\ast$registration)}\label{mpool_8h_a9803113d74bc94f06d1babcfbfc1d113}

\begin{DoxyCompactList}\small\item\em deregister memory \end{DoxyCompactList}\item 
\hypertarget{mpool_8h_afb9b07f498fa8971927ddd5a0d6b332d}{typedef int($\ast$ \hyperlink{mpool_8h_afb9b07f498fa8971927ddd5a0d6b332d}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+find\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__mpool__base__module__t}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t} $\ast$mpool, void $\ast$addr, size\+\_\+t size, \hyperlink{structmca__mpool__base__registration__t}{mca\+\_\+mpool\+\_\+base\+\_\+registration\+\_\+t} $\ast$$\ast$reg)}\label{mpool_8h_afb9b07f498fa8971927ddd5a0d6b332d}

\begin{DoxyCompactList}\small\item\em find registration in this memory pool \end{DoxyCompactList}\item 
\hypertarget{mpool_8h_a0fb0417ba4f960e5b7c85fc51b787720}{typedef int($\ast$ \hyperlink{mpool_8h_a0fb0417ba4f960e5b7c85fc51b787720}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+release\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__mpool__base__module__t}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t} $\ast$mpool, \hyperlink{structmca__mpool__base__registration__t}{mca\+\_\+mpool\+\_\+base\+\_\+registration\+\_\+t} $\ast$registration)}\label{mpool_8h_a0fb0417ba4f960e5b7c85fc51b787720}

\begin{DoxyCompactList}\small\item\em release registration \end{DoxyCompactList}\item 
\hypertarget{mpool_8h_a0f2cf599c786482364be86f091117b12}{typedef int($\ast$ \hyperlink{mpool_8h_a0f2cf599c786482364be86f091117b12}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+release\+\_\+memory\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__mpool__base__module__t}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t} $\ast$mpool, void $\ast$base, size\+\_\+t size)}\label{mpool_8h_a0f2cf599c786482364be86f091117b12}

\begin{DoxyCompactList}\small\item\em release memory region \end{DoxyCompactList}\item 
\hypertarget{mpool_8h_a41e4e69483df6fd9b852b1a35dd763eb}{typedef void $\ast$($\ast$ \hyperlink{mpool_8h_a41e4e69483df6fd9b852b1a35dd763eb}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+address\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__mpool__base__module__t}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t} $\ast$mpool)}\label{mpool_8h_a41e4e69483df6fd9b852b1a35dd763eb}

\begin{DoxyCompactList}\small\item\em if appropriate -\/ returns base address of memory pool \end{DoxyCompactList}\item 
\hypertarget{mpool_8h_a7997dac4ef7efa28157ad3f74d86a5e6}{typedef void($\ast$ \hyperlink{mpool_8h_a7997dac4ef7efa28157ad3f74d86a5e6}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+finalize\+\_\+fn\+\_\+t} )(struct \hyperlink{structmca__mpool__base__module__t}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t} $\ast$)}\label{mpool_8h_a7997dac4ef7efa28157ad3f74d86a5e6}

\begin{DoxyCompactList}\small\item\em finalize \end{DoxyCompactList}\item 
typedef int($\ast$ \hyperlink{mpool_8h_a299b829c13aa86f919cbdb7982c2229f}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+ft\+\_\+event\+\_\+fn\+\_\+t} )(int state)
\begin{DoxyCompactList}\small\item\em Fault Tolerance Event Notification \hyperlink{structFunction}{Function}. \end{DoxyCompactList}\item 
\hypertarget{mpool_8h_a51dc4924cea98d3d5d454bfbe982e6f5}{typedef struct \\*
\hyperlink{structmca__mpool__base__component__2__0__0__t}{mca\+\_\+mpool\+\_\+base\+\_\+component\+\_\+2\+\_\+0\+\_\+0\+\_\+t} \hyperlink{mpool_8h_a51dc4924cea98d3d5d454bfbe982e6f5}{mca\+\_\+mpool\+\_\+base\+\_\+component\+\_\+2\+\_\+0\+\_\+0\+\_\+t}}\label{mpool_8h_a51dc4924cea98d3d5d454bfbe982e6f5}

\begin{DoxyCompactList}\small\item\em Convenience typedef. \end{DoxyCompactList}\item 
\hypertarget{mpool_8h_ac17cbfc8f12a117dfd410d6169e00c9a}{typedef struct \\*
\hyperlink{structmca__mpool__base__component__2__0__0__t}{mca\+\_\+mpool\+\_\+base\+\_\+component\+\_\+2\+\_\+0\+\_\+0\+\_\+t} \hyperlink{mpool_8h_ac17cbfc8f12a117dfd410d6169e00c9a}{mca\+\_\+mpool\+\_\+base\+\_\+component\+\_\+t}}\label{mpool_8h_ac17cbfc8f12a117dfd410d6169e00c9a}

\begin{DoxyCompactList}\small\item\em Convenience typedef. \end{DoxyCompactList}\item 
\hypertarget{mpool_8h_a93b4befa8fddbb2b448d605816f9152c}{typedef struct \\*
\hyperlink{structmca__mpool__base__module__t}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t} \hyperlink{mpool_8h_a93b4befa8fddbb2b448d605816f9152c}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t}}\label{mpool_8h_a93b4befa8fddbb2b448d605816f9152c}

\begin{DoxyCompactList}\small\item\em Convenience typedef. \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Functions}
\begin{DoxyCompactItemize}
\item 
\hypertarget{mpool_8h_ad9ed5da0c13c40a981ac6f5fa721111d}{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__mpool__base__registration__t}{mca\+\_\+mpool\+\_\+base\+\_\+registration\+\_\+t})}\label{mpool_8h_ad9ed5da0c13c40a981ac6f5fa721111d}

\item 
O\+M\+P\+I\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C void $\ast$ \hyperlink{mpool_8h_af88c63dbd840e09aef6afa5a1e5255e1}{mca\+\_\+mpool\+\_\+base\+\_\+alloc} (size\+\_\+t size, struct \hyperlink{structompi__info__t}{ompi\+\_\+info\+\_\+t} $\ast$info)
\begin{DoxyCompactList}\small\item\em \hyperlink{structFunction}{Function} to allocate special memory according to what the user requests in the info object. \end{DoxyCompactList}\item 
O\+M\+P\+I\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int \hyperlink{mpool_8h_abf5fe401dba0a5822c0810a80a3283a8}{mca\+\_\+mpool\+\_\+base\+\_\+free} (void $\ast$base)
\begin{DoxyCompactList}\small\item\em \hyperlink{structFunction}{Function} to free memory previously allocated by mca\+\_\+mpool\+\_\+base\+\_\+alloc. \end{DoxyCompactList}\item 
O\+M\+P\+I\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int \hyperlink{mpool_8h_ac71bb93b558c820201ea4a9729452953}{mca\+\_\+mpool\+\_\+base\+\_\+tree\+\_\+node\+\_\+compare} (void $\ast$key1, void $\ast$key2)
\begin{DoxyCompactList}\small\item\em \hyperlink{structFunction}{Function} for the red black tree to compare 2 keys. \end{DoxyCompactList}\item 
\hypertarget{mpool_8h_a7ee378f03c72d2e6d3a505cf02228580}{O\+M\+P\+I\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int {\bfseries mca\+\_\+mpool\+\_\+base\+\_\+insert} (void $\ast$addr, size\+\_\+t size, \hyperlink{structmca__mpool__base__module__t}{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t} $\ast$mpool, void $\ast$user\+\_\+in, \hyperlink{structmca__mpool__base__registration__t}{mca\+\_\+mpool\+\_\+base\+\_\+registration\+\_\+t} $\ast$registration)}\label{mpool_8h_a7ee378f03c72d2e6d3a505cf02228580}

\item 
\hypertarget{mpool_8h_a2b67cf965371f21d480b198331d39c6b}{O\+M\+P\+I\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int {\bfseries mca\+\_\+mpool\+\_\+base\+\_\+remove} (void $\ast$base)}\label{mpool_8h_a2b67cf965371f21d480b198331d39c6b}

\end{DoxyCompactItemize}


\subsection{Detailed Description}
Copyright (c) 2004-\/2007 The Trustees of Indiana University and Indiana University Research and Technology Corporation. 

All rights reserved. Copyright (c) 2004-\/2007 The University of Tennessee and The University of Tennessee Research Foundation. All rights reserved. Copyright (c) 2004-\/2005 High Performance Computing Center Stuttgart, University of Stuttgart. All rights reserved. Copyright (c) 2004-\/2005 The Regents of the University of California. All rights reserved. Copyright (c) 2009 Sun Microsystems, Inc. All rights reserved. Copyright (c) 2011 N\+V\+I\+D\+I\+A Corporation. All rights reserved. \$\+C\+O\+P\+Y\+R\+I\+G\+H\+T\$

Additional copyrights may follow

\$\+H\+E\+A\+D\+E\+R\$

Description of the Memory Pool framework 

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


Macro for use in components that are of type mpool. 



\subsection{Typedef Documentation}
\hypertarget{mpool_8h_a299b829c13aa86f919cbdb7982c2229f}{\index{mpool.\+h@{mpool.\+h}!mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+ft\+\_\+event\+\_\+fn\+\_\+t@{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+ft\+\_\+event\+\_\+fn\+\_\+t}}
\index{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+ft\+\_\+event\+\_\+fn\+\_\+t@{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+ft\+\_\+event\+\_\+fn\+\_\+t}!mpool.\+h@{mpool.\+h}}
\subsubsection[{mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+ft\+\_\+event\+\_\+fn\+\_\+t}]{\setlength{\rightskip}{0pt plus 5cm}typedef int($\ast$ mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+ft\+\_\+event\+\_\+fn\+\_\+t)(int state)}}\label{mpool_8h_a299b829c13aa86f919cbdb7982c2229f}


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


\begin{DoxyParams}{Parameters}
{\em state} & Checkpoint Stae \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
O\+M\+P\+I\+\_\+\+S\+U\+C\+C\+E\+S\+S or failure status 
\end{DoxyReturn}


\subsection{Function Documentation}
\hypertarget{mpool_8h_af88c63dbd840e09aef6afa5a1e5255e1}{\index{mpool.\+h@{mpool.\+h}!mca\+\_\+mpool\+\_\+base\+\_\+alloc@{mca\+\_\+mpool\+\_\+base\+\_\+alloc}}
\index{mca\+\_\+mpool\+\_\+base\+\_\+alloc@{mca\+\_\+mpool\+\_\+base\+\_\+alloc}!mpool.\+h@{mpool.\+h}}
\subsubsection[{mca\+\_\+mpool\+\_\+base\+\_\+alloc}]{\setlength{\rightskip}{0pt plus 5cm}O\+M\+P\+I\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C void$\ast$ mca\+\_\+mpool\+\_\+base\+\_\+alloc (
\begin{DoxyParamCaption}
\item[{size\+\_\+t}]{size, }
\item[{{\bf ompi\+\_\+info\+\_\+t} $\ast$}]{info}
\end{DoxyParamCaption}
)}}\label{mpool_8h_af88c63dbd840e09aef6afa5a1e5255e1}


\hyperlink{structFunction}{Function} to allocate special memory according to what the user requests in the info object. 

If the user passes in a valid info structure then the function will try to allocate the memory and register it with every mpool that there is a key for it in the info struct. If it fails at registering the memory with one of the requested mpools, an error will be returned. Also, if there is a key in info that does not match any mpool, an error will be returned.

If the info parameter is M\+P\+I\+\_\+\+I\+N\+F\+O\+\_\+\+N\+U\+L\+L, then this function will try to allocate the memory and register it wih as many mpools as possible. However, if any of the registratons fail the mpool will simply be ignored.


\begin{DoxyParams}{Parameters}
{\em size} & the size of the memory area to allocate \\
\hline
{\em info} & an info object which tells us what kind of memory to allocate\\
\hline
\end{DoxyParams}

\begin{DoxyRetVals}{Return values}
{\em pointer} & to the allocated memory \\
\hline
{\em N\+U\+L\+L} & on failure\\
\hline
\end{DoxyRetVals}
If the user passes in a valid info structure then the function will try to allocate the memory and register it with every mpool that there is a key for it in the info struct. If it fails at registering the memory with one of the requested mpools, an error will be returned. Also, if there is a key in info that does not match any mpool, an error will be returned.

If the info parameter is M\+P\+I\+\_\+\+I\+N\+F\+O\+\_\+\+N\+U\+L\+L, then this function will try to allocate the memory and register it with as many mpools as possible. However, if any of the registratons fail the mpool will simply be ignored.


\begin{DoxyParams}{Parameters}
{\em size} & the size of the memory area to allocate \\
\hline
{\em info} & an info object which tells us what kind of memory to allocate\\
\hline
\end{DoxyParams}

\begin{DoxyRetVals}{Return values}
{\em pointer} & to the allocated memory \\
\hline
{\em N\+U\+L\+L} & on failure \\
\hline
\end{DoxyRetVals}


References mca\+\_\+mpool\+\_\+base\+\_\+tree\+\_\+item\+\_\+t\+::count, mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t\+::flags, mca\+\_\+mpool\+\_\+base\+\_\+tree\+\_\+item\+\_\+t\+::key, mca\+\_\+base\+\_\+component\+\_\+2\+\_\+0\+\_\+0\+\_\+t\+::mca\+\_\+component\+\_\+name, mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t\+::mpool\+\_\+alloc, mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t\+::mpool\+\_\+component, mca\+\_\+mpool\+\_\+base\+\_\+module\+\_\+t\+::mpool\+\_\+register, mca\+\_\+mpool\+\_\+base\+\_\+component\+\_\+2\+\_\+0\+\_\+0\+\_\+t\+::mpool\+\_\+version, mca\+\_\+mpool\+\_\+base\+\_\+tree\+\_\+item\+\_\+t\+::mpools, mca\+\_\+mpool\+\_\+base\+\_\+tree\+\_\+item\+\_\+t\+::num\+\_\+bytes, opal\+\_\+list\+\_\+get\+\_\+end(), opal\+\_\+list\+\_\+get\+\_\+first(), opal\+\_\+list\+\_\+get\+\_\+next, opal\+\_\+list\+\_\+get\+\_\+size(), and mca\+\_\+mpool\+\_\+base\+\_\+tree\+\_\+item\+\_\+t\+::regs.

\hypertarget{mpool_8h_abf5fe401dba0a5822c0810a80a3283a8}{\index{mpool.\+h@{mpool.\+h}!mca\+\_\+mpool\+\_\+base\+\_\+free@{mca\+\_\+mpool\+\_\+base\+\_\+free}}
\index{mca\+\_\+mpool\+\_\+base\+\_\+free@{mca\+\_\+mpool\+\_\+base\+\_\+free}!mpool.\+h@{mpool.\+h}}
\subsubsection[{mca\+\_\+mpool\+\_\+base\+\_\+free}]{\setlength{\rightskip}{0pt plus 5cm}O\+M\+P\+I\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int mca\+\_\+mpool\+\_\+base\+\_\+free (
\begin{DoxyParamCaption}
\item[{void $\ast$}]{base}
\end{DoxyParamCaption}
)}}\label{mpool_8h_abf5fe401dba0a5822c0810a80a3283a8}


\hyperlink{structFunction}{Function} to free memory previously allocated by mca\+\_\+mpool\+\_\+base\+\_\+alloc. 


\begin{DoxyParams}{Parameters}
{\em base} & pointer to the memory to free\\
\hline
\end{DoxyParams}

\begin{DoxyRetVals}{Return values}
{\em O\+M\+P\+I\+\_\+\+S\+U\+C\+C\+E\+S\+S} & \\
\hline
{\em O\+M\+P\+I\+\_\+\+E\+R\+R\+\_\+\+B\+A\+D\+\_\+\+P\+A\+R\+A\+M} & if the passed base pointer was invalid \\
\hline
\end{DoxyRetVals}


References mca\+\_\+mpool\+\_\+base\+\_\+tree\+\_\+find().

\hypertarget{mpool_8h_ac71bb93b558c820201ea4a9729452953}{\index{mpool.\+h@{mpool.\+h}!mca\+\_\+mpool\+\_\+base\+\_\+tree\+\_\+node\+\_\+compare@{mca\+\_\+mpool\+\_\+base\+\_\+tree\+\_\+node\+\_\+compare}}
\index{mca\+\_\+mpool\+\_\+base\+\_\+tree\+\_\+node\+\_\+compare@{mca\+\_\+mpool\+\_\+base\+\_\+tree\+\_\+node\+\_\+compare}!mpool.\+h@{mpool.\+h}}
\subsubsection[{mca\+\_\+mpool\+\_\+base\+\_\+tree\+\_\+node\+\_\+compare}]{\setlength{\rightskip}{0pt plus 5cm}O\+M\+P\+I\+\_\+\+D\+E\+C\+L\+S\+P\+E\+C int mca\+\_\+mpool\+\_\+base\+\_\+tree\+\_\+node\+\_\+compare (
\begin{DoxyParamCaption}
\item[{void $\ast$}]{key1, }
\item[{void $\ast$}]{key2}
\end{DoxyParamCaption}
)}}\label{mpool_8h_ac71bb93b558c820201ea4a9729452953}


\hyperlink{structFunction}{Function} for the red black tree to compare 2 keys. 


\begin{DoxyParams}{Parameters}
{\em key1} & a pointer to the 1st key \\
\hline
{\em key2} & a pointer to the second key\\
\hline
\end{DoxyParams}

\begin{DoxyRetVals}{Return values}
{\em -\/1} & if key1 is below key2 \\
\hline
{\em 1} & if key 1 is above key2 \\
\hline
{\em 0} & if the keys are the same \\
\hline
\end{DoxyRetVals}
