summaryrefslogtreecommitdiffstats
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorUros Bizjak <ubizjak@gmail.com>2022-05-18 15:51:11 +0200
committerPaolo Bonzini <pbonzini@redhat.com>2022-06-15 08:11:14 -0400
commitaee98a6838d52d5cca14610d228893e9208f4ed1 (patch)
tree79551e55c29d47e91ef351508b21ab314744ce1b /tools/perf/scripts/python
parentd895f28ed6da96d7b922bd79977e2b732b103a99 (diff)
downloadlinux-aee98a6838d52d5cca14610d228893e9208f4ed1.tar.gz
linux-aee98a6838d52d5cca14610d228893e9208f4ed1.zip
KVM: x86/mmu: Use try_cmpxchg64 in tdp_mmu_set_spte_atomic
Use try_cmpxchg64 instead of cmpxchg64 (*ptr, old, new) != old in tdp_mmu_set_spte_atomic. cmpxchg returns success in ZF flag, so this change saves a compare after cmpxchg (and related move instruction in front of cmpxchg). Also, remove explicit assignment to iter->old_spte when cmpxchg fails, this is what try_cmpxchg does implicitly. Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Sean Christopherson <seanjc@google.com> Signed-off-by: Uros Bizjak <ubizjak@gmail.com> Reviewed-by: David Matlack <dmatlack@google.com> Message-Id: <20220518135111.3535-1-ubizjak@gmail.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions