This is an archive of the discontinued LLVM Phabricator instance.

Make DT a transitive dependency of LI.
ClosedPublic

Authored by eugenis on Jul 17 2019, 4:21 PM.

Details

Summary

LoopInfoWrapperPass::verify uses DT, which means DT must be alive
even if it has no direct users.

Fixes a crash in expensive checks mode.

Diff Detail

Repository
rL LLVM

Event Timeline

eugenis created this revision.Jul 17 2019, 4:21 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 17 2019, 4:21 PM
Herald added a subscriber: hiraditya. · View Herald Transcript

This fixes http://lab.llvm.org:8011/builders/llvm-clang-x86_64-expensive-checks-win/builds/18689.
I've added a pass that preservesCFG; following passes use LI but not DT. Without the transitive dependency, the pass manager kills DT before my pass as there are no future users, but then calls LoopInfoWrapperPass::verify that assumes that DT is still alive.

vitalybuka accepted this revision.Jul 17 2019, 4:27 PM
This revision is now accepted and ready to land.Jul 17 2019, 4:27 PM
pcc accepted this revision.Jul 17 2019, 4:30 PM

LGTM

This revision was automatically updated to reflect the committed changes.