CS533 Concepts of Operating Systems Jonathan Walpole.

Slides:



Advertisements
Similar presentations
1 Communication in Distributed Systems REKs adaptation of Tanenbaums Distributed Systems Chapter 2.
Advertisements

More on Processes Chapter 3. Process image _the physical representation of a process in the OS _an address space consisting of code, data and stack segments.
Dr. Kalpakis CMSC 621, Advanced Operating Systems. Fall 2003 URL: Distributed System Architectures.
Chorus and other Microkernels Presented by: Jonathan Tanner and Brian Doyle Articles By: Jon Udell Peter D. Varhol Dick Pountain.
Lightweight Remote Procedure Call Brian N. Bershad, Thomas E. Anderson, Edward D. Lazowska, and Henry M. Levy Presented by Alana Sweat.
EEE 435 Principles of Operating Systems Principles and Structure of I/O Software (Modern Operating Systems 5.2 & 5.3) 5/22/20151Dr Alain Beaulieu.
Chapter 7 Protocol Software On A Conventional Processor.
ECE 526 – Network Processing Systems Design Software-based Protocol Processing Chapter 7: D. E. Comer.
04/14/2008CSCI 315 Operating Systems Design1 I/O Systems Notice: The slides for this lecture have been largely based on those accompanying the textbook.
Contiki A Lightweight and Flexible Operating System for Tiny Networked Sensors Presented by: Jeremy Schiff.
CS533 Concepts of Operating Systems Class 5 System Structuring using Layers & Micro-Kernel Based OSs.
The Structuring of Systems Using Upcalls David D Clark Presented by: Prassnitha Sampath.
Figure 2.8 Compiler phases Compiling. Figure 2.9 Object module Linking.
CS533 Concepts of Operating Systems Class 7 System Structuring using Layers and Micro-kernels.
CS533 Concepts of Operating Systems Class 11 System Structuring using Layers.
1 CS 333 Introduction to Operating Systems Class 2 – OS-Related Hardware & Software The Process Concept Jonathan Walpole Computer Science Portland State.
Operating System Structure. Announcements Make sure you are registered for CS 415 First CS 415 project is up –Initial design documents due next Friday,
3.5 Interprocess Communication
CS533 Concepts of Operating Systems Class 8 System Structuring using Layers.
Real-Time Kernels and Operating Systems. Operating System: Software that coordinates multiple tasks in processor, including peripheral interfacing Types.
Ralf Juengling Portland State University The Structuring of Systems using Upcalls David D. Clark, “The Structuring of Systems using Upcalls”, Proc. of.
Exokernel: An Operating System Architecture for Application-Level Resource Management Dawson R. Engler, M. Frans Kaashoek, and James O’Toole Jr. M.I.T.
The Structuring of Systems Using Upcalls David D. Clark 4/26/20111Frank Sliz, CS533, Upcalls.
User-Level Interprocess Communication for Shared Memory Multiprocessors Brian N. Bershad, Thomas E. Anderson, Edward D. Lazowska, and Henry M. Levy Presented.
The Structuring of Systems Using Upcalls David D. Clark Presenter: Haitham Gad.
The Structuring of Systems Using Upcalls Paper by David D. Clark Presentation by Emerson Murphy-Hill.
CS533 Concepts of OS Class 16 ExoKernel by Constantia Tryman.
 The Open Systems Interconnection model (OSI model) is a product of the Open Systems Interconnection effort at the International Organization for Standardization.
