Scheduling/Processor Management Flashcards

1
Q

(FCFS) First Come First Served Scheduling + pros and cons

A

allocates the processor in order of the process creation time

Pros:
No unnecessary switching between processes
Every process will eventually be given some processing time

Cons:
The average waiting time is usually too long

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Round robin scheduling + pros and cons

A

Similar to FCFS except each process only has a pre-defined amount of time (called the time quantum) that they can occupy the processor for, after arriving at the processor the process execution will either be interrupted and it will be placed back at the end of the (circular) queue or it will finish its execution before the time quantum has expired.

New processes get priority ahead of processes that have already been given execution time

Pros:
Distributes resources in a fair manner
A short process can pass through in a relatively quick manner

Cons:
Long average waiting time when a process elapses multiple time quanta
Performance is heavily reliant on the defined time quantum, a long time quantum will mean it acts exactly like FCFS
(
The time quantum should be long comparative to the time taken for a context-switch
The majority of processes should complete within one time quantum
)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Shortest process next scheduling + pros and cons

A

Schedules processes in order of their predicted execution time, has two variants (pre-emptive and non-pre-emptive)
Pre-emptive - processes can be interrupted before they have finished execution
Non-pre-emptive - processes cannot be interrupted before they have finished execution

Pros:
Has the minimum average waiting time (pre-emptive)

Cons:
Execution time has to be estimated
Longer processes may have to wait a very long time before they are executed

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is an interactive, normal and batch process

A

Interactive - a process with lots of IO
Normal - e.g a system service
Batch - a process without any IO

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Multi-level queues pros and cons

A

Pros:
Complex, can accommodate a range of different performance objectives

Cons:
Complex, difficult to calibrate

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Approaches to multi-processor scheduling - Common ready queue

A

When a processor becomes available, it will select a process from a common shared queue

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Approaches to multi-processor scheduling - Private queues

A

When a processor becomes available, it will choose a new process from its own private queue

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Two methods to improve the performance of multi-processor scheduling

A

Load balancing - balancing processes across the processors, using common ready queues naturally enforces load balancing as each processor takes processes from the same queue

Processor affinity - when you keep a process running on the same processor to keep the cache warm, soft affinity is when you only move processes when there is a good reason. Private queues automatically enforce processor affinity

Each method counteracts the other

How well did you know this?
1
Not at all
2
3
4
5
Perfectly