From 71e2e98d07499c6d0f31596fec52cd8cef5813a9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karel=20Ko=C4=8D=C3=AD?= Date: Fri, 5 Jan 2018 18:14:53 +0100 Subject: Implement machine restart --- qtmips_machine/memory.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'qtmips_machine/memory.h') diff --git a/qtmips_machine/memory.h b/qtmips_machine/memory.h index ab33e4a..3bd1060 100644 --- a/qtmips_machine/memory.h +++ b/qtmips_machine/memory.h @@ -43,6 +43,7 @@ public: void write_byte(std::uint32_t offset, std::uint8_t value); std::uint8_t read_byte(std::uint32_t offset) const; + void merge(MemorySection&); std::uint32_t length() const; const std::uint8_t* data() const; @@ -71,6 +72,8 @@ public: Memory(); Memory(const Memory&); ~Memory(); + void reset(); // Reset whole content of memory (removes old tree and creates new one) + void reset(const Memory&); MemorySection *get_section(std::uint32_t address, bool create) const; // returns section containing given address void write_byte(std::uint32_t address, std::uint8_t value); -- cgit v1.2.3