Dave Archer - CS533 - Spring 2006 1 On the Duality of Operating System Structures Hugh C. Lauer, Roger M. Needham.

Slides:



Advertisements
Similar presentations
DISTRIBUTED COMPUTING PARADIGMS
Advertisements

CS 443 Advanced OS Fabián E. Bustamante, Spring 2005 Cooperative Task Management without Manual Stack Management or Event-driven programming is not the.
Remote Procedure Call (RPC)
Remote Procedure Call Design issues Implementation RPC programming
Extensibility, Safety and Performance in the SPIN Operating System Presented by Allen Kerr.
1 SEDA: An Architecture for Well- Conditioned, Scalable Internet Services Matt Welsh, David Culler, and Eric Brewer Computer Science Division University.
OS Organization 1 CS502 Spring 2006 A Note on Operating System Organization CS-502 – Spring 2006.
Concurrency, Thread and Event CS6410 Sept 6, 2011 Ji-Yong Shin.
Hugh Lauer Xerox Corporation Roger Needham Cambridge University Presented by Vidhya Priyadharshnee Palaniswamy Gnanam Spring 2011.
1 On the Duality of Operating System Structures by Hugh C. Lauer, Xerox Corporation and Roger M. Needham, Cambridge University Presented by Scott Fletcher.
CS533 Concepts of Operating Systems Class 6 The Duality of Threads and Events.
Concurrency CS 510: Programming Languages David Walker.
Active Messages: a Mechanism for Integrated Communication and Computation von Eicken et. al. Brian Kazian CS258 Spring 2008.
Chapter 11: Distributed Processing Parallel programming Principles of parallel programming languages Concurrent execution –Programming constructs –Guarded.
“Why Events are a Bad Idea (For high-concurrency servers)” Paper by Rob von Behren, Jeremy Condit and Eric Brewer, May 2003 Presentation by Loren Davis,
1 On the Duality of Operating System Structures Hugh Lauer, Xerox Roger Needham, Cambridge University Oct 1978, reprinted April 1979 Presented by David.
Concurrency, Threads, and Events Robbert van Renesse.
Real-Time Kernels and Operating Systems. Operating System: Software that coordinates multiple tasks in processor, including peripheral interfacing Types.
On the Duality of Operating System Structures Hugh Lauer Xerox Corporation Roger Needham Cambridge University Presented by Yahia Mahmoud.
Informationsteknologi Tuesday, October 9, 2007Computer Systems/Operating Systems - Class 141 Today’s class Scheduling.
User-Level Interprocess Communication for Shared Memory Multiprocessors Brian N. Bershad, Thomas E. Anderson, Edward D. Lazowska, and Henry M. Levy Presented.
PRASHANTHI NARAYAN NETTEM.
On the Duality of Operating System Structures Hugh C. Lauer Xerox Corporation Roger M. Needham Cambridge University Presented By: Ashwini Kulkarni.
SEDA: An Architecture for Well-Conditioned, Scalable Internet Services
SEDA – Staged Event-Driven Architecture
Basics of Operating Systems March 4, 2001 Adapted from Operating Systems Lecture Notes, Copyright 1997 Martin C. Rinard.
1 Chapter 9 Spaces with LINDA. 2 Linda Linda is an experimental programming concept unlike ADA or Occam which are fully developed production-quality languages.
Operating Systems ECE344 Ashvin Goel ECE University of Toronto Threads and Processes.
CS 153 Design of Operating Systems Spring 2015 Lecture 11: Scheduling & Deadlock.
On the Duality of Operating System Structures 1. Hugh C. Lauer Xerox Corporation Palo Alto, Californi a Roger M. Needham Cambridge University Cambridge,
SEDA: An Architecture for Well-Conditioned, Scalable Internet Services Presented by Changdae Kim and Jaeung Han OFFENCE.
Chapter 101 Multiprocessor and Real- Time Scheduling Chapter 10.
1 Multiprocessor and Real-Time Scheduling Chapter 10 Real-Time scheduling will be covered in SYSC3303.
1 Concurrency Architecture Types Tasks Synchronization –Semaphores –Monitors –Message Passing Concurrency in Ada Java Threads.
 Remote Procedure Call (RPC) is a high-level model for client-sever communication.  It provides the programmers with a familiar mechanism for building.
