neutral architectures I N operating system

download neutral architectures I N operating system

If you can't read please download the document

Transcript of neutral architectures I N operating system

TERM PAPERneutral architectures I N operating system

SUBMITTED BY:-JABIR ALIREG NO.11102338ROLL NO:-B12SEC-D1113 SUBMITTED TO:- Mr.shakti kundu AcknowledgementI would like to express my special thanks of gratitudeto my teacher shakti kundu sir who gave me the golden opportunity to do this wonderful project on the topic (neutral architectures in operating system) which also helped me in doing a lot of research and I came to know about so many new things I am really thankful to him .Secondly I would also like to thank my parents and friendswho helped me a lot in finishing this project within the limitted time I am making this project not only for marksbut to also increase my knowledge thanks again to allwho helped me. CONTENT1-kernal design

2-Monolithic Architecture

3-Layered Architecture

4-Microkernel Architecture

5-THE MULTIKERNEL MODEL

6-Make OS structure hardware-neutral

7-Process structure

8- Computer System Organization9-memory management

INTRODUCTIONComputer hardware is changing and diversifying faster than systemsoftware. A diverse mix of cores, caches, interconnect links, IOdevices and accelerators, combined with increasing core counts,leads to substantial scalability and correctness challenges for OSdesigners.data communication oers tangible benefits: instead of sequentiallymanipulating shared data structures, which is limited by thelatency of remote data access, the ability to pipeline and batch messagesencoding remote operations allows a single core to achievegreater throughput and reduces interconnect utilization. Furthermore,the concept naturally accommodates heterogeneous hardware.The contributions of this work are as follows:We introduce the multikernel model and the design principlesof explicit communication, hardware-neutral structure, andstate replication.We present a multikernel, Barrelfish, which explores the implicationsof applying the model to a concrete OS implementation.We show through measurement that Barrelfish satisfies ourgoals of scalability and adaptability to hardware characteristics,while providing competitive performance on contemporaryhardware. THE MULTIKERNEL MODELIn this section we present our OS architecture for heterogeneousmulticore machines, which we call the multikernel model. In anutshell, we structure the OS as a distributed system of cores thatcommunicate using messages and share no memory . Themultikernel model is guided by three design principles:1. Make all inter-core communication explicit.2. Make OS structure hardware-neutral.3. View state as replicated instead of shared.These principles allow the OS to benefit from the distributed systemsapproach to gain improved performance, natural support forhardware heterogeneity, greater modularity, and the ability to reusealgorithms developed for distributed systems.After discussing the principles in detail below weexplore the implications of these principles by describing the implementationof Barrelfish, a new operating system based on themultikernel model.

Make OS structure hardware-neutralA multikernel separates the OS structure as much as possible fromthe hardware. This means that there are just two aspects of theOS as a whole that are targeted at specific machine architectures the messaging transport mechanisms, and the interface to hardware(CPUs and devices). This has several important potential benefits.Firstly, adapting the OS to run on hardware with new performancecharacteristics will not require extensive, cross-cuttingchanges to the code base (as was the case with recent scalabilityenhancements to Linux and Windows). This will become increasinglyimportant as deployed systems become more diverse.In particular, experience has shown that the performance of aninter-process communication mechanism is crucially dependent onhardware-specific optimizations (we describe those used in Barrelfish. Hardware-independence in a multikernelmeans that we can isolate the distributed communication algorithmsfrom hardware implementation details.We envision a number of dierent messaging implementations(for example, a user-level RPC protocol using shared memory, or ahardware-based channel to a programmable peripheral). As we saw hardware platforms exist today without cache coherence,and even without shared memory, and are likely to becomemore widespread. Once the message transport is optimized, we canimplement ecient message-based algorithms independently of thehardware details or memory layout.

Process structure

The multikernel model leads to a somewhat dierent process structurethan a typical monolithic multiprocessor OS. A process in Barrelfishis represented by a collection of dispatcher objects, oneon each core on which it might execute. Communication in Barrelfishis not actually between processes but between dispatchers(and hence cores).Dispatchers on a core are scheduled by the local CPU driver,which invokes an upcall interface that is provided by each dispatcher.This is the mechanism used in Psyche [48] and scheduleractivations [3], and contrasts with the Unix model of simply resumingexecution. Above this upcall interface, a dispatcher typicallyruns a core-local user-level thread scheduler.

Memory managementAlthough a multikernel OS is itself distributed, it must consistentlymanage a set of global resources, such as physical memory. Inparticular, because user-level applications and system services maymake use of shared memory across multiple cores, and because OScode and data is itself stored in the same memory, the allocationof physical memory within the machine must be consistent forexample, the system must ensure that one user process can neveracquire a virtual mapping to a region of memory used to store ahardware page table or other OS object.

Monolithic Architecture Monolithic operating systemEvery component contained in kernelAny component can directly communicate with any otherTend to be highly efficientDisadvantage is difficulty determining source of subtle errors

Examples:LinuxUNIX (BSD, Solaris)MS-DOSMAC-OS till 8.6

Layers of the operating system

Layered approach to operating systemsTries to improve on monolithic kernel designsGroups components that perform similar functions into layersEach layer communicates only with layers immediately above and below itProcesses requests might pass through many layers before completionSystem throughput can be less than monolithic kernelsAdditional methods must be invoked to pass data and control Microkernel operating system architectureMicrokernel operating system architectureProvides only small number of servicesAttempt to keep kernel small and scalableHigh degree of modularityExtensible, portable and scalableIncreased level of intermodule communicationCan degrade system performanceExamples:MACHNTEROSMINIX Computer System Organization

Computer-system operationOne or more CPUs, device controllers connect through common bus providing access to shared memoryConcurrent execution of CPUs and devices competing for memory cycles Computer System OperationI/O devices and the CPU can execute concurrently. Each device controller is in charge of a particular device type. Each device controller has a local buffer. CPU moves data from/to main memory to/from local buffers

I/O is from the device to local buffer of controller.

Device controller informs CPU that it has finished its operation by causing an interrupt. Interrupts Suspends the normal sequence of executionSimple Interrupt Processing

Multiple InterruptsDisable interrupts while an interrupt is being processed Transition from User to Kernel Mode Timer to prevent infinite loop / process hogging resourcesSet interrupt after specific periodOperating system decrements counterWhen counter zero generate an interruptSet up before scheduling process to regain control or terminate program that exceeds allotted time.