aboutsummaryrefslogtreecommitdiff
path: root/ui/x_keymap.c
diff options
context:
space:
mode:
authorNicholas Piggin <npiggin@gmail.com>2024-02-21 20:08:31 +1000
committerNicholas Piggin <npiggin@gmail.com>2024-05-24 08:57:50 +1000
commitc700b5e162208a0fa4211fc6d9dab271b1342640 (patch)
tree794e2bd36806c77269fc4e3dff93e7f1d32fdbf3 /ui/x_keymap.c
parent70581940cabcc51b329652becddfbc6a261b1b83 (diff)
spapr: avoid overhead of finding vhyp class in critical operations
PPC_VIRTUAL_HYPERVISOR_GET_CLASS is used in critical operations like interrupts and TLB misses and is quite costly. Running the kvm-unit-tests sieve program with radix MMU enabled thrashes the TCG TLB and spends a lot of time in TLB and page table walking code. The test takes 67 seconds to complete with a lot of time being spent in code related to finding the vhyp class: 12.01% [.] g_str_hash 8.94% [.] g_hash_table_lookup 8.06% [.] object_class_dynamic_cast 6.21% [.] address_space_ldq 4.94% [.] __strcmp_avx2 4.28% [.] tlb_set_page_full 4.08% [.] address_space_translate_internal 3.17% [.] object_class_dynamic_cast_assert 2.84% [.] ppc_radix64_xlate Keep a pointer to the class and avoid this lookup. This reduces the execution time to 40 seconds. Reviewed-by: Harsh Prateek Bora <harshpb@linux.ibm.com> Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Diffstat (limited to 'ui/x_keymap.c')
0 files changed, 0 insertions, 0 deletions