Scheduling (computing)

From WikiMD's Food, Medicine & Wellness Encyclopedia

Thread pool
Simplified Structure of the Linux Kernel

Scheduling in computing refers to the method by which work is assigned to resources that complete the work. The work could be virtual computation elements such as threads, processes or data flows, which are in turn managed by the scheduler. The scheduler is a type of system software that controls the execution of processes by the CPU.

Overview[edit | edit source]

In computing, scheduling is the action of assigning processes to run on available CPU cores or other resources. This is a fundamental function of an operating system (OS). The main goals of scheduling are to maximize the utilization of resources, ensure fairness among processes, and minimize response times for tasks.

Types of Schedulers[edit | edit source]

There are several types of schedulers used in computing:

  • Long-term scheduler: Also known as the job scheduler, it controls the admission of new jobs or processes into the system. It decides which jobs or processes are to be admitted to the ready queue (the queue of processes that are ready to run).
  • Short-term scheduler: Also known as the CPU scheduler, it decides which of the ready, in-memory processes are to be executed (allocated a CPU) next following a certain algorithm. The short-term scheduler is invoked very frequently and needs to be very fast.
  • Mid-term scheduler: Also known as the swapper, it temporarily removes processes from main memory and places them on disk (swapping out) and vice versa (swapping in). This is part of the memory management policy of an OS.

Scheduling Algorithms[edit | edit source]

Several scheduling algorithms are used to determine which process runs at any given time:

  • First-Come, First-Served (FCFS): Processes are dispatched according to their arrival time in the queue.
  • Shortest Job First (SJF): Processes with the shortest execution time are chosen next. This algorithm can be preemptive or non-preemptive.
  • Round Robin (RR): Each process is assigned a fixed time in a cyclic manner. It is designed to ensure fairness among processes.
  • Priority Scheduling: Processes are executed based on priority. Higher priority processes are executed before lower priority ones. This can also be preemptive or non-preemptive.
  • Multilevel Queue Scheduling: This algorithm partitions the ready queue into several separate queues, each having its own scheduling algorithm.

Challenges in Scheduling[edit | edit source]

Scheduling in computing faces several challenges:

  • Concurrency: Managing the execution of concurrent processes in a way that maximizes CPU utilization while ensuring process isolation and synchronization.
  • Resource Allocation: Efficiently allocating limited resources among competing processes.
  • Load Balancing: Distributing work evenly across computing resources to avoid overloading any single resource.
  • Real-Time Scheduling: Meeting the strict timing constraints of real-time applications.

Conclusion[edit | edit source]

Scheduling is a critical component of operating systems and computing environments, ensuring efficient and fair resource utilization. As computing systems evolve, scheduling algorithms and strategies continue to adapt to meet the demands of increasingly complex and dynamic computing environments.

This article is a stub.

Help WikiMD grow by registering to expand it.
Editing is available only to registered and verified users.
About WikiMD: A comprehensive, free health & wellness encyclopedia.

Wiki.png

Navigation: Wellness - Encyclopedia - Health topics - Disease Index‏‎ - Drugs - World Directory - Gray's Anatomy - Keto diet - Recipes

Search WikiMD


Ad.Tired of being Overweight? Try W8MD's physician weight loss program.
Semaglutide (Ozempic / Wegovy and Tirzepatide (Mounjaro) available.
Advertise on WikiMD

WikiMD is not a substitute for professional medical advice. See full disclaimer.

Credits:Most images are courtesy of Wikimedia commons, and templates Wikipedia, licensed under CC BY SA or similar.


Contributors: Prab R. Tumpati, MD