How to avoid race conditions with critical section?, Basic Computer Science


• The key to preventing problem involving shared storage is get some way to prohibit more than one process from reading and writing the shared data concurrently. That part of the program where the shared memory is used is called the Critical Section. To keep away from race conditions and flawed outcomes, one must identify codes in Critical Sections in each thread. The feature properties of the code that form a Critical Section are:
o Codes that position one or more variables in a “read-update-write” fashion while some of those variables is probably being changed by another thread.
o Codes that alter one or more variables that are possibly being mentioned in “read-update-write” fashion by another thread.
o Codes use a data structure while any division of it is possibly being altered by another thread.
o Codes alter any division of a data structure while it is possibly in use by an additional thread.

Here, the significant point is that when one process is executing shared adaptable data in its critical section, no further process is to be allowed to execute in its critical section. Therefore, the execution of critical sections by the processes is mutually exclusive in moment.
Posted Date: 5/2/2012 9:08:27 AM | Location : United States







Related Discussions:- How to avoid race conditions with critical section?, Assignment Help, Ask Question on How to avoid race conditions with critical section?, Get Answer, Expert's Help, How to avoid race conditions with critical section? Discussions

Write discussion on How to avoid race conditions with critical section?
Your posts are moderated
Related Questions
what are the phases of oo progarmming or java?

assembly programs


Hi I have an assignment can you help me ?


Function: The purpose of a function is to take in a number of values or arguments, do some calculations with those arguments and then return a single result.  Each language has d


what is the sql command to List all the join conditions or join paths (pairwise) existing between tables.

QUESTION (a) Using the Luhn 10 check formula verify whether the following account number is compliant: 49927398716. Show details of your workings (b) Why is it advisable to

Working of web Browser:   Internet is characterized by the Client Server Computing that consists of three basic components: The Web client which may be the web browser;