为什么的C ++ 0x标准委员会否决的boost :: shared_mutex? [英] why C++0x standard committee rejected boost::shared_mutex?

查看:193
本文介绍了为什么的C ++ 0x标准委员会否决的boost :: shared_mutex?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你有关于这个问题的任何信息?与升压::在所有shared_mutex特别是与读写器互斥什么问题?

do you have any info about the subject? any problem with boost::shared_mutex in particular and with reader-writer mutexes at all?

读写器互斥可以被滥用,例如频繁的写锁降低性能,即使在简单的互斥体的比较。但也有是很多情况下,当许多读者往往需要一个共享的资源,可以由作家真的很少进行修改。

reader-writer mutex can be misused, e.g. frequent writer locks reduces performance, even in comparison with simple mutex. but there're a lot of cases when many readers often require a shared resource that can be modified by writer really infrequently.

推荐答案

安东尼·威廉姆斯是C ++标准委员会的一个有影响力的成员。他参与撰写了许多,导致了列入C ++标准的11线程库的建议。你可以阅读他的本评论。然而,它并使它成为C ++ 17。

Anthony Williams is an influential member of the C++ standards committee. He co-authored many of the proposals that led to the inclusion of the thread library in the C++11 Standard. You can read his objections in this commentary. Nevertheless, it did make it into C++17.

这篇关于为什么的C ++ 0x标准委员会否决的boost :: shared_mutex?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