svt_data Class Reference

Inheritance diagram for class svt_data:

List of all members.


Detailed Description

Base class for all SVT-based model's data object classes (configuration, transaction, etc.).



Public Member Functions

function void  add_compound_pattern_prop ( svt_pattern pttrn, string owner, string name, svt_pattern_data :: type_enum typ, int unsigned supported_methods_flag = 0, int unsigned field_width = 0, string enum_type = "" )
function void  add_pattern_prop ( svt_pattern pttrn, string owner, string name, svt_pattern_data :: type_enum typ, int unsigned supported_methods_flag = 0, int unsigned field_width = 0, string enum_type = "" )
virtual function vmm_data  allocate ( )
function svt_pattern  allocate_auto_op_pattern ( int allocate_pattern_filter )
function svt_pattern  allocate_pattern ( )
function svt_pattern  allocate_xml_pattern ( )
function bit  auto_compare ( svt_data rhs_data, output string diff )
function void  auto_copy ( svt_data to )
function unsigned int  auto_pack ( ref logic [7:0] bytes[], input int unsigned offset )
function unsigned int  auto_unpack ( const ref logic [7:0] bytes[], input int unsigned offset )
virtual function unsigned int  byte_pack ( ref logic [7:0] bytes[], input int unsigned offset, input int kind )
function unsigned int  byte_size ( int kind = -1 )
virtual function unsigned int  byte_unpack ( const ref logic [7:0] bytes[], input int unsigned offset, input int len, input int kind )
static function timeunit_enum  calc_timeunit ( )
virtual function bit  compare ( vmm_data to, output string diff, input int kind )
function bit  compare_pattern_data ( svt_pattern_data rhs_pd, output string diff, input string name_override )
function bit  compare_via_pattern ( svt_pattern pttrn )
virtual function vmm_data  copy ( vmm_data to = null )
function bit  decode_pattern_data ( svt_pattern_data pd, ref string pd_string, input string delimiter )
function bit  decode_prop_val ( string prop_name, bit [1023:0] prop_val, ref string prop_val_string, input svt_pattern_data :: type_enum typ )
function void  display_get_prop_val_outcome ( bit success, string prop_name, bit [1023:0] prop_val, int array_ix, svt_data data_obj )
function void  display_set_prop_val_outcome ( bit success, string prop_name, bit [1023:0] prop_val, int array_ix )
function void  do_all ( vmm_data :: do_what_e do_what, ref logic [7:0] pack[], const ref logic [7:0] unpack[] )
function svt_pattern  do_allocate_pattern ( )
function unsigned int  do_byte_pack ( ref logic [7:0] bytes[], input int unsigned offset, input int kind )
function unsigned int  do_byte_unpack ( const ref logic [7:0] bytes[], input int unsigned offset, input int len, input int kind )
function bit  do_compare ( vmm_data to, output string diff, input int kind )
function vmm_data  do_copy ( vmm_data to = null )
function bit  do_is_valid ( bit silent = 1, int kind = -1 )
function bit  encode_prop_val ( string prop_name, string prop_val_string, ref bit [1023:0] prop_val, input svt_pattern_data :: type_enum typ )
function type_enum  find_type ( string prop_name )
function string  get_class_name ( )
function bit  get_do_compare_done ( )
function bit  get_do_pack_done ( )
static function string  get_environment_variable_value ( string method_name, string env_var_name, vmm_log log, bit is_optional = 0 )
function string  get_mcd_class_name ( )
function svt_pa_object_data  get_pa_obj_data ( string uid = "", string typ = "", string parent_uid = "", string channel = "" )
function bit  get_prop_val ( string prop_name, ref bit [1023:0] prop_val, input int array_ix, ref svt_data data_obj )
function bit  get_prop_val_via_pattern ( ref svt_pattern pttrn )
function string  get_suite_name ( )
static function string  get_timeunit_str ( string class_name, vmm_log log )
function string  get_uid ( )
function svt_pattern  get_user_fsdb_props ( )
function string  get_xml_object_block_desc ( string obj_type = "", string obj_sub_type = "", string parent_uid = "", string channel = "" )
function bit  is_safe_as_ref ( svt_xml_writer writer )
function bit  is_silent ( )
virtual function bit  is_valid ( bit silent = 1, int kind = -1 )
function bit  load ( int file )
function bit  load_from_string ( string text )
function bit  load_prop_vals ( string filename = "", int file = 0 )
function bit  load_prop_vals_with_checks ( string filename = "", int file = 0 )
function int  log_base_2 ( int val, bit round_up = 1 )
function void  mcd_log_object ( int mcd_log_file, string mcd_parameter )
function void  new ( vmm_log log = null, string suite_spec = "" )
function unsigned int  pack_pattern_data ( svt_pattern_data pd, ref logic [7:0] bytes[], input int unsigned offset )
function int  power_of_2 ( int val )
virtual function string  psdisplay ( string prefix = "" )
function int  reasonable_constraint_mode ( bit on_off )
function int  resolve_compare_kind ( int kind )
function int  resolve_is_valid_kind ( int kind )
function int  resolve_pack_kind ( int kind )
function real  safe_atoreal ( string ascii_real )
function void  save ( int file )
function bit  save_child_refs ( svt_xml_writer writer, string prefix = "" )
function bit  save_object_begin ( svt_xml_writer writer )
function bit  save_object_data ( svt_xml_writer writer, string prefix = "" )
function bit  save_pattern_to_xml ( svt_xml_writer writer, svt_pa_object_data pa_obj_data, svt_pattern pttrn, string prefix = "" )
function bit  save_prop_vals ( string filename = "", int file = 0, string prefix = "" )
function bit  save_prop_vals_to_fsdb ( string inst_name, string parent_object_uid = "", string stream_attr_namestream_attr_name = [$], string stream_attr_valstream_attr_val = [$] )
function bit  save_prop_vals_to_fsdb_internal ( string top_level_name, string object_channel, string parent_object_uid = "", string object_uid = "", string prefix = "" )
function bit  save_prop_vals_to_xml ( svt_xml_writer writer, string object_block_desc = "", string prefix = "" )
function bit  save_ref ( svt_xml_writer writer, string prefix = "" )
function bit  set_prop_object ( string prop_name, svt_data prop_obj, int array_ix )
function bit  set_prop_val ( string prop_name, bit [1023:0] prop_val, int array_ix )
function bit  set_prop_val_via_pattern ( svt_pattern pttrn )
function void  set_prop_val_via_plusargs ( string plusarg_keyword )
function void  silent_mode ( bit mode )
static function bit  strip_array_element_suffix ( vmm_log log, string prop_name, output string base_name, output int array_ix )
function void  svt_post_do_all_do_byte_unpack ( )
function void  svt_post_do_all_do_copy ( vmm_data to )
function string  svt_shorthand_psdisplay ( string prefix )
function string  svt_shorthand_psdisplay_hook ( string prefix )
function unsigned int  unpack_pattern_data ( svt_pattern_data pd, const ref logic [7:0] bytes[], input int unsigned offset )
function void  vmm_opts_via_pattern ( )

