Interlocked Operations Explained

Interlocked Operations are considered high-performance since they don’t utilize operating system mechanisms to function.  Instead they rely on hardware-based synchronization techniques. Interlocked operations’re a way to update variables in an atomic manner. An operation is considered atomic if it’s indivisible (not in a mathematical sense). During atomic operations threads cannot access variables that’re in use (locked) […]
Interlocked Operations are considered high-performance since they don’t utilize operating system mechanisms to function.  Instead they rely on hardware-based synchronization techniques. Interlocked operations’re a way to update variables in an atomic manner. An operation is considered atomic if it’s indivisible (not in a mathematical sense). During atomic operations threads cannot access variables that’re in use (locked) by a different thread. That having been said, Interlocked Operations are limited in that there’s only so much that the native operations can do. More complex operations would require the use of alternate mechanisms – such as mutexes.

About The Author

Deepak Gupta is a IT & Web Consultant. He is the founder and CEO of diTii.com & DIT Technologies, where he's engaged in providing Technology Consultancy, Design and Development of Desktop, Web and Mobile applications using various tools and softwares. Sign-up for the Email for daily updates. Google+ Profile.