Thanks all, got many ideas from you..

My script took ~7 min to run with data file of ~50,000 lines with
substr()/unpack() enabled and same script took ~2 min after disabling
substr()/unpack().
That led me to the conclusion that substr/unpack is taking maximum of my
time (and that I should reduce).

I have updated changes like using "@_" instead of "shift",  with very small
performance improvement.

For "Devel::NYTProf", I need to check if my SA if he will allow me to
install.

Thanks again for your responses.

Regards,
Kavita :-)


On Thu, Apr 11, 2013 at 12:01 AM, Rob Dixon <rob.di...@gmx.com> wrote:

> On 10/04/2013 16:45, Bob goolsby wrote:
>
>> G'Mornin' Kavita --
>>
>> Before you go off on a goose chase, how do you know that substr() is going
>> to be a problem for you?  Have you bench-marked it?  If your file is as
>> large as you say, I strongly suspect that your bottleneck is going to be
>> I/O and any differences between unpack() and substr() will be lost in the
>> noise band below 1%.
>>
>
> Hint:
>
> Try adding
>
>   return "";
>
> as the first statement of `extractFieldValue` (i.e. so that it does
> nothing and returns a null string) then run your program and see how
> long it takes just doing the IO.
>
> Rob
>

Reply via email to