登录
首页 » c++ » boost shared_mutex

boost shared_mutex

于 2022-03-25 发布 文件大小:3.43 kB
0 107
下载积分: 2 下载次数: 1

代码说明:

共享资源库.今天介绍的共享互斥量用来实现缓冲区读写模型,与生产者/消费者模型不同的地方是,消费者消费产品后,被消费的产品就不存在了,所以消费者线程也要互斥运行;而缓冲区读取线程读取数据后不删除数据,多个线程可以并行读取。这时使用条件变量也不合适了,就要使用共享互斥变量了。        共享互斥量,顾名思义,既共享,也互斥,读线程之间共享读取数据,使用shared_lock类锁定shared_mutex变量;写线程之间需要独占缓冲区,必须互斥运行,使用unique_lock类锁定shared_mutex变量

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • COM
    “COM技术内幕-微软组件对象模型”美 Dale Rogeson著 此书中的配套代码(" COM Technology Insider- Microsoft' s Component Object Model" Dale Rogeson the United States and supporting the code in this book)
    2011-05-25 20:54:10下载
    积分:1
  • fit
    基于Levenberg-Marquardt的曲线/面拟合(C library for Levenberg-Marquardt least-squares minimization and curve fitting)
    2014-02-14 04:20:28下载
    积分:1
  • eigen
    说明:  在vs2015中编译过的eigen开源库的编译文件(The compiled file of the eigen open source library compiled in vs2015)
    2021-04-17 10:38:53下载
    积分:1
  • BICG
    BICG算法,是Krylov子空间的迭代方法之一(The BICG algorithm is one of the Krylov subspace iteration method)
    2012-07-09 21:57:18下载
    积分:1
  • MultiPing
    ICMP扫描器的设计源码。能实现ping功能,扫描IP地址可以手动输入。方便初学者学习。。(ICMP scanner design source. Ping function, scanning the IP address can be entered manually.)
    2012-11-08 14:23:46下载
    积分:1
  • ADS8505
    ADS850516位AD的驱动程序,采用8位单片机控制,C语言编写(ADS850516 bit AD driver, using 8-bit single-chip control, C language)
    2008-02-26 09:22:35下载
    积分:1
  • Signal-Processing-and-Linear-Systems
    信号处理与线性系统(英文版)( This text presents a comprehensive treatment of signal processing and linear systems suitable for juniors and seniors in electrical engineering. Based on B. P. Lathi s widely used book, Linear Systems and Signals, it features additional applications to communications, controls, and filtering。)
    2012-08-27 10:19:43下载
    积分:1
  • CMTS.SendMMS
    短彩信下发程序,短彩信生成程序,包含源代码(MMS issued a short program, short program to generate MMS)
    2011-12-14 11:09:33下载
    积分:1
  • eqep
    基于F28035的EQEP模块用于捕获外部脉冲的程序(The EQEP based F28035 module for capturing external pulse program)
    2020-08-23 15:38:16下载
    积分:1
  • 05753794
    说明:  《Office2000下内部COM插件的编程实现》配套代码,(< Office2000 internal COM plug-in programming implementation > supporting code,)
    2018-12-30 08:48:28下载
    积分:1
  • 696516资源总数
  • 106658会员总数
  • 16今日下载