Skip to content

Commit 27e862f

Browse files
committed
Remove unused ConcurrentDictionary.AcquireAllLocks
1 parent 6538304 commit 27e862f

File tree

1 file changed

+0
-16
lines changed

1 file changed

+0
-16
lines changed

src/MSBuildTaskHost/Concurrent/ConcurrentDictionary.cs

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -471,22 +471,6 @@ private static void GetBucketAndLockNo(int hashcode, out int bucketNo, out int l
471471
Debug.Assert(lockNo >= 0 && lockNo < lockCount);
472472
}
473473

474-
/// <summary>
475-
/// Acquires all locks for this hash table, and increments locksAcquired by the number
476-
/// of locks that were successfully acquired. The locks are acquired in an increasing
477-
/// order.
478-
/// </summary>
479-
private void AcquireAllLocks(ref int locksAcquired)
480-
{
481-
// First, acquire lock 0
482-
AcquireLocks(0, 1, ref locksAcquired);
483-
484-
// Now that we have lock 0, the _locks array will not change (i.e., grow),
485-
// and so we can safely read _locks.Length.
486-
AcquireLocks(1, _tables._locks.Length, ref locksAcquired);
487-
Debug.Assert(locksAcquired == _tables._locks.Length);
488-
}
489-
490474
/// <summary>
491475
/// Acquires a contiguous range of locks for this hash table, and increments locksAcquired
492476
/// by the number of locks that were successfully acquired. The locks are acquired in an

0 commit comments

Comments
 (0)