CS 537: INTRO TO OPERATING SYSTEMS
Andrea C. Arpaci-Dusseau University of Wisconsin-Madison Fall 2019
WHO AM I?
Professor Andrea Arpaci-Dusseau
PhD from U.C. Berkeley – Implicit Coscheduling of Parallel Jobs Postdoc at Stanford – Taught OS course there
Teach CS 537, CS 736 (Adv OS), CS 739 (Dist Systems) and CS 402 Co-Advised about 25 PhD students, mostly research in file and storage systems Co-Chair for 2018 OSDI Program Committee
2018 (w/ Remzi) – SIGOPS Mark Weiser award for “outstanding leadership, innovation, and impact in storage and computer systems research”
Call Me
Prof. Andrea, Prof. Dusseau, or Andrea
TODAYS AGENDA
What will you do in this course?
What is an operating system and why do we need one? Why study operating systems?
Course syllabus
LEARNING OUTCOMES
• High-level understanding of an Operating System and role it plays
• Understand how OS virtualizes physical resources, abstractions the
OS provides, and how abstractions efficiently implemented w/
current hardware
• Create correct multi-threaded applications using synchronization
primitives
• Understand how OS ensures information persists despite power
outages, crashes, and failures
• Implement open-ended programming projects (alone and w/ partner)
• Use existing system calls and add functionality to a simplified OS
Lecture Material (50%)
ASSESSMENTS
Two midterms and a final exam
Closed book, multiple choice
Assess OS concepts discussed in class
May have homeworks as part of this
Form study groups of 5 or so; meet weekly to discuss lecture content
Projects (50%)
Eight programming projects done on CS Linux labs
Gain hands-on experience, Build your own OS system calls!
Lecture
Tue and Thu, 11:00-12:15 Location: 1125 BioChem
Conceptual content, Shows Slides,
Reading matches textbook chapters
FORMAT
Discussion
5 “smaller” sections on Wednesday …
Hands-on code walk through (BYOL) Explain programming projects
Led by TAs (and Peer Mentors)
Instructor: Andrea Arpaci-Dusseau
Teaching assistants:
Yifan Dai,
Abigail Matthews, Vanshika Baoni,
Adarsh Mittal,
Apurbaa Bhattacharjee, Akhil Guliani,
Akshaya Kalyanaraman
20 course staff!
Peer mentors: Anthony Barthell, Siddhant Bhagat, Taijing Chen, Alan Gao,
Emma He,
Kieran Mulligan, Shashwat Srivastava, Sean Sun,
June Werner,
Jerry Yu,
Shawn Zhong,
Jerry Zou
PERSONNEL
IMPORTANT LINKS
Course website https://canvas.wisc.edu/courses/154998
Piazza
https: //piazza. com/wisc/fall2019/fa19compsci537001/home
MATERIALS
Free
Academic Integrity
It is OK to:
– discuss project or specification in general terms (when to return an error?) – discuss how different library routines/system calls work
– ask peer mentors, TAs, and professor for help
It is NOT OK to:
– use code samples for similar problems you may find on-line – bug someone else for a lot of help
– share your code directly with other people/project groups – post your code in a public place
We will run tools to check for similar code across individuals
WHAT IS AN OPERATING SYSTEM ?
Users Applications
Operating System
Hardware
Software that converts hardware into a useful form for applications
WHAT DOES OS PROVIDE: ROLE #1
Abstraction: Provide standard library for resources
What is a resource?
Anything valuable (e.g., CPU, memory, disk)
What abstraction does modern OS typically provide?
CPU: process and/or thread Memory: address space Disk: files
WHY SHOULD OS DO THIS ?
Advantages of OS providing abstraction?
Allow applications to reuse common facilities Make different devices look the same
Provide higher-level or more useful functionality
Challenges
What are the correct abstractions?
How much of hardware should be exposed?
WHAT DOES OS PROVIDE: ROLE #2
Resource management – Share resources well
What is sharing?
Multiple users of the system
Multiple applications run by same user Multiple devices for same functionality
WHY SHOULD OS DO THIS ?
Advantages of OS providing resource management?
Protect applications at a common layer
Provide efficient access to resources (cost, time, energy) Provide fair access to resources
Challenges
What are the correct mechanisms? What are the correct policies?
OPERATING SYSTEM ROLES SUMMARY
Two main roles – Abstraction
– Resource management
Common layer to implement roles
Number of design, implementation challenges
Break Time?
• You form a unique community
• Get to know your classmates
• Introduce yourself to the two people around you
– Your name
– What year are you in school?
– What other classes are you taking?
– Have you already taken any that they are – if so, advice?
COURSE APPROACH
OPERATING SYSTEMS: THREE EASY PIECES
Three conceptual pieces 1. Virtualization
2. Concurrency
3. Persistence
VIRTUALIZATION
Make each application believe it has each resource to itself Demo: Virtualize CPU and memory
CONCURRENCY
Events occur simultaneously and may interact with one another Need to
Hide concurrency from independent processes Manage concurrency with interacting processes
Provide abstractions (locks, semaphores, condition variables etc.)
Demo with threads
PERSISTENCE
Lifetime of data is longer than lifetime of any one process Machine may lose power or crash unexpectedly
Issues:
High-level abstractions: Files, directories (folders), links Correctness with unexpected failures
Performance: disks are very slow!
Virtualization Concurrency Persistence Advanced Topics
ADVANCED TOPICS
SSDs
Network and Distributed File Systems
WHY STUDY OS ?
Build, modify, or administer an operating system
Understand system performance
– Behavior of OS impacts entire machine
– Tune workload performance
– Apply knowledge across many layers
Fun and challenging to understand large, complex systems
WAITLIST
If you are on the waitlist, sign sheet showing you attended lecture today
NEXT STEPS
Check out Canvas pages and Register on Piazza
First programming assignment available now
More details in discussion next Wednesday
Due Monday 9/16
Lab hours in CS instructional lab for help from TAs and Peer Mentors
Welcome to CS 537!