23

面试官:你说说互斥锁、自旋锁、读写锁、悲观锁、乐观锁的应用场景

 3 years ago
source link: https://database.51cto.com/art/202009/626231.htm
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
多线程访问共享资源的时候,避免不了资源竞争而导致数据错乱的问题,所以我们通常为了解决这一问题,都会在访问共享资源之前加锁。

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK