1 Overview Assignment 10: hints  Deadlocks & Scheduling Assignment 9: solution  Scheduling.

Slides:



Advertisements
Similar presentations
Uniprocessor Scheduling Chapter 9 Operating Systems: Internals and Design Principles, 6/E William Stallings Patricia Roy Manatee Community College, Venice,
Advertisements

Scheduling Criteria CPU utilization – keep the CPU as busy as possible (from 0% to 100%) Throughput – # of processes that complete their execution per.
CPU Scheduling Tanenbaum Ch 2.4 Silberchatz and Galvin Ch 5.
CS 149: Operating Systems February 3 Class Meeting
OS, , Part II CPU Scheduling Department of Computer Engineering, PSUWannarat Suntiamorntut.
Overview Assignment 8: hints Assignment 7: solution Deadlocks
1 Christmas special - Overview Assignment 9: hints  Scheduling Assignment 8: solution  Deadlocks.
Silberschatz, Galvin and Gagne  2002 Modified for CSCI 399, Royden, Operating System Concepts Operating Systems Lecture 17 Scheduling III.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition Chapter 5: CPU Scheduling.
Operating Systems Chapter 6
Operating System Concepts with Java – 7 th Edition, Nov 15, 2006 Silberschatz, Galvin and Gagne ©2007 Processes and Their Scheduling.
Chapter 3: CPU Scheduling
CS 311 – Lecture 23 Outline Kernel – Process subsystem Process scheduling Scheduling algorithms User mode and kernel mode Lecture 231CS Operating.
02/06/2008CSCI 315 Operating Systems Design1 CPU Scheduling Algorithms Notice: The slides for this lecture have been largely based on those accompanying.
Project 2 – solution code
Avishai Wool lecture Priority Scheduling Idea: Jobs are assigned priorities. Always, the job with the highest priority runs. Note: All scheduling.
Cs238 CPU Scheduling Dr. Alan R. Davis. CPU Scheduling The objective of multiprogramming is to have some process running at all times, to maximize CPU.
02/11/2004CSCI 315 Operating Systems Design1 CPU Scheduling Algorithms Notice: The slides for this lecture have been largely based on those accompanying.
Threads & Scheduling What are threads?
Silberschatz, Galvin and Gagne  Operating System Concepts Chapter 6: CPU Scheduling Basic Concepts Scheduling Criteria Scheduling Algorithms.
Chapter 6: CPU Scheduling
1 Process States (1) Possible process states –running –blocked –ready Transitions between states shown.
Chapter 5: CPU Scheduling. 5.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts – 7 th Edition, Feb 2, 2005 Scheduler What is the job of.
1 Scheduling Processes. 2 Processes Each process has state, that includes its text and data, procedure call stack, etc. This state resides in memory.
Chapter 5 – CPU Scheduling (Pgs 183 – 218). CPU Scheduling  Goal: To get as much done as possible  How: By never letting the CPU sit "idle" and not.
Scheduling Basic scheduling policies, for OS schedulers (threads, tasks, processes) or thread library schedulers Review of Context Switching overheads.
Scheduling Strategies Operating Systems Spring 2004 Class #10.
CPU Scheduling CSCI 444/544 Operating Systems Fall 2008.
CPU Scheduling Basic Concepts Scheduling Criteria Scheduling Algorithms Thread Scheduling Multiple-Processor Scheduling Operating Systems Examples Algorithm.
Cpr E 308 Spring 2004 Real-time Scheduling Provide time guarantees Upper bound on response times –Programmer’s job! –Every level of the system Soft versus.
CS140 Project 1: Threads Slides by Kiyoshi Shikuma.
Discussion Week 2 TA: Kyle Dewey. Overview Concurrency Process level Thread level MIPS - switch.s Project #1.
CS333 Intro to Operating Systems Jonathan Walpole.
Operating Systems CMPSC 473 Processes (contd.) September 01, Lecture 4 Instructor: Bhuvan Urgaonkar.
1 CPU Scheduling Basic Concepts Scheduling Criteria Scheduling Algorithms Multiple-Processor Scheduling Real-Time Scheduling.
1 Critical Section Problem CIS 450 Winter 2003 Professor Jinhua Guo.
CPU Scheduling Operating Systems CS 550. Last Time Deadlock Detection and Recovery Methods to handle deadlock – Ignore it! – Detect and Recover – Avoidance.
lecture 5: CPU Scheduling
CPU SCHEDULING.
Chapter 6: CPU Scheduling
Operating Systems Design (CS 423)
Copyright ©: Nahrstedt, Angrave, Abdelzaher
Processes and Threads Processes and their scheduling
Networks and Operating Systems: Exercise Session 2
April 6, 2001 Gary Kimura Lecture #6 April 6, 2001
Chapter 2.2 : Process Scheduling
Scheduling (Priority Based)
CPU Scheduling.
Chapter 6: CPU Scheduling
ICS 143 Principles of Operating Systems
CPU Scheduling Basic Concepts Scheduling Criteria
CPU Scheduling G.Anuradha
Chapter 6: CPU Scheduling
Chapter 5: CPU Scheduling
Operating System Concepts
Chapter 9 Uniprocessor Scheduling
Outline Scheduling algorithms Multi-processor scheduling
Chapter 6: CPU Scheduling
Lecture 2 Part 3 CPU Scheduling
February 5, 2004 Adrienne Noble
Outline Announcement Process Scheduling– continued
Operating System , Fall 2000 EA101 W 9:00-10:00 F 9:00-11:00
Shortest-Job-First (SJR) Scheduling
Concurrency and Threading: CPU Scheduling
Scheduling 21 May 2019.
CS703 – Advanced Operating Systems
CSE 153 Design of Operating Systems Winter 2019
CPU Scheduling.
CPU Scheduling: Basic Concepts
Chapter 5: CPU Scheduling
Presentation transcript:

1 Overview Assignment 10: hints  Deadlocks & Scheduling Assignment 9: solution  Scheduling

2 A10 Ex1 – Deadlocks Give a real-life example of deadlock. Is it possible to have a deadlock with one process/thread only? Hint: think of types of locks

3 A10 Ex2 – Synchronization Primitives Assumption: OS with only a yield() system call Your task: give a pseudo-code implementation of lock, unlock, wait, and notify Hint: keep track of the threads and their state

4 A10 Ex3 – Scheduling Implement a scheduler simulator  Input: comma separated list of [time, priority]  Output: average turnaround and response time for First come first served Shortest job first Longest response ratio Highest priority first Round Robin (Hood)

5 Overview Assignment 10: hints  Deadlocks & Scheduling Assignment 9: solution  Scheduling

6 A9 Ex1 - Scheduling 5 jobs arrive at the same time Process turnaround time: the time elapsed from the submission of the job until the job was done JobTimePriorityRRPrioFCFSSJF A B C D E Avg

7 A9 Ex2 - Multithreading Difference between kernel threads and user-space threads User level threads:  Managed by an application (customizable)  No preemption, cooperative  Only one CPU Kernel threads:  Managed by kernel  User-space  Kernel-space  more expensive

8 A9 Ex3 - Processes Process: has its own address space Thread: shares the address space with some other thread/s Context switch: Threads: save PC, SP, FP, regs Processes: save PC, SP, FP, regs, PT Coroutines: save PC, SP, FP