Quiz# 2: Synchronization
1. In a uniprocessor environment, disabling interrupts is a perfect solution for avoiding race conditions.
True
False
2. A process cannot be switched out if it is executing in its critical section.
True
False
3. A process waiting for a semaphore, upon being signalled, immediately gets the CPU.
True
False
4. What could happen if processes are added and removed from the semaphore queue in a LIFO (last in, first out) order?
Last process in the queue gets the semaphore
First process in the queue gets the semaphore
Indefinite blocking
Last process in the queue does not release the semaphore
5. The Test and Set synchronization primitive is
A variable that the user tests and sets
Is not atomic
Is a hardware solution to the synchronization problem