linux-stable/arch/x86/kernel/apic
Eric Dumazet cc95a07fef x86/apic: Reduce cache line misses in __x2apic_send_IPI_mask()
Using per-cpu storage for @x86_cpu_to_logical_apicid is not optimal.

Broadcast IPI will need at least one cache line per cpu to access this
field.

__x2apic_send_IPI_mask() is using standard bitmask operators.

By converting x86_cpu_to_logical_apicid to an array, we divide by 16x
number of needed cache lines, because we find 16 values per cache
line. CPU prefetcher can kick nicely.

Also move @cluster_masks to READ_MOSTLY section to avoid false sharing.

Tested on a dual socket host with 256 cpus, cost for a full broadcast
is now 11 usec instead of 33 usec.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lkml.kernel.org/r/20211007143556.574911-1-eric.dumazet@gmail.com
2021-10-29 10:02:17 +02:00
..
apic.c x86: Add support for 0x22/0x23 port I/O configuration space 2021-08-10 23:31:43 +02:00
apic_common.c x86/apic: Fix signedness bug in APIC ID validity checks 2018-04-10 16:46:39 +02:00
apic_flat_64.c x86/apic: Cleanup destination mode 2020-10-28 20:26:25 +01:00
apic_noop.c x86/apic: Cleanup destination mode 2020-10-28 20:26:25 +01:00
apic_numachip.c x86/apic: Cleanup destination mode 2020-10-28 20:26:25 +01:00
bigsmp_32.c x86/apic: Cleanup destination mode 2020-10-28 20:26:25 +01:00
hw_nmi.c locking/seqlock, headers: Untangle the spaghetti monster 2020-08-06 16:13:13 +02:00
io_apic.c A set of updates to support port 0x22/0x23 based PCI configuration space 2021-08-30 15:20:05 -07:00
ipi.c x86/apic: Replace pointless apic:: Dest_logical usage 2020-10-28 20:26:24 +01:00
local.h x86/headers: Remove APIC headers from <asm/smp.h> 2020-08-06 16:13:09 +02:00
Makefile x86/PCI: Remove unused HyperTransport interrupt support 2017-11-23 20:18:18 +01:00
msi.c x86/msi: Force affinity setup before startup 2021-08-10 10:59:21 +02:00
probe_32.c x86/apic: Cleanup destination mode 2020-10-28 20:26:25 +01:00
probe_64.c x86/irq: Move apic_post_init() invocation to one place 2020-09-16 16:52:35 +02:00
vector.c x86: Avoid magic number with ELCR register accesses 2021-08-10 23:31:43 +02:00
x2apic_cluster.c x86/apic: Reduce cache line misses in __x2apic_send_IPI_mask() 2021-10-29 10:02:17 +02:00
x2apic_phys.c x86/apic: Add extra serialization for non-serializing MSRs 2021-02-04 19:36:31 +01:00
x2apic_uv_x.c x86/platform/uv: Use x2apic enabled bit as set by BIOS to indicate APIC mode 2021-04-16 12:51:03 +02:00