Top Banner
Principles of Operating Systems - Lecture 1 1 Principles of Operating Systems Introduction and Overview Prof. Dan Connors
26

Principles of Operating Systems

Jan 22, 2016

Download

Documents

Nora

Principles of Operating Systems. Introduction and Overview Prof. Dan Connors. OS Staff. Instructor: Prof. Dan Connors Office: MW 12-2 CS Building 320 Email: [email protected] Teaching Assistants: TA Bryan Corell 
Email: [email protected] 
. Course logistics and details. - PowerPoint PPT Presentation
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 1

Principles of Operating Systems

Introduction and Overview

Prof. Dan Connors

Page 2: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 2

OS Staff

Instructor: Prof. Dan Connors

Office: MW 12-2 CS Building 320

Email: [email protected]

Teaching Assistants: TA Bryan Corell Email: [email protected]

Page 3: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 3

Course logistics and details

Course Web page - http://web.cs.du.edu/~dconnors/courses/comp3361

Lectures - MW 2:00-3:50

Textbook: Operating System Concepts -- 8th Edition Silberschatz and Galvin, Addison-Wesley Inc.

Alternate Book Principles of Operating Systems, L.F. Bic and A.C. Shaw,

Prentice-Hall/Pearson Education, 2003. ISBN 0130266116.

Page 4: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 4

Course logistics and details

Homework and Assignments ~5 written homework assignments in the

quarter, and 5 programming assignments (some knowledge of C). Late homework will not be accepted.

Tests Midterm - date to be announced, tentatively

Week 5 in class 2:00 pm - 3:50 pm Friday John Greene

Hall 316 Mar 12, 2010 - Mar 12, 2010

Page 5: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 5

Grading Policy

Homework - 35% Midterm - 30% of the final gradeFinal exam - 35% of the final grade

Final assignment of grades will be based on a curve.

Page 6: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 6

Lecture Schedule

Week 1: • Introduction to Operating Systems, Computer System

Structures, Operating System Structures

Week 2 : Process Management• Processes and Threads, CPU Scheduling

Week 3: Process Management• Process Synchronization

Week 4: Process Management• Process Synchronization

Week 5: Storage Management• Deadlocks

Page 7: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 7

Course Schedule

Week 6 - Storage Management• Midterm exam, Memory Management

Week 7 - Storage Management• Memory Mangement, Virtual Memory

Week 8 - I/O Systems• Virtual Memory, Filesystem Interface,

Week 9 - Other topics• FileSystems Implementation, I/O subsystems

Week 10 - Other topics• Case study – UNIX, WindowsNT, course revision and

summary.

Page 8: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 8

Introduction

What is an operating system?Early Operating SystemsSimple Batch SystemsMultiprogrammed Batch SystemsTime-sharing SystemsPersonal Computer SystemsParallel and Distributed SystemsReal-time Systems

Page 9: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 9

What is an Operating System?

An OS is a program that acts an intermediary between the user of a computer and computer hardware.

Major cost of general purpose computing is software. OS simplifies and manages the complexity of

running application programs efficiently.

Page 10: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 10

Goals of an Operating System

Simplify the execution of user programs and make solving user problems easier.

Use computer hardware efficiently. Allow sharing of hardware and software resources.

Make application software portable and versatile.

Provide isolation, security and protection among user programs.

Improve overall system reliability error confinement, fault tolerance, reconfiguration.

Page 11: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 11

Why should I study Operating Systems?

Need to understand interaction between the hardware and applications

New applications, new hardware..

Need to understand basic principles in the design of computer systems

efficient resource management, security, flexibility

Increasing need for specialized operating systems

e.g. embedded operating systems for devices - cell phones, sensors and controllers

real-time operating systems - aircraft control, multimedia services

Page 13: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 13

Abstract View of System

System and Application ProgramsSystem and Application Programs

Operating SystemOperating System

Computer Hardware

Computer Hardware

User1

User1 User

2

User2

User3

User3

Usern

Usern

compiler assembler Text editor Databasesystem

...

Page 14: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 14

Multiprogramming

Use interrupts to run multiple programs simultaneously

When a program performs I/O, instead of polling, execute another program till interrupt is received.

Requires secure memory, I/O for each program.

Requires intervention if program loops indefinitely.

Requires CPU scheduling to choose the next job to run.

Page 15: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 15

Timesharing

Programs queued for execution in FIFO order.

Like multiprogramming, but timer device interrupts after a quantum (timeslice).

Interrupted program is returned to end of FIFONext program is taken from head of FIFO

Control card interpreter replaced by command language interpreter.

Page 16: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 16

Timesharing (cont.)

Interactive (action/response) when OS finishes execution of one command, it

seeks the next control statement from user.

File systems online filesystem is required for users to access data

and code.

Virtual memory Job is swapped in and out of memory to disk.

Page 17: Principles of   Operating Systems

Moore’s Law- Growth in Transistor Density

Defined by Dr. Gordon Moore (Intel) in the late 1960s.

Predicts an exponential increase in component (transistor) density over time- a doubling time of 18 months.

Does not translate directly into performance or clock frequency.

Applicable to microprocessors, DRAMs, DSPs, and other microelectronics.

Page 18: Principles of   Operating Systems

Transistors and Clock Rate

Processors got faster every 18 months (roughly 50% to 100%!)Why bother with parallel programming? Just wait a year or two.

Slide Source: http://audilab.bmed.mcgill.ca/~funnell/Bacon/HW/trends.html

Page 19: Principles of   Operating Systems

Current Trends

New ConstraintsPower limits clock rates

Cannot squeeze more performance from ILP (complex cores) either!

But Moore’s Law continues!What to do with all of those transistors if everything else is flat-lining?

Power Consumption is chief concern for system architects

Power-Efficiency is the primary concern of consumers of computer systems!

Figure courtesy of Kunle Olukotun, Lance Hammond, Herb Sutter, and Burton Smith

Page 20: Principles of   Operating Systems

Emerging Multicore ProcessorsProcessor coresProcessor cores

SharedShared

L2$L2$

SharedShared

L3$L3$

L2$L2$

L3$L3$

Multicore ProcessorsMonolithic Processor

Page 21: Principles of   Operating Systems

Chip-multiprocessors (CMPs)Processor coresProcessor cores

SharedShared

L2$L2$

SharedShared

L3$L3$

• Future computer systems will integrate 10’s of multithreaded processors on a single chip die, resulting in 100’s of concurrent program threads sharing system resources

• Multiple processor cores– Chip multiprocessor (CMP)– Multithreaded (SMT/MT) in

each core• Lower communication

costs• Purpose-built low-latency

communication hardware

Page 22: Principles of   Operating Systems

Run-time Adaptation/Optimization

Continuous optimization: constantly adapt system to meet current usage requirements and system characteristics

System software continually and automatically adapt system resource decisions and thread execution

MT coresMT cores

SharedShared

L2$L2$

SharedShared

L3$L3$

PMU DataPMU Data

HW AlertsHW Alerts

On/off-line profileOn/off-line profile Monit

ori

ng

En

gin

e

OperatingSystem

DynamicCompiler

StaticCompile

r

Adjusted codeAdjusted code

Resource allocationsResource allocations

Page 23: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 23

Parallel Systems

Multiprocessor systems with more than one CPU in close communication.

Improved Throughput, economical, increased reliability.

Kinds:• Vector and pipelined• Symmetric and asymmetric multiprocessing• Distributed memory vs. shared memory

Programming models:• Tightly coupled vs. loosely coupled ,message-based vs.

shared variable

Page 24: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 24

Distributed Systems

Distribute computation among many processors.

Loosely coupled - • no shared memory, various communication lines

client/server architecturesAdvantages:

• resource sharing • computation speed-up• reliability• communication - e.g. email

Applications - digital libraries, digital multimedia

Page 25: Principles of   Operating Systems

Principles of Operating Systems - Lecture 1 25

Real-time systems

Correct system function depends on timeliness

Feedback/control loopsSensors and actuatorsHard real-time systems -

Failure if response time too long.Secondary storage is limited

Soft real-time systems - Less accurate if response time is too long.Useful in applications such as multimedia, virtual reality.

Page 26: Principles of   Operating Systems

Virtual Machines

Logically treats hardware and OS kernel as hardware

Provides interface identical to underlying bare hardware.

Creates illusion of multiple processes - each with its own processor and virtual memory

hardware

Virtual machine

kernel kernel kernel

processes

processes

processes