1.10

C++ Concurrency in Action Anthony Williams

Chapter 3. Sharing data between threads

3.2.7 Transfering mutex ownership between scopes

3.2.8 Locking at an appropriate granularity

  Where possible, lock a mutex only while actually accessing the shared data.

3.3. Alternative facilities for protecting shared data

3.3.1 Protecting shared data during initialization  

3.3.2 Protecting rarely updated data structures

3.3.3 Recursive locking

3.4 Summary

猜你喜欢

转载自www.cnblogs.com/lefthook/p/10253465.html