develooper Front page | perl.perl5.porters | Postings from April 2014

Re: [perl #121230] process group kill on Win32 broken in 5.17.2,regression 5.18

Thread Previous | Thread Next
From:
demerphq
Date:
April 23, 2014 11:34
Subject:
Re: [perl #121230] process group kill on Win32 broken in 5.17.2,regression 5.18
Message ID:
CANgJU+UNNW_k4URft1zOfgE1QL3iC5+e8kj6YdNWtFr7Qv626A@mail.gmail.com
On 18 March 2014 13:46, H.Merijn Brand <h.m.brand@xs4all.nl> wrote:
> On Tue, 18 Mar 2014 13:15:11 +0100, demerphq <demerphq@gmail.com> wrote:
>
>> > The difference in parsing time between single and double quotes strings is
>> > infinitesimal
>>
>> IMO there is no point in worrying about these kind of things unless
>> the string is very long.
>
> And not even then. I benched it years ago on several machines, and all
> bench results are in line-noise margins and differ per architecture.
> IIRC all big-endian boxes I tried on had a <1% preference for double
> quotes whereas little-endian boxes prefered single quotes.

Well no, when the string becomes long it starts being interesting to
not use a quoted string, or to use single quoted here docs.

When I checked last Perl has non-linear and degrading performance
parsing strings. The longer the string the slower it gets.

In practice unless the string is quite long (hundreds to thousands of
characters) it is not something you need to worry about at all. On the
other hand if you happen to be dealing with a case where you are
generating code with lots of long quoted strings you can see real
parsing performance gains by removing the strings.

Yves

-- 
perl -Mre=debug -e "/just|another|perl|hacker/"

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