|
template <unsigned long long SIZE, unsigned BUSWIDTH, unsigned PAGE_ADDR_BITS, bool USE_CYCLES> |
|
int memory<SIZE, BUSWIDTH, PAGE_ADDR_BITS, USE_CYCLES>::handle_operation(tlm::tlm_generic_payload& trans, sc_core::sc_time& delay) { |
|
uint64_t adr = trans.get_address(); |
|
uint8_t* ptr = trans.get_data_ptr(); |
|
unsigned len = trans.get_data_length(); |
|
uint8_t* byt = trans.get_byte_enable_ptr(); |
|
unsigned wid = trans.get_streaming_width(); |
In the memory peripheral, the handle_operation performs a sanity check on the byte enable transaction parameter:
|
if(byt) { |
|
auto res = std::accumulate(byt, byt + trans.get_byte_enable_length(), 0xff, [](uint8_t a, uint8_t b) { return a | b; }); |
|
if(trans.get_byte_enable_length() != len || res != 0xff) { |
|
SC_REPORT_ERROR("TLM-2", "generic payload transaction with scattered byte enable not supported"); |
|
trans.set_response_status(tlm::TLM_GENERIC_ERROR_RESPONSE); |
|
return 0; |
|
} |
|
} |
In its actual transmission logic, no byte enable is consumed from the data stream. Is this is intentional?
SystemC-Components/src/components/scc/memory.h
Lines 226 to 232 in cc94c10
In the memory peripheral, the
handle_operationperforms a sanity check on the byte enable transaction parameter:SystemC-Components/src/components/scc/memory.h
Lines 247 to 254 in cc94c10
In its actual transmission logic, no byte enable is consumed from the data stream. Is this is intentional?