This is an archive of the discontinued LLVM Phabricator instance.

[obj2yaml,yaml2obj] Add NumBlocks to the BBAddrMapEntry yaml field.
ClosedPublic

Authored by rahmanl on Feb 16 2021, 6:56 PM.

Details

Summary

As discussed in D95511, this allows us to encode invalid BBAddrMap
sections to be used in more rigorous testing.

Diff Detail

Event Timeline

rahmanl created this revision.Feb 16 2021, 6:56 PM
rahmanl requested review of this revision.Feb 16 2021, 6:56 PM
Herald added a project: Restricted Project. · View Herald TranscriptFeb 16 2021, 6:56 PM
jhenderson accepted this revision.Feb 17 2021, 12:47 AM

LGTM, with nits.

llvm/lib/ObjectYAML/ELFEmitter.cpp
1362
llvm/test/tools/obj2yaml/ELF/bb-addr-map.yaml
133
llvm/tools/obj2yaml/elf2yaml.cpp
864

clang-format seems to recognise this comment styling, and it seems clearer to me.

This revision is now accepted and ready to land.Feb 17 2021, 12:47 AM
rahmanl updated this revision to Diff 324446.Feb 17 2021, 3:35 PM
rahmanl marked 3 inline comments as done.
  • Typos and format.
rahmanl updated this revision to Diff 324449.Feb 17 2021, 3:38 PM
  • rebase.
This revision was landed with ongoing or failed builds.Feb 17 2021, 3:45 PM
This revision was automatically updated to reflect the committed changes.

It looks like you somehow pushed an older version of this change? Several of the typos/minor changes you fixed in previous iterations have been undone. Please take a look and fix accordingly.

I used this link to spot differences that look bad to me: https://reviews.llvm.org/D96831?vs=324449&id=324451#toc

llvm/lib/ObjectYAML/ELFYAML.cpp
1668

This line probably should be above the BBEntries line, right?

llvm/test/tools/obj2yaml/ELF/bb-addr-map.yaml
133

I don't think this typo (the missing "the" before "section") has been fixed.

llvm/tools/obj2yaml/elf2yaml.cpp
864

Similarly, this issue hasn't been addressed in the actual commit that appears on github.

rahmanl reopened this revision.Feb 22 2021, 5:46 PM
This revision is now accepted and ready to land.Feb 22 2021, 5:46 PM
rahmanl updated this revision to Diff 325628.Feb 22 2021, 5:50 PM
  • Typos and formatting.

It looks like you somehow pushed an older version of this change? Several of the typos/minor changes you fixed in previous iterations have been undone. Please take a look and fix accordingly.

I used this link to spot differences that look bad to me: https://reviews.llvm.org/D96831?vs=324449&id=324451#toc

My bad, Not sure how this happened. I am pushing the version with fixes now.

rahmanl updated this revision to Diff 325630.Feb 22 2021, 6:01 PM
  • Typos and formatting.
rahmanl updated this revision to Diff 325632.Feb 22 2021, 6:02 PM
  • Typos and formatting.
This revision was landed with ongoing or failed builds.Feb 22 2021, 6:09 PM
This revision was automatically updated to reflect the committed changes.
Harbormaster completed remote builds in B90308: Diff 325632.