Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re: Subroutine overhead in Perl

by saberworks (Curate)
on Nov 06, 2007 at 18:21 UTC ( [id://649304]=note: print w/replies, xml ) Need Help??


in reply to Subroutine overhead in Perl

Did you guys also time the startup of the java runtime?

Replies are listed 'Best First'.
Re^2: Subroutine overhead in Perl
by enemyofthestate (Monk) on Nov 06, 2007 at 18:40 UTC
    We just used /usr/bin/time to measure the over all execution time:
    $ time java -cp $CLASSPATH:. SudoKu d.txt $ time ./sudoku.pl <d.txt
      It has been a while since I have developed java code, but I think this means the java was already compiled, while the compile time was included in the perl.

        So? Aside that it's not entirely true — Java run-time engines typically compile Java bytecode into native code at run-time — it is not standard behaviour to run Java programs from their sources. Perl's developers made a choice to parse the source every time, and Java should not be penalized for it.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others having an uproarious good time at the Monastery: (6)
As of 2024-04-18 13:11 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found