Professional Documents
Culture Documents
Introduction to OS
"
Introduction to OS
Introduction to OS
Workstation:
"
"
Computer with little (or no) user view: embedded home devices.
"
Introduction to OS
OS is a resource allocator.
"
"
OS is a control program.
"
"
Introduction to OS
OS is
"
"
Computer-system operation:
"
"
10
Introduction to OS
"
11
"
"
Introduction to OS
"
"
13
Interrupt Mechanism
!
The CPU hardware has a wire called the interrupt-request line that the
CPU senses after executing every instruction.
When the CPU detects that a controller has asserted a signal on the line,
the CPU performs a state save and transfers control to a generic routine.
The generic routine examine the interrupt information and calls the
interrupt-specific handler.
" Polling all the devices to see which one raised the interrupt.
14
Introduction to OS
15
Note:
"
"
16
Introduction to OS
Interrupt Timeline
17
Example of Interrupt
P1
I/O devices and the CPU can
execute concurrently
I/O operations
(read)
I/O ready to
transfer data
I/O
device
Interrupt
handler
Time sharing
time
Introduction to OS
P2
Point of
interruption
Resume the
interrupted
process
(or multitasking)
18
Storage Structure
!
Registers:
"
"
Main memory:
"
"
19
20
Introduction to OS
10
Impossible!!
#
21
expensive
nonvolatile
slow
Introduction to OS
cheap
22
11
I/O Structure
!
23
24
Introduction to OS
12
25
"
"
"
"
26
Introduction to OS
13
27
Benefit:
#
#
28
Introduction to OS
14
But can produce high overhead when used for bulk data
movement (e.g., disk I/O).
"
"
29
30
Introduction to OS
15
31
Single-processor systems:
"
"
32
Introduction to OS
16
Multiprocessor Systems:
"
"
Main advantages:
"
"
Increased throughput:
$ We expect to get more work done in less time.
$ The speed-up ratio with N processors is not N,
however; rather, it is less than N.
$ A certain amount of overhead is incurred in keeping
all the parts working correctly.
33
Main advantages:
# Economy of scale:
$
Increased reliability:
$
34
Introduction to OS
17
"
Symmetric multiprocessing
#
(SMP):
36
Introduction to OS
18
Clustered Systems:
"
"
"
"
"
38
Introduction to OS
19
User cannot keep CPU and I/O devices busy at all times.
#
"
39
Multiprogramming:
"
"
"
"
"
"
40
Introduction to OS
20
41
"
42
Introduction to OS
21
Since main memory is too small to accommodate all jobs, the jobs
are kept initially on the disk in the job pool.
"
Job scheduling (chapter 5) selects jobs from the pool and loads
them into memory for execution.
43
44
Introduction to OS
22
45
Operating-System Operations
!
46
Introduction to OS
23
"
"
47
Dual-Mode Operation
!
"
"
"
"
48
Introduction to OS
24
49
"
50
Introduction to OS
25
"
"
"
"
51
52
Introduction to OS
26
Process Management
!
Process:
"
A program in execution.
"
!
!
53
54
Introduction to OS
27
Memory Management
!
"
55
8 and 9).
"
"
56
Introduction to OS
28
Storage Management
!
57
File-System Management
!
Introduction to OS
29
Mass-Storage Management
!
OS activities:
"
"
"
Free-space management.
Storage allocation.
Disk scheduling.
59
Tertiary storage:
"
"
"
60
Introduction to OS
30
Caching
!
Caching (contd)
!
Introduction to OS
31
Caching (contd)
!
"
63
Caching (contd)
!
In multitasking environments:
"
In multiprocessor environment:
"
"
"
each process (has its memory space) must obtain the most
recently updated value of A.
64
Introduction to OS
32
I/O Subsystem
!
"
"
65
66
Introduction to OS
33
67
Distributed Systems
!
Network:
"
"
"
68
Introduction to OS
34
Special-Purpose Systems
!
Embedded Systems:
" A special-purpose computer system designed to perform
one or a few dedicated functions.
# E.g., robotic arms.
" Usually have little or no user interface.
" Almost run real-time operating systems.
# Rigid time requirements have been placed on the operation
of a processor or the flow of data.
Multimedia Systems:
" A recent trend in technology is the incorporation of
multimedia data into computer system.
" Different from convention data, multimedia data must be
delivered according to a certain time restrictions.
" Chapter 20 explores the nature of multimedia data and the
design of operating systems that support the multimedia.
69
Handheld Systems:
"
"
70
Introduction to OS
35
Office environment:
"
"
Now:
#
Home networks:
"
"
Now:
#
#
"
72
Introduction to OS
36
"
73
74
Introduction to OS
37
75
Introduction to OS
38