Public Attributes

static int  display_kind = -1; 
int  kind = svt_data::UNASSIGNED; 
vmm_log  log 
static int  max_array_elem_display = SVT_MAX_ARRAY_ELEM_DISPLAY_DEFAULT
static vmm_log  notify_log = new; 
static vmm_log  silent_log = new; 

Protected Attributes

protected string  suite_name = ""; 
static protected svt_data  __vmm_rhs 

Member Typedefs

 typedef enum  kind_enum 
 typedef enum  recursive_op_enum 


Member Function Documentation

  function void
 svt_data::add_compound_pattern_prop

 (  svt_pattern pttrn , string owner , string name , svt_pattern_data :: type_enum typ , int unsigned supported_methods_flag = 0, int unsigned field_width = 0, string enum_type = ""  ) 


Method which can be used to add a single svt_compound_pattern_data element to the provided pattern.

pttrn - Pattern the property is to be added to.

owner - Class name where the property is defined.

name - Name portion of the new name/value pair.

typ - Type portion of the new name/value pair.

field_width - Field bit width used by common data class operations. 0 indicates "not set".

supported_methods_flag - Flag indicating which common data class operations are to be supported automatically for this field. 0 indicates "not set".

  function void
 svt_data::add_pattern_prop

 (  svt_pattern pttrn , string owner , string name , svt_pattern_data :: type_enum typ , int unsigned supported_methods_flag = 0, int unsigned field_width = 0, string enum_type = ""  ) 


Method which can be used to add a single svt_pattern_data element to the provided pattern.

pttrn - Pattern the property is to be added to.

owner - Class name where the property is defined.

name - Name portion of the new name/value pair.

typ - Type portion of the new name/value pair.

field_width - Field bit width used by common data class operations. 0 indicates "not set".

supported_methods_flag - Flag indicating which common data class operations are to be supported automatically for this field. 0 indicates "not set".

 virtual function vmm_data
 svt_data::allocate

 (   ) 


 Superseded functions 
 vmm_data :: allocate 
 Superseding functions 
 svt_cmd_channel_data :: allocate 
 svt_cmd_transaction_ix_data :: allocate 
 svt_cmd_transaction_stack_data :: allocate 
 svt_configuration :: allocate 
 svt_err_check :: allocate 
 svt_err_check_stats :: allocate 
 svt_svc_err_check_stats :: allocate 
 svt_exception :: allocate 
 svt_exception_list :: allocate 
 svt_mem :: allocate 
 svt_pattern_data_carrier :: allocate 
 svt_debug_opts_carrier :: allocate 
 svt_status :: allocate 
 svt_transaction :: allocate 
 svt_8b10b_data :: allocate 
 svt_mem_transaction :: allocate 
 svt_traffic_profile_transaction :: allocate 

  function svt_pattern
 svt_data::allocate_auto_op_pattern

 (  int allocate_pattern_filter  ) 


This method allocates a pattern containing svt_pattern_data instances for all of the data fields in the object that support automated implementations for the common data methods.

allocate_pattern_filter - Control settings used to limit which pattern_data elements are created.

Return values - An svt_pattern instance containing entries for all of the fields that support the automated operations.

  function svt_pattern
 svt_data::allocate_pattern

 (   ) 


This is a pattern allocation method which is implemented to add properties without including support for the 'automated operation' capabilities. This is provided by VIPs which have not updated to provide the automated operation support via do_allocate_pattern. VIPs should provide one or the other, but not both.

The method allocates a pattern containing svt_pattern_data instances for all of the primitive data fields in the object. The svt_pattern_data :: name is normally set to the corresponding field name, the svt_pattern_data :: value is normally set to 0. For fields which are displayed but not owned, the method puts the current value in for svt_pattern_data :: value.

The base class this method is simplay a feed through, calling do_allocate_pattern to insure all of the 'enabled' pattern_data instances are allocated.

Note that most clients needing patterns should continue to call 'allocate_pattern' or one of the derived pattern methods. This is to to insure they get both the enabled and 'not enabled' pattern_data instances. The only exceptions at this point are:

Return values - An svt_pattern instance containing entries for all of the data fields.

  function svt_pattern
 svt_data::allocate_xml_pattern

 (   ) 


This method allocates a pattern containing svt_pattern_data instances for all of the data fields in the object that are to be included in the object's XML output.

Return values - An svt_pattern instance containing entries for all of the fields required for XML output of the data object.


 Superseding functions 
 svt_transaction :: allocate_xml_pattern 
 svt_traffic_profile_transaction :: allocate_xml_pattern 

  function bit
 svt_data::auto_compare

 (  svt_data rhs_data , output string diff  ) 


Methodology independent 'compare' method for comparing fields based on pattern information.

  function void
 svt_data::auto_copy

 (  svt_data to  ) 


Methodology independent 'copy' method for copying fields based on pattern information.

  function unsigned int
 svt_data::auto_pack

 (  ref logic [7:0] bytes [], input int unsigned offset  ) 


Methodology independent 'pack' method for packing fields based on pattern information.

  function unsigned int
 svt_data::auto_unpack

 (  const ref logic [7:0] bytes [], input int unsigned offset  ) 


Methodology independent 'unpack' method for unpacking fields based on pattern information.

 virtual function unsigned int
 svt_data::byte_pack

 (  ref logic [7:0] bytes [], input int unsigned offset , input int kind  ) 


 Superseded functions 
 vmm_data :: byte_pack 
 Superseding functions 
 svt_cmd_channel_data :: byte_pack 
 svt_cmd_transaction_ix_data :: byte_pack 
 svt_cmd_transaction_stack_data :: byte_pack 
 svt_configuration :: byte_pack 
 svt_err_check :: byte_pack 
 svt_err_check_stats :: byte_pack 
 svt_svc_err_check_stats :: byte_pack 
 svt_exception :: byte_pack 
 svt_exception_list :: byte_pack 
 svt_mem :: byte_pack 
 svt_pattern_data_carrier :: byte_pack 
 svt_debug_opts_carrier :: byte_pack 
 svt_status :: byte_pack 
 svt_transaction :: byte_pack 
 svt_8b10b_data :: byte_pack 
 svt_mem_transaction :: byte_pack 
 svt_traffic_profile_transaction :: byte_pack 

  function unsigned int
 svt_data::byte_size

 (  int kind = -1  ) 


Returns the size (in bytes) required by the byte_pack operation based on the requested byte_size kind.

