What is a mutex and a critical section.Whats difference
between them?How do each of them work?
Answer Posted / prasenjit roy
Mutex is a locking object ( like a flag ) for avoiding the
simultaneous use of a common resource. It is also used to
lock the critical section.
Ctitical Section :: is a block of code which should run
atomically ie. there should be no contact switching while
this block executes and once the block starts it should
finish without any interruption.
| Is This Answer Correct ? | 10 Yes | 0 No |
Post New Answer View All Answers
How does c++ sort work?
Evaluate as true or false: !(1 &&0 || !1) a) True b) False c) Invalid statement
Explain the difference between overloading and overriding?
How to give an alternate name to a namespace?
How does a C++ structure differ from a C++ class?
What is a rooted hierarchy?
How should a contructor handle a failure?
What do you mean by enumerated data type?
Write down the equivalent pointer expression for referring the same element a[i][j][k][l]?
What is meant by a delegate?
Write a Program to find the largest of 4 no using macros.
What is a friend function in c++?
What is a node class in c++?
What is auto type c++?
What is a set in c++?