0 votes 0 votes How the processes are removed from the Semaphore suspended queue?Is it implementation dependent or is it FIFO always?If not FIFO then how starvation will be handled.I got this doubt while reading following paragraph from williams stallings Chapter -5[Concurrency] The question arises of the order in which processes are removed from such a queue. The fairest removal policy is first-in-first-out (FIFO): The process that has been blocked the longest is released from the queue first; a semaphore whose definition includes this policy is called a strong semaphore . A semaphore that does not specify the order in which processes are removed from the queue is a weak semaphore Where will this definiton fits if we use some other scheduling algorithm rather than FIFO?Says if I use Priority based/SJf..etc ,then it will neither be strong semaphore nor weak semaphore?# Please clarify Operating System operating-system process-synchronization algorithms semaphore + – rahul sharma 5 asked Dec 4, 2016 rahul sharma 5 3.4k views answer comment Share Follow See 1 comment See all 1 1 comment reply Shubhanshu commented Oct 23, 2017 reply Follow Share Strong semaphores guarantee avoiding starvation. What if a system goes into deadlock, then each and every process participating in the deadlock have to starve forever. Ryt?? 0 votes 0 votes Please log in or register to add a comment.
0 votes 0 votes as far as i know,any random process can be waked up from the suspended list.FIFO is not used.hence,starvation can occur Akriti sood answered Dec 4, 2016 Akriti sood comment Share Follow See 1 comment See all 1 1 comment reply joshi_nitish commented Oct 23, 2017 reply Follow Share @Akriti sood depends on whether hard or soft semaphore are used, if hard semaphore used, then FIFO is used for waking process, else if soft semaphore are used, random selection is used... 0 votes 0 votes Please log in or register to add a comment.