2 instantiations of ThreadCounts
System.Private.CoreLib (2)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Threading\PortableThreadPool.ThreadCounts.cs (2)
162public ThreadCounts VolatileRead() => new ThreadCounts(Volatile.Read(ref _data)); 173return new ThreadCounts(Interlocked.CompareExchange(ref _data, newCounts._data, oldCounts._data));
32 references to ThreadCounts
System.Private.CoreLib (32)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Threading\PortableThreadPool.Blocking.cs (1)
129ThreadCounts counts = _separated.counts;
src\runtime\src\libraries\System.Private.CoreLib\src\System\Threading\PortableThreadPool.cs (4)
88public ThreadCounts counts; // SOS's ThreadPool command depends on this name 326ThreadCounts counts = _separated.counts.VolatileRead(); 390ThreadCounts counts = _separated.counts; 469ThreadCounts counts = _separated.counts;
src\runtime\src\libraries\System.Private.CoreLib\src\System\Threading\PortableThreadPool.GateThread.cs (3)
151ThreadCounts counts = threadPoolInstance._separated.counts; 161ThreadCounts newCounts = counts; 165ThreadCounts countsBeforeUpdate =
src\runtime\src\libraries\System.Private.CoreLib\src\System\Threading\PortableThreadPool.ThreadCounts.cs (15)
14private struct ThreadCounts : IEquatable<ThreadCounts> 142public ThreadCounts InterlockedSetNumThreadsGoal(short value) 146ThreadCounts counts = this; 149ThreadCounts newCounts = counts; 152ThreadCounts countsBeforeUpdate = InterlockedCompareExchange(newCounts, counts); 162public ThreadCounts VolatileRead() => new ThreadCounts(Volatile.Read(ref _data)); 164public ThreadCounts InterlockedCompareExchange(ThreadCounts newCounts, ThreadCounts oldCounts) 176public static bool operator ==(ThreadCounts lhs, ThreadCounts rhs) => lhs._data == rhs._data; 177public static bool operator !=(ThreadCounts lhs, ThreadCounts rhs) => lhs._data != rhs._data; 179public override bool Equals([NotNullWhen(true)] object? obj) => obj is ThreadCounts other && Equals(other); 180public bool Equals(ThreadCounts other) => _data == other._data;
src\runtime\src\libraries\System.Private.CoreLib\src\System\Threading\PortableThreadPool.WorkerThread.cs (9)
190ThreadCounts counts = threadPoolInstance._separated.counts; 202ThreadCounts newCounts = counts; 210ThreadCounts oldCounts = 244ThreadCounts oldCounts = threadPoolInstance._separated.counts; 245ThreadCounts newCounts = oldCounts; 263ThreadCounts oldCounts, newCounts; 306ThreadCounts counts = threadPoolInstance._separated.counts; 318ThreadCounts newCounts = counts; 321ThreadCounts oldCounts = threadPoolInstance._separated.counts.InterlockedCompareExchange(newCounts, counts);