From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 571CFC433EF for ; Sat, 9 Oct 2021 00:34:12 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id A627F60FD7 for ; Sat, 9 Oct 2021 00:34:11 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org A627F60FD7 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=infradead.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kvack.org Received: by kanga.kvack.org (Postfix) id E31316B0071; Fri, 8 Oct 2021 20:34:10 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id DE0F2900002; Fri, 8 Oct 2021 20:34:10 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id CCED36B0073; Fri, 8 Oct 2021 20:34:10 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0070.hostedemail.com [216.40.44.70]) by kanga.kvack.org (Postfix) with ESMTP id BD9C96B0071 for ; Fri, 8 Oct 2021 20:34:10 -0400 (EDT) Received: from smtpin35.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay04.hostedemail.com (Postfix) with ESMTP id 7D6D33A2D8 for ; Sat, 9 Oct 2021 00:34:10 +0000 (UTC) X-FDA: 78675027060.35.AFCB7BD Received: from casper.infradead.org (casper.infradead.org [90.155.50.34]) by imf12.hostedemail.com (Postfix) with ESMTP id 24C4C1000A8A for ; Sat, 9 Oct 2021 00:34:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=xql+N3ib1eUlIjDNmObuElGGVllxpdEKF1ivrtTjnA4=; b=wSc1Df6rvCC4r06ynh69vQYqGw fe7y5D5XS7RiFwKZLwNYmFEoRjG6XG4H/m8JcH4WzhjljjJJ2tbuzxJqNW22w4ugJtgXCs/SGg0UI whzTQZgIjcKM4EICtdR3/bzBiSsRECIve1L+kkDBeGhJp1Ku8NXZmSHcTpjzYQxUqdClwt8O0qLYW HIX7MVhwdsfMMJrJgKSwtSUnRAa//y43nX6LPBsHKYt8t2XxZUeanjwEFs7phr48LVDp7VXoyzA+f /YLmeeoZUrqVhb9ycDgw+nIKNWVdqA25tSbAFse0c9X8tiXzQC/JGG0YbtNy8fL/ED2Y2INZ/W08L wcVJZFrg==; Received: from willy by casper.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1mZ0J5-003kwH-W8; Sat, 09 Oct 2021 00:33:51 +0000 Date: Sat, 9 Oct 2021 01:33:43 +0100 From: Matthew Wilcox To: Hyeonggon Yoo <42.hyeyoo@gmail.com> Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, Christoph Lameter , Pekka Enberg , David Rientjes , Joonsoo Kim , Andrew Morton , Vlastimil Babka Subject: Re: [RFC] Some questions and an idea on SLUB/SLAB Message-ID: References: <20211009001903.GA3285@kvm.asia-northeast3-a.c.our-ratio-313919.internal> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20211009001903.GA3285@kvm.asia-northeast3-a.c.our-ratio-313919.internal> X-Rspamd-Queue-Id: 24C4C1000A8A X-Stat-Signature: j39eekn9t848x37qpsnw7q6zryfjmu4a Authentication-Results: imf12.hostedemail.com; dkim=pass header.d=infradead.org header.s=casper.20170209 header.b=wSc1Df6r; spf=none (imf12.hostedemail.com: domain of willy@infradead.org has no SPF policy when checking 90.155.50.34) smtp.mailfrom=willy@infradead.org; dmarc=none X-Rspamd-Server: rspam06 X-HE-Tag: 1633739648-848951 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: On Sat, Oct 09, 2021 at 12:19:03AM +0000, Hyeonggon Yoo wrote: > - Is there a reason that SLUB does not implement cache coloring? > it will help utilizing hardware cache. Especially in block layer, > they are literally *squeezing* its performance now. Have you tried turning off cache colouring in SLAB and seeing if performance changes? My impression is that it's useful for caches with low associativity (direct mapped / 2-way / 4-way), but loses its effectiveness for caches with higher associativity. For example, my laptop: L1 Data Cache: 48KB, 12-way associative, 64 byte line size L1 Instruction Cache: 32KB, 8-way associative, 64 byte line size L2 Unified Cache: 1280KB, 20-way associative, 64 byte line size L3 Unified Cache: 12288KB, 12-way associative, 64 byte line size I very much doubt that cache colouring is still useful for this machine.