assert_never_unknown

Ensures that the value of a specified expression contains only 0 and 1 bits when a qualifying expression is TRUE.

Parameters:
severity_level
width
property_type
msg
coverage_level
Class:
single-cycle assertion

Syntax

assert_never_unknown 
		[#(severity_level, width, property_type, msg, coverage_level )] 
		instance_name (clk, reset_n, qualifier, 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.
 
qualifier
 
Expression that indicates whether or not to check test_expr .
 
test_expr
[ width - 1: 0 ]
Expression that should contain only 0 or 1 bits when qualifier is TRUE.

Description

The assert_never_unknown assertion checker checks the expression qualifier at each rising edge of clk to determine if it should check test_expr. If qualifier is sampled TRUE, the checker evaluates test_expr and if the value of test_expr contains a bit that is not 0 or 1, the assertion fails.

The checker is useful for ensuring certain data have only known values following a reset sequence. It also can be used to verify tristate input ports are driven and tristate output ports drive known values when necessary.

Assertion Checks

 
test_expr contains X/Z value
The test_expr expression contained at least one bit that was not 0 or 1; qualifier was sampled TRUE; and ‘OVL_XCHECK_OFF is not set.

Cover Points

 
qualifier
A never_unknown check was initiated.
 
test_expr_change
Expression changed value.

Notes

1. If ‘OVL_XCHECK_OFF is set, all assert_never_unknown checkers are turned off.

See also

assert_never, assert_one_cold, assert_one_hot, assert_zero_one_hot

Example

  
assert_never_unknown #(
 
‘OVL_ERROR,
8,
‘OVL_ASSERT,
“Error: data unknown or undriven”,
‘OVL_COVER_ALL)
// severity_level
// width
// property_type
// msg
// coverage_level
 
valid_data (
 
 
 
clk,
reset_n,
rd_data,
data);
// clock
// reset
// qualifier
// test_expr
    

Ensures that values of data are known and driven when rd_data is TRUE.


  © Accellera Organization, Inc. 2005
All Rights Reserved.
Standard OVL V1.1a