FPGA Central - World's 1st FPGA / CPLD Portal

FPGA Central

World's 1st FPGA Portal

 

Go Back   FPGA Groups > NewsGroup > Verilog

Verilog comp.lang.verilog newsgroup / usenet

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 07-16-2003, 10:10 PM
David Jones
Guest
 
Posts: n/a
Default Parameter override types

I have a question about the rules in section 3.11.1 of Std-1364-2001 on p. 35.
Bottom bunch of paragraphs:

rule 3:
"A parameter with a type specification, but with no range specification,
shall be of the type specified. A signed parameter shall default to the
range of the final value assigned to the parameter, after any value overrides
have been applied."

rules 5/6:
"A parameter with no range specification, and with either a signed type
specification or no type specification, shall have..."

For a declaration of the form:

parameter signed foo = ...;

is rule 3 supposed to apply, or is one of rules 5/6 supposed to apply?


Reply With Quote
  #2 (permalink)  
Old 07-17-2003, 11:11 AM
Srinivasan Venkataramanan
Guest
 
Posts: n/a
Default Re: Parameter override types

Hi David,

"David Jones" <[email protected]> wrote in message
news:[email protected] .
> I have a question about the rules in section 3.11.1 of Std-1364-2001 on p.

35.
> Bottom bunch of paragraphs:
>
> rule 3:
> "A parameter with a type specification, but with no range specification,
> shall be of the type specified. A signed parameter shall default to the
> range of the final value assigned to the parameter, after any value

overrides
> have been applied."
>


So essentially it says that the parameter should be able to "hold" the
FINAL value (in terms of its range/size).

> rules 5/6:
> "A parameter with no range specification, and with either a signed type
> specification or no type specification, shall have..."
>


Taking Rule 5: looks to me like it just fine tunes what Rule 3 said, i.e.
the parameter LSB will be 0, MSB = final_value's size-1
Taking Rule 6: if the final value is unsized, then the minimus guaranteed
range is 31:0, is what I understand.

So, I think 3 & 5 or 3 & 6 will be applicable.

Did I miss some thing?

Thanks,
Srinivasan

> For a declaration of the form:
>
> parameter signed foo = ...;
>
> is rule 3 supposed to apply, or is one of rules 5/6 supposed to apply?
>
> --

Srinivasan Venkataramanan
Senior Verification Engineer
Software & Silicon Systems India Pvt Ltd. - an Intel company
Bangalore, India

http://www.noveldv.com http://www.deeps.org

I don't speak for Intel


Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 01:06 PM.


Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0
Copyright 2008 @ FPGA Central. All rights reserved