# Tagged Questions

Questions about the concurrency-control requirement of ensuring that no two processes are simultaneously in a critical section (a period when the process is accessing a shared resource). Failing to achieve mutual exclusion leads to the problem of data races.

0answers
33 views

### Deadlock free process calculi

So when programming with locks as a synchronization primitives you can ensure no deadlock by ensuring that an ordering exists on the locks and that all acquires of the locks happen in that order (...
0answers
56 views

### Orient edges in a mixed graph to minimize the critical path

A mixed graph is a graph that has directed and undirected edges. Is there an efficient algorithm that allows the orientation of undirected edges in a mixed graph in such a way that no cycle is ...
1answer
92 views

### Lamport's Bakery algorithm

I have problems understanding Lamport's bakery algorithm. The thing I do understand is that each thread ask all other threads what number they have.Then the thread takes the maximum number and add 1 ...
0answers
44 views

### Lamport's Bakery algorithm with other > relation

i'm reading an old exam and one question was: Which property of the Bakery algorithm is violated with the following change? ...
1answer
30 views

### Confusion in the solution to first readers-writers synchronization

I am studying the solution to “First Readers-Writers Problem” from the book Operating System Concepts (9th edition) and it describes: First readers–writers problem, requires that no reader be kept ...
0answers
90 views

### Proof of Manna-Pnueli algorithm for mutual exclusion being incorrect

Suppose we have the Manna-Pnueli algorithm for mutual exclusion: I was trying to find a sequence that violates mutual exclusion and I came up with this: ...
2answers
52 views

### Help understanding this algorithm that's supposed to solve the critical section problem through mutual exclusion

Our professor gave us the following algorithm that's supposed to solve the critical section problem. I'm guessing the code is just pseudocode so I'm not trying to focus on the strange syntax and just ...
1answer
58 views

2answers
794 views

### Does Peterson's 2-process mutual exclusion algorithm account for dying processes?

I think that in Peterson's algorithm for mutual exclusion, if the process first to enter the critical section were to die or be cancelled, the other process would loop forever, waiting to enter the ...