kind - This int indicates the type of byte_size being requested. Note that the 'kind' variable can be used to control this behavior, in which case this argument will be ignored.


 Superseded functions 
 vmm_data :: byte_size 
 Superseding functions 
 svt_cmd_channel_data :: byte_size 
 svt_cmd_transaction_ix_data :: byte_size 
 svt_cmd_transaction_stack_data :: byte_size 
 svt_configuration :: byte_size 
 svt_fifo_rate_control_configuration :: byte_size 
 svt_mem_configuration :: byte_size 
 svt_base_mem_suite_configuration :: byte_size 
 svt_mem_suite_configuration :: byte_size 
 svt_exception :: byte_size 
 svt_exception_list :: byte_size 
 svt_fifo_rate_control :: byte_size 
 svt_transaction :: byte_size 
 svt_8b10b_data :: byte_size 
 svt_mem_transaction :: byte_size 
 svt_traffic_profile_transaction :: byte_size 

 virtual function unsigned int
 svt_data::byte_unpack

 (  const ref logic [7:0] bytes [], input int unsigned offset , input int len , input int kind  ) 


 Superseded functions 
 vmm_data :: byte_unpack 
 Superseding functions 
 svt_cmd_channel_data :: byte_unpack 
 svt_cmd_transaction_ix_data :: byte_unpack 
 svt_cmd_transaction_stack_data :: byte_unpack 
 svt_configuration :: byte_unpack 
 svt_err_check :: byte_unpack 
 svt_err_check_stats :: byte_unpack 
 svt_svc_err_check_stats :: byte_unpack 
 svt_exception :: byte_unpack 
 svt_exception_list :: byte_unpack 
 svt_mem :: byte_unpack 
 svt_pattern_data_carrier :: byte_unpack 
 svt_debug_opts_carrier :: byte_unpack 
 svt_status :: byte_unpack 
 svt_transaction :: byte_unpack 
 svt_8b10b_data :: byte_unpack 
 svt_mem_transaction :: byte_unpack 
 svt_traffic_profile_transaction :: byte_unpack 

 static function timeunit_enum
 svt_data::calc_timeunit

 (   ) 


Calculates the timeunit that the VIP has been compiled in.

Return values - Enumerated value representing the time unit for the local compilation unit.

 virtual function bit
 svt_data::compare

 (  vmm_data to , output string diff , input int kind  ) 


 Superseded functions 
 vmm_data :: compare 
 Superseding functions 
 svt_cmd_channel_data :: compare 
 svt_cmd_transaction_ix_data :: compare 
 svt_cmd_transaction_stack_data :: compare 
 svt_configuration :: compare 
 svt_err_check :: compare 
 svt_err_check_stats :: compare 
 svt_svc_err_check_stats :: compare 
 svt_exception :: compare 
 svt_exception_list :: compare 
 svt_mem :: compare 
 svt_pattern_data_carrier :: compare 
 svt_debug_opts_carrier :: compare 
 svt_status :: compare 
 svt_transaction :: compare 
 svt_8b10b_data :: compare 
 svt_mem_transaction :: compare 
 svt_traffic_profile_transaction :: compare 

  function bit
 svt_data::compare_pattern_data

 (  svt_pattern_data rhs_pd , output string diff , input string name_override  ) 


Compare the information associated with a single pattern_data instance.

rhs_pd - The pattern data instance containing the compare value, plus the description of the field we are interested in.

diff - Describes any difference that was encountered.

name_override - Used in when the pattern data name doesn't reflect the actual field being compared (e.g., if comparing array elements).

  function bit
 svt_data::compare_via_pattern

 (  svt_pattern pttrn  ) 


This method takes advantage of the get_prop_val method to make a simple way to compare a property pattern with the contents of a data instance. The method simply uses each name specified in pttrn, uses get_prop_val to retrieve the corresponding value from the data instance, and compares it to the value stored in the pattern.

pttrn - Pattern to be compared against the values stored in the data instance.

Return values - Success (1) or failure (0) of the compare.

 virtual function vmm_data
 svt_data::copy

 (  vmm_data to = null  ) 


 Superseded functions 
 vmm_data :: copy 
 Superseding functions 
 svt_cmd_channel_data :: copy 
 svt_cmd_transaction_ix_data :: copy 
 svt_cmd_transaction_stack_data :: copy 
 svt_configuration :: copy 
 svt_err_check :: copy 
 svt_err_check_stats :: copy 
 svt_svc_err_check_stats :: copy 
 svt_exception :: copy 
 svt_exception_list :: copy 
 svt_mem :: copy 
 svt_pattern_data_carrier :: copy 
 svt_debug_opts_carrier :: copy 
 svt_status :: copy 
 svt_transaction :: copy 
 svt_8b10b_data :: copy 
 svt_mem_transaction :: copy 
 svt_traffic_profile_transaction :: copy 

  function bit
 svt_data::decode_pattern_data

 (  svt_pattern_data pd , ref string pd_string , input string delimiter  ) 


Simple utility used to convert an svt_pattern_data representation into its equivalent string property value representation.

pd - The pattern data being decoded.

pd_string - The resulting decoded value.

delimiter - String used as a delimiter, placed around the 'value' in complex data situations.

Return values - Status indicating the success/failure of the decode.

  function bit
 svt_data::decode_prop_val

 (  string prop_name , bit [1023:0] prop_val , ref string prop_val_string , input svt_pattern_data :: type_enum typ  ) 


Simple utility used to convert 'bit [1023:0]' property value representation into its equivalent string property value representation. If provided the type is used by the default implementation to choose an appropriate conversion method. If the type is specified as UNDEF then the the field is assumed to be an int field and the string is assumed to be an ascii int representation. Derived classes can extend this method to support other field representations such as strings, enums, bitvecs, etc.

prop_name - The name of the property being decoded.

prop_val - The bit vector decoding of prop_val_string.

prop_val_string - The resulting decoded value.

typ - Optional field type used to help in the decode effort.

Return values - Status indicating the success/failure of the decode.


 Superseding functions 
 svt_configuration :: decode_prop_val 
 svt_fifo_rate_control_configuration :: decode_prop_val 
 svt_mem_configuration :: decode_prop_val 
 svt_err_check_stats :: decode_prop_val 
 svt_transaction :: decode_prop_val 
 svt_8b10b_data :: decode_prop_val 
 svt_traffic_profile_transaction :: decode_prop_val 

  function void
 svt_data::display_get_prop_val_outcome

 (  bit success , string prop_name , bit [1023:0] prop_val , int array_ix , svt_data data_obj  ) 


Method to display the outcome of a get_prop_val operation.

success - Indicates whether the 'get' was successful.

prop_name - The name of a property in this class.

prop_val - The current value of the property that is being returned.

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 the sub-object is returned. In that case, the prop_val argument is meaningless.

  function void
 svt_data::display_set_prop_val_outcome

 (  bit success , string prop_name , bit [1023:0] prop_val , int array_ix  ) 


Method to display the outcome of a set_prop_val operation.

success - Indicates whether the 'set' was successful.

prop_name - The name of a property in this class.

