文件名称:PV
- 所属分类:
- 其他小程序
- 资源属性:
- [Windows] [Visual C] [源码]
- 上传时间:
- 2013-12-15
- 文件大小:
- 1.24mb
- 下载次数:
- 0次
- 提 供 者:
- 范*
- 相关连接:
- 无
- 下载说明:
- 别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容均来自于网络,请自行研究使用
基于信号量与P/V操作同步机制的读者/写者问题的设计与实现
(1)设置读者、写者个数输入(界面);实现读者、写者进程的动态创建;
(2)用信号量与P/V操作同步机制实现写者优先的读者/写者问题。
(3)设计并实现运行结果(界面)包括:
动态显示多个读者或一个写者的读/写操作互斥状态:
显示正在进行读或写操作的进程,以及等待读或写操作的进程;
动态显示写者优先的过程:
即当有读者进程在读时,有写者进程要求写操作,后续的读者进程应该等待;并且当读操作的读者进程结束读操作后,等待的写者进程应能立即进行写操作。设计相应的等待队列。(4)进行读/写操作的进程可通过随机延时的方式来模拟读/写操作的时间过程。
-Design and Implementation of semaphores and P/V synchronization mechanisms operate reader/writer problem (1) Set the readers, who write the number of input (interface) realize readers who write dynamically created process (2) signal the amount of P/V operation synchronization mechanisms to achieve writer priority readers/writers problem. (3) design and implement the results (interface), including: Dynamic display multiple reader or a writer read/write operations are mutually exclusive states: Display a read or write operation is ongoing process and wait for the process to read or write operation Dynamic Display wrote preferred process: that is, when a reader processes in reading, there are writers process requires a write operation, the subsequent reader process should wait and after the read operation when the read operation of the reader end of the process, writer waiting for the process to be able to Now write operation. Design appropriate queue. (4) read/write operation is dela
(1)设置读者、写者个数输入(界面);实现读者、写者进程的动态创建;
(2)用信号量与P/V操作同步机制实现写者优先的读者/写者问题。
(3)设计并实现运行结果(界面)包括:
动态显示多个读者或一个写者的读/写操作互斥状态:
显示正在进行读或写操作的进程,以及等待读或写操作的进程;
动态显示写者优先的过程:
即当有读者进程在读时,有写者进程要求写操作,后续的读者进程应该等待;并且当读操作的读者进程结束读操作后,等待的写者进程应能立即进行写操作。设计相应的等待队列。(4)进行读/写操作的进程可通过随机延时的方式来模拟读/写操作的时间过程。
-Design and Implementation of semaphores and P/V synchronization mechanisms operate reader/writer problem (1) Set the readers, who write the number of input (interface) realize readers who write dynamically created process (2) signal the amount of P/V operation synchronization mechanisms to achieve writer priority readers/writers problem. (3) design and implement the results (interface), including: Dynamic display multiple reader or a writer read/write operations are mutually exclusive states: Display a read or write operation is ongoing process and wait for the process to read or write operation Dynamic Display wrote preferred process: that is, when a reader processes in reading, there are writers process requires a write operation, the subsequent reader process should wait and after the read operation when the read operation of the reader end of the process, writer waiting for the process to be able to Now write operation. Design appropriate queue. (4) read/write operation is dela
(系统自动生成,下载前可以参看下载内容)
下载文件列表
读者写者问题\Debug\input.txt
............\.....\StdAfx.obj
............\.....\vc60.idb
............\.....\vc60.pdb
............\.....\读者写者问题.exe
............\.....\读者写者问题.ilk
............\.....\读者写者问题.obj
............\.....\读者写者问题.pch
............\.....\读者写者问题.pdb
............\input.txt
............\ReadMe.txt
............\StdAfx.cpp
............\StdAfx.h
............\读者写者问题.cpp
............\读者写者问题.dsp
............\读者写者问题.dsw
............\读者写者问题.ncb
............\读者写者问题.opt
............\读者写者问题.plg
............\Debug
读者写者问题