From 4baf970f1b151400152c43559e601625dc03bd67 Mon Sep 17 00:00:00 2001 From: sthiruva Date: Wed, 30 Sep 2020 00:39:24 +0530 Subject: Adding symbol lookup when --enable-commitlog is enabled (#558) * Adding symbol lookup when --enable-commitlog is enabled * Removed the #ifdef RISCV_ENABLE_COMMITLOG for all get_symbol related function Only retained the in processor.cc where it is called. Co-authored-by: Shajid Thiruvathodi --- fesvr/htif.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'fesvr/htif.h') diff --git a/fesvr/htif.h b/fesvr/htif.h index d69bd42..5b16a60 100644 --- a/fesvr/htif.h +++ b/fesvr/htif.h @@ -49,6 +49,9 @@ class htif_t : public chunked_memif_t // range to memory, because it has already been loaded through a sideband virtual bool is_address_preloaded(addr_t taddr, size_t len) { return false; } + // Given an address, return symbol from addr2symbol map + const char* get_symbol(uint64_t addr); + private: void parse_arguments(int argc, char ** argv); void register_devices(); @@ -75,6 +78,8 @@ class htif_t : public chunked_memif_t const std::vector& target_args() { return targs; } + std::map addr2symbol; + friend class memif_t; friend class syscall_t; }; -- cgit v1.1