4 ms·
It doesn't, this is about this case: CPU1: lock() write1 unlock() CPU2, after CPU1: lock() write2 unlock() Until now it was not guaranteed
by AnssiH 8y ago
It doesn't, this is about this case:
CPU1:
lock()
write1
unlock()
CPU2, after CPU1:
lock()
write2
unlock()
Until now it was not guaranteed on all platforms that the writes arrive in the same order even if the CPU2 entered the critical section after CPU1.
This was because spinlocks only implied regular memory barriers, not mmiowb barriers.