PROCESS STATES
COMPUTER ORGANIZATION AND ARCHITECTURE DESIGNING FOR PERFORMANCE NINTH EDITION
To understand the operation of the short-term scheduler, we
need to consider the concept of a process state. During the lifetime of a process,
its status will change a number of times. Its status at any point in time is referred to
as a state. The term state is used because it connotes that certain information exists
that defines the status at that point. At minimum, there are five defined states for a
process (Figure 8.7):
• New: A program is admitted by the high-level scheduler but is not yet ready
to execute. The OS will initialize the process, moving it to the ready state.
• Ready: The process is ready to execute and is awaiting access to the processor.
• Running: The process is being executed by the processor.
• Waiting: The process is suspended from execution waiting for some system
resource, such as I/O.
• Halted: The process has terminated and will be destroyed by the OS.
For each process in the system, the OS must maintain information indicat-
ing the state of the process and other information necessary for process execution.
For this purpose, each process is represented in the OS by a process control block
(Figure 8.8), which typically contains
• Identifier: Each current process has a unique identifier.
• State: The current state of the process (new, ready, and so on).
• Priority: Relative priority level.
• Program counter: The address of the next instruction in the program to be
executed.
• Memory pointers: The starting and ending locations of the process in memory.
• Context data: These are data that are present in registers in the processor
while the process is executing, and they will be discussed in Part Three. For
now, it is enough to say that these data represent the “context” of the process.
The context data plus the program counter are saved when the process leaves
the running state. They are retrieved by the processor when it resumes execu-
tion of the process.
• I/O status information: Includes outstanding I/O requests, I/O devices (e.g., tape
drives) assigned to this process, a list of files assigned to the process, and so on.
• Accounting information: May include the amount of processor time and clock
time used, time limits, account numbers, and so on.
When the scheduler accepts a new job or user request for execution, it creates
a blank process control block and places the associated process in the new state.
After the system has properly filled in the process control block, the process is
transferred to the ready state.
PROCESS STATES的更多相关文章
- Linux Process VS Thread VS LWP
Process program program==code+data; 一个进程可以对应多个程序,一个程序也可以变成多个进程.程序可以作为一种软件资源长期保存,以文件的形式存放在硬盘 process: ...
- The Concept of a Process
COMPPUTER SCIENCE AN OVERVIEW 11th Edition One of the most fundamental concepts of modern operating ...
- Linux 日志报错 xxx blocked for more than 120 seconds
监控作业发现一台服务器(Red Hat Enterprise Linux Server release 5.7)从凌晨1:32开始,有一小段时间无法响应,数据库也连接不上,后面又正常了.早上检查了监听 ...
- Investigating Your RAM Usage
转载自:http://developer.android.com/intl/zh-cn/tools/debugging/debugging-memory.html Because Android is ...
- Android内存管理(5)*官方教程:Logcat内存日志各字段含义,查看当前内存快照,跟踪记录内存分配,用adb查看内存情况时各行列的含义,捕获内存快照的3种方法,如何让程序暴漏内存泄漏的方法
Investigating Your RAM Usage In this document Interpreting Log Messages 内存分析日志中各消息的含 ...
- Linux-进程管理
关于进程 Process what is process ? 什么是进程 process life cycle 进程的生命周期 process states 进程状态 什么是进程? 进程是已启动的可执 ...
- bootstrap-typeahead 自动补全简单的使用教程
参考链接: 参考1 : https://segmentfault.com/a/1190000006036166参考2 : https://blog.csdn.net/u010174173/articl ...
- Virtualization
time sharing——>virtualization. OS需要low-level machinery mechanisms and high-level intelligence. 前者 ...
- liunx进程管理之进程介绍
关于进程 process ====================================================================================Wha ...
随机推荐
- Laravel 4 系列入门教程(一)
默认条件 本文默认你已经有配置完善的PHP+MySQL运行环境,懂得PHP网站运行的基础知识.跟随本教程走完一遍,你将会得到一个基础的包含登录的简单blog系统,并将学会如何使用一些强大的Larave ...
- 写好的mapreduce程序,编译,打包,得到最后的jar包! 验证jar包 ! 整体流程
创建一个bin目录,用于存放编译.java文件产生的.class等结果,然后编译! 编译结果! 打包操作! 打包结果! 验证打包生成的jar包,是否正常,验证成功!!!!!!!!!!!! 结果正确!! ...
- 【HTML5】Server-Sent服务器发送事件
Server-Sent 事件 - 单向消息传递 Server-Sent 事件指的是网页自动获取来自服务器的更新. 以前也可能做到这一点,前提是网页不得不询问是否有可用的更新.通过服务器发送事件,更新能 ...
- Hark的数据结构与算法练习之鸡尾酒排序
算法说明 鸡尾酒排序又叫定向冒泡排序,鸡尾酒搅拌排序,搅拌排序,涟漪排序,回来排序,快乐小时排序. 鸡尾酒排序是交换排序的一种,它是冒泡排序的一个轻微的变种.冒泡是从低向高比较排序,鸡尾酒从低向高,从 ...
- JS一个根据时区输出时区时间的函数
做项目遇到的坑爹问题,需要根据时区获取时区中轴线的时间.为此搜了好久网上都没什么JS的代码描述到这一方面,最后自己翻了下高中地理才写了个函数出来. 此图可以看出来,全球分为了0时区,东西1-11区,第 ...
- SpringBoot相关
快速构建项目 第 1 步:将这个 Spring Boot 项目的打包方式设置为 war. <packaging>war</packaging> SpringBoot 默认有内嵌 ...
- Codeforces 161D Distance in Tree(树的点分治)
题目大概是,给一棵树,统计距离为k的点对数. 不会DP啊..点分治的思路比较直观,啪啪啪敲完然后AC了.具体来说是这样的: 树上任何两点的路径都可以看成是一条过某棵子树根的路径,即任何一条路径都可以由 ...
- 【转载】Linux下makefile详解--跟我一起写 Makefile
概述 —— 什么是makefile?或许很多Winodws的程序员都不知道这个东西,因为那些Windows的IDE都为你做了这个工作,但我觉得要作一个好的和professional的程序员,makef ...
- 【推荐】开放静态文件 CDN服务staticfile.org
虽然国内外有很多类似的服务器,比如最初的google ajax api,还有后来的sae,百度等都有提供,但是也都有不同的弊端,比如国内访问速度慢.提供的静态文件不全等...staticfile有望解 ...
- wp7 HubTile
在最新的Windows Phone Toolkit中我们可以看到HubTile这个控件,首先先了解下什么是HubTile,简单来说,就是允许你给你的应用程序添加些生动或富有意义的瓦片(Tile).Hu ...