Keep OSNews alive by becoming a Patreon, by donating through Ko-Fi, or by buying merch!

PowerPC atomic instruction prevents code meltdown

Something as simple as incrementing an integer can fail in a concurrent environment. This article illustrates the failure scenario and introduces the PowerPC’s coping mechanism: atomic instructions. Learn how to close the Window of Death with these assembly-level instructions to update memory correctly, even in the face of concurrency.