prop_val - The value assigned to the property.

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.

  function void
 svt_data::do_all

 (  vmm_data :: do_what_e do_what , ref logic [7:0] pack [], const ref logic [7:0] unpack []  ) 


 Superseded functions 
 vmm_data :: do_all 
 Superseding functions 
 svt_configuration :: do_all 
 svt_err_check :: do_all 
 svt_err_check_stats :: do_all 
 svt_svc_err_check_stats :: do_all 
 svt_exception :: do_all 
 svt_exception_list :: do_all 
 svt_mem :: do_all 
 svt_pattern_data_carrier :: do_all 
 svt_debug_opts_carrier :: do_all 
 svt_status :: do_all 
 svt_transaction :: do_all 
 svt_8b10b_data :: do_all 
 svt_mem_transaction :: do_all 
 svt_traffic_profile_transaction :: do_all 

  function svt_pattern
 svt_data::do_allocate_pattern

 (   ) 


This is the base pattern allocation method, which must be implemented to support the 'automated operation' capabilities. VIPs not providing this support instead implement allocate_pattern. VIPs should provide one or the other, but not both.

The method allocates a pattern containing svt_pattern_data instances for all of the primitive data fields in the object. The svt_pattern_data :: name is normally set to the corresponding field name, the svt_pattern_data :: value is normally set to 0. For fields which are displayed but not owned, the method puts the current value in for svt_pattern_data :: value.

Note that most clients needing patterns should continue to call 'allocate_pattern' or one of the derived pattern methods. This is to to insure they get both the enabled and 'not enabled' pattern_data instances. The only exceptions at this point are:

Return values - An svt_pattern instance containing entries for all of the data fields.


 Superseding functions 
 svt_configuration :: do_allocate_pattern 
 svt_fifo_rate_control_configuration :: do_allocate_pattern 
 svt_mem_configuration :: do_allocate_pattern 
 svt_base_mem_suite_configuration :: do_allocate_pattern 
 svt_mem_suite_configuration :: do_allocate_pattern 
 svt_err_check_stats :: do_allocate_pattern 
 svt_exception :: do_allocate_pattern 
 svt_exception_list :: do_allocate_pattern 
 svt_fifo_rate_control :: do_allocate_pattern 
 svt_mem :: do_allocate_pattern 
 svt_pattern_data_carrier :: do_allocate_pattern 
 svt_status :: do_allocate_pattern 
 svt_transaction :: do_allocate_pattern 
 svt_8b10b_data :: do_allocate_pattern 
 svt_mem_transaction :: do_allocate_pattern 
 svt_traffic_profile_transaction :: do_allocate_pattern 

  function unsigned int
 svt_data::do_byte_pack

 (  ref logic [7:0] bytes [], input int unsigned offset , input int kind  ) 


Packs the object into the bytes buffer, beginning at offset, based on the requested byte_pack kind.

bytes - Buffer that will contain the packed bytes at the end of the operation.

offset - Offset into bytes where the packing is to begin.

kind - This int indicates the type of byte_pack being requested. Note that the 'kind' variable can be used to control this behavior, in which case this argument will be ignored.


 Superseded functions 
 vmm_data :: do_byte_pack 
 Superseding functions 
 svt_configuration :: do_byte_pack 
 svt_fifo_rate_control_configuration :: do_byte_pack 
 svt_mem_configuration :: do_byte_pack 
 svt_exception :: do_byte_pack 
 svt_exception_list :: do_byte_pack 
 svt_fifo_rate_control :: do_byte_pack 
 svt_transaction :: do_byte_pack 
 svt_8b10b_data :: do_byte_pack 
 svt_mem_transaction :: do_byte_pack 
 svt_traffic_profile_transaction :: do_byte_pack 

  function unsigned int
 svt_data::do_byte_unpack

 (  const ref logic [7:0] bytes [], input int unsigned offset , input int len , input int kind  ) 


Unpacks len bytes of the object from the bytes buffer, beginning at offset, based on the requested byte_unpack kind.

bytes - Buffer containing the bytes to be unpacked.

offset - Offset into bytes where the unpacking is to begin.

len - Number of bytes to be unpacked.

kind - This int indicates the type of byte_unpack being requested. Note that the 'kind' variable can be used to control this behavior, in which case this argument will be ignored.


 Superseded functions 
 vmm_data :: do_byte_unpack 
 Superseding functions 
 svt_configuration :: do_byte_unpack 
 svt_fifo_rate_control_configuration :: do_byte_unpack 
 svt_mem_configuration :: do_byte_unpack 
 svt_exception :: do_byte_unpack 
 svt_exception_list :: do_byte_unpack 
 svt_fifo_rate_control :: do_byte_unpack 
 svt_transaction :: do_byte_unpack 
 svt_8b10b_data :: do_byte_unpack 
 svt_mem_transaction :: do_byte_unpack 
 svt_traffic_profile_transaction :: do_byte_unpack 

  function bit
 svt_data::do_compare

 (  vmm_data to , output string diff , input int kind  ) 


Compares the object with to, based on the requested compare kind. Differences are placed in diff.

to - vmm_data object to be compared against.

diff - String indicating the differences between this and to.

kind - This int indicates the type of compare to be attempted. Only supported kind value is svt_data :: COMPLETE, which results in comparisons of the non-static data members. All other kind values result in a return value of 1. Note that the 'kind' variable can be used to control this behavior, in which case this argument will be ignored.


 Superseded functions 
 vmm_data :: do_compare 
 Superseding functions 
 svt_fifo_rate_control_configuration :: do_compare 
 svt_mem_configuration :: do_compare 
 svt_base_mem_suite_configuration :: do_compare 
 svt_mem_suite_configuration :: do_compare 
 svt_exception :: do_compare 
 svt_exception_list :: do_compare 
 svt_mem :: do_compare 
 svt_transaction :: do_compare 
 svt_8b10b_data :: do_compare 
 svt_mem_transaction :: do_compare 
 svt_traffic_profile_transaction :: do_compare 

  function vmm_data
 svt_data::do_copy

 (  vmm_data to = null  ) 


Copies the object into to, allocating if necessay.

to - Destination class for the copy operation


 Superseded functions 
 vmm_data :: do_copy 
 Superseding functions 
 svt_configuration :: do_copy 
 svt_exception :: do_copy 
 svt_exception_list :: do_copy 
 svt_fifo_rate_control :: do_copy 
 svt_transaction :: do_copy 
 svt_traffic_profile_transaction :: do_copy 

  function bit
 svt_data::do_is_valid

 (  bit silent = 1, int kind = -1  ) 


Checks to see that the data field values are valid.

silent - bit indicating whether failures should result in warning messages.

