[sv-ec] RE: soft constraint proposal

From: Dhiraj Goswami <Dhiraj.Goswami@synopsys.com>
Date: Tue Sep 27 2011 - 14:09:52 PDT

I agree with Ray and Arturo's response.

Regards,
Dhiraj

From: owner-sv-ec@eda.org [mailto:owner-sv-ec@eda.org] On Behalf Of Arturo Salz
Sent: Tuesday, September 27, 2011 2:03 PM
To: Ryan, Ray; Francoise Martinolle; Arturo Salz; Gran, Alex; 'sv-ec@eda.org'
Subject: [sv-ec] RE: soft constraint proposal

I'm in complete agreement with Ray's response. In short:

1) Your example shoed three soft constraints

2) A "soft dist" will discard the constraint if it causes a (membership) conflict

3) If calling the function leads to a conflict then the soft constraint may be discarded

                Arturo

From: Ryan, Ray [mailto:Ray_Ryan@mentor.com]
Sent: Tuesday, September 27, 2011 1:12 PM
To: Francoise Martinolle; Arturo Salz; Gran, Alex; 'sv-ec@eda.org'
Subject: RE: soft constraint proposal

Francoise,

I added comments below giving my opinion on answering your questions.

Regards,
Ray

From: Francoise Martinolle [mailto:fm@cadence.com]
Sent: Tuesday, September 27, 2011 9:37 AM
To: Arturo Salz; Ryan, Ray; Gran, Alex; 'sv-ec@eda.org'
Subject: RE: soft constraint proposal

Arturo,

I have received some comments/issues from our randomization experts this morning.
Could you reply to these comments and I will forward them immediately.

Thanks

Hi Francoise.

I have some questions:

"disable soft constraint_primary" is used to disable previous soft constraints on that variable. If the soft constraint has multiple variables, is it disabled or not? If those other variables are state variables vs rand variables vs rand variables which are temporarily state variables? The text seems to imply that only soft constraints on the single named variable are disabled.

Ø For "disable soft X;", any soft constraint with a lower priority (ie previous) that contains a reference to 'X' will be disabled (discarded). It doesn't matter whether 'X' is the only random variable in the discarded soft constraint.

Ø A related question might be what happens if 'X' is a state variable (or disabled by rand_mode). IMHO it doesn't matter whether 'X' is a random variable or a state variable (for "disable soft 'X').

Is this legal?

constraint c1 { if ( a < b ) then soft b < 20;

else if ( a > b ) then soft b > 20;

else soft b < 20; }

If it is (BNF implies this) then does this mean we cannot treat the two copies of "b < 20" as common subexpressions? Are there really three soft constraints here, with well-defined priority? Currently we treat this as a single constraint expression across the RNC interface.

Ø This is legal.

Ø Technically, there are 3 soft constraints with different soft priorities. In this case I suspect an optimization could treat "b < 20" as a common sub-expression.
However for:
               Constraint C2 {
                  if (a < b) then {
                      soft b > 20;
                  } else if (a > b) {
                      soft b > 20;
                      b < x;
                 } else {
                      b > 20;
                 }
                  x < 10;
              }
In this case, the second "soft b > 20" should be discarded because it conflicts with "b < x; x < 10" when (a > b).

What is a "soft" dist constraint? If it is part of a conflict, I assume we ignore it altogether, not just the weight expressions (some of which may be zero and thus cause the contradiction).

Ø A soft dist constraint is discarded if:

o The 'inside' part of the dist conflicts with a higher priority constraint.

o There is a higher priority "disable soft" for any variable referenced in the soft dist constraint.

If a soft constraint contains a function call which causes it to be difficult to solve (but to the user has an obvious solution) are we allowed to fail, or do we discard that soft constraint after some amount of effort?

Ø The function priority (18.5.11) still applies to 'soft' constraint. So any random variables that occur as an actual to the function call can be solved (assigned values) prior to consideration of the soft constraint that contains the function call. The function is then evaluated for the given argument values. If the soft constraint cannot be met using the function return value the soft constraint can be discarded. (A soft constraint never causes a randomize call to fail). BTW, there is nothing in the LRM that prohibits you from applying more effort to try and meet the soft constraint.

-- Petr

--
This message has been scanned for viruses and
dangerous content by MailScanner<http://www.mailscanner.info/>, and is
believed to be clean.
-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
Received on Tue Sep 27 14:10:48 2011

This archive was generated by hypermail 2.1.8 : Tue Sep 27 2011 - 14:10:52 PDT