Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re^2: Subroutine overhead in Perl

by enemyofthestate (Scribe)
on Nov 06, 2007 at 18:40 UTC ( #649314=note: print w/replies, xml ) Need Help??


in reply to Re: Subroutine overhead in Perl
in thread Subroutine overhead in Perl

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

Replies are listed 'Best First'.
Re^3: Subroutine overhead in Perl
by traveler (Parson) on Nov 07, 2007 at 00:03 UTC
    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.

        I'm sorry: I was probably not clear. The timing for 'java' does not include the 'javac' step, but the perl timing includes the conversion of source to code for the interpreter. I was just suggesting that the 'time' commands were not timing the same things.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://649314]
help
Chatterbox?
[marto]: it's good to know that things can always get worse :P
[hippo]: Ignorance can be bliss
[Corion]: hippo: Yeah - I'll just avoid the project lead :)
[Corion]: marto: Yeah, it helps with the perspective :-D

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (11)
As of 2017-07-26 08:13 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    I came, I saw, I ...
























    Results (385 votes). Check out past polls.