What is the difference between mutex and semaphore?

Answer Posted / rohit

Apart from counting behaviour the biggest differnce is in
scope of mutex and semaphore. Mutex have process scope that
is it is valid within a process space and can be used for
thread synchronization (hence light weight), semaphore are
can be used accross process space and hence can be used for
inter process synch.

However on RTOS this distinction is not applicable due to
flat process space hence only semaphores are supported on
typical RTOS.

Is This Answer Correct ?    31 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How does disk operating system work?

518


How do I know if my ram is corrupted?

581


What is virtual memory and where it exhist ?

651


How to recovery from deadlock?

575


How do I copy a path to a shared drive?

568






What do you mean by parallel processing?

570


What is the code of mobile?

522


How much ram do I need laptop?

532


Define max, min heap and search time of heap.

636


How are data structures handled by ntfs and how does it recover from a crash?

574


List the sub-components of i/o manager in windows nt?

519


What are a virtual machines and site their advantages?

628


Throw some light on internal process memory.

559


How do I search for excel files on my computer?

561


What grep means?

503