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 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
<== Date ==> <== Thread ==>

Subject: Re: registerRecordDeviceDriver.pl takes a long time to finish
From: Andrew Johnson <anj@aps.anl.gov>
To: <tech-talk@aps.anl.gov>
Date: Thu, 28 Sep 2017 09:46:53 -0500
Hi Luca,

I have been using NYTProf, it's a nice package, but I wasn't aware of
the addpid functionality, thanks for providing that hint.

The problem is that due to a change inside Perl to utilize Copy-On-Write
for large strings that was added between 5.18 and 5.20, the code in the
DBD Parser now appears to be triggering a lot of string copying when the
input DBD files are large. This shows up in the profiler output as large
amounts of time spent in CORE:match routines, that being the regexp
opcode that is used. I'm hoping to be able to avoid that behaviour by
passing references instead of copying the large string that holds the
file contents.

Thanks,

- Andrew


On 09/28/2017 03:00 AM, Luca Cavalli wrote:
> Hi,
> 
> can Perl profiling be of any help here?
> 
> install NYTProf Perl package, then build your IOC with:
> 
> $ export NYTPROF=addpid=1
> $ PERL5OPT=-d:NYTProf make
> 
> Locate the correct nytprof.out.<pid> and open it with
> 
> $ nytprofhtml -f nytprof.out.<pid> --open
> 
> Hope it helps,
> 
> Luca
> 
> 
> On Wed, 2017-09-27 at 12:15 +0200, Hinko Kocevar wrote:
>> Hi,
>>
>> Under 3.15.4 perl script execution takes a lot of time on Linux Mint,
>> while it executes in a jiffy on CentOS.
>> I added a time in front of the perl call in RULES.db:
>>
>>
>> time perl -CSD
>> /devel/root/R3.15.4/base/bin/linux-x86_64/registerRecordDeviceDriver.pl  
>> -I. -I.. -I../O.Common -I../../../dbd
>> -I/devel/root/R3.15.4/modules/adcore-master/dbd
>> -I/devel/root/R3.15.4/modules/adsimdetector-master/dbd
>> -I/devel/root/R3.15.4/modules/asyn-master/dbd
>> -I/devel/root/R3.15.4/modules/autosave-master/dbd
>> -I/devel/root/R3.15.4/modules/busy-master/dbd
>> -I/devel/root/R3.15.4/modules/calc-master/dbd
>> -I/devel/root/R3.15.4/modules/sscan-master/dbd
>> -I/devel/root/R3.15.4/base/dbd    -o
>> simDetectorApp_registerRecordDeviceDriver.cpp
>> ../O.Common/simDetectorApp.dbd
>> simDetectorApp_registerRecordDeviceDriver
>> /devel/stage/R3.15.4/iocs/simdetectorioc-master
>>
>>
>> 29.95user 0.02system 0:29.98elapsed 99%CPU (0avgtext+0avgdata
>> 19256maxresident)k
>>
>>
>> I think other calls to perl are awfully slow, too..
>> Any idea why it might be so slow?
>>
>> Thanks,
>> Hinko
>>
>  
> 
> ------------------------------------------------------------------------
> 
> 
> << Le informazioni contenute in questo messaggio di posta elettronica e
> relativi allegati sono riservate e confidenziali e ne è vietata la
> diffusione in qualunque modo eseguita. Qualora Lei non fosse la persona
> a cui il presente messaggio è destinato, La invitiamo ad eliminarlo e a
> darcene gentile comunicazione. Quanto precede ai fini del rispetto delle
> Legge 675/96 e del Decreto Legislativo 30/06/2003 n.196, sulla tutela
> dei dati personali >>
> 
> << This e-mail is confidential and may well also be legally privileged.
> If you have received it in error, you are on notice of its status.
> Please notify us immediately by reply e-mail and then delete this
> message from your system. Please do not copy it or use it for any
> purposes, or disclose its contents to any other person: to do so could
> be a breach of confidence. Thank you for your co-operation. Please
> contact our IT Helpdesk on +3902380481 or email it@cgspace.it if you
> need assistance >>
>  
> 

-- 
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

References:
registerRecordDeviceDriver.pl takes a long time to finish Hinko Kocevar
Re: registerRecordDeviceDriver.pl takes a long time to finish Luca Cavalli

Navigate by Date:
Prev: Question about the epics driver for PXIe-5162 high speed digitizer (National instruments) lzf neu
Next: Re: CA gatway runs away when zero length PV name in UDP search request Anton Derbenev
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
Navigate by Thread:
Prev: Re: registerRecordDeviceDriver.pl takes a long time to finish Luca Cavalli
Next: Record processing twice after upgrading to Base 3.15.5 Dunning, Michael
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
ANJ, 29 Sep 2017 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·