Search code examples
perlmemoryheap-memoryvalgrind

Profiling heap memory usage on perl programs


I have written a perl program to operate on huge datasets. I am trying to profile its excution in terms of its memory usage. Tried using valgrind on small datasets, but it slows down the execution dramatically. I am looking for just heap profiling. Could you guys suggest some ways ?


Solution

  • When I used Google and the search term 'perl memory profile', one of the first items points to the Perl module Devel::Size as one way of spotting memory usage. There are also memory leak detector modules lurking around.