From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mta1.migadu.com (out-87.mta1.migadu.com [95.215.58.87]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1750B381E8B for ; Thu, 13 Aug 2026 17:01:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=95.215.58.87 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786640486; cv=none; b=SyCjyxL0ss/bQnys5/nX31V0SgNEfFtNBZ9wG+ubdydnuy0JryqWUBi6Ng9ubOSC3HF19H6kq1eI5yguhSJtIjk5Rial40z2+MOOcp8Dw63vaUzAgBreu0nBGFJ8eSA3+jgeG4byf2eGMoLt+2GzfwhtGE8P/zApDXjtm3RiIO8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786640486; c=relaxed/simple; bh=IC8q4K8Uk8A6ZcbO1N8MmnhqRx/RYea67hNdi4ByC2M=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=D7SR6/DKZlaWNb6LRTCP50Om84PWUpF6MMDf9itu/0/0gLEgQjM8Hn+V2tmwIlxfYG19mloKHE3Ewl/VTpbfAQ0CgU+sDhGExichfLPWhBTrrhOke8H9QuohNmB8MEPvV4F1pWN5qC7ZrtUaEj4Snaga6LFNkqqT7cHYWhI3CV0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev; spf=pass smtp.mailfrom=linux.dev; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=aEqHfNzo; arc=none smtp.client-ip=95.215.58.87 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.dev Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="aEqHfNzo" X-Envelope-To: oe-lkp@lists.linux.dev DKIM-Signature: a=rsa-sha256; bh=IC8q4K8Uk8A6ZcbO1N8MmnhqRx/RYea67hNdi4ByC2M=; c=simple/simple; d=linux.dev; h=from:to:subject:date:message-id:mime-version:content-type; s=key1; t=1786640482; v=1; x=1787245282; b=aEqHfNzoIvCDfrWkqYihGXCwGeugeiLoRs6zokTUSwl/EhRs7jkms7OF91Nz1nZ0rK6bxVhw IEKDH5Q/OSwY44D625i1yd+TsPwpE+E14omR5Chvrep8JuvHlV/xpn7r9R6d6z6f3OMIjxsIDLb ZzrFAC9CwazpCqL0KcyRTdVw= X-Envelope-To: oe-lkp@lists.linux.dev Received: from localhost (2a03:2880:10ff:42::) by smtp.migadu.com with ESMTPS id ac65b9794b46e62b; Thu, 13 Aug 2026 17:01:22 +0000 X-Migadu-Flow: FLOW_OUT Date: Thu, 13 Aug 2026 10:01:19 -0700 From: Shakeel Butt To: kernel test robot Cc: Usama Arif , oe-lkp@lists.linux.dev, lkp@intel.com, Andrew Morton , David Hildenbrand , Johannes Weiner , "Liam R. Howlett" , Lorenzo Stoakes , Michal Hocko , Michal =?utf-8?Q?Koutn=C3=BD?= , Mike Rapoport , Roman Gushchin , Suren Baghdasaryan , Tejun Heo , Vlastimil Babka , linux-mm@kvack.org, cgroups@vger.kernel.org Subject: Re: [linux-next:master] [mm/vmpressure] ea928e9e18: stress-ng.mremap.ops_per_sec 36.2% regression Message-ID: References: <202608131743.c6a7dda4-lkp@intel.com> Precedence: bulk X-Mailing-List: oe-lkp@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <202608131743.c6a7dda4-lkp@intel.com> On Thu, Aug 13, 2026 at 09:16:22PM +0800, kernel test robot wrote: > > > Hello, > > kernel test robot noticed a 36.2% regression of stress-ng.mremap.ops_per_sec on: > > commit: ea928e9e18da682e9a5bc40aa862bff7ce5ae42e ("mm/vmpressure: move v1 userspace eventfd code into memcontrol-v1.c") https://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git master > > in testcase: stress-ng > version: stress-ng-x86_64-29ce10a2c-1_20260712 > with following parameters: > > nr_threads: 100% > testtime: 60s > test: mremap > cpufreq_governor: performance > > > > config: x86_64-rhel-9.4 (CONFIG_MEMCG=y and CONFIG_MEMCG_V1 is not set) > compiler: gcc-14 > test machine: 256 threads 4 sockets INTEL(R) XEON(R) PLATINUM 8592+ (Emerald Rapids) with 256G memory > > (please refer to attached dmesg/kmsg for entire log/backtrace) > Hi there, Can you please test the following patch and see if it fixes the regression? >From 84c0b05b3bc5cf73ee66ead75aafb1ad684462c3 Mon Sep 17 00:00:00 2001 From: Shakeel Butt Date: Thu, 13 Aug 2026 09:38:28 -0700 Subject: [PATCH] memcg: keep vmstats_percpu off the memory_events[] cacheline Signed-off-by: Shakeel Butt --- include/linux/memcontrol.h | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/include/linux/memcontrol.h b/include/linux/memcontrol.h index e78bc98ab229..e25d5b9a1db8 100644 --- a/include/linux/memcontrol.h +++ b/include/linux/memcontrol.h @@ -246,8 +246,13 @@ struct mem_cgroup { /* handle for "memory.swap.events" */ struct cgroup_file swap_events_file; - /* memory.stat */ + /* Read-mostly. */ struct memcg_vmstats *vmstats; + struct memcg_vmstats_percpu __percpu *vmstats_percpu; + int kmemcg_id; + + /* Write-hot from here on; do not let it share with the above. */ + CACHELINE_PADDING(_pad_); /* memory.events */ atomic_long_t memory_events[MEMCG_NR_MEMORY_EVENTS]; @@ -266,9 +271,6 @@ struct mem_cgroup { #if BITS_PER_LONG < 64 seqlock_t socket_pressure_seqlock; #endif - int kmemcg_id; - - struct memcg_vmstats_percpu __percpu *vmstats_percpu; #ifdef CONFIG_CGROUP_WRITEBACK struct list_head cgwb_list; -- 2.53.0-Meta