<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>SuperLU: SRC/dmemory.c File Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.5 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main Page</span></a></li>
<li><a href="annotated.html"><span>Data Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>SRC/dmemory.c File Reference</h1>Memory details. <a href="#_details">More...</a>
<p>
<code>#include "<a class="el" href="slu__ddefs_8h-source.html">slu_ddefs.h</a>"</code><br>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Defines</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#1ef4d4db4d5e1fe0719416163e0e51ae">StackFull</a>(x) ( x + Glu->stack.used >= Glu->stack.size )</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#c11b1c3847a3d397e9675de40782134d">NotDoubleAlign</a>(addr) ( (long int)addr & 7 )</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#c8204d321846eb4b23d563eac7e5bfa7">DoubleAlign</a>(addr) ( ((long int)addr + 7) & ~7L )</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#70ca807c578a0c495f7ce5edb0215e2b">TempSpace</a>(m, w)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#7b2a35bfd2e6c9d03e2a6ccdba9fa847">Reduce</a>(alpha) ((alpha + 1) / 2)</td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void * </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#fe3104df9ace895f5332843534ae99b4">dexpand</a> (int *prev_len,<a class="el" href="superlu__enum__consts_8h.html#bd31f838aefffa46191d0d7dc36a96b2">MemType</a> type,int len_to_copy,int keep_prev,<a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> *Glu)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Expand the existing storage to accommodate more fill-ins. <a href="#fe3104df9ace895f5332843534ae99b4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#0ae701a41439ca8af10604920e2f72ba">dLUWorkInit</a> (int m, int n, int panel_size, int **iworkptr, double **dworkptr, <a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> *Glu)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Allocate known working storage. Returns 0 if success, otherwise returns the number of bytes allocated so far when failure occurred. <a href="#0ae701a41439ca8af10604920e2f72ba"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#1540850a622674131bd1ea6a4f91cd56">copy_mem_double</a> (int, void *, void *)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#adb43e6ea6725f06d04704a1db3dc0be">dStackCompress</a> (<a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> *Glu)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Compress the work[] array to remove fragmentation. <a href="#adb43e6ea6725f06d04704a1db3dc0be"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#cb29e96116d7b170d6f021a87a4763e6">dSetupSpace</a> (void *work, int lwork, <a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> *Glu)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Setup the memory model to be used for factorization. <a href="#cb29e96116d7b170d6f021a87a4763e6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void * </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#00f228f45bab7594bea821b70eedbf51">duser_malloc</a> (int, int, <a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> *)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#8412c8f776ad7cfe599a5b601310fb8e">duser_free</a> (int, int, <a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> *)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#b59eea34474da95fb3dc125400a1287e">copy_mem_int</a> (int, void *, void *)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#4c226087c09a94ff40b92b14fa46fc53">user_bcopy</a> (char *, char *, int)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#e94c561110fcc75c31cda89105fd0a6c">dQuerySpace</a> (<a class="el" href="structSuperMatrix.html">SuperMatrix</a> *L, <a class="el" href="structSuperMatrix.html">SuperMatrix</a> *U, <a class="el" href="structmem__usage__t.html">mem_usage_t</a> *mem_usage)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#61aaccf587a78d15d79c4cc79f80e8b0">ilu_dQuerySpace</a> (<a class="el" href="structSuperMatrix.html">SuperMatrix</a> *L, <a class="el" href="structSuperMatrix.html">SuperMatrix</a> *U, <a class="el" href="structmem__usage__t.html">mem_usage_t</a> *mem_usage)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#e2ca2ac5e9a763fd3f07487343e4522e">dLUMemInit</a> (<a class="el" href="superlu__enum__consts_8h.html#c785c8235480e5cfef9848d89c047c0a">fact_t</a> fact, void *work, int lwork, int m, int n, int annz, int panel_size, double fill_ratio, <a class="el" href="structSuperMatrix.html">SuperMatrix</a> *L, <a class="el" href="structSuperMatrix.html">SuperMatrix</a> *U, <a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> *Glu, int **iwork, double **dwork)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Allocate storage for the data structures common to all factor routines. <a href="#e2ca2ac5e9a763fd3f07487343e4522e"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#aa5359da217b433b43bf6c8e2d29aa45">dSetRWork</a> (int m, int panel_size, double *dworkptr, double **dense, double **tempv)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Set up pointers for real working arrays. <a href="#aa5359da217b433b43bf6c8e2d29aa45"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#a7d9129a2b0dc259ccccc8d6d2218cf8">dLUWorkFree</a> (int *iwork, double *dwork, <a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> *Glu)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Free the working storage used by factor routines. <a href="#a7d9129a2b0dc259ccccc8d6d2218cf8"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#9aff5dfe301496ef7c9234789975c043">dLUMemXpand</a> (int jcol, int next, <a class="el" href="superlu__enum__consts_8h.html#bd31f838aefffa46191d0d7dc36a96b2">MemType</a> mem_type, int *maxlen, <a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> *Glu)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Expand the data structures for L and U during the factorization. <a href="#9aff5dfe301496ef7c9234789975c043"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#eed250713fbfb3fac567d7a503774ccc">dallocateA</a> (int n, int nnz, double **a, int **asub, int **xa)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Allocate storage for original matrix A. <a href="#eed250713fbfb3fac567d7a503774ccc"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">double * </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#8f2b9305cb611c37e7f627da902451a8">doubleMalloc</a> (int n)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">double * </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#c8b6d99155644578a5e5542c32040cfe">doubleCalloc</a> (int n)</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="dmemory_8c.html#5c9b1e24d07635068c014999d44672aa">dmemory_usage</a> (const int nzlmax, const int nzumax, const int nzlumax, const int n)</td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
<pre>
-- SuperLU routine (version 4.0) --
Lawrence Berkeley National Laboratory.
June 30, 2009
</pre> <hr><h2>Define Documentation</h2>
<a class="anchor" name="c8204d321846eb4b23d563eac7e5bfa7"></a><!-- doxytag: member="dmemory.c::DoubleAlign" ref="c8204d321846eb4b23d563eac7e5bfa7" args="(addr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define DoubleAlign </td>
<td>(</td>
<td class="paramtype">addr </td>
<td class="paramname"> </td>
<td> ) </td>
<td width="100%"> ( ((long int)addr + 7) & ~7L )</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="c11b1c3847a3d397e9675de40782134d"></a><!-- doxytag: member="dmemory.c::NotDoubleAlign" ref="c11b1c3847a3d397e9675de40782134d" args="(addr)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define NotDoubleAlign </td>
<td>(</td>
<td class="paramtype">addr </td>
<td class="paramname"> </td>
<td> ) </td>
<td width="100%"> ( (long int)addr & 7 )</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="7b2a35bfd2e6c9d03e2a6ccdba9fa847"></a><!-- doxytag: member="dmemory.c::Reduce" ref="7b2a35bfd2e6c9d03e2a6ccdba9fa847" args="(alpha)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define Reduce </td>
<td>(</td>
<td class="paramtype">alpha </td>
<td class="paramname"> </td>
<td> ) </td>
<td width="100%"> ((alpha + 1) / 2)</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="1ef4d4db4d5e1fe0719416163e0e51ae"></a><!-- doxytag: member="dmemory.c::StackFull" ref="1ef4d4db4d5e1fe0719416163e0e51ae" args="(x)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define StackFull </td>
<td>(</td>
<td class="paramtype">x </td>
<td class="paramname"> </td>
<td> ) </td>
<td width="100%"> ( x + Glu->stack.used >= Glu->stack.size )</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="70ca807c578a0c495f7ce5edb0215e2b"></a><!-- doxytag: member="dmemory.c::TempSpace" ref="70ca807c578a0c495f7ce5edb0215e2b" args="(m, w)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">#define TempSpace </td>
<td>(</td>
<td class="paramtype">m, <tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">w </td>
<td class="paramname"> </td>
<td> ) </td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
<b>Value:</b><div class="fragment"><pre class="fragment">( (2*w + 4 + <a class="code" href="slu__util_8h.html#9b7b2a5116ee487722b0967317ab6360">NO_MARKER</a>) * m * <span class="keyword">sizeof</span>(<span class="keywordtype">int</span>) + \
(w + 1) * m * <span class="keyword">sizeof</span>(<span class="keywordtype">double</span>) )
</pre></div>
</div>
</div><p>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="1540850a622674131bd1ea6a4f91cd56"></a><!-- doxytag: member="dmemory.c::copy_mem_double" ref="1540850a622674131bd1ea6a4f91cd56" args="(int, void *, void *)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void copy_mem_double </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>howmany</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">void * </td>
<td class="paramname"> <em>old</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">void * </td>
<td class="paramname"> <em>new</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="b59eea34474da95fb3dc125400a1287e"></a><!-- doxytag: member="dmemory.c::copy_mem_int" ref="b59eea34474da95fb3dc125400a1287e" args="(int, void *, void *)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void copy_mem_int </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname">, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">void * </td>
<td class="paramname">, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">void * </td>
<td class="paramname"></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="eed250713fbfb3fac567d7a503774ccc"></a><!-- doxytag: member="dmemory.c::dallocateA" ref="eed250713fbfb3fac567d7a503774ccc" args="(int n, int nnz, double **a, int **asub, int **xa)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void dallocateA </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>n</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"> <em>nnz</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">double ** </td>
<td class="paramname"> <em>a</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int ** </td>
<td class="paramname"> <em>asub</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int ** </td>
<td class="paramname"> <em>xa</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="fe3104df9ace895f5332843534ae99b4"></a><!-- doxytag: member="dmemory.c::dexpand" ref="fe3104df9ace895f5332843534ae99b4" args="(int *prev_len,MemType type,int len_to_copy,int keep_prev,GlobalLU_t *Glu)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void * dexpand </td>
<td>(</td>
<td class="paramtype">int * </td>
<td class="paramname"> <em>prev_len</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="superlu__enum__consts_8h.html#bd31f838aefffa46191d0d7dc36a96b2">MemType</a> </td>
<td class="paramname"> <em>type</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"> <em>len_to_copy</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"> <em>keep_prev</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> * </td>
<td class="paramname"> <em>Glu</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="e2ca2ac5e9a763fd3f07487343e4522e"></a><!-- doxytag: member="dmemory.c::dLUMemInit" ref="e2ca2ac5e9a763fd3f07487343e4522e" args="(fact_t fact, void *work, int lwork, int m, int n, int annz, int panel_size, double fill_ratio, SuperMatrix *L, SuperMatrix *U, GlobalLU_t *Glu, int **iwork, double **dwork)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int dLUMemInit </td>
<td>(</td>
<td class="paramtype"><a class="el" href="superlu__enum__consts_8h.html#c785c8235480e5cfef9848d89c047c0a">fact_t</a> </td>
<td class="paramname"> <em>fact</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">void * </td>
<td class="paramname"> <em>work</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"> <em>lwork</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"> <em>m</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"> <em>n</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"> <em>annz</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"> <em>panel_size</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">double </td>
<td class="paramname"> <em>fill_ratio</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="structSuperMatrix.html">SuperMatrix</a> * </td>
<td class="paramname"> <em>L</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="structSuperMatrix.html">SuperMatrix</a> * </td>
<td class="paramname"> <em>U</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> * </td>
<td class="paramname"> <em>Glu</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int ** </td>
<td class="paramname"> <em>iwork</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">double ** </td>
<td class="paramname"> <em>dwork</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Memory-related.<p>
<pre>
For those unpredictable size, estimate as fill_ratio * nnz(A).
Return value:
If lwork = -1, return the estimated amount of space required, plus n;
otherwise, return the amount of space actually allocated when
memory allocation failure occurred.
</pre>
</div>
</div><p>
<a class="anchor" name="9aff5dfe301496ef7c9234789975c043"></a><!-- doxytag: member="dmemory.c::dLUMemXpand" ref="9aff5dfe301496ef7c9234789975c043" args="(int jcol, int next, MemType mem_type, int *maxlen, GlobalLU_t *Glu)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int dLUMemXpand </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>jcol</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"> <em>next</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="superlu__enum__consts_8h.html#bd31f838aefffa46191d0d7dc36a96b2">MemType</a> </td>
<td class="paramname"> <em>mem_type</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int * </td>
<td class="paramname"> <em>maxlen</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> * </td>
<td class="paramname"> <em>Glu</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
<pre>
Return value: 0 - successful return
> 0 - number of bytes allocated when run out of space
</pre>
</div>
</div><p>
<a class="anchor" name="a7d9129a2b0dc259ccccc8d6d2218cf8"></a><!-- doxytag: member="dmemory.c::dLUWorkFree" ref="a7d9129a2b0dc259ccccc8d6d2218cf8" args="(int *iwork, double *dwork, GlobalLU_t *Glu)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void dLUWorkFree </td>
<td>(</td>
<td class="paramtype">int * </td>
<td class="paramname"> <em>iwork</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">double * </td>
<td class="paramname"> <em>dwork</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> * </td>
<td class="paramname"> <em>Glu</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="0ae701a41439ca8af10604920e2f72ba"></a><!-- doxytag: member="dmemory.c::dLUWorkInit" ref="0ae701a41439ca8af10604920e2f72ba" args="(int m, int n, int panel_size, int **iworkptr, double **dworkptr, GlobalLU_t *Glu)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int dLUWorkInit </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>m</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"> <em>n</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"> <em>panel_size</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int ** </td>
<td class="paramname"> <em>iworkptr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">double ** </td>
<td class="paramname"> <em>dworkptr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> * </td>
<td class="paramname"> <em>Glu</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="5c9b1e24d07635068c014999d44672aa"></a><!-- doxytag: member="dmemory.c::dmemory_usage" ref="5c9b1e24d07635068c014999d44672aa" args="(const int nzlmax, const int nzumax, const int nzlumax, const int n)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int dmemory_usage </td>
<td>(</td>
<td class="paramtype">const int </td>
<td class="paramname"> <em>nzlmax</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const int </td>
<td class="paramname"> <em>nzumax</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const int </td>
<td class="paramname"> <em>nzlumax</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const int </td>
<td class="paramname"> <em>n</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="c8b6d99155644578a5e5542c32040cfe"></a><!-- doxytag: member="dmemory.c::doubleCalloc" ref="c8b6d99155644578a5e5542c32040cfe" args="(int n)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">double* doubleCalloc </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>n</em> </td>
<td> ) </td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="8f2b9305cb611c37e7f627da902451a8"></a><!-- doxytag: member="dmemory.c::doubleMalloc" ref="8f2b9305cb611c37e7f627da902451a8" args="(int n)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">double* doubleMalloc </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>n</em> </td>
<td> ) </td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="e94c561110fcc75c31cda89105fd0a6c"></a><!-- doxytag: member="dmemory.c::dQuerySpace" ref="e94c561110fcc75c31cda89105fd0a6c" args="(SuperMatrix *L, SuperMatrix *U, mem_usage_t *mem_usage)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int dQuerySpace </td>
<td>(</td>
<td class="paramtype"><a class="el" href="structSuperMatrix.html">SuperMatrix</a> * </td>
<td class="paramname"> <em>L</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="structSuperMatrix.html">SuperMatrix</a> * </td>
<td class="paramname"> <em>U</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="structmem__usage__t.html">mem_usage_t</a> * </td>
<td class="paramname"> <em>mem_usage</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
<pre>
mem_usage consists of the following fields:<ul>
<li>for_lu (float)
The amount of space used in bytes for the L data structures.</li><li>total_needed (float)
The amount of space needed in bytes to perform factorization.
</li></ul>
</pre>
</div>
</div><p>
<a class="anchor" name="aa5359da217b433b43bf6c8e2d29aa45"></a><!-- doxytag: member="dmemory.c::dSetRWork" ref="aa5359da217b433b43bf6c8e2d29aa45" args="(int m, int panel_size, double *dworkptr, double **dense, double **tempv)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void dSetRWork </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>m</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"> <em>panel_size</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">double * </td>
<td class="paramname"> <em>dworkptr</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">double ** </td>
<td class="paramname"> <em>dense</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">double ** </td>
<td class="paramname"> <em>tempv</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="cb29e96116d7b170d6f021a87a4763e6"></a><!-- doxytag: member="dmemory.c::dSetupSpace" ref="cb29e96116d7b170d6f021a87a4763e6" args="(void *work, int lwork, GlobalLU_t *Glu)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void dSetupSpace </td>
<td>(</td>
<td class="paramtype">void * </td>
<td class="paramname"> <em>work</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"> <em>lwork</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> * </td>
<td class="paramname"> <em>Glu</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
lwork = 0: use system malloc; lwork > 0: use user-supplied work[] space.
</div>
</div><p>
<a class="anchor" name="adb43e6ea6725f06d04704a1db3dc0be"></a><!-- doxytag: member="dmemory.c::dStackCompress" ref="adb43e6ea6725f06d04704a1db3dc0be" args="(GlobalLU_t *Glu)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void dStackCompress </td>
<td>(</td>
<td class="paramtype"><a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> * </td>
<td class="paramname"> <em>Glu</em> </td>
<td> ) </td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="8412c8f776ad7cfe599a5b601310fb8e"></a><!-- doxytag: member="dmemory.c::duser_free" ref="8412c8f776ad7cfe599a5b601310fb8e" args="(int, int, GlobalLU_t *)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void duser_free </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>bytes</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"> <em>which_end</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> * </td>
<td class="paramname"> <em>Glu</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="00f228f45bab7594bea821b70eedbf51"></a><!-- doxytag: member="dmemory.c::duser_malloc" ref="00f228f45bab7594bea821b70eedbf51" args="(int, int, GlobalLU_t *)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void * duser_malloc </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>bytes</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"> <em>which_end</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="structGlobalLU__t.html">GlobalLU_t</a> * </td>
<td class="paramname"> <em>Glu</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="61aaccf587a78d15d79c4cc79f80e8b0"></a><!-- doxytag: member="dmemory.c::ilu_dQuerySpace" ref="61aaccf587a78d15d79c4cc79f80e8b0" args="(SuperMatrix *L, SuperMatrix *U, mem_usage_t *mem_usage)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int ilu_dQuerySpace </td>
<td>(</td>
<td class="paramtype"><a class="el" href="structSuperMatrix.html">SuperMatrix</a> * </td>
<td class="paramname"> <em>L</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="structSuperMatrix.html">SuperMatrix</a> * </td>
<td class="paramname"> <em>U</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="structmem__usage__t.html">mem_usage_t</a> * </td>
<td class="paramname"> <em>mem_usage</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
<pre>
mem_usage consists of the following fields:<ul>
<li>for_lu (float)
The amount of space used in bytes for the L data structures.</li><li>total_needed (float)
The amount of space needed in bytes to perform factorization.
</li></ul>
</pre>
</div>
</div><p>
<a class="anchor" name="4c226087c09a94ff40b92b14fa46fc53"></a><!-- doxytag: member="dmemory.c::user_bcopy" ref="4c226087c09a94ff40b92b14fa46fc53" args="(char *, char *, int)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void user_bcopy </td>
<td>(</td>
<td class="paramtype">char * </td>
<td class="paramname">, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">char * </td>
<td class="paramname">, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
</div>
<hr size="1"><address style="text-align: right;"><small>Generated on Mon Nov 22 10:23:47 2010 for SuperLU by
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.5 </small></address>
</body>
</html>