lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+icZUX576Rt7HJ4hvrwRTCC2pTmoH-Yu-haU+MDb8B6yADAYA@mail.gmail.com>
Date:   Fri, 29 Jan 2021 23:23:46 +0100
From:   Sedat Dilek <sedat.dilek@...il.com>
To:     Nick Desaulniers <ndesaulniers@...gle.com>
Cc:     Masahiro Yamada <masahiroy@...nel.org>,
        Nathan Chancellor <natechancellor@...il.com>,
        Andrew Morton <akpm@...ux-foundation.org>,
        LKML <linux-kernel@...r.kernel.org>,
        Clang-Built-Linux ML <clang-built-linux@...glegroups.com>,
        Linux Kbuild mailing list <linux-kbuild@...r.kernel.org>,
        linux-arch <linux-arch@...r.kernel.org>,
        Jakub Jelinek <jakub@...hat.com>,
        Fangrui Song <maskray@...gle.com>,
        Caroline Tice <cmtice@...gle.com>,
        Nick Clifton <nickc@...hat.com>, Yonghong Song <yhs@...com>,
        Jiri Olsa <jolsa@...nel.org>,
        Andrii Nakryiko <andrii@...nel.org>,
        Arnaldo Carvalho de Melo <acme@...nel.org>,
        Arvind Sankar <nivedita@...m.mit.edu>
Subject: Re: [PATCH v6 2/2] Kbuild: implement support for DWARF v5

