Design an Efficent Scheduler

The electronic forum deals with the topics related to analog and digital circuits and systems (i.e. ASIC, FPGA, DSPs, Microcontroller, Single/Multi Processors etc) and their programming such as HDL, C/C++, etc.
Forum rules
The electronic forum deals with the topics related to analog and digital circuits and systems (i.e. ASIC, FPGA, DSPs, Microcontroller, Single/Multi Processors, PCBs etc) and their programming such as HDL, C/C++, etc.

Re: Design an Efficent Scheduler

Unread postby junaid05 » Wed Apr 01, 2015 10:46 pm

JUNAID SARWAR CMS No. 7316
Scheduler
The scheduler is the component of the operating system that is responsible for deciding whether the currently running process should continue running and, if not, which process should run next. There are four events that may occur where the scheduler needs to step in and make this decision:
1. The current process goes from the running to the waiting state because it issues an I/O request or some operating system request that cannot be satisfied immediately.
2. The current process terminates.
3. A timer interrupt causes the scheduler to run and decide that a process has run for its allotted interval of time and it is time to move it from the running to the ready state.
4. An I/O operation is complete for a process that requested it and the process now moves from the waiting to the ready state. The scheduler may then decide to preempt the currently-running process and move this newly-ready process into the running state.
A scheduler is a preemptive scheduler if it has the ability to get invoked by an interrupt and move a process out of a running state to let another process run. The last two events in the above list may cause this to happen. If a scheduler cannot take the CPU away from a process then it is a cooperative, or non-preemptive scheduler.
Long-term scheduler
The long-term, or admission, scheduler decides which jobs or processes are to be admitted to the ready queue; that is, when an attempt is made to execute a program, its admission to the set of currently executing processes is either authorized or delayed by the long-term scheduler. Thus, this scheduler dictates what processes are to run on a system, and the degree of concurrency to be supported at any one time
Mid-term scheduler
The mid-term scheduler temporarily removes processes from main memory and places them on secondary memory or vice versa. This is commonly referred to as "swapping out" or "swapping in". The mid-term scheduler may decide to swap out a process which has not been active for some time, or a process which has a low priority, or a process which is page faulting frequently, or a process which is taking up a large amount of memory in order to free up main memory for other processes, swapping the process back in later when more memory is available, or when the process has been unblocked and is no longer waiting for a resource.
Short-term scheduler

The short-term scheduler decides which of the ready, in-memory processes are to be executed next following a clock interrupt, an IO interrupt, an operating system call or another form of signal.
User avatar
junaid05
 
Posts: 2
Joined: Wed Apr 01, 2015 9:24 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Design an Efficent Scheduler

Unread postby M.irfan Malik » Wed Apr 01, 2015 11:06 pm

M.Irfan Malik CMS:7481
Scheduling is a process used to allocate valuable resources of computer e.g. time needed by processer, memory & bandwidth, spider's web, flow of data & applications that need them during run time. Scheduling is done for the guarantee of distribution of equal resources to balance the system load by giving some priorities according to some rules. Because of this our computer system is able to attend all requests and to achieve a good service of quality.
The objective of Scheduling in Operating System is to maximize the utilization of CPU by running some process at all times with the help of multiprogramming. While operation the processer migrates among various scheduling queues and the selection process of these queues is done with the help of scheduler. Scheduling affects the system performance by deciding which process will progress and which will delay.
Types of Scheduling in operating systems:
Long-term Scheduling:
Whenever a new process is created long term scheduling is performed and the new process is put into the ready queue but there is an overhead on the operating system “if the number of ready processes is ready queue becomes very” to maintain these long lists, by dispatching increase. Long term scheduling manages it by allowing limited number of ready queues and also decides the programs to be admitted into the system for processing.
Medium-term Scheduling:
It decides which processes are to be postponed and which are to be resumed during run time.
Short-term Scheduling:
Short term scheduling decides the distribution of CPU resources to the ready process and for how long these resources can be used.it is also known as dispatching.
Scheduling Criteria:
This is also known as scheduling methodology. Different scheduling algorithm have different properties and to compare these algorithm following criteria is used.
CPU Utilization, Throughput, Turnaround time, Waiting time, Response time and
Fairness:
This means that each process that are to be executed have a fair share of CPU.
Non-preemptive Scheduling:
In this scheduling once a process start then it stops only if it terminates or block itself or by request by operating system.
Preemptive Scheduling:
In this mode, by the operating system currently running process may be moved to the ready State or interrupted.
User avatar
M.irfan Malik
 
Posts: 3
Joined: Wed Apr 01, 2015 9:33 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Design an Efficent Scheduler

Unread postby Mubashara Tariq » Thu Apr 02, 2015 5:48 am

Scheduling
The behavior of system are controlled by scheduling policies in embedded systems, these behaviors shows true parallelism of hardware and concurrency of software. These policies hold the order for the execution of tasks. In multi user environment these services may include quality assurance. Or maybe these policies simply include, user friendly graphical interface. Run time scheduling is that all task instances are completed under obsolete limitation.
Many operating systems use combinations of the scheduling algorithms because there is no universal accurate scheduling algorithms.So a programmer should consider which algorithm is performing the best, whenever designing an operating system.There are different properties for different CPU scheduling algorithm.
There are three major types of scheduling:
Long term scheduling: Long term scheduling tells us about the programs which are permitted to the system for completion and when, and also which ones are to be departed. The scheduler indicates the number of processes which have to be run on the system and how much the agreements are to be supported at a given time though too many processes are to be carried out simultaneously
Medium term scheduling: Medium term scheduling tells us that which programs are to be hanged and which are to be continued. The scheduler removes the processes from the major memory and insets it into a secondary one which probably can be a hard disk.
Short term scheduling: Short term scheduling tells us about the time in which ready processes could have CPU resources. It is also called dispatcher. Short time scheduling is generated whenever an event occurs that causes interruption in the prevailing running process.
User avatar
Mubashara Tariq
 
Posts: 1
Joined: Thu Apr 02, 2015 5:40 am
Has thanked: 0 time
Been thanked: 0 time

Re: Design an Efficent Scheduler

Unread postby umar » Thu Apr 02, 2015 8:27 am

Muhammad Umar Iftikhar, CMS # 7347
THE TASK SCHEDULER :
The Task Scheduler schedules and coordinates tasks at run-time. The Task Scheduler manages the details that are related to efficiently scheduling tasks on computers that have multiple computing resources.
The Task Scheduler can be used to execute tasks such as starting an application, sending an email message, or showing a message box.Task Scheduler was introduced with Windows Vista and included in Windows Server 2008 as well. The Task Scheduler user interface is now based on Management Console. In addition to running tasks on scheduled times or specified intervals, it also supports calendar and event-based triggers, such as starting a task when a particular event is logged to the event log or when a combination of events has occurred. Also, several tasks that are triggered by the same event can be configured to run either simultaneously or in a pre-determined chained sequence of a series of actions, instead of having to create multiple scheduled tasks. Tasks can also be configured to run based on system status such as being idle for a pre-configured amount of time, on start-up or only during or for a specified time. Tasks can also be delayed for a specified time after the triggering event has occurred, or repeat until some other event occurs. Actions that need to be done if a task fails can also be configured. The actions that can be taken in response to triggers, both event-based as well as time-based, not only include launching applications but also take a number of custom actions. Task Scheduler includes a number of actions built-in, spanning a number of applications; including send an e-mail, show a message box when it is triggered.
User avatar
umar
 
Posts: 2
Joined: Wed Apr 01, 2015 9:19 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Design an Efficent Scheduler

Unread postby Ali Hassan Khan » Thu Apr 02, 2015 8:37 am

Name : Ali Hassan Khan CMS : 7551
Scheduler
Scheduling is a technique of managing or executing processes equally at the same time. As we know that modern systems perform multitasking and multiplexing for which scheduling is required. A scheduler can execute many tasks at a single time. It can share the resources of the system equally to every process. It can share equal time of the CPU to every process. When the CPU is loaded with many processes to be executed than it is the scheduler which properly manages all the process equally and gives each process its needed time/resource for executing by the CPU. Scheduling is required in most modern systems nowadays especially in the industries where embedded systems are used for controlling machines which requires simultaneous sharing of resources of the processing unit and also the processes should complete in the required time so that the system should be stable. Most often there is also conflict between processes to be executed where the decision is to be taken that which process should be executed first or quickly, So the scheduler decides this at priority bases. Priority can be memory based or user priority or run time based. The processes are established into queues and every queue gets equal share of the resources of CPU. These queues are given equal resources by many methods either by minimizing each queue’s share or limiting the number of running processes per user. In short, the scheduler manages all the processes of a systems in a systematic and well-defined way and guarantee the proper working of the processing unit of the system.
User avatar
Ali Hassan Khan
 
Posts: 2
Joined: Thu Apr 02, 2015 7:47 am
Has thanked: 0 time
Been thanked: 0 time

PreviousNext

Return to Electronics

Who is online

Users browsing this forum: No registered users and 1 guest

cron