I
Ilya Kalistru
Guest
Hi,
I am learning SV after using VHDL for many years and have a question.
In VHDL I often declare signals this way:
signal cntr : natural range 0 to MaxCntrValue;
This allows me not to worry about number of bit in cntr, while I am sure that a synthesizer will use minimal sufficient number of them for the signal.
Is there a way in SV to make this trick? May be it can be done through a new type declaration or other way...
Or should I always use bit vectors with implicit declaration of number of bit in them?
I am learning SV after using VHDL for many years and have a question.
In VHDL I often declare signals this way:
signal cntr : natural range 0 to MaxCntrValue;
This allows me not to worry about number of bit in cntr, while I am sure that a synthesizer will use minimal sufficient number of them for the signal.
Is there a way in SV to make this trick? May be it can be done through a new type declaration or other way...
Or should I always use bit vectors with implicit declaration of number of bit in them?