Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked

Re^2: Question about curious performance of if...elsif block

by markseger (Beadle)
on Jan 17, 2012 at 12:28 UTC ( #948309=note: print w/ replies, xml ) Need Help??

in reply to Re: Question about curious performance of if...elsif block
in thread Question about curious performance of if...elsif block

> Directly fetch and execute (if it exists) the specific subroutine that you want to execute.

For those of use who not only remember but actually used them, this sounds like fortran's computed goto statement. However in my case it's not that I want to execute different subs, but rather blocks of code. Can I do the same thing using labels? That really would make it a computed goto. ;)

However I would still like to hear any and all theories about why this curious behavior. The script in question is 'collectl', an opensouce project I released a number of years ago. It's a very light-weight system monitoring tool and am always looking for way to make it even lighter-weight and this feels like an opportunity.

On a different note, my comments about rhel6.2 were wrong. I forgot the VM has <100 processes so I'm actually executing have the number of tests and so the performance improvement over the earlier tests seems as little better but not that much better.


Comment on Re^2: Question about curious performance of if...elsif block

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (10)
As of 2016-02-09 16:10 GMT
Find Nodes?
    Voting Booth?

    How many photographs, souvenirs, artworks, trophies or other decorative objects are displayed in your home?

    Results (319 votes), past polls