timbunce / devel-nytprof

Devel::NYTProf is a powerful feature-rich source code profiler for Perl. (Mostly in maintenance mode, so PRs are much more likely to be acted upon than Issues.)
http://blog.timbunce.org/tag/nytprof/
67 stars 51 forks source link

nytprofhtml dies #122

Closed venupec closed 6 years ago

venupec commented 6 years ago

Hello,

First all thank you for developing this wonderful tool for code profiling. I've got immense insights wrt timing of each statement, sub etc.,

For major part nytprofhtml, nytprofcsv works fine. But in the following scenario, the process gets "Killed". Do you know why?

I'm trying to generate report from a nytprof.out that is more than 5 GB. The process fails with the following output. The report works fine for files of size in MBs.

Using Devel::NYTProf v5.06

HTML report

$ time nytprofhtml -m -profself -f nytprof.out.7719 -o /tmp/nytprof.7719_report
Reading nytprof.out.7719
Invoking load_profile_data_from_file() <--- i've added this is print
Killed

real    1m51.868s
user    0m37.727s
sys     0m8.354s

CSV report

$ time nytprofcsv -f nytprof.out.7719 -o /tmp/nytprof.7719_report
Generating CSV report...
Reading nytprof.out.7719
Invoking load_profile_data_from_file() <--- i've added this print 
Killed

real    2m36.551s
user    0m37.786s
sys     0m9.065s

I've set NYTPROF as the following:

$ echo $NYTPROF 
addpid=1:optimize=0:slowops=0:subs=0:stmts=0

On further debugging, i found this is failing in, load_profile_data_from_file() / load_profile_to_callback() calls in NYTProf.xs

Any help/pointers are much appreciated!! Also, is there any other method to generate the NYTProf report?

Thank you,

timbunce commented 6 years ago

You're probably running out of memory. Try googling for "why does my process get killed" (also "oom killer") Look in your system log (eg /var/log/messages) and you'll probably see more details. Closing this as not a NYTProf issue.