chapter 4 - The Abstraction: The Process Flashcards

1
Q

What is a process?

A

Running a program

A process is the execution of a program that includes its machine state and memory compromises.

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

machine state

A

What a program can read or update when it is running

The machine state includes all the information needed to resume the program’s execution.

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

What are ‘memory compromises’ in the context of a process?

A

Process

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

What is the role of registers in a process?

A

They are important for the execution of the process as many instructions explicitly read or update them

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

stack pointer/frame pointer

A

manage the stack for a function parameters, local variables and return address

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

What types of storage do programs often access?

A

Persistent storage devices

Persistent storage devices include hard drives, SSDs, and other forms of long-term data storage.

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

What is a register

A

Registers are small storage locations within the CPU that hold data temporarily

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

what is the create operation in the process API

A

creates a new process to run a program when you type a command or open an app

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

what is the destroy operation in the process API

A

forcefully kill a process that is no longer needed or is misbehaving

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

what is the wait operation in the process API

A

allows a program to wait for another process to finish execution

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

What does miscellaneous control allow in process management

A

method to suspend a process (stop it from running for a while) and then resume it (continue it running)

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

What does the status API do in process management?

A

Provides information about the process, such as runtime and current state

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

What must the OS do to run a program as a process?

A

Load the program’s code and static data into memory (address space)

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

eager loading

A

loading process is done all at once before running the program

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

lazy loading

A

loading pieces of code or data only as they are needed during program execution

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

heap

A

For dynamic memory allocation (e.g., linked lists, hash tables) via malloc().

17
Q

What does it mean if a process is in the Running state?

A

It is currently executing instructions on the CPU

18
Q

Ready state?

A

ready to run, but the OS has not scheduled it to run at that moment

19
Q

process is Blocked?

A

waiting for an event (e.g., I/O) and cannot run until that event completes

20
Q

zombie process?

A

A data structure tracking all ready processes and the one currently running

21
Q

What is register context used for?

A

It’s used to store the CPU register values of a process when it’s not running