From ce811fb6d94e1d4af1fd1f52fbf109bc34834970 Mon Sep 17 00:00:00 2001 From: Thurston Dang Date: Tue, 23 Jul 2024 14:01:48 -0700 Subject: [PATCH] [NFCI][scudo] Remove unused variable 'MaxCount' (#100201) Fixes "error: unused variable 'MaxCount' [-Werror,-Wunused-variable]", which is no longer used after https://github.com/llvm/llvm-project/pull/99409 --- compiler-rt/lib/scudo/standalone/secondary.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/compiler-rt/lib/scudo/standalone/secondary.h b/compiler-rt/lib/scudo/standalone/secondary.h index b8e12db9349639..d8505742d60544 100644 --- a/compiler-rt/lib/scudo/standalone/secondary.h +++ b/compiler-rt/lib/scudo/standalone/secondary.h @@ -332,7 +332,6 @@ template class MapAllocatorCache { bool retrieve(Options Options, uptr Size, uptr Alignment, uptr HeadersSize, LargeBlock::Header **H, bool *Zeroed) EXCLUDES(Mutex) { const uptr PageSize = getPageSizeCached(); - const u32 MaxCount = atomic_load_relaxed(&MaxEntriesCount); // 10% of the requested size proved to be the optimal choice for // retrieving cached blocks after testing several options. constexpr u32 FragmentedBytesDivisor = 10; @@ -449,7 +448,6 @@ template class MapAllocatorCache { Quarantine[I].invalidate(); } } - const u32 MaxCount = atomic_load_relaxed(&MaxEntriesCount); for (u32 I = LRUHead; I != CachedBlock::InvalidEntry; I = Entries[I].Next) { Entries[I].MemMap.setMemoryPermission(Entries[I].CommitBase, Entries[I].CommitSize, 0);