Ask or Answer

🏠 Home🏷️ Tags❔ Ask a Question✔️ Answer a QuestionUsers
What are counting semaphores and resource semaphore?

Please log in or register to answer this question.

1 Answer

Answer :

If a task tries to take the semaphore when the integer is equal to zero, then the task will block. These semaphores are called counting semaphore.

Some system offer semaphore that can be released only by the task that took them. These semaphore are useful for the shared data problem, but they cannot be used to communicate between two tasks. Such semaphores are called resource semaphore.
Like 0 like

Related Questions


Last Answer : A semaphore is called binary semaphore when its value is 0, it is assumed that it has been taken (or accepted) & when its value is 1, it is assumed that it has been released & no ... that are not themselves reentrant.3. A reentrant function may does not use the hardware in a nonatomic way.

1 answer

Description : There are three processes P1, P2 and P3 sharing a semaphore for synchronising a variable. Initial value of semaphore is one. Assume that negative value of semaphore tells us how many processes are waiting in queue. Processes access ... The final value of semaphore will be: (1) 0 (2) 1 (3) -1 (4) -2 

Last Answer : Answer: 1

1 answer

Description : State the methods of task synchronization. Describe semaphore with suitable example.

Last Answer : The methods of task synchronization are: Semaphore Message queue. Mutual exclusion.  Dead lock. Mailboxes. Message Queues. Semaphores: It is a system of sending message by using flags. Multiple concurrent threads of execution ...   signal(Sem);  }  in process P2  {  wait(Sem);  S2;  }

1 answer
1 view

Description : Cell size and cell number can be measured using A- hemocytometer B- coulter counter C- petroff-hausser counting chamber D- none of these

Last Answer : coulter counter

1 answer

Description : Intermediate goods are not included to calculate the final output because: a) they do not have value b) they have unknown value c) their value is included in final goods so they are not added to avoid the problem of double counting d) none of the above

Last Answer : : c) their value is included in final goods so they are not added to avoid the problem of double counting

1 answer
Show MoreAsk QuestionNext Page →