Вы находитесь на странице: 1из 5

Synopsis

Process Scheduling in Android

SubmittedBy.. Ishan(11110699) RK1107B40

What is Android ?
LiketheWebOS,Androidisanoperatingsystembaseduponthepreexistinglinuxoperating system,optimizedformobiledevices.Itisdesignedprimarilyfortouchscreenmobiledevices suchasSmartphones.InitiallydevelopedbyAndroidInc,itwaslaterboughtbyGooglein2005. Andsincethenitisbeingbackedanddevelopedbythetechnologygiant. Itisanopensourceproject,whichmeansthatallthesource codeisavailablefreeofcost.Androidislicensedunderthe ApacheLicense.SinceitisundertheApachelicense,it requiresthepreservationofcopyrightnoticeandthe disclaimer.TheApacheLicenseallowstheuserofthesoftwarethefreedomtousethecode, modifyit,anddistributeit,evenforthepurposeofgeneratingroyaltieswithoutbeingconcerned ofsharingtheroyaltywiththeoriginalprojectcreators. Sinceitisanoperatingsystemdesignedformobiledevices,alotofdecisionshavetobemade whichhastofavortheconditionsofamobiledevice.

For Example :
ItdoesnthavethepowersupplylikethedesktopsorLaptopsthatmeanithastokeepthepower usageinextremecheck. Tinyscreensmeanthatfortheuserexperiencetobegreat,theinterfacehastoberevamped completely. Sincetheuserisgonnaholdthedevicesalotcloserthanthetraditionaldesktops,itmeans greaterpixeldensityandthusmoreprocessingfordisplayingsameamountofcontentwhen comparedtodesktops. Androidhasalistoffeaturesthatitsupports,someofthefeaturesthatitsupportsrightnoware Inadditiontosupportingmultimediafiles,GSM,Bluetooth,Wifi,GPRSandhavinganinternet browser.ItalsohaveanApplicationFrameworkforthedeveloperstoworkon,DalvikVirtual Machine(JavaByteCodeinterpreter,optimizedformobile)Webkitengine,SQLite,OpenGLES.

What is Process-Scheduling ?
Schedulinginitsstrictestsenserefers tothemanagementofProcesses, Threadsandflowofthedata. Schedulingalgorithmsareusedfor allocatingresourcesamongdifferent entitieswhicharerequestingthem simultaneouslyandasynchronously. Therearedifferenttechniquesand Algorithmswhichhavebeendeveloped overtimeforthemanagement (Scheduling)overtime.

The three distinct categories of Schedulers : LongTermScheduler MidTermScheduler ShortTermScheduler SomeAlgorithmswhichgarneredmoreattractionthanothersintheraceofpopularityand performanceare:

First in First out AlsoknownasFirstComeFirstServe.Itisthesimplestschedulingalgorithm.FirstInFirstOut (FIFO)simplyprocessestherequestsastheyarrive.Noneoftheotheralgorithmsarethis simple.FIFOdoesntcomesinthegroupoftheeffectiveschedulingalgorithmsforgeneral purposecases,wheretheuseralmostalwaysismultitasking.

Shortest Job First AlsoknownasSJF,thistechniquewecomparewhichistheshortestjobavailableatthetimeto bedone.Wethenexecutethatspecificjobstallinganyotherlongerjobwhichmayhavebeen requestedlongago.Thisalgorithmmayeffectivelyblockanylargeprocessiftherearemany smallerprocessrequestsspurringcontinuously.

Shortest Remaining Time SimilartoShortestJobFirst,thisstrategyrequirestheschedulertoarrangerequestsintheorder wheretheleastestimatedprocessingtimeremainingistobeexecutedfirst.Thisalgorithm requiresadvancedknowledgeorestimationsaboutthetimerequiredforajobtocomplete.

Fixed Priority Preemptive Scheduling Thealgorithmsassignsafixedpriorityranktoeveryjob.Itthenarrangestheprocessesinorder oftheirpriority.Lowerprioritygetsexecutedlasthoweverhigherprioritygetsexecutedearlier. Executionoflowerpriorityjobscanbeinterruptedbyhigherpriorityjobs.

Round Robin Scheduling Inthiscasetheschedulerassignsafixedamountoftime(quantumtime)ofexecutiontobe giventoeveryjob.Ifthejobgetsexecutedwithinthetimeframe,theschedulermovestothenext job,butifthejobisnotdone,ithastowaitfortheschedulertocyclethroughalltheprocesses beforecomingbacktoit.

Multilevel Queue Scheduling Thisisusedforsituationsinwhichjobsareeasilydividedintogroups.

Process Scheduling in Android :


AsitisalreadymentionedthatandroidisbasedonLinux.Thusitmeansthatitskernelisderived aftermakingchangestotheLinuxskerneltobeoptimizedformobiledevices. AndroidiscurrentlyusingLinux2.6foritslowlevelmanagementofresources.Linux2.6 happenstouseCompletelyFairScheduler.ItismadebyIngoMolnr,whowasinspiredbytheCon
KolivassworkonFairScheduling. ApplicationsinAndroidareknowasActivities.Eachactivityhasitsownlifecycle.Basedontheworkthat eachactivityisdoing,theyarecategorisedintodifferentcategoriesandpriorityissetonthebasisof importanceoftheactivitytotheuser. Wheneveranapplicationcomponentstartsandtheapplicationdoesnothaveanyothercomponentsrunning anewlinuxprocessisstartedforitwithasinglethreadofexecution(alsoknownasmainthreadortheUI thread). Thedifferentcategoriesoftheprocessesare: 1. ForegroundProcess 2. VisibleProcess 3. ServiceProcess 4. BackgroundProcess 5. EmptyProcess Androidranksaprocessatthehighestlevelitcanfindsuitableforit,basedupontheimportanceofthe componentscurrentlyactiveintheprocess.

References :
AndroidDevelopers http://developer.android.com CornellUniversityLibrary http://arxiv.org/ Stackexchange http://android.stackexchange.com Stackoverflow http://stackoverflow.com Wikipedia|English http://en.wikipedia.org Google https://www.google.co.in/ Unixmen http://www.unixmen.com GoogleDocs https://docs.google.com Scribd http://www.scribd.com TutorialsPoint http://www.tutorialspoint.com GitamUniversity http://www.gitam.edu WorcesterPolytechnicInstitute http://www.wpi.edu

Вам также может понравиться