svt_mem_address_mapper Class Reference

Inheritance diagram for class svt_mem_address_mapper:

List of all members.


Detailed Description

This is a container class used by the System Memory Manager for storing source and destination address range information and providing access to methods converting between the two address ranges.



Public Member Functions

function bit  contains_dest_addr ( svt_mem_addr_t dest_addr )
function bit  contains_src_addr ( svt_mem_addr_t src_addr )
function bit  get_allow_addr_range_overlap ( )
function svt_mem_addr_t  get_dest_addr ( svt_mem_addr_t src_addr )
function svt_mem_addr_t  get_dest_addr_hi ( )
function svt_mem_addr_t  get_dest_addr_lo ( )
function bit  get_dest_overlap ( svt_mem_addr_t dest_addr_lo, svt_mem_addr_t dest_addr_hi, output svt_mem_addr_t dest_addr_overlap_lo, output svt_mem_addr_t dest_addr_overlap_hi )
function string  get_formatted_name ( )
function string  get_name ( )
function svt_mem_addr_t  get_src_addr ( svt_mem_addr_t dest_addr )
function svt_mem_addr_t  get_src_addr_hi ( )
function svt_mem_addr_t  get_src_addr_lo ( )
function bit  get_src_overlap ( svt_mem_addr_t src_addr_lo, svt_mem_addr_t src_addr_hi, output svt_mem_addr_t src_addr_overlap_lo, output svt_mem_addr_t src_addr_overlap_hi )
function void  new ( svt_mem_addr_t src_addr_lo, svt_mem_addr_t dest_addr_lo, size_t size, uvm_report_object reporter, string name = "" )
function string  psdisplay ( string prefix = "" )
function void  set_allow_addr_range_overlap ( bit allow_addr_range_overlap )
function void  set_name ( string name )

Public Attributes

uvm_report_object  reporter 

Protected Attributes

protected string  name = ""; 

Member Typedefs


Member Function Documentation

  function bit
 svt_mem_address_mapper::contains_dest_addr

 (  svt_mem_addr_t dest_addr  ) 


Used to check whether 'dest_addr' is included in the destination address range covered by this address map.

dest_addr - The destination address for inclusion in the destination address range.

Return values - Indicates if the dest_addr is within the destination address range (1) or not (0).


 Superseding functions 
 svt_mem_address_mapper_stack :: contains_dest_addr 

  function bit
 svt_mem_address_mapper::contains_src_addr

 (  svt_mem_addr_t src_addr  ) 


Used to check whether 'src_addr' is included in the source address range covered by this address map.

src_addr - The source address for inclusion in the source address range.

Return values - Indicates if the src_addr is within the source address range (1) or not (0).


 Superseding functions 
 svt_mem_address_mapper_stack :: contains_src_addr 

  function bit
 svt_mem_address_mapper::get_allow_addr_range_overlap

 (   ) 


Used to get the allow_addr_range_overlap value.

Return values - Current setting of the allow_addr_range_overlap field.

  function svt_mem_addr_t
 svt_mem_address_mapper::get_dest_addr

 (  svt_mem_addr_t src_addr  ) 


Used to convert a source address into a destination address.

src_addr - The original source address to be converted.

Return values - The destination address based on conversion of the source address.


 Superseding functions 
 svt_mem_address_mapper_stack :: get_dest_addr 

  function svt_mem_addr_t
 svt_mem_address_mapper::get_dest_addr_hi

 (   ) 


Utility function for getting the high address in the destination address range.

Return values - High address value.


 Superseding functions 
 svt_mem_address_mapper_stack :: get_dest_addr_hi 

  function svt_mem_addr_t
 svt_mem_address_mapper::get_dest_addr_lo

 (   ) 


Utility function for getting the low address in the destination address range.

Return values - Low address value.


 Superseding functions 
 svt_mem_address_mapper_stack :: get_dest_addr_lo 

  function bit
 svt_mem_address_mapper::get_dest_overlap

 (  svt_mem_addr_t dest_addr_lo , svt_mem_addr_t dest_addr_hi , output svt_mem_addr_t dest_addr_overlap_lo , output svt_mem_addr_t dest_addr_overlap_hi  ) 


Used to check to see if there is an overlap between the provided destination address range and the destination address range defined for the svt_mem_address_mapper instance. Returns an indication of the overlap while also providing the range of the overlap.

dest_addr_lo - The low end of the address range to be checked for a destination range overlap.

dest_addr_hi - The high end of the address range to be checked for a destination range overlap.

