What's An OS?
What's An OS?
An OS is just a program:
It has a main() function, which gets called only once (during boot)
Like any program, it consumes resources (such as memory), can do
silly things (like generating an exception), etc.
But it is a very strange program:
It is “entered” from different locations in response to external events
It does not have a single thread of control, it can be invoked
simultaneously by two different events (e.g. sys call & an interrupt)
It is not supposed to terminate
It can execute any instruction in the machine
Control Flow in an OS
From boot
main()
System call
Initialization Interrupt
Exception
Idle
Loop
Operating System Modules
RTI
General OS Structure
Monolithic
App App App Structure. e.g. UNIX
API
Security Service
Module Module
Each API
module Process Network Object
File Memory
has a well Manager Support Support
Systems Manager
defined
interface
Kernel: M/C dependent basic implementations