![]() |
|
[C] precedence graph with semaphores - Printable Version +- Hack Forums (https://hackforums.net) +-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444) +--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151) +---- Forum: Software Development (https://hackforums.net/forumdisplay.php?fid=118) +---- Thread: [C] precedence graph with semaphores (/showthread.php?tid=6128585) |
precedence graph with semaphores - georgeziozas - Dec 20, 2020 🙃Hey there, I am working on system programming for the last weeks, and I'm trying to grasp some major concepts. I am writing C in Linux OS. P1 process code: Code while(true){P2 process code: Code while(true){P3 process code: Code while(true){I have achieved to use P and V semaphores to print PIZZA once with the code below: Code var Σ12, Σ13, Σ23: semaphores;What if I want to use the same 3 semaphores to print : Code PIZZAPIZZAPIZZAPIZZA.......Thanks in advance. ✌ |