OIS Model TCP/IP Model.
CS510 Concurrent Systems Jonathan Walpole. Lightweight Remote Procedure Call (LRPC)
Stack Management Each process/thread has two stacks  Kernel stack  User stack Stack pointer changes when exiting/entering the kernel Q: Why is this necessary?
Protocol Layering Chapter 10. Looked at: Architectural foundations of internetworking Architectural foundations of internetworking Forwarding of datagrams.
CS533 Concepts of Operating Systems Jonathan Walpole.
LiNK: An Operating System Architecture for Network Processors Steve Muir, Jonathan Smith Princeton University, University of Pennsylvania
LWIP TCP/IP Stack 김백규.
Three fundamental concepts in computer security: Reference Monitors: An access control concept that refers to an abstract machine that mediates all accesses.
Lecture 3 Process Concepts. What is a Process? A process is the dynamic execution context of an executing program. Several processes may run concurrently,
TCOM 509 – Internet Protocols (TCP/IP) Lecture 03_b Protocol Layering Instructor: Dr. Li-Chuan Chen Date: 09/15/2003 Based in part upon slides of Prof.
CE Operating Systems Lecture 3 Overview of OS functions and structure.
30 October Agenda for Today Introduction and purpose of the course Introduction and purpose of the course Organization of a computer system Organization.
Threads G.Anuradha (Reference : William Stallings)
CS333 Intro to Operating Systems Jonathan Walpole.
SOFTWARE DESIGN. INTRODUCTION There are 3 distinct types of activities in design 1.External design 2.Architectural design 3.Detailed design Architectural.
CS533 - Concepts of Operating Systems 1 The Mach System Presented by Catherine Vilhauer.
LRPC Firefly RPC, Lightweight RPC, Winsock Direct and VIA.
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.
The Mach System Silberschatz et al Presented By Anjana Venkat.
1 Chap. 2 Protocol. 2 Communication model Simplified communication model  source node  gather data from sensor or switch using ADC (analog-to-digital.
Lecture 4 Mechanisms & Kernel for NOSs. Mechanisms for Network Operating Systems  Network operating systems provide three basic mechanisms that support.
CS533 Concepts of Operating Systems Jonathan Walpole.
Presented by: JungChun Lu. Goal Propose a design methodology suitable for operating system programs which: Permits synchronous procedure call between.
Major OS Components CS 416: Operating Systems Design, Spring 2001 Department of Computer Science Rutgers University
The Structuring of Systems Using Upcalls By David D. Clark Presented by Samuel Moffatt.
The Structuring of Systems Using Upcalls David D. Clark (Presented by John McCall)
Computer Networking A Top-Down Approach Featuring the Internet Introduction Jaypee Institute of Information Technology.
Computer System Structures
LWIP TCP/IP Stack 김백규.
CS533 Concepts of Operating Systems
CS399 New Beginnings Jonathan Walpole.
The Structuring of Systems Using Upcalls David D. Clark
Final Review CS144 Review Session 9 June 4, 2008 Derrick Isaacson
Chapter 4: Threads.
Software models - Software Architecture Design Patterns
Structuring Of Systems Using Upcalls - By David D. Clark
Operating Systems Lecture 1.
Jonathan Walpole Computer Science Portland State University
CS533 Concepts of Operating Systems Class 11
Structuring of Systems using Upcalls
Computer Networking A Top-Down Approach Featuring the Internet
CS510 Operating System Foundations
Presentation transcript:

CS533 Concepts of Operating Systems Jonathan Walpole

The Structuring of Systems Using Upcalls

Overview A method for implementing layers with synchronous procedure calls between layers Upcalls –a lower layer calls an upper layer Multi-task module – multithreading

Outline Background Upcalls and Multi-task Modules Example Advantages Swift Operating System Problems Conclusions

Background 1968 – THE operating system -OS using strict top-down layering model 1982 – ISO network protocol stack -protocol stack using strict layering model 1985 – Swift operating system -OS with performance optimizations -inspired by networking problems

Layered Operating System

Advantages of Layered OS Black box abstraction Divide and conquer approach Easier to test and debug Easier to modify Acyclic dependencies Flow control matches trust relationships

7-Layer OSI Model application presentation session transport network data link physical

Disadvantages of Layered OS Poor match for bottom-up control flow Example: TCP congestion control Other problems: -Interrupt handlers are not scheduled -They are typically asynchronous -Buffering and copying overhead for data

Upcalls and Multi-Task Modules Upcall -Lower layer calls an upper layer via procedure call Multi-Task Modules -Multithreaded subroutines in a layer -State variables in shared memory -Subroutines callable from above or below

System Organization

Example - Network Protocol Display Transport Network CreateReceiveSend

Control Flow in Network Protocol Transport Layer Display Layer Network Layer

Example - Display Layer

Example - Transport Layer

Example - Network Layer

Example – Create Task

Example – Receive Task

Example – Send Task

Advantages of Upcalls Upward, synchronous control transfer via procedure call is more efficient than IPC No need for data buffering between layers Simplicity of implementation Lower layer can ask advice from upper layer resulting in simplification of algorithm

Advantage of Multi-Task Modules Subroutine interfaces are easier to deal with than IPC interfaces No system wide IPC message format needed Decisions about task usage can be made later, the tasks are not hard coded into layers Acknowledgements can be sent with new data packet - Piggybacking

Swift Operating System Explore upcall and multi-module usage Single address space with a typesafe language Monitor locks control access to shared state Initially used for network protocols Test to determine if useful in other contexts Develop solutions for upcall problems

Problems with Upcall Violates basic principle of layering -violates trust dependencies -upcall failure can leave lower layer in an unstable condition Difficult to recover resources when an upcall fails What if an upcall causes a recursive down call that changes layer state?

Mitigating Upcall Failures 2 classes of data -Client-specific private data which is expendable -Shared data shared that must be unlocked and consistent before upcalls Expendable tasks Layer-specific cleanup via system procedures Timer or User to detect infinite loop

Solutions to Recursive Calls 1.Put variables in consistent state before upcall and reevaluate them on return 2.Prohibit recursive downcalls so that variables can be left locked or inconsistent when upcalling 3.Downcall queues the work for later execution 4.Downcall is restricted in its actions 5.Downcall is replaced by extra arguments or it is replaced by a second upcall to query

Conclusions Methodology is useful for operating systems -Upcalls & multi-task modules are efficient -useful for network protocols and I/O -typesafe language gives efficient protection in shared address space Process per layer model is inefficient Parallel systems need shared memory for efficient communication between processes