This is an archive of the discontinued LLVM Phabricator instance.

AArch64: Add missing branch relaxation tests
ClosedPublic

Authored by arsenm on Jul 27 2016, 3:54 PM.

Details

Reviewers
rovka
Summary

The branch relaxation pass has the worst test coverage
of any pass in AArch64. Add a few tests that hit some
large pieces of code in the pass.

http://llvm.org/reports/coverage/lib/Target/AArch64/AArch64BranchRelaxation.cpp.gcov.html

Diff Detail

Event Timeline

arsenm updated this revision to Diff 65826.Jul 27 2016, 3:54 PM
arsenm retitled this revision from to AArch64: Add missing branch relaxation tests.
arsenm updated this object.
arsenm added a subscriber: llvm-commits.
rovka accepted this revision.Jul 28 2016, 1:26 AM
rovka added a reviewer: rovka.
rovka added a subscriber: rovka.

Thanks for working on this. Could you please rename the test files to branch-relax-blah.ll? (To match the already-existing branch-relax-asm.ll).

lib/Target/AArch64/AArch64InstrInfo.cpp
134

I'd rather move this closer to the point of use, because that would make the need for it clearer. But that's just personal preference.

This revision is now accepted and ready to land.Jul 28 2016, 1:26 AM
arsenm added inline comments.Jul 28 2016, 11:16 AM
lib/Target/AArch64/AArch64InstrInfo.cpp
134

Do you mean into the pass itself?

arsenm added inline comments.Jul 28 2016, 11:19 AM
lib/Target/AArch64/AArch64InstrInfo.cpp
134

I'm trying to move the target specific details out of the pass, to I don't think it should go there

rovka added inline comments.Jul 29 2016, 1:55 AM
lib/Target/AArch64/AArch64InstrInfo.cpp
134

No, I guess the pass itself is too far off, and it's probably just as well if it lives here or in isBranchInRange. LGTM as it is, thanks.

arsenm closed this revision.Aug 2 2016, 12:49 AM

Test in r277428, splitting the assert to a later patch