[PATCH] D58116: [llvm-objcopy] Improve section removal

Jake Ehrlich via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 14 15:05:59 PST 2019


jakehehrlich added a comment.

Can we get an explicit real use case for this or a case where not removing these sections is detrimental? I believe this to be fundamentally wrong otherwise. Imagine what would happen if you first ran --strip-sections and then ran literally anything again. It's also a primary tenant so far that we not modify program headers. That's how we maintain that stripping not affect run time behavior so trivially. This diff changes that.

The one use case I'm aware of that would modify program headers is to add a program header so that a special chunk of data can be used at runtime that isn't available until after the binary is linked (because it is in part a way to verify that the correct binary is loaded or something like that; I'm not sure about the details)


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

https://reviews.llvm.org/D58116





More information about the llvm-commits mailing list