vault backup: 2025-03-10 10:45:13

This commit is contained in:
Marco Realacci 2025-03-10 10:45:13 +01:00
parent 4f3268bda9
commit 92174244e8
2 changed files with 18 additions and 5 deletions

View file

@ -255,4 +255,18 @@ unlock(i) :=
![[Pasted image 20250310103703.png]]
so by this, the very worst possible case is that my lock experiences that.
It looks like I can experience at most $2n-1$ other critical sections, but it is even better, let's see:
It looks like I can experience at most $2n-1$ other critical sections, but it is even better, let's see:
...
#### Improvement of Aravinds algorithm
```
unlock(i) :=
∀j≠i.if DATE[j] > DATE[i] then
DATE[j] <- DATE[j]-1
DATE[i] <- n STAGE[i] <- 0
FLAG[i] <- down
```
Since the LOCK is like before, the revised protocol satisfies MUTEX. Furthermore, you can prove that it satisfies bounded bypass with bound n-1 -> EXERCISE!