aboutsummaryrefslogtreecommitdiff
path: root/arch/x86/kvm/svm/svm.c
diff options
context:
space:
mode:
authorUros Bizjak <[email protected]>2022-08-16 23:10:10 +0200
committerPaolo Bonzini <[email protected]>2022-09-26 12:02:27 -0400
commitafe30b59d30b80d91c70664f58c05ba149ef3a5d (patch)
tree030017137ed2e238cd2677e6453cfea264844b69 /arch/x86/kvm/svm/svm.c
parent5a2a961be2ad6a16eb388a80442443b353c11d16 (diff)
KVM/VMX: Avoid stack engine synchronization uop in __vmx_vcpu_run
Avoid instructions with explicit uses of the stack pointer between instructions that implicitly refer to it. The sequence of POP %reg; ADD $x, %RSP; POP %reg forces emission of synchronization uop to synchronize the value of the stack pointer in the stack engine and the out-of-order core. Using POP with the dummy register instead of ADD $x, %RSP results in a smaller code size and faster code. The patch also fixes the reference to the wrong register in the nearby comment. Cc: Paolo Bonzini <[email protected]> Cc: Sean Christopherson <[email protected]> Signed-off-by: Uros Bizjak <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Sean Christopherson <[email protected]> Signed-off-by: Paolo Bonzini <[email protected]>
Diffstat (limited to 'arch/x86/kvm/svm/svm.c')
0 files changed, 0 insertions, 0 deletions