|
|
|
|
|
by kazinator
1301 days ago
|
|
Neither. The code wasn't standard C, and it didn't just "happen" to work, either. You probably wouldn't want to build an atomic compare-exchange in standard C, even if it were possible; you find out what the hardware provides and work with that. |
|
At the risk of sounding pedantic, you did say using nothing but C99 or C90, implying use of standard features only.
Agreed.