scc 2025.09
SystemC components library
axi Namespace Reference

TLM2.0 components modeling AHB. More...

Namespaces

namespace  pin
 pin level adapters
namespace  pe
 protocol engine implementations

Classes

class  axi_initiator_base
 axi_initiator class provides an input_socket for incoming TLM transactions. It attaches AXI extension to the tlm_generic_payload and forwards it to the AXI Protocol Engine. More...
class  axi_initiator
class  axi_target_base
 axi_target class instantiates the AXI Protocol Engine. It accesses the Protocol Engine with access() callback function and forwards the transactions via the output_socket. More...
class  axi_target
struct  master_types
struct  lite_master_types
struct  slave_types
struct  lite_slave_types
struct  signal_types
struct  select_if
struct  select_if< true, T, S >
struct  axi4_cfg
struct  axi4_lite_cfg
struct  ace_cfg
struct  aw_axi_lite
 Write address channel signals. More...
struct  aw_axi
struct  wdata_axi_lite
 write data channel signals More...
struct  wdata_axi
struct  b_axi_lite
 write response channel signals More...
struct  b_axi
struct  ar_axi_lite
 read address channel signals More...
struct  ar_axi
struct  rresp_axi_lite
 Read data channel signals. More...
struct  rresp_axi
struct  rresp_ace
struct  ar_ace
struct  aw_ace
struct  ac_ace
 snoop address(AC) channel signals More...
struct  cd_ace
 snoop data(cd) channel signals More...
struct  cr_ace
 snoop response(cr) channel signals More...
struct  enable_for_enum
struct  common
struct  request
struct  axi3
struct  axi4
struct  ace
struct  response
struct  ace_response
struct  axi_extension
struct  axi3_extension
struct  axi4_extension
struct  ace_extension
struct  axi_protocol_types
 The AXI protocol traits class. Since the protocoll defines additional non-ignorable phases a dedicated protocol traits class has to be defined. More...
class  bw_blocking_transport_if
class  ace_bw_transport_if
struct  axi_initiator_socket
struct  axi_target_socket
struct  ace_initiator_socket
struct  ace_target_socket
struct  enable_for_enum< burst_e >
struct  enable_for_enum< lock_e >
struct  enable_for_enum< domain_e >
struct  enable_for_enum< bar_e >
struct  enable_for_enum< snoop_e >
struct  enable_for_enum< resp_e >

Typedefs

template<unsigned int BUSWDTH = 32, unsigned int ADDRWDTH = 32, unsigned int IDWDTH = 32, unsigned int USERWDTH = 1>
using axi5_cfg = axi4_cfg<BUSWDTH, ADDRWDTH, IDWDTH, USERWDTH>
template<typename CFG, typename TYPES = master_types>
using wdata_ace = wdata_axi<CFG, TYPES>
 alias declaration for rresp_ch_ace, wdata_ch_ace, b_ch_ace???
template<typename CFG, typename TYPES = master_types>
using b_ace = b_axi<CFG, TYPES>
template<typename CFG, typename TYPES = master_types>
using wdata_ace_lite = wdata_axi<CFG, TYPES>
template<typename CFG, typename TYPES = master_types>
using b_ace_lite = b_axi<CFG, TYPES>
template<typename CFG, typename TYPES = master_types>
using rresp_ace_lite = rresp_axi<CFG, TYPES>
template<typename CFG, typename TYPES = master_types>
using aw_ace_lite = aw_ace<CFG, TYPES>
template<typename CFG, typename TYPES = master_types>
using ar_ace_lite = ar_ace<CFG, TYPES>
using axi_payload = tlm::tlm_generic_payload
 aliases for payload and phase types
using axi_phase = tlm::tlm_phase
template<typename TYPES = axi_protocol_types>
using axi_fw_transport_if = tlm::tlm_fw_transport_if<TYPES>
 alias declaration for the forward interface
template<typename TYPES = axi_protocol_types>
using axi_bw_transport_if = tlm::tlm_bw_transport_if<TYPES>
 alias declaration for the backward interface:
template<typename TYPES = axi_protocol_types>
using ace_fw_transport_if = tlm::tlm_fw_transport_if<TYPES>
 alias declaration for the ACE forward interface
using type_index = sc_core::sc_type_index

Enumerations

enum class  flavor_e { AXI , ACEL , ACE }
enum class  burst_e : uint8_t { FIXED = 0 , INCR = 1 , WRAP = 2 }
enum class  lock_e : uint8_t { NORMAL = 0x0 , EXLUSIVE = 0x1 , LOCKED = 0x2 }
enum class  domain_e : uint8_t { NON_SHAREABLE = 0x0 , INNER_SHAREABLE = 0x1 , OUTER_SHAREABLE = 0x2 , SYSTEM = 0x3 }
enum class  bar_e : uint8_t { RESPECT_BARRIER = 0x0 , MEMORY_BARRIER = 0x1 , IGNORE_BARRIER = 0x2 , SYNCHRONISATION_BARRIER = 0x3 }
enum class  snoop_e : uint8_t {
  READ_NO_SNOOP = 0x10 , READ_ONCE = 0x0 , READ_SHARED = 0x1 , READ_CLEAN = 0x2 ,
  READ_NOT_SHARED_DIRTY = 0x3 , READ_ONCE_CLEAN_INVALID = 0x4 , READ_ONCE_MAKE_INVALID = 0x5 , READ_UNIQUE = 0x7 ,
  CLEAN_UNIQUE = 0xb , MAKE_UNIQUE = 0xc , CLEAN_SHARED = 0x8 , CLEAN_INVALID = 0x9 ,
  CLEAN_SHARED_PERSIST = 0xa , MAKE_INVALID = 0xd , DVM_COMPLETE = 0xe , DVM_MESSAGE = 0xf ,
  BARRIER = 0x40 , WRITE_NO_SNOOP = 0x30 , WRITE_UNIQUE = 0x20 , WRITE_LINE_UNIQUE = 0x21 ,
  WRITE_CLEAN = 0x22 , WRITE_BACK = 0x23 , EVICT = 0x24 , WRITE_EVICT = 0x25 ,
  CMO_ON_WRITE = 0x26 , WRITE_UNIQUE_PTL_STASH = 0x28 , WRITE_UNIQUE_FULL_STASH = 0x29 , STASH_ONCE_SHARED = 0x2c ,
  STASH_ONCE_UNIQUE = 0x2d , STASH_TRANSLATION = 0x2e
}
enum class  atop_low_e {
  ADD = 0x0 , CLR = 0x1 , EOR = 0x2 , SET = 0x3 ,
  SMAX = 0x4 , SMIN = 0x5 , UMAX = 0x6 , UMIN = 0x7
}
enum class  atop_enc_e {
  NonAtomic = 0x00 , AtomicStore = 0x10 , AtomicLoad = 0x20 , AtomicSwap = 0x30 ,
  AtomicCompare = 0x31
}
enum class  resp_e : uint8_t { OKAY = 0x0 , EXOKAY = 0x1 , SLVERR = 0x2 , DECERR = 0x3 }

Functions

std::string concat (const char *prefix, const char *name)
template<>
const char * to_char< snoop_e > (snoop_e v)
template<>
const char * to_char< burst_e > (burst_e v)
template<>
const char * to_char< lock_e > (lock_e v)
template<>
const char * to_char< domain_e > (domain_e v)
template<>
const char * to_char< bar_e > (bar_e v)
template<>
const char * to_char< resp_e > (resp_e v)
std::ostream & operator<< (std::ostream &os, const tlm::tlm_generic_payload &t)
template<>
char const * is_valid_msg< axi::ace_extension > (axi::ace_extension *ext)
template<>
char const * is_valid_msg< axi::axi4_extension > (axi::axi4_extension *ext)
template<>
char const * is_valid_msg< axi::axi3_extension > (axi::axi3_extension *ext)
template<typename E>
into (typename std::underlying_type< E >::type t)
template<typename E, typename ULT = typename std::underlying_type<E>::type, typename X = typename std::enable_if<std::is_enum<E>::value && !std::is_convertible<E, ULT>::value, bool>::type>
constexpr ULT to_int (E t)
template<typename E>
const char * to_char (E t)
template<typename E, typename std::enable_if< enable_for_enum< E >::value, bool >::type>
std::ostream & operator<< (std::ostream &os, E e)
 DECLARE_EXTENDED_PHASE (BEGIN_PARTIAL_REQ)
 DECLARE_EXTENDED_PHASE (END_PARTIAL_REQ)
 DECLARE_EXTENDED_PHASE (BEGIN_PARTIAL_RESP)
 DECLARE_EXTENDED_PHASE (END_PARTIAL_RESP)
 DECLARE_EXTENDED_PHASE (ACK)