On Fri, Jan 29, 2021 at 11:21 PM Nick Desaulniers
<ndesaulniers@...gle.com> wrote:
>
> On Fri, Jan 29, 2021 at 2:11 PM Sedat Dilek <sedat.dilek@...il.com> wrote:
> >
> > On Fri, Jan 29, 2021 at 11:09 PM Nick Desaulniers
> > <ndesaulniers@...gle.com> wrote:
> > >
> > > On Fri, Jan 29, 2021 at 1:20 PM Sedat Dilek <sedat.dilek@...il.com> wrote:
> > > >
> > > > On Fri, Jan 29, 2021 at 10:13 PM Sedat Dilek <sedat.dilek@...il.com> wrote:
> > > > >
> > > > > On Fri, Jan 29, 2021 at 10:09 PM Nick Desaulniers
> > > > > <ndesaulniers@...gle.com> wrote:
> > > > > >
> > > > > > On Fri, Jan 29, 2021 at 12:55 PM Sedat Dilek <sedat.dilek@...il.com> wrote:
> > > > > > >
> > > > > > > On Fri, Jan 29, 2021 at 9:48 PM Nick Desaulniers
> > > > > > > <ndesaulniers@...gle.com> wrote:
> > > > > > > >
> > > > > > > > On Fri, Jan 29, 2021 at 12:41 PM Sedat Dilek <sedat.dilek@...il.com> wrote:
> > > > > > > > >
> > > > > > > > > On Fri, Jan 29, 2021 at 8:43 PM Nick Desaulniers
> > > > > > > > > <ndesaulniers@...gle.com> wrote:
> > > > > > > > > >
> > > > > > > > > > diff --git a/Makefile b/Makefile
> > > > > > > > > > index 20141cd9319e..bed8b3b180b8 100644
> > > > > > > > > > --- a/Makefile
> > > > > > > > > > +++ b/Makefile
> > > > > > > > > > @@ -832,8 +832,20 @@ endif
> > > > > > > > > >
> > > > > > > > > >  dwarf-version-$(CONFIG_DEBUG_INFO_DWARF2) := 2
> > > > > > > > > >  dwarf-version-$(CONFIG_DEBUG_INFO_DWARF4) := 4
> > > > > > > > > > +dwarf-version-$(CONFIG_DEBUG_INFO_DWARF5) := 5
> > > > > > > > > >  DEBUG_CFLAGS   += -gdwarf-$(dwarf-version-y)
> > > > > > > > > >
> > > > > > > > > > +# If using clang without the integrated assembler, we need to explicitly tell
> > > > > > > > > > +# GAS that we will be feeding it DWARF v5 assembler directives. Kconfig should
> > > > > > > > > > +# detect whether the version of GAS supports DWARF v5.
> > > > > > > > > > +ifdef CONFIG_CC_IS_CLANG
> > > > > > > > > > +ifneq ($(LLVM_IAS),1)
> > > > > > > > > > +ifeq ($(dwarf-version-y),5)
> > > > > > > > > > +DEBUG_CFLAGS   += -Wa,-gdwarf-5
> > > > > > > > >
> > > > > > > > > I noticed double "-g -gdwarf-5 -g -gdwarf-5" (a different issue) and
> > > > > > > > > that's why I looked again into the top-level Makefile.
> > > > > > > >
> > > > > > > > That's...unexpected.  I don't see where that could be coming from.
> > > > > > > > Can you tell me please what is the precise command line invocation of
> > > > > > > > make and which source file you observed this on so that I can
> > > > > > > > reproduce?
> > > > > > > >
> > > > > > >
> > > > > > > That's everywhere...
> > > > > > >
> > > > > > > $ zstdgrep --color '\-g -gdwarf-5 -g -gdwarf-5'
> > > > > > > build-log_5.11.0-rc5-8-amd64-clang12-lto.txt.zst
> > > > > > > | wc -l
> > > > > > > 29529
> > > > > >
> > > > > > I'm not able to reproduce.
> > > > > >
> > > > > > $ make LLVM=1 -j72 V=1 2>&1 | grep dwarf
> > > > > > ...
> > > > > > clang ... -g -gdwarf-5 -Wa,-gdwarf-5 ...
> > > > > > ...
> > > > > >
> > > > > > $ make LLVM=1 LLVM_IAS=1 -j72 V=1 2>&1 | grep dwarf
> > > > > > ...
> > > > > > clang ... -g -gdwarf-5 ...
> > > > > > ...
> > > > > >
> > > > >
> > > > > Hmm...
> > > > >
> > > > > I do not see in my current build "-Wa,-gdwarf-5" is passed with v6.
> > > > >
> > > > > $ grep '\-Wa,-gdwarf-5' build-log_5.11.0-rc5-10-amd64-clang12-lto-pgo.txt
> > > > > [ empty ]
> > > > >
> > > >
> > > > That's the diff v5 -> v6...
> > > >
> > > > There is no more a dwarf-aflag / KBUILD_AFLAGS += $(dwarf-aflag) used.
> > >
> > > Yep; not sure that's relevant though to duplicate flags?
> > >
> > > > > > Can you tell me please what is the precise command line invocation of
> > > > > > make and which source file you observed this on so that I can
> > > > > > reproduce?
> > >
> > > If you don't send me your invocation of `make`, I cannot help you.
> > >
> >
> > /usr/bin/perf_5.10 stat make V=1 -j4 LLVM=1 LLVM_IAS=1
> > PAHOLE=/opt/pahole/bin/pahole LOCALVERSION=-10-amd64-clang12
> > -lto-pgo KBUILD_VERBOSE=1 KBUILD_BUILD_HOST=iniza
> > KBUILD_BUILD_USER=sedat.dilek@...il.com
> > KBUILD_BUILD_TIMESTAMP=2021-01-29 bindeb-pkg
> > KDEB_PKGVERSION=5.11.0~rc5-10~bullseye+dileks1
>
> $ make LLVM=1 LLVM_IAS=1 -j72 defconfig
> $ make LLVM=1 LLVM_IAS=1 -j72 menuconfig
> <enable CONFIG_DEBUG_INFO and CONFIG_DEBUG_INFO_DWARF5>
> $ make LLVM=1 LLVM_IAS=1 -j72 V=1 &> log.txt
> $ grep '\-g -gdwarf-5 -g -gdwarf-5' log.txt | wc -l
> 0
> $ grep '\-g -gdwarf-5' log.txt | wc -l
> 2517
>
> Do have the patch applied twice, perhaps?
>
> Is your compiler haunted, or is mine? (haha! they both are; false
> dichotomy; they are one in the same).  Is zstdgrep haunted, or is GNU
> grep haunted? :P
>

Switched to my v6 local Git branch and invoked above make line I gave you.
I still see that double.
Looks like I need some "undrunken" switch.

- Sedat -

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