develooper Front page | perl.perl5.porters | Postings from February 2013

Re: OP_PADSV_NOLV

Thread Previous | Thread Next
From:
Steffen Mueller
Date:
February 27, 2013 21:33
Subject:
Re: OP_PADSV_NOLV
Message ID:
512E7B92.1040907@cpan.org
On 02/27/2013 09:59 PM, chromatic wrote:
> On Wednesday, February 27, 2013 08:50:59 PM Nicholas Clark wrote:
>
>> Yes, I thought this. I certainly tried it for one of the ops a long time
>> ago. I hit exactly the problem you did - I couldn't measure the difference.
>
> The only worthwhile approach I've ever found is to count the instructions
> executed by callgrind. Even that varies--especially as it's instructions for a
> fake processor--but dramatic improvements make themselves visible.

That and running things in a hot loop in a separate process over and 
over again, then looking at a histogram of the results. Very 
unscientific, but again, significant things tend to stand out. Human 
intuition (particularly when trained a bit) is quite good at spotting 
such differences.

Anyway: Callgrind not (yet) done in this case. But any difference is 
still going to be small. Callgrind probably also doesn't really 
highlight cost of branch (mis-)prediction fairly, does it?
Actually, on this one, maybe cachegrind is at least as interesting.

--Steffen

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About