template<typename EXT>
bool is_valid (EXT &ext)
template<typename EXT>
bool is_valid (EXT *ext)
template<typename EXT>
char const * is_valid_msg (EXT &ext)
template<typename EXT>
char const * is_valid_msg (EXT *ext)
bool is_dataless (axi::ace_extension const *ext)
unsigned get_axi_id (axi::axi_protocol_types::tlm_payload_type const &trans)
unsigned get_axi_id (axi::axi_protocol_types::tlm_payload_type const *trans)
bool is_burst (const axi::axi_protocol_types::tlm_payload_type &trans)
bool is_burst (const axi::axi_protocol_types::tlm_payload_type *trans)
unsigned get_burst_length (const request &r)
unsigned get_burst_length (const request *r)
unsigned get_burst_length (const axi::axi_protocol_types::tlm_payload_type &trans)
unsigned get_burst_length (const axi::axi_protocol_types::tlm_payload_type *trans)
unsigned get_burst_size (const request &r)
unsigned get_burst_size (const request *r)
unsigned get_burst_size (const axi::axi_protocol_types::tlm_payload_type &trans)
unsigned get_burst_size (const axi::axi_protocol_types::tlm_payload_type *trans)
burst_e get_burst_type (const axi::axi_protocol_types::tlm_payload_type &trans)
burst_e get_burst_type (const axi::axi_protocol_types::tlm_payload_type *trans)
unsigned get_cache (const axi::axi_protocol_types::tlm_payload_type &trans)
unsigned get_cache (const axi::axi_protocol_types::tlm_payload_type *trans)
template<>
burst_e into< burst_e > (typename std::underlying_type< burst_e >::type t)
template<>
lock_e into< lock_e > (typename std::underlying_type< lock_e >::type t)
template<>
domain_e into< domain_e > (typename std::underlying_type< domain_e >::type t)
template<>
bar_e into< bar_e > (typename std::underlying_type< bar_e >::type t)
template<>
snoop_e into< snoop_e > (typename std::underlying_type< snoop_e >::type t)
template<>
resp_e into< resp_e > (typename std::underlying_type< resp_e >::type t)

Variables

const sc_core::sc_time CLK_DELAY = 1_ps

Detailed Description

TLM2.0 components modeling AHB.

SCV components for AXI/ACE.

LWTR components for AXI/ACE.

TLM2.0 components modeling AXI/ACE.

TLM2.0 components modeling AXI.

Typedef Documentation

◆ ace_fw_transport_if

template<typename TYPES = axi_protocol_types>
using axi::ace_fw_transport_if = tlm::tlm_fw_transport_if<TYPES>

alias declaration for the ACE forward interface

Definition at line 958 of file axi_tlm.h.

◆ ar_ace_lite

template<typename CFG, typename TYPES = master_types>
using axi::ar_ace_lite = ar_ace<CFG, TYPES>

Definition at line 719 of file signal_if.h.

◆ aw_ace_lite

template<typename CFG, typename TYPES = master_types>
using axi::aw_ace_lite = aw_ace<CFG, TYPES>

Definition at line 718 of file signal_if.h.

◆ axi5_cfg

template<unsigned int BUSWDTH = 32, unsigned int ADDRWDTH = 32, unsigned int IDWDTH = 32, unsigned int USERWDTH = 1>
using axi::axi5_cfg = axi4_cfg<BUSWDTH, ADDRWDTH, IDWDTH, USERWDTH>

Definition at line 93 of file signal_if.h.

◆ axi_bw_transport_if

