Dear Monks (and Anyone Else, Including Heathens):

I tried using system() to run an MS-DOS-based program from within Perl. But this program aborts--apparently because it doesn't have enough memory available to it.

Typing MEM at the DOS prompt shows that without Perl running I have a little conventional memory (639K total = 60K used + 579K free) and a bit more extended (XMS) memory (39,936K total = 2,112K used + 37,824K free). Executing system("MEM") from within a Perl script implies that Perl uses up a little conventional memory (values change to 639K total = 188K used + 451K free) and essentially all of the extended memory (values change to 39,936K total = 39,936K used + 0K free).

If Perl is using up all of my extended memory, is there any way of telling it not to be so greedy? Or is this apparent memory problem caused by another constraint of running Perl under DOS?

Thanks.


In reply to Is (DOS-)Perl a Memory Hog? by Neuroactive

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.