uvm_recorder

The uvm_recorder class provides a policy object for recording uvm_objects.  The policies determine how recording should be done.

A default recorder instance, uvm_default_recorder, is used when the uvm_object::record is called without specifying a recorder.

Summary
uvm_recorder
The uvm_recorder class provides a policy object for recording uvm_objects.
Class Hierarchy
uvm_recorder
Class Declaration
class uvm_recorder extends uvm_object
Variables
tr_handleThis is an integral handle to a transaction object.
default_radixThis is the default radix setting if record_field is called without a radix.
physicalThis bit provides a filtering mechanism for fields.
abstractThis bit provides a filtering mechanism for fields.
identifierThis bit is used to specify whether or not an object’s reference should be recorded when the object is recorded.
recursion_policySets the recursion policy for recording objects.
Methods
get_type_nameReturns type name of the recorder.
record_fieldRecords an integral field (less than or equal to 4096 bits).
record_field_realRecords an real field.
record_objectRecords an object field.
record_stringRecords a string field.
record_timeRecords a time value.
record_genericRecords the name-value pair, where value has been converted to a string.

tr_handle

integer tr_handle = 0

This is an integral handle to a transaction object.  Its use is vendor specific.

A handle of 0 indicates there is no active transaction object.

default_radix

uvm_radix_enum default_radix = UVM_HEX

This is the default radix setting if record_field is called without a radix.

physical

bit physical = 1

This bit provides a filtering mechanism for fields.

The abstract and physical settings allow an object to distinguish between two different classes of fields.

It is up to you, in the uvm_object::do_record method, to test the setting of this field if you want to use the physical trait as a filter.

abstract

bit abstract = 1

This bit provides a filtering mechanism for fields.

The abstract and physical settings allow an object to distinguish between two different classes of fields.

It is up to you, in the uvm_object::do_record method, to test the setting of this field if you want to use the abstract trait as a filter.

identifier

bit identifier = 1

This bit is used to specify whether or not an object’s reference should be recorded when the object is recorded.

recursion_policy

uvm_recursion_policy_enum policy = UVM_DEFAULT_POLICY

Sets the recursion policy for recording objects.

The default policy is deep (which means to recurse an object).

get_type_name

Returns type name of the recorder.  Subtypes must override this method to enable the `uvm_record_field macro.

virtual function string get_type_name()

record_field

virtual function void record_field ( string  name,   
uvm_bitstream_t  value,   
int  size,   
uvm_radix_enum  radix  =  UVM_NORADIX )

Records an integral field (less than or equal to 4096 bits).  name is the name of the field.

value is the value of the field to record.  size is the number of bits of the field which apply.  radix is the uvm_radix_enum to use.

record_field_real

virtual function void record_field_real ( string  name,
real  value )

Records an real field.  value is the value of the field to record.

record_object

virtual function void record_object ( string  name,
uvm_object  value )

Records an object field.  name is the name of the recorded field.

This method uses the recursion_policy to determine whether or not to recurse into the object.

record_string

virtual function void record_string ( string  name,
string  value )

Records a string field.  name is the name of the recorded field.

record_time

virtual function void record_time ( string  name,
time  value )

Records a time value.  name is the name to record to the database.

record_generic

virtual function void record_generic ( string  name,
string  value )

Records the name-value pair, where value has been converted to a string.  For example:

recorder.record_generic("myvar",$sformatf("%0d",myvar));
The uvm_void class is the base class for all UVM classes.
virtual class uvm_object extends uvm_void
The uvm_object class is the base class for all UVM data and hierarchical classes.
class uvm_recorder extends uvm_object
The uvm_recorder class provides a policy object for recording uvm_objects.
integer tr_handle = 0
This is an integral handle to a transaction object.
uvm_radix_enum default_radix = UVM_HEX
This is the default radix setting if record_field is called without a radix.
virtual function void record_field ( string  name,   
uvm_bitstream_t  value,   
int  size,   
uvm_radix_enum  radix  =  UVM_NORADIX )
Records an integral field (less than or equal to 4096 bits).
bit physical = 1
This bit provides a filtering mechanism for fields.
bit abstract = 1
This bit provides a filtering mechanism for fields.
bit identifier = 1
This bit is used to specify whether or not an object’s reference should be recorded when the object is recorded.
uvm_recursion_policy_enum policy = UVM_DEFAULT_POLICY
Sets the recursion policy for recording objects.
virtual function void record_field_real ( string  name,
real  value )
Records an real field.
virtual function void record_object ( string  name,
uvm_object  value )
Records an object field.
virtual function void record_string ( string  name,
string  value )
Records a string field.
virtual function void record_time ( string  name,
time  value )
Records a time value.
virtual function void record_generic ( string  name,
string  value )
Records the name-value pair, where value has been converted to a string.
uvm_recorder uvm_default_recorder = new()
The default recording policy.
function void record ( uvm_recorder  recorder  =  null )
The record method deep-records this object’s properties according to an optional recorder policy.
virtual function void do_record ( uvm_recorder  recorder )
The do_record method is the user-definable hook called by the record method.
Macro for recording name-value pairs into a transaction recording database.
Specifies the radix to print or record in.