b04902xxx 板


LINE

※ [本文转录自 NTU-Exam 看板 #1Jb25YcT ] 作者: irritum (′・ω・‵) 看板: NTU-Exam 标题: Re: [试题] 102下 郭大维 作业系统 期中考 解答 时间: Sun Jun 8 16:39:58 2014 课程名称︰作业系统 课程性质︰必修 课程教师︰郭大维 开课学院:电资学院 开课系所︰资工系 考试日期(年月日)︰2014/4/30 考试时限(分钟):180 是否需发放奖励金:是 (如未明确表示,则不予发放) 试题 : The exam is 180 minutes long. The total score is 103pts. Please read the questions carefully. 1.Terminologies (24pts). a. Booting Initialize all aspects of the system and then load and run the OS. b. Interrupt Vector An array of interrupt-handlers' addresses that are indexed by device numbers (or interrupt numbers). c. Cache Coherency Cache coherency problems can arise when more than one processors refer to the same data. Coherency defines what value is returned on a read. d. Platform as a service (PaaS) in Cloud Computing Pass provides a computing platform and a solution stack as a service, such as a database server. One example is Microsoft Azure. e. A Modular Kernel (Hint: OS Structure) A moduler kernel consists of a set of components, where there are core/primary modules, and it is of modules without a layer structure. f. Data Parellelism in Multicore Programming Distribute data over cores to execute the same operation. g. Rate Monotonic Scheduling A fixed priority real-time process scheduling algorithm in which the priorities of processes are inversely proportional to their periods. h. Deterministic Modeling Take a particular predetermined workload and defines the performance of each algorithm for that workload. 2. Please answer the following questions regarding the designs of operating systems: (20pts) a. There are two conflicting goals in the designs of operating systems. What is the other one, beside "convenient for the users" ? (3pts) b. Which one of the following actions/events is belonging to or might result in software interrupts: System calls, child termination, mouse clicking, invalid memory access. (8pts) c. Consider the implementation of virtual machines in which operating systems run on the top of the virtual machine software (or referred to as the hypervisor). Is an operating system running in the user mode or kernel mode? (3pts) d. Please give me 2 advantages of virtual machines, beside system consolidation and easy in system development/deployment. (6pts) (a) Efficient operation of the computer system. (b) System calls, child termination, and invalid memory access. (c) The user mode. (d) Complete isolation and multiple personalities. 3. ANSI C refers to the family of successive standards published by ANSI for the C programming language. Please compare difference (or provide the purpose difference) between POSIX and ANSI C. (5pts) Any program written only in ANSI C and without any hardware dependent assumptions is virtully guarnteed to compile correctly on any platform with a conforming C implementation. POSIX is an acronym for "Portable Operating System Interface". POSIX is for software compatibility with variants of Unix and other operating systems. 4. Please answer the following questions for task scheduling. (14pts) a. Is the "Swapper" a short-term or mid-term scheduler? b. In Unix, the process control block PCB[] of a process consists of proc[] and .u, where the attributes in .u are those needed when the process is running, and the attributes in proc[] are those needed all the time. Please indicate which one should be in .u : file[], task priority, pid, signal disposition, and task state. You must provide explanation to receive any credits. (10pts) (a) It is a short-term scheduler. (b) file[] and signal disposition. 5. Consider message passing and shared memory for inerprocess communication. Is "Pipe" considered one for message passing or shared memory ? Is "Pipe" direct or indirect communication ? Is it "synchronous" or "asynchronous" ? for a reader or a writer of the communication in Unix. You must provide explanation to receive any credits. (12pts) It is "message passing" and indirect communication. Reader: synchronous; Writer: asynchronous. 6. Kernel-level threads are superior than uer-level threads do in many ways. What is the main disadvantage of kernel-level threads ? With OpenMP in program development, shall we prefer kernel-level or user-level threads ? You must provide explanation to receive any credits. (8pts) It is context switching cost. With OpenMP, we should prefer kernel-level threads because we look for parallelism to better utilize multiple cores of a system. 7. Please answer the following questions for process scheduling. Explanation is needed to receive any credits. (15pts) a. Given 3 processes P1, P2, and P3 with CPU burst time 5, 6, 7, respectively. Suppose that the 3 processes arrive at time 0, and P1 and P3 are the first and the last processes in the ready queue, respectively. What is the average waiting time in running the 3 processes under the Round-Robin Scheduling with the time slice equal to 3. (5pts) b. Consider FCFS and Round-Robin Scheduling. If process are only of CPU burst and all arrive at time 0, do FCFS and Round-Robin Scheduling with time slice = 1 always have the same total waiting time in running all processes ? Prove your answer. (5pts) c. Suppose that the variance of the tunaround time is the cirterion in process scheduling. Shall we have a small time slice for a better variance turnaround time when all processes arrive at time 0? (5pts) (a) (6 + (3 + 5) + (6 + 3)) / 3 = 23 / 3 (b) Nope. Give one example, such as processes of CPU burst 7, 1, and 1. (c) Yes. 8. Please explain why the Completely Fair Scheduling (CFS) of Linux V2.6 favors I/O tasks. (5pts) An example answer: CFS usually dispatches the CPU to the task with the smallest vruntime (that denotes how long the task runs) such that I/O tasks usually have smaller vruntime. --



※ 发信站: 批踢踢实业坊(ptt.cc), 来自: 140.112.217.52
※ 文章网址: http://webptt.com/cn.aspx?n=bbs/NTU-Exam/M.1402216802.A.99D.html
1F:→ rod24574575 :已收资讯系! 06/10 00:36



※ 发信站: 批踢踢实业坊(ptt.cc)
※ 转录者: w4a2y4 (140.112.16.131), 05/01/2017 16:19:48







like.gif 您可能会有兴趣的文章
icon.png[问题/行为] 猫晚上进房间会不会有憋尿问题
icon.pngRe: [闲聊] 选了错误的女孩成为魔法少女 XDDDDDDDDDD
icon.png[正妹] 瑞典 一张
icon.png[心得] EMS高领长版毛衣.墨小楼MC1002
icon.png[分享] 丹龙隔热纸GE55+33+22
icon.png[问题] 清洗洗衣机
icon.png[寻物] 窗台下的空间
icon.png[闲聊] 双极の女神1 木魔爵
icon.png[售车] 新竹 1997 march 1297cc 白色 四门
icon.png[讨论] 能从照片感受到摄影者心情吗
icon.png[狂贺] 贺贺贺贺 贺!岛村卯月!总选举NO.1
icon.png[难过] 羡慕白皮肤的女生
icon.png阅读文章
icon.png[黑特]
icon.png[问题] SBK S1安装於安全帽位置
icon.png[分享] 旧woo100绝版开箱!!
icon.pngRe: [无言] 关於小包卫生纸
icon.png[开箱] E5-2683V3 RX480Strix 快睿C1 简单测试
icon.png[心得] 苍の海贼龙 地狱 执行者16PT
icon.png[售车] 1999年Virage iO 1.8EXi
icon.png[心得] 挑战33 LV10 狮子座pt solo
icon.png[闲聊] 手把手教你不被桶之新手主购教学
icon.png[分享] Civic Type R 量产版官方照无预警流出
icon.png[售车] Golf 4 2.0 银色 自排
icon.png[出售] Graco提篮汽座(有底座)2000元诚可议
icon.png[问题] 请问补牙材质掉了还能再补吗?(台中半年内
icon.png[问题] 44th 单曲 生写竟然都给重复的啊啊!
icon.png[心得] 华南红卡/icash 核卡
icon.png[问题] 拔牙矫正这样正常吗
icon.png[赠送] 老莫高业 初业 102年版
icon.png[情报] 三大行动支付 本季掀战火
icon.png[宝宝] 博客来Amos水蜡笔5/1特价五折
icon.pngRe: [心得] 新鲜人一些面试分享
icon.png[心得] 苍の海贼龙 地狱 麒麟25PT
icon.pngRe: [闲聊] (君の名は。雷慎入) 君名二创漫画翻译
icon.pngRe: [闲聊] OGN中场影片:失踪人口局 (英文字幕)
icon.png[问题] 台湾大哥大4G讯号差
icon.png[出售] [全国]全新千寻侘草LED灯, 水草

请输入看板名称,例如:BuyTogether站内搜寻

TOP