20 SRAM(
const std::string& name,
22 bool* loaded =
nullptr);
25 bool* loaded =
nullptr);
28 [[nodiscard]]
const byte&
operator[](
size_t addr)
const {
29 assert(addr <
size());
33 void write(
size_t addr,
byte value);
35 [[nodiscard]]
size_t size()
const {
39 template<
typename Archive>
40 void serialize(Archive& ar,
unsigned version);
46 void executeRT()
override;
50 std::optional<SRAMSchedulable> schedulable;
52 void load(
bool* loaded);
55 const DeviceConfig config;
57 const char*
const header =
nullptr;
void write(size_t addr, byte value)
void serialize(Archive &ar, unsigned version)
const byte & operator[](size_t addr) const
void memset(size_t addr, byte c, size_t size)
This file implemented 3 utility functions: