|
Message
From: John Sheahan <jrsheahan@o...>
Date: Thu, 24 Apr 2003 20:15:29 +1000
Subject: Re: [oc] Adder issues ?
On Thu, Apr 24, 2003 at 04:40:05PM +0800, NansonHuang@I... wrote:
> Now if we would like to
> implement the function such as c=a+ 11'h001(a constant) or the negation of
> a, -a(i.e ~a+1'b1), do we code that as the above coding style c=a+11'h001
> in the RTL ?
IMHO its poor style to bury magic numbers in the RTL.
Should be a named parameter.
> Will the synthesizer optimize it instead of area occupation X
depends on how good the synthesizer is and what speed/area goals it
is given. DC will certainly optimize this if it is told to firmly
enough. If the constant assignment is in a different module, you have
to be very firm.
john
|
 |