Module 2 Flashcards

1
Q

A _______ is a program in execution.

A

Process

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

True or False.
A program is an active entity while a process is a passive entity.

A

False
(a program is a PASSIVE entity while a process is an ACTIVE entity)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

True or False.
A computer system consists of a collection of processes.

A

True

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

True or False.
User processes execute system code. Operating system processes execute user code.

A

False
(OPERATING SYSTEM processes execute SYSTEM code, USER processes execute USER code)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

True or False.
Several processes within different programs are considered separate execution sequences.

A

False
(several processes within THE SAME program)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

True or False.
All processes can execute concurrently with the CPU multiplexing among them (time sharing).

A

True

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

A ________ is a cycle of CPU execution (CPU burst) and I/O wait (I/O burst) that alternates between these two states.

A

Process

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

True or False.
Process execution begins with an I/O burst then a CPU burst and so on.

A

False
(begins with a CPU BURST then an I/O BURST)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

The last CPU burst will end with a ___________ to terminate execution.

A

System Request

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

_______- are written and becomes a process when executed/loaded into memory.

A

Programs

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

A process can be divided into four sections. What are these sections?

A

(SHT Damn)
- Stack
- Heap
- Text
- Data

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

This section contains the temporary data such as function parameters, return address and local variables.

A

Stack

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

This section is dynamically allocated memory to a process during its run time.

A

Heap
(dynamically allocated memory)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

This section includes the current activity represented by the value of Program Counter and the contents of the processor’s registers.

A

Text

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

This section contains the the code.

A

Text

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

This section contains the global and static variables.

A

Data

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

True or False.
As a process executes, it changes states.

A

True

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

In this state, the process is being created.

A

New

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

In this state, the process is waiting for the OS to assign a processor to it.

A

Ready

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

In this state, the process has finished execution.

A

Terminated

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

Each process is represented in the operating system by a ________________.

A

Process Control Block (PCB)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

In this state, the process is waiting for some event to occur (such as an I/O completion).

A

Waiting

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

In this state, the CPU is executing its instructions.

A

Running

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

This is also known as a task control block.

A

