[PATCH] D81655: [yaml2obj] - Introduce the "NoHeaders" key for "SectionHeaderTable"
George Rimar via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jun 11 07:42:03 PDT 2020
grimar added a comment.
Currently the test\ObjectYAML\MachO\DWARF-pubsections.yaml
fails with it (--docnum=2)
II happens because of the bug in ObjectYAML\MachOEmitter.cpp
It does:
IO.mapOptional("debug_pubnames", DWARF.PubNames);
IO.mapOptional("debug_pubtypes", DWARF.PubTypes);
where
Optional<PubSection> PubNames;
Optional<PubSection> PubTypes;
And since this patch fixes an issue mentioned in the description
(in YAMLTraits.cpp), the following code does not work anymore:
if (Obj.DWARF.PubNames)
Err = DWARFYAML::emitPubSection(OS, *Obj.DWARF.PubNames, Obj.IsLittleEndian);
because `Obj.DWARF.PubNames` was never `Optional::None` previously, but now it is.
Seems previously it always wrote a piece of broken data.
I am going to investigate if I can fix it separatelly from this patch.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D81655/new/
https://reviews.llvm.org/D81655
More information about the llvm-commits
mailing list