Hi everyone,
Have a couple of questions here regarding the semaphores:
The semaphore invariant is often given as nW < nS + init.
How could we explain each term in this invariant? and How is the invariant enforced within the semaphore object?
And I'd like to know why might a semaphore be initialised to values: (a) 0, (b) 1, © N, where n > 1.
Any help would be grandly appreciated.
Thanks a bunch.
4 replies to this topic
#1
Posted 31 December 2011 - 07:13 AM
|
|
|
#2
Posted 01 January 2012 - 09:49 AM
Bump.
Sorry to bump here but seriously need help here because of a major exam comming up quite soon !
Thanks a lot for any help
Sorry to bump here but seriously need help here because of a major exam comming up quite soon !
Thanks a lot for any help
#3
Posted 01 January 2012 - 02:23 PM
You've given us no idea what the context of your question is. There are semaphores in data exchanges between systems, semaphores in threading, etc. Also, certain languages have the concept of semaphores as special meanings.
#4
Posted 01 January 2012 - 05:28 PM
Sorry.
Meant Semaphores in Threading / Processes management.
Thanks for any further answer !
Meant Semaphores in Threading / Processes management.
Thanks for any further answer !
#5
Posted 01 January 2012 - 07:48 PM
Unfortunately, the discussion of semaphores may not be as standardized as you'd like to think. nW and nS don't have an inherent meaning. Doing a quick search, I found discussions of semaphores that refer to nP and nV, for example.
Always start with definitions. Also, think about the purpose of initializing a semaphore in the first place.
Always start with definitions. Also, think about the purpose of initializing a semaphore in the first place.
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users


Sign In
Create Account

Back to top









