Performance of single was considerably worse than plain barrier. Adding a check to the code before the atomic compare and store helped considerably.
Patch by Terry Wilmarth.
LGTM.