G22.3250-001 Robert Grimm New York University Lottery Scheduling.

Slides:



Advertisements
Similar presentations
Scheduling Introduction to Scheduling
Advertisements

LOTTERY SCHEDULING: FLEXIBLE PROPORTIONAL-SHARE RESOURCE MANAGEMENT
Embedded System Lab. 1 Embedded system Lab.
Allocation of Frames Each process needs minimum number of pages
CPU Scheduling Section 2.5.
Project 2 – solution code
CS 3013 & CS 502 Summer 2006 Scheduling1 The art and science of allocating the CPU and other resources to processes.
Chapter 6: CPU Scheduling. 5.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts – 7 th Edition, Feb 2, 2005 Chapter 6: CPU Scheduling Basic.
Tao Yang, UCSB CS 240B’03 Unix Scheduling Multilevel feedback queues –128 priority queues (value: 0-127) –Round Robin per priority queue Every scheduling.
1 Pertemuan 8 Penjadwalan (lanjutan) Matakuliah: T0316/sistem Operasi Tahun: 2005 Versi/Revisi: 5.
Supporting Time-sensitive Application on a Commodity OS Ashvin Goel, Luca Abeni, Charles Krasic, Jim Snow, Jonathan Walpole Presented by Wen Sun Some Slides.
RTOS Scheduling – II EE202A (Fall 2001): Lecture #5.
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.
Supporting Time-sensitive Application on a Commodity OS By Ashvin Goel, Luca Abeni, Charles Krasic, Jim Snow, Jonathan Walpole Presenter: Shuping Tien.
Scheduling CS623, Lecture 7 3/9/2004 © Joel Wein, updated by T. Suel.
Chapter 11 Operating Systems
5: CPU-Scheduling1 Jerry Breecher OPERATING SYSTEMS SCHEDULING.
Wk 2 – Scheduling 1 CS502 Spring 2006 Scheduling The art and science of allocating the CPU and other resources to processes.
U NIVERSITY OF M ASSACHUSETTS, A MHERST Department of Computer Science Emery Berger University of Massachusetts, Amherst Operating Systems CMPSCI 377 Lecture.
Dreams in a Nutshell Steven Sommer Microsoft Research Institute Department of Computing Macquarie University.
Chapter 2 Processes and Threads Scheduling Classical Problems.
Copyright © 2006 by The McGraw-Hill Companies, Inc. All rights reserved. McGraw-Hill Technology Education Lecture 5 Operating Systems.
OPERATING SYSTEMS CPU SCHEDULING.  Introduction to CPU scheduling Introduction to CPU scheduling  Dispatcher Dispatcher  Terms used in CPU scheduling.
Lottery Scheduling: Flexible Proportional-Share Resource Management Sim YounSeok C. A. Waldspurger and W. E. Weihl.
University of Michigan Electrical Engineering and Computer Science 1 Dynamic Acceleration of Multithreaded Program Critical Paths in Near-Threshold Systems.
1 Scheduling Processes. 2 Processes Each process has state, that includes its text and data, procedure call stack, etc. This state resides in memory.
Outline for Today Objectives: Linux scheduler Lottery scheduling
Budget-based Control for Interactive Services with Partial Execution 1 Yuxiong He, Zihao Ye, Qiang Fu, Sameh Elnikety Microsoft Research.
Chapter 3 System Performance and Models. 2 Systems and Models The concept of modeling in the study of the dynamic behavior of simple system is be able.
Operating System Concepts Chapter One: Introduction What is an operating system? Simple Batch Systems Multiprogramming Systems Time-Sharing Systems Personal-Computer.
111 © 2002, Cisco Systems, Inc. All rights reserved.
Event-Based Hybrid Consistency Framework (EBHCF) for Distributed Annotation Records Ahmet Fatih Mustacoglu Advisor: Prof. Geoffrey.
1 Scheduling The part of the OS that makes the choice of which process to run next is called the scheduler and the algorithm it uses is called the scheduling.
1 Coscheduling in Clusters: Is it a Viable Alternative? Gyu Sang Choi, Jin-Ha Kim, Deniz Ersoz, Andy B. Yoo, Chita R. Das Presented by: Richard Huang.
OPERATING SYSTEMS CS 3530 Summer 2014 Systems with Multi-programming Chapter 4.
15.1 Threads and Multi- threading Understanding threads and multi-threading In general, modern computers perform one task at a time It is often.
Energy-Aware Resource Adaptation in Tessellation OS 3. Space-time Partitioning and Two-level Scheduling David Chou, Gage Eads Par Lab, CS Division, UC.
Review for Quiz-2 Applied Operating System Concepts Chap.s 1,2,6,7 - ECE3055b, Spring 2005.
Lecture 8: Lottery Scheduling 1. Class Plan Lottery scheduling: – Motivation – Solution proposed Group work and answers on: – Implementation issues: challenges?
CS333 Intro to Operating Systems Jonathan Walpole.
1.  System Characteristics  Features of Real-Time Systems  Implementing Real-Time Operating Systems  Real-Time CPU Scheduling  An Example: VxWorks5.x.
Operating Systems Scheduling. Scheduling Short term scheduler (CPU Scheduler) –Whenever the CPU becomes idle, a process must be selected for execution.
Advanced Operating Systems (CS 202) Scheduling Jan, 20, 2016.
Stride Scheduling: Deterministic Proportional-Share Resource Management Carl A. Waldspurger, William E. Weihl MIT Laboratory for Computer Science Presenter:
Lecture 12 Scheduling Models for Computer Networks Dr. Adil Yousif.
Scheduling.
CPU Scheduling Scheduling processes (or kernel-level threads) onto the cpu is one of the most important OS functions. The cpu is an expensive resource.
REAL-TIME OPERATING SYSTEMS
Chapter 6: CPU Scheduling (Cont’d)
Outline for Today Objectives: Announcements Interrupts (continued)
Advanced Operating Systems (CS 202) Scheduling (2)
Unit OS9: Real-Time and Embedded Systems
Chapter 2 Scheduling.
Chapter 8 – Processor Scheduling
Lottery Scheduling: Flexible Proportional-Share Resource Management
Lottery Scheduling Ish Baid.
CS 3204 Operating Systems Lecture 14 Godmar Back.
Operating Systems : Overview
CS140 – Operating Systems Midterm Review
Jason Neih and Monica.S.Lam
Operating Systems : Overview
Operating systems Process scheduling.
CPU SCHEDULING.
Operating Systems : Overview
Operating Systems : Overview
Operating Systems : Overview
Operating Systems : Overview
Supporting Time-Sensitive Applications on a Commodity OS
CSE 542: Operating Systems
Don Porter Portions courtesy Emmett Witchel
Presentation transcript:

