OS Part 3 (Inter Process Communication) Flashcards

1
Q

How does the kernel facilitate communication between processes?

A

Kernel sets up shared memory (distinct location from processes own memory) so that processes can both read input/output from each other.

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

What is the “critical region”?

A

Any time a process is actively accessing shared memory.

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

What are the 4 conditions needed to allow processes to communicate with one another correctly and efficiently?

A
  1. No two processes simultaneously in their critical
    regions.
  2. No assumptions made about number or speed of
    CPU(s)
  3. No process outside a critical region may block
    another process.
  4. No process should wait forever to enter its critical
    region.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is the “critical region”?

A

Any time a process is actively accessing shared memory.

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

What is “busy waiting”?

A

When a process takes up CPU resources by constantly checking (e.g infinite while loop) if it can access shared data.

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

What three values are tracked with Dijkstra’s Semaphores?

A
  1. “Full”, which counts the number of slots that are in use.
  2. “Empty”, which counts the number of slots that are free.
  3. “Mutex”, which guards the buffer ensuring mutual exclusion.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly