无锁数据结构(五)
来源:互联网 发布:固定收益部 知乎 编辑:程序博客网 时间:2024/05/21 15:41
Andrei Alexandrescu
December 16, 2007
译者:张桂权
7 结束语
无锁数据结构是非常有希望的。它们通过线程消亡、优先级反演和信号安全等展示了很多优秀的特性。它们从来不会死锁或活锁。在测试中,最近的无锁数据结构通过一个很大的容限超过了它们加锁的副本。
然而,无锁编程是一种技巧,尤其与内存分解有关。一个有垃圾收集的环境是必要的,因为它拥有一些手段来终止和审查所有的线程,但是如果你想要确定性的解构,你需要硬件或内存分配器的特殊支持。泛型编程(Generic<Programming>)的下一部分将了解在执行确定性解构时支持无锁的WRRMMap的优化方法。如果这一个部分中基于垃圾收集和WRRMBNTM的map不能满足于你,那么这儿有一个省钱的方法:不要去看电影,《Alien vs. Predator》,除非你喜欢“这么坏,太滑稽了(so bad it’s funny)”的电影。
8 致谢
特别感谢Krzysztof Machelski,他审核了代码的实现,并提示其中的两个bug。
参考文献
[1] Andrei Alexandrescu. Modern C++ Design.Addison-Wesley Longman, 2001.
[2] Andrei Alexandrescu. GenerichProgrammingi:yasli::vector is on the move. C++ Users Journal,June 2004.
[3] D.R. Butenhof. Programming with POSIX Threads. Addison-Wesley,
[4] David L. Detlefs, Paul A. Martin, Mark Moir,and Guy L. Steele, Jr. Lock-free reference counting.In Proceedings of the twentieth annual ACM symposium on Principles of distributed computing,pages 190–199. ACM Press, 2001. ISBN 1-58113-383-9.
[5] Erich Gamma, Richard Helm, Ralph E. Johnson,and John Vlissides. Design Patterns. Addison-Wesley, Reading, MA, 1995.
[6] Scott Meyers and Andrei Alexandrescu. The Perils of Double-Checked Locking. Dr. Dobb’s Journal,July 2004.
[7] Maged M. Michael. Scalable lock-free dynamic memory allocation.
In Proceedings of the ACM SIGPLAN 2004 conference on Programming language design and implementation,pages 35–46.ACM Press, 2004. ISBN 1-58113-807-5.
---------------源文档------------------
Lock-Free Data Structures
Andrei Alexandrescu
December 17, 2007
http://erdani.org/publications/cuj-2004-10.pdf
最后一次访问时间:2007年12月30日
----------------------------------------
http://download.csdn.net/source/346893
- 无锁数据结构(五)
- 无锁数据结构(一)
- 无锁数据结构(二)
- 无锁数据结构(三)
- 无锁数据结构(四)
- 再论 无锁数据结构 (上)
- 再论 无锁数据结构(下)
- 并发无锁队列学习(数据结构)
- 并发无锁队列学习(数据结构)
- 并发无锁队列学习(数据结构)
- 无锁数据结构
- 无锁数据结构
- 无锁数据结构一
- 无锁数据结构三
- 数据结构(五)
- 数据结构复习题(五)
- 数据结构(五) --- 链表
- 数据结构(五):队列
- 无锁数据结构(二)
- 套接字编程学习笔记(一) 服务器端demo说明
- 无锁数据结构(三)
- 无锁数据结构(四)
- 满江红开放技术研究组织发布Seam 2.0中文文档RC版
- 无锁数据结构(五)
- Axis2 WebService
- 在VB应用程序中使用INI文件
- eXpresso: 在线Excel电子表格
- 一种可以穿透还原卡和还原软件的代码
- 还原卡破解
- SQL行转列的问题
- 雨林木风 Ghost XP SP2 精简版 Y2.0
- 雨林木风 Ghost XP SP2 纯净版 Y3.0