[sv-cc] LRM Changes for Chapter 27 of 3.1 "SystemVerilog Assertion API" (UPDATED: 12/5/03)


Subject: [sv-cc] LRM Changes for Chapter 27 of 3.1 "SystemVerilog Assertion API" (UPDATED: 12/5/03)
From: Bassam Tabbara (bassam@novas.com)
Date: Wed Dec 10 2003 - 10:29:15 PST


 
 
**Please view this in html form so it is very easy to see the change,
otherwise just read the new**

LRM Changes for Chapter 27 of 3.1 "SystemVerilog Assertion API":

1) p. 249

OLD:
typedef struct t_vpi_source_info {

PLI_BYTE* *fileName;

PLI_INT32 startLine;

PLI_INT32 startColumn;

PLI_INT32 endLine;

PLI_INT32 endColumn;

} s_vpi_source_info, *p_vpi_source_info;

typedef struct t_vpi_assertion_info {

PLI_BYTE8 *name; /* name of assertion */

vpiHandle instance; /* instance containing assertion */

PLI_BYTE8 defname; /* name of module/interface containing assertion

*/

vpiHandle clock; /* clocking expression */

PLI_INT32 assertionType; /* vpiSequenceType, ... */

s_vpi_source_info sourceInfo;

} s_vpi_assertion_info, *p_vpi_assertion_info;

int vpi_get_assertion_info (assert_handle, p_vpi_assertion_info);

NEW

typedef struct t_vpi_source_info {

PLI_BYTE8 *fileName;

PLI_INT32 startLine;

PLI_INT32 startColumn;

PLI_INT32 endLine;

PLI_INT32 endColumn;

} s_vpi_source_info, *p_vpi_source_info;

typedef struct t_vpi_assertion_info {

PLI_BYTE8 *assertName; /* name of assertion */

vpiHandle instance; /* instance containing assertion */

PLI_BYTE8 *defName; /* name of module/interface containing assertion */

vpiHandle clock; /* clocking expression */

PLI_INT32 assertionType; /* vpiSequenceType, vpiAssertType,
vpiCoverType, vpiPropertyType,

                            vpiImmediateAssertType */

s_vpi_source_info sourceInfo;

} s_vpi_assertion_info, *p_vpi_assertion_info;

PLI_INT32 vpi_get_assertion_info (assert_handle, p_vpi_assertion_info);

2) p. 251:

OLD:

vpiHandle vpi_register_assertion_cb(

vpiHandle, /* handle to assertion */

PLI_INT32 reason, /* reason for which callbacks needed */

PLI_INT32 (*cb_rtn)( /* callback function */

PLI_INT32 reason,

vpiHandle assertion,

p_vpi_attempt_info info,

PLI_BYTE8 *userData ),

PLI_BYTE8 *user_data /* user data to be supplied to cb */

);

typedef struct t_vpi_assertion_step_info {

PLI_INT32 matched_expression_count;

vpiHandle *matched_exprs; /* array of expressions */

p_vpi_source_info *exprs_source_info; /* array of source info */

PLI_INT32 stateFrom, stateTo;/* identify transition */

} s_vpi_assertion_step_info, *p_vpi_assertion_step_info;

typedef struct t_vpi_attempt_info {

union {

vpiHandle failExpr;

p_vpi_assertion_step_info step;

} detail;

s_vpi_time attemptTime,

} s_vpi_attempt_info, *p_vpi_attempt_info;

 NEW:

vpiHandle vpi_register_assertion_cb(

vpiHandle assertion, /* handle to assertion */

PLI_INT32 reason, /* reason for which callbacks needed */

PLI_INT32 (*cb_rtn)( /* callback function */

PLI_INT32 reason, /* callback reason */
p_vpi_time cb_time, /* callback time */
vpiHandle assertion,

p_vpi_attempt_info info,

PLI_BYTE8 *userData ),

PLI_BYTE8 *user_data /* user data to be supplied to cb */

);

typedef struct t_vpi_assertion_step_info {

PLI_INT32 matched_expression_count;

vpiHandle *matched_exprs; /* array of expressions */

p_vpi_source_info *exprs_source_info; /* array of source info */

PLI_INT32 stateFrom, stateTo;/* identify transition */

} s_vpi_assertion_step_info, *p_vpi_assertion_step_info;

typedef struct t_vpi_attempt_info {

union {

vpiHandle failExpr;

p_vpi_assertion_step_info step;

} detail;

s_vpi_time attemptStartTime; /* Time attempt triggered */

} s_vpi_attempt_info, *p_vpi_attempt_info;

3) p. 252

OLD:

The callback function shall be supplied the following arguments:

1) the reason for the callback

2) the handle for the assertion

3) a pointer to an attempt information structure

4) a reference to the user data supplied when the callback was placed.

The attempt information structure contains details relevant to the
specific event that occurred.

- On disable, enable, reset and kill events, the info field is absent (a
NULL pointer is given as the value

of info).

- On start and success events, only the attempt time field is valid.

- On a failure event, the attempt time and detail.failExpr are valid.

- On a step callback, the attempt time and detail.step elements are
valid.

NEW:

The callback function shall be supplied the following arguments:

1) the reason for the callback
2) a pointer to the time of the callback

3) the handle for the assertion

4) a pointer to an attempt information structure

5) a reference to the user data supplied when the callback was
registered.

The attempt information structure contains details relevant to the
specific callback that occurred.

- On disable, enable, reset and kill callbacks, the info field is NULL.

- On start and success callbacks, only the attemptStartTime field is
valid.

- On a failure callback, the attemptStartTime and detail.failExpr are
valid.

- On a step callback, the attemptStartTime and detail.step are valid.

4) p. 253:

OLD:

Usage example: vpi_control(vpiAssertionKill, assertionHandle, attempt)

vpiAssertionKill

discards the given attempts, but leaves the assertion enabled and does
not reset any state used by this

assertion (e.g., past() sampling).

Usage example: vpi_control(vpiAssertionDisableStep, assertionHandle,
attempt)

vpiAssertionDisableStep

disables step callbacks for this assertion. This has no effect if
stepping not enabled or it is already disabled.

- For the following operator, the second argument shall be a valid
assertion handle, the third argument shall

be an attempt start-time (as a pointer to a correctly initialized
s_vpi_time structure) and the fourth argument

shall be a step control constant.

Usage example: vpi_control(vpiAssertionEnableStep, assertionHandle,
attempt,

NEW:

Usage example: vpi_control(vpiAssertionKill, assertionHandle,
attemptStartTime)

vpiAssertionKill

discards the given attempts, but leaves the assertion enabled and does
not reset any state used by this

assertion (e.g., past() sampling).

Usage example: vpi_control(vpiAssertionDisableStep, assertionHandle,
attemptStartTime)

vpiAssertionDisableStep

disables step callbacks for this assertion. This has no effect if
stepping not enabled or it is already disabled.

- For the following operator, the second argument shall be a valid
assertion handle, the third argument shall

be an attempt start-time (as a pointer to a correctly initialized
s_vpi_time structure) and the fourth argument

shall be a step control constant.

Usage example: vpi_control(vpiAssertionEnableStep, assertionHandle,
attemptStartTime,

 
 
 



This archive was generated by hypermail 2b28 : Wed Dec 10 2003 - 10:29:59 PST