Two atomic operations permissible on semaphores are ________ and ________.
Pick an option to check yourself, or open the answer below.
Show answer & explanation
Correct answer: D. wait, signal
Explanation
A semaphore supports exactly two atomic operations in the classical Dijkstra definition: wait() (also written P or down), which decrements the semaphore and blocks the caller if the value goes negative, and signal() (also written V or up), which increments the semaphore and may wake a waiting process. 'Stop' and 'hold' are not standard semaphore operations in any textbook definition. Therefore the correct pair is wait, signal, option (iv).More Computer System Architecture questions
- Three processes share a single counting semaphore S whose initial value is 1. All three execute wait(S) one after another, in the order P2,…
- In the UNIX operating system, when a process creates a child process using the fork() system call, which of the following is genuinely shar…
- A system has 12 instances of a resource R shared among four processes. The maximum need and current allocation of each process are: Process…
- Match List I with List II
- The write operation in I/O operation does the following-
- Which of the following gates do not give output 1 when both the inputs are 0 - A. NAND gate B. NOR gate C. X-OR gate D. X-NOR gate