Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Electronic Equipment > VHDL > Re: Globally st...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 2 of 8 Topic 6103 of 6417
Post > Topic >>

Re: Globally static expression

by Andy <jonesandy@[EMAIL PROTECTED] > Jun 23, 2008 at 06:13 AM

On Jun 23, 7:41 am, "ALu...@[EMAIL PROTECTED]
" <ALu...@[EMAIL PROTECTED]
> wrote:
> Hi,
>
> I am using the following globally static expression:
>
> CASE ((InputAddressRegisterReg(13 DOWNTO 1) & '0') AND
> cREGADDRGeneralRangeMask) IS
> ....
>
> When trying to compile that VHDL module with Modelsim I get the error
> message:
> Error: f:/sim/sim_msd/../../Src/Src_rtl/ProcInterface/
> ProcInterface.vhd(930): (vcom-1014) Array type case expression must be
> of a locally static subtype.
>
> When putting it to synthesis with Synplify it is no problem at all.
> Hardware is working fine.
> So how can I solve that simulation "mismatch" ?
>
> Rgds
> Andre

Assign a variable with that expression, and use the variable in the
case statement.

Because the language defines the case statement as requiring mutually
exclusive and exhaustive choices, the compiler has to "know"  the size
of your expression in the case statement, at compile time. The "and"
function return type is an unconstrained vector, and is defined in a
package, so the compiler does not know how wide the vector is when it
compiles this file, so the compiler cannot guarantee mutual exclusive
and exhaustive choices. Putting it in a container (variable) that is
known solves the problem.

The synthesis tool (synplify) should not accept the code either; enter
a bug re****t.

Andy
 




 8 Posts in Topic:
Globally static expression
"ALuPin@[EMAIL PROTE  2008-06-23 05:41:21 
Re: Globally static expression
Andy <jonesandy@[EMAIL  2008-06-23 06:13:04 
Re: Globally static expression
"ALuPin@[EMAIL PROTE  2008-06-23 06:57:49 
Re: Globally static expression
KJ <kkjennings@[EMAIL   2008-06-23 07:37:24 
Re: Globally static expression
"ALuPin@[EMAIL PROTE  2008-06-23 07:52:00 
Re: Globally static expression
KJ <kkjennings@[EMAIL   2008-06-23 09:23:42 
Re: Globally static expression
"ALuPin@[EMAIL PROTE  2008-06-24 00:55:22 
Re: Globally static expression
"ALuPin@[EMAIL PROTE  2008-06-24 01:28:50 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Mon Dec 1 14:24:55 CST 2008.