[compiler-rt] [scudo] Separated committed and decommitted entries. (PR #101409)

Christopher Ferris via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 31 19:47:38 PDT 2024


================
@@ -579,10 +641,12 @@ template <typename Config> class MapAllocatorCache {
   NonZeroLengthArray<CachedBlock, Config::getQuarantineSize()>
       Quarantine GUARDED_BY(Mutex) = {};
 
-  // The LRUHead of the cache is the most recently used cache entry
-  u16 LRUHead GUARDED_BY(Mutex) = 0;
-  // The LRUTail of the cache is the least recently used cache entry
-  u16 LRUTail GUARDED_BY(Mutex) = 0;
+  // EntryLists stores the head and tail indices of all
+  // lists being used to store valid cache entries.
+  // Currently there are lists storing COMMITTED and DECOMMITTED entries.
+  // COMMITTED entries are those that are not madvise()'d
----------------
cferris1000 wrote:

madvise is actually linux specific, so how about saying something like released to the OS.

https://github.com/llvm/llvm-project/pull/101409


More information about the llvm-commits mailing list