what is the use of Mutex and critical section
Answers were Sorted based on User's Feedback
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 |
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 |
1)dynamic creation of a Button ?
Which MFC function is used to display output?
what is the size of a process
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);
What is mfc class hierarchy?
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?
Differ GetMessage, PostMessage & PeakMessage?
If i derive a new class from CObject what are the basic features my derived wil get ?
what is the difference between compiling and building?
What is the difference between the SDI and MDI
What is Thread ?(VC++)What is the difference between Cmutex and Csemaphone?
visual Pogramming c++ coding for create a paint application.. (Please someone help me)