[PATCH] D56840: [llvm-objcopy] [COFF] Implement --only-keep-debug

Jordan Rupprecht via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 18 14:17:00 PST 2019


rupprecht accepted this revision.
rupprecht added inline comments.


================
Comment at: test/tools/llvm-objcopy/COFF/only-keep-debug.test:5
+RUN: llvm-readobj --sections %t.out.exe | FileCheck %s --check-prefix=SECTIONS
+RUN: llvm-objdump -t %t.out.exe | FileCheck %s --check-prefix=SYMBOLS
+
----------------
mstorsjo wrote:
> jhenderson wrote:
> > You don't need to change this, but the GNU style of llvm-readobj also provides symbol dumping in the style you are looking at. It may be useful to use that instead, if you want to keep things to one run of llvm-readobj.
> Hmm, how do you activate that? Do you mean `--elf-output-style=GNU`, or something else? That one doesn't seem to have any effect when inspecting a COFF file.
Yes, or invoke "llvm-readelf" instead of "llvm-readobj" sets that flag (among a few other minor tweaks). But it looks like that flag is only used in ELFDumper which explains why nothing changes for COFF. If you're feeling adventurous, you might want to handle that in COFFDumper, but that would be a major patch.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D56840/new/

https://reviews.llvm.org/D56840





More information about the llvm-commits mailing list