Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Critical section
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
{{Short description|Protected section of code that cannot be executed by more than one process at a time}} In [[concurrent programming]], concurrent accesses to [[shared resource]]s can lead to unexpected or erroneous behavior. Thus, the parts of the program where the shared resource is accessed need to be protected in ways that avoid the concurrent access. One way to do so is known as a '''critical section''' or '''critical region'''. This protected section cannot be entered by more than one process or thread at a time; others are suspended until the first leaves the critical section. Typically, the critical section accesses a shared resource, such as a [[data structure]], peripheral device, or network connection, that would not operate correctly in the context of multiple concurrent accesses.<ref>{{Cite book |title=Concurrent Programming: Algorithms, Principles, and Foundations |last=Raynal |first=Michel |publisher=Springer Science & Business Media |year=2012 |isbn=978-3642320279 |pages=9}}</ref>
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)