Lecture: OS overview
Class structure
- relations to prereq
- 351: OS concepts
- 333: how to write applications that use the OS
- this course: how to write an OS
- goals
- understand low-level systems
- learn to work with systems software: reading code/manuals, debugging, etc.
- two OSes
- xv6 (exercises): a Unix-style OS on x86
- JOS (labs): an exokernel-style OS on x86
- structures
- lectures: basic/more modern concepts
- sections: help you with exercises/labs
- final exam: open book/notes/laptop; no Internet or other communication
- textbooks & Intel/AMD manuals
- see the course website on grades & policies
- the first xv6 exercise: start now!
- Lab 1 will be released soon
- systems research at UW
Overview
- what’s an OS / why do we need an OS
- a reusable library
- a set of programming abstractions
- a mediator between applications/hardware
- concerns: safety, performance, scalability
- the PC hardware
- example: IBM T42
- abstract model:
CPU, Memory, and I/O
- CPU interprets instructions: IP (Instruction Pointer) to memory
- memory stores instructions and data
- I/O to external world: memory-mapped I/O & port I/O
- in this class we use QEMU to emulate the PC
- concepts apply to non-x86 architectures
- how does printing “hello” work on this PC?
- example: a tiny hello “kernel” (tar and source code)
- run
make qemu
- VGA text buffer at physical memory address
0xb8000
- one byte for character, one byte for attribute
- memory-mapped I/O:
0xb8000
+ (row * 80 + column) * 2;
- talk to devices through memory address space
- will see more examples in later labs
- perhaps the lowest-level “hello world” you have seen so far
- what if we have two applications trying to print?
- question to think: what happens when you enter a URL in your browser
- client side / server side
- will have a better idea at the end of this quarter
- a brief history