网站大量收购闲置独家精品文档,联系QQ:2885784924

硬体(Hardware)、作业系统(Operating System) - Min-Shiang Hwang.PPT

硬体(Hardware)、作业系统(Operating System) - Min-Shiang Hwang.PPT

  1. 1、本文档共55页,可阅读全部内容。
  2. 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
  3. 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载
  4. 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
硬体(Hardware)、作业系统(Operating System) - Min-Shiang Hwang

1.4 Operating System Structure (作業系統架構) Multiprogramming needed for efficiency Single user cannot keep CPU and I/O devices busy at all times Multiprogramming organizes jobs (code and data) so CPU always has one to execute A subset of total jobs in system is kept in memory One job selected and run via job scheduling (工作排班) When it has to wait (for I/O for example), OS switches to another job Timesharing (multitasking) is logical extension in which CPU switches jobs so frequently that users can interact with each job while it is running, creating interactive computing Response time should be 1 second Each user has at least one program executing in memory ?process If several jobs ready to run at the same time ? CPU scheduling If processes don’t fit in memory, swapping moves them in and out to run Virtual memory allows execution of processes not completely in memory Memory Layout for Multiprogrammed System 作業系統提供執行程式的環境,工作排班的最重要觀念就是多元程式規劃的能力。多元程式規劃 (multiprogramming)的目的就是讓CPU始終有工作做,以增加CPU的使用率。 作業系統在同一時間存放數項工作在記憶體中,這一組工作是工作池(job pool)中所有工作的部份集合,作業系統把工作池中的一項工作挑出來並且開始執行。 Time Sharing(分時)或Multitasking(多工)是常用的多元程式規劃技術。 1.5 Operating-System Operations (作業系統的運作) Interrupt driven by hardware Software error or request creates exception or trap Division by zero, request for operating system service Other process problems include infinite loop, processes modifying each other or the operating system 現代作業系統是中斷驅動式 (interrupt driven),如果沒有行程要執行,沒有I/O裝置要服務和沒有使用者需要回應,則作業系統將安靜進入等待事件發生;事件通常都是由於中斷或陷阱(Trap)的發生(如被0除)而被通知。 因為作業系統和使用者共用電腦系統中硬體和軟體的資源,在共用的情況下,一個程式中的錯誤(如Infinite Loop)可能會使許多工作受到不利影響。 一個設計正確的作業系統必須保證一個不正確的 (或蓄意破壞的)程式不會造成其他程式不正確的執行。 Dual-mode operation allows OS to protect itself and other system components User mode and kernel mode Mode bit provided by hardware Provides ability to distinguish when system is running user code or kernel code Some instructions designated as privileged, only executable in kernel mode System call changes mode to kernel, return from call resets it

文档评论(0)

youbika + 关注
实名认证
内容提供者

该用户很懒,什么也没介绍

1亿VIP精品文档

相关文档