core/util: MemoryMap learns to materialize in files

Change-Id: I003168d3718491524db91b9f7d855d6b3428961c
This commit is contained in:
Horst Schirmeier
2013-04-06 22:05:51 +02:00
parent 467ad88577
commit 4d03b7ce5c
3 changed files with 64 additions and 0 deletions

View File

@ -73,6 +73,24 @@ public:
* structure.
*/
iterator end() { return as.end(); }
/**
* Loads a memory map from a file and merges it with the current state.
*
* File format (addresses and sizes in decimal):
* \code
* address1<tab>size1
* address2<tab>size2
* ...
* \endcode
*/
bool readFromFile(char const * const filename);
/**
* Saves the map to a file.
*
* Currently all access size information is lost; the map is flattened out
* to a long list of single-byte addresses.
*/
bool writeToFile(char const * const filename);
};
} // end-of-namespace: fail