Overview
This is a program that acts as an intermediary between a user and the hardware. It makes general purpose computing much easier, but is not needed in embedded systems.
It consists of two different views, the user and system view, both of which aim to solve different problems.
User View
It provides the following conveniences:
- Easier to write programs (abstraction over hardware)
- Easier to run programs (loading program, program state, stopping program)
- More powerful instructions than the ISA
- Multi user operation (resource management, security, performance, fairness)
The following services can be provided to a user in an OS:
- User interface (GUI, CLI, Touch Screen)
- Program execution (load, run, end program)
- I/O interfacing
- File system manipulation
- Inter-process communication (IPC)
- Error detection (hardware faults, I/O errors, user errors)
The goals of the user view are:
- Convenience (to the user)
- Ease of use/learning
- Reliable
- Fast
- Safe
System View
The following services are run on an OS to manage the system.
- Resource allocation (memory, files, CPU time, I/O devices)
- Accounting (keep track of system resource usage)
- Protection & Security (from users, outside the system)
The goals of the system view are:
- Ease of design
- Ease of implementation
- Ease of maintenance
- Flexible
- Reliable
- Error-free
- Efficient
Topics
The OS prevents applications from crashing into each other by using address space protection. This limits the address ranges of memory the process is allowed to touch.
The OS prevents applications from crashing into itself with dual-mode operation. This involves two different modes user and kernel mode. To run some privileged instructions the user has to make a request to the kernel to run some operation.