Thread safety is a computer programming concept applicable in the context of multi-threaded programs. A piece of code is thread-safe if it only manipulates shared data structures in a manner that guarantees safe execution by multiple threads at the same time. There are various strategies for making thread-safe data structures.
A key challenge in multi-threaded programming, thread safety was not a concern for most application developers until the 1990s when operating systems began to expose multiple threads for code execution. Today, a program may execute code on several threads simultaneously in a shared address space where each of those threads has access to virtually all of the memory of every other thread. Thread safety is a property that allows code to run in multi-threaded environments by re-establishing some of the correspondences between the actual flow of control and the text of the program, by means of synchronization.
Read more about Thread Safety: Levels of Thread Safety, Implementation Approaches, Examples
Famous quotes containing the words thread and/or safety:
“It may be the more
That no line of her writing have I,
Nor a thread of her hair,
No mark of her late time as dame in her dwelling, whereby
I may picture her there.”
—Thomas Hardy (18401928)
“Can we not teach children, even as we protect them from victimization, that for them to become victimizers constitutes the greatest peril of all, specifically the sacrificephysical or psychologicalof the well-being of other people? And that destroying the life or safety of other people, through teasing, bullying, hitting or otherwise, putting them down, is as destructive to themselves as to their victims.”
—Lewis P. Lipsitt (20th century)