[PATCH] D39021: [llvm-objcopy] Add support for --only-keep and the special way it interacts with -O binary

Jake Ehrlich via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Nov 2 17:09:37 PDT 2017


jakehehrlich added a comment.

> When you talk about relative offsets of sections, are you talking about relative to the segment start? If so, I agree that appears to be the objcopy behaviour, and I'm happy for this to be done in llvm-objcopy. With that change, we should be able to drop the SectionDump class, as the BinaryObject class should give us the functionality we expect for -j, along with the other cases. I think it might be wise to make these changes in a separate pre-requisite review, since it's really a separate issue (e.g. the behaviour we currently have for -R is different to gnu objcopy's, if the first or last section is stripped).

Well I meant the relative offset between any two sections. So .text and .text3 if both in the same segment would be the same distance away from each other in the ELF file as they were in the binary file. But yes, I agree I should add another pre-req and then add this


Repository:
  rL LLVM

https://reviews.llvm.org/D39021





More information about the llvm-commits mailing list