Awesome
Benchmarks for the AsyncKeyedLock library
This is a project to help benchmark the AsyncKeyedLock library against other competing solutions. We are testing with 3 separate parameters:
- Number of locks: 200 and 10000
- Contention: 100 and 10000
- GUID reversals (to simulate some load): 0, 1 and 5
When looking at the benchmarks, please ignore all values for 10k locks with 10k contention: they are dummy tests and don't actually run.
Solutions tested
- AsyncKeyedLocker with pooling (from AsyncKeyedLock)
- AsyncKeyedLocker without pooling (from AsyncKeyedLock)
- StripedAsyncKeyedLocker (from AsyncKeyedLock)
- AsyncKeyLock from ImageSharp.Web
- AsyncKeyLock by usercode
- KeyedSemaphoresCollection from Keyed Semaphores, similar to StripedAsyncKeyedLocker
- KeyedSemaphoresDictionary from Keyed Semaphores, similar to AsyncKeyedLocker without pooling
- AsyncDuplicateLock from Stephen Cleary's StackOverflow solution
- AsyncDuplicateLock from Theodor Zoulias' improvement over #8
- StripedAsyncLock from AsyncUtilities, similar to StripedAsyncKeyedLocker
- NeoSmart.Synchronization
- Dao.IndividualLock
- AsyncLockSet from Stl.Fusion
Results
The benchmark results can be found in our actions as they run in Github Actions, in a fully transparent fashion.
There are also some graphical comparisons over time.