G Robert Grimm New York University Lottery Scheduling

Altogether Now: The Three Questions  What is the problem?  What is new or different?  What are the contributions and limitations?

Motivation  Scheduling of scarce computer resources (e.g., CPU)  Has major impact on throughput and response time  Should be fair (scientific applications)  But also needs to adjust rapidly (interactive applications)  Priority-based schemes  Do not provide encapsulation, modularity  Rely on ad-hoc assignment of priorities  Are poorly understood

Enter Lottery Scheduling  Provides a randomized mechanism  Not suitable for real-time systems  Provides control over relative execution rates  Can be implemented efficiently  Supports modular resource management

The Basic Ingredients  Tickets  Abstract, relative, and uniform resource rights  Lotteries  Probabilistically fair selection of next resource holder  Throughput proportional to client’s ticket allocation  Binomial distribution, accuracy improves with  Average response time inversely proportional to client’s ticket allocation

Modular Resource Management  Ticket transfers  Useful for RPC-based systems  Avoid priority inversion problem  Ticket inflation  Provides alternative to transfers (no communication!)  Needs to be avoided/contained in general  Ticket currencies  Support flexible naming, sharing, protecting of access rights  Compensation tickets  Make up for underutilization

Implementation  Integrated into Mach 3.0  Supports ticket transfers, inflation, currencies, compensation tickets  Relies on fast pseudo-random number generator  Generator of choice is subject to discussion  Communications of the ACM, 36(7): , July 1993  Selects winning thread from list of tickets: O(n)  Ordered by relative amount  Possible optimization: Tree-based O(log n)

Ticket Currencies  Tickets only active when thread is ready: Active amount/currency  (De)activation propagates up/down the tree on change to/from zero  Currency’s value equals to sum of backing tickets  Ticket’s value equals to fraction of currency’s value

Experimental Evaluation

Fairness  Two tasks executing the Dhrystone benchmark  Varying ticket allocations Observed ratio over 60 seconds 8 sec time windows, 2:1 alloc

Flexible Control  Three Monte-Carlo tasks  Dynamic ticket inflation proportional to (relative error) 2

Client-Server Computation  Three clients querying text-search server  8:3:1 ticket allocation for clients  None for server

Multimedia Applications  Three video viewers  3:2:1 initial allocation, changed to 3:1:2 at arrow  Real ratios: 1.92:1.50:1 before, 1.92:1:1.53 after  Why?

Load Insulation  5 tasks executing Dhrystone  Two currencies A and B  Funded equally  Task group A  1:2  Task group B  1:2, then 1:2:3

Lock Scheduling  Lottery-scheduled mutex has  Mutex currency  Inheritance ticket  Waiting threads fund mutex currency  When done, mutex holder conducts lottery to determine next holder  Passes on inheritance ticket

Lock Scheduling in Practice  n=8 threads competing for single mutex  Each thread  Acquires mutex  Holds it for h=50 milliseconds  Releases mutex  Computes for t=50 milliseconds  Threads divided into two groups  2:1 ticket allocation  1:2.11 waiting times  1.80:1 mutex acquisition rates

What Do You Think?