kind - This int indicates the type of is_avalid check to attempt. Only supported kind value is svt_data :: COMPLETE, which results in verification that the non-static data members are valid. All other kind values result in a return value of 1. Note that the 'kind' variable can be used to control this behavior, in which case this argument will be ignored.


 Superseded functions 
 vmm_data :: do_is_valid 
 Superseding functions 
 svt_fifo_rate_control_configuration :: do_is_valid 
 svt_mem_configuration :: do_is_valid 
 svt_exception :: do_is_valid 
 svt_exception_list :: do_is_valid 
 svt_transaction :: do_is_valid 
 svt_8b10b_data :: do_is_valid 
 svt_mem_transaction :: do_is_valid 
 svt_traffic_profile_transaction :: do_is_valid 

  function bit
 svt_data::encode_prop_val

 (  string prop_name , string prop_val_string , ref bit [1023:0] prop_val , input svt_pattern_data :: type_enum typ  ) 


Simple utility used to convert string property value representation into its equivalent 'bit [1023:0]' property value representation. If provided the type is used by the default implementation to choose an appropriate conversion method. If the type is specified as UNDEF then the the field is assumed to be an int field and the string is assumed to be an ascii int representation. Derived classes can extend this method to support other field representations such as strings, enums, bitvecs, etc.

prop_name - The name of the property being encoded.

prop_val_string - The string describing the value to be encoded.

prop_val - The bit vector encoding of prop_val_string.

typ - Optional field type used to help in the encode effort.

Return values - Status indicating the success/failure of the encode.


 Superseding functions 
 svt_fifo_rate_control_configuration :: encode_prop_val 
 svt_mem_configuration :: encode_prop_val 
 svt_err_check_stats :: encode_prop_val 
 svt_transaction :: encode_prop_val 
 svt_8b10b_data :: encode_prop_val 
 svt_traffic_profile_transaction :: encode_prop_val 

  function type_enum
 svt_data::find_type

 (  string prop_name  ) 


Utility method which can be used to get the 'type' of the indicated property.

  function string
 svt_data::get_class_name

 (   ) 


Returns the name of this class, or a class derived from this class.

 Superseding functions 
 svt_err_check_stats :: get_class_name 
 svt_svc_err_check_stats :: get_class_name 
 svt_pattern_data_carrier :: get_class_name 
 svt_debug_opts_carrier :: get_class_name 

  function bit
 svt_data::get_do_compare_done

 (   ) 


Utility to obtain the do_compare_done setting for the object.

  function bit
 svt_data::get_do_pack_done

 (   ) 


Utility to obtain the do_pack_done setting for the object.

 static function string
 svt_data::get_environment_variable_value

 (  string method_name , string env_var_name , vmm_log log , bit is_optional = 0  ) 


Function which can be used to get access to an environment variable.

method_name - The method used to prefix the message.

env_var_name - The environment variable being accessed.

log - Used to report any issues.

is_optional - Indicates whether failure to find the environment variable is a problem.

Return values - Provides the value that was found for the envirionment variable.

  function string
 svt_data::get_mcd_class_name

 (   ) 


Returns the name of this class, or a class derived from this class.

 Superseding functions 
 svt_fifo_rate_control_configuration :: get_mcd_class_name 
 svt_mem_configuration :: get_mcd_class_name 
 svt_base_mem_suite_configuration :: get_mcd_class_name 
 svt_mem_suite_configuration :: get_mcd_class_name 
 svt_fifo_rate_control :: get_mcd_class_name 
 svt_mem :: get_mcd_class_name 
 svt_8b10b_data :: get_mcd_class_name 
 svt_mem_transaction :: get_mcd_class_name 
 svt_traffic_profile_transaction :: get_mcd_class_name 

  function svt_pa_object_data
 svt_data::get_pa_obj_data

 (  string uid = "", string typ = "", string parent_uid = "", string channel = ""  ) 


This method returns PA object which contains the PA header information for XML or FSDB.

uid - Optional string indicating the unique identification value for object. If not provided uses the 'get_uid' method to retrieve the value.

typ - Optional string indicating the 'type' of the object. If not provided uses the type name for the class.

parent_uid - Optional string indicating the UID of the object's parent. If not provided the method assumes there is no parent.

channel - Optional string indicating an object channel. If not provided the method assumes there is no channel.

Return values - The requested object block description.


 Superseding functions 
 svt_transaction :: get_pa_obj_data 

  function bit
 svt_data::get_prop_val

 (  string prop_name , ref bit [1023:0] prop_val , input int array_ix , ref svt_data data_obj  ) 


This method gets the value of a single named property.

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. In that case, the prop_val argument is meaningless.

When this command is used by a component's command interface, the component 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.

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 component 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.


 Superseding functions 
 svt_cmd_channel_data :: get_prop_val 
 svt_cmd_transaction_ix_data :: get_prop_val 
 svt_cmd_transaction_stack_data :: get_prop_val 
 svt_configuration :: get_prop_val 
 svt_fifo_rate_control_configuration :: get_prop_val 
 svt_mem_configuration :: get_prop_val 
 svt_base_mem_suite_configuration :: get_prop_val 
 svt_mem_suite_configuration :: get_prop_val 
 svt_err_check :: get_prop_val 
 svt_err_check_stats :: get_prop_val 
 svt_exception :: get_prop_val 
 svt_exception_list :: get_prop_val 
 svt_fifo_rate_control :: get_prop_val 
 svt_mem :: get_prop_val 
 svt_pattern_data_carrier :: get_prop_val 
 svt_status :: get_prop_val 
 svt_transaction :: get_prop_val 
 svt_8b10b_data :: get_prop_val 
 svt_mem_transaction :: get_prop_val 
 svt_traffic_profile_transaction :: get_prop_val 

  function bit
 svt_data::get_prop_val_via_pattern

 (  ref svt_pattern pttrn  ) 


This method takes advantage of the get_prop_val method to make a simple way to extract a property pattern from a data instance. The method simply takes all of the names specified in pttrn, and uses get_prop_val to retrieve the corresponding value so it can be placed in the pattern.

pttrn - Pattern to be loaded from the data object.

Return values - Success (1) or failure (0) of the get operation.


 Superseding functions 
 svt_pattern_data_carrier :: get_prop_val_via_pattern 

  function string
 svt_data::get_suite_name

 (   ) 


Returns the suite name associated with an object.

 static function string
 svt_data::get_timeunit_str

 (  string class_name , vmm_log log  ) 


Returns the timeunit that the VIP has been compiled in as a string value.

class_name - The class making this request.

log - Used to report any issues.

Return values - String value representing the time unit for the local compilation unit.

  function string
 svt_data::get_uid

 (   ) 


This method can be used to obtain a unique identifier for a data object.

Return values - Unique identifier for the object.

  function svt_pattern
 svt_data::get_user_fsdb_props

 (   ) 


User method for providing additional properties, consisting of name/value pairs, that are to be included in any FSDB output.

Return values - Pattern object describing the user proprties.

  function string
 svt_data::get_xml_object_block_desc

 (  string obj_type = "", string obj_sub_type = "", string parent_uid = "", string channel = ""  ) 


This method returns a string for use in the XML object block which provides basic information about the object.

obj_type - Optional string indicating the 'type' of the object. If not provided uses the type name for the class.

