This is an archive of the discontinued LLVM Phabricator instance.

Prevent dead uses in register coalescer after rematerialization
ClosedPublic

Authored by rampitec on Jul 20 2021, 2:00 PM.

Details

Summary

The coalescer does not check if register uses are available
at the point of rematerialization. If it attempts to rematerialize
an instruction with such uses it can end up with use without a def.

LiveRangeEdit does such check during rematerialization, so just
call LiveRangeEdit::allUsesAvailableAt() to avoid the problem.

Diff Detail