[sgen] Fix call to `InterlockedCompareExchange()`.