The LRM says [size] means [0:size-1] Looks like 32-bit arithmetic to me. -- Brad -----Original Message----- From: owner-sv-bc@eda.org [mailto:owner-sv-bc@eda.org] On Behalf Of Gordon Vreugdenhil Sent: Tuesday, October 03, 2006 7:16 AM To: Bresticker, Shalom Cc: Greg Jaxon; SV_BC List Subject: Re: [sv-bc] logic A[ 2'b11<<1 ] Bresticker, Shalom wrote: > Let's see... > > "2'b11 << 1" is a self-determined expression. Yes, and the other key piece is that the rule for "i << j" is that the result width is L(i) so the width of "1" (32 bits) is immaterial. > That means that the result is 2'b10, i.e., 2. Yes. Gord. > > So it should be the same as > > logic A[2], > > which is the same as > > logic A{0:1]. > > So the answer to the question is, A has 2 elements, A[0] and A[1]. > > Shalom > > > >>-----Original Message----- >>From: owner-sv-bc@server.eda.org [mailto:owner-sv-bc@server.eda.org] > > On > >>Behalf Of Greg Jaxon >>Sent: Tuesday, October 03, 2006 11:13 AM >>To: SV_BC List >>Subject: [sv-bc] logic A[ 2'b11<<1 ] >> >>How many elements does A have? > > > -- -------------------------------------------------------------------- Gordon Vreugdenhil 503-685-0808 Model Technology (Mentor Graphics) gordonv@model.comReceived on Tue Oct 3 08:10:36 2006
This archive was generated by hypermail 2.1.8 : Tue Oct 03 2006 - 08:10:51 PDT