[compiler-rt] [scudo] Update secondary cache time-based release logic. (PR #107507)
via llvm-commits
llvm-commits at lists.llvm.org
Thu Sep 12 11:45:24 PDT 2024
================
@@ -318,9 +318,10 @@ class MapAllocatorCache {
}
CachedBlock PrevEntry = Quarantine[QuarantinePos];
Quarantine[QuarantinePos] = Entry;
- if (OldestTime == 0)
- OldestTime = Entry.Time;
Entry = PrevEntry;
+ // Set entry time once more to reflect time
+ // that quarantined memory was placed in the cache
+ Entry.Time = Time;
----------------
ChiaHungDuan wrote:
I don't understand the assignment here. Entry.Time has been set above why do we need to do it unconditionally here?
https://github.com/llvm/llvm-project/pull/107507
More information about the llvm-commits
mailing list