[compiler-rt] [scudo] Reduce thread contention in secondary cache releases. (PR #102984)
Christopher Ferris via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 12 17:28:34 PDT 2024
================
@@ -351,9 +351,13 @@ class MapAllocatorCache {
for (MemMapT &EvictMemMap : EvictionMemMaps)
unmapCallBack(EvictMemMap);
- if (Interval >= 0) {
+ // If a thread already holds the mutex, the current thread can
----------------
cferris1000 wrote:
I don't think this is strictly true, right? Specifically, in the retrieve function you could hold the lock while trying to find an entry in the cache.
Is there a worry that you could skip these checks while doing a retrieve?
https://github.com/llvm/llvm-project/pull/102984
More information about the llvm-commits
mailing list