<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
  </head>
  <body bgcolor="#ffffff" text="#000000">
    Hi ADMB developers,<br>
    <br>
    In response to questions on the ADMB Users email list, I tried to
    write brief entry into the FAQ about memory use.<br>
    You can see what I came up with here: <a
      href="http://admb-project.org/documentation/faq#memory">http://admb-project.org/documentation/faq#memory</a>
    and please offer suggestions for changes if you want.<br>
    <br>
    I struggled with how to describe the units, given the issue noted in
    the ADMB User Manual:<br>
    <blockquote>-gbs N set GRADSTACK_BUFFER_SIZE<br>
      <br>
      This option has the same effect as using the gradient
      structure::set GRADSTACK BUFFER SIZE function in the code program
      code, but has the advantage that it can be done at run time. <b>Also
        note that the size is in bytes here whereas for the included
        code it is inchunks of about 36 bytes.</b><br>
    </blockquote>
    This seems to originate in section of code from <a
href="http://www.google.com/codesearch/p?hl=en#sZ0O2CjgkrU/trunk/src/nh99/xmodelm3.cpp">xmodelm3.cpp</a>:<br>
    <pre><span id="l531">    nopt=get_option_number(<span class="stx-string">"-gbs"</span>,
</span><span id="l532">      <span class="stx-string">"-gbs option needs positive integer -- ignored"</span>,ssz);
</span><span id="l533">    <span class="stx-keyword">if</span> (nopt&gt;-<span class="stx-number">1</span> &amp;&amp; ssz&gt;<span class="stx-number">0</span>) {
</span><span id="l534">      gradient_structure::set_GRADSTACK_BUFFER_SIZE
</span><span id="l535">        (ssz/<span class="stx-keyword">sizeof</span>(grad_stack_entry));
</span><span id="l536">    }
</span></pre>
    <span id="l536">Would it be possible to modify either than code (or
      <a
href="http://www.google.com/codesearch/p?hl=en#sZ0O2CjgkrU/trunk/src/linad99/gs_set.cpp">gs_set.cpp</a></span>)
    so that all these inputs are always in bytes? It seems like if it's
    necessary to allocated chunks related to the size of the gradstack
    entry, and thus the input in bytes got rounded to the nearest chunk,
    that would be still preferable to having totally different units
    depending on where you enter the values.<br>
    <br>
    -Ian<br>
    <span id="l536"></span><br>
    <br>
  </body>
</html>