From patchwork Fri Aug 5 13:32:52 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nicholas Piggin X-Patchwork-Id: 9265427 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id CB5C060760 for ; Fri, 5 Aug 2016 13:48:26 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BC5FC28440 for ; Fri, 5 Aug 2016 13:48:26 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B07BD28444; Fri, 5 Aug 2016 13:48:26 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5F32228440 for ; Fri, 5 Aug 2016 13:48:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1759759AbcHENsZ (ORCPT ); Fri, 5 Aug 2016 09:48:25 -0400 Received: from mail-pa0-f68.google.com ([209.85.220.68]:33353 "EHLO mail-pa0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753746AbcHENsZ (ORCPT ); Fri, 5 Aug 2016 09:48:25 -0400 Received: by mail-pa0-f68.google.com with SMTP id vy10so842951pac.0; Fri, 05 Aug 2016 06:48:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:cc:subject:message-id:in-reply-to:references :organization:mime-version:content-transfer-encoding; bh=rN5Nj6iSxIkoyUnFPxoR4UTGZz8Pl/l2tuvP8PlqlU4=; b=SuTbZ8utbf/Tfsy0Psh/dXo9g8w1sMLmMFkC2zIRgtQvY8kjf23ZxY1JBaC71scxwT y9rWWw1IQ022n1aGOmA5IWJrUeS8hEinBcK8tPOhzFC46aDFmt1qdTc+7z74Jq/4qGdz pkXgv4rsNFmIMGaBt9waNZflzXXJYbsqvNEwkovx9FC+EQ7qeu28c6zI0S3SSm6R3GAm /xFdntN2q5RjyXU/blAcd8lJ/rjP0l2ZIhPjJpffjMjtXZVcM1VR6ldxpisaJF7puwp5 ppir46Ny4K6Sh+2knW6M+0QrNFDHQLHd19PRSEWonOwWhKZbDb8B8iPljeN+36uRQE1B ezSQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:organization:mime-version:content-transfer-encoding; bh=rN5Nj6iSxIkoyUnFPxoR4UTGZz8Pl/l2tuvP8PlqlU4=; b=SpRXj4gnS9Nhb7Ph6DoEp0W0ASPLrQVG7L5GdS85MrqC+IJKnNrihRgtFqgfzANvXD tnYroH5rA+NmYmdmILBaJcaaNPuGK7lFJHQBfN4VGJkZuvC/HnDKryBpq4dY6pxxasgL m18na81NeVR9XoUT3MNZ15J1ONsB35rs5N/huM7f0+EfQij8xO+FqDXiBMQZPHjTTd71 NnHOx8KJnjXDio+SE6BP/mpvC7fatdhvruN272P4rd5JWO4RVjPyzN4BC7cr6b+IJtl1 QIb7J8+2pK1z5oehkSRPG1O9FLjimD88wJqBFoH2M2CGoYMZFZ/7NPPTc3LnmcomDF+m PaOw== X-Gm-Message-State: AEkooutfAGsbUQAfQG2+rdkhUER2eHrvvpHFogJ5FDWccgSJmfA0+PO2oeWWR0dMhbTNtA== X-Received: by 10.66.51.137 with SMTP id k9mr134848527pao.49.1470403980635; Fri, 05 Aug 2016 06:33:00 -0700 (PDT) Received: from roar.ozlabs.ibm.com ([122.99.82.10]) by smtp.gmail.com with ESMTPSA id q26sm28258175pfj.53.2016.08.05.06.32.56 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 05 Aug 2016 06:33:00 -0700 (PDT) Date: Fri, 5 Aug 2016 23:32:52 +1000 From: Nicholas Piggin To: linux-kbuild@vger.kernel.org Cc: linux-arch@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, Stephen Rothwell , Arnd Bergmann , Nicolas Pitre , Segher Boessenkool , Alan Modra Subject: Re: [RFC][PATCH 0/5] kbuild changes, thin archives, --gc-sections Message-ID: <20160805233252.50cb8cce@roar.ozlabs.ibm.com> In-Reply-To: <1470399123-8455-1-git-send-email-npiggin@gmail.com> References: <1470399123-8455-1-git-send-email-npiggin@gmail.com> Organization: IBM X-Mailer: Claws Mail 3.13.2 (GTK+ 2.24.30; x86_64-pc-linux-gnu) MIME-Version: 1.0 Sender: linux-kbuild-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kbuild@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP On Fri, 5 Aug 2016 22:11:58 +1000 Nicholas Piggin wrote: > Hello, > > I have 3 different things in this patchset. All arch specific, but all > involve kbuild changes, so I'd like to discuss them with kbuild > maintainers. The goal has been to improve long standing linking > difficulties with the powerpc kernel. Here's a 30 second hack of an x86 patch. It seems to build and boot defconfig in a really quick kvm test. For x86-64 machine building x86 target, defconfig, make -j8 vmlinux time: orig thinarc thinarc+dce real 4m58.865s 4m59.747s 5m20.028s user 15m14.428s 15m13.868s 15m17.012s sys 0m57.296s 0m55.904s 0m58.416s build output directory size: orig thinarc thinarc+dce 317M 257M 285M vmlinux size: text data bss dec filename 10192338 4360136 1105920 15658394 vmlinux 10186739 4356040 1105920 15648699 vmlinux.thinarc 9580486 3759880 1011712 14352078 vmlinux.thinarc+dce Thanks, Nick --- To unsubscribe from this list: send the line "unsubscribe linux-kbuild" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig index 0a7b885..845069e 100644 --- a/arch/x86/Kconfig +++ b/arch/x86/Kconfig @@ -51,6 +51,8 @@ config X86 select ARCH_WANT_IPC_PARSE_VERSION if X86_32 select ARCH_WANT_OPTIONAL_GPIOLIB select BUILDTIME_EXTABLE_SORT + select THIN_ARCHIVES + select LINKER_DCE select CLKEVT_I8253 select CLKSRC_I8253 if X86_32 select CLOCKSOURCE_VALIDATE_LAST_CYCLE diff --git a/arch/x86/kernel/vmlinux.lds.S b/arch/x86/kernel/vmlinux.lds.S index 9297a00..7395dd8 100644 --- a/arch/x86/kernel/vmlinux.lds.S +++ b/arch/x86/kernel/vmlinux.lds.S @@ -92,7 +92,7 @@ SECTIONS .text : AT(ADDR(.text) - LOAD_OFFSET) { _text = .; /* bootstrapping code */ - HEAD_TEXT + KEEP(HEAD_TEXT) . = ALIGN(8); _stext = .; TEXT_TEXT @@ -321,7 +321,7 @@ SECTIONS .bss : AT(ADDR(.bss) - LOAD_OFFSET) { __bss_start = .; *(.bss..page_aligned) - *(.bss) + *(.bss .bss.*) . = ALIGN(PAGE_SIZE); __bss_stop = .; }