Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id ; Sat, 26 Oct 2002 18:05:57 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id ; Sat, 26 Oct 2002 18:05:56 -0400 Received: from pc1-cwma1-5-cust42.swa.cable.ntl.com ([80.5.120.42]:61387 "EHLO irongate.swansea.linux.org.uk") by vger.kernel.org with ESMTP id ; Sat, 26 Oct 2002 18:05:56 -0400 Subject: Re: [PATCH,RFC] faster kmalloc lookup From: Alan Cox To: Manfred Spraul Cc: Linux Kernel Mailing List In-Reply-To: <3DBAEB64.1090109@colorfullife.com> References: <3DBAEB64.1090109@colorfullife.com> Content-Type: text/plain Content-Transfer-Encoding: 7bit X-Mailer: Ximian Evolution 1.0.8 (1.0.8-10) Date: 26 Oct 2002 23:30:12 +0100 Message-Id: <1035671412.13032.125.camel@irongate.swansea.linux.org.uk> Mime-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 789 Lines: 17 On Sat, 2002-10-26 at 20:22, Manfred Spraul wrote: > kmalloc spends a large part of the total execution time trying to find > the cache for the passed in size. > > What about the attached patch (against 2.5.44-mm5)? > It uses fls jump over the caches that are definitively too small. Out of curiousity how does fls compare with finding the right cache by using a binary tree walk ? A lot of platforms seem to use generic_fls which has a lot of conditions in it and also a lot of references to just computed values that look likely to stall - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/