[PATCH] D75498: [llvm-objdump] Add option to sort symbols during disassembly

James Henderson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 5 01:41:29 PST 2020


jhenderson added a comment.

In D75498#1904130 <https://reviews.llvm.org/D75498#1904130>, @rupprecht wrote:

> Is there a particular use case for this feature?
>
> The loop that prints each symbol might have some more assumptions that it's printed in address order; it's pretty complicated so I didn't fully review it, but I'm not confident this won't introduce some subtle bug. For an initial test, you might want run `llvm-objdump -d --sort` on some large binary, and make sure that it's equivalent to `llvm-objdump -d` after you've reordered the sections with a different post-processing script.


I've not looked at the loop, but unless it handles local and global symbols differently, there can't be any assumption about address order, since locals always appear before globals in the symbol table, regardless of address order.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D75498





More information about the llvm-commits mailing list