From owner-svn-src-head@FreeBSD.ORG Wed Oct 31 22:55:45 2012 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 62127D3D; Wed, 31 Oct 2012 22:55:45 +0000 (UTC) (envelope-from asmrookie@gmail.com) Received: from mail-la0-f54.google.com (mail-la0-f54.google.com [209.85.215.54]) by mx1.freebsd.org (Postfix) with ESMTP id F14898FC14; Wed, 31 Oct 2012 22:55:43 +0000 (UTC) Received: by mail-la0-f54.google.com with SMTP id e12so1817886lag.13 for ; Wed, 31 Oct 2012 15:55:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:reply-to:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=ZflBhTTJ//NO9sHnaQq4nqJThCNPN+3hTRP9IwwkK5c=; b=dek9IKSOL0Cg6uNU8vj7A3DgPjxHHUXYkTTxNCEF5miyfKonhackce/eLYV9crg7k8 9cOcBFF69Gm2+IhB9oIU9OjfwhTRQprliTEbIiuxnb3Ro1c7EoYcJadJQf9ONS3ShEdI 16XQQEmKqYSljP1TcL+IJ94vKQ8ucVqMoZqeyJVq9fFltSC08Stgm/KS1w7bthBctoRl MmzJukjiVbzVWgFq6+XyVmDQ6WWFv+eqr4USV0WQ/xgFTHKosuco0bVAWAw/YkMqwayc 6HKgw0KFJCV96Sczc4V/P4pn8im1fvDx5r6gOqvklj/0gzmcSZWMVRvW9VL7R5QktLDx st9g== MIME-Version: 1.0 Received: by 10.112.36.200 with SMTP id s8mr15434822lbj.92.1351724142727; Wed, 31 Oct 2012 15:55:42 -0700 (PDT) Sender: asmrookie@gmail.com Received: by 10.112.30.37 with HTTP; Wed, 31 Oct 2012 15:55:42 -0700 (PDT) In-Reply-To: <50918AAD.2090906@freebsd.org> References: <201210311807.q9VI7IcX000993@svn.freebsd.org> <1351707964.1120.97.camel@revolution.hippie.lan> <20121031193020.GJ3309@server.rulingia.com> <1351712425.1120.109.camel@revolution.hippie.lan> <50918AAD.2090906@freebsd.org> Date: Wed, 31 Oct 2012 22:55:42 +0000 X-Google-Sender-Auth: Z8g6BNw5RhPFOC4g5RrYO-9Cmmo Message-ID: Subject: Re: svn commit: r242402 - in head/sys: kern vm From: Attilio Rao To: Andre Oppermann Content-Type: text/plain; charset=UTF-8 Cc: Ian Lepore , Adrian Chadd , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org, Peter Jeremy X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: attilio@FreeBSD.org List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 31 Oct 2012 22:55:45 -0000 On Wed, Oct 31, 2012 at 8:31 PM, Andre Oppermann wrote: > On 31.10.2012 20:40, Ian Lepore wrote: >> >> On Thu, 2012-11-01 at 06:30 +1100, Peter Jeremy wrote: >>> >>> On 2012-Oct-31 18:57:37 +0000, Attilio Rao wrote: >>>> >>>> On 10/31/12, Adrian Chadd wrote: >>>>> >>>>> Right, but you didn't make it configurable for us embedded peeps who >>>>> still care about memory usage. >>>> >>>> >>>> How is this possible without breaking the module/kernel ABI? >>> >>> >>> Memory usage may override ABI compatibility in an embedded environment. >>> >>>> All that assuming you can actually prove a real performance loss even >>>> in the new cases. >>> >>> >>> The issue with padding on embedded systems is memory utilisation rather >>> than performance. >>> >> >> There are potential performance hits too, in that embedded systems tend >> to have tiny caches (16K L1 with no L2, that sort of thing), so >> purposely padding things so that large parts of a cache line aren't used >> for anything wastes a scarce resource. > > > You can define CACHE_LINE_SIZE to 0 on those platforms. > Or to make it even more granular there could be a CACHE_LINE_SIZE_LOCKS > that is used for lock padding. I think that this is a bright idea, albeit under the condition that just like CACHE_LINE_SIZE it won't change during STABLE branches timeframe and that it must not be dependent by SMP option. What do you think about this patch?: http://www.freebsd.org/~attilio/cache_line_size_locks.patch Thanks, Attilio -- Peace can only be achieved by understanding - A. Einstein