Download Operating System Overview - Operating Systems - Lecture Slides and more Slides Computer Science in PDF only on Docsity!
Operating Systems
Lecture 04:
Operating System Overview
Today
- Announcements:
- Operating Systems Overview:
- Main concepts in OS
- OS structure
- Virtual Machines
- Windows vs. Unix vs. Linux: study cases
Process
- Fundamental to the structure of operating systems
- Many definitions have been given , including
- A program in execution
- An instance of a program running on a computer
- The entity that can be assigned to and executed
on a processor
- A unit of activity characterized by a single
sequential thread of execution, a current state,
and an associated set of system resources
Development of the Process
Three major lines of computer system development created
problems in timing and synchronization that contributed to the
development of the process concept:
- processor is switched among the various programs residing in main memory
multiprogramming batch operation
- be responsive to the individual user but be able to support many users simultaneously
time sharing
- a number of users are entering queries or updates against a database
real-time transaction systems
Components of
a Process
- The execution context is essential: - it is the internal data by which the OS is able to supervise and control the process - includes the contents of the various process registers - includes information such as the priority of the process and whether the process is waiting for the completion of a particular I/O event
- A process contains
three components:
- an executable program
- the associated data needed by the program (variables, work space, buffers, etc.)
- the execution context (or “process state”) of the program
Process Management
The entire state of the
process at any instant is
contained in its context
New features can be
designed and incorporated
into the OS by expanding
the context to include any
new information needed to
support the feature
Virtual Memory
• A facility that allows programs to address
memory from a logical point of view, without
regard to the amount of main memory physically
available
• Conceived to meet the requirement of having
multiple user jobs reside in main memory
concurrently
Paging
- Allows processes to be comprised of a number of fixed-
size blocks, called pages
- Program references a word by means of a virtual address
- consists of a page number and an offset within the page
- each page may be located anywhere in main memory
- Provides for a dynamic mapping between the virtual
address used in the program and a real (or physical)
address in main memory
Virtual Memory
Addressing
Key Elements for
Resource Scheduling
Microkernel Architecture
• Assigns only a few essential functions to the
kernel:
– The approach:
address spaces
interprocess communication (IPC)
basic scheduling
simplifies implementation
provides flexibility
is well suited to a distributed environment
Multithreading
- Technique in which a process, executing an application, is
divided into threads that can run concurrently
Thread
- dispatchable unit of work
- includes a processor context and its own data area to enable subroutine branching
- executes sequentially and is interruptible Process
- a collection of one or more threads and associated system resources
- programmer has greater control over the modularity of the application and the timing of application related events
SMP Advantages
Performance
more than one process can be running simultaneously, each on a different processor
Availability failure of a single process does nothalt the system
Incremental Growth
performance of a system can be enhanced by adding an additional processor
Scaling
vendors can offer a range of products based on the number of processors configured in the system
Multiprogramming vs.
Multiprocessing