The X86 doesn't provide sequential consistency (SC) out of the box.
X86 provides TSO; so it will provide the following barriers for free
[LoadLoad]
[LoadStore]
[StoreStore]
Regular loads provide acquire semantics.
r1=A
[LoadLoad]
[LoadStore]
...
Regular stores provide release semantics.
...
[StoreStore]
[LoadStore]
X=r1
So X86 for regular loads and stores provide acquire/release semantics.
This isn't sufficient for SC, e.g.
[StoreStore]
[LoadStore]
X=r1
r2=Y
[LoadStore]
[LoadLoad]
In this case the store and load can still be reordered and hence it isn't SC. To remedy this issue a [StoreLoad] barrier can be added (e.g. a MFENCE).
[StoreStore]
[LoadStore]
X=r1
[StoreLoad]<--
r2=Y
[LoadStore]
[LoadLoad]
So now we have upgraded from acquire/release semantics to SC.
On most cases reads are more frequent than writes, so it is most beneficial to do the [StoreLoad] with the write.
[StoreStore]
[LoadStore]
X=r1
[StoreLoad]
My question is about linearizability. The difference between linearizability and SC is that with SC the effect of an operation can be skewed in front of the invocation start or after the invocation completion, but with linearizability it is required that the effect of the invocation is between invocation start and invocation completion.
This brings me to question; can X86 provide linearizability?
Lets first determine invocation start and completion:
Invocation start: the issuing of the instruction; so when a entry on the ROB is reserved.
Invocation completion: the removal of the instruction of the ROB (e.g. in case of a store when the item is moved from the SB to the L1D).
A load will become globally visible when it reads the data either from cache or from memory. This is after start and before completion. MESI protocol will prevent the load reading a stale value.
A store will become globally visible when the stores leaves the SB and hits the L1d. This is also between invocation start and completion.
So to me it looks that X86 can provide linearizability.