linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sedat Dilek <sedat.dilek@gmail.com>
To: Nick Desaulniers <ndesaulniers@google.com>
Cc: Masahiro Yamada <masahiroy@kernel.org>,
	Arvind Sankar <nivedita@alum.mit.edu>,
	Jakub Jelinek <jakub@redhat.com>,
	Fangrui Song <maskray@google.com>,
	Caroline Tice <cmtice@google.com>,
	clang-built-linux <clang-built-linux@googlegroups.com>,
	Nick Clifton <nickc@redhat.com>,
	LKML <linux-kernel@vger.kernel.org>,
	Linux Kbuild mailing list <linux-kbuild@vger.kernel.org>
Subject: Re: [PATCH v3 0/2] Kbuild: DWARF v5 support
Date: Thu, 31 Dec 2020 20:27:07 +0100	[thread overview]
Message-ID: <CA+icZUX3WRUfnOsLrSpdGHSR8B=+Nj23wB47-FDYeSkaKneLSA@mail.gmail.com> (raw)
In-Reply-To: <CA+icZUWwNWVQDYUCoo6TQNBOtMqwwEuLJuNO2c8gvihs6jTGOA@mail.gmail.com>

On Mon, Dec 28, 2020 at 4:15 PM Sedat Dilek <sedat.dilek@gmail.com> wrote:
>
> On Sun, Dec 27, 2020 at 7:47 PM Sedat Dilek <sedat.dilek@gmail.com> wrote:
> >
> > On Fri, Dec 4, 2020 at 2:13 AM 'Nick Desaulniers' via Clang Built
> > Linux <clang-built-linux@googlegroups.com> wrote:
> > >
> > > sigh...I ran a broken script to send the series which doesn't cc folks properly.
> > > + lkml, linux-kbuild
> > > (Might just resend, properly)
> > >
> > > On Thu, Dec 3, 2020 at 5:11 PM Nick Desaulniers <ndesaulniers@google.com> wrote:
> > > >
> > > > DWARF v5 is the latest standard of the DWARF debug info format.
> > > >
> > > > DWARF5 wins significantly in terms of size when mixed with compression
> > > > (CONFIG_DEBUG_INFO_COMPRESSED).
> > > >
> > > > Link: http://www.dwarfstd.org/doc/DWARF5.pdf
> > > >
> > > > Patch 1 is a cleanup that lays the ground work and isn't DWARF
> > > > v5 specific.
> > > > Patch 2 implements Kconfig and Kbuild support for DWARFv5.
> > > >
> > > > Changes from v2:
> > > > * Drop two of the earlier patches that have been accepted already.
> > > > * Add measurements with GCC 10.2 to commit message.
> > > > * Update help text as per Arvind with help from Caroline.
> > > > * Improve case/wording between DWARF Versions as per Masahiro.
> > > >
> > > > Changes from the RFC:
> > > > * split patch in 3 patch series, include Fangrui's patch, too.
> > > > * prefer `DWARF vX` format, as per Fangrui.
> > > > * use spaces between assignment in Makefile as per Masahiro.
> > > > * simplify setting dwarf-version-y as per Masahiro.
> > > > * indent `prompt` in Kconfig change as per Masahiro.
> > > > * remove explicit default in Kconfig as per Masahiro.
> > > > * add comments to test_dwarf5_support.sh.
> > > > * change echo in test_dwarf5_support.sh as per Masahiro.
> > > > * remove -u from test_dwarf5_support.sh as per Masahiro.
> > > > * add a -gdwarf-5 cc-option check to Kconfig as per Jakub.
> > > >
> >

[ ... ]

Some more numbers with Linux v5.10.4.

GCC v10.2.1
GNU/ld BFDd v2.35.1
LLD v11.0.1-rc2
LLVM toolchain v11.0.1-rc2

So using GCC with LLD together with DWARF v5 reduces the binary sizes.

Looks like Gmail makes the tabella look ugly...

          | gcc10-bfd | gcc10-lld | gcc10-llvm | clang-ias
----------------------------------------------------------
vmlinux.o | 580212    | 504508    | 504508     | 353864
----------------------------------------------------------
vmlinux   | 503172    | 509944    | 509944     | 358500
----------------------------------------------------------
dbg deb   | 701576    | 606348    | 607656     | 506816

