This is an archive of the discontinued LLVM Phabricator instance.

[TRE] Slight refactor and cleanup.
ClosedPublic

Authored by jakev on May 24 2016, 7:21 PM.

Details

Summary

In preparation for porting TailCallElim to the new PassManager, seems like a good idea to do a slight refactor and some cleanup similar to DSE.

Diff Detail

Repository
rL LLVM

Event Timeline

jakev updated this revision to Diff 58377.May 24 2016, 7:21 PM
jakev retitled this revision from to [TRE] Slight refactor and cleanup..
jakev updated this object.
jakev added reviewers: chandlerc, bogner, davide.
jakev set the repository for this revision to rL LLVM.
jakev added a subscriber: llvm-commits.
davide edited edge metadata.May 25 2016, 8:52 PM

This seems a nice cleanup in preparation for porting to the new PM. Some comments inline.

lib/Transforms/Scalar/TailRecursionElimination.cpp
58 ↗(On Diff #58377)

Can you split the include-what-you-use patch?

81 ↗(On Diff #58377)

Probably runOnFunction() and getAnalyisUsage() can be inlined here.

jakev updated this revision to Diff 58693.May 26 2016, 1:57 PM
jakev edited edge metadata.
jakev marked 2 inline comments as done.

Addressed dcci's comments.

jakev updated this revision to Diff 58743.May 26 2016, 7:07 PM

Moved the markTails stuff out of runOnFunction so we don't have to duplicate this when we port to the new PM.

This revision was automatically updated to reflect the committed changes.