Re: FW: [sv-bc] RE: [sv-ec] Are variable-width part selects already part of the SV language? (Mantis 2684)

From: Gordon Vreugdenhil <gordonv@model.com>
Date: Fri May 07 2010 - 16:16:39 PDT

In terms of what we could reasonably do without huge impact,
I agree with Dave.

<soap box mode>

I am still horribly uncomfortable with the tendency of
1800 development to be willing to accept "localized language
hacks" to solve problems. This kind of proposal continues
to exacerbate the many special rules, exceptions, caveats, and
gotchas which drive many users crazy.

Unfortunately, the "gotta have the feature" philosophy is
the dominant one in the committees. I understand that such
language feature hacks solve a point problem, but I continue to
fear for the long-term future of the mess that we are creating.

Ok, back to work...

<end soap box mode>

Gord.

Rich, Dave wrote:
> John,
>
> I believe that most people on the committee seem to converging on
> enhancement where a variable width part select would be OK in the
> context of a cast, a concatenation, or streaming operator where the
> resulting type is determined by the context of an assignment to the
> destination type. So if you had
>
> bit [127:0] A,B;
> int N;
>
> A = {A[127:N],B[N-1:0]}; // would be legal
> A = {A[127:N],B[N-1:0]} + 1; // should never be legal
> A = type(A)'(A[127:N]) + 128'(B[N-1:0]); // would be legal
>
>
> We'll need a few more rules about out-of-range and reverse index
> ordering, but I'd wait until we get an actual proposal before spending
> more time on this.
>
>
> Dave

-- 
--------------------------------------------------------------------
Gordon Vreugdenhil                                503-685-0808
Model Technology (Mentor Graphics)                gordonv@model.com
-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
Received on Fri May 7 16:16:57 2010

This archive was generated by hypermail 2.1.8 : Fri May 07 2010 - 16:19:40 PDT