. please consider the following mutual exclusion algorithm that uses the shared variables y1 and y2 (initially both 0). process p1: while true do . . . noncritical section . . . y1 := y2 + 1; wait until (y2 = 0) ? (y1 < y2) . . . critical section . . . y1 := 0; od process p2: while true do . . . noncritical section . . . y2 := y1 + 1; wait until (y1 = 0) ? (y2 < y1) . . . critical section . . . y2 := 0; od please answer following questions: a) give the program graph representations of both processes. (a pictorial representation suffices.) b) give the reachable part of the transition system of p1 || p2 where y1 ? 2 and y2 ? 2. c) describe an execution that shows that the entire transition system is infinite. d) check whether the algorithm indeed ensures mutual exclusion. e) check whether the algorithm never reaches a state in which both processes are mutually waiting for each other. f) is it possible that a process that wants to enter the critical section has to wait ad infinitum?
Get the answer

Category: mechanicalengineering |
Author: Sagi Boris

## Related Questions

##### . point c is on line segment ab so the ratio of ac to cb is 1 to 3.

##### . por fin.(poder) descansar!(levantarse) al mediodia.(ponerse) un pant

##### . prepare any journal entries, adjusting journal entries, and closing

## Category

## art

. problems and applications q7 consider a monopolistically competitive market with n firms. each firm's business opportunities are described by the fo

## statistics

. provide a one-paragraph summary of the key issues as you see them in this case. 2. how would you describe rinaldi's influence tactics? cite at least

## statistics

. póngase acento a todas estas palabras esdrújulas. 1. algera 2. barbaro 3. cientifico 4. discipulo 5. examenes 6. fabrica 7. heroe 8. indice 9. kilo