文件名称:Scheduling
-
所属分类:
- 标签属性:
- 上传时间:2013-11-14
-
文件大小:1mb
-
已下载:0次
-
提 供 者:
-
相关连接:无下载说明:别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容来自于网络,使用问题请自行百度
设计一个按优先数调度算法实现处理器调度的程序
提示:
(1)假定系统有5个进程,每个进程用一个PCB来代表。PCB的格式为:
进程名、指针、要求运行时间、优先数、状态。
进程名——P1~P5。
指针——按优先数的大小把5个进程连成队列,用指针指出下一个进程PCB的首地址。
要求运行时间——假设进程需要运行的单位时间数。
优先数——赋予进程的优先数,调度时总是选取优先数大的进程先执行。
状态——假设两种状态,就绪,用R表示,和结束,用E表示。初始状态都为就绪状态。
(2) 每次运行之前,为每个进程任意确定它的“优先数”和“要求运行时间”。
(3) 处理器总是选队首进程运行。采用动态改变优先数的办法,进程每运行1次,优先数减1,要求运行时间减1。
(4) 进程运行一次后,若要求运行时间不等于0,则将它加入队列,否则,将状态改为“结束”,退出队列。
(5) 若就绪队列为空,结束,否则,重复(3)。-Design a number of priority scheduling algorithm processor scheduling procedures
Hint:
( 1 ) assumes that the system has five processes, each with a PCB to represent . PCB in the format:
Process name , pointer, required running time, priority number , status.
Process Name- P1 ~ P5.
Pointer- the size of the number of priority 5 into Cheng Liancheng queue , using a pointer that the next process, the first address of the PCB .
The time required to run- assuming unit time required to run the process number .
Priority number- number of priority given to the process , always select a priority when scheduling a large number of processes executed first .
State- assuming two states , Ready, represented by R , and the end , with the E said . The initial state is the ready state .
( 2 ) Before each run , for each process arbitrarily determined its " priority number " and " run-time requirements ."
( 3 ) processor always choose the first team to run the process . Dynamic way to change th
提示:
(1)假定系统有5个进程,每个进程用一个PCB来代表。PCB的格式为:
进程名、指针、要求运行时间、优先数、状态。
进程名——P1~P5。
指针——按优先数的大小把5个进程连成队列,用指针指出下一个进程PCB的首地址。
要求运行时间——假设进程需要运行的单位时间数。
优先数——赋予进程的优先数,调度时总是选取优先数大的进程先执行。
状态——假设两种状态,就绪,用R表示,和结束,用E表示。初始状态都为就绪状态。
(2) 每次运行之前,为每个进程任意确定它的“优先数”和“要求运行时间”。
(3) 处理器总是选队首进程运行。采用动态改变优先数的办法,进程每运行1次,优先数减1,要求运行时间减1。
(4) 进程运行一次后,若要求运行时间不等于0,则将它加入队列,否则,将状态改为“结束”,退出队列。
(5) 若就绪队列为空,结束,否则,重复(3)。-Design a number of priority scheduling algorithm processor scheduling procedures
Hint:
( 1 ) assumes that the system has five processes, each with a PCB to represent . PCB in the format:
Process name , pointer, required running time, priority number , status.
Process Name- P1 ~ P5.
Pointer- the size of the number of priority 5 into Cheng Liancheng queue , using a pointer that the next process, the first address of the PCB .
The time required to run- assuming unit time required to run the process number .
Priority number- number of priority given to the process , always select a priority when scheduling a large number of processes executed first .
State- assuming two states , Ready, represented by R , and the end , with the E said . The initial state is the ready state .
( 2 ) Before each run , for each process arbitrarily determined its " priority number " and " run-time requirements ."
( 3 ) processor always choose the first team to run the process . Dynamic way to change th
(系统自动生成,下载前可以参看下载内容)
下载文件列表
Scheduling/Debug/Scheduling.exe
Scheduling/Debug/Scheduling.ilk
Scheduling/Debug/Scheduling.pdb
Scheduling/Scheduling/Debug/BuildLog.htm
Scheduling/Scheduling/Debug/mt.dep
Scheduling/Scheduling/Debug/Scheduling.exe.embed.manifest
Scheduling/Scheduling/Debug/Scheduling.exe.embed.manifest.res
Scheduling/Scheduling/Debug/Scheduling.exe.intermediate.manifest
Scheduling/Scheduling/Debug/Scheduling.obj
Scheduling/Scheduling/Debug/Scheduling.pch
Scheduling/Scheduling/Debug/stdafx.obj
Scheduling/Scheduling/Debug/vc90.idb
Scheduling/Scheduling/Debug/vc90.pdb
Scheduling/Scheduling/ReadMe.txt
Scheduling/Scheduling/Scheduling.cpp
Scheduling/Scheduling/Scheduling.vcproj
Scheduling/Scheduling/Scheduling.vcproj.RecluseGu-PC.RecluseGu.user
Scheduling/Scheduling/stdafx.cpp
Scheduling/Scheduling/stdafx.h
Scheduling/Scheduling/targetver.h
Scheduling/Scheduling.ncb
Scheduling/Scheduling.sln
Scheduling/Scheduling.suo
Scheduling/Scheduling/Debug
Scheduling/Debug
Scheduling/Scheduling
Scheduling
Scheduling/Debug/Scheduling.ilk
Scheduling/Debug/Scheduling.pdb
Scheduling/Scheduling/Debug/BuildLog.htm
Scheduling/Scheduling/Debug/mt.dep
Scheduling/Scheduling/Debug/Scheduling.exe.embed.manifest
Scheduling/Scheduling/Debug/Scheduling.exe.embed.manifest.res
Scheduling/Scheduling/Debug/Scheduling.exe.intermediate.manifest
Scheduling/Scheduling/Debug/Scheduling.obj
Scheduling/Scheduling/Debug/Scheduling.pch
Scheduling/Scheduling/Debug/stdafx.obj
Scheduling/Scheduling/Debug/vc90.idb
Scheduling/Scheduling/Debug/vc90.pdb
Scheduling/Scheduling/ReadMe.txt
Scheduling/Scheduling/Scheduling.cpp
Scheduling/Scheduling/Scheduling.vcproj
Scheduling/Scheduling/Scheduling.vcproj.RecluseGu-PC.RecluseGu.user
Scheduling/Scheduling/stdafx.cpp
Scheduling/Scheduling/stdafx.h
Scheduling/Scheduling/targetver.h
Scheduling/Scheduling.ncb
Scheduling/Scheduling.sln
Scheduling/Scheduling.suo
Scheduling/Scheduling/Debug
Scheduling/Debug
Scheduling/Scheduling
Scheduling
本网站为编程资源及源代码搜集、介绍的搜索网站,版权归原作者所有! 粤ICP备11031372号
1999-2046 搜珍网 All Rights Reserved.