Em Fri, Dec 04, 2020 at 12:37:50AM +0100, Jiri Olsa escreveu: > On Thu, Dec 03, 2020 at 03:22:18PM -0800, Andrii Nakryiko wrote: > > On Thu, Dec 3, 2020 at 2:08 PM Jiri Olsa <jolsa@xxxxxxxxxx> wrote: > > > > > > We can't assume the address size is always size of unsigned > > > long, we have to use directly the ELF's address size. > > > > > > Changing addrs array to __u64 and convert 32 bit address > > > values when copying from ELF section. > > > > > > Signed-off-by: Jiri Olsa <jolsa@xxxxxxxxxx> > > > --- > > > > It looks ok to me, but I didn't expect that changes would be so > > numerous... Makes me wonder if pahole ever supported working with ELF > > files of different bitness. I'll defer to Arnaldo to make a call on > > whether this is necessary. > > so to test this I built 32bit vmlinux and used 64bit pahole > to generate BTF data on both vmlinux and modules, which I > thought was valid use case It is valid, yeah. - Arnaldo > jirka > > > > > > btf_encoder.c | 24 +++++++++++++++++------- > > > 1 file changed, 17 insertions(+), 7 deletions(-) > > > > > > > [...] > > > -- - Arnaldo