obj_sub_type - Optional string indicating the sub-type of the object. If not provided the method assumes there is no sub-type.

parent_uid - Optional string indicating the UID of the object's parent. If not provided the method assumes there is no parent.

channel - Optional string indicating an object channel. If not provided the method assumes there is no channel.

Return values - The requested object block description.

  function bit
 svt_data::is_safe_as_ref

 (  svt_xml_writer writer  ) 


This method indicates whether it will be safe to reference this object in the output generated by the writer.

writer - Object which takes care of the basic write operations.

Return values - Indicates that the reference will be available (1) or not (0).

  function bit
 svt_data::is_silent

 (   ) 


Returns true if silent mode is currently enabled

 virtual function bit
 svt_data::is_valid

 (  bit silent = 1, int kind = -1  ) 


 Superseded functions 
 vmm_data :: is_valid 
 Superseding functions 
 svt_cmd_channel_data :: is_valid 
 svt_cmd_transaction_ix_data :: is_valid 
 svt_cmd_transaction_stack_data :: is_valid 
 svt_configuration :: is_valid 
 svt_err_check :: is_valid 
 svt_err_check_stats :: is_valid 
 svt_svc_err_check_stats :: is_valid 
 svt_exception :: is_valid 
 svt_exception_list :: is_valid 
 svt_mem :: is_valid 
 svt_pattern_data_carrier :: is_valid 
 svt_debug_opts_carrier :: is_valid 
 svt_status :: is_valid 
 svt_transaction :: is_valid 
 svt_8b10b_data :: is_valid 
 svt_mem_transaction :: is_valid 
 svt_traffic_profile_transaction :: is_valid 

  function bit
 svt_data::load

 (  int file  ) 


 Superseded functions 
 vmm_data :: load 

  function bit
 svt_data::load_from_string

 (  string text  ) 

  function bit
 svt_data::load_prop_vals

 (  string filename = "", int file = 0  ) 


This method loads the property values from the indicated file assuming a basic text format. If filename specified without file then creates file handle and uses it to load the values. If file specified without filename then uses file to load the values. If both filename and file specified than no load is attempted and the failure is indicated via the return.

filename - Defines the file location.

file - Handle to the file being used as the source for the load.

Return values - Indicates success (1) or failure (0) of the load.

  function bit
 svt_data::load_prop_vals_with_checks

 (  string filename = "", int file = 0  ) 


This method calls load_prop_vals, but enables checking on the file format and content.

filename - Defines the file location.

file - Handle to the file being used as the source for the load.

Return values - Indicates success (1) or failure (0) of the load.

  function int
 svt_data::log_base_2

 (  int val , bit round_up = 1  ) 


This method returns the log_base_2 of provided value.

val - Value for which log_base_2 is to be calculated.

round_up - Indicates if the log_base_2 should be rounded up to the next value if val is not an exact power of 2.

  function void
 svt_data::mcd_log_object

 (  int mcd_log_file , string mcd_parameter  ) 

  function void
 svt_data::new

 (  vmm_log log = null, string suite_spec = ""  ) 


CONSTRUCTOR: Creates a new instance of the data class.

log - An vmm_log object reference used to replace the default internal logger. The class extension that calls super.new should pass a reference to its own static log instance.

suite_spec - A String that identifies the product suite to which the data object belongs.


 Superseding functions 
 svt_configuration :: new 
 svt_fifo_rate_control_configuration :: new 
 svt_mem_configuration :: new 
 svt_base_mem_suite_configuration :: new 
 svt_mem_suite_configuration :: new 
 svt_exception :: new 
 svt_fifo_rate_control :: new 
 svt_status :: new 
 svt_transaction :: new 
 svt_8b10b_data :: new 
 svt_mem_transaction :: new 
 svt_traffic_profile_transaction :: new 

  function unsigned int
 svt_data::pack_pattern_data

 (  svt_pattern_data pd , ref logic [7:0] bytes [], input int unsigned offset  ) 


Pack the information associated with a single pattern_data instance.

  function int
 svt_data::power_of_2

 (  int val  ) 


This method returns the power of 2 of provided value.

val - value to plug in to get power of 2.

 virtual function string
 svt_data::psdisplay

 (  string prefix = ""  ) 


 Superseded functions 
 vmm_data :: psdisplay 
 Superseding functions 
 svt_cmd_channel_data :: psdisplay 
 svt_cmd_transaction_ix_data :: psdisplay 
 svt_cmd_transaction_stack_data :: psdisplay 
 svt_configuration :: psdisplay 
 svt_err_check :: psdisplay 
 svt_err_check_stats :: psdisplay 
 svt_svc_err_check_stats :: psdisplay 
 svt_exception :: psdisplay 
 svt_exception_list :: psdisplay 
 svt_mem :: psdisplay 
 svt_pattern_data_carrier :: psdisplay 
 svt_debug_opts_carrier :: psdisplay 
 svt_status :: psdisplay 
 svt_transaction :: psdisplay 
 svt_8b10b_data :: psdisplay 
 svt_mem_transaction :: psdisplay 
 svt_traffic_profile_transaction :: psdisplay 

  function int
 svt_data::reasonable_constraint_mode

 (  bit on_off  ) 


Method to turn reasonable constraints on/off as a block. This method is not implemented in this virtual class.

on_off - A bit that indicates whether the reasonable constraints should be turnd on (1) or off (0).


 Superseding functions 
 svt_fifo_rate_control_configuration :: reasonable_constraint_mode 
 svt_mem_configuration :: reasonable_constraint_mode 
 svt_base_mem_suite_configuration :: reasonable_constraint_mode 
 svt_mem_suite_configuration :: reasonable_constraint_mode 
 svt_exception_list :: reasonable_constraint_mode 
 svt_fifo_rate_control :: reasonable_constraint_mode 
 svt_8b10b_data :: reasonable_constraint_mode 
 svt_mem_transaction :: reasonable_constraint_mode 
 svt_traffic_profile_transaction :: reasonable_constraint_mode 

  function int
 svt_data::resolve_compare_kind

 (  int kind  ) 


Resolves the kind value used for compare operations.

kind - Value passed in to the method

Return values - Resolved value

  function int
 svt_data::resolve_is_valid_kind

 (  int kind  ) 


Resolves the kind value used for is_valid operations.

kind - Value passed in to the method

Return values - Resolved value

  function int
 svt_data::resolve_pack_kind

 (  int kind  ) 


Resolves the kind value used for pack/unpack operations.

kind - Value passed in to the method

Return values - Resolved value

  function real
 svt_data::safe_atoreal

 (  string ascii_real  ) 


Utility method which can be used to safely convert an ascii string to a real value, dealing with any embedded '_' characters.

ascii_real - String to be converted to a real value.

Return values - The result of the conversion.

  function void
 svt_data::save

 (  int file  ) 


 Superseded functions 
 vmm_data :: save 

  function bit
 svt_data::save_child_refs

 (  svt_xml_writer writer , string prefix = ""  ) 