template<typename TYPES = axi_protocol_types>
using axi::axi_bw_transport_if = tlm::tlm_bw_transport_if<TYPES>

alias declaration for the backward interface:

Definition at line 956 of file axi_tlm.h.

◆ axi_fw_transport_if

template<typename TYPES = axi_protocol_types>
using axi::axi_fw_transport_if = tlm::tlm_fw_transport_if<TYPES>

alias declaration for the forward interface

Definition at line 954 of file axi_tlm.h.

◆ axi_payload

using axi::axi_payload = tlm::tlm_generic_payload

aliases for payload and phase types

Definition at line 914 of file axi_tlm.h.

◆ axi_phase

using axi::axi_phase = tlm::tlm_phase

Definition at line 915 of file axi_tlm.h.

◆ b_ace

template<typename CFG, typename TYPES = master_types>
using axi::b_ace = b_axi<CFG, TYPES>

Definition at line 714 of file signal_if.h.

◆ b_ace_lite

template<typename CFG, typename TYPES = master_types>
using axi::b_ace_lite = b_axi<CFG, TYPES>

Definition at line 716 of file signal_if.h.

◆ rresp_ace_lite

template<typename CFG, typename TYPES = master_types>
using axi::rresp_ace_lite = rresp_axi<CFG, TYPES>

Definition at line 717 of file signal_if.h.

◆ type_index

using axi::type_index = sc_core::sc_type_index

Definition at line 967 of file axi_tlm.h.

◆ wdata_ace

template<typename CFG, typename TYPES = master_types>
using axi::wdata_ace = wdata_axi<CFG, TYPES>

alias declaration for rresp_ch_ace, wdata_ch_ace, b_ch_ace???

Definition at line 713 of file signal_if.h.

◆ wdata_ace_lite

template<typename CFG, typename TYPES = master_types>
using axi::wdata_ace_lite = wdata_axi<CFG, TYPES>

Definition at line 715 of file signal_if.h.

Enumeration Type Documentation

◆ atop_enc_e

enum class axi::atop_enc_e
strong

Definition at line 146 of file axi_tlm.h.

◆ atop_low_e

enum class axi::atop_low_e
strong

Definition at line 144 of file axi_tlm.h.

◆ bar_e

enum class axi::bar_e : uint8_t
strong

the barrier type enumeration class

Enumerator
MEMORY_BARRIER 

Normal access, respecting barriers.

IGNORE_BARRIER 

Memory barrier.

SYNCHRONISATION_BARRIER 

Normal access, ignoring barriers.

Definition at line 89 of file axi_tlm.h.

◆ burst_e

enum class axi::burst_e : uint8_t
strong

the burst type enumeration class

Enumerator
INCR 

fixed address burst

WRAP 

incrementing burst

Definition at line 73 of file axi_tlm.h.

◆ domain_e

enum class axi::domain_e : uint8_t
strong

the domain type enumeration class

Definition at line 85 of file axi_tlm.h.

◆ flavor_e

enum class axi::flavor_e
strong

Definition at line 27 of file axi_tlm.h.

◆ lock_e

enum class axi::lock_e : uint8_t
strong

the lock type enumeration class

Definition at line 81 of file axi_tlm.h.

◆ resp_e

enum class axi::resp_e : uint8_t
strong

the response type enumeration class

Definition at line 156 of file axi_tlm.h.

◆ snoop_e

enum class axi::snoop_e : uint8_t
strong

the snoop type enumeration class. Since the interpretation depends of other setting there are double defined entries

Definition at line 99 of file axi_tlm.h.

Function Documentation

◆ concat()

std::string axi::concat ( const char * prefix,
const char * name )
inline

Definition at line 141 of file signal_if.h.

◆ get_axi_id() [1/2]

unsigned axi::get_axi_id ( axi::axi_protocol_types::tlm_payload_type const & trans)
inline

Definition at line 1126 of file axi_tlm.h.

◆ get_axi_id() [2/2]

unsigned axi::get_axi_id ( axi::axi_protocol_types::tlm_payload_type const * trans)
inline

Definition at line 1137 of file axi_tlm.h.

◆ get_burst_length() [1/4]

unsigned axi::get_burst_length ( const axi::axi_protocol_types::tlm_payload_type & trans)
inline

get length of a burst

Parameters
trans
Returns
the number of beats

Definition at line 1179 of file axi_tlm.h.

◆ get_burst_length() [2/4]

unsigned axi::get_burst_length ( const axi::axi_protocol_types::tlm_payload_type * trans)
inline

get length of a burst

Parameters
trans
Returns
the number of beats

Definition at line 1194 of file axi_tlm.h.

◆ get_burst_length() [3/4]

unsigned axi::get_burst_length ( const request & r)
inline

get length of a burst

Parameters
r
Returns
the number of beats

Definition at line 1167 of file axi_tlm.h.

◆ get_burst_length() [4/4]

unsigned axi::get_burst_length ( const request * r)
inline

get length of a burst

Parameters
r
Returns
the number of beats

Definition at line 1173 of file axi_tlm.h.

◆ get_burst_size() [1/4]

unsigned axi::get_burst_size ( const axi::axi_protocol_types::tlm_payload_type & trans)
inline

get size of a burst in bytes which is 2^AxBURST

Parameters
trans
Returns
the burst size in bytes

Definition at line 1214 of file axi_tlm.h.

◆ get_burst_size() [2/4]

unsigned axi::get_burst_size ( const axi::axi_protocol_types::tlm_payload_type * trans)
inline

get size of a burst in bytes which is 2^AxBURST

Parameters
trans
Returns
the burst size in bytes

Definition at line 1229 of file axi_tlm.h.

◆ get_burst_size() [3/4]

unsigned axi::get_burst_size ( const request & r)
inline

get size of a burst in bytes which is 2^AxBURST

Parameters
r
Returns
the burst size in bytes

Definition at line 1202 of file axi_tlm.h.

◆ get_burst_size() [4/4]

unsigned axi::get_burst_size ( const request * r)
inline

get size of a burst in bytes which is 2^AxBURST

Parameters
r
Returns
the burst size in bytes

Definition at line 1208 of file axi_tlm.h.

◆ get_burst_type() [1/2]

burst_e axi::get_burst_type ( const axi::axi_protocol_types::tlm_payload_type & trans)
inline

Definition at line 1233 of file axi_tlm.h.

◆ get_burst_type() [2/2]

burst_e axi::get_burst_type ( const axi::axi_protocol_types::tlm_payload_type * trans)
inline

Definition at line 1243 of file axi_tlm.h.

◆ get_cache() [1/2]

unsigned axi::get_cache ( const axi::axi_protocol_types::tlm_payload_type & trans)
inline

Definition at line 1245 of file axi_tlm.h.

◆ get_cache() [2/2]

unsigned axi::get_cache ( const axi::axi_protocol_types::tlm_payload_type * trans)
inline

Definition at line 1255 of file axi_tlm.h.

◆ into()

template<typename E>
E axi::into ( typename std::underlying_type< E >::type t)
inline

helper function to convert integer into class enums

Parameters
t
Returns

◆ into< bar_e >()

template<>
bar_e axi::into< bar_e > ( typename std::underlying_type< bar_e >::type t)
inline

Definition at line 1282 of file axi_tlm.h.

◆ into< burst_e >()

template<>
burst_e axi::into< burst_e > ( typename std::underlying_type< burst_e >::type t)
inline

Definition at line 1267 of file axi_tlm.h.

◆ into< domain_e >()

template<>
domain_e axi::into< domain_e > ( typename std::underlying_type< domain_e >::type t)
inline

Definition at line 1277 of file axi_tlm.h.

◆ into< lock_e >()

template<>
lock_e axi::into< lock_e > ( typename std::underlying_type< lock_e >::type t)
inline

Definition at line 1272 of file axi_tlm.h.

◆ into< resp_e >()

template<>
resp_e axi::into< resp_e > ( typename std::underlying_type< resp_e >::type t)
inline

Definition at line 1292 of file axi_tlm.h.

◆ into< snoop_e >()

template<>
snoop_e axi::into< snoop_e > ( typename std::underlying_type< snoop_e >::type t)
inline

Definition at line 1287 of file axi_tlm.h.

◆ is_burst() [1/2]

bool axi::is_burst ( const axi::axi_protocol_types::tlm_payload_type & trans)
inline

determine if the transaction is an AXI burst

Parameters
trans
Returns
true if the access is a burst
Todo
The calculation needs to be checked and probably fixed

Definition at line 1146 of file axi_tlm.h.

◆ is_burst() [2/2]

bool axi::is_burst ( const axi::axi_protocol_types::tlm_payload_type * trans)
inline

determine if the transaction is an AXI burst

Parameters
trans
Returns
the number of beats

Definition at line 1161 of file axi_tlm.h.

◆ is_dataless()

bool axi::is_dataless ( axi::ace_extension const * ext)
inline

Definition at line 1117 of file axi_tlm.h.

◆ is_valid() [1/2]

template<typename EXT>
bool axi::is_valid ( EXT & ext)

Definition at line 1109 of file axi_tlm.h.

◆ is_valid() [2/2]

template<typename EXT>
bool axi::is_valid ( EXT * ext)

Definition at line 1111 of file axi_tlm.h.

◆ is_valid_msg()

template<typename EXT>
char const * axi::is_valid_msg ( EXT & ext)

Definition at line 1113 of file axi_tlm.h.

◆ is_valid_msg< axi::ace_extension >()

template<>
char const * axi::is_valid_msg< axi::ace_extension > ( axi::ace_extension * ext)

Definition at line 235 of file axi_tlm.cpp.

◆ is_valid_msg< axi::axi3_extension >()

template<>
char const * axi::is_valid_msg< axi::axi3_extension > ( axi::axi3_extension * ext)

Definition at line 325 of file axi_tlm.cpp.

◆ is_valid_msg< axi::axi4_extension >()

template<>
char const * axi::is_valid_msg< axi::axi4_extension > ( axi::axi4_extension * ext)

Definition at line 312 of file axi_tlm.cpp.

◆ operator<<() [1/2]

std::ostream & axi::operator<< ( std::ostream & os,
const tlm::tlm_generic_payload & t )

Definition at line 160 of file axi_tlm.cpp.

◆ operator<<() [2/2]

template<typename E, typename std::enable_if< enable_for_enum< E >::value, bool >::type>
std::ostream & axi::operator<< ( std::ostream & os,
E e )
inline
Parameters
os
e
Returns

Definition at line 63 of file axi_tlm.h.

◆ to_char()

template<typename E>
const char * axi::to_char ( E t)

helper function to convert class enums into char string

Parameters
t
Returns

◆ to_char< bar_e >()

template<>
const char * axi::to_char< bar_e > ( bar_e v)

Definition at line 130 of file axi_tlm.cpp.

◆ to_char< burst_e >()

template<>
const char * axi::to_char< burst_e > ( burst_e v)

Definition at line 89 of file axi_tlm.cpp.

◆ to_char< domain_e >()

template<>
const char * axi::to_char< domain_e > ( domain_e v)

Definition at line 115 of file axi_tlm.cpp.

◆ to_char< lock_e >()

template<>
const char * axi::to_char< lock_e > ( lock_e v)

Definition at line 102 of file axi_tlm.cpp.

◆ to_char< resp_e >()

template<>
const char * axi::to_char< resp_e > ( resp_e v)

Definition at line 145 of file axi_tlm.cpp.

◆ to_char< snoop_e >()

template<>
const char * axi::to_char< snoop_e > ( snoop_e v)

Definition at line 26 of file axi_tlm.cpp.

◆ to_int()

template<typename E, typename ULT = typename std::underlying_type<E>::type, typename X = typename std::enable_if<std::is_enum<E>::value && !std::is_convertible<E, ULT>::value, bool>::type>
ULT axi::to_int ( E t)
inlineconstexpr

helper function to convert class enums into integer

Parameters
t
Returns

Definition at line 47 of file axi_tlm.h.

Variable Documentation

◆ CLK_DELAY

const sc_core::sc_time axi::CLK_DELAY = 1_ps

Definition at line 25 of file signal_if.h.