Re: [sv-ac] Local variable question.


Subject: Re: [sv-ac] Local variable question.
From: John Havlicek (john.havlicek@motorola.com)
Date: Thu Apr 10 2003 - 08:20:39 PDT


Hi Adam:

I don't see a and y overlapping in

          (a, x = data) [*1:3] ## [1:2] y ##1 z == x

The ##[1:2] ensures at least 1 cycle delay from the cycle that
(a, x = data) [*1:3] finishes and the cycle that y is tested.

Let's look at

          (a, x = data) [*1:3] ##0 y

instead. I will assume that a and y may themselves depend on x.

On the first iteration of (a, x = data) [*1:3], x has not yet been sampled when
a is tested. If a depends on x, then the first test of a will use the previous
value of x, which should have been sampled before. If the first test of a
passes, then x will get the sampled value of data in the same cycle. If there
is a second iteration of (a, x = data) [*1:3], then the second test of a will
use the value of x sampled from data in the previous cycle. If this second
test passes, then x will be resampled from data in the current cycle. Similarly
if there is a third iteration.

Now, however many iterations of (a, x = data) [*1:3] there are, we are guaranteed
that the last one sampled x from data. In the same cycle as the last test of a
and the last sampling of x from data, we then test y. And if y depends on x, then
y will be tested with x equal to the value of data in the same cycle.

Thus, in the presence of fusion, the left-to-right order of the syntax
determines whether the sampling occurs before or after the test of a boolean
expression.

Best regards,

John H.

>
> Hi John;
>
> I was looking at the LRM and wondering about the definition of sampling
> for local variables in the presence of variable repeats and ranges.
> Consider these two examples:
>
>
> (a, x = data) [*1:3] ## [1:2] y ##1 z == x
>
> How would this work - considering overlapping conditions of a and y?
>
> a [*1:3] ## [1:2] y, x = data ##1 z == x
>
>
> Similar idea, different point - what data would you get?
> when there are overlaps in a and y?
>
>
>
>
>
> Adam Krolnik
> Verification Mgr.
> LSI LOgic Corp.
> Plano TX. 75074



This archive was generated by hypermail 2b28 : Thu Apr 10 2003 - 08:25:48 PDT