Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  <20182019  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  <20182019 
<== Date ==> <== Thread ==>

Subject: RE: perl under
From: Hinko Kocevar <Hinko.Kocevar@esss.se>
To: "tech-talk@aps.anl.gov" <tech-talk@aps.anl.gov>, "anj@anl.gov" <anj@anl.gov>
Date: Mon, 8 Oct 2018 17:35:43 +0000
Hi Andrew,

works nice when applied to R3.15.5, too.

Thanks,
Hinko
 
-- 
Hinko Kocevar
Beam Diagnostics Engineer
European Spallation Source ERIC
P.O Box 176, SE-221 00 Lund, Sweden
Visiting address: Odarslövsvägen 113, 224 84 Lund
Mobile: +46-721-79 22 58
Phone:  +46-46-888 32 58
E-mail: hinko.kocevar@esss.se
Web:    www.esss.se
 

On 2018-10-08 19:12:16+02:00 tech-talk-bounces@aps.anl.gov wrote:

Hi Hinko,

On 10/08/2018 11:46 AM, Hinko Kocevar wrote:
&gt; Looking at this old post, 
&gt; https://epics.anl.gov/tech-talk/2017/msg01571.php, did you manage to
&gt; solve perl issues?
&gt; 
&gt; I'm using base R3.15.5. Maybe there is a temporary fix avoid long
&gt; waiting between IOC rebuild?

Yes, I modified the regular _expression_ to avoid the particular construct
that was causing the slow-up. This change will be in 3.15.6:

&gt; commit 32a6f6c4f1672d4c7b3a7008de89b9ed4eb97a04
&gt; Author: Andrew Johnson <anj@aps.anl.gov>
&gt; Date:   Mon Oct 9 14:45:01 2017 +0200
&gt; 
&gt;     Fix DBD parsing slow-up with Perl 5.20 and later
&gt; 
&gt; diff --git a/src/tools/DBD/Parser.pm b/src/tools/DBD/Parser.pm
&gt; index 9014206..113ef42 100644
&gt; --- a/src/tools/DBD/Parser.pm
&gt; +++ b/src/tools/DBD/Parser.pm
&gt; @@ -78,8 +78,13 @@ sub parseCommon {
&gt;          m/\G \s* /oxgc;
&gt;  
&gt;          # Extract POD
&gt; -        if (m/\G ( = [a-zA-Z] .* ) \n/oxgc) {
&gt; -            $obj-&gt;add_pod($1, &amp;parsePod);
&gt; +        if (m/\G ( = [a-zA-Z] )/xgc) {
&gt; +           # The above regex was split from the one below for performance.
&gt; +           # Using m/\G ( = [a-zA-Z] .* ) \n/ is slow in Perl 5.20 and later.
&gt; +           my $directive = $1;
&gt; +           m/\G ( .* ) \n/xgc;
&gt; +           $directive .= $1;
&gt; +            $obj-&gt;add_pod($directive, &amp;parsePod);
&gt;          }
&gt;          elsif (m/\G \# /oxgc) {
&gt;              if (m/\G \# ! BEGIN \{ ( [^}]* ) \} ! \# \# \n/oxgc) {

HTH,

- Andrew


-- 
Arguing for surveillance because you have nothing to hide is no
different than making the claim, "I don't care about freedom of
speech because I have nothing to say." -- Edward Snowdon
</anj@aps.anl.gov>

References:
perl under Hinko Kocevar
Re: perl under Johnson, Andrew N.

Navigate by Date:
Prev: Re: perl under Johnson, Andrew N.
Next: Re: No reply from device using asyn+streamdevice Eric Norum
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  <20182019 
Navigate by Thread:
Prev: Re: perl under Johnson, Andrew N.
Next: Git vulnerability: update your clients! Ralph Lange
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  <20182019 
ANJ, 09 Oct 2018 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·