Surya: The treatment of "@" as an operator is a device for parsing. Therefore, you cannot deduce from the precedence assigned to "@" for the purpose of parsing or the groupings that result that the SVA example is wrong. You have to use a combination of parsing and semantic analysis, and you have to understand what are the artificial effects of your parsing devices. I know a number of tool teams have solved this problem already. Perhaps someone else watching the reflector can help you. Best regards, John H. > X-Authentication-Warning: server.eda.org: majordom set sender to owner-sv-ac@eda.org using -f > Date: Wed, 08 Mar 2006 19:19:29 +0530 > From: Surya Pratik Saha <spsaha@cal.interrasystems.com> > X-Accept-Language: en > Cc: sv-ac@eda.org > X-Virus-Status: Clean > Sender: owner-sv-ac@eda.org > X-OriginalArrivalTime: 08 Mar 2006 13:50:14.0164 (UTC) FILETIME=[39BAF540:01C642B7] > > <!doctype html public "-//w3c//dtd html 4.0 transitional//en"> > <html> > Hi John, > <br>Then I need to know the precedence of "@". That will automatically > distiguish the real parentheses and fake parentheses. > <p>Ed also mentioned in one of the mail that @ has the weakest precedence. > <p>I am not sure, the mail you got or not. > <p>But then considering @ as weakest the e.g. given will be parsed as I > mentioned by using parentheses. That is: > <br>@(posedge clk) a ##1 (@(posedge clk1) s1 |=> @(posedge clk2)s2); > <p>So the e.g. is wrong as I explained earlier. > <p>If otherwise, then can you tell me what it wants to mean by putting > explicit parenthesis there? > <p>John Havlicek wrote: > <blockquote TYPE=CITE>Hi Surya: > <p>I am not a parsing expert, but I think that you can treat "@" as > <br>an operator and make up a precedence for it for the purpose > <br>of reading it in. Not all choices may be equally good. > :) > <p>You have to distinguish "real" parentheses that were written > <br>in the property from "fake" ones that get introduced in parsing. > <p>Then you could go back over your parsed structure and figure > <br>out, according to the clock flow rules, what the scope of each > <br>clocking event is. > <p>Best regards, > <p>John H. > <p>> Sender: spsaha@cal.interrasystems.com > <br>> Date: Wed, 08 Mar 2006 18:42:25 +0530 > <br>> From: Surya Pratik Saha <spsaha@cal.interrasystems.com> > <br>> X-Accept-Language: en > <br>> CC: sv-ac@eda.org > <br>> X-OriginalArrivalTime: 08 Mar 2006 13:11:27.0485 (UTC) FILETIME=[CEEBEAD0:01C642B1] > <br>> > <br>> <!doctype html public "-//w3c//dtd html 4.0 transitional//en"> > <br>> <html> > <br>> Hi John, > <br>> <br>Even if I dont consider @ as operator, I have to know the > precedence > <br>> to implement sequence/property expression in an yacc file. And also > the > <br>> LRM has the following rule: > <br>> <p>property_expr ::= > <br>> <br>sequence_expr > <br>> <br>... > <br>> <br>| clocking_event property_expr > <br>> <p>So in which context an item will be reduced with "clocking_event > property_expr" > <br>> has to be well defined. > <br>> <p>LRM is not clear on that. > <br>> <p>John Havlicek wrote: > <br>> <blockquote TYPE=CITE>Surya: > <br>> <p>> Some days ago I asked the precedence of @ operator in assertion > rule. > <br>> <br>> I did not get well defined answer, however by reading the > clock flow > <br>> section, > <br>> <br>> it is understood that @ has the weakest precedence. > <br>> <p>Ed answered you that "@" is not an assertion expression operator, > <br>> <br>so your line of reasoning to deduce that the LRM example > <br>> <p>> @(posedge clk) a ##1 @(posedge clk1) s1 |=> @(posedge clk2) > s2; > <br>> <p>is wrong is flawed. > <br>> <p>I will repeat Ed's answer:&nbsp; in SVA, "@" is not an > expression > <br>> <br>operator. > <br>> <p>Best regards, > <br>> <p>John H. > <br>> <p>> X-Authentication-Warning: server.eda.org: majordom set sender > to owner-sv-ac@eda.org > <br>> using -f > <br>> <br>> Date: Wed, 08 Mar 2006 15:22:41 +0530 > <br>> <br>> From: Surya Pratik Saha &lt;spsaha@cal.interrasystems.com> > <br>> <br>> X-Accept-Language: en > <br>> <br>> X-Virus-Status: Clean > <br>> <br>> Sender: owner-sv-ac@eda.org > <br>> <br>> X-OriginalArrivalTime: 08 Mar 2006 09:55:09.0683 (UTC) FILETIME=[62CDF430:01C64296] > <br>> <br>> > <br>> <br>> &lt;!doctype html public "-//w3c//dtd html 4.0 transitional//en"> > <br>> <br>> &lt;html> > <br>> <br>> &amp;nbsp; > <br>> <br>> &lt;p>-------- Original Message -------- > <br>> <br>> &lt;table BORDER=0 CELLSPACING=0 CELLPADDING=0 > > <br>> <br>> &lt;tr> > <br>> <br>> &lt;th ALIGN=RIGHT VALIGN=BASELINE NOWRAP>Subject:&amp;nbsp;&lt;/th> > <br>> <br>> > <br>> <br>> &lt;td>Clock flow in SV assertion&lt;/td> > <br>> <br>> &lt;/tr> > <br>> <br>> > <br>> <br>> &lt;tr> > <br>> <br>> &lt;th ALIGN=RIGHT VALIGN=BASELINE NOWRAP>Date:&amp;nbsp;&lt;/th> > <br>> <br>> > <br>> <br>> &lt;td>Wed, 08 Mar 2006 10:28:44 +0530&lt;/td> > <br>> <br>> &lt;/tr> > <br>> <br>> > <br>> <br>> &lt;tr> > <br>> <br>> &lt;th ALIGN=RIGHT VALIGN=BASELINE NOWRAP>From:&amp;nbsp;&lt;/th> > <br>> <br>> > <br>> <br>> &lt;td>Surya Pratik Saha &amp;lt;spsaha@cal.interrasystems.com>&lt;/td> > <br>> <br>> &lt;/tr> > <br>> <br>> > <br>> <br>> &lt;tr> > <br>> <br>> &lt;th ALIGN=RIGHT VALIGN=BASELINE NOWRAP>To:&amp;nbsp;&lt;/th> > <br>> <br>> > <br>> <br>> &lt;td>"sv-bc@eda.org" &amp;lt;sv-bc@eda.org>, sv-ac@eda.org&lt;/td> > <br>> <br>> &lt;/tr> > <br>> <br>> &lt;/table> > <br>> <br>> > <br>> <br>> &lt;p>Hi, > <br>> <br>> &lt;br>Some days ago I asked the precedence of @ operator > in assertion > <br>> rule. > <br>> <br>> I did not get well defined answer, however by reading the > clock flow > <br>> section, > <br>> <br>> it is understood that @ has the weakest precedence. > <br>> <br>> &lt;p>Considering the fact the given e.g. in LRM (page > no. 282, e.g. > <br>> d) > <br>> <br>> &lt;p>@(posedge clk) a ##1 @(posedge clk1) s1 |=> @(posedge > clk2) > <br>> s2; > <br>> <br>> &lt;p>will be parsed as: > <br>> <br>> &lt;p>@(posedge clk) a ##1 (@(posedge clk1) s1 |=> @(posedge > clk2) > <br>> s2); > <br>> <br>> &lt;p>So (@(posedge clk1) s1 |=> @(posedge clk2) s2) > will become > <br>> a property > <br>> <br>> expression. > <br>> <br>> &lt;p>But as per assertion BNF, ## operator can not > have property > <br>> expression > <br>> <br>> in RHS. So the e.g. given in LRM is wrong. > <br>> <br>> &lt;p>Please confirm. > <br>> <br>> &lt;pre>--&amp;nbsp; > <br>> <br>> Regards > <br>> <br>> Surya.&lt;/pre> > <br>> <br>> &amp;nbsp;&lt;/html> > <br>> <br>></blockquote> > <br>> > <br>> <pre>--&nbsp; > <br>> Regards > <br>> Surya.</pre> > <br>> &nbsp;</html> > <br>></blockquote> > > <pre>-- > Regards > Surya.</pre> > </html> >Received on Wed Mar 8 06:05:26 2006
This archive was generated by hypermail 2.1.8 : Wed Mar 08 2006 - 06:06:01 PST