Re: $sv-ec Proposal for Random Constraints for SV-extension


Subject: Re: $sv-ec Proposal for Random Constraints for SV-extension
From: Adam Krolnik (krolnik@lsil.com)
Date: Wed Nov 20 2002 - 09:09:26 PST


Good morning Mehdi;

I have a few questions for you about the proposal.

1. Rand vs randc type modifiers.

I have referred to the 'randc' functionality as 'unique'. Maybe this would be
an easier to explain. The functionality is the same. Choose a number uniquely,
do not reselect a number until all numbers have been chosen. Then start over.

So you have random, and unique selection methods. Why do you not include these
models as functional operations.

    stepping (through a list of elements.)
    sequence (initial value, expression to compute new value each time called.)

These are useful with setting up things in a declarative fashion (similar to
the random value setup.)

Section 19. Random functions.

I am somewhat confused on how the random functions work. The current verilog model
requires one to use $random() and pass in a seed with each call to obtain values
derived from that random stream. If one uses another seed value, a different
stream is created. Is this the same model for these functions? Or do they
use the seed from the current thread/object unless specified otherwise.

Why does $urandom() accept a seed value? You may have answered this above.

If one wanted to seed a given run by passing in a value so that each simulation
would be different if the seed is different, what would one have to do
so that each user of random numbers would have a base of this seed? Would only
one $srandom() call be sufficient? Or would each object/thread have to do this?

    Thanks.

    Adam Krolnik
    Verification Mgr.
    LSI Logic Corp.
    Plano TX. 75074



This archive was generated by hypermail 2b28 : Wed Nov 20 2002 - 09:10:18 PST