Perl performance issue

Discussion in 'Perl Misc' started by Cameron McCormack, Jul 27, 2005.

  1. Hi everyone.

    I am migrating my web/mail/svn/etc. servers from a computer connected to
    my ADSL at home, an old Athlon 800, to a hosted Celeron 2.4GHz machine.
    I found though that Perl runs much more slowly on the new machine and I
    really don't know why. The problem seems to show itself mostly when
    loading modules (though this could just be because there is lots of
    code in the modules).

    For example on my old machine:

    jet:~ $ for x in . . .; do time perl -MCPAN -e1; done

    real 0m0.167s
    user 0m0.158s
    sys 0m0.008s

    real 0m0.166s
    user 0m0.156s
    sys 0m0.009s

    real 0m0.167s
    user 0m0.159s
    sys 0m0.007s

    and on the new machine:

    arc:~ $ for x in . . .; do time perl -MCPAN -e1; done

    real 0m2.310s
    user 0m2.280s
    sys 0m0.030s

    real 0m2.320s
    user 0m2.270s
    sys 0m0.050s

    real 0m2.326s
    user 0m2.300s
    sys 0m0.030s

    Actually, even without loading the CPAN module there is an appreciable
    difference:

    port:~ $ for x in . . .; do time perl -e1; done

    real 0m0.009s
    user 0m0.004s
    sys 0m0.005s

    real 0m0.010s
    user 0m0.004s
    sys 0m0.006s

    real 0m0.009s
    user 0m0.005s
    sys 0m0.003s

    arc:/tmp $ for x in . . .; do time perl -e1; done

    real 0m0.069s
    user 0m0.060s
    sys 0m0.000s

    real 0m0.067s
    user 0m0.060s
    sys 0m0.000s

    real 0m0.069s
    user 0m0.060s
    sys 0m0.010s

    I did multiple tests to (hopefully) discount issues of disk speed. Both
    machines are using the same Debian package versions (5.8.7-4).

    Anyone know why this might be (with the little information I've given)
    or be able to help me diagnose the problem properly?

    Also, if there's a more appropriate forum for this question, please
    point me towards it.

    Thanks,

    Cameron

    --
    e-mail : cam (at) mcc.id.au icq : 26955922
    web : http://mcc.id.au/ msn : cam-msn (at) aka.mcc.id.au
    office : +61399055779 jabber : heycam (at) jabber.org
     
    Cameron McCormack, Jul 27, 2005
    #1
    1. Advertising

  2. Cameron McCormack

    brian d foy Guest

    In article <42e76687$>, Cameron McCormack wrote:

    > Hi everyone.
    >
    > I am migrating my web/mail/svn/etc. servers from a computer connected to
    > my ADSL at home, an old Athlon 800, to a hosted Celeron 2.4GHz machine.
    > I found though that Perl runs much more slowly on the new machine and I
    > really don't know why.


    Compare the two perl binary (perl -V) and see what's different
    about them. :)

    --
    brian d foy,
    Subscribe to The Perl Review: http://www.theperlreview.com
     
    brian d foy, Jul 27, 2005
    #2
    1. Advertising

  3. brian d foy wrote:
    > Compare the two perl binary (perl -V) and see what's different
    > about them. :)


    I did compare the output of 'perl -V' on both machines, and the only
    difference was that on my old machine there are a couple of extra paths
    in @INC.

    --
    e-mail : cam (at) mcc.id.au icq : 26955922
    web : http://mcc.id.au/ msn : cam-msn (at) aka.mcc.id.au
    office : +61399055779 jabber : heycam (at) jabber.org
     
    Cameron McCormack, Jul 28, 2005
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. dpackwood
    Replies:
    3
    Views:
    1,829
  2. jm
    Replies:
    1
    Views:
    519
    alien2_51
    Dec 12, 2003
  3. Paul
    Replies:
    1
    Views:
    160
    Tad McClellan
    May 20, 2004
  4. Replies:
    3
    Views:
    198
    Josef Moellers
    Nov 1, 2007
  5. Software Engineer
    Replies:
    0
    Views:
    348
    Software Engineer
    Jun 10, 2011
Loading...

Share This Page