dest_addr_overlap_lo - The low end of the address overlap if one exists.

dest_addr_overlap_hi - The high end of the address overlap if one exists.

Return values - Indicates if there is an overlap (1) or not (0).


 Superseding functions 
 svt_mem_address_mapper_stack :: get_dest_overlap 

  function string
 svt_mem_address_mapper::get_formatted_name

 (   ) 


Used to get the mapper name in a form that can easily be added to a message.

Return values - Name assigned to this mapper formatted for inclusion in a message.

  function string
 svt_mem_address_mapper::get_name

 (   ) 


Used to get the mapper name.

Return values - Name assigned to this mapper.

  function svt_mem_addr_t
 svt_mem_address_mapper::get_src_addr

 (  svt_mem_addr_t dest_addr  ) 


Used to convert a destination address into a source address.

dest_addr - The original destination address to be converted.

Return values - The source address based on conversion of the destination address.


 Superseding functions 
 svt_mem_address_mapper_stack :: get_src_addr 

  function svt_mem_addr_t
 svt_mem_address_mapper::get_src_addr_hi

 (   ) 


Utility function for getting the high address in the source address range.

Return values - High address value.


 Superseding functions 
 svt_mem_address_mapper_stack :: get_src_addr_hi 

  function svt_mem_addr_t
 svt_mem_address_mapper::get_src_addr_lo

 (   ) 


Utility function for getting the low address in the source address range.

Return values - Low address value.


 Superseding functions 
 svt_mem_address_mapper_stack :: get_src_addr_lo 

  function bit
 svt_mem_address_mapper::get_src_overlap

 (  svt_mem_addr_t src_addr_lo , svt_mem_addr_t src_addr_hi , output svt_mem_addr_t src_addr_overlap_lo , output svt_mem_addr_t src_addr_overlap_hi  ) 


Used to check to see if there is an overlap between the provided source address range and the source address range defined for the svt_mem_address_mapper instance. Returns an indication of the overlap while also providing the range of the overlap.

src_addr_lo - The low end of the address range to be checked for a source range overlap.

src_addr_hi - The high end of the address range to be checked for a source range overlap.

src_addr_overlap_lo - The low end of the address overlap if one exists.

src_addr_overlap_hi - The high end of the address overlap if one exists.

Return values - Indicates if there is an overlap (1) or not (0).


 Superseding functions 
 svt_mem_address_mapper_stack :: get_src_overlap 

  function void
 svt_mem_address_mapper::new

 (  svt_mem_addr_t src_addr_lo , svt_mem_addr_t dest_addr_lo , size_t size , uvm_report_object reporter , string name = ""  ) 


CONSTRUCTOR: Creates a new instance of the svt_mem_address_mapper class. Uses 'src_addr_lo', 'dest_addr_lo', and 'size' (i.e., number of addressable locations) to calculate the src_addr_hi (=src_addr_lo + size - 1) and dest_addr_hi (=dest_addr_lo + size - 1) values.

src_addr_lo - Low address in the source address range.

dest_addr_lo - Low address in the destination address range.

size - The size of the ranges defined in terms of addressable locations within the range. Used in combination with the src_addr_lo and dest_addr_lo arguments to identify the src_addr_hi and dest_addr_hi values. The mimimum value accepted is 1, and the maximum value accepted must not result in src_addr_hi or dest_addr_hi to be larger than the maximum addressable location.

reporter - Used to report messages.

name - (optional) Used to identify the mapper in any reported messages.

  function string
 svt_mem_address_mapper::psdisplay

 (  string prefix = ""  ) 


Generates short description of the address mapping represented by this object.

Return values - The generated description.


 Superseding functions 
 svt_mem_address_mapper_stack :: psdisplay 

  function void
 svt_mem_address_mapper::set_allow_addr_range_overlap

 (  bit allow_addr_range_overlap  ) 


Used to set the allow_addr_range_overlap value.

allow_addr_range_overlap - New setting for the allow_addr_range_overlap field.

  function void
 svt_mem_address_mapper::set_name

 (  string name  ) 


Used to set the mapper name.

name - New name to be assigned to this mapper


Member Attribute Documentation

 protected string  attribute
 svt_mem_address_mapper::name = ""


Name given to the mapper. Used to identify the mapper in any reported messages.

 uvm_report_object  attribute
 svt_mem_address_mapper::reporter


Reporter instance Used to report messages.

Member Typedef Documentation

 Typedefe'd string ==>   bit [SVT_MEM_MAX_ADDR_WIDTH:0]