CS533 - Concepts of Operating Systems 1 On The Duality of Operating System Structures Hugh Lauer, Xerox Roger Needham, Cambridge University 1979 Presented.
CS-3013 & CS-502, Summer 2006 Operating System Organization1 A Brief Discussion on Operating System Organization.
ICS 313: Programming Language Theory Chapter 13: Concurrency.
CS533 - Concepts of Operating Systems 1 The Mach System Presented by Catherine Vilhauer.
ON THE DUALITY OF OPERATING SYSTEM STRUCTURES Hugh C. Lauer and Roger M. Needham Presented by: Ali R. Butt (adapted from many slides available online and.
Processes CSCI 4534 Chapter 4. Introduction Early computer systems allowed one program to be executed at a time –The program had complete control of the.
Computer Architecture and Operating Systems CS 3230: Operating System Section Lecture OS-4 Process Communication Department of Computer Science and Software.
M. Accetta, R. Baron, W. Bolosky, D. Golub, R. Rashid, A. Tevanian, and M. Young MACH: A New Kernel Foundation for UNIX Development Presenter: Wei-Lwun.
Presenting: Why Events Are A “Bad” Idea ( for high-concurrency servers) Paper by: Behren, Condit and Brewer, 2003 Presented by: Rania Elnaggar 1/30/2008.
13-1 Chapter 13 Concurrency Topics Introduction Introduction to Subprogram-Level Concurrency Semaphores Monitors Message Passing Java Threads C# Threads.
CS533 – Spring Jeanie M. Schwenk Experiences and Processes and Monitors with Mesa What is Mesa? “Mesa is a strongly typed, block structured programming.
By: Rob von Behren, Jeremy Condit and Eric Brewer 2003 Presenter: Farnoosh MoshirFatemi Jan
1 Why Events Are A Bad Idea (for high-concurrency servers) By Rob von Behren, Jeremy Condit and Eric Brewer (May 2003) CS533 – Spring 2006 – DONG, QIN.
CS533 Concepts of Operating Systems Jonathan Walpole.
REVIEW OF “ON THE DUALITY OF OPERATING SYSTEM STRUCTURES” Paper by Hugh C. Lauer and Roger M. Needham Presentation by Erin Chapman.
Paper Review of Why Events Are A Bad Idea (for high-concurrency servers) Rob von Behren, Jeremy Condit and Eric Brewer By Anandhi Sundaram.
Channels. Models for Communications Synchronous communications – E.g. Telephone call Asynchronous communications – E.g. .
Big Picture Lab 4 Operating Systems C Andras Moritz
SEDA: An Architecture for Scalable, Well-Conditioned Internet Services
Chapter 3: Process Concept
The Mach System Sri Ramkrishna.
On the Duality of Operating System Structures
Concurrency, threads, and events
Presentation by Omar Abu-Azzah
Processes Overview: Process Concept Process Scheduling
CS533 Concepts of Operating Systems
B. N. Bershad, T. E. Anderson, E. D. Lazowska and H. M
On the Duality of Operating System Structures
Channels.
Hugh Lauer Xerox Corporation Roger Needham Cambridge University
Chapter 13: I/O Systems I/O Hardware Application I/O Interface
Channels.
Channels.
On the Duality of Operating System Structures
CS533 Concepts of Operating Systems Class 4
Presentation transcript:

Dave Archer - CS533 - Spring On the Duality of Operating System Structures Hugh C. Lauer, Roger M. Needham

Dave Archer - CS533 - Spring Duality Defined In Boolean algebra, if f(i 1, i 2, …) is true, dual f’ is also true, formed by swapping with +, i with ¬i In this paper, OS models are dual if –functionally equivalent –can be transformed into one another by interchanging primitives for process structure and cooperation a b a b =

Dave Archer - CS533 - Spring Motivation, Goals, Approach “Religious argument” over design slows innovation Characterize and classify operating systems designs –As message-oriented or procedure-oriented Most systems biased toward one of these –By process structure, synchronization, IPC –Using an “idealized” model for each Show duality, equivalence » short-circuit decision process “Empirical” = “Engineering” approach –Observation and generalization –Informal reasoning, empirical support –Conclusion Motive Goals Approach

Dave Archer - CS533 - Spring Welsh’s “Event-Driven Server” Request FSM Scheduler Disk Network Producer Consumer Event Queue Small number of threads Event queues Processing organized in “handlers” Server maintains continuation state

Dave Archer - CS533 - Spring Lauer’s Message-Oriented OS Producer Consumer Send Wait WaitReply SendReply Channel Ports Execution “Stream” Data “Stream” Typically real-time, e.g. Cisco Catalyst Small, static process count Explicit messages for communication –Passing (channels), queueing (ports), waiting for (MsgWait) data –Persistent bindings = complexity in creating processes Cooperation by encapsulating data/ptrs in messages Pre-emption driven by message arrival –When a higher priority process is waiting Little or no sharing of address spaces –Data or pointers passed in messages

Dave Archer - CS533 - Spring Welsh’s “Threaded Server” Request 1 Request 2 Request 3 Request 4 Request 5 Dispatcher Network Producer Consumer Protected, Shared Data Large, dynamic thread count Shared data structures Processing organized in threads Thread maintains state

Dave Archer - CS533 - Spring Procedure-oriented OS Typically time-sharing – most familiar OSs today Large, dynamic process count Explicit shared data system for communication –Passing (vars), queueing (monitors), waiting for (cond. vars) data –Persistent state = complexity in creating shared data Cooperation by encapsulating data in monitors Pre-emption driven by release of lock –When a higher priority process is waiting Little or no messaging –data or pointers passed in shared vars Producer Consumer Signal Wait

Dave Archer - CS533 - Spring Producer Consumer  - dual operations   Signal Wait Send Wait WaitReply SendReply         Channel Ports Execution “Stream” Data “Stream” Execution “Stream” Data “Stream”

Dave Archer - CS533 - Spring Mapping Duality Message-oriented system Processes Message Channel IDs Port numbers SndMsg…WaitReply –Immediate –Delayed SendReply WaitForMsg Main loop CASE arguments Send message Procedure-oriented system Monitors ENTRY procedure names Simple procedure names Procedure call/return –Simple –Fork/Join Return from Monitor Wait for lock, condition variable ENTRY procedures Signal condition variable

Dave Archer - CS533 - Spring Three Observations Two OS classes are duals –One can be directly mapped to the other by replacing primitives Logically identical to each other –almost down to syntax, if we work at it Equivalent in performance? –e.g. queue lengths, wait times, service rates

Dave Archer - CS533 - Spring What about Performance? Three areas to worry about –Execution of programs No difference – identical program semantics –Overhead of system calls Send = Call Wait = Leave Process switching, VM access identical Scheduling, dispatching, preemption equally efficient –Can use same disciplines –Queueing and waiting times for shared resources Identical, since scheduling disciplines are equal Hypothesis: Lifetime of similar computation is equal

Dave Archer - CS533 - Spring One Conclusion “In the message oriented model, objects move between processes in messages. In the procedure oriented model, processes move between objects by calling procedures.” (loosely quoted from Dearle et al, 1994) Choosing which model to adopt relies on 2 nd -order factors –0 th order = similar program structure, performance of client programs –1 st order = similar computational complexity –2 nd order = machine architecture features, programming environment – set a priori, so will drive decisions Can drive decision closure on process structure and synchronization using these 2 nd order factors

Dave Archer - CS533 - Spring Believable? Intuitive, but no formal classification or proof Mixed acceptance among a (biased) peer community Only one “transformable” example 47 citations, mostly taking it on faith –One, Welsh[2002] disputes that performance is equivalent when scaled to Internet server demands –None dispute the claimed functional duality Bottom line: close enough, except re performance

Dave Archer - CS533 - Spring References Hugh C. Lauer, Roger M. Needham. “On the Duality of Operating System Structures.” in Proceedings of the Second International Symposium on Operating Systems, IRIA, October 1978, reprinted in Operating Systems Review, 13, 2, pp April A. Dearle, R. Di Bona, J. Farrow, F. Henskens, A. Lindstrom. J. Rosenberg, F. Vaughan. “Grasshopper: An Orthogonally Persistent Operating System.” Computing Systems 7, 3 (Summer), pp Matthew D. Welsh, “An Architecture for Highly Concurrent, Well-conditioned Internet Services.” PhD Thesis at UC Berkeley, 2002.