[dsymutil] Add -verify option to run DWARF verifier after linking.

Authored by JDevlieghere on Dec 3 2017, 12:57 PM.



This patch adds support for running the DWARF verifier on the linked
debug info files. If the -verify options is specified and verification
fails, dsymutil exists with abort with non-zero exit code. This behavior
is *not* enabled by default.

Diff Detail

JDevlieghere created this revision.Dec 3 2017, 12:57 PM
vsk accepted this revision.Dec 4 2017, 12:03 PM

Looks good to me.

4 ↗(On Diff #125294)

Why are the copies needed?

This revision is now accepted and ready to land.Dec 4 2017, 12:03 PM
probinson added inline comments.
105 ↗(On Diff #125294)

This looks like an unrelated formatting change?
Also later on a couple of extra blank lines were removed. I'm guessing you ran clang-format on the whole file instead of using clang-format-diff. Generally we prefer whitespace/formatting changes to be done separately from functional changes.

JDevlieghere marked 2 inline comments as done.Dec 5 2017, 8:23 AM
JDevlieghere added inline comments.
4 ↗(On Diff #125294)

Thanks! I had copied this from another test where the flat mode mattered and output was written to the temp folder. It's not necessary for this test so we don't need the copies.

105 ↗(On Diff #125294)

Jup, this was unintentional. In addition to git clang-format before uploading the patch, I usually format new code in my editor by visually selecting it. However if you're in normal mode, it formats the whole file which is what must have happened here.

JDevlieghere marked 2 inline comments as done.
aprantl added inline comments.Dec 5 2017, 9:21 AM
210 ↗(On Diff #125535)

should this be gated by --verbose ?

JDevlieghere marked an inline comment as done.
aprantl accepted this revision.Dec 6 2017, 9:11 AM
This revision was automatically updated to reflect the committed changes.