in reply to Re: Re: Re: RegExps, Prematch and Postmatch without efficiency penalty
in thread RegExps, Prematch and Postmatch without efficiency penalty

...you should do benchmark them in separate scripts.

This is similar to the problem I had trying to benchmark the memory footprint of threaded applications. See Benchmark::Thread::Size for an example of how I embedded scripts within scripts to get a clean memory benchmark. I think a similar (probably simpler) approach could be taken to benchmark alternate approaches to $`, $& and $'.

Liz

  • Comment on Re: Re: Re: Re: RegExps, Prematch and Postmatch without efficiency penalty

Replies are listed 'Best First'.
Re: Re: Re: Re: Re: RegExps, Prematch and Postmatch without efficiency penalty
by demerphq (Chancellor) on Sep 16, 2003 at 09:41 UTC

    for an example of how I embedded scripts within scripts to get a clean memory benchmark.

    I started work on a generic tool to do this as part of my OO::Benchmark stuff. Never got around to finishing it though.


    ---
    demerphq

    <Elian> And I do take a kind of perverse pleasure in having an OO assembly language...