mirror of
https://github.com/NixOS/nix
synced 2025-06-25 06:31:14 +02:00
Merge pull request #12238 from apoelstra/2025-01--unsorted-gc
gc: replace ordered sets with unordered sets for in-memory caches
This commit is contained in:
commit
a78f998cc7
1 changed files with 2 additions and 2 deletions
|
@ -455,7 +455,7 @@ void LocalStore::collectGarbage(const GCOptions & options, GCResults & results)
|
|||
bool gcKeepOutputs = settings.gcKeepOutputs;
|
||||
bool gcKeepDerivations = settings.gcKeepDerivations;
|
||||
|
||||
StorePathSet roots, dead, alive;
|
||||
std::unordered_set<StorePath> roots, dead, alive;
|
||||
|
||||
struct Shared
|
||||
{
|
||||
|
@ -661,7 +661,7 @@ void LocalStore::collectGarbage(const GCOptions & options, GCResults & results)
|
|||
}
|
||||
};
|
||||
|
||||
std::map<StorePath, StorePathSet> referrersCache;
|
||||
std::unordered_map<StorePath, StorePathSet> referrersCache;
|
||||
|
||||
/* Helper function that visits all paths reachable from `start`
|
||||
via the referrers edges and optionally derivers and derivation
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue