pumax__stub_8c_source.html 9.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml">
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
  5. <title>PUMA: /Users/home/WC/puma/src/pumax_stub.c Source File</title>
  6. <link href="tabs.css" rel="stylesheet" type="text/css"/>
  7. <link href="doxygen.css" rel="stylesheet" type="text/css" />
  8. <link href="navtree.css" rel="stylesheet" type="text/css"/>
  9. <script type="text/javascript" src="jquery.js"></script>
  10. <script type="text/javascript" src="resize.js"></script>
  11. <script type="text/javascript" src="navtree.js"></script>
  12. <script type="text/javascript">
  13. $(document).ready(initResizable);
  14. </script>
  15. <link href="search/search.css" rel="stylesheet" type="text/css"/>
  16. <script type="text/javascript" src="search/search.js"></script>
  17. <script type="text/javascript">
  18. $(document).ready(function() { searchBox.OnSelectItem(0); });
  19. </script>
  20. </head>
  21. <body>
  22. <div id="top"><!-- do not remove this div! -->
  23. <div id="titlearea">
  24. <table cellspacing="0" cellpadding="0">
  25. <tbody>
  26. <tr style="height: 56px;">
  27. <td id="projectlogo"><img alt="Logo" src="puma103.jpg"/></td>
  28. <td style="padding-left: 0.5em;">
  29. <div id="projectname">PUMA
  30. &#160;<span id="projectnumber">219</span>
  31. </div>
  32. <div id="projectbrief">Portable University Model of the Atmosphere</div>
  33. </td>
  34. </tr>
  35. </tbody>
  36. </table>
  37. </div>
  38. <!-- Generated by Doxygen 1.7.5.1 -->
  39. <script type="text/javascript">
  40. var searchBox = new SearchBox("searchBox", "search",false,'Search');
  41. </script>
  42. <div id="navrow1" class="tabs">
  43. <ul class="tablist">
  44. <li><a href="index.html"><span>Main&#160;Page</span></a></li>
  45. <li><a href="annotated.html"><span>Data&#160;Types&#160;List</span></a></li>
  46. <li class="current"><a href="files.html"><span>Files</span></a></li>
  47. <li>
  48. <div id="MSearchBox" class="MSearchBoxInactive">
  49. <span class="left">
  50. <img id="MSearchSelect" src="search/mag_sel.png"
  51. onmouseover="return searchBox.OnSearchSelectShow()"
  52. onmouseout="return searchBox.OnSearchSelectHide()"
  53. alt=""/>
  54. <input type="text" id="MSearchField" value="Search" accesskey="S"
  55. onfocus="searchBox.OnSearchFieldFocus(true)"
  56. onblur="searchBox.OnSearchFieldFocus(false)"
  57. onkeyup="searchBox.OnSearchFieldChange(event)"/>
  58. </span><span class="right">
  59. <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
  60. </span>
  61. </div>
  62. </li>
  63. </ul>
  64. </div>
  65. <div id="navrow2" class="tabs2">
  66. <ul class="tablist">
  67. <li><a href="files.html"><span>File&#160;List</span></a></li>
  68. <li><a href="globals.html"><span>File&#160;Members</span></a></li>
  69. </ul>
  70. </div>
  71. </div>
  72. <div id="side-nav" class="ui-resizable side-nav-resizable">
  73. <div id="nav-tree">
  74. <div id="nav-tree-contents">
  75. </div>
  76. </div>
  77. <div id="splitbar" style="-moz-user-select:none;"
  78. class="ui-resizable-handle">
  79. </div>
  80. </div>
  81. <script type="text/javascript">
  82. initNavTree('pumax__stub_8c.html','');
  83. </script>
  84. <div id="doc-content">
  85. <div class="header">
  86. <div class="headertitle">
  87. <div class="title">/Users/home/WC/puma/src/pumax_stub.c</div> </div>
  88. </div>
  89. <div class="contents">
  90. <a href="pumax__stub_8c.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="preprocessor">#include &lt;sys/resource.h&gt;</span>
  91. <a name="l00002"></a>00002
  92. <a name="l00003"></a><a class="code" href="pumax__stub_8c.html#ae945943e7c586e54246713808c69e529">00003</a> <span class="keywordtype">void</span> <a class="code" href="pumax__stub_8c.html#ae945943e7c586e54246713808c69e529">pumax_dummy</a>(<span class="keywordtype">void</span>) {}
  93. <a name="l00004"></a>00004
  94. <a name="l00005"></a><a class="code" href="pumax__stub_8c.html#a495f2e0742e95d86d37335ea01a248a1">00005</a> <span class="keywordtype">int</span> <a class="code" href="pumax_8c.html#a495f2e0742e95d86d37335ea01a248a1">nresources_</a>(<span class="keywordtype">double</span> *ut, <span class="keywordtype">double</span> *st, <span class="keywordtype">long</span> *mem, <span class="keywordtype">long</span> *par, <span class="keywordtype">long</span> *paf,
  95. <a name="l00006"></a>00006 <span class="keywordtype">long</span> *swa, <span class="keywordtype">long</span> *dr, <span class="keywordtype">long</span> *dw)
  96. <a name="l00007"></a>00007 {
  97. <a name="l00008"></a>00008 <span class="keyword">struct </span>rusage ru;
  98. <a name="l00009"></a>00009 getrusage(RUSAGE_SELF,&amp;ru);
  99. <a name="l00010"></a>00010 *ut = ru.ru_utime.tv_sec + 0.000001 * ru.ru_utime.tv_usec;
  100. <a name="l00011"></a>00011 *st = ru.ru_stime.tv_sec + 0.000001 * ru.ru_stime.tv_usec;
  101. <a name="l00012"></a>00012 *mem = ru.ru_maxrss;
  102. <a name="l00013"></a>00013 *par = ru.ru_minflt;
  103. <a name="l00014"></a>00014 *paf = ru.ru_majflt;
  104. <a name="l00015"></a>00015 *swa = ru.ru_nswap;
  105. <a name="l00016"></a>00016 *dr = ru.ru_inblock;
  106. <a name="l00017"></a>00017 *dw = ru.ru_oublock;
  107. <a name="l00018"></a>00018 <span class="keywordflow">return</span> 1;
  108. <a name="l00019"></a>00019 }
  109. <a name="l00020"></a>00020
  110. <a name="l00021"></a>00021 <span class="comment">/* ------------------------------------------------ */</span>
  111. <a name="l00022"></a>00022 <span class="comment">/* Stub routines for Absoft Compiler and others, */</span>
  112. <a name="l00023"></a>00023 <span class="comment">/* which require, that FORTRAN callable C-functions */</span>
  113. <a name="l00024"></a>00024 <span class="comment">/* are written in uppercase letters only */</span>
  114. <a name="l00025"></a>00025 <span class="comment">/* ------------------------------------------------ */</span>
  115. <a name="l00026"></a>00026
  116. <a name="l00027"></a>00027
  117. <a name="l00028"></a><a class="code" href="pumax__stub_8c.html#a7856e9415ba484949a3cefeac70c1c8c">00028</a> <span class="keywordtype">int</span> <a class="code" href="pumax_8c.html#a7856e9415ba484949a3cefeac70c1c8c">NRESOURCES</a>(<span class="keywordtype">double</span> *ut, <span class="keywordtype">double</span> *st, <span class="keywordtype">long</span> *mem, <span class="keywordtype">long</span> *par, <span class="keywordtype">long</span> *paf,
  118. <a name="l00029"></a>00029 <span class="keywordtype">long</span> *swa, <span class="keywordtype">long</span> *dr, <span class="keywordtype">long</span> *dw)
  119. <a name="l00030"></a>00030 {
  120. <a name="l00031"></a>00031 <span class="keywordflow">return</span> <a class="code" href="pumax_8c.html#a495f2e0742e95d86d37335ea01a248a1">nresources_</a>(ut,st,mem,par,paf,swa,dr,dw);
  121. <a name="l00032"></a>00032 }
  122. <a name="l00033"></a>00033
  123. <a name="l00034"></a>00034 <span class="comment">/* ------------------------------------------------ */</span>
  124. <a name="l00035"></a>00035 <span class="comment">/* Stub routines for IBM Compiler and others, */</span>
  125. <a name="l00036"></a>00036 <span class="comment">/* which require, that FORTRAN callable C-functions */</span>
  126. <a name="l00037"></a>00037 <span class="comment">/* are written in lowercase without underscore */</span>
  127. <a name="l00038"></a>00038 <span class="comment">/* ------------------------------------------------ */</span>
  128. <a name="l00039"></a>00039
  129. <a name="l00040"></a>00040
  130. <a name="l00041"></a><a class="code" href="pumax__stub_8c.html#a7e885dd959a1c4e56017782911c1f796">00041</a> <span class="keywordtype">int</span> <a class="code" href="pumax_8c.html#a7e885dd959a1c4e56017782911c1f796">nresources</a>(<span class="keywordtype">double</span> *ut, <span class="keywordtype">double</span> *st, <span class="keywordtype">long</span> *mem, <span class="keywordtype">long</span> *par, <span class="keywordtype">long</span> *paf,
  131. <a name="l00042"></a>00042 <span class="keywordtype">long</span> *swa, <span class="keywordtype">long</span> *dr, <span class="keywordtype">long</span> *dw)
  132. <a name="l00043"></a>00043 {
  133. <a name="l00044"></a>00044 <span class="keywordflow">return</span> <a class="code" href="pumax_8c.html#a495f2e0742e95d86d37335ea01a248a1">nresources_</a>(ut,st,mem,par,paf,swa,dr,dw);
  134. <a name="l00045"></a>00045 }
  135. </pre></div></div>
  136. </div>
  137. <div id="nav-path" class="navpath">
  138. <ul>
  139. <li class="navelem"><a class="el" href="pumax__stub_8c.html">pumax_stub.c</a> </li>
  140. <!-- window showing the filter options -->
  141. <div id="MSearchSelectWindow"
  142. onmouseover="return searchBox.OnSearchSelectShow()"
  143. onmouseout="return searchBox.OnSearchSelectHide()"
  144. onkeydown="return searchBox.OnSearchSelectKey(event)">
  145. <a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Defines</a></div>
  146. <!-- iframe showing the search results (closed by default) -->
  147. <div id="MSearchResultsWindow">
  148. <iframe src="javascript:void(0)" frameborder="0"
  149. name="MSearchResults" id="MSearchResults">
  150. </iframe>
  151. </div>
  152. <li class="footer">Generated on Wed Sep 21 2011 12:35:46 for PUMA by
  153. <a href="http://www.doxygen.org/index.html">
  154. <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.5.1 </li>
  155. </ul>
  156. </div>
  157. </body>
  158. </html>