AMD CPU 不受修改bug 影響... 但是沒看到數據就是
https://lkml.org/lkml/2017/12/27/2
Intel 修改 Bug 後效能下降: 7% ~ 16%; 最糟狀況 16% ~ 23%
linux+postgres測試
The fix will unfortunately cause performance regressions. Depending on
the hardware version and kernel version (will not be backported for
every version) hardware features (PCID / ASID) will be used to reduce
the impact.
pti is the workaroud, page table isolation, which can be
enabled/disabled via boot parameters. nopcid disables the use of the
hardware feature that reduces the impact of workaround. PCID support
readonly pgbench (tpch-like), 16 clients, i7-6820HQ CPU (skylake):
pti=off:
tps = 236629.778328
pti=on:
tps = 220791.228297 (~0.93x) -> 效能降至 93%
pti=on, nopcid:
tps = 198959.801459 (~0.84x) -> 效能降至 84%
To get closer to the worst case, I've also measured:
pgbench SELECT 1, 16 clients, i7-6820HQ CPU (skylake):
pti=off:
tps = 420490.162391
pti=on:
tps = 350746.065039 (~0.83x) -> 效能降至 84%
pti=on, nopcid:
tps = 324269.903152 (~0.77x) -> 效能降至 77%