Jordan Rupprecht
Jordan Rupprecht
I stumbled across this old bug because we're hitting this issue as well. Chris, I took your patch and applied it in https://reviews.llvm.org/D49330. In the past two years since this...
Should be fixed now after commits r354375 and r356697.
We've also seen issues w/ switching to llvm-objdump (in various build scripts) for these two uses: objdump -thr (i.e. --syms --headers --reloc) objdump -sj.foo (i.e. --full-contents --section=.foo)
Note: --intermediate-format has been replaced with --json-format in gcc trunk: https://gcc.gnu.org/ml/gcc-patches/2018-10/msg00553.html. -i still exists, but is an alias to --json-format.
(retitling to make this clang specific -- see llvm/llvm-bugzilla-archive#41437 for gcc) FWIW, gcc+nm seems to also not provide useful data for these fields when using lto. So I'm not sure...
The relevant bit in GNU ar is here: https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;a=blob;f=binutils/binemul.c;h=894a915716ce39eaec167e93f2c7ad8346c15f99;hb=HEAD#l63 llvm-ar/libObject doesn't seem to flatten archive members.
https://reviews.llvm.org/D53531
https://reviews.llvm.org/D52328 sent
I'm able to get size and llvm-size to agree by making the following changes in libobject (for ELF files): 1) isSectionText needs to include sections where SHF_WRITE is not set...
I happen to be looking at the same thing -- I might as well accept this bug :) Here's LLVM's snippet: ``` // isText(): // return sh_flags & ELF::SHF_EXECINSTR bool...