OSDN Git Service

[llvm-objdump] Dump inline relocations if the relocated section is specified with...
authorFangrui Song <maskray@google.com>
Wed, 22 May 2019 15:12:51 +0000 (15:12 +0000)
committerFangrui Song <maskray@google.com>
Wed, 22 May 2019 15:12:51 +0000 (15:12 +0000)
commit93cf9afa9eb5262fadedc17b33c5185a2405bade
treeb6f26a9778bdf5df2785986829a55969817d539d
parent291b5b2fc8299b097e0436645ad4427ccf8d8032
[llvm-objdump] Dump inline relocations if the relocated section is specified with --section

This fixes PR41886: llvm-objdump -d -r -j .text doesn't show inline relocations of .text

While here, switch to stable_sort() because we don't want to change the order of relocations applied to the same location. gABI says consecutive relocation records are composed together and their order matters. In practise it is difficult to see relocations applied to the same location not consecutive, we just have to keep the relative order of relocations with the same offset.

Reviewed By: grimar

Differential Revision: https://reviews.llvm.org/D62253

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@361395 91177308-0d34-0410-b5e6-96231b3b80d8
test/tools/llvm-objdump/X86/section-filter-relocs.test
tools/llvm-objdump/llvm-objdump.cpp