This method can be used to write out Unique IDs for the children of this object using the XML format. The extended class must drive this process, but can use the save_ref method on the to individual children to output those children.

writer - Object which takes care of the basic write operations.

prefix - String to be placed at the beginning of each line in the file.

Return values - Indicates success (1) or failure (0) of the save.

  function bit
 svt_data::save_object_begin

 (  svt_xml_writer writer  ) 


This method uses the 'writer' class methods to write out the object begin data to file. This method is intoduced to resolve the Verdi call back issue where during concurrent transaction the order of the transaction has to be correct otherwise Verdi dumper APIs will have performance issue.

writer - Object which takes care of the basic write operations.

Return values - Indicates success (1) or failure (0) of the save.

  function bit
 svt_data::save_object_data

 (  svt_xml_writer writer , string prefix = ""  ) 


This method writes the object start to XML/FSDB file, This method is introduced to resolve the Verdi call back issue where during concurrent transaction the order of the transaction as to be correct otherwise Verdi dumper APIs will have performance issue.

writer - Object which takes care of the basic write operations.

prefix - Optional string to be placed at the begining of each line.

Return values - Indicates success (1) or failure (0) of the save.

  function bit
 svt_data::save_pattern_to_xml

 (  svt_xml_writer writer , svt_pa_object_data pa_obj_data , svt_pattern pttrn , string prefix = ""  ) 


This method writes the property values stored in the pattern to the indicated file using the XML format.

writer - Object which takes care of the basic write operations.

pa_obj_data - The 'svt_pa_object_data' which contains the PA header information.

pttrn - The pattern to be saved to XML.

prefix - String to be placed at the beginning of each line in the file.

Return values - Indicates success (1) or failure (0) of the save.

  function bit
 svt_data::save_prop_vals

 (  string filename = "", int file = 0, string prefix = ""  ) 


This method saves the property values to the indicated file using a basic text format. If filename specified without file then creates file handle and uses it to saves the values. If file specified without filename then uses file to save the values. If both filename and file specified than no save is attempted and the failure is indicated via the return.

filename - Defines the file location.

file - Handle to the file being used as the source for the load.

prefix - String to be placed at the beginning of each line in the file.

Return values - Indicates success (1) or failure (0) of the save.

  function bit
 svt_data::save_prop_vals_to_fsdb

 (  string inst_name , string parent_object_uid = "", string stream_attr_name stream_attr_name = [$], string stream_attr_val stream_attr_val = [$]  ) 


This method writes the property values associated with this data object to an FSDB file.

The supplied instance path must be a full instance path to the source of the data object. This path must identify an instance that is a sub-component of a top-level VIP component that is enabled for debug using debug opts. The routine will split out the top-level component instance from the provided instance name and obtain the registered VIP writer class using this value. The leaf path from the top-level component name is used as the FSDB channel identifier.

inst_name - The full instance path of the component that is writing the object to FSDB

parent_object_uid - Unique ID of the parent object

stream_attr_name - Queue of stream attribute names to add

stream_attr_val - Queue of stream attribute values to add

Return values - Indicates success (1) or failure (0) of the save.

  function bit
 svt_data::save_prop_vals_to_fsdb_internal

 (  string top_level_name , string object_channel , string parent_object_uid = "", string object_uid = "", string prefix = ""  ) 


This is an internal method and should not be used by external components.

top_level_name - The full instance path of the top level component that is writing the object to FSDB

object_channel - Channel that is being used to write the object to FSDB

parent_object_uid - Unique ID of the parent object

object_uid - Unique ID of this object

prefix - String prepended to the property name

Return values - Indicates success (1) or failure (0) of the save.

  function bit
 svt_data::save_prop_vals_to_xml

 (  svt_xml_writer writer , string object_block_desc = "", string prefix = ""  ) 


This method writes the property values to the indicated file using the XML format. This method relies on the allocate_xml_pattern method to obtain the pattern for the property values to be saved. Therefore the preferred mechanism for altering the format is to overload the allocate_xml_pattern to define a different pattern.

writer - Object which takes care of the basic write operations.

object_block_desc - String that is placed in the 'object' block created for the data object. If not specified method relies on get_xml_object_block_desc method to get default description.

prefix - String to be placed at the beginning of each line in the file.

Return values - Indicates success (1) or failure (0) of the save.


 Superseding functions 
 svt_transaction :: save_prop_vals_to_xml 

  function bit
 svt_data::save_ref

 (  svt_xml_writer writer , string prefix = ""  ) 


This method can be used to write out the Unique IDs for an object using the XML format.

writer - Object which takes care of the basic write operations.

prefix - String to be placed at the beginning of each line in the file.

Return values - Indicates success (1) or failure (0) of the save.

  function bit
 svt_data::set_prop_object

 (  string prop_name , svt_data prop_obj , int array_ix  ) 


This method allows clients to assign an object to a single named property supported by a class derived from this class. This base class implementation always returns a value of '0' since the svt_data class has no 'object' properties.

prop_name - The name of a property in this class, or a derived class.

prop_obj - The object to assign to the property, expressed as svt_data instance.

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.


 Superseding functions 
 svt_pattern_data_carrier :: set_prop_object 

  function bit
 svt_data::set_prop_val

 (  string prop_name , bit [1023:0] prop_val , int array_ix  ) 


This method sets the value of a single named property. This method cannot be used to set the value of a sub-object.

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.


 Superseding functions 
 svt_cmd_channel_data :: set_prop_val 
 svt_cmd_transaction_ix_data :: set_prop_val 
 svt_cmd_transaction_stack_data :: set_prop_val 
 svt_configuration :: set_prop_val 
 svt_fifo_rate_control_configuration :: set_prop_val 
 svt_mem_configuration :: set_prop_val 
 svt_base_mem_suite_configuration :: set_prop_val 
 svt_mem_suite_configuration :: set_prop_val 
 svt_err_check :: set_prop_val 
 svt_err_check_stats :: set_prop_val 
 svt_exception :: set_prop_val 
 svt_exception_list :: set_prop_val 
 svt_fifo_rate_control :: set_prop_val 
 svt_pattern_data_carrier :: set_prop_val 
 svt_status :: set_prop_val 
 svt_transaction :: set_prop_val 
 svt_8b10b_data :: set_prop_val 
 svt_mem_transaction :: set_prop_val 
 svt_traffic_profile_transaction :: set_prop_val 

  function bit
 svt_data::set_prop_val_via_pattern

 (  svt_pattern pttrn  ) 


This method takes advantage of the set_prop_val method to make a simple way to take a common property pattern, and apply it across multiple data instances. The method simply takes all of the name/value pairs specified in pttrn, and uses set_prop_val to apply them to the data instance.

pttrn - Pattern to be applied to the data object.

Return values - Success (1) or failure (0) of the set operation.

  function void
 svt_data::set_prop_val_via_plusargs

 (  string plusarg_keyword  ) 


