We run our test base on top of a model that equates the effect of the clflushopt instruction to the one of the clflush instruction, yielding log file ModelNoOpt.3 We then display the hardware observation that do not comply with this model. Thereby we display behaviours of the clflushopt instruction that the clflush instruction forbids.
Like the clflush instruction, the clflusopt instruction takes an address4 as argument. Test names reflect that address: clflushopt refers to the variable accessed by the previous instruction clflushoptnext refers to the variable accessed by the next instruction, while clflushoptother refers to an arbitrary variable, different from all variables accessed by the test.
We first show the four “MP” tests of Figure 11.
Model-NoOpt | Hardware | Model | SC | CoreI5 | CoreI7 | Estephe | Zdani | |
MP+clflushoptnext+mfence+WB+WC | Forbid | Ok, 3/9.4G | Allow | Forbid | Ok, 1/4.6G | No, 0/3.8G | Ok, 2/704M | No, 0/227M |
Forbid invalidated | Forbid invalidated | Forbid invalidated | ||||||
MP+clflushoptnextntna+mfence+WB+WB | Forbid | Ok, 517/9.4G | Allow | Forbid | No, 0/4.6G | No, 0/3.8G | Ok, 352/704M | Ok, 165/227M |
Forbid invalidated | Forbid invalidated | Forbid invalidated | ||||||
MP+clflushoptother+mfence+WB+WC | Forbid | Ok, 11/7.1G | Allow | Forbid | No, 0/3.8G | No, 0/2.8G | No, 0/320M | Ok, 11/212M |
Forbid invalidated | Forbid invalidated | |||||||
MP+clflushoptothernant+mfence+WB+WB | Forbid | Ok, 19/13G | Allow | Forbid | No, 0/7.8G | No, 0/4.0G | No, 0/979M | Ok, 19/527M |
Forbid invalidated | Forbid invalidated |
The following table lists all our observations of clflushopt being weaker then clflush. From the table below, one may notice that no experiment makes a distinction between the clflush and clflushopt instructions when they apply to the address accessed by the previous instruction.
Model-NoOpt | Hardware | Model | SC | CoreI5 | CoreI7 | Estephe | Zdani | |
2+2W+mfence+clflushoptnext+WC+WB | Forbid | Ok, 4/9.4G | Allow | Forbid | Ok, 1/4.6G | Ok, 3/3.8G | No, 0/704M | No, 0/227M |
Forbid invalidated | Forbid invalidated | Forbid invalidated | ||||||
2+2W+mfence+clflushoptnextntna+WB+WB | Forbid | Ok, 1.1k/9.4G | Allow | Forbid | No, 0/4.6G | No, 0/3.8G | Ok, 1.0k/704M | Ok, 73/227M |
Forbid invalidated | Forbid invalidated | Forbid invalidated | ||||||
2+2W+mfence+clflushoptother+WC+WB | Forbid | Ok, 1/7.1G | Allow | Forbid | No, 0/3.8G | Ok, 1/2.8G | No, 0/320M | No, 0/212M |
Forbid invalidated | Forbid invalidated | |||||||
2+2W+mfence+clflushoptothernant+WB+WB | Forbid | Ok, 15/13G | Allow | Forbid | No, 0/7.8G | No, 0/4.0G | Ok, 1/979M | Ok, 14/527M |
Forbid invalidated | Forbid invalidated | Forbid invalidated | ||||||
2+2W+mfence+clflushoptothernant+WT+WB | Forbid | Ok, 1/13G | Allow | Forbid | No, 0/7.8G | No, 0/4.0G | Ok, 1/979M | No, 0/527M |
Forbid invalidated | Forbid invalidated | |||||||
MP+clflushoptnext+mfence+WB+WC | Forbid | Ok, 3/9.4G | Allow | Forbid | Ok, 1/4.6G | No, 0/3.8G | Ok, 2/704M | No, 0/227M |
Forbid invalidated | Forbid invalidated | Forbid invalidated | ||||||
MP+clflushoptnextntna+mfence+WB+WB | Forbid | Ok, 517/9.4G | Allow | Forbid | No, 0/4.6G | No, 0/3.8G | Ok, 352/704M | Ok, 165/227M |
Forbid invalidated | Forbid invalidated | Forbid invalidated | ||||||
MP+clflushoptother+mfence+WB+WC | Forbid | Ok, 11/7.1G | Allow | Forbid | No, 0/3.8G | No, 0/2.8G | No, 0/320M | Ok, 11/212M |
Forbid invalidated | Forbid invalidated | |||||||
MP+clflushoptother+mfence+WC+WB | Forbid | Ok, 4/13G | Allow | Forbid | No, 0/7.8G | No, 0/4.0G | No, 0/979M | Ok, 4/527M |
Forbid invalidated | Forbid invalidated | |||||||
MP+clflushoptothernant+mfence+WB+WB | Forbid | Ok, 19/13G | Allow | Forbid | No, 0/7.8G | No, 0/4.0G | No, 0/979M | Ok, 19/527M |
Forbid invalidated | Forbid invalidated | |||||||
MP+clflushoptothernant+mfence+WB+WT | Forbid | Ok, 7/13G | Allow | Forbid | No, 0/7.8G | No, 0/4.0G | Ok, 1/979M | Ok, 6/527M |
Forbid invalidated | Forbid invalidated | Forbid invalidated | ||||||
R+clflushoptnext+mfence+WB+WC | Forbid | Ok, 4/9.4G | Allow | Forbid | Ok, 1/4.6G | No, 0/3.8G | Ok, 3/704M | No, 0/227M |
Forbid invalidated | Forbid invalidated | Forbid invalidated | ||||||
R+clflushoptnextntna+mfence+WB+WB | Forbid | Ok, 539/9.4G | Allow | Forbid | No, 0/4.6G | No, 0/3.8G | Ok, 372/704M | Ok, 167/227M |
Forbid invalidated | Forbid invalidated | Forbid invalidated | ||||||
R+clflushoptother+mfence+WB+WC | Forbid | Ok, 1/7.2G | Allow | Forbid | Ok, 1/3.8G | No, 0/2.8G | No, 0/320M | No, 0/269M |
Forbid invalidated | Forbid invalidated | |||||||
R+clflushoptother+mfence+WC+WB | Forbid | Ok, 2/13G | Allow | Forbid | No, 0/7.8G | No, 0/4.0G | No, 0/979M | Ok, 2/584M |
Forbid invalidated | Forbid invalidated | |||||||
R+clflushoptothernant+mfence+WB+WB | Forbid | Ok, 13/13G | Allow | Forbid | No, 0/7.8G | No, 0/4.0G | No, 0/979M | Ok, 13/584M |
Forbid invalidated | Forbid invalidated | |||||||
R+clflushoptothernant+mfence+WB+WT | Forbid | Ok, 1/13G | Allow | Forbid | Ok, 1/7.8G | No, 0/4.0G | No, 0/979M | No, 0/584M |
Forbid invalidated | Forbid invalidated | |||||||
S+clflushoptnext+mfence+WB+WC | Forbid | Ok, 1/9.4G | Allow | Forbid | No, 0/4.6G | No, 0/3.8G | No, 0/704M | Ok, 1/269M |
Forbid invalidated | Forbid invalidated | |||||||
S+clflushoptnextntna+mfence+WB+WB | Forbid | Ok, 401/9.4G | Allow | Forbid | No, 0/4.6G | No, 0/3.8G | Ok, 287/704M | Ok, 114/269M |
Forbid invalidated | Forbid invalidated | Forbid invalidated | ||||||
S+clflushoptother+mfence+WB+WC | Forbid | Ok, 23/7.2G | Allow | Forbid | No, 0/3.8G | No, 0/2.8G | No, 0/320M | Ok, 23/269M |
Forbid invalidated | Forbid invalidated | |||||||
S+clflushoptother+mfence+WC+WB | Forbid | Ok, 5/13G | Allow | Forbid | No, 0/7.8G | No, 0/4.0G | No, 0/979M | Ok, 5/529M |
Forbid invalidated | Forbid invalidated | |||||||
S+clflushoptothernant+mfence+WB+WB | Forbid | Ok, 18/13G | Allow | Forbid | Ok, 1/7.8G | No, 0/4.0G | No, 0/979M | Ok, 17/529M |
Forbid invalidated | Forbid invalidated | Forbid invalidated | ||||||
S+clflushoptothernant+mfence+WB+WT | Forbid | Ok, 6/13G | Allow | Forbid | No, 0/7.8G | No, 0/4.0G | Ok, 2/979M | Ok, 4/529M |
Forbid invalidated | Forbid invalidated | Forbid invalidated |