This is an archive of the discontinued LLVM Phabricator instance.

Fix LDV InstrRefBasedImpl to not crash when encountering unreachable MBBs.
ClosedPublic

Authored by aprantl on Aug 2 2022, 10:38 AM.

Details

Summary

The testcase was delta-reduced from an LTO build with sanitizer
coverage and the MIR tail duplication pass caused a machine basic
block to become unreachable in MIR. This caused the MBB to be invisible
to the reverse post-order traversal used to initialize the MBB <->
RPONumber lookup tables.

rdar://97226240

Diff Detail

Event Timeline

aprantl created this revision.Aug 2 2022, 10:38 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 2 2022, 10:38 AM
Herald added a subscriber: hiraditya. · View Herald Transcript
aprantl requested review of this revision.Aug 2 2022, 10:38 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 2 2022, 10:38 AM
aprantl retitled this revision from Fix LDV InstrRefBasedImpl to no crash when encountering unreachable MBBs. to Fix LDV InstrRefBasedImpl to not crash when encountering unreachable MBBs..Aug 2 2022, 10:38 AM
This revision was not accepted when it landed; it landed in state Needs Review.Aug 3 2022, 1:06 PM
This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.

Sorry, I just accidentally pushed this together with a different patch!
I *think* this should be a fairly uncontroversial patch,so I'm going to leave it in for now, but please let me know if you prefer me to revert.

jryans added a subscriber: jryans.Aug 3 2022, 1:15 PM

Looks reasonable to me, seems safe to keep it in. 🙂

jmorse added a comment.Aug 9 2022, 1:19 AM

(have been on fire lately) LGTM, thanks for the fix!