This is an archive of the discontinued LLVM Phabricator instance.

Reapply r160194, switching to use LV information for finding local kills.
ClosedPublic

Authored by chandlerc on Jul 14 2012, 4:19 AM.

Details

Reviewers
bkramer
Summary

The notable fix is to look at any dependencies attached to the kill
instruction (or other instructions between MI nad the kill) where the
dependencies are specific to the register in question.

The old code implicitly handled this by rejecting the transform if *any*
other uses were found within the block, but after the start point. The
new code directly finds the kill, and has to re-use the existing
dependency scan to check for non-kill uses.

This was caught by self-host, but I found the bug via inspection and use
of absurd assert scaffolding to compute the kills in two ways and
compare them. So I have no useful testcase for this other than
"bootstrap". I'd work harder to reduce a test case if this particular
code were likely to live for a long time.

Diff Detail