Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

Ovid (2709)

Ovid
  (email not shown publicly)
http://publius-ovidius.livejournal.com/
AOL IM: ovidperl (Add Buddy, Send Message)

Stuff with the Perl Foundation. A couple of patches in the Perl core. A few CPAN modules. That about sums it up.

Journal of Ovid (2709)

Sunday March 28, 2004
02:21 PM

Memory Usage

[ #18099 ]

Assuming that I don't want to recompile Perl with -DDEBUGGING_MSTATS, what's the easiest way to determine memory usage on RH9 Linux (RAM and swap)? Is it to manually read the /proc/$$/statm file?

I'm playing around with tail recursion techniques and it looks like goto &code is leaking memory. This appears to be a known issue, even though perl561delta lists this problem as fixed and I'm using 5.8.0 (yeah, I know. I need to upgrade).

Update: Eh, what the heck. This is a test box, so I'm upgrading to 5.9.1 and adding -DPERL_DEBUGGING_MSTATS anyway. Of course, reading the source reveals that the problem appears to be fixed, but we'll see.

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.
  • Has a memory test that you can enable with an environment variable. It uses /proc/self/statm for the data. It's unportable but it works.