DOC PREVIEW
Berkeley COMPSCI 162 - Lecture Notes

This preview shows page 1 out of 4 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 4 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 4 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

CS 162 Spring 2004 Lecture 2 1/1 Operating Systems and Systems Programming Professor: Anthony D. Joseph Spring 2004 Lecture 2: Operating System Structures 2.0 Administrivia: 2.0 Main points: History of operating systems Overview of Course Topics Overview of Main OS “structures” 2.1 History of Operating Systems: Change! One view of change: Typical academic computer in 1981 and 2004 1981 2004 Factor CPU MHz, cycles/inst 10 3-4 3200 0.25- 0.5 320 1.5-12 DRAM capacity 128KB 2 GB 16,000 Disk capacity 10 MB 500 GB 50,000 net bandwidth 9600 b/s 1 Gb/s 110,000 # address bits 16 32 2 # users/mach. 10s <= 1 0.1 Price $25000 $5500 0.22 LEAVE SPACE ON BOARD CS 162 Spring 2004 Lecture 2 2/2 Another view of change: DistributionMoreLessBatchRJETime SharingWS/ServerPC + NetworkMany peopleper computerOne personper computerMany computersper personInfo.AppliancesTime What does this mean? Techniques have to vary over time, adapt to changing tradeoffs. 2.1.1 History Phase 1: hardware expensive, humans cheap (1948 – 1970) When computers cost millions of $’s, optimize for more efficient use of the hardware! Lack of interaction between user and computer. • User at console: one user at a time. • Batch monitor: load program, run, print. Computers are expensive, so optimize to make better use of the hardware. When the user at the console is thinking, he’s not using the computer. So instead, feed the computer jobs in batches and make users wait for their results. Makes better use of hardware, but a lot worse for users. No protection: what if batch program had a bug and wrote over batch monitor? • Data channels, interrupts: overlap of I/O and computation. DMA – Direct Memory Access for I/O devices. OS requests I/O, goes back to computing, gets interrupt when I/O device has finished.CS 162 Spring 2004 Lecture 2 3/3 • Multiprogramming: several programs run at the same time; users share system. Multiprogramming benefits: 1. Small jobs not delayed by large jobs 2. More overlap between I/O and CPU Multiprogramming requires memory protection to keep bugs in one program from crashing the system or corrupting other programs. Bad news: OS must manage all these interactions between programs. Each step seems logical, but at some point, fall off cliff – just gets too complicated. • Multics: announced in 1963 -> ran in 1969 • OS 360 released with 1000 bugs. • OS’s finally begin to be an important science. How do we deal with this complexity? • UNIX based on Multics, but simplified so they could get it to work! 2.1.2 History, Phase 2: hardware cheap, humans expensive (1970-1985) Computers available for tens of thousands of dollars instead of millions. Can afford to start using them for more kinds of jobs Interactive timesharing: Use cheap terminals ($1-2K) to let multiple users interact with the system at the same time. Sacrifice CPU time to get better response time for users. Users start doing things like program development and debugging, test editing, and e-mail online. Problem: thrashing – performance falls off a cliff as you add users. CS 162 Spring 2004 Lecture 2 4/4 2.1.3 History, Phase 3: hardware very cheap, humans very expensive (1981-1990) Computer costs $1K, Programmer costs $100K/year If you can make someone 1% more efficient by giving them a computer, it’s worth it! Key challenge is to use computers to make more efficient use of people’s time. Personal computing – Computers are cheap, so give everyone a PC. Initially, PCs had limited hardware resources, so OS became a subroutine library for running one application at a time again (MSDOS). But since then, PCs have become powerful computers and the OS has regained all the complexity of a “big” OS: memory protection, multiprogramming, etc (NT, OS/2). Question: As hardware gets cheaper and cheaper does the need for some (or all) OS functions go away? 2.1.4 History, Phase 4: Distributed systems (1989-) Networking: allow different machines to share resources easily (printers, file servers, web servers). Client – Server model. 2.1.5 History, Phase 5: Mobile systems (1995-) Mobile devices (laptops, Personal Digital Assistants, etc.): small, portable, and inexpensive, but have limited capabilities (memory, CPU, power, etc.). If they have wireless support, they can leverage resources of distributed systems. Today’s lightweight laptops are nearly as powerful as desktops.CS 162 Spring 2004 Lecture 2 5/5 High-end lightweight laptop in 2004 Laptop 2004 CPU MHz, cycles/inst 1600 0.25- 0.5 DRAM capacity 2GB Disk capacity 80GB net BW (wired) (wireless LAN) (wide-area) 1 Gb/s 54 Mb/s 2 Mb/s # address bits 32 # users/mach. <= 1 Price $3700 2.1.6 History of Operating Systems: Summary Point of change isn’t: look how stupid batch processing is. It was right for the tradeoffs of the time – but not anymore. Point is: have to change with changing technology. Situation today is much like it was in the late 60’s: OS’s today are enormous, complex things: • small OS – 100K lines • big OS – 10M lines 100 – 1000 people-years NT under development from early 90’s to late 90’s (similar to mainframe OS development cycles), still doesn’t work very well. Jury is still out for Windows 2000 and Windows XP. Windows “Longhorn” delayed until 2006+? Key aspect of this course – understand OS’s, so we can simplify them! CS 162 Spring 2004 Lecture 2 6/6 2.2 Overview of Course Topics The course will be divided into three main topics (with exams corresponding roughly to these): 1. Concurrency: processes and threads 2. Memory management, File Systems, and I/O 3. Distributed Systems and Networking 2.3 Operating System Structures What follows is a brief “tour” of the overall structure of OS’s. There are several ways to divide things up and each yields a different kind of understanding about an OS. 2.3.1 System Components (What are the pieces of the OS?) • Process management • Main-memory management • I/O system management • File management • Networking • UI 2.3.2 Operating System Services (what things does the OS do?) Services that (more-or-less) map onto components: • Program execution • I/O operations • File system manipulation • Communications Cross-cutting capabilities: • Error detection & recovery • Resource allocation • Accounting • Protection


View Full Document

Berkeley COMPSCI 162 - Lecture Notes

Documents in this Course
Lecture 1

Lecture 1

12 pages

Nachos

Nachos

41 pages

Security

Security

39 pages

Load more
Download Lecture Notes
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Lecture Notes and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Lecture Notes 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?