操作系統(tǒng)試卷2007卷_第1頁
操作系統(tǒng)試卷2007卷_第2頁
操作系統(tǒng)試卷2007卷_第3頁
操作系統(tǒng)試卷2007卷_第4頁
操作系統(tǒng)試卷2007卷_第5頁
全文預(yù)覽已結(jié)束

下載本文檔

版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進行舉報或認領(lǐng)

文檔簡介

1、東 北 大 學 考 試 試 卷 (A卷 )20072008學年 第 二 學期課程名稱:Operating System. Multiple Choice (10 points,1 point each)Directions: There are 10 questions. For each question there are 4 choices marked A, B, C and D. You should make the correct choices (one or more choices may be correct) and write down the correspondi

2、ng letters.6(B) What refers to the page replacement algorithm which replaces the page that has notbeen used for the longest period of time?(A) FIFO(B) LRU(C) OPT(D) LFU密1(BCD ) What are the major activities of an operating system?7(BCD) Which of the followings is a condition for deadlock?(A) User ma

3、nagement(C) I/O system management(B) Main memory management(D) File management(A) Starvation(B) Circular Wait(C) No Preemption(D) Mutual Exclusion8(A) The basic function of the file system is accessing files by names. The function can2(ABC ) The way that operating system components are interconnecte

4、d andbe realized by(A) directory-managing(C) file-protectingmodeled into a kernel can be(A) Simple structure(C) Layered approach(B) boosting the speed of the file-accessing(D) improving the utilization of storage(B) Microkernels(D) Prototype approach9(B) Preemption allocation strategies can be appli

5、ed to3(toC) What state is a process in when it can not run because it needs a resourcee available?(A) Main memory space(C) I/O system management(B) CPU management(D) Tape management封(A) Ready(B) Interrupt(C) Blocked(D) Running10(ABC ) Which of the following strategies need base register and length r

6、egister?4(ABC ) Which are the major differences between user-level threads and(A) paging(B) segmentation(D) fixed-sized partitions memory-managementkernel-level threads?(A) User-level threads kernel threads.(C) segmentation with pagingare unknown by the kernel, whereas the kernel is awareof. Concept

7、 Explanations (12 points, 3 points each)Directions: Explain the following concepts by giving the Chinese saying and describing the main features.User threads are scheduled by the thread library and the kernel schedules kernel threads.Kernel threads need not be associated with a process whereas every

8、 user thread belongs to a process.One user-level thread can be only mapped be one kernel thread.1System call線進程與操作系統(tǒng)之間的接口5(ABCD ) Which of the following free-space management strategies are supportedby an operating system?(A) Bit Vector(B) Linked list(C) Grouping(D) Counting學 院班 級學 號姓 名總分一二三四2What i

9、s the cause of trashing? How does the system detect thrashing? Once it thrashing, what can the system do to eliminate this problem?detects2Critical section進程中關(guān)于臨界資源的代碼段3Directory是為了對文件實施有效管理,將他們妥善的管理起來密4Overlay為了能讓進程比他所分配到的內(nèi)存空間大。基本思想:任何時候只在內(nèi)存中保存所需的指令和數(shù)據(jù),當需其他指令時,他們會裝入到剛剛不再需要的指令的內(nèi)存空間內(nèi)3What is SPOOLing

10、? Describe how SPOOLing works using printer as an example.封. Brief Answers (20 points, 5 points each) Directions: Answer the following questions briefly.1Whats the difference between process and program? Whats the difference between process and thread?A程序是完成所需求的功能時,所應(yīng)采取的順序步驟,是執(zhí)行指令的有序集合。進程是執(zhí)行中的程序。包括程

11、序計數(shù)器,進程堆棧段 數(shù)據(jù)段程序和進程區(qū)別:程序是一個靜態(tài)的概念,作為一種資源可以永久的存放在磁盤中。進程是程序執(zhí)行的動態(tài)活動過程,隨程序執(zhí)行而發(fā)生,隨程序執(zhí)行結(jié)束而消亡靜止狀態(tài)的程序和數(shù)據(jù)是相互獨立的信息集合,進程中的程序和數(shù)據(jù)是一個不可分割的實體,一個程序可以對應(yīng)多進程進程是4Consider a system consisting of 4 resources of the same type that are shared by three processes, each of which needs at most 2 resources. Show that the system

12、is deadlock free.線學 院班 級學 號姓 名. Comprehensive Questions(58 points)2(10 points) Consider the following snapshot of a system:AllocationMaxR3 15555AvailableR1R2R3R4R1 02020R2 00033R3 10353R4 20442R1 02640R2 07636R4 20662P0 P1 P2 P3P421001 (5 points)Consider a memory management system with paging. There

13、 are threejobs, J1, J2 and J3, are in the memory now. J2 has 4 pages, which are stored in the 3rd,4th, 6thand 8th block of the main memory respectively. Suppose the page size is 1024bytes, and the main memory is 10k bytes, please answer the following two questions:密(1) Draw the page table of J2;Answ

14、er the following questions using the bankers algorithm:How many instances of each resource type in the system?What is the content of the matrix Need?Is the system in a safe state? Why?If a request from process P2 arrives for (0,1,0,0), can the request be granted immediately?(2) If J2 meets the instr

15、uction “MOV 2100, 3100” (decimal) at its logical address500 (decimal), give the physical addresses of the two operands above.封線.學 院班 級學 號姓 名4(20 points) Consider the following set of processes, with the length of the CPU-burst timegiven in milliseconds:3(15 points) Consider the following page refere

16、nce string:、 、 、 、 、 、 、 、 、 、 、 、 、 、 、 、 、 、1、3Please write processes of the following replacement algorithms and give the number of page faults, assuming three frames? Remember all frames are initially empty, so your first unique pages will all cost one fault each.FIFO replacementLRU replacementO

17、ptimal replacementProcess P1P2 P3 P4P5Arrival time 02468Burst time (ms) 36452Priority 35124密Draw Gantt charts illustrating theexecution of these processes of the following schedulingalgorithms, and calculate the waiting time of each process as well as the average waiting time of each scheduling algorithms.Preemptive and non-preemptive SJFPreemptive priority (a smaller priority number implies a higher priority)RR (quantum = 4ms)封線學 院班 級學 號姓 名密5(8 points) Consider four processes A, B, C and D, sharing a same buffer. Process A inputs one object into the buffer each time,

溫馨提示

  • 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
  • 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
  • 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負責。
  • 6. 下載文件中如有侵權(quán)或不適當內(nèi)容,請與我們聯(lián)系,我們立即糾正。
  • 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。

評論

0/150

提交評論