From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pf0-f195.google.com ([209.85.192.195]:35956 "EHLO mail-pf0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751108AbdFUMC1 (ORCPT ); Wed, 21 Jun 2017 08:02:27 -0400 Date: Wed, 21 Jun 2017 22:02:13 +1000 From: Nicholas Piggin Subject: Re: [PATCH 1/5] kbuild: thin archives final link close --whole-archives option Message-ID: <20170621220213.2b33d56d@roar.ozlabs.ibm.com> In-Reply-To: References: <20170609052417.561-1-npiggin@gmail.com> <20170619165100.3ce26d00@roar.ozlabs.ibm.com> <20170619182714.2cb60e17@roar.ozlabs.ibm.com> <20170620015205.329519b2@roar.ozlabs.ibm.com> <20170621124708.6bce7692@roar.ozlabs.ibm.com> <20170621140445.4d6fd92a@roar.ozlabs.ibm.com> <20170621191607.33c8db74@roar.ozlabs.ibm.com> <20170621203824.719ffdc5@roar.ozlabs.ibm.com> <20170621211002.44525d9b@roar.ozlabs.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kbuild-owner@vger.kernel.org List-ID: To: Arnd Bergmann Cc: Masahiro Yamada , Linux Kbuild mailing list , linux-arch , Michal Marek , Linus Torvalds , Stephen Rothwell , kbuild test robot , Josh Triplett , Nicolas Pitre On Wed, 21 Jun 2017 13:32:17 +0200 Arnd Bergmann wrote: > On Wed, Jun 21, 2017 at 1:10 PM, Nicholas Piggin wrote: > > On Wed, 21 Jun 2017 12:49:10 +0200 > > Arnd Bergmann wrote: > > > >> On Wed, Jun 21, 2017 at 12:38 PM, Nicholas Piggin wrote: > >> > On Wed, 21 Jun 2017 12:21:16 +0200 > >> > Arnd Bergmann wrote: > >> > > >> > >> I'm building on top of yesterday's linux-next at the moment, > >> with a number of my own patches applied > >> > >> > I can take a look at ARM and try to get it at least to parity with > >> > incremental link. Any particular config options required? > >> > >> This is the patch I am testing with: > >> > >> https://pastebin.com/HQuhCEmK > >> I have not looked at that in a while, no idea if it works, or > >> if it has known problems. > >> > >> I last posted the patch in March for discussion: > >> > >> https://patchwork.kernel.org/patch/9626207/ > > > > Well I just mean the stuff now in kbuild/thin-ac, not the LD_DCDE. > > Just want to try getting thin archives up to a point where there are > > no serious regressions first. > > For my build testing, I have now reverted most of my patch and only > left the 'select THIN_ARCHIVES'. I'll let you know if I run into problems. Okay. Currently with the patches in the kbuild tree, thin archives actually does better than incremental linking for ARM (defconfig). 11651574 6090952 418616 18161142 1151df6 vmlinux.thinarc 11656118 6095208 418952 18170278 11541a6 vmlinux.inc In mainline, thin archives is sub-optimal for lib-y libraries (just pulls them all in). But now that I test it, even that is better than incremental linking for ARM: 11653926 6090888 418620 18163434 11526ea vmlinux.thinarc I haven't grabbed that "clk: sunxi-ng: Move all clock types to a library" patch yet to check. What tree is it in? I wonder if I could convince you to drop that for now and bring it up on linux-kernel/linux-kbuild? I think it's quite reasonable to reduce Kconfig hell of very fine grained conditional compilation/linking if we can make the toolchain do it for us. So we should consider how to support it nicely rather than having such hacks IMO. Thanks, Nick