[PATCH] D74205: [llvm-dwarfdump] Add the --show-sections-sizes option

Djordje Todorovic via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Mar 13 00:50:45 PDT 2020


djtodoro marked an inline comment as done.
djtodoro added inline comments.


================
Comment at: llvm/tools/llvm-dwarfdump/SectionSizes.cpp:55
+
+bool isDebugSection(StringRef SectionName) {
+  return SectionName.startswith(".debug") ||
----------------
aprantl wrote:
> djtodoro wrote:
> > aprantl wrote:
> > > Shouldn't this be in libObject instead?
> > Since the ELF does not consider the '__debug*' as debug sections, I would use this locally.
> Wait, so now I'm confused :-)
> 
> `__debug*` is the Mach-O section name for the ELF `.debug`* sections (because of different naming rules and constraints). I don't think you would ever have a `__debug*` section in a n ELF object. So this should be implementable as a virtual method in `ObjectFile`, right?
Oh right, we do not need to implement it within `ElfObjectFile`, that makes sense :)


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

https://reviews.llvm.org/D74205





More information about the llvm-commits mailing list