Operating Systems: Architecture and General Theory CTEC1863/2013F Operating Systems.

Slides:



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

Operating System.
Operating System Structures
What is an operating system? Is it software?
Operating Systems Manage system resources –CPU scheduling –Process management –Memory management –Input/Output device management –Storage device management.
Computer Hardware & Systems
COURSE: COMPUTER PLATFORMS
Khaled A. Al-Utaibi  Computers are Every Where  What is Computer Engineering?  Design Levels  Computer Engineering Fields  What.
Operating-System Structures
Lecture 12 Page 1 CS 111 Online Devices and Device Drivers CS 111 On-Line MS Program Operating Systems Peter Reiher.
Introduction to Operating Systems CS-2301 B-term Introduction to Operating Systems CS-2301, System Programming for Non-majors (Slides include materials.
UNIX Chapter 01 Overview of Operating Systems Mr. Mohammad A. Smirat.
IT Systems Operating System EN230-1 Justin Champion C208 –
Operating Systems. What is an Operating System? A layer of software between users/applications and the hardware. The first program loaded onto a computer.
Home: Phones OFF Please Unix Kernel Parminder Singh Kang Home:
Xuan Guo Chapter 1 What is UNIX? Graham Glass and King Ables, UNIX for Programmers and Users, Third Edition, Pearson Prentice Hall, 2003 Original Notes.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition Chapter 2: Operating-System Structures Modified from the text book.
Copyright Arshi Khan1 System Programming Instructor Arshi Khan.
Operating Systems.
Word Processing, Web Browsing, File Access, etc. Windows Operating System (Kernel) Window (GUI) Platform Dependent Code Virtual Memory “Swap” Block Data.
Operating Systems Concepts 1. A Computer Model An operating system has to deal with the fact that a computer is made up of a CPU, random access memory.
Operating Systems.
An Introduction to Operating Systems. Definition  An Operating System, or OS, is low-level software that enables a user and higher-level application.
The University of Akron Summit College Business Technology Department Computer Information Systems 2440: 145 Operating Systems Introduction to UNIX/Linux.
Week 6 Operating Systems.
Chapter 3.1:Operating Systems Concepts 1. A Computer Model An operating system has to deal with the fact that a computer is made up of a CPU, random access.
Computer Organization Review and OS Introduction CS550 Operating Systems.
Lecture 14: Operating Systems Intro to IT COSC1078 Introduction to Information Technology Lecture 14 Operating Systems James Harland
hardware and operating systems basics.
Computer System Architectures Computer System Software
Chapter 4: What is an operating system?. What is an operating system? A program or collection of programs that coordinate computer usage among users and.
This presentation has been done by : Kareem Marwan Hamida..
Operating System. Architecture of Computer System Hardware Operating System (OS) Programming Language (e.g. PASCAL) Application Programs (e.g. WORD, EXCEL)
Operating Systems CS3502 Fall 2014 Dr. Jose M. Garrido
Operating Systems.
 Introduction to Operating System Introduction to Operating System  Types Of An Operating System Types Of An Operating System  Single User Single User.
LINUX System : Lecture 2 OS and UNIX summary Bong-Soo Sohn Assistant Professor School of Computer Science and Engineering Chung-Ang University Acknowledgement.
Software GCSE COMPUTING.
Hardware Definitions –Port: Point of connection –Bus: Interface Daisy Chain (A=>B=>…=>X) Shared Direct Device Access –Controller: Device Electronics –Registers:
Chapter 2: Operating-System Structures. 2.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts – 7 th Edition, Jan 14, 2005 Operating System.
Computing and the Web Operating Systems. Overview n What is an Operating System n Booting the Computer n User Interfaces n Files and File Management n.
Processes and OS basics. RHS – SOC 2 OS Basics An Operating System (OS) is essentially an abstraction of a computer As a user or programmer, I do not.
CE Operating Systems Lecture 3 Overview of OS functions and structure.
OPERATING SYSTEMS Lecture 3: we will explore the role of the operating system in a computer Networks and Communication Department 1.
Computers & Operating Systems
OPERATING SYSTEM - program that is loaded into the computer and coordinates all the activities among computer hardware devices. -controls the hardware.
X-WindowsP.K.K.Thambi The X Window System Module 5.
An operating system is the software that makes everything in the computer work together smoothly and efficiently. What is an Operating System?
© Paradigm Publishing, Inc. 4-1 Chapter 4 System Software Chapter 4 System Software.
CSC414 “Introduction to UNIX/ Linux” Lecture 2. Schedule 1. Introduction to Unix/ Linux 2. Kernel Structure and Device Drivers. 3. System and Storage.
Lecture on Central Process Unit (CPU)
Lecture 1: Network Operating Systems (NOS) An Introduction.
Computer Organization Instruction Set Architecture (ISA) Instruction Set Architecture (ISA), or simply Architecture, of a computer is the.
Chapter 1 Basic Concepts of Operating Systems Introduction Software A program is a sequence of instructions that enables the computer to carry.
System Programming Basics Cha#2 H.M.Bilal. Operating Systems An operating system is the software on a computer that manages the way different programs.
OPERATING SYSTEMS DO YOU REQUIRE AN OPERATING SYSTEM IN YOUR SYSTEM?
1 Chapter 2: Operating-System Structures Services Interface provided to users & programmers –System calls (programmer access) –User level access to system.
1 OPERATING SYSTEMS. 2 CONTENTS 1.What is an Operating System? 2.OS Functions 3.OS Services 4.Structure of OS 5.Evolution of OS.
System SOFTWARE.
Introduction to Operating Systems Concepts
Operating System Overview
Operating System & Application Software
Lecture 1-Part 2: Operating-System Structures
Resource Management IB Computer Science.
2. OPERATING SYSTEM 2.1 Operating System Function
Lesson Objectives Aims You should be able to:
Linux Operating System Architecture
Chapter 2: System Structures
CS703 - Advanced Operating Systems
Chapter-1 Computer is an advanced electronic device that takes raw data as an input from the user and processes it under the control of a set of instructions.
Presentation transcript:

Operating Systems: Architecture and General Theory CTEC1863/2013F Operating Systems

Operating System a program that acts as an interface between a user of a computer and the computer hardware make the computer system convenient to use use the computer hardware in an efficient manner

Some light reading...

Programs program = a set of instructions to control the computer hardware Most modern operating systems are written in the C language or and/or a C-like language and/or assembly language

Interfaces interface = a boundary between two layers – typically, how a "lower" layer appears to a "higher" layer. Interfaces exist all throughout computers. A "higher" layer means a higher level of abstraction – a "lower" layer often represents "nuts & bolts".

Interfaces (2) Examples: – RS-232 interface (serial port) – USB interface – Application Programmer Interface (API) An interface exists so that a computer user does not need to know the underlying details – how the hardware "really" works.

Interfaces (3) Interestingly enough, the field of computer engineering is all about understanding both the higher and lower layers...

Non-computer analogy An automobile is a complicated machine – most drivers do not actually understand how a car really works. This is because, as a driver, you do not need to know what happens. You have a standard interface.

Human-Motor Vehicle Interface (HMVI)* The interface for the automobile is the steering wheel, accelerator pedal, brake pedal, gearshift, gauges (speedometer, fuel gauge, possible tachometer), turn signal, (optional) clutch pedal... *I made it up!

... Drive! The bottom line: you can drive any car, from a lowly Yugo to a Formula One racer, because the interfaces on every car are similar enough!

User Interface (UI) Graphical (GUI)Command-Line (CLI)

Operating Systems In this course we are going to study three popular operating systems: Microsoft Windows, MacOS X, and Linux.

Operating System Interfaces Each presents both graphical and command- line interfaces (to the computer hardware) to the user.

Operating System Interfaces (2) Windows has the Windows Desktop, Windows Explorer, and Command Prompt Mac OS X has the Aqua Desktop, Finder, and Terminal Linux has the GNOME and KDE desktops, and various terminals

Operating System Interfaces (3) All Microsoft Windows operating systems, from Windows 95 to 7, have a similar interface. All UNIX operating systems, from Solaris to AIX to HP-UX to the BSDs, have a similar interface. All Linux operating systems, from Red Hat to Slackware to SuSE to Debian to Ubuntu, have a similar interface.

Operating System Interfaces (4) To simplify things even further, Linux and UNIX are similar (almost identical from a CLI perspective). Furthermore, MacOS X has BSD UNIX under the hood. In fact, you can run Windows, MacOS X, Solaris, and Linux on the exact same hardware!

Task an independently-scheduled thread of execution. a.k.a. process, thread i.e., a running program Some programs are interactive applications, others exist in the form of services.

Kernel the code that is directly responsible for the tasking model – i.e., how the CPU's time is allocated.

Pre-emptive Multitasking The capability of an operating system to equitably share CPU time between several well- defined tasks currently scheduled to run on the system. All modern O/S do this!

Meeting the two goals … Be responsive to the user when running multiple tasks (allow fairly quick switching between tasks) Keep the CPU (and the rest of the hardware) busy at all times

Resource Management Another way of looking at operating systems… An operating system manages resources for applications and services. (This is its only real purpose in life.) – CPU time sharing (context switching) – Memory management (virtual memory) – Hardware (timers, DMA, interrupt controllers, etc.) – Interprocess communications (IPCs)

Resource Management (2) Both applications and services are just fancy names for programs that run on a computer (in the form of tasks/processes/threads). In pursuing the goal of managing resources, the operating system designer walks the line between convenience and efficiency.

Resource #1: CPU Time The CPU is rated at a certain speed – way back in the day, kHz; recently, MHz; now, GHz; in the future THz (?) CPU designers try to make their CPUs run as fast as possible using a variety of techniques: pipelining, superscaling, superpipelining, Hyperthreading, etc.

CPU Time (2) The faster the CPU, the more instructions can be executed per second: – 1 kHz = 1,000 instructions per second* (ips) – 1 MHz = 1,000,000 ips – 1 GHz = 1,000,000,000 ips * best case scenario

CPU Time (3) Instructions are what make up programs. Programs run on a computer in the form of tasks/processes/threads. A faster CPU means programs run faster. (Although, not necessarily... lots of other factors!) An operating system is a program, made up of instructions. To get its work done, those instructions run on the CPU.

CPU Time (4) Some operating systems try to use as little CPU time as possible, so that more of the CPU time is available for running programs. How efficient an operating system/CPU combination is can be measured in context switch time, typically in μs. The lower the context switch time, the more efficient an operating system is at managing the CPU's time.

Walking the Line Between Convenience and Efficiency Efficiency is important for real-time operating systems – that are used in applications like process control. It is also important in server operating systems that need to deal with high network traffic. Desktop operating systems place less importance on efficiency and more importance on convenience.

Resource #2: Memory There are multiple levels of memory in a computer system:

Memory (2) The operating system controls physical memory (RAM) and virtual memory (paging file or swap space – on disk). RAM is always at least 1,000 times faster than the fastest (mechanical) hard disk – therefore, adding more RAM will (almost always) make the operating system better able to operate efficiently and also provide a more convenient user experience.

Memory (3) For the same reason, file system caching is also used on all modern operating systems, to minimize the amount of hard disk access.

Resource #3: Hardware All devices that make up a computer system are connected to the CPU Programs control the CPU only; the CPU controls the hardware The CPU can only access instructions and data that are in RAM

Hardware (2) As important (more important for some applications!) as CPU clock speed and the amount of RAM is I/O throughput – how quickly data can be moved between RAM and the other devices – disk drives, network interfaces, etc.

Hardware (3) Throughput is also known as bandwidth. It is a rate, and is measured in bits per second (bps) or bytes per second (Bps), also: – kilobits per second (kbps) / kilobytes per second (kBps) – megabits per second (Mbps) / megabytes per second (MBps) – gigabits per second (Gbps) / gigabytes per second (GBps)

Interrupts I/O operations are typically done via interrupts – an I/O device will signal (interrupt) the CPU when it needs attention An operating system responds by running a program, called an interrupt service routine (ISR), made up of instructions to control the hardware device – the instructions are executed (processed) on the CPU itself.

Interrupts (2) An ISR has four responsibilities: 1.Read the status of the hardware device. 2.Control the hardware device. 3.Move data from the hardware device to RAM (input). 4.Move data from RAM to the hardware device (output).

Interrupts (3) Another measure: interrupt latency – how fast the operating system/CPU combination can respond to interrupts – typically measured in µs or even ms. The lower the interrupt latency, the more interrupts can be processed per second. And the more data can be moved – i.e., higher throughput.

Resource #4: Inter-Process Communications This means co-operation between tasks/processes/threads (a.k.a., running programs).

IPCs (2) – Examples: Pipelines "drag and drop Printing helper applications/file associations CGI applications database-driven web sites The lower the IPC overhead (latency), the faster the communications (higher throughput).

See the course web site for more…