On Tue, 1 Aug 2023 15:28:38 -0300 Arnaldo Carvalho de Melo <arnaldo.melo@xxxxxxxxx> wrote: > Sorry, replied only to Alan :-\ > > - Arnaldo > > ---------- Forwarded message --------- > From: Arnaldo Carvalho de Melo <arnaldo.melo@xxxxxxxxx> > Date: Tue, Aug 1, 2023 at 3:26 PM > Subject: Re: [RESEND] BTF is not generated for gcc-built kernel with > the latest pahole > To: Alan Maguire <alan.maguire@xxxxxxxxxx> > > > On Tue, Aug 1, 2023 at 2:37 PM Alan Maguire <alan.maguire@xxxxxxxxxx> wrote: > > On 01/08/2023 02:01, Masami Hiramatsu (Google) wrote: > > > On Mon, 31 Jul 2023 16:45:24 +0100 > > > Alan Maguire <alan.maguire@xxxxxxxxxx> wrote: > > > >> Unfortunately (or fortunately?) I haven't been able to reproduce so far > > >> I'm afraid. I used your config and built gcc 13 from source; everything > > >> worked as expected, with no warnings or missing functions (aside from > > >> the ones skipped due to inconsistent prototypes etc). > > > > > > Yeah, so I think gcc-11.3 is suspicious too (and it seems fixed in gcc-13). > > See below, but this one is interesting, gcc-13 works with > CONFIG_DEBUG_INFO_DWARF_TOOLCHAIN_DEFAULT=y? I'm using gcc-11.3, and it seems to work. > > > >> One other thing I can think of - is it possible libdw[arf]/libelf > > >> versions might be having an effect here? I'm using libdwarf.so.1.2, > > >> libdw-0.188, libelf-0.188. I can try and match yours. Thanks! > > > > > > Both libdw/libelf are 0.181. I didn't install libdwarf. > > > Hmm, I should update the libdw (elfutils) too. > > > > That might help. Thanks! > > Probably he needs to tweak these CONFIG_ entries: > > ⬢[acme@toolbox perf-tools]$ grep DWARF ../build/v6.2-rc5+/.config > CONFIG_DEBUG_INFO_DWARF_TOOLCHAIN_DEFAULT=y > # CONFIG_DEBUG_INFO_DWARF4 is not set > # CONFIG_DEBUG_INFO_DWARF5 is not set > ⬢[acme@toolbox perf-tools]$ > > And make it use CONFIG_DEBUG_INFO_DWARF4=y, > CONFIG_DEBUG_INFO_DWARF_TOOLCHAIN_DEFAULT=n OK, interesting. Let me check again with DWARF4. Thank you! > > For DWARF5 I need to forward port what I have in: > > https://git.kernel.org/pub/scm/devel/pahole/pahole.git/log/?h=WIP-imported-unit > > - Arnaldo -- Masami Hiramatsu (Google) <mhiramat@xxxxxxxxxx>