Monday, May 20, 2013

INC_AND_READ

Imagine you have a shared object containing integer value that supports three atomic operations:
  • READ (read value)
  • INC_AND_READ (increment and read value)
  • DEC (decrement value)
The init value is 0.

How do you implement mutex and semaphore using this object?

No comments:

Post a Comment