diff options
Diffstat (limited to 'base/loader/object_file.hh')
-rw-r--r-- | base/loader/object_file.hh | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/base/loader/object_file.hh b/base/loader/object_file.hh index 1b44ae14f..08a51863e 100644 --- a/base/loader/object_file.hh +++ b/base/loader/object_file.hh @@ -33,7 +33,7 @@ #include "sim/host.hh" // for Addr -class FunctionalMemory; +class TranslatingPort; class SymbolTable; class ObjectFile @@ -72,8 +72,7 @@ class ObjectFile void close(); - virtual bool loadSections(FunctionalMemory *mem, - bool loadPhys = false) = 0; + virtual bool loadSections(TranslatingPort *memPort, bool loadPhys = false); virtual bool loadGlobalSymbols(SymbolTable *symtab) = 0; virtual bool loadLocalSymbols(SymbolTable *symtab) = 0; @@ -83,8 +82,9 @@ class ObjectFile protected: struct Section { - Addr baseAddr; - size_t size; + Addr baseAddr; + uint8_t *fileImage; + size_t size; }; Addr entry; @@ -94,6 +94,8 @@ class ObjectFile Section data; Section bss; + bool loadSection(Section *sec, TranslatingPort *memPort, bool loadPhys); + public: Addr entryPoint() const { return entry; } Addr globalPointer() const { return globalPtr; } |