# git rev-parse -q --verify 4df910620bebb5cfe234af16ac8f6474b60215fd^{commit} 4df910620bebb5cfe234af16ac8f6474b60215fd already have revision, skipping fetch # git checkout -q -f -B kisskb 4df910620bebb5cfe234af16ac8f6474b60215fd # git clean -qxdf # < git log -1 # commit 4df910620bebb5cfe234af16ac8f6474b60215fd # Author: Feng Tang # Date: Wed Nov 25 13:22:21 2020 +0800 # # mm: memcg: relayout structure mem_cgroup to avoid cache interference # # 0day reported one -22.7% regression for will-it-scale page_fault2 # case [1] on a 4 sockets 144 CPU platform, and bisected to it to be # caused by Waiman's optimization (commit bd0b230fe1) of saving one # 'struct page_counter' space for 'struct mem_cgroup'. # # Initially we thought it was due to the cache alignment change introduced # by the patch, but further debug shows that it is due to some hot data # members ('vmstats_local', 'vmstats_percpu', 'vmstats') sit in 2 adjacent # cacheline (2N and 2N+1 cacheline), and when adjacent cache line prefetch # is enabled, it triggers an "extended level" of cache false sharing for # 2 adjacent cache lines. # # So exchange the 2 member blocks, while keeping mostly the original # cache alignment, which can restore and even enhance the performance, # and save 64 bytes of space for 'struct mem_cgroup' (from 2880 to 2816, # with 0day's default RHEL-8.3 kernel config) # # [1]. https://lore.kernel.org/lkml/20201102091543.GM31092@shao2-debian/ # # Fixes: bd0b230fe145 ("mm/memcg: unify swap and memsw page counters") # Reported-by: kernel test robot # Signed-off-by: Feng Tang # Acked-by: Waiman Long # Signed-off-by: Linus Torvalds # < /opt/cross/kisskb/br-sparc64-full-2016.08-613-ge98b4dd/bin/sparc64-linux-gcc --version # < /opt/cross/kisskb/br-sparc64-full-2016.08-613-ge98b4dd/bin/sparc64-linux-ld --version # < git log --format=%s --max-count=1 4df910620bebb5cfe234af16ac8f6474b60215fd # < make -s -j 48 ARCH=sparc64 O=/kisskb/build/linus_sparc64-allmodconfig_sparc64 CROSS_COMPILE=/opt/cross/kisskb/br-sparc64-full-2016.08-613-ge98b4dd/bin/sparc64-linux- allmodconfig # Added to kconfig CONFIG_BUILD_DOCSRC=n # Added to kconfig CONFIG_HAVE_FTRACE_MCOUNT_RECORD=n # Added to kconfig CONFIG_SAMPLES=n # Added to kconfig CONFIG_MODULE_SIG=n # < make -s -j 48 ARCH=sparc64 O=/kisskb/build/linus_sparc64-allmodconfig_sparc64 CROSS_COMPILE=/opt/cross/kisskb/br-sparc64-full-2016.08-613-ge98b4dd/bin/sparc64-linux- help # make -s -j 48 ARCH=sparc64 O=/kisskb/build/linus_sparc64-allmodconfig_sparc64 CROSS_COMPILE=/opt/cross/kisskb/br-sparc64-full-2016.08-613-ge98b4dd/bin/sparc64-linux- olddefconfig # make -s -j 48 ARCH=sparc64 O=/kisskb/build/linus_sparc64-allmodconfig_sparc64 CROSS_COMPILE=/opt/cross/kisskb/br-sparc64-full-2016.08-613-ge98b4dd/bin/sparc64-linux- :1511:2: warning: #warning syscall clone3 not implemented [-Wcpp] /kisskb/src/drivers/input/joystick/analog.c:160:2: warning: #warning Precise timer not defined for this architecture. [-Wcpp] #warning Precise timer not defined for this architecture. ^ kernel: arch/sparc/boot/image is ready kernel: arch/sparc/boot/zImage is ready Completed OK # rm -rf /kisskb/build/linus_sparc64-allmodconfig_sparc64 # Build took: 0:16:08.685034