19 #include <axi/pe/axi_target_pe.h>
20 #include <cci_configuration>
21 #include "target_info_if.h"
29 sc_core::sc_in<bool> clk_i{
"clk_i"};
31 sc_core::sc_export<tlm::scc::pe::intor_fw_nb> fw_i{
"fw_i"};
33 sc_core::sc_port<tlm::scc::pe::intor_bw_nb, 1, sc_core::SC_ZERO_OR_MORE_BOUND> bw_o{
"bw_o"};
65 void transport(tlm::tlm_generic_payload& payload,
bool lt_transport =
false)
override;
72 void snoop_resp(tlm::tlm_generic_payload& payload,
bool sync =
false)
override {}
74 sc_core::sc_clock* clk_if{
nullptr};
75 sc_core::sc_time time_per_byte_rd, time_per_byte_wr, time_per_byte_total;
83 double total_residual_clocks{0.0};
84 void end_of_elaboration()
override;
85 void start_of_simulation()
override;
87 void process_req2resp_fifos();
88 void start_rd_resp_thread();
89 void start_wr_resp_thread();
97 sc_core::sc_port_policy POL = sc_core::SC_ONE_OR_MORE_BOUND>
101 using payload_type = base::payload_type;
102 using phase_type = base::phase_type;
103 sc_core::sc_in<bool> clk_i{
"clk_i"};
112 : sc_core::sc_module(nm)
114 , rate_limit_buffer(
"rate_limit_buffer", pe.rd_resp_delay, pe.wr_resp_delay){
117 rate_limit_buffer.clk_i(clk_i);
118 pe.fw_o(rate_limit_buffer.fw_i);
119 rate_limit_buffer.bw_o(pe.bw_i);
132 size_t get_outstanding_tx_count()
override {
return pe.getAllOutStandingTx();}
135 void end_of_elaboration(){
136 auto* ifs = sckt.get_base_port().get_interface(0);
137 sc_assert(ifs!=
nullptr);
138 pe.set_bw_interface(ifs);
142 rate_limiting_buffer rate_limit_buffer;
ordered_target(const sc_core::sc_module_name &nm)
the constructor
scc::sc_attribute_randomized< int > & rd_resp_delay
the latency between request and response phase. Will be overwritten by the return of the callback fun...
scc::fifo_w_cb< std::tuple< tlm::tlm_generic_payload *, unsigned > > rd_req2resp_fifo
queues realizing the min latency
cci::cci_param< double > total_bw_limit_byte_per_sec
the bandwidth limit for read accesses
void snoop_resp(tlm::tlm_generic_payload &payload, bool sync=false) override
scc::sc_attribute_randomized< int > & wr_resp_delay
the latency between request and response phase. Will be overwritten by the return of the callback fun...
scc::fifo_w_cb< tlm::tlm_generic_payload * > rd_resp_fifo
queues to handle bandwidth limit
void transport(tlm::tlm_generic_payload &payload, bool lt_transport=false) override
cci::cci_param< double > rd_bw_limit_byte_per_sec
the bandwidth limit for read accesses
cci::cci_param< double > wr_bw_limit_byte_per_sec
the bandwidth limit for write accesses
The ordered_semaphore primitive channel class.
TLM2.0 components modeling AHB.
The AXI protocol traits class. Since the protocoll defines additional non-ignorable phases a dedicate...