Chapter 21 Flashcards

1
Q

What is CS

A

Critical Section

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

Does bakery algorithm satisfies all 3 requirements
1- Mutual exclusion
2- Progress
3- Bounded-waiting

A

Yes

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

Does bounded waiting follows FCFS

A

Yes

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

Does hardware-based solutions are related to hardware

A

No. It is related to CPU instructions

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

The access to memory location excludes other access to same memory location. It is normal for hardware solutions. What is extension in hardware solutions

A

Designers have proposed machine instructions that perform two operations atomically (indivisbly) on same memory location (e.g. reading and writing) (it means 2 operations in single instruction)

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

What TSL/Read Modify Write instruction do

A

Test-and-set instruction. test and modify a word atomically.

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

What is swap instruction

A

It swaps 2 variables. It plays with key and lock. It turns key value false and lock true and vice versa to perform operation.

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