Chapter 1: Introduction Flashcards
What is an operating system?
A program that manages a computer’s hardware. It also provides a basis for application programs and acts as an intermediary between the computer hardware.
Caching
copying information into faster storage system. main memory can be viewed as a last cache for secondary storage.
What is dual mode?
operation allows operating system to protect itself and other system components.
What is a trap?
generated interrupt caused either by an error or a user request. stops normal execution.
What is the kernel?
“The one program running at all times on the computer”
Goals of Operating System
Execute user programs and make solving user problems easier.
Make the computer system convenient to use
Use the computer hardware in an efficient manner
Resource allocator
manages and allocates resources
Control program
controls the execution of user programs and operations of I/O devices
Process
An executing program
Resource
Anything that is needed for a process to run:
Memory
Space on a disk
The CPU
Storage systems organized in hierarchy
Speed
Cost
Volatility
volatile storage
loses its
contents when the power to the device is removed
Solid-state disks
have several variants but in general are faster than
magnetic disks and are nonvolatile
What are two tasks that an operating system is responsible for from the perspective of the computer?
Manages resource allocation, execution of program and hardware.
From the perspective of the computer, what is the purpose of the operating system?
resource management and controlling programs.
What are methods of parameter passing that are used in an invocation of a system call?
table
registers
stack
Space-multiplexed
sharing is the division of a resource into two or more distinct units and then the allocation of the individual units to processes.
Time-multiplexed
sharing is when one process can use the entire resource for a period of time and then another process uses it at a later time.
Timesharing (multitasking)
is logical extension in which CPU switches jobs so frequently that users can interact with each job while it is running, creating interactive computing
Response time should be < 1 second
Each user has at least one program executing in memory process
If several jobs ready to run at the same time CPU scheduling
If processes don’t fit in memory, swapping moves them in and out to run
Virtual memory allows execution of processes not completely in memory
What are the two types of isolated sharing that is practiced by the operating system when multi-programming is in use? Provide an example of each type.
Time-multiplex: library book
space-multiplex: parking lot
What does it mean to say that the operating system is in dual mode and what is the purpose of dual mode?
operation allows operating system to protect itself and other system components. Uses user mode and kernel mode. Also uses interrupts and traps.
How does the operating system protect itself from erroneous application program behavior?
Dual mode operation protects it.
What is the purpose of a cache? Where is it usually in the memory hierarchy?
copying information into faster storage system; main memory can be viewed as a last cache for secondary storage.
Below registry and above main memory.
Main memory
is usually too small to store all needed programs and data permanently. a volatile storage device that loses its contents when power is turned off or otherwise lost.
Bootstrap program
is loaded at power-up or reboot
Typically stored in ROM or EEPROM, generally known as firmware
Initializes all aspects of system
Loads operating system kernel and starts execution
What is the difference between a program and a process?
A process is the way the program itself is executed.