[PATCH] D57146: [llvm-objdump] - Print LMAs when dumping section headers.
James Henderson via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jan 28 02:22:45 PST 2019
jhenderson added inline comments.
================
Comment at: test/tools/llvm-objdump/X86/phdrs-lma2.test:3-4
+
+## If there are no sections which has LMA different
+## from VMA, we do not display LMA column.
+# RUN: llvm-objdump --section-headers %t | FileCheck %s
----------------
which has LMA different from VMA -> with different LMA to VMA
================
Comment at: tools/llvm-objdump/llvm-objdump.cpp:183
+cl::opt<bool>
+ ShowLMA("show-lma",
----------------
Can this be `static`?
================
Comment at: tools/llvm-objdump/llvm-objdump.cpp:185
+ ShowLMA("show-lma",
+ cl::desc("Display LMA column when dumping ELF section headers"));
+
----------------
This should probably be in the documentation.
================
Comment at: tools/llvm-objdump/llvm-objdump.cpp:1495
+// show it only when the platform is ELF and either we have at least one section
+// whose VMA and LMA are different or/and when --show-lma flag is used.
+static bool shouldDisplayLMA(const ObjectFile *Obj) {
----------------
It's more common to say "and/or" rather than "or/and".
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D57146/new/
https://reviews.llvm.org/D57146
More information about the llvm-commits
mailing list