diff options
author | Max Horn | 2010-07-01 16:05:47 +0000 |
---|---|---|
committer | Max Horn | 2010-07-01 16:05:47 +0000 |
commit | 9d47b191f6302ac8960bb4d91d32104c0993a198 (patch) | |
tree | e0e8524e68cde7d4be66be175bf865a4c60ee57e /engines/sci/engine/gc.cpp | |
parent | b8904a48ed81d04a2cbe84f78d80aaa75344d16e (diff) | |
download | scummvm-rg350-9d47b191f6302ac8960bb4d91d32104c0993a198.tar.gz scummvm-rg350-9d47b191f6302ac8960bb4d91d32104c0993a198.tar.bz2 scummvm-rg350-9d47b191f6302ac8960bb4d91d32104c0993a198.zip |
SCI: Rename some more stuff
svn-id: r50553
Diffstat (limited to 'engines/sci/engine/gc.cpp')
-rw-r--r-- | engines/sci/engine/gc.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/engines/sci/engine/gc.cpp b/engines/sci/engine/gc.cpp index 75456bcef0..936b83d760 100644 --- a/engines/sci/engine/gc.cpp +++ b/engines/sci/engine/gc.cpp @@ -30,7 +30,7 @@ namespace Sci { struct WorklistManager { Common::Array<reg_t> _worklist; - reg_t_hash_map _map; + AddrSet _map; void push(reg_t reg) { if (!reg.segment) // No numbers @@ -51,10 +51,10 @@ struct WorklistManager { } }; -static reg_t_hash_map *normalizeAddresses(SegManager *segMan, reg_t_hash_map &nonnormal_map) { - reg_t_hash_map *normal_map = new reg_t_hash_map(); +static AddrSet *normalizeAddresses(SegManager *segMan, const AddrSet &nonnormal_map) { + AddrSet *normal_map = new AddrSet(); - for (reg_t_hash_map::iterator i = nonnormal_map.begin(); i != nonnormal_map.end(); ++i) { + for (AddrSet::const_iterator i = nonnormal_map.begin(); i != nonnormal_map.end(); ++i) { reg_t reg = i->_key; SegmentObj *mobj = segMan->getSegmentObj(reg.segment); @@ -68,9 +68,9 @@ static reg_t_hash_map *normalizeAddresses(SegManager *segMan, reg_t_hash_map &no } -reg_t_hash_map *find_all_used_references(EngineState *s) { +AddrSet *findAllActiveReferences(EngineState *s) { SegManager *segMan = s->_segMan; - reg_t_hash_map *normal_map = NULL; + AddrSet *normal_map = NULL; WorklistManager wm; uint i; @@ -159,7 +159,7 @@ void run_gc(EngineState *s) { memset(segcount, 0, sizeof(segcount)); // Compute the set of all segments references currently in use. - reg_t_hash_map *activeRefs = find_all_used_references(s); + AddrSet *activeRefs = findAllActiveReferences(s); // Iterate over all segments, and check for each whether it // contains stuff that can be collected. |