Sd-key-p
Keys are derived from wire names and are the basis of our skip
detection.
(sd-key-p x) is a defaggregate of the following fields.
- pat — The same as the wire name except that some embedded number (perhaps
spanning many digits) may have been replaced by a * character.
Invariant (stringp pat).
- index — The parsed value of the number that has been replaced, or nil
if no replacement was made.
Invariant (maybe-natp index).
- orig — The original wire name. This is somewhat unnecessary since it can be
recovered by just replacing * in pat with the characters
for index, but we thought it was convenient to keep around.
Invariant (stringp orig).
Source link: sd-key-p
The idea of keys is to cause related signals to have the same
pattern. For instance, bcWCB0Ent_P and bcWCB1Ent_P will both give
rise to the pattern bcWCB*Ent_P.
Because a particular wire name might include many numbers, we may generate a
list of keys for a single wire. For instance, for bcL2RB1NoRtry_P we will
generate one key with the pattern bcL*RB1NoRtry_P and another with the
pattern bcL2RB*NoRtry_P. We had previously considered using a list of
indices, but found it easier to just generate multiple keys, each with a single
index.
Subtopics
- Sd-key
- Raw constructor for sd-key-p structures.
- Make-sd-key
- Constructor macro for sd-key-p structures.
- Change-sd-key
- A copying macro that lets you create new sd-key-p structures, based on existing structures.
- Make-honsed-sd-key
- Constructor macro for honsed sd-key-p structures.
- Honsed-sd-key
- Raw constructor for honsed sd-key-p structures.
- Sd-key->index
- Access the index field of a sd-key-p structure.
- Sd-key->pat
- Access the pat field of a sd-key-p structure.
- Sd-key->orig
- Access the orig field of a sd-key-p structure.