[source]

Class uvm_tlm_generic_payload

This class provides a transaction definition commonly used in memory-mapped bus-based systems. It's intended to be a general purpose transaction class that lends itself to many applications. The class is derived from uvm_sequence_item which enables it to be generated in sequences and transported to drivers through sequencers.

Constructors

function new ( string name ) [source]

Create a new instance of the generic payload. Initialize all the members to their default values.

Functions

virtual function void do_print ( uvm_printer printer ) [source]

Function- do_print

virtual function void do_copy ( uvm_object rhs ) [source]

Function- do_copy

virtual function bit do_compare ( uvm_object rhs, uvm_comparer comparer ) [source]

Function- do_compare

virtual function void do_pack ( uvm_packer packer ) [source]

Function- do_pack

We only pack m_length bytes of the m_data array, even if m_data is larger than m_length. Same treatment for the byte-enable array. We do not pack the extensions, if any, as we will be unable to unpack them.

virtual function void do_unpack ( uvm_packer packer ) [source]

Function- do_unpack

We only reallocate m_data/m_byte_enable if the new size is greater than their current size. We do not unpack extensions because we do not know what object types to allocate before we unpack into them. Extensions must be handled by user code.

virtual function void do_record ( uvm_recorder recorder ) [source]

Function- do_record

virtual function string convert2string ( ) [source]

Function- convert2string

virtual function uvm_tlm_command_e get_command ( ) [source]

Get the value of the m_command variable

virtual function void set_command ( uvm_tlm_command_e command ) [source]

Set the value of the m_command variable

virtual function bit is_read ( ) [source]

Returns true if the current value of the m_command variable is UVM_TLM_READ_COMMAND .

virtual function void set_read ( ) [source]

Set the current value of the m_command variable to UVM_TLM_READ_COMMAND .

virtual function bit is_write ( ) [source]

Returns true if the current value of the m_command variable is UVM_TLM_WRITE_COMMAND .

virtual function void set_write ( ) [source]

Set the current value of the m_command variable to UVM_TLM_WRITE_COMMAND .

virtual function void set_address ( bit[63:0] addr ) [source]

Set the value of the m_address variable

virtual function bit[63:0] get_address ( ) [source]

Get the value of the m_address variable

virtual function void get_data ( byte unsigned p ) [source]

Return the value of the m_data array

virtual function void set_data ( byte unsigned p ) [source]

Set the value of the m_data array

virtual function int unsigned get_data_length ( ) [source]

Return the current size of the m_data array

virtual function void set_data_length ( int unsigned length ) [source]

Set the value of the m_length

virtual function int unsigned get_streaming_width ( ) [source]

Get the value of the m_streaming_width array

virtual function void set_streaming_width ( int unsigned width ) [source]

Set the value of the m_streaming_width array

virtual function void get_byte_enable ( byte unsigned p ) [source]

Return the value of the m_byte_enable array

virtual function void set_byte_enable ( byte unsigned p ) [source]

Set the value of the m_byte_enable array

virtual function int unsigned get_byte_enable_length ( ) [source]

Return the current size of the m_byte_enable array

virtual function void set_byte_enable_length ( int unsigned length ) [source]

Set the size m_byte_enable_length of the m_byte_enable array i.e. m_byte_enable.size()

virtual function void set_dmi_allowed ( bit dmi ) [source]

DMI hint. Set the internal flag m_dmi to allow dmi access

virtual function bit is_dmi_allowed ( ) [source]

DMI hint. Query the internal flag m_dmi if allowed dmi access

virtual function uvm_tlm_response_status_e get_response_status ( ) [source]

Return the current value of the m_response_status variable

virtual function void set_response_status ( uvm_tlm_response_status_e status ) [source]

Set the current value of the m_response_status variable

virtual function bit is_response_ok ( ) [source]

Return TRUE if the current value of the m_response_status variable is UVM_TLM_OK_RESPONSE

virtual function bit is_response_error ( ) [source]

Return TRUE if the current value of the m_response_status variable is not UVM_TLM_OK_RESPONSE

virtual function string get_response_string ( ) [source]

Return the current value of the m_response_status variable as a string

function uvm_tlm_extension_base set_extension ( uvm_tlm_extension_base ext ) [source]

Add an instance-specific extension. Only one instance of any given extension type is allowed. If there is an existing extension instance of the type of ext , ext replaces it and its handle is returned. Otherwise, null is returned.

function int get_num_extensions ( ) [source]

Return the current number of instance specific extensions.

function uvm_tlm_extension_base get_extension ( uvm_tlm_extension_base ext_handle ) [source]

Return the instance specific extension bound under the specified key. If no extension is bound under that key, null is returned.

function void clear_extension ( uvm_tlm_extension_base ext_handle ) [source]

Remove the instance-specific extension bound under the specified key.

function void clear_extensions ( ) [source]

Remove all instance-specific extensions