VHDL Issue Number: 0095 Classification: Language Definition Problem Language Version: VHDL-87 Summary: Composite resolved signals undefined with subelement null transaction. Related Issues: Relevant LRM Sections: 2.4, 12.6.1 Key Words and Phrases: Null transaction, resolved signal, composite signal Current Status: ISAC-Approved 1076-1993 Disposition: Closed (All Issues Completely Addressed) Disposition Rationale: Section 12.6.2 completely addresses the issue. Superseded By: N/A ----------------------- Date Submitted: 1989/02/10 Author of Submission: Doug Dunlop Author's Affiliation: Intermetrics, Inc. Author's Post Address: 4733 Bethesda Ave #415 Bethesda, MD 20814 Author's Phone Number: (301) 657-3775 Author's Fax Number: Author's Net Address: dunlop@inmet.inmet.com ----------------------- Date Analyzed: 1990/10/01 Author of Analysis: Doug Dunlop Revision Number: $Revision: 1.7 $ Date Last Revised: $Date: 1995/05/13 19:34:42 $ Description of Problem ---------------------- If a source of a composite guarded resolved signal has some subelement sources defined by a null transaction and some not defined by a null transaction, the LRM does not specify what should be passed to the resolution function for this source. Proposed Resolution ------------------- For each source of a composite guarded resolved signal the subelement sources must be either all determined by a null transaction or none determined by a null transaction. VASG-ISAC Analysis & Rationale ------------------------------ The problem described above does appear to be a flaw in the definition of the language. There are several possible ways of addressing this problem. First, the "partially null" source could somehow be passed into the resolution function. This approach is problematic because it introduces a number of difficulties such as how the resolution function would detect a partially null source and what value would be obtained if it read a partially null source. A second approach is to declare a partially null source to be completely null, i.e., the source would not be represented in the input to the resolution function. A disadvantage with this approach is that a partially null source can be viewed as an indication of suspicious behavior and is possibly a symptom of a model flaw. Hence we favor a third approach which is to declare a partially null source to be an error condition. Note that many vendors treat simulation-time errors by announcing the error, taking corrective action, and proceeding with the simulation. A reasonable corrective action in this case is to treat the partially null source as though it were completely null. In attempting to precisely state the desired semantics for resolved signals, the following additional difficulties have become apparent: (a) The definition of the driving value of a signal (LRM 12.6.1) does not accurately take into account composite resolved signals; in particular, no distinction is made between composite resolved signals and composite non-resolved signals. This seems contrary to the intent behind resolved signals. (b) The definition of the driving value of a signal does not explicitly cover register signals. Register signals are explained toward the end of LRM 12.6.1 but the definition of signal driving values is misleading since it does not distinguish these signals. (c) There appear to be two different definitions for the driving value of a resolved signal that has no sources. By the first element of the four- element list near the bottom of Page 12-10, the resolution function is not invoked for such a signal. But the fourth element of this list also seems to apply and in this case the resolution function determines the driving value of the signal. The way the list elements are worded suggests that it was the intent that this case be covered exclusively by the first list element. VASG-ISAC Recommendation for IEEE Std 1076-1987 ----------------------------------------------- The following is the proposed LRM-style wording to correct these problems. This text is intended to be a replacement for the LRM 12.16.1 paragraphs beginning "For a scalar signal S, ..." on Page 12-10 (including the four- element list), "For a composite signal R, ..." (which immediately follows), and "For any signal other than one declared with the signal kind *register*" (near the end of Page 12-11). For the purpose of defining the driving value of a signal, the notion of a basic signal is introduced. Basic signals are those whose driving values imply the driving values for all other signals. A basic signal is one satisfying the following properties: o It is either a scalar signal or a resolved signal, and o It is not a subelement of a resolved signal. The driving value of any basic signal B is determined as follows: o If B has no source, then the driving value of B is given by the default value associated with B (see Section 4.3.1.2). o If B has one source that is a driver and B is not a resolved signal (see Section 4.3.1.2), then the driving value of B is the value of that driver. o If B has one source that is a port and B is not a resolved signal, then the driving value of B is the driving value of the formal part of the association element that associates B with that port (see Section 4.3.3.2). The driving value of a formal part is obtained by evaluating the formal part, using the driving value of the signal denoted by the formal designator in place of the formal designator. o If B is a resolved signal and has one or more sources, the driving values of the sources of B are examined. It is an error if any of these driving values are a composite where one or more subelement values are determined by the null transaction (see Section 8.3.1) and one or more subelement values are not determined by the null transaction. If B is of signal kind *register* and all the sources of B have values determined by the null transaction, then the driving value of B is unchanged. Otherwise, the driving value of B is obtained by executing the resolution function associated with B, where that function is called with an input parameter consisting of the concatenation of the driving values of the sources of B, with the exception of the value of any source of B whose current value is determined by a null transaction. The driving value of any non-basic signal S is determined as follows: o If S is a subelement of a resolved signal R, the driving value of S is the corresponding subelement value from the driving value of R. o Otherwise (S is a non-resolved composite signal), the driving value of S is equal to the aggregate of the driving values of each of the basic subelements of S. NOTE: The definition of the driving value of a basic signal exhausts all cases with the exception of a non-resolved signal with more than one source. This condition is declared to be an error in Section 4.3.1.2. VASG-ISAC Recommendation for Future Revisions --------------------------------------------- (1) There are several potential issues related to the computation of signal driving values that are not addressed by this IR. These need to be reviewed with the next revision of the standard: (a) What is the driving value of the formal part of the association whose formal part is a linkage port or subelement or slice of a linkage port? Does it matter that this is not defined? (b) The definition above concerning an unresolved signal with one source that is a port makes use of the VHDL87 LRM sentence: The driving value of a formal part is obtained by evaluating the formal part, using the driving value of the signal denoted by the formal designator in place of the formal designator. As some find this sentence confusing, it should be reviewed. Clearly the intent is to take the driving value of the formal port (the formal designator), apply any type conversion on the formal side, and make this result the new driving value of the actual signal. (c) Is a REGISTER signal active when its last driver turns off? Would it be inconsistent if it were active at this point but yet its resolution function did not run? (2) Consider whether the V7.2 notion of "atomicity" should be put back in the language. Notice a V7.2 atomic signal is very similar to the notion of a "basic" signal discussed above.