[PATCH] D68848: [llvm-objdump] Use a counter for llvm-objdump -h instead of the section index.
Jordan Rupprecht via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 14 10:06:46 PDT 2019
rupprecht marked 3 inline comments as done.
rupprecht added inline comments.
================
Comment at: llvm/tools/llvm-objdump/llvm-objdump.cpp:376
+ // increment so the indexing is stable.
+ return {/*Keep=*/is_contained(FilterSections, SecName),
+ /*IncrementIndex=*/true};
----------------
grimar wrote:
> Can we have a test for this logic? I.e. for a case when `Keep=false`, `IncrementIndex=true`.
> (Doesn't seem we have it)
This is already covered by `llvm/test/tools/llvm-objdump/X86/section-index.s`:
```
# RUN: llvm-objdump -section-headers %t | FileCheck %s
...
# CHECK-NEXT: 4 .bar
# RUN: llvm-objdump -section-headers -section=.bar %t \
# RUN: | FileCheck %s --check-prefix=BAR
...
# BAR-NEXT: 4 .bar
```
I'll mention this in the patch description.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D68848/new/
https://reviews.llvm.org/D68848
More information about the llvm-commits
mailing list