...so I add the lines below.

580212  5.10.4-1-amd64-gcc10-bfd/vmlinux.o
504508  5.10.4-2-amd64-gcc10-lld/vmlinux.o
504508  5.10.4-3-amd64-gcc10-llvm/vmlinux.o
353864  5.10.4-4-amd64-clang-ias/vmlinux.o

503172  5.10.4-1-amd64-gcc10-bfd/vmlinux
509944  5.10.4-2-amd64-gcc10-lld/vmlinux
509944  5.10.4-3-amd64-gcc10-llvm/vmlinux
358500  5.10.4-4-amd64-clang-ias/vmlinux

701576  5.10.4-1-amd64-gcc10-bfd/linux-image-5.10.4-1-amd64-gcc10-bfd-dbg_5.10.4-1~bullseye+dileks1_amd64.deb
606348  5.10.4-2-amd64-gcc10-lld/linux-image-5.10.4-2-amd64-gcc10-lld-dbg_5.10.4-2~bullseye+dileks1_amd64.deb
607656  5.10.4-3-amd64-gcc10-llvm/linux-image-5.10.4-3-amd64-gcc10-llvm-dbg_5.10.4-3~bullseye+dileks1_amd64.deb
506816  5.10.4-4-amd64-clang-ias/linux-image-5.10.4-4-amd64-clang-ias-dbg_5.10.4-4~bullseye+dileks1_amd64.deb

- Sedat -

> >
> > > > Nick Desaulniers (2):
> > > >   Kbuild: make DWARF version a choice
> > > >   Kbuild: implement support for DWARF v5
> > > >
> > > >  Makefile                          | 15 +++++++------
> > > >  include/asm-generic/vmlinux.lds.h |  6 +++++-
> > > >  lib/Kconfig.debug                 | 35 ++++++++++++++++++++++++++-----
> > > >  scripts/test_dwarf5_support.sh    |  9 ++++++++
> > > >  4 files changed, 53 insertions(+), 12 deletions(-)
> > > >  create mode 100755 scripts/test_dwarf5_support.sh
> > > >
> > > > --
> > > > 2.29.2.576.ga3fc446d84-goog
> > > >
> > >
> > >
> > > --
> > > Thanks,
> > > ~Nick Desaulniers
> > >
> > > --
> > > You received this message because you are subscribed to the Google Groups "Clang Built Linux" group.
> > > To unsubscribe from this group and stop receiving emails from it, send an email to clang-built-linux+unsubscribe@googlegroups.com.
> > > To view this discussion on the web visit https://groups.google.com/d/msgid/clang-built-linux/CAKwvOdkZEiHK01OD420USb0j%3DF0LcrnRbauv9Yw26tu-GRbYkg%40mail.gmail.com.

  reply	other threads:[~2020-12-31 19:28 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-04  1:11 [PATCH v3 1/2] Kbuild: make DWARF version a choice Nick Desaulniers
2020-12-04  1:11 ` [PATCH v3 2/2] Kbuild: implement support for DWARF v5 Nick Desaulniers
2021-01-04 22:12   ` Nathan Chancellor
     [not found] ` <20201204011129.2493105-3-ndesaulniers@google.com>
2020-12-04  1:13   ` [PATCH v3 0/2] Kbuild: DWARF v5 support Nick Desaulniers
2020-12-27 18:47     ` Sedat Dilek
2020-12-28 15:15       ` Sedat Dilek
2020-12-31 19:27         ` Sedat Dilek [this message]
2020-12-04  1:18 ` [PATCH v3 1/2] Kbuild: make DWARF version a choice Nick Desaulniers
2021-01-04 22:03 ` Nathan Chancellor

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CA+icZUX3WRUfnOsLrSpdGHSR8B=+Nj23wB47-FDYeSkaKneLSA@mail.gmail.com' \
    --to=sedat.dilek@gmail.com \
    --cc=clang-built-linux@googlegroups.com \
    --cc=cmtice@google.com \
    --cc=jakub@redhat.com \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=masahiroy@kernel.org \
    --cc=maskray@google.com \
    --cc=ndesaulniers@google.com \
    --cc=nickc@redhat.com \
    --cc=nivedita@alum.mit.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).