Inheritance diagram for class svt_err_check:
Error Check Class - Tracks error checks performed by a transactor. An object of this class is instantiated in the svt_xactor class (the m_o_err_chk member of that class). Error checks performed by the transactor are registered to this class, and statistic collection objects for them are stored in the checks[$] queue of this class.
Public Member Functions | |
| function int | capture_and_disable_checks ( string disable_group = "", string disable_sub_group = "", string disable_unique_id = "" ) |
| function void | check_catcher_exists ( ) |
| function void | check_catcher_needed ( ) |
| function void | clear_dynamic_err_checks ( ) |
| function void | disable_check ( svt_err_check_stats check_stats ) |
| function int | disable_checks ( string disable_group = "", string disable_sub_group = "", string disable_unique_id = "" ) |
| function int | disable_checks_cov ( string disable_cov_group = "", string disable_cov_sub_group = "" ) |
| function void | enable_check ( svt_err_check_stats check_stats ) |
| function int | enable_checks ( string enable_group = "", string enable_sub_group = "", string enable_unique_id = "" ) |
| function int | enable_checks_cov ( string enable_cov_group = "", string enable_cov_sub_group = "", bit enable_pass_cov = 0, bit enable_fail_cov = 1 ) |
| function void | execute ( svt_err_check_stats check_stats, bit test_pass, string fail_msg = "", svt_err_check_stats :: fail_effect_enum fail_effect = svt_err_check_stats::ERROR, string filename = "", int line = 0 ) |
| function void | execute_stats ( svt_err_check_stats check_stats, bit test_pass, string fail_msg = "" ) |
| function void | fail ( svt_err_check_stats check_stats, string fail_msg = "", svt_err_check_stats :: fail_effect_enum fail_effect = svt_err_check_stats::ERROR, string filename = "", int line = 0 ) |
| function void | filter_after_n_fails ( int threshold, svt_err_check_stats check_stats = null ) |
| function int | filter_error ( svt_err_check_stats check_stats ) |
| function svt_err_check_stats | find ( string unique_id ) |
| function bit | find_check ( svt_err_check_stats check_stats ) |
| function void | find_checks ( string find_group = "", string find_sub_group = "", ref svt_err_check_stats found_checks[$], input string find_unique_id ) |
| function string | get_check_msg ( svt_err_check_stats check_stats, string fail_msg = "" ) |
| function svt_err_check_stats | get_check_stats ( string unique_id ) |
| function svt_err_check | get_err_check ( string err_check_name, bit silent = 0 ) |
| function string | get_err_check_name ( ) |
| function svt_err_check_stats | get_err_check_stats ( string unique_id, bit silent = 0 ) |
| function bit | get_prop_val ( string prop_name, ref bit [1023:0] prop_val, input int array_ix, ref svt_sequence_item_base data_obj ) |
| function void | new ( string suite_name = "", string err_check_name = "", ovm_report_object reporter = null ) |
| function void | pass ( svt_err_check_stats check_stats, string filename = "", int line = 0 ) |
| function string | psdisplay_all_check_stats ( string prefix, bit include_initial_header, bit include_intermediate_header, bit omit_unexercised ) |
| function svt_err_check_stats | register ( string description, input string reference = "", svt_err_check_stats :: fail_effect_enum default_fail_effect = svt_err_check_stats::ERROR, int filter_after_count = 0 ) |
| function void | register_check ( svt_err_check_stats check_stats ) |
| function void | register_err_check ( svt_err_check new_err_check ) |
| function void | register_err_check_stats ( svt_err_check_stats new_err_check_stats ) |
| function void | report ( string prefix = " " ) |
| function void | report_all_check_info ( string prefix = " ", bit include_initial_header = 0, bit include_intermediate_header = 1, bit omit_disabled = 1 ) |
| function void | report_all_check_stats ( string prefix = " ", bit include_initial_header = 0, bit include_intermediate_header = 1, bit omit_unexercised = 1 ) |
| function void | report_check_info ( svt_err_check_stats checks[$], bit omit_disabled = 1, string prefix = " " ) |
| function void | report_check_stats ( svt_err_check_stats checks[$], bit omit_unexercised = 1, string prefix = " " ) |
| function int | restore_enable_last_disabled_checks ( string enable_group = "", string enable_sub_group = "", string enable_unique_id = "" ) |
| function void | set_checks_cov_fail ( string set_fail_cov_group, string set_fail_cov_sub_group = "", bit enable_fail_cov = 1 ) |
| function void | set_checks_cov_pass ( string set_pass_cov_group, string set_pass_cov_sub_group = "", bit enable_pass_cov = 1 ) |
| function void | set_component_reporter ( ovm_component comp_reporter, bit force_override = 0 ) |
| function int | set_default_fail_effects ( string fail_effect_group = "", string fail_effect_sub_group = "", svt_err_check_stats :: fail_effect_enum new_default_fail_effect, string fail_effect_unique_id = "" ) |
| function int | set_default_pass_effects ( string pass_effect_group = "", string pass_effect_sub_group = "", svt_err_check_stats :: fail_effect_enum new_default_pass_effect, string pass_effect_unique_id = "" ) |
| function bit | set_prop_val ( string prop_name, bit [1023:0] prop_val, int array_ix ) |
| function void | unfilter_error ( int filter_id = -1 ) |
| function void | unregister_check ( svt_err_check_stats check_stats, bit silent = 1 ) |
| function void | unregister_err_check_stats ( svt_err_check_stats err_check_stats, bit silent = 1 ) |
Public Attributes | |
| bit | dynamic_checks = 0; |
Protected Attributes | |
| protected svt_err_check_report_catcher | catcher |
| protected svt_err_check_stats | checks [$] |
| protected string | err_check_name |
| protected svt_err_check | registered_err_check [$] |
| protected ovm_report_object | reporter |
|
||
Disables checks that match specified group and sub-group criteria. Checks that are already disabled will not be effected and will not be included in the count that is returned. It internally captures current is_enabled state prior to disabling a check.
disable_group - Regular expression string used to search for groups associated with the checks to disable. The empty string can be used to do a wildcard match against all group values.
disable_sub_group - Regular expression string used to search for sub-groups associated with the checks to disable. The empty string can be used to do a wildcard match against all sub-group values.
disable_unique_id - Regular expression string used to search for the unique_id associated with the checks to find. The empty string can be used to do a wildcard match against all unique_id values.
Return values - The number of checks that were disabled. |
|
||
Method insures the catcher has been setup.
|
|
||
Method which deletes the catcher if it is no longer needed.
|
|
||
Clears out the dynamic svt_err_check instances registered with this class.
|
|
||
This method is called to disable a check. This allows the svt_err_check class to stop check-related threads that are currently running.
This method must be implemented by the derived svt_err_check class.
check_stats - The registered check to disable. |
|
||
Disables checks that match specified group and sub-group criteria. Checks that are already disabled will not be effected and will not be included in the count that is returned.
disable_group - Regular expression string used to search for groups associated with the checks to disable. The empty string can be used to do a wildcard match against all group values.
disable_sub_group - Regular expression string used to search for sub-groups associated with the checks to disable. The empty string can be used to do a wildcard match against all sub-group values.
disable_unique_id - Regular expression string used to search for the unique_id associated with the checks to find. The empty string can be used to do a wildcard match against all unique_id values.
Return values - The number of checks that were disabled. |
|
||
Deletes the coverage for the checks that match specified group and sub-group criteria.
disable_cov_group - Regular expression used to search for groups for coverage deletion. The empty string can be used to do a wildcard match against all group values.
disable_cov_sub_group - Regular expression used to search for sub-groups for coverage deletion. The empty string can be used to do a wildcard match against all sub-group values.
Return values - The number of checks that were disabled for coverage. |
|
||
This method is called to enable a check. This allows the svt_err_check class to start any threads needed to perform this check.
This method must be implemented by the derived svt_err_check class.
check_stats - The registered check to enable. |
|
||
Enables checks that match specified group and sub-group criteria. Checks that are already enabled will not be effected and will not be included in the count that is returned.
enable_group - Regular expression string used to search for groups associated with the checks to enable. The empty string can be used to do a wildcard match against all group values.
enable_sub_group - Regular expression string used to search for sub-groups associated with the checks to enable. The empty string can be used to do a wildcard match against all sub-group values.
enable_unique_id - Regular expression string used to search for the unique_id associated with the checks to find. The empty string can be used to do a wildcard match against all unique_id values.
Return values - The number of checks that were enabled. |
|
||
Add covergroups for all registered checks that match the specified group and sub-group criteria utilizing the provided pass/fail settings.
enable_cov_group - Regular expression used to search for groups associated with the checks to cover. The empty string can be used to do a wildcard match against all group values.
enable_cov_sub_group - Regular expression used to search for sub-groups associated with the checks to cover. The empty string can be used to do a wildcard match against all sub-group values.
enable_pass_cov - Enables the "pass" bins on all of the the check coverage instances.
enable_fail_cov - Enables the "fail" bins on all of the the check coverage instances.
Return values - The number of checks that were enabled for coverage. |
|
||
Called by transactor to execute a DUT Error Check with a default severity of ERROR.
check_stats - Handle to the check being executed test_pass - Represents the outcome of the check (PASS = 1, FAIL = 0). fail_msg - (Optional) Contains more data about a check that failed. fail_effect - (Optional: Default=ERROR) Determines how a failure should be counted (as IGNORE, WARNING, ERROR, EXPECTED, or DEFAULT). filename - Optional argument identifying the source file for the message. line - Optional argument identifying the source line number for the message. |
|
||
Called by transactor to execute a DUT Error Check with the configured default severity for the svt_err_check_stats instance.
check_stats - Handle to the check being executed test_pass - Represents the outcome of the check (PASS = 1, FAIL = 0). fail_msg - (Optional) Contains more data about a check that failed. |
|
||
Registers a FAILED check with this class. As long as the error has not been filtered, this method produces log output with the description of the check, and the fact that it has FAILED, and what the corresponding failure effect is.
check_stats - Check performed by a transactor. fail_msg - (Optional) Additional output that will be printed along with the basic failure message. fail_effect - (Optional: Default=ERROR) Determines how a failure should be counted (as IGNORE, WARNING, ERROR, EXPECTED, or DEFAULT). filename - Optional argument identifying the source file for the message. line - Optional argument identifying the source line number for the message. |
|
||
Activates or modifies automatic error message filtering, after a specified number of failures for a given check (or all checks).
threshold - Specifies the allowed number of FAIL messages, before filtering is activated. check_stats - (Optional) Specifies the check to be filtered (null => all checks). |
|
||
Filters out a specified error. The argument specifies the error using the same ID with which it is registered.
check_stats - Check performed by a transactor. Return values - An int handle to the filter rule just created (used to later unfilter the error). |
|
||
Returns a registered check, given a unique string which identifies the check.
unique_id - The identifier of the check to retrieve. This is based on how the check was constructed, using the check_id_str or the description as its unique identifier. The check_id_str is given precedence over the description.
Return values - The registered check, or null if the check wasn't found. |
|
||
Looks for the indicated check, returning a bit indicating whether it was found.
check_stats - The check to look for.
Return values - Indication of whether the check was found (1) or not found (0). |
|
||
Finds checks that match specified group, sub-group, and unique_id criteria.
find_group - Regular expression string used to search for groups associated with the checks to find. The empty string can be used to do a wildcard match against all group values.
find_sub_group - Regular expression string used to search for sub-groups associated with the checks to find. The empty string can be used to do a wildcard match against all sub-group values.
found_checks - A queue that stores the checks that were found as a result of the find operation.
find_unique_id - Regular expression string used to search for the unique_id associated with the checks to find. The empty string can be used to do a wildcard match against all unique_id values. The find_group, find_sub_group, and find_unique_id string arguments are compared with captured groups/sub-groups/unique-ids through a SystemVerilog DPI uvm_re_match. The UVM_NO_DPI option prevents compilation of UVM C code that uses the SystemVerilog DPI. This option is only there for some environments that do not have their C compilers installed. In SystemVerilog characters [ and ] is not recognized as strings. So these special characters has to be escaped according to following options- With UVM_NO_DPI : In SystemVerilog the [ character needs to be escaped inside a string. Therefore need to escape this character with \ character as \[0\]. Without UVM_NO_DPI : uvm_re_match uses the POSIX function regexec to perform a match. Special character [] is not recognized as strings in POSIX function. According to POSIX regex the [0] will try to match the character found between the brackets, and no matching is performed for the bracket characters [ and ] themselves. The bracket characters are escaped using \ [ and \ ]. In SystemVerilog the \ character also needs to be escaped because it is itself the escape character used inside a string. Therefore need to escape this escape character with another \ character as \\[0\\]. |
|
||
Returns a string that provides the basic check msg (check info plus fail_msg, if provided).
|
|
||
DEPRECATED -- USE 'get_err_check_stats'
|
|
||
Returns a handle to the svt_err_check class object that has the indicated name value.
err_check_name - The identifier of the check to retrieve. silent - Indicates whether a failure to find the svt_err_check_stats instance should result in an error. |
|
||
Returns a string with the name of the svt_err_check instance.
Return values - the name of the svt_err_check instance. |
|
||
Returns a handle to the svt_err_check_stats class object that contains the statistics associated with the given unique_id.
unique_id - The identifier of the svt_err_check_stats instance to retrieve. This is based on how the check was constructed, using the check_id_str or the description as its unique identifier. When doing the match the check_id_str value in the svt_err_check_stats object is given precedence over the description in the object. silent - Indicates whether a failure to find the svt_err_check_stats instance should result in an error. |
|
||||
This method is used by a component's command interface, to allow command code to retrieve the value of a single named property of a data class derived from this class. If the prop_name argument does not match a property of the class, or if the array_ix argument is not zero and does not point to a valid array element, this function returns '0'. Otherwise it returns '1', with the value of the prop_val argument assigned to the value of the specified property. However, If the property is a sub-object, a reference to it is assigned to the data_obj (ref) argument.
prop_name - The name of a property in this class, or a derived class. prop_val - A ref argument used to return the current value of the property, expressed as a 1024 bit quantity. When returning a string value each character requires 8 bits so returned strings must be 128 characters or less. array_ix - If the property is an array, this argument specifies the index being accessed. If the property is not an array, it should be set to 0. data_obj - If the property is not a sub-object, this argument is assigned to null. If the property is a sub-object, a reference to it is assigned to this (ref) argument. In that case, the prop_val argument is meaningless. The transactor will then store the data object reference in its temporary data object array, and return a handle to its location as the prop_val argument of the get_data_prop task of the component. The command testbench code must then use that handle to access the properties of the sub-object. Return values - A single bit representing whether or not a valid property was retrieved. | ||||
|
|
||
CONSTRUCTOR: Create a new svt_err_check instance.
suite_name - Passed in to identify the model suite for licensing.
err_check_name - A string that identifies this particular svt_err_check instance.
reporter - Optional reporter object for routing messages. |
|
||
Registers a PASSED check with this class. If the verbosity of this class's log object is TRACE or higher, this method produce slog output indicating the name of the check, and the fact that it has PASSED.
check_stats - The check performed by a transactor. filename - Optional argument identifying the source file for the message. line - Optional argument identifying the source line number for the message. |
|
||
Formats the current stats for all registered checks so that they can be reported.
prefix - The prefix string for all output.
include_initial_header - If this flag is set and top level report header is included.
include_intermediate_header - If this flag is set an intermediate header for this set of checks is included.
omit_unexercised - If this flag is set, checks that have not been exercised are skipped. |
|
||
Creates a new registered check. After this method is called, the unique check description is stored for future reference. Calling this method multiple times with the same description argument has no further effect (i.e. the existing registration stays intact, and a new one is not created).
description - Describes (briefly) a unique check performed by a transactor. reference - (Optional) Text to reference protocol spec requirement associated with the check. default_fail_effect - (Optional: Default = ERROR) Sets the default handling of a failed check. filter_after_count - (Optional) Sets the number of fails before automatic filtering is applied. Return values - A handle to the check constructed to implement the check indicated by the description. |
|
||
DEPRECATED -- USE 'register_err_check_stats'
|
|
||
Registers an svt_err_check instance with this class.
new_err_check - The svt_err_check to register. |
|
||
Registers an svt_err_check_stats instance with this class.
new_err_check_stats - The svt_err_check_stats to register. |
|
||
Reports (to transcript) the current stats for all tracked errors.
prefix - Prefix string for all output. |
|
||
Reports information about all registered checks.
prefix - The prefix string for all output.
include_initial_header - If this flag is set and top level report header is included.
include_intermediate_header - If this flag is set an intermediate header for this set of checks is included.
omit_disabled - If this flag is set, checks that are disabled are skipped. |
|
||
Reports the current stats for all registered checks.
prefix - The prefix string for all output.
include_initial_header - If this flag is set and top level report header is included.
include_intermediate_header - If this flag is set an intermediate header for this set of checks is included.
omit_unexercised - If this flag is set, checks that have not been exercised are skipped. |
|
||
Reports information about checks.
checks - The checks to be reported on, or null for all checks that are registered with this class.
omit_disabled - If this flag is set, checks that are disabled are skipped.
prefix - The prefix string for all output. |
|
||
Reports the current stats for checks.
checks - The checks to be reported on, or null for all checks that are registered with this class.
prefix - The prefix string for all output.
omit_unexercised - If this flag is set, checks that have not been exercised are skipped. |
|
||
Enables checks that match specified group and sub-group criteria AND were captured as enabled using capture_and_disable_checks API. Checks that are already enabled will not be effected and will not be included in the count that is returned.
enable_group - Regular expression string used to search for groups associated with the checks to enable. The empty string can be used to do a wildcard match against all group values.
enable_sub_group - Regular expression string used to search for sub-groups associated with the checks to enable. The empty string can be used to do a wildcard match against all sub-group values.
enable_unique_id - Regular expression string used to search for the unique_id associated with the checks to find. The empty string can be used to do a wildcard match against all unique_id values.
Return values - The number of checks that were enabled. |
|
||
Enables the "fail" bins of the "status" covergroup associated with the all the registered checks. This method would set the "enable_fail_cov" bit of the coverage class, if coverage is enabled on the checks identified by the group and sub_group. If coverage is disabled, it would not set the "enable_fail_cov" bit.
set_fail_cov_group - The group associated with the checks for coverage.
set_fail_cov_sub_group - The sub-group associated with the checks for coverage. If no sub-group is specified, all registered checks associated with the specified group will have coverage bins "fail" added to them.
enable_fail_cov - Bit indicates, whether the "fail" bins are enabled or disabled. Default value is '1' which enables the "fail" bins by default. |
|
||
Enables the "pass" bins of the "status" covergroup associated with the all the registered checks. This method would set the "enable_pass_cov" bit of the coverage class, if coverage is enabled on the checks identified by the group and sub_group. If coverage is disabled, it would not set the "enable_pass_cov" bit.
set_pass_cov_group - The group associated with the checks for coverage.
set_pass_cov_sub_group - The sub-group associated with the checks for coverage. If no sub-group is specified, all registered checks associated with the specified group will have coverage bins "pass" added to them.
enable_pass_cov - Bit indicates, whether the "pass" bins are enabled or disabled. Default value is '1' which enables the "pass" bins by default. |
|
||
Basic report objects aren't included in the component hierarchy and therefore don't respond well to verbosity modifications. I.e., verbosity modifications travel the component hierarchy, and miss anything which isn't in it. To deal with this we provide an easy mechanism for providing a component report object.
comp_reporter - The new component report object. force_override - Indicates whether the setting of the reporter should be forced, even if the svt_err_check instance already has a component reporter. |
|
||
Modifies the default handling in the event of 'fail' of checks that match specified group and sub-group criteria. Checks that already have the indicated default handling will not be effected and will not be included in the count that is returned.
fail_effect_group - Regular expression string used to search for groups associated with the checks to modify. The empty string can be used to do a wildcard match against all group values.
fail_effect_sub_group - Regular expression string used to search for sub-groups associated with the checks to modify. The empty string can be used to do a wildcard match against all sub-group values.
new_default_fail_effect - The new fail effect.
fail_effect_unique_id - Regular expression string used to search for the unique_id associated with the checks to find. The empty string can be used to do a wildcard match against all unique_id values.
Return values - The number of checks that were modified. |
|
||
Modifies the default handling in the event of 'pass' of checks that match specified group and sub-group criteria. Checks that already have the indicated default handling will not be effected and will not be included in the count that is returned.
pass_effect_group - Regular expression string used to search for groups associated with the checks to modify. The empty string can be used to do a wildcard match against all group values.
pass_effect_sub_group - Regular expression string used to search for sub-groups associated with the checks to modify. The empty string can be used to do a wildcard match against all sub-group values.
new_default_pass_effect - The new pass effect.
pass_effect_unique_id - Regular expression string used to search for the unique_id associated with the checks to find. The empty string can be used to do a wildcard match against all unique_id values.
Return values - The number of checks that were modified. |
|
||||
This method is used by a component's command interface, to allow command code to set the value of a single named property of a data class derived from this class. This method cannot be used to set the value of a sub-object, since sub-object consruction is taken care of automatically by the command interface. If the prop_name argument does not match a property of the class, or it matches a sub-object of the class, or if the array_ix argument is not zero and does not point to a valid array element, this function returns '0'. Otherwise it returns '1'.
prop_name - The name of a property in this class, or a derived class. prop_val - The value to assign to the property, expressed as a 1024 bit quantity. When assigning a string value each character requires 8 bits so assigned strings must be 128 characters or less. array_ix - If the property is an array, this argument specifies the index being accessed. If the property is not an array, it should be set to 0. Return values - A single bit representing whether or not a valid property was set. | ||||
|
|
||
Removes a filter previously set for a specified error. The argument specifies the filter rule handle that was returned when the filter was set.
filter_id - (Optional) An int handle to the filter rule (as returned by filter_error). If this argument is not supplied, or the default -1 value is specified, all error check failure message filter rules will be removed. |
|
||
DEPRECATED -- USE 'unregister_err_check_stats'
|
|
||
Unregisters an svt_err_check_stats instance previously registered with this class.
err_check_stats - The svt_err_check_stats to unregister. silent - Indicates whether an error should be generated if the check cannot be found. |
|
|
UVM/OVM Report Catcher used to filter failing checks
|
|
|
Queue that stores statistics for registered checks.
|
|
|
Indicates whether this svt_err_check instance is dynamic, and should therefore be destroyed and reconstructed when the associated transactor is restarted.
|
|
|
A string that identifies this class.
|
|
|
Queue that stores the registered error checking instances, used to build a hierarchy of svt_err_check instances.
|
|
|
SVT message macros route messages through this reference. This overrides the shared svt_sequence_item_base reporter.
|