From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752541AbdJKODO (ORCPT ); Wed, 11 Oct 2017 10:03:14 -0400 Received: from mx1.redhat.com ([209.132.183.28]:50122 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751814AbdJKODN (ORCPT ); Wed, 11 Oct 2017 10:03:13 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com E44B282111 Authentication-Results: ext-mx02.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx02.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=longman@redhat.com Subject: Re: [PATCH v2 4/5] arm64: locking: Move rwlock implementation over to qrwlocks To: Will Deacon Cc: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Jeremy.Linton@arm.com, peterz@infradead.org, mingo@redhat.com, boqun.feng@gmail.com, paulmck@linux.vnet.ibm.com References: <1507296882-18721-1-git-send-email-will.deacon@arm.com> <1507296882-18721-5-git-send-email-will.deacon@arm.com> <909c3e84-745c-20db-a071-f9e0f2cbe63a@redhat.com> <20171011114905.GA27426@arm.com> From: Waiman Long Organization: Red Hat Message-ID: <36af9f1f-6ca8-aff6-4b78-4b6a25816907@redhat.com> Date: Wed, 11 Oct 2017 10:03:11 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.0 MIME-Version: 1.0 In-Reply-To: <20171011114905.GA27426@arm.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Content-Language: en-US X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.26]); Wed, 11 Oct 2017 14:03:13 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 10/11/2017 07:49 AM, Will Deacon wrote: > Hi Waiman, > >> >> Inlining is good for performance, but it may come with an increase in >> kernel text size. Inlining unlock and unlock_irq are OK, but the other >> inlines will increase the text size of the kernel. Have you measured how >> much size increase will that be? Is there any concern about the >> increased text size? > Yes, I did look at the disassembly and bloat-o-meter results. Inlining > these functions means that the fastpath sits entirely within a 64-byte > cacheline and bloat-o-meter shows a relatively small increase in vmlinux > size for a defconfig build with CONFIG_PREEMPT disabled: > > Total: Before=13800924, After=13812904, chg +0.09% > > (I also just noticed my typos in ARCH_INLINE_{READ.WRITE}_UNLOCK_IRQSAVE > so I regenerated the numbers!) The size increase looks small enough. That may largely due to the fact that rwlocks aren't as frequently used as spinlocks, so the number of call sites are not that many. Anyway, I am OK with that. I just want to make sure that people are aware of this. Cheers, Longman