Introduction
Tom Kelliher, CS 325
Jan. 28, 2009
Read Chapter 1.
- Syllabus.
- A ``grand tour:'' OS and system views, structure, and operation.
Continued ``grand tour.''
- Objectives:
- Study operating system design.
- Understand threads and concurrency: Banking example.
- Appreciate connections to other areas of computer science.
- C refresher project.
- Internet resources.
- Linux internals project orientation.
- Class preparation.
- (Doubtful) Possibilities for Other topics: deadlock, distributed systems, security and protection.
An OS's responsibilities boil down to managing:
(Process = running program. Separate address spaces. Threads share an
address space.)
- Top-down view: virtual machine abstraction -- convenient ``user''
interface. Abstractions: files, applications. I/O devices integrated into
filesystem.
- Bottom-up view: management of real resources: CPU cycles, memory, disk
space, device allocations.
- Secondary concerns: efficiency, fairness.
Abstractions:
- Multiprogramming, protection and security.
Threads.
- Virtual memory.
- File systems.
- Virtualization.
- Kernel. Static. Process/thread, memory, I/O management and access.
Timers.
- Daemons. Provide additional services.
- System applications: compilers, linkers, loaders.
- User applications: shells, windowing systems, browsers, editors,
etc.
The ``Hello world'' program:
- Compiled into assembly code.
- Assembled in machine code.
- Written to a file.
- Loaded into memory.
- Linked against system libraries.
- Executes.
- Makes supervisor calls to access I/O devices through OS.
- CPU, memory, I/O devices block diagram.
I/O device bandwidth/latency differences.
Process execution within this context. Data/code locality: caches. VM.
DMA.
- Single CPU, multiple CPU chips, multiple cores, hyperthreading.
(Phoenix: eight ``CPUs.'')
Why can't we just turn up the clock?
Efficiencies with multiple cores vs. multiple CPU chips.
Programming consequences.
- Process, do I/O, repeat model.
- Memory hierarchy. Speed, density, cost, volatility.
- I/O architecture. Abstract models, device drivers, devices.
Plug'n'play/pray.
- Multiprogramming.
Mental memory model:
Timesharing vs. batch.
Short-term, long-term schedulers.
Physical, virtual memory. Swapping.
- Interrupt driven kernel operation.
Dual (or more) CPU modes: user, kernel modes. Privileged operations and/or
I/O spaces.
Interrupts, traps. Hardware timers.
Thomas P. Kelliher
2009-01-27
Tom Kelliher