Chapter 3 Flashcards
Describe how the OS manages application execution
Resources are made available to multiple applications.
The processor is switched among multiple applications so all will appear to be progressing.
What are the two essential elements of a process?
- The program code
- The set of data associated with that code
What are the two process states?
- Trace, list of instructions that execute for that process.
- Dispatcher, which switches the processor from one process to the other.
What are the 4 reasons for process creation/
- A new batch job
- Interactive logon
- Created by the OS to provide a service
- Spawned by existing process
Give 4 reasons for process termination.
- Time limit exceeded.
- Not enough memory
- Invalid instruction
- Privileged instruction
What are 4 characteristics of a suspended process?
- The process isn’t immediately avaialble for execution
- The process may or may not be waiting on an event. if it is, then it is blocked/suspended. Otherwise it is ready/suspended. It is important to note that it is suspended regardless if it’s waiting for an event or not.
- The process was suspended by an agent: itself, it’s parent process or the OS itself for the purpose of preventing its execution.
- The process may not be removed from this state until the agent explicitly orders the removal.
What are some reasons for a process getting suspended?
- Swapping
- Other OS reason
- Interactive user request
- Timing
- Parent process request
What is a memory table used for?
Used to keep track of both main and secondary memory
What are I/O tables used for?
- Used by the OS to manage the I/O devices and channels of the computer system
What are process control structures?
- Data structure which stores:
- Where the process is located in memory
- Attributes of the process that are necessary for its management
- These are contained in the process control structure
What are the 3 ways to identify a process?
- Identifier of this process
- Identifer of the process that created this process (parent process)
- User identifier
What are the typical elements of a process image?
- User data
- User program
- Stack
- Process Control Block
What is the process control block?
The process control block is an important data structure which holds information such as:
- Process identifier
- Process state
- Process priority
- Program Counter
- Memory pointers
- Context data
- I/O status information
- Accounting information
When a new process is created, what state is it in?
The process would be in a “not running” state.
The process only runs until dispatched.
What are the two modes of execution?
- User mode, which is the less priviledged mode. User programs typically execute in this mode.
- System mode, which is a more privileged mode.