国立中山大学资讯工程学系.doc
上传人:sy****28 上传时间:2024-09-10 格式:DOC 页数:3 大小:25KB 金币:12 举报 版权申诉
预览加载中,请您耐心等待几秒...

国立中山大学资讯工程学系.doc

国立中山大学资讯工程学系.doc

预览

在线预览结束,喜欢就下载吧,查找使用更方便

12 金币

下载此文档

如果您无法下载资料,请参考说明:

1、部分资料下载需要金币,请确保您的账户上有足够的金币

2、已购买过的文档,再次下载不重复扣费

3、资料包下载后请先用软件解压,在使用对应软件打开

國立中山大學資訊工程學系92學年度第2學期博士班資格考試作業系統OperatingSystemConcepts-45%ModernOperatingSystems-15%Other-40%1.Deadlock[15%,A.Silberschatz,P.Galvin,andG.Gagne,OperatingSystemConcepts,JohnWiley&Sons,Inc.,6thEd,Chapter8,Exercises9]Considerasystemconsistingofmresourcesofthesametype,beingsharedbynprocesses.Resourcescanberequestedandreleasedbyprocessesonlyoneatatime.Showthatthesystemisdeadlockfreeifthefollowingtwoconditionshold:a.Themaximumneedofeachprocessisbetween1andmresourcesb.Thesumofallmaximumneedsislessthanm+n2.MassStorage[15%,A.Silberschatz,P.Galvin,andG.Gagne,OperatingSystemConcepts,JohnWiley&Sons,Inc.,6thEd,Chapter14,Exercises2]Supposethatadiskdrivehas5000cylinders,numbered0to4999.Thedriveiscurrentlyservingarequestatcylinder143,andthepreviousrequestwasatcylinder125.Thequeueofpendingrequests,inFIFOorder,is86,1470,913,1774,948,1509,1022,1750,130Startingfromthecurrentheadposition,whatisthetotaldistance(incylinders)thatthediskarmmovestosatisfyallthependingrequests,foreachofthefollowingdiskschedulingalgorithms?A.FCFSB.SSTFC.SCAND.LOOKE.C-SCAN3.CPUScheduling[15%,A.Silberschatz,P.Galvin,andG.Gagne,OperatingSystemConcepts,JohnWiley&Sons,Inc.,6thEd,Chapter6,Exercises4]Supposethatthefollowingprocessesarriveforexecutionatthetimesindicated.Eachprocesswillrunthelistedamountoftime.Inansweringthequestions,usenonpreemptiveschedulingandbasealldecisionsontheinformationyouhaveatthetimethedecisionmustbemade.ProcessArrivalTimeBurstTimeP10.08P20.65P31.02(A).WhatistheaverageturnaroundtimefortheseprocesseswiththeFCFSschedulingalgorithm?(B).WhatistheaverageturnaroundtimefortheseprocesseswiththeSJFschedulingalgorithm?(C).TheSJFalgorithmissupposedtoimproveperformance,butnoticethatwechosetorunprocessP1attime0becausewedidnotknowthattwoshorterprocesseswouldarrivesoon.ComputewhattheaverageturnaroundtimewillbeiftheCPUisleftidleforthefirst1unitandthenSJFschedulingisused.RememberthatprocessesP1andP2arewaitingduringthisidletime,sotheirwaitingtimemayincrease.Thisalgorithmcouldbeknown