<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
    <title></title>
  </head>
  <body bgcolor="#ffffff" text="#000000">
    Hi Mollie,<br>
    The amount that it wants to allocate that causes the error is<br>
    <span class="Apple-tab-span" style="white-space: pre;"></span>1345314216
    = 1345314216 / 1024^3 = 1.25 GB.<br>
    So I would try to start with replacing<br>
    <tt>arrmblsize = 40000000000;</tt><br>
    which is somehow getting transformed into 1345294336 (in the
    unpredictable way, as predicted). Actually, maybe it is predictable
    because if you take 40,000,000,000 modulo 2^31<tt></tt> then you get
    1,345,294,336. So instead, try <br>
    <tt>arrmblsize = 2147483647;<br>
    </tt>which is 2^32 - 1, and more than 50% greater than the level
    that caused the error.<br>
    <br>
    Unfortunately, just because that's where the error occurred doesn't
    mean that it won't want a lot more, so if 2^31 isn't enough for your
    model, then try 2^32 -1 just in case, and if that doesn't work, then
    I'm afraid that think that somebody who can compile ADMB after
    figuring out how to change the source code to allow greater inputs
    for this quantity will have to help you. Maybe one day we'll get it
    fixed to the point of being able to write <tt>arrmblsize = 2e8</tt>
    and then we won't get confused counting digits like this.<br>
    -Ian<br>
    <br>
    On 10/13/2010 07:41 PM, Mollie Brooks wrote:
    <blockquote cite="mid:138CB3D1-5647-4D3A-ACD5-5D000F842851@ufl.edu"
      type="cite">
      <div>Hello,</div>
      I'm still having trouble allocating memory. 
      <div>
        <div>You said "any value greater than 2^31 for any of these
          inputs will be truncated, rounded, or otherwise produce
          unpredictable results" </div>
        <div>So how do I allocate more than 2GB?</div>
        <div><br>
        </div>
        <div>In my TOP_OF_MAIN_SECTION I have</div>
        <div>
          <div><span class="Apple-tab-span" style="white-space: pre;"> </span>arrmblsize
            = 40000000000;</div>
          <div>Of course this gets truncated or rounded down.</div>
          <div>The program stops and I get this in my output file:</div>
          <div>
            <div><span class="Apple-tab-span" style="white-space: pre;">
              </span>1345314216>=1345294336</div>
            <div><span class="Apple-tab-span" style="white-space: pre;">
              </span> No memory for dvar_vectors</div>
            <div> <span class="Apple-tab-span" style="white-space: pre;">
              </span>Need to increase ARRAY_MEMBLOCK_SIZE parameter</div>
            <div><span class="Apple-tab-span" style="white-space: pre;">
              </span>In gradient_structure declaration</div>
            <div><br>
            </div>
            <div>thanks,</div>
            <div>Mollie</div>
            <div apple-content-edited="true"><br
                class="Apple-interchange-newline">
            </div>
            <br>
            <div>
              <div>On Sep 10, 2010, at 3:47 PM, Ian Taylor wrote:</div>
              <br class="Apple-interchange-newline">
              <blockquote type="cite">
                <div bgcolor="#ffffff" text="#000000"> Hi Mollie,<br>
                  This topic seems to be frequently asked about, so I'll
                  add something about it to the ADMB FAQ: <a
                    moz-do-not-send="true"
                    href="http://admb-project.org/documentation/faq">http://admb-project.org/documentation/faq</a><br>
                  This values should be in Bytes, so your arrmblsize =
                  800000000000 Bytes = 800000000000/(1024^2) = 762939.5
                  MB = 800000000000/(1024^3) = 745 GB, which is surely
                  more memory than your cluster has available.<br>
                  <br>
                  However, depending on the compiler, any value greater
                  than 2^31 for any of these inputs will be truncated,
                  rounded, or otherwise produce unpredictable results.
                  Allan Hicks and I did some work on this topic which is
                  available at <a moz-do-not-send="true"
                    href="http://admb-project.org/community/benchmarks/compilers">http://admb-project.org/community/benchmarks/compilers</a><br>
                  <br>
                  You can search the users list archives at: <a
                    moz-do-not-send="true" class="moz-txt-link-freetext"
                    href="http://groups.google.com/group/admb-users/">http://groups.google.com/group/admb-users/</a><br>
                  -Ian<br>
                  <br>
                  On 9/10/2010 12:11 PM, Mollie Brooks wrote:
                  <blockquote
                    cite="mid:B0F932FF-08D9-413C-BB2D-9A95974D28CB@ufl.edu"
                    type="cite">Hi all,
                    <div>I'm not very good at understanding hardware. </div>
                    <div>I'm running ADMB on a cluster and have to
                      specify how much memory to allocate.</div>
                    <div>If my ADMB code has the lines</div>
                    <div>
                      <div><span class="Apple-tab-span"
                          style="white-space: pre;"> </span>arrmblsize
                        = 800000000000;</div>
                      <div><span class="Apple-tab-span"
                          style="white-space: pre;"> </span>gradient_structure::set_GRADSTACK_BUFFER_SIZE(1.e7);</div>
                      <div><span class="Apple-tab-span"
                          style="white-space: pre;"> </span>gradient_structure::set_CMPDIF_BUFFER_SIZE(1.e7);</div>
                      <div><span class="Apple-tab-span"
                          style="white-space: pre;"> </span>gradient_structure::set_MAX_NVAR_OFFSET(5000);</div>
                      <div><span class="Apple-tab-span"
                          style="white-space: pre;"> </span>gradient_structure::set_NUM_DEPENDENT_VARIABLES(5000);</div>
                      <div><br>
                      </div>
                      <div>How do I translate this into Megabytes?</div>
                      <div>thanks,</div>
                      <div>Mollie</div>
                      <div><br>
                      </div>
                      <div apple-content-edited="true">
                        <div style="word-wrap: break-word;">
                          <div><span class="Apple-style-span"
                              style="font-size: 12px;">
                              <div>Mollie Brooks</div>
                              <div>Ph.D. Candidate</div>
                              <div>NSF IGERT Fellow</div>
                              <div>Biology Department</div>
                              <div>University of Florida</div>
                              <div><a moz-do-not-send="true"
                                  href="mailto:mbrooks@ufl.edu">mbrooks@ufl.edu</a></div>
                              <div><a moz-do-not-send="true"
                                  href="http://www.zoology.ufl.edu/mbrooks">www.zoology.ufl.edu/mbrooks</a></div>
                              <div><br>
                              </div>
                            </span></div>
                        </div>
                        <br class="Apple-interchange-newline">
                      </div>
                      <br>
                    </div>
                    <pre wrap=""><fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
Users mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:Users@admb-project.org">Users@admb-project.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://lists.admb-project.org/mailman/listinfo/users">http://lists.admb-project.org/mailman/listinfo/users</a>
</pre>
                  </blockquote>
                </div>
              </blockquote>
            </div>
            <br>
          </div>
        </div>
      </div>
    </blockquote>
  </body>
</html>