diff options
author | Nathan Lynch <nathanl@linux.ibm.com> | 2022-09-26 17:02:50 -0500 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2022-09-28 19:22:14 +1000 |
commit | b37ac1894ac3c014863986d6b8ed880195213e78 (patch) | |
tree | db0bd72ac7a3c544908558a0bbfbb13c65c34d47 /arch/sparc/Kbuild | |
parent | b8f3e48834fe8c86b4f21739c6effd160e2c2c19 (diff) | |
download | linux-b37ac1894ac3c014863986d6b8ed880195213e78.tar.bz2 |
powerpc/smp: poll cpu_callin_map more aggressively in __cpu_up()
At boot time, it is not necessary to delay between polls of
cpu_callin_map when waiting for a kicked CPU to come up. Remove the
delay intervals, but preserve the overall deadline (five seconds).
At run time, the first poll result is usually negative and we incur a
sleeping wait. If we spin on the callin word for a short time first,
we can reduce __cpu_up() from dozens of milliseconds to under 1ms in
the common case on a P9 LPAR:
$ ppc64_cpu --smt=off
$ bpftrace -e 'kprobe:__cpu_up {
@start[tid] = nsecs;
}
kretprobe:__cpu_up /@start[tid]/ {
@us = hist((nsecs - @start[tid]) / 1000);
delete(@start[tid]);
}' -c 'ppc64_cpu --smt=on'
Before:
@us:
[16K, 32K) 85 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@|
[32K, 64K) 13 |@@@@@@@ |
After:
@us:
[128, 256) 95 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@|
[256, 512) 3 |@ |
Signed-off-by: Nathan Lynch <nathanl@linux.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20220926220250.157022-1-nathanl@linux.ibm.com
Diffstat (limited to 'arch/sparc/Kbuild')
0 files changed, 0 insertions, 0 deletions