Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Parser produces Out of Memory error on HP-UX but not on Windows XP

0 views
Skip to first unread message

Reiner Buehl

unread,
Aug 11, 2006, 6:58:44 AM8/11/06
to recde...@perl.org
Hi all,

on HP-UX, my Parse::RecDescent parser dies with an Out of Memory error.
If I run the same skript with the same input on a Windows XP system
(with
less Memory!) it works fine. I did check the ulimit values but could not
find any user-limitations. Is there a way to solve this?

Best regards,
Reiner.

Ron Smith

unread,
Aug 11, 2006, 2:01:25 PM8/11/06
to Buehl, Reiner (HPS EMEA GD-C&I), recde...@perl.org

I have encountered the same thing. There are two possible explanations:

You have a memory leak. This can come about when you create references
to lexical variables that go out of scope and you fail to clean them up.
If you have a pointer to a structure and both the pointer and
structure go out of scope, they cannot be garbage collected because the
structure's reference count never decrements to zero.

You are on the hairy edge of using all resources. The two platforms
allocate memory differently (and recall it is not the amount of memory
you have, it is the total size of the swap space). If it turns out that
HP-UX uses memory inefficiently in this case, you could easily find
yourself in a magic zone where a test case passes on one and fails on
the other.

I suspect the memory leak. That was always my problem...

Dominique Dumont

unread,
Aug 21, 2006, 9:03:46 AM8/21/06
to recde...@perl.org

As far as I recall, on HP-UX kernel limits the memory consumed by a
process to 64 MB (this amount may have changed with recent HPUX).

You can increase this amount by setting one of the kernel parameter
and recompile the kernel (in fact a small part of the kernel).

HTH

--
Dominique Dumont
"Delivering successful solutions requires giving people what they
need, not what they want." Kurt Bittner

0 new messages