This is an archive of the discontinued LLVM Phabricator instance.

[DWARFYAML][debug_info] Make the 'Values' field optional.
ClosedPublic

Authored by Higuoxing on Aug 5 2020, 10:27 PM.

Details

Summary

This patch makes the 'Values' field optional. This is useful when we
handcraft the terminating entry of DIEs.

debug_info:
  - Version:  4
    ...
    Entries:
      - AbbrCode: 1
        Values:
          - Value: 0x1234
      - AbbrCode: 0 ## Termination

Diff Detail

Event Timeline

Higuoxing created this revision.Aug 5 2020, 10:27 PM
Higuoxing requested review of this revision.Aug 5 2020, 10:27 PM
grimar accepted this revision.Aug 6 2020, 2:23 AM

LGTM. Though better wait for a second opinion.

llvm/test/tools/yaml2obj/ELF/DWARF/debug-info.yaml
846

the 'Values' entry -> the Values` key for an entry` I guess is more clear.
(At first I thought hat Values is a property of debug_info.)

This revision is now accepted and ready to land.Aug 6 2020, 2:23 AM
jhenderson accepted this revision.Aug 6 2020, 2:33 AM

LGTM too.

Higuoxing updated this revision to Diff 283582.Aug 6 2020, 5:43 AM
Higuoxing marked an inline comment as done.

Address review comments.

Thanks for reviewing!

This revision was landed with ongoing or failed builds.Aug 6 2020, 5:44 AM
This revision was automatically updated to reflect the committed changes.