util: space-efficient MemoryMap
We now use boost::icl::interval_set internally, consuming extremely lower amounts of memory. boost::icl was introduced with Boost 1.46; Debian 7.0 comes with 1.49, so this dependency should be no problem anymore. Both the class interface and the memory-map file format stay the same. Change-Id: I38e8148384c90aa493984d0f6280817df00f1702
This commit is contained in:
@ -37,9 +37,12 @@ bool MemoryMap::writeToFile(char const * const filename)
|
||||
return false;
|
||||
}
|
||||
|
||||
for (iterator it = begin(); it != end(); ++it) {
|
||||
file << *it << "\t1\n";
|
||||
#ifndef __puma
|
||||
for (address_set::iterator it = as.begin();
|
||||
it != as.end(); ++it) {
|
||||
file << it->lower() << " " << (it->upper() - it->lower() + 1) << "\n";
|
||||
}
|
||||
#endif
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user