large memory usage by perl .so modules?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



Under Centos 5.5 on an x86_64 box I am seeing large memory usage
associated with perl .so modules.

Example: this script:

#!/usr/bin/perl
use Time::HiRes;

open(SMAPS, "/proc/$$/smaps");
while (<SMAPS>) {
  if (m/^\d/) {
    chomp($lib = (split(' ', $_))[5]);
  } elsif (m/^Size:\s*(\d+.*)/) {
    my $size = $1;
    print "$size $lib\n" if ($lib =~ m/HiRes/);
  }
}

produces this output:

24 kB /usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi/auto/Time/HiRes/HiRes.so
2044 kB /usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi/auto/Time/HiRes/HiRes.so
4 kB /usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi/auto/Time/HiRes/HiRes.so

What is this 2044 kB entry? On a 32-bit Centos 5.4 box the same script emits:

20 kB /usr/lib/perl5/5.8.8/i386-linux-thread-multi/auto/Time/HiRes/HiRes.so
4 kB /usr/lib/perl5/5.8.8/i386-linux-thread-multi/auto/Time/HiRes/HiRes.so

The 2044 kB entry seems to be counted towards memory usage as reported by ps.

Thanks!
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos


[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux