summaryrefslogtreecommitdiff
path: root/arch/x86/Kbuild
diff options
context:
space:
mode:
authorNadav Amit <namit@vmware.com>2019-04-26 02:01:43 +0300
committerIngo Molnar <mingo@kernel.org>2019-04-26 13:01:45 +0300
commit3db6d5a5ecaf0a778d721ccf9809248350d4bfaf (patch)
tree2136fff8b0378ea2cee822cf7f2e0e6dcba49bf9 /arch/x86/Kbuild
parentda398dbd7d871bae332a800f7d194af18a2a9058 (diff)
downloadlinux-3db6d5a5ecaf0a778d721ccf9809248350d4bfaf.tar.xz
x86/mm/tlb: Remove 'struct flush_tlb_info' from the stack
Move flush_tlb_info variables off the stack. This allows to align flush_tlb_info to cache-line and avoid potentially unnecessary cache line movements. It also allows to have a fixed virtual-to-physical translation of the variables, which reduces TLB misses. Use per-CPU struct for flush_tlb_mm_range() and flush_tlb_kernel_range(). Add debug assertions to ensure there are no nested TLB flushes that might overwrite the per-CPU data. For arch_tlbbatch_flush() use a const struct. Results when running a microbenchmarks that performs 10^6 MADV_DONTEED operations and touching a page, in which 3 additional threads run a busy-wait loop (5 runs, PTI and retpolines are turned off): base off-stack ---- --------- avg (usec/op) 1.629 1.570 (-3%) stddev 0.014 0.009 Signed-off-by: Nadav Amit <namit@vmware.com> Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Andy Lutomirski <luto@kernel.org> Cc: Borislav Petkov <bp@alien8.de> Cc: Brian Gerst <brgerst@gmail.com> Cc: Dave Hansen <dave.hansen@intel.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Rik van Riel <riel@surriel.com> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20190425230143.7008-1-namit@vmware.com Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'arch/x86/Kbuild')
0 files changed, 0 insertions, 0 deletions