Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Can't run Devel::DProf on Text::CSV

by rhino (Novice)
on Jul 15, 2011 at 00:07 UTC ( [id://914458]=perlquestion: print w/replies, xml ) Need Help??

rhino has asked for the wisdom of the Perl Monks concerning the following question:

I'm not having any luck profiling a script that uses Text::CSV, and when I shorten it to just my "use" I get the following:
$ perl -d:DProf -e 'use Text::CSV' Can't call method "0" without a package or object reference at -e line + 1. Compilation failed in require at -e line 1. BEGIN failed--compilation aborted at -e line 1.
Funny thing is that its just fine with a "require":
$ perl -d:DProf -e 'require "/opt/perl/lib/site_perl/5.8.8/Text/CSV.pm +"'
Anybody got any ideas why this might be failing? Normally I'd just start up the debugger to see where its failing, but I'm not where to start in this case. Here are my versions:
This is perl, v5.8.8 built for alpha-dec_osf-thread-multi $Devel::DProf::VERSION = '20050603.00' $Text::CSV::VERSION = '1.10';
Thanks for the help!

Replies are listed 'Best First'.
Re: Can't run Devel::DProf on Text::CSV
by BrowserUk (Patriarch) on Jul 15, 2011 at 00:52 UTC

    As anonymonk pointed out, Dprof is known to be broken.

    Personally, I still find the fine-grained, concise, parsable numeric output from Devel::SmallProf infinitely more usable and useful than the course-grained, never-mind-the-quality-feel-the-width, look-at-the-pretty-pictures, overkill verbosity that NYTProf projectile vomits at me.

    YMMV.


    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority".
    In the absence of evidence, opinion is indistinguishable from prejudice.
Re: Can't run Devel::DProf on Text::CSV
by Tux (Canon) on Jul 15, 2011 at 07:12 UTC

    The fact that you are trying to profile Text::CSV implies that you are looking for more speed. The first thing to do is use Text::CSV_XS instead.

    As others already said, Devel::DProf is dead and gone, use Devel::NYTProf instead. Much better and gives you much more usable data.

    Last, Text::CSV is just a wrapper module. If you want to profile, profile the backend: Text::CSV_PP or Text::CSV_XS.


    Enjoy, Have FUN! H.Merijn
Re: Can't run Devel::DProf on Text::CSV
by Anonymous Monk on Jul 15, 2011 at 00:33 UTC

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://914458]
Approved by toolic
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (5)
As of 2024-04-18 05:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found