Message ID | 20240117-slab-misc-v2-0-81766907896e@bytedance.com (mailing list archive) |
---|---|
Headers | show
Return-Path: <owner-linux-mm@kvack.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id E76E1C47DDB for <linux-mm@archiver.kernel.org>; Tue, 23 Jan 2024 09:33:55 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 8364B6B0080; Tue, 23 Jan 2024 04:33:55 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 7E6B76B0082; Tue, 23 Jan 2024 04:33:55 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 6D6336B0083; Tue, 23 Jan 2024 04:33:55 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0011.hostedemail.com [216.40.44.11]) by kanga.kvack.org (Postfix) with ESMTP id 5E0DD6B0080 for <linux-mm@kvack.org>; Tue, 23 Jan 2024 04:33:55 -0500 (EST) Received: from smtpin20.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay04.hostedemail.com (Postfix) with ESMTP id ED9361A0368 for <linux-mm@kvack.org>; Tue, 23 Jan 2024 09:33:54 +0000 (UTC) X-FDA: 81710063988.20.DDFC616 Received: from out-174.mta1.migadu.com (out-174.mta1.migadu.com [95.215.58.174]) by imf26.hostedemail.com (Postfix) with ESMTP id C6737140002 for <linux-mm@kvack.org>; Tue, 23 Jan 2024 09:33:52 +0000 (UTC) Authentication-Results: imf26.hostedemail.com; dkim=none; spf=pass (imf26.hostedemail.com: domain of chengming.zhou@linux.dev designates 95.215.58.174 as permitted sender) smtp.mailfrom=chengming.zhou@linux.dev; dmarc=fail reason="SPF not aligned (relaxed), No valid DKIM" header.from=bytedance.com (policy=quarantine) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1706002433; h=from:from:sender: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: references; bh=8MHcoFhxFxX05/b04xMNi+k07OVZqHefdPDgbGSe6Dw=; b=LxCEZLkdpoTWJtmoHRrVBkVuUU+lD/S7c/qde5MQFE1JaTddWoBgOdDhj2yce0LDDg0Goa zRo2KAofXhm5tQsx2dqeuv03axFYiGEWB3IeuqWeTQwxk40I2wIGyLz7k5+LAXh1k7AmNZ lXw6u2b5zVeyNWLcuU2roe37lyK0WU0= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1706002433; a=rsa-sha256; cv=none; b=unNuBxNkhwUYMFZTPhz/PLCAK7yJENh+Y8mpNni9kAt8AzNZME9EDi8Jk2y/c12Xy3GLuZ OXBpcjZZVY3ep9G0NOLAb1F8fmSH4008DoRVsZimZDDrjg07KG0dQ8pJufm1RZJWasF0lI yqX/GqDmRHhr8BlckAGczGQybHCath0= ARC-Authentication-Results: i=1; imf26.hostedemail.com; dkim=none; spf=pass (imf26.hostedemail.com: domain of chengming.zhou@linux.dev designates 95.215.58.174 as permitted sender) smtp.mailfrom=chengming.zhou@linux.dev; dmarc=fail reason="SPF not aligned (relaxed), No valid DKIM" header.from=bytedance.com (policy=quarantine) Subject: [PATCH v2 0/3] mm/slub: some minor optimization and cleanup MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit X-b4-tracking: H4sIAOiHr2UC/22MwQqDMBBEf0X23C1Jagjtqf8hPSTrWgMaIWsFEf+9S889DW+YeQcI18wCj+aAyl uWvBQFd2mAxljejLlXBmdca6wNKFNMOGch9NEPtxC9dT6A7lMUxlRjoVEf5TNNWo5Z1qXuP/9mNbp/ qs2iwaG31N6JEgfzTPvKvar4SssMr/M8v5IA8fSrAAAA X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Chengming Zhou <zhouchengming@bytedance.com> Date: Tue, 23 Jan 2024 09:33:28 +0000 Message-Id: <20240117-slab-misc-v2-0-81766907896e@bytedance.com> To: Joonsoo Kim <iamjoonsoo.kim@lge.com>, Vlastimil Babka <vbabka@suse.cz>, David Rientjes <rientjes@google.com>, Roman Gushchin <roman.gushchin@linux.dev>, Pekka Enberg <penberg@kernel.org>, Christoph Lameter <cl@linux.com>, Andrew Morton <akpm@linux-foundation.org>, Hyeonggon Yoo <42.hyeyoo@gmail.com> Cc: Vlastimil Babka <vbabka@suse.cz>, linux-kernel@vger.kernel.org, Chengming Zhou <zhouchengming@bytedance.com>, linux-mm@kvack.org, "Christoph Lameter (Ampere)" <cl@linux.com> X-Developer-Signature: v=1; a=ed25519-sha256; t=1706002427; l=1261; i=zhouchengming@bytedance.com; s=20231204; h=from:subject:message-id; bh=eVMXKZAo6mMH3XIzuesaTRxENZPYrR21d0pV00ugJoA=; b=7EmvuAw7LCSLOid/Dwt/QI7NYHltCGe5nToDs6wYquYL4RGXYdJ8Nk17M+xbUBH28eqpO843V XlC9mRiHUnKBFUuoCLBCzCVxqGBRRLpNTDF6kXvt7MYn7/sm41HyuAb X-Developer-Key: i=zhouchengming@bytedance.com; a=ed25519; pk=xFTmRtMG3vELGJBUiml7OYNdM393WOMv0iWWeQEVVdA= X-Migadu-Flow: FLOW_OUT X-Rspamd-Pre-Result: action=add header; module=dmarc; Action set by DMARC X-Rspam-User: X-Rspamd-Queue-Id: C6737140002 X-Rspamd-Server: rspam11 X-Stat-Signature: yqmj4e8soinuk95ww5bpa4mabbzbma8f X-Rspam: Yes X-HE-Tag: 1706002432-753166 X-HE-Meta: U2FsdGVkX18SDeXXZBKWfcmwlrYNiefPUPNCK3D+hfkPnfEMCG/NGyNmNpcpw6RC8MqfoQ66bHsIABdMneet5GW6em3P1SIot6xw5zIUcEgQy94ZzFXuO/Iugn+Ini3SDdmvk1Z6BBZUIHQVWeWqs+GwpZ7V3y4x6oWAU9/v4ezGdJ5lX3yQ9ztjegcDc+iJ9zaFpsUftWnUCnpOV8EhF3TtIl7dFFIbpPHJCG4RaaI+s4uvoKMByPE1caEQac1nC5AJNysl+h6UvHGXgxcq+yyHumk0ezJENncL8Bom5SX8f4YqkHuiubzVB+WY4Jy5oL5ExjSypXJOg5YJdLmy2Lfrj+Ov1nD0AgFcjZljQz3GfDUCN280AXcqF2lBsdH3hVtfXAL7Q6VNgeXRM+b3MCbqYNPxkpqbhStVvg3/X9GnwxhrSlnLmFTH48MRxo8q3EcjfTa2ms2DLw3vowidsyVeWQgPPRw3EBrJH98BjM0GOkLiMyKgiLSC+r4jU3Z+hncJRYZwS0fplZA27fT8kr975QRyCsGiNBEaI5troFnMSTOBYCddH9hUBxw6NoiLP7+IGwt3t5uFnnnwN/H5zUrxlW3klzEWgr7hTIWj7D/DT+QNlkEGOsYD7mIMRBGnxD8M+LJXZA5GRAS3u7lglH6lkbytHiyfO10R8Ek2fZ5zQ7sC42juAXDaxnFs5U+0YoO2ziZTxEAggPoanYFzNgXVC4YWvc3ogcF6Gaqt0P8wfrQHHtYno1Rv2ehEziGbHrIVMY8imH0sBlZLgcs2GieueQbVUzfQeYC+NFosQ4LayQivs7NtkAgNjqXghbYGlO9igOXY2hYN13z50WQ31+czoVLum2l6XIKyryrnSVbZAfhWP9zx41KzkRpBdjdRMXLGOQz6mNydf+BnzUK6wndfIA3hZJ3vGEm0kpbECWvcM2R2BNifdZl1ddnkRAgyJuIhq83iItKtTxbp8cR QbGAkiWC 2lyQ3iwlfTyGSgORA8vsKMugeg0lOIAzhQy042BBSGsrLu88rd3cd7nqS2kNeaIA0ijYu9XUiUQglp28= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> List-Subscribe: <mailto:majordomo@kvack.org> List-Unsubscribe: <mailto:majordomo@kvack.org> |
Series |
mm/slub: some minor optimization and cleanup
|
expand
|
Changes in v2: - Add VM_BUG_ON(!freelist) after get_freelist() for cpu partial slab case, since it's not possible to happen for this case. - Collect tags. - Link to v1: https://lore.kernel.org/r/20240117-slab-misc-v1-0-fd1c49ccbe70@bytedance.com Hi, This series include a minor optimization of cpu partial slab fastpath, which directly load freelist from cpu partial slab in the likely case. It has small performance improvement in testing: perf bench sched messaging -g 5 -t -l 100000 mm-stable slub-optimize Total time 7.473 7.209 The other two patches are cleanups, which are included for convenience. Thanks for review and comment! Signed-off-by: Chengming Zhou <zhouchengming@bytedance.com> --- Chengming Zhou (3): mm/slub: directly load freelist from cpu partial slab in the likely case mm/slub: remove full list manipulation for non-debug slab mm/slub: remove unused parameter in next_freelist_entry() mm/slub.c | 32 ++++++++++++++------------------ 1 file changed, 14 insertions(+), 18 deletions(-) --- base-commit: ab27740f76654ed58dd32ac0ba0031c18a6dea3b change-id: 20240117-slab-misc-5a5f37a51257 Best regards,