user image

Preeti Tripathi

Job Interview Skills
English
2 years ago

Question 329. Should I Use Readerwriterlock Instead Of Monitor.enter/exit?

user image

Abhishek Mishra

2 years ago

The article shows how you can create a simple synchronization primitive that restricts access to a shared resource to a single writer, while still allowing multiple readers to access it simultaneously. Of course, it's not supposed to replace the highly optimized default ReaderWriterLockSlim implementation, but nonetheless, it's a very interesting demonstration of how Monitor.Wait and Monitor.PulseAll can be used to achieve the goal.

Recent Doubts

Close [x]