如何互斥和锁定结构来实现? [英] How are mutex and lock structures implemented?
问题描述
我明白了锁,互斥和其他同步结构的概念,但他们是如何实现的?它们是由OS提供,或者是这些结构依赖于特殊的CPU指令的CPU的MMU的?
I understand the concept of locks, mutex and other synchronization structures, but how are they implemented? Are they provided by the OS, or are these structures dependent on special CPU instructions for the CPUs MMU?
推荐答案
您可能想看看这些链接,但主要是检查并设置维基百科:
http://en.wikipedia.org/wiki/Test-and-set
You may want to look at these links, but the main one is the Test-and-set on Wikipedia: http://en.wikipedia.org/wiki/Test-and-set
<一个href=\"http://stackoverflow.com/questions/1485924/how-are-mutexes-implemented\">http://stackoverflow.com/questions/1485924/how-are-mutexes-implemented
您也可以看看这个专利:
http://www.faqs.org/patents/app/20080222331
You can also look at this patent: http://www.faqs.org/patents/app/20080222331
这篇关于如何互斥和锁定结构来实现?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!