欢迎来到天天文库
浏览记录
ID:37725430
大小:448.56 KB
页数:21页
时间:2019-05-29
《普通本科专业毕业论文(设计)》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、SchedulingAlgorithmicResearchRamiAbielmona94.571(ELG6171)MondayMarch27,2000Prof.T.W.PearceSchedulingAlgorithmsIntroductionProblemdefinition:“OneCPUwithanumberofprocesses.OnlyoneprocesscanusetheCPUatatimeandeachprocessisspecializedinone,andonetask.What’sthebestwaytoorganizetheprocess
2、es(schedulethem)?”[1]“HowwilltheCPUtimebedividedamongtheprocessesandthreadscompetingtouseit?”[2]SchedulingAlgorithmsEmbeddedOSArchitectureKernel:TheexecutorExecutive:ThemanagerApplicationPrograms:TheprogrammertasksRealWorldInterfacing:S/WhandlingtheH/WSchedulingAlgorithmsBasicAssu
3、mptionsApoolofrunnableprocessesarecontendingforoneCPU;Theprocessesareindependentandcompeteforresources;ThejobofthescheduleristodistributethescarceresourceoftheCPUtothedifferentprocesses“fairly”andinanoptimalway;Thejobofthedispatcheristoprovidethemechanismforrunningtheprocesses;TheOS
4、isamultitasking,butnotamultiprocessor,one;OnlyCPUschedulingisconsidered(thelowestlevelofscheduling).SchedulingAlgorithmsEvaluationCharacteristicsSchedulingAlgorithmsProcessesandResourcesResources:Preemptible:Takeresourceaway,useitforsomethingelse,thengiveitback.(e.g.processororI/O
5、channel)Non-preemptible:Oncegive,itcan’tbereuseduntilprocessgivesitback.(e.g.filespaceorterminal)Processes:IObound:PerformlotsofIOoperations.IOburst----shortCPUbursttoprocessIO---IOburstCPUbound:PerformlotsofcomputationanddolittleIOCPUburst-----------SmallIOburst-----------CPUburstS
6、chedulingAlgorithmsProcessStateTransitionsThestatesofaprocess,atanygiventime,iscomprisedofthefollowingminimalset:Running:TheCPUiscurrentlyexecutingthecodebelongingtotheprocess.Ready:Theprocesscouldberunning,butanotherprocesshastheCPU.Waiting:Beforetheprocesscanrun,someexternalevent
7、mustoccur.SchedulingAlgorithmsTypesofSchedulersLong-termscheduler:admitsnewprocessestothesystem;requiredbecauseeachprocessneedsaportionoftheavailablememoryforitscodeanddata.Medium-termscheduler:isnotfoundinallsystems;requiredtocontrolthetemporaryremovalfrommemoryofaprocesswhenthela
8、tterisextractable.S
此文档下载收益归作者所有