[sv-bc] RE: [sv-ec] Query for Array of instance Unrolling

From: Bresticker, Shalom <shalom.bresticker_at_.....>
Date: Mon May 05 2008 - 00:51:26 PDT
The LRM says (22.3.3.5 in Draft 5):

"For an unpacked array port, the port and the array connected to the
port must shall have the same number of unpacked dimensions, and each
dimension of the port must shall have the same size as the corresponding
dimension of the array being connected.

..

If the port connection is an unpacked array, the slowest varying
unpacked array dimensions of each port connection shall be compared with
the dimensions of the instance array. If they match exactly in size,
each element of the port connection shall be matched to the port left
index to left index, right index to right index.
If they do not match it shall be considered an error." 

Those conditions are not fulfilled in this example, so it should be an
error.

Beyond that, 7.6 says,

"A packed array cannot be directly assigned to an unpacked array without
an explicit cast."

Here if you would partition array A into 8 parts, you would get that
each individual instance of leaf has a connection of a 4-bit packed
array to a 2-element packed array of 2-bit elements, so it would still
not be legal.
  
Shalom

> -----Original Message-----
> From: owner-sv-ec@server.eda.org 
> [mailto:owner-sv-ec@server.eda.org] On Behalf Of Moumita
> Sent: Monday, May 05, 2008 10:31 AM
> To: sv-bc; sv-ec
> Subject: [sv-ec] Query for Array of instance Unrolling
> 
> Hello,
> 
> Array of instance unrolling for port connection of array 
> having both packed and unpacked dimensions is valid or not?.
> SV LRM 1800-2005 does not say anything  regarding this mixed case.
> So my query is whether following testcase is valid or not?
> 
> module top ;
> wire [3:0]A[0:1][0:1][0:1];
> leaf l1[0:7] (A);
> endmodule
> 
> module leaf(input wire [1:0]B[0:1]);
> endmodule
> 
> Some standard  simulators show errors for this above testcase 
> and some don't.
> 
> Thanks and regards,
> 
> Moumita
> 
> 
> 
> --
> This message has been scanned for viruses and dangerous 
> content by MailScanner, and is believed to be clean.
> 
> 
---------------------------------------------------------------------
Intel Israel (74) Limited

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.


-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
Received on Mon May 5 00:52:57 2008

This archive was generated by hypermail 2.1.8 : Mon May 05 2008 - 00:53:15 PDT