M a c O S X CS-450-1: Operating Systems Fall 2005 Matt Grady – Mike O’Connor – Justin Rains.

Slides:



Advertisements
Similar presentations
Operating Systems (CSCI2413) Lecture 2 Overview phones off (please)
Advertisements

Operating System Structures
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.
G Robert Grimm New York University Virtual Memory.
MACHINE-INDEPENDENT VIRTUAL MEMORY MANAGEMENT FOR PAGED UNIPROCESSOR AND MULTIPROCESSOR ARCHITECTURES R. Rashid, A. Tevanian, M. Young, D. Golub, R. Baron,
14 Macintosh OS X Internals. © 2005 Pearson Addison-Wesley. All rights reserved The Macintosh Platform 1984 – first affordable GUI Based on Motorola 32-bit.
Threads, SMP, and Microkernels Chapter 4. Process Resource ownership - process is allocated a virtual address space to hold the process image Scheduling/execution-
Computer Systems/Operating Systems - Class 8
3: OS Structures 1 OPERATING SYSTEM STRUCTURES PROCESS MANAGEMENT A process is a program in execution: (A program is passive, a process active.) A process.
Chapter 101 Virtual Memory Chapter 10 Sections and plus (Skip:10.3.2, 10.7, rest of 10.8)
11/13/01CS-550 Presentation - Overview of Microsoft disk operating system. 1 An Overview of Microsoft Disk Operating System.
Introduction to Operating Systems – Windows process and thread management In this lecture we will cover Threads and processes in Windows Thread priority.
Introduction to Kernel
CMPT 300: Operating Systems Review THIS REIVEW SHOULD NOT BE USED AS PREDICTORS OF THE ACTUAL QUESTIONS APPEARING ON THE FINAL EXAM.
2: OS Structures 1 Jerry Breecher OPERATING SYSTEMS STRUCTURES.
Home: Phones OFF Please Unix Kernel Parminder Singh Kang Home:
CSCE 351: Operating System Kernels
Microkernels: Mach and L4
Cs238 Lecture 3 Operating System Structures Dr. Alan R. Davis.
CS533 - Concepts of Operating Systems
Operating Systems CS208. What is Operating System? It is a program. It is the first piece of software to run after the system boots. It coordinates the.
Computer Organization and Architecture
OPERATING SYSTEMS Introduction
1 Process Description and Control Chapter 3 = Why process? = What is a process? = How to represent processes? = How to control processes?
The Design of Robust and Efficient Microkernel ManRiX, The Design of Robust and Efficient Microkernel Presented by: Manish Regmi
Operating System Organization
The Mach System "Operating Systems Concepts, Sixth Edition" by Abraham Silberschatz, Peter Baer Galvin, and Greg Gagne Presentation by Jonathan Walpole.
CS364 CH08 Operating System Support TECH Computer Science Operating System Overview Scheduling Memory Management Pentium II and PowerPC Memory Management.
Basics of Operating Systems March 4, 2001 Adapted from Operating Systems Lecture Notes, Copyright 1997 Martin C. Rinard.
Chapter 8 Windows Outline Programming Windows 2000 System structure Processes and threads in Windows 2000 Memory management The Windows 2000 file.
Mac OS X Stephen Ayers David Der Nathan Henkel Dan Hodos William Hunt.
Mac OS X Panther Operating System
Operating Systems (CS 340 D) Dr. Abeer Mahmoud Princess Nora University Faculty of Computer & Information Systems Computer science Department.
Chapter 4 Threads, SMP, and Microkernels Patricia Roy Manatee Community College, Venice, FL ©2008, Prentice Hall Operating Systems: Internals and Design.
Processes and Threads Processes have two characteristics: – Resource ownership - process includes a virtual address space to hold the process image – Scheduling/execution.
30 October Agenda for Today Introduction and purpose of the course Introduction and purpose of the course Organization of a computer system Organization.
The Mach System Abraham Silberschatz, Peter Baer Galvin, Greg Gagne Presentation By: Agnimitra Roy.
Scott Ferguson Section 1
A summary by Nick Rayner for PSU CS533, Spring 2006
1 Threads, SMP, and Microkernels Chapter Multithreading Operating system supports multiple threads of execution within a single process MS-DOS.
CS533 - Concepts of Operating Systems 1 The Mach System Presented by Catherine Vilhauer.
Mac OS X December 5, 2005 Fall 2005 Term Project CS450 Operating Systems (Section 2) Darrell Hall, Ryan Lanman, Chris Sanford, John Suarez {halldl, lanmanrm,
System Components ● There are three main protected modules of the System  The Hardware Abstraction Layer ● A virtual machine to configure all devices.
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.
CSC414 “Introduction to UNIX/ Linux” Lecture 2. Schedule 1. Introduction to Unix/ Linux 2. Kernel Structure and Device Drivers. 3. System and Storage.
Full and Para Virtualization
What is an Operating System? Various systems and their pros and cons –E.g. multi-tasking vs. Batch OS definitions –Resource allocator –Control program.
1 Process Description and Control Chapter 3. 2 Process A program in execution An instance of a program running on a computer The entity that can be assigned.
Operating Systems: Summary INF1060: Introduction to Operating Systems and Data Communication.
Mac OS X Cate Wardell Tim Miller Tina Han Kenan Shifflett Zach Debord.
COMP091 – Operating Systems 1 Memory Management. Memory Management Terms Physical address –Actual address as seen by memory unit Logical address –Address.
1 Contents Memory types & memory hierarchy Virtual memory (VM) Page replacement algorithms in case of VM.
CSCI/CMPE 4334 Operating Systems Review: Exam 1 1.
1 Chapter 2: Operating-System Structures Services Interface provided to users & programmers –System calls (programmer access) –User level access to system.
Introduction to Operating Systems Concepts
Introduction to Kernel
The Mach System Sri Ramkrishna.
Chapter 12: File System Implementation
Chapter 9: Virtual Memory
Operating System I/O System Monday, August 11, 2008.
KERNEL ARCHITECTURE.
Chapter 3: Windows7 Part 2.
Mach Kernel Kris Ambrose Kris Ambrose 2003.
Chapter 3: Windows7 Part 2.
Overview Continuation from Monday (File system implementation)
Process Description and Control
Operating Systems Lecture 1.
LINUX System : Lecture 7 Lecture notes acknowledgement : The design of UNIX Operating System.
OPERATING SYSTEMS STRUCTURES
Presentation transcript:

M a c O S X CS-450-1: Operating Systems Fall 2005 Matt Grady – Mike O’Connor – Justin Rains

Overview: General Tenth version of the Mac OS developed by Apple Independent of all previous versions of Mac OS Noticeable surface changes –Brand new GUI “Aqua,” a radical departure from previous versions –Addition of the Dock, an application launcher Introduction of open-source Darwin –Mach forms the core of XNU kernel –Built on BSD Unix foundation

Overview: Tiger Current version of OS X, 10.4 Changes for the general user –Spotlight: powerful meta-data search tool –Dashboard: mini-application layer Additions “under the hood” –Startup daemon ‘launchd’ allows for quick boots –Kernel resource locking optimization –Core Image, Core Data, Core Video

CPU Scheduling Mach holds four different priority queues –Normal –System High –Kernel Mode Only –Real Time Non-kernel mode only threads’ priorities constantly changing Prevents bottlenecking by giving resource-intensive threads lower priorities

Processor Modes Supervisor Mode or User Mode –Supervisor calls made through Mach –Message Passing (no trap table) Interrupt Context not necessary –Uses a generic interrupt handling thread –Spends minimal time in supervisor mode –Minimal latency using this approach. I/O Kit –Part of Darwin that handles device drivers –Has all the support for multi-processor machines (SMP)

Process Management Multiprocessor Systems –Splits processes into independent threads –Takes advantage of critical sections (regions) –Multiprocessing Services API Features, code, and support for multiprocessor functionality (semaphores, critical regions, processor availability, etc) Allows programmers to set relative priority of tasks Process Tracking –Similar to Mach 3.0 –Mach Tasks –Mach Ports

File Management Provides support for numerous file systems –UFS, ISO 9660, MS-DOS, SMB, NFS –HFS and HFS+ (extended) Preferred file system 64 bit length files 32 bit allocation table (HFS was 16 – limits disk size drastically) Not case sensitive Virtual File System –On UFS, derived from BSD –Allows for booting from other file systems (need kernel extensions) –Vnode Data structure for directories and files Vnode Operations (VOP) allows access and provide operations

File Management Carbon –Default Volume type is HFS+ –Includes File Manager subsystem Provides functionality for manipulating directories and files Accessing Information about Files and Directories Allocating File Blocks Controlling Login and Directory AccessCopying and Moving Files Creating a File System Reference Creating and Deleting Forks Creating and Deleting Directories Creating File System Specifications Creating and Deleting Files Getting and Setting Volume Information

Memory Management Apple’s memory model is based on the one used in the Mach v3.0 kernel Uses virtual memory with the working set algorithm for determining page faults In addition, Translation Lookaside Buffers, page tables, and other techniques are implemented as hardware specific RAM is considered a cache for virtual memory – processes are initially loaded into virtual memory and pages are only brought into RAM as needed

Memory Management At the base level, memory is paged Above that level is the Memory Object, which may contain a page, a set of pages, a stack, or a file A Virtual Memory (VM) Object is a collection of memory objects A Memory Map is the total collection of VM objects for a process The Virtual Memory (VM) system manages the VM objects, while a subordinate, machine dependent, Process Mapping system (pmap) handles the actual page faults When two or more processes refer to the same page(s), a Shadow VM object is created, which is a pointer to the original VM object that actually contains the data Universal Page Lists (UPL) are data structures used to communicate with the VM system. A UPL is initialized with data from a VM object, the data is altered, and the UPL is forced back on the VM object

Memory Management There are two types of page faults: hard and soft A hard page fault is the usual, where a page is not RAM, but is needed A soft page fault is when the needed page is already in RAM, but does not belong to the calling process’s memory space. In this case a shadow VM object is created Shadow VM objects use “copy-on-write”, which means that the shadow VM object continues to point to the target VM object until a write is attempted, at which point the target pages within the VM object are copied The VM system maintains a “free list”, an “inactive list”, and an “active list” of RAM. The system attempts to maintain a certain number of pages in the free list by swapping pages in the inactive list out.

Deadlock OS X does not seem to have any standard strategies for dealing with deadlock. It is essentially left up to the application programmer to work out the bugs which may cause deadlock One strategy listed was to try to minimize the amount of a resource that could be contested at any one time. For example, break one large lock, which refers to a list of buffers, into several smaller locks for each buffer It is also recommended that critical sections of code be kept to a minimum Buffers may be eliminated, and thereby the possibility for their contention, by using InterProcess Communication (IPC), which is a kernel function that directly copies data from one process to another Apple mentions using a total order for read-write locks, but refers to this technique as “rather extreme”

Summary OS X v10.4 is Apple’s current OS for the Mac Designed for use by home users and creative professionals Built on open-source, very stable Darwin core