EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  <20192020  2021  2022  2023  2024  Index 2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  <20192020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: Re: EPICS 7.0.2.1 release preparation
From: "Johnson, Andrew N. via Core-talk" <[email protected]>
To: Dirk Zimoch <[email protected]>, "[email protected]" <[email protected]>
Date: Wed, 8 May 2019 21:39:03 +0000
On 5/8/19 7:54 AM, Dirk Zimoch wrote:
On 07.05.19 19:58, Johnson, Andrew N. wrote:
and for every link field (DB or CA) it performs a record-name lookup on the PV name in that link (which requires calculating a hash of the name and checking the names in that hash bucket, which may have several records in it so does several string comparisons, most of which are going to fail).

I don't think so. I do epicsStrGlobMatch(), but that does not look up records by name or calculate hashes. Still it fails on most records, of course. Like dbgrep does. I don't think that I can avoid the glob match, even when iterating target records instead of links, but the number of matches performed may be smaller. In particular when I only check records that are known to have links pointing to them.
Ah, sorry I didn't notice that your match and alt_match variables were inputs to the code, I thought you were looking up record names there and didn't read that code too closely.

If you use the new BKLNK field in the record you will still have to look through every record instance, but for each record you immediately know how many DB links point back to this record, which in most cases will be a small number or 0.

Yes, that may shortcut things. Unfortunately it does not give me the name of the link field. But searching the record were the link came from is not too difficult.
There might be more than one link between the two records, so don't give up the scan after you find the first one. The lockset code doesn't care how many links there are beyond one, so it doesn't count them for you.

Now this doesn't give you CA links
Which is a pity. I understand why, as it was implemented to handle lock sets. But for my use case it would be really helpful to get all types of links.
The problem is you can only look inside the DB and CA links because they are defined in the code IOC code so you have access to all their internals. To support any external link types you'd have to interface to it by calling some routine provided by the link type. We can add routines to the Link Support Entry Table in the future if we want to though, given a specific need.

Can you tell me what link type PN_LINK is? It seems to be used only in dev*SoftCallback.c but I found no documentation about it.
It's a "Process Notify" link, where there is an asynchronous connection between two records using the dbNotify subsystem (that's the code that implements the ca_put_callback() mechanism inside the IOC). Only our "Async Soft Channel" input device support currently creates these, the "Async Soft Channel" output device support currently uses a CA link instead (but implementing that using a PN_LINK should be relatively straightforward if we need it).

The idea for an input record is to to be able to trigger processing on the target record but not actually fetch the value from the field pointed to until after all that processing has finished.

- Andrew

-- 
Complexity comes for free, Simplicity you have to work for.

References:
EPICS 7.0.2.1 release preparation Michael Davidsaver via Core-talk
Re: EPICS 7.0.2.1 release preparation Dirk Zimoch via Core-talk
Re: EPICS 7.0.2.1 release preparation Johnson, Andrew N. via Core-talk
Re: EPICS 7.0.2.1 release preparation Dirk Zimoch via Core-talk
Re: EPICS 7.0.2.1 release preparation Dirk Zimoch via Core-talk
Re: EPICS 7.0.2.1 release preparation Johnson, Andrew N. via Core-talk
Re: EPICS 7.0.2.1 release preparation Dirk Zimoch via Core-talk

Navigate by Date:
Prev: Re: EPICS 7.0.2.1 release preparation Dirk Zimoch via Core-talk
Next: Build failed in Jenkins: epics-base-3.15-sol #188 APS Jenkins via Core-talk
Index: 2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  <20192020  2021  2022  2023  2024 
Navigate by Thread:
Prev: Re: EPICS 7.0.2.1 release preparation Dirk Zimoch via Core-talk
Next: Build failed in Jenkins: EPICS-3.14 #245 Jenkins EPICS PSI via Core-talk
Index: 2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  <20192020  2021  2022  2023  2024 
ANJ, 09 May 2019 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·