[PATCH] D49472: [WIP] Always create a MCFragment for Mach-O section.
David Blaikie via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 18 07:10:05 PDT 2018
dblaikie added inline comments.
================
Comment at: llvm/lib/MC/MCObjectFileInfo.cpp:955-957
+ return Ctx->getMachOSection("__DWARF", "__debug_types", MachO::S_ATTR_DEBUG,
+ SectionKind::getMetadata(),
+ "debug_types_begin");
----------------
How does this section get deduplicated by the linker? (I don't see the 'Hash' being used here, which is the unique key for the section)
================
Comment at: llvm/lib/MC/MCObjectFileInfo.cpp:960-964
+ return Ctx->getCOFFSection(".debug_types",
+ COFF::IMAGE_SCN_MEM_DISCARDABLE |
+ COFF::IMAGE_SCN_CNT_INITIALIZED_DATA |
+ COFF::IMAGE_SCN_MEM_READ,
+ SectionKind::getMetadata(), "debug_types");
----------------
Similarly here..
================
Comment at: llvm/lib/MC/MCObjectFileInfo.cpp:969
+ case Triple::Wasm:
+ return Ctx->getWasmSection(".debug_info", SectionKind::getMetadata());
+ case Triple::UnknownObjectFormat:
----------------
I assume this is incorrect (given that this function is for the debug_types section (& should be comdat or equivalent) rather than debug_info)?
https://reviews.llvm.org/D49472
More information about the llvm-commits
mailing list