Process Control Block (PCB)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
It is the repository of information of a process.
Process Control Block (PCB)
23
What are the parts of the process control block?
- Process State - Program Counter - CPU Registers - CPU Scheduling Information - Memory Management Information - Accounting Information - I/O Status Information
24
This part of the process control block indicates the address of the next instruction to be executed.
Program Counter
24
This part of the process control block include accumulators, index registers, stack pointers, and general-purpose registers, plus any condition-code information.
CPU Registers
25
This part of the process control block process priority, pointers to scheduling queues, and scheduling parameters.
CPU Scheduling Information
25
This part of the process control block along with the program counter, must be saved when an interrupt occurs to allow the process to continue.
CPU Registers
26
This part of the process control block contains information on limits registers or page tables.
Memory Management Information
27
This part of the process control block contains the amount of CPU and real time used, time limits, account numbers, job or process numbers.
Accounting Information
28
This part of the process control block contains the I/O requests, I/O devices allocated, a list of open files.
I/O Status Information
29
True or False. The processes in the system cannot execute concurrently or multitasked on a CPU.
False (CAN execute concurrently)
30
A process may create new processes via create process system call during execution. The creating process is the __________ whereas the new processes are the ______________.
Parent Process / Children or Sub-process
31
True or False. The sub-process may obtain resources directly from the OS or use a subset of the resources of the parent process (Inheritance).
True
32
True or False. Restricting a child process to a subset of the parent's resources prevents any process from overloading the system by creating too many processes.
True
33
True or False. When a process creates a new process, either: The parent continues to execute concurrently by itself. The parent waits until all its children have terminated.
False (continues to execute concurrently WITH ITS CHILDREN)
34
A process terminates when it finishes its last statement and asks the operating system to delete it using the _____________.
Exit System Call
35
True or False. A parent may terminate the execution of one of its children when: 1. The child has exceeded its usage of some resources it has been allocated. 2. The task assigned to the child is no longer required. 3. The parent is exiting, and the OS terminates the all its children.
True
36
True or False. The concurrent processes may be independent processes or cooperating processes.
True
37
A process is ________- if it cannot affect or be affected by other processes or does not share any data.
Independent
38
An independent process is ________, meaning the result of the execution depends solely on the input state.
Deterministic
39
An independent process is ________ meaning the result of the execution will always be the same for the same input.
Reproducible
40
True or False. An independent process' execution cannot be stopped and restarted without causing ill effects.
False (CAN BE stopped and restarted without causing ill effects)
41
A process is _________ if it can affect or be affected by other processes or share data.
Cooperating
42
True or False. The results of a cooperating process' execution cannot be predicted in advance, since it depends on relative execution sequence.
True
43
True or False. The results of a cooperating process' execution is nondeterministic since it will not always be the same for the same input.
True
44
True or False. Concurrent execution of cooperating process must have processes communicate and synchronize their actions.
True
45
The objective of multiprogramming is to have some process running at all times, to ________.
Maximize CPU utilization
46
True or False. Multiprogramming also decreases throughput, which is the amount of work the system accomplishes in a given time interval.
False (multiprogramming also INCREASES throughput)
47
The idea of multiprogramming is if one process is in the waiting state, then another process which is in the ready state goes to the _______.
Running state
48
A _______ consists of all processes that enters a system.
Job Queue
49
A _______ consists of processes residing in the memory ready and waiting to execute.
Ready Queue (waiting to execute)
50
A process migrates between various scheduling queues and the OS must select processes with an appropriate _______.
Scheduler
51
__________ selects processes from the secondary storage and loads them into memory for execution.
Long-term Scheduler
52
The long-term scheduler is also known as the "_______".
Job Scheduler
53
True or False. The long-term scheduler executes much more frequently.
False (the long-term scheduler executes much LESS frequently)
54
True or False. There may be minutes between the creation of new processes in the system when using a long-term scheduler.
True
54
True or False. The long-term scheduler controls the degree of multiprogramming – the number of processes in memory.
True
54
True or False. The long-term scheduler can take less time to select a process for execution.
False (the long-term scheduler can take MORE time to select a process for execution)
54
_______ selects process from the ready queue, and allocates the CPU to one of them.
Short-term scheduler
55
The short-term scheduler is also known as the "_______".
CPU Scheduler
56
True or False. The short-term scheduler must select a new process more frequently.
True
57
True or False. A process may execute for a few seconds before waiting for an I/O request.
False (ONLY A FEW MILLISECONDS)
58
True or False. The short-term scheduler must be very fast.
True
59
____________ removes (swaps out) certain processes from memory to lessen the degree of multiprogramming when thrashing occurs.
Medium-term scheduler
60
True or False. In a medium-term scheduler the process can be reintroduced into memory and its execution can be continued where it left off, this scheme is called cycling.
False (this scheme is called SWAPPING)
61
This refers to the CPU being switched from one process to another.
Context Switch
62
True or False. Context-switch time is pure overhead, because the system does no useful work while switching and should therefore be minimized.
True
63
Whenever the _______ becomes idle, the OS or CPU scheduler must select a process in the ready queue for execution.
CPU
64
True or False. CPU scheduling decisions may take place under three circumstances.
False (may take place under FOUR circumstances)
65
Preemptive or Non-preemptive? Switches from running state to waiting state.
Non-Preemptive
66
Preemptive or Non-preemptive? Switches from running state to ready state.
Preemptive
66
Preemptive or Non-preemptive? Switches from waiting state to ready state.
Preemptive
67
Preemptive or Non-preemptive? When a process terminates.
Non-Preemptive
68
In __________ scheduling, the process keeps the CPU until it terminates or switches states. No process is interrupted until it is completed.
Non-preemptive
69
In ____________ works by dividing time slots of CPU to a given process. The time slot given might be able to complete the process or not be able to. This scheduling is used when the process switch to ready state.
Preemptive scheduling
70
___________ measures how busy is the CPU. CPU utilization may range from 0 to 100 percent.
CPU Utilization
71
__________ is the amount of work or jobs completed in a unit of time.
Throughput
72
____________- measures how long it takes to execute a process. It is the interval from the time of submission to the time of completion.
Turnaround Time
73
____________ is the time a job waits for resource allocation. It is the total amount of time a process spends waiting in the ready queue.
Waiting Time
74
____________ is the time from the submission of a request to the first response. It is not the time that it takes to output that response.
Response Time
75
True or False. A good CPU scheduling algorithm maximizes CPU utilization and throughput and minimizes turnaround time, waiting time and response time.
True
76
True or False. It may be better to maximize the minimum response time.
False (MINIMIZE the MAXIMUM response time)
77
True or False. For interactive systems (time-sharing systems), minimizing the variance in the response time is less important than averaging response time.
False (minimizing the variance in the response time is MORE important than averaging response time)
78
True or False. A reasonable and predictable response may be more desirable than a variable response time.
True