This method takes advantage of the set_prop_val method to load up a set of property values based on a command line plusarg value.

plusarg_keyword - The keyword that is used to identify the command line plusarg.

  function void
 svt_data::silent_mode

 (  bit mode  ) 


Disables generation of internal messages. This can be used to turn off debug messages while executing a method that may itself be used as an argument to VMM message macros. Using this feature resolves the issue of embedded messages.

Care must be taken when using this feature to re-enable messages after they have been disabled. Every call to silent_mode with a mode value 1 must be matched with a corresponding call to silent_mode with a mode value of 0.

mode - Enables or disables silent mode

 static function bit
 svt_data::strip_array_element_suffix

 (  vmm_log log , string prop_name , output string base_name , output int array_ix  ) 


Utility method which accepts a property name containing an array element index, and returns the base property name and the index value.

prop_name - Property name which includes an array element index

base_name - Output value which is the property name with the array index removed

array_ix - Output value which is the array index

Return values - Indicates whether the property name supplied was recognized as an array element (1 indicates that the array element was successfully removed, 0 indicates a failed attempt)

  function void
 svt_data::svt_post_do_all_do_byte_unpack

 (   ) 


User extendable hook which is called at the end of the byte_unpack method, after the call to 'do_all'. Extended classes can implement this method to add a customized action at the end of the byte_unpack method.

  function void
 svt_data::svt_post_do_all_do_copy

 (  vmm_data to  ) 


User extendable hook which is called at the end of the copy method, after the call to 'do_all'. Extended classes can implement this method to add a customized action at the end of the copy method.

  function string
 svt_data::svt_shorthand_psdisplay

 (  string prefix  ) 


Uses the SVT pattern data to format the display generated by calling psdisplay. This routine is called automatically when the SVT shorthand macros are used and shoudl not be called by extended classes.

prefix - String prefix appended to the formatted display

  function string
 svt_data::svt_shorthand_psdisplay_hook

 (  string prefix  ) 


User extendable hook which is called immediately after svt_shorthand_psdisplay. Extended classes can implement this method to add a customized display after the automated display.

 Superseding functions 
 svt_mem :: svt_shorthand_psdisplay_hook 

  function unsigned int
 svt_data::unpack_pattern_data

 (  svt_pattern_data pd , const ref logic [7:0] bytes [], input int unsigned offset  ) 


Unpack the information associated with a single pattern_data instance.

  function void
 svt_data::vmm_opts_via_pattern

 (   ) 


This method takes advantage of the set_prop_val method to implement the vmm_opts feature. The method uses the name and type values from the pattern to test whether a value corresponding to that property name has been supplied via vmm_opts. If a value has been supplied, then set_prop_val is used to set the value of the property.

Member Attribute Documentation

 static int  attribute
 svt_data::display_kind = -1


Used by all svt_data derived display methods to limit the contents of the string generated by the 'psdisplay' method and put to the log by the 'display' method.

A value of -1 (svt_data :: RELEVANT) indicates all display calls should only display the relevant data, as defined by the current transaction values, configuration settings, etc.

If a value of svt_data :: COMPLETE is specified, then all data fields are displayed.

Some data classes may respond to additional kind values. The interpretations for these values are defined in the classes which support them. If one of these additional kind values is specified when the display method is called for a data class which does not support the specified kind, the display implemented for svt_data :: RELEVANT will be done.

Since this field is not owned by an individual instance, it is not copied, compared, etc., like the other svt_data properties.

 int  attribute
 svt_data::kind = svt_data::UNASSIGNED


Used as an alternate method for the 'kind' argument to compare, is_valid, byte_size, byte_pack, and byte_unpack. If set to a value other than 10, then this value will be used rather than the 'kind' value that is passed into these methods or the policy class that is passed in. Acceptible values are RELEVANT and COMPLETE.

NOTE: For OVM and UVM users, the 'abstract' and 'physical' attributes of the comparer and packer policy classes are used to mimic the 'kind' argument. However, begining with the UVM 1800.2 2017 release these properties have been removed from these policy classes, and so this property is the only mechanism to control this.

 vmm_log  attribute
 svt_data::log


Log instance that will be passed in from a derived class (through the constructor).

 static int  attribute
 svt_data::max_array_elem_display = SVT_MAX_ARRAY_ELEM_DISPLAY_DEFAULT


Used by all svt_data derived display methods to limit the number of array entries which are displayed whenever an array data member is displayed. If the number of array elements is less than or equal to the max_array_elem_display value or max_array_elem_display is set to -1, then all array elements are displayed. If max_array_elem_display is set to 0, then only the array size will be displayed. Otherwise max_array_elem_display array elements are displayed. Since this field is not owned by an individual instance, it is not copied, compared, etc., like the other svt_data properties. Initial value set to SVT_MAX_ARRAY_ELEM_DISPLAY_DEFAULT so it can be overridden at compile time.

 static vmm_log  attribute
 svt_data::notify_log = new


Built-in shared log instance that will be used by the vmm_data.notify instance.

 static vmm_log  attribute
 svt_data::silent_log = new


Built-in shared log that is used for all messages issued when in silent mode.

 protected string  attribute
 svt_data::suite_name = ""


Identifies the product suite with which a derivative class is associated. Can be accessed through 'get_suite_name', but cannot be altered after object creation.

 static protected svt_data  attribute
 svt_data::__vmm_rhs


Member Typedef Documentation

 typedef enum  svt_data::kind_enum

Kinds commonly recognized (i.e., via constants) by compare, is_valid, byte_size, byte_pack, and byte_unpack. Although specified as an enum, the constant values associated with these enum elements allow them to be used to define the integer 'kind' parameter to these methods.

Classes sometimes include fields which are implied or enabled by other fields in the same class or by a field in a related class. The RELEVANT kind can be used to limit the operations to those class fields which have been enabled by these other related fields.

As an example of the 'same class' case, consider a master transaction which contains 'command' and 'data' fields. The data field would obviously be relevant when 'command == WRITE'. The data field would not be relevant, however, when 'command == READ'.

As an example of the 'related class' case, consider a system which can be configured to enable or disable specific transaction capabilities. For instance the existence of a data bus could be configurable. In this case if the 'enable_data' field in the configuration class would impact the relevance of the 'data' field in the transaction class.

If the COMPLETE kind value is specified that the operation is applied across all class fields, not just the implied or enabled fields.


RELEVANT(SVT_RELEVANT)
Limit operation to fields which are applicable based on current format, etc.
COMPLETE(SVT_COMPLETE)
Apply operation to all fields.
UNASSIGNED(SVT_UNASSIGNED)
Use the default operation (complete).

 typedef enum  svt_data::recursive_op_enum

Hierachical transaction options. These are used to control how embedded objects are handled for the 'copy' and 'compare' methods.

DEEP(SVT_DEEP_RECURSION)
SHALLOW(SVT_SHALLOW_RECURSION)
NULL(SVT_NULL_RECURSION)