assert_even_parity
Ensures that the value of a specified expression has even parity.
|
Parameters:
severity_level
width
property_type
msg
coverage_level
|
Class:
single-cycle assertion
|
Syntax
assert_even_parity
[#(severity_level, width, property_type, msg, coverage_level )]
instance_name (clk, reset_n, test_expr );
Parameters
|
severity_level
|
Severity of the failure. Default: ‘OVL_ERROR.
|
|
width
|
Width of the test_expr argument. Default: 1.
|
|
property_type
|
Property type. Default: ‘OVL_ASSERT.
|
|
msg
|
Error message printed when assertion fails. Default: “VIOLATION”.
|
|
coverage_level
|
Coverage level. Default: ‘OVL_COVER_ALL.
|
Ports
|
clk
|
|
Clock event for the assertion. The checker samples on the rising edge of the clock.
|
|
reset_n
|
|
Active low synchronous reset signal indicating completed initialization.
|
|
test_expr
|
[ width - 1: 0 ]
|
Expression that should evaluate to a value with even parity on the rising clock edge.
|
Description
The assert_even_parity
assertion checker checks the expression test_expr at each rising edge of clk to verify the expression evaluates to a value that has even parity. A value has even parity if it is 0 or if the number of bits set to 1 is even.
The checker is useful for verifying control circuits, for example, it can be used to verify a finite-state machine with error detection. In a datapath circuit the checker can perform parity error checking of address and data buses.
Assertion Check
|
ASSERT_EVEN_PARITY
|
Expression evaluated to a value whose parity is not even.
|
Cover Point
|
test_expr_change
|
Expression has changed value.
|
See also
assert_odd_parity
Examples
assert_even_parity #(
|
|
‘OVL_ERROR,
8,
‘OVL_ASSERT,
“Error: data has odd parity”,
‘OVL_COVER_ALL)
|
// severity_level
// width
// property_type
// msg
// coverage_level
|
|
valid_data_even_parity (
|
|
|
|
clk,
reset_n,
data );
|
// clock
// reset
// test_expr
|
Ensures that data
has even parity at each rising edge of clk.
|
© Accellera Organization, Inc. 2005 All Rights Reserved.
|
Standard OVL V1.1a
|