From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from out-179.mta1.migadu.com (out-179.mta1.migadu.com [95.215.58.179]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7210D263F44 for ; Wed, 20 May 2026 06:14:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=95.215.58.179 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1779257690; cv=none; b=YkGgYlLWkgCgd6Il1UAcBgXqf90w9h8ctQhyWMqoKdCGTVY9RDP7JBLpbB3/8yjA8iT2MsZJhPYECY/IFsjV0JhWiaFit9JcWYu5GE4mx9lqD0nVg+8DND5HNryObDKwGtLaRckZfIm6aijBwq8QGlSVx48sW4EbrYmSOVqW3qs= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1779257690; c=relaxed/simple; bh=sUnLIK/nsSMXWjoWKoX14W3kTVmT/RwIKGRFCvAQlow=; h=Content-Type:Mime-Version:Subject:From:In-Reply-To:Date:Cc: Message-Id:References:To; b=a8vXUaM2v7z676f4Xjux2UofNpkkZTBJ/yS3mF7pQQGCDBbnOoun6TNvBK6DuXZb36p8fZ0i7PVAupcsn+ufE7/NL5P4JlCdtTkpWNWcSqRnPTYTOj85haK8u6UzuHe927yeu+Nm+CSXEPJvAw/6PFQ17Zca2ZCyxxMbqe4zOoo= 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=K/EWTj2f; arc=none smtp.client-ip=95.215.58.179 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="K/EWTj2f" Content-Type: text/plain; charset=us-ascii DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1779257686; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=7e+jehEEvjjqFDVMHvCX7/NWn18MESwVkGseJjxy/2s=; b=K/EWTj2fUFvDDc8uLbsWf19nUn0V3CeKUvpUzCv5fiWeXo6vBhWkzzsuho85530U9etXtb kUYnQrdnKjZI83DTJOQZ2NQRwt8Mf6z1Yyy21G0ZwJXyzBqJDyGOEGjl3QG4Z5aiK4N0OM 9ojDL6eQmmFZHbsDoFHbm1ShZkIQ3zk= Precedence: bulk X-Mailing-List: cgroups@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3864.500.181\)) Subject: Re: [PATCH 1/4] memcg: store node_id instead of pglist_data pointer X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Muchun Song In-Reply-To: <20260520053123.2709959-2-shakeel.butt@linux.dev> Date: Wed, 20 May 2026 14:13:47 +0800 Cc: Andrew Morton , Johannes Weiner , Michal Hocko , Roman Gushchin , Qi Zheng , Alexandre Ghiti , Joshua Hahn , Harry Yoo , Meta kernel team , linux-mm@kvack.org, cgroups@vger.kernel.org, linux-kernel@vger.kernel.org, kernel test robot Content-Transfer-Encoding: 7bit Message-Id: <0B4974B5-FB9B-47CD-956A-B13BCF278163@linux.dev> References: <20260520053123.2709959-1-shakeel.butt@linux.dev> <20260520053123.2709959-2-shakeel.butt@linux.dev> To: Shakeel Butt X-Migadu-Flow: FLOW_OUT > On May 20, 2026, at 13:31, Shakeel Butt wrote: > > The struct obj_stock_pcp stores a pointer to pglist_data for the slab > stats cached on the cpu. On 64-bit machines, this costs 8 bytes. The > pointer is not strictly required: NODE_DATA() can recover it from the > node id. Replace cached_pgdat with int16_t node_id and use NUMA_NO_NODE > as the "no stats cached" sentinel. > > At the moment all the archs limit MAX_NUMNODES to 1024 so int16_t is > plenty; a BUILD_BUG_ON() makes sure we notice if that ever changes. > > Signed-off-by: Shakeel Butt > Tested-by: kernel test robot Acked-by: Muchun Song Thanks.