[PATCH] D47404: llvm-objcopy: Set sh_link to 0 on unrecognized symtab-linked sections.

James Henderson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue May 29 02:02:08 PDT 2018


jhenderson accepted this revision.
jhenderson added a comment.

LGTM with the suggested test change.

I'm not a massive fan of this behaviour, but it makes sense to follow GNU's lead on this until such point as there's a standards-defined way of doing it. I'm assuming that all tools out there already know how to consume such special sections.



================
Comment at: llvm/test/tools/llvm-objcopy/symtab-link.test:2
+# RUN: yaml2obj %s > %t
+# RUN: llvm-objcopy %t %t2
+# RUN: llvm-readobj -sections %t2 | FileCheck %s
----------------
Based on a comment I think I saw in the gABI thread, that suggests that it's important for llvm-strip to follow the same behaviour, would it be worth adding an equivalent case using llvm-strip? There are some other tests that show how we typically do this.


https://reviews.llvm.org/D47404





More information about the llvm-commits mailing list