06(计)A 东南大学 计算机学院 操作系统试卷
东 南 大 学 考 试 卷( A 卷) 课程名称 操作系统原理 考试学期 05-06 得分 适用专业 计算机 考试形式 闭卷 考试时间长度 120分钟 Ⅰ Explain the following clauses in the course of OS.(7.5×4=30 points) 1. SPOOLING 2. System Call 3. multi-programming 4. process deadlock Ⅱ Answer the following questions.(10+15=25 points) 1. Why it is necessary to use an open file command before to read (or write) a file? 2. Which kinds of interface commands are provided by device-driver to the kernel I/O subsystem? Ⅲ Computation(18 points) Consider the following page-reference string: 1,2,3,4,2,1,5,6,2,1,2,3,7,6,3,2,1,2,3,6 How many pages faults would occur for the following replacement algorithms, assuming three frames? Remember that all frames are initially empty, so your first unique pages will all cost one fault each. 1.LRU replacement 2.FIFO replacement 3.Optimal replacement Ⅳ Programming(27 points)
The solution to the first readers-writers problem does not prevent waiting writers from starving: If the database is currently being read and there is a waiting writer, subsequent readers will be allowed to read the database before the writer can write. Modify the solution such that it does not starve waiting writers.
1.Give a modification approach and
2.Write a segment of java code to implement this approach
共 1 页 第 1 页