Re: [sv-bc] Assignment, incrementor and decrementor proposal


Subject: Re: [sv-bc] Assignment, incrementor and decrementor proposal
From: Dave Rich (David.Rich@synopsys.com)
Date: Sun Mar 16 2003 - 14:31:04 PST


Peter,

On 03/03/03 we also passed some changes to the third paragraph that need
to be incorporated into your proposal for some common terminology. Also
there are some other earlier passed changes that need to be incorporated
with your proposal.

IN DRAFT 3 SECTION 7.3
REPLACE OLD SENTENCE
"Assignment operators may only be used with blocking assignments"
WITH NEW
An assignment operator is semantically equivalent to a blocking
assignment, with the exception that any left hand side index expression
is only evaluated once. For example:

a[i]+=2; // same as a[i] = a[i] +2;

REPLACE THIRD PARAGRAPH WITH 2 NEW
The semantics of such an assignment expression are those of a function
which evaluates the right hand side, casts the right hand side to the
left hand data type, stacks it, updates the left hand side and returns
the stacked value. The type returned is the type of the left hand side
data type. If the left hand side is a concatenation, the type returned
shall be an unsigned integral value whose bit length is the sum of the
length of its operands.

It shall be illegal to include an assignment operator in an event
expression, in an expression within a procedural continuous assignment,
or in an expression that is not within a procedural statement.

SystemVerilog also includes the C incrementor and decrementor assignment
operators ++i, --i, i++, and i--. These do not need parentheses when
used in expressions. These increment and decrement assignment operators
behave as blocking assignments.

Peter Flake wrote:

> IN DRAFT 3 SECTION 7.3
> REPLACE OLD
> "Assignment operators may only be used with blocking assignments"
> WITH NEW
> An assignment operator is semantically equivalent to a blocking
> assignment, with the exception that any left hand side index expression
> is only evaluated once. For example:
> a[i]+=2; // same as a[i] = a[i] +2;
>
> REPLACE THIRD PARAGRAPH WITH 2 NEW
> The semantics of such an assignment expression are those of a function
> which evaluates the right hand side, casts the right hand side to the
> left hand data type, stacks it, updates the left hand side and returns
> the stacked value.
>
> SystemVerilog also includes the C incrementor and decrementor
> operators ++i, --i, i++, and i--. These do not need parentheses when
> used in expressions. These increment and decrement operations behave
> as blocking assignments.
>
>

-- 
--
Dave Rich
Principal Engineer, CAE, VTG
Tel:  650-584-4026
Cell: 510-589-2625
DaveR@Synopsys.com



This archive was generated by hypermail 2b28 : Sun Mar 16 2003 - 14:31:51 PST