6 writes to CacheSize
Microsoft.Extensions.Caching.Memory (6)
MemoryCache.cs (6)
190
Interlocked.Add(ref coherentState.
CacheSize
, -priorEntry.Size);
212
Interlocked.Add(ref coherentState.
CacheSize
, -entry.Size);
364
Interlocked.Add(ref coherentState.
CacheSize
, -entry.Size);
571
long original = Interlocked.CompareExchange(ref coherentState.
CacheSize
, committedSize, sizeRead);
865
internal long Size => Volatile.Read(ref
CacheSize
);
879
Interlocked.Add(ref
CacheSize
, -entry.Size);