AXI muckbucket
|
contains all data and functions related to axi and usage More...
Public Member Functions | |
uvm_object_utils (axi_seq_item) rand axi_protocol_version_t protocol | |
constraint | protocol_c () |
constraint | burst_type_c () |
constraint | addr_c () |
constraint | burst_size_c () |
constraint | max_len () |
new (string name="axi_seq_item") | |
Constructor. More... | |
string | convert2string () |
Convert item's variable into one printable string. More... | |
void | do_copy (uvm_object rhs) |
Deep copy. More... | |
bit | do_compare (uvm_object rhs, uvm_comparer comparer) |
Deep compare. More... | |
void | do_print (uvm_printer printer) |
prints out immediate object, but no parents' stuff. More... | |
void | pre_randomize () |
void | post_randomize () |
Tweak things after randomization. More... | |
void | get_beat_N_data (input int beat_cnt, input int data_bus_bytes, ref bit< 7:0 > data[], ref bit wstrb[], output bit wlast) |
return beat values for write data and read data channels More... | |
Public Attributes | |
rand bit< ADDR_WIDTH-1:0 > | addr |
rand bit< 7:0 > | data [] |
rand int | len |
rand bit< ID_WIDTH-1:0 > | id |
rand logic< 2:0 > | burst_size |
rand logic< 1:0 > | burst_type |
rand bit | valid [] |
rand bit | wstrb [] |
rand bit | wlast [] |
bit< LEN_WIDTH-1:0 > | axlen |
logic< 0:0 > | lock = 0x0 |
logic< 3:0 > | cache = 0x0 |
logic< 2:0 > | prot = 0x0 |
logic< 3:0 > | qos = 0x0 |
logic< ID_WIDTH-1:0 > | bid = 0xF |
logic< 1:0 > | bresp = 0x3 |
rand cmd_t | cmd |
rand logic< 31:0 > | toggle_pattern = 0xFFFF_FFFF |
const shortint | c_AXI3_MAXBEATCNT =16 |
const shortint | c_AXI4_MAXBEATCNT =256 |
contains all data and functions related to axi and usage
In addition to variables like addr,len, id, this alsocontains functions that could be moved into axi_uvm_pkg to save object space. Things like calculating aligned_address from address.
Definition at line 34 of file axi_seq_item.svh.
|
inline |
Definition at line 107 of file axi_seq_item.svh.
References addr, burst_size, e_128BYTES, e_16BYTES, e_2BYTES, e_32BYTES, e_4BYTES, e_64BYTES, e_8BYTES, e_FIXED, and e_WRAP.
|
inline |
Definition at line 142 of file axi_seq_item.svh.
References len.
|
inline |
Definition at line 102 of file axi_seq_item.svh.
References addr, and e_RESERVED.
string axi_seq_item::convert2string | ( | ) |
Convert item's variable into one printable string.
Definition at line 288 of file axi_seq_item.svh.
References addr, bid, bresp, burst_size, burst_type, cmd, data, len, and valid.
Referenced by axi_sequential_reads_seq::body(), axi_sequential_writes_seq::body(), axi_responder_seq::body(), do_print(), max_len(), axi_driver::read_address(), axi_monitor::read_address(), axi_responder::read_data(), axi_pipelined_reads_seq::response_handler(), axi_pipelined_writes_seq::response_handler(), axi_driver::run_phase(), axi_responder::run_phase(), axi_scoreboard::write(), axi_coveragecollector::write(), axi_driver::write_address(), axi_monitor::write_address(), axi_responder::write_data(), axi_driver::write_data(), and axi_responder::write_response().
bit axi_seq_item::do_compare | ( | uvm_object | rhs, |
uvm_comparer | comparer | ||
) |
void axi_seq_item::do_copy | ( | uvm_object | rhs | ) |
void axi_seq_item::do_print | ( | uvm_printer | printer | ) |
prints out immediate object, but no parents' stuff.
Definition at line 392 of file axi_seq_item.svh.
References convert2string().
Referenced by max_len().
void axi_seq_item::get_beat_N_data | ( | input int | beat_cnt, |
input int | data_bus_bytes, | ||
ref bit< 7:0 > | data[], | ||
ref bit | wstrb[], | ||
output bit | wlast | ||
) |
return beat values for write data and read data channels
given the beat number and how wide the bus is, return field values that can be placed directly on the bus.
beat_cnt | which beat inthe burst, starting at 0. |
data_bus_bytes | - how wide is the bus (the driver/responder can get this from the interface |
data | - data to be put on wdata/rdata busses (dynamic array, depth=data_bus_bytes) |
wstrb | - byte strobes, to be put on wstrb bus (dynamic array, depth=data_bus_bytes) |
wlast | - just what you think it is. |
Definition at line 492 of file axi_seq_item.svh.
References addr, burst_size, burst_type, calculate_axlen(), get_beat_N_byte_lanes(), and len.
Referenced by max_len(), axi_responder::read_data(), and axi_driver::write_data().
|
inline |
Definition at line 144 of file axi_seq_item.svh.
References addr, c_AXI3_MAXBEATCNT, c_AXI4_MAXBEATCNT, convert2string(), do_compare(), do_copy(), do_print(), e_128BYTES, e_16BYTES, e_1BYTE, e_2BYTES, e_32BYTES, e_4BYTES, e_64BYTES, e_8BYTES, e_AXI3, e_AXI4, e_FIXED, e_INCR, e_WRAP, get_beat_N_data(), post_randomize(), and pre_randomize().
axi_seq_item::new | ( | string | name = "axi_seq_item" | ) |
Constructor.
Doesn't actually do anything except call parent constructor
Definition at line 276 of file axi_seq_item.svh.
void axi_seq_item::post_randomize | ( | ) |
Tweak things after randomization.
Currenly being used to reset the data[] to incrementing pattern ending with 'FE. This is for easier debugging. More love coming.
Definition at line 409 of file axi_seq_item.svh.
References cmd, data, e_WRITE, len, valid, wlast, and wstrb.
Referenced by max_len().
void axi_seq_item::pre_randomize | ( | ) |
Definition at line 397 of file axi_seq_item.svh.
Referenced by max_len().
|
inline |
Definition at line 95 of file axi_seq_item.svh.
axi_seq_item::uvm_object_utils | ( | axi_seq_item | ) |
rand bit<ADDR_WIDTH-1:0> axi_seq_item::addr |
Definition at line 43 of file axi_seq_item.svh.
Referenced by addr_c(), axi_sequential_reads_seq::body(), burst_type_c(), convert2string(), do_compare(), do_copy(), get_beat_N_data(), max_len(), axi_monitor::read_address(), axi_responder::read_data(), axi_driver::read_data(), axi_driver::write_data(), and axi_monitor::write_data().
bit<LEN_WIDTH-1:0> axi_seq_item::axlen |
Definition at line 58 of file axi_seq_item.svh.
Referenced by axi_coveragecollector::sample().
logic<ID_WIDTH-1:0> axi_seq_item::bid = 0xF |
Definition at line 68 of file axi_seq_item.svh.
Referenced by convert2string(), do_copy(), and axi_driver::write_response().
logic<1:0> axi_seq_item::bresp = 0x3 |
Definition at line 69 of file axi_seq_item.svh.
Referenced by convert2string(), do_copy(), and axi_driver::write_response().
rand logic<2:0> axi_seq_item::burst_size |
Definition at line 48 of file axi_seq_item.svh.
Referenced by addr_c(), axi_sequential_reads_seq::body(), convert2string(), do_copy(), get_beat_N_data(), axi_monitor::read_address(), axi_driver::read_data(), axi_responder::read_data(), axi_coveragecollector::sample(), axi_driver::write_data(), and axi_monitor::write_data().
rand logic<1:0> axi_seq_item::burst_type |
Definition at line 49 of file axi_seq_item.svh.
Referenced by axi_sequential_reads_seq::body(), convert2string(), do_copy(), get_beat_N_data(), axi_monitor::read_address(), axi_driver::read_data(), axi_coveragecollector::sample(), and axi_monitor::write_data().
const shortint axi_seq_item::c_AXI3_MAXBEATCNT =16 |
Definition at line 89 of file axi_seq_item.svh.
Referenced by max_len().
const shortint axi_seq_item::c_AXI4_MAXBEATCNT =256 |
Definition at line 90 of file axi_seq_item.svh.
Referenced by max_len().
logic<3:0> axi_seq_item::cache = 0x0 |
Definition at line 64 of file axi_seq_item.svh.
Referenced by do_copy().
rand cmd_t axi_seq_item::cmd |
Definition at line 71 of file axi_seq_item.svh.
Referenced by convert2string(), do_copy(), post_randomize(), axi_monitor::read_address(), axi_driver::read_data(), axi_monitor::read_data(), axi_pipelined_reads_seq::response_handler(), axi_pipelined_writes_seq::response_handler(), axi_driver::run_phase(), axi_responder::run_phase(), axi_scoreboard::write(), axi_coveragecollector::write(), axi_monitor::write_address(), axi_monitor::write_data(), axi_driver::write_response(), and axi_monitor::write_response().
rand bit<7:0> axi_seq_item::data[] |
Definition at line 44 of file axi_seq_item.svh.
Referenced by convert2string(), do_compare(), do_copy(), post_randomize(), axi_monitor::read_address(), axi_driver::read_data(), axi_monitor::read_data(), and axi_monitor::write_data().
rand bit<ID_WIDTH-1:0> axi_seq_item::id |
Definition at line 47 of file axi_seq_item.svh.
Referenced by do_compare(), do_copy(), axi_pipelined_reads_seq::response_handler(), and axi_pipelined_writes_seq::response_handler().
rand int axi_seq_item::len |
Definition at line 45 of file axi_seq_item.svh.
Referenced by axi_sequential_reads_seq::body(), burst_size_c(), convert2string(), do_compare(), do_copy(), get_beat_N_data(), post_randomize(), protocol_c(), axi_monitor::read_address(), axi_driver::read_data(), axi_responder::read_data(), axi_monitor::read_data(), axi_monitor::write_address(), axi_driver::write_data(), and axi_monitor::write_data().
logic<0:0> axi_seq_item::lock = 0x0 |
Definition at line 63 of file axi_seq_item.svh.
Referenced by do_copy().
logic<2:0> axi_seq_item::prot = 0x0 |
Definition at line 65 of file axi_seq_item.svh.
Referenced by do_copy().
logic<3:0> axi_seq_item::qos = 0x0 |
Definition at line 66 of file axi_seq_item.svh.
Referenced by do_copy().
rand logic<31:0> axi_seq_item::toggle_pattern = 0xFFFF_FFFF |
Definition at line 73 of file axi_seq_item.svh.
rand bit axi_seq_item::valid[] |
Definition at line 52 of file axi_seq_item.svh.
Referenced by axi_sequential_writes_seq::body(), convert2string(), do_copy(), post_randomize(), axi_monitor::read_address(), axi_responder::read_data(), and axi_driver::write_data().
rand bit axi_seq_item::wlast[] |
Definition at line 57 of file axi_seq_item.svh.
Referenced by do_copy(), and post_randomize().
rand bit axi_seq_item::wstrb[] |
Definition at line 56 of file axi_seq_item.svh.
Referenced by do_copy(), post_randomize(), and axi_monitor::write_data().