Page MenuHomePhabricator

Improve the debug-info test created in r274263
ClosedPublic

Authored by ygao on Oct 5 2016, 11:54 AM.

Details

Summary

Hi,
This patch is related to r274263 or Phabricator/D21818.
This patch aims to improve the test case added in the previous commit to verify
specifically that the stack protector pass is adding the debug line info as
intended. Before, the test only verified that the verifier pass does not crash.
The current approach is to generate the assembly output and then look for the
.loc directive.

To recapture from the mailing list, I also attempted to use llc's -start-after
and -stop-after options to run and check a single pass, but it would involve
the MIR format which seems not ready for common use yet.

Please review whether this test seems reasonable,

  • Gao

Diff Detail

Repository
rL LLVM

Event Timeline

ygao updated this revision to Diff 73679.Oct 5 2016, 11:54 AM
ygao retitled this revision from to Improve the debug-info test created in r274263.
ygao updated this object.
ygao added a reviewer: dblaikie.
ygao added subscribers: aprantl, llvm-commits.
dblaikie accepted this revision.Oct 5 2016, 12:23 PM
dblaikie edited edge metadata.

Great - thanks!

(I see now, that the test is already being run for several different architectures - as that's the case, and you did have the right CHECKs for each architecture (& the other tests in the file do test several architectures), feel free to add those back in - seeing only the (somewhat mangled) diff, I wasn't sure if you'd created a test case to specifically run on multiple architectures, extra test invocations, etc - but since this file is already being invoked for all those different targets, CHECKing the result on them seems nice to have)

This revision is now accepted and ready to land.Oct 5 2016, 12:23 PM
This revision was automatically updated to reflect the committed changes.