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

From: Greg Jaxon <Greg.Jaxon@synopsys.com>
Date: Wed May 05 2010 - 14:58:42 PDT
Since the LHS (result) type informs both arms of the conditional, the solution for fixed width
types should be the same as if you'd used explicit casts (bitwise blending, right?).

For the more complex cases, I'm not sure there are real benefits.  But consider that section 11.4.14.1
gives formulae for concatenating any kind of operand into a stream.  It seems to me that if you
can concatenate, you could certainly blend the two arguments to a concatenation operator.

I admit that the resizing rules would be perverse and the blending rule might be obsolete in this
new context.  It isn't a high-priority musing, just an exercise.

Steven Sharp wrote:
I also wonder if ?: can be used for stream selection, since it can pass down 
    
assignment pattern type info.


What would you do if the selector was unknown?


Steven Sharp   |   Architect   |   Cadence

P: 508.459.1436   M: 774.535.4149   www.cadence.com


  

--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean. Received on Wed May 5 14:59:06 2010

This archive was generated by hypermail 2.1.8 : Wed May 05 2010 - 15:01:51 PDT