0% found this document useful (0 votes)
8 views1 page

PP 3

Uploaded by

Mohd Faizan Alam
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views1 page

PP 3

Uploaded by

Mohd Faizan Alam
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

Title Goes Here (Edit This)

Let's discuss **"Process Scheduling in Operating Systems"**.

---

### **Process Scheduling in Operating Systems**

Process scheduling is the method by which the operating system decides which process gets to u

### **Key Concepts**:

1. **Process**: A program in execution. Each process has a state (e.g., running, waiting, ready).

2. **Scheduler**: The OS component responsible for deciding which process runs next.

3. **CPU Scheduling**: The process of assigning CPU time to processes, based on scheduling a

### **Types of Scheduling**:

1. **Preemptive Scheduling**:
- The scheduler can interrupt a running process to allocate CPU time to another process.
- **Example**: Round Robin, Shortest Job First (SJF).

2. **Non-preemptive Scheduling**:
- A running process is not interrupted and runs until it finishes or voluntarily releases the CPU.
- **Example**: First-Come, First-Served (FCFS).

### **Common Scheduling Algorithms**:

1. **First-Come, First-Served (FCFS)**:


- Processes are executed in the order they arrive.
- **Pros**: Simple to implement.
- **Cons**: Can cause long waiting times for short processes (convoy effect).

2. **Round Robin (RR)**:


- Each process gets a fixed time slice (quantum) to execute. If it doesn’t finish, it is preempted a
- **Pros**: Fair, as each process gets an equal share of CPU time.
- **Cons**: Can lead to high turnaround time if the time slice is too large or small.

3. **Shortest Job First (SJF)**:


- The process with the smallest execution time is scheduled next.
- **Pros**: Minimizes average waiting time.
- **Cons**: Difficult to predict burst time.

4. **Priority Scheduling**:
- Processes are assigned priorities. The process with the highest priority gets the CPU.
- **Pros**: Suitable for systems with tasks of varying importance.
- **Cons**: Can lead to starvation (low-priority processes may never get executed).

You might also like