what is the use of Mutex and critical section

Answers were Sorted based on User's Feedback



what is the use of Mutex and critical section..

Answer / krishna akkulu

Using a mutex is more expensive in terms of CPU
utilization, but mutexes may be shared outside the
processes boundaries.

A critical section object provides synchronization similar
to that provided by a mutex object, except that a critical
section can be used only by the threads of a single
process.

Event, mutex, and semaphore objects can also be used in a
single-process application, but critical section objects
provide a slightly faster, more efficient mechanism for
mutual-exclusion

Is This Answer Correct ?    8 Yes 2 No

what is the use of Mutex and critical section..

Answer / xxxx

Supports synchronization by which we can provide controlled
access to the shared resource. At a time, only one process
can access the shared resource by using mutex n critical
section.

Is This Answer Correct ?    4 Yes 3 No

Post New Answer

More MFC Interview Questions

1)dynamic creation of a Button ?

2 Answers   TCS,


Which MFC function is used to display output?

9 Answers   TCS,


what is the size of a process

2 Answers   E Logic, IBM,


Will there be any difference in the image buffer size if it is loaded in from CString to LPTSTR using GetBuffer()? lptstr = string.GetBuffer(0);

2 Answers  


What is mfc class hierarchy?

0 Answers  






I have 2 threads. One thread prints odd numbers and the second thread prints even numbers. Now, I have to execute the threads alternatively so that i can output 1,2,3,4,5,6,..... write code for this?

1 Answers  


Differ GetMessage, PostMessage & PeakMessage?

4 Answers   Symphony,


If i derive a new class from CObject what are the basic features my derived wil get ?

4 Answers   Microsoft,


what is the difference between compiling and building?

1 Answers  


What is the difference between the SDI and MDI

3 Answers   Invensys,


What is Thread ?(VC++)What is the difference between Cmutex and Csemaphone?

5 Answers   Atos Origin,


visual Pogramming c++ coding for create a paint application.. (Please someone help me)

2 Answers  


Categories