[PATCH] D62296: [Object] object::ELFObjectFile::symbol_begin(): skip symbol index 0

Chris Jackson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 6 07:27:47 PDT 2019


chrisjackson added a comment.

In D62296#1514082 <https://reviews.llvm.org/D62296#1514082>, @MaskRay wrote:

> In D62296#1514030 <https://reviews.llvm.org/D62296#1514030>, @jhenderson wrote:
>
> > Have you made sure that there aren't any uses which would result in an undesired change in behaviour because of this? I feel like it's something that people wouldn't expect to change, and therefore wouldn't test explicitly necessarily.
> >
> > There should also be a test case somewhere (not that I have a good suggestion for where).
>
>
> I've checked the call sites:
>
> In RuntimeDyld, `if (Flags & SymbolRef::SF_Undefined) continue;` filters out index 0.
>  In llvm-objdump, the filtering code is removed in this patch.
>  In lib/Object/SymbolSize.cpp, I think the code doesn't notice index 0 is included... but it doesn't seem to matter.
>  In llvm-nm.cpp, I'll leave the test to @chrisjackson in D62148 <https://reviews.llvm.org/D62148>


I have included the test as part of D62955 <https://reviews.llvm.org/D62955>.


Repository:
  rL LLVM

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

https://reviews.llvm.org/D62296





More information about the llvm-commits mailing list