..:: PCSX2 Forums ::..

Full Version: Atomic ?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi, I often go to the Git page to follow PCSX2 progresses. And those days I read Atomic on many revs.

Anybody could explain what it is ?
When you do an addition (let's say + 1), you do it in 3 step.
1/ load the value in memory
2/ you do the +1
3/ you store the result in memory

A program can stop at 1 or 2, execute plenty of operation and then resume. Unfortunately data could be corrupted. Atomic is just way to block everyone and to guarantee that you can't split the above example in 3 steps.

From PCSX2 point of view, it justs a way to replace old API with the new one from the C++11 standard. This way it works the same on linux/windows and 32b/64b.
Headache incoming !

Thanks for the infos.