[llvm-bugs] [Bug 30958] New: LoopDistribute domtree handling gives eternal loop
via llvm-bugs
llvm-bugs at lists.llvm.org
Wed Nov 9 01:39:04 PST 2016
https://llvm.org/bugs/show_bug.cgi?id=30958
Bug ID: 30958
Summary: LoopDistribute domtree handling gives eternal loop
Product: tools
Version: trunk
Hardware: PC
OS: Windows NT
Status: NEW
Severity: normal
Priority: P
Component: opt
Assignee: unassignedbugs at nondot.org
Reporter: jesper.antonsson at ericsson.com
CC: llvm-bugs at lists.llvm.org
Classification: Unclassified
Created attachment 17572
--> https://llvm.org/bugs/attachment.cgi?id=17572&action=edit
Small program provoking the bug
Opt gets stuck in an eternal loop with the attached small program, using these
flags:
opt -simplifycfg -loop-distribute -instcombine loopdist_simplified.ll
The reason is that the LoopDistribute pass mess up the dominator tree and
introduce a cycle, so when the instcombiner needs to walk the dominator tree it
gets stuck in a tight eternal loop:
Program received signal SIGINT, Interrupt.
llvm::DominatorTreeBase<llvm::BasicBlock>::dominatedBySlowTreeWalk
(this=0x343d570, A=0x345e5e0, B=0x3455b70)
at ../include/llvm/Support/GenericDomTree.h:220
220 B = IDom; // Walk up the tree
If we use this command line:
opt -loop-distribute -verify-dom-info loopdist_simplified.ll
... the verifier complains:
DominatorTree for function: f is not up to date!
Computed:
=============================--------------------------------
Inorder Dominator Tree: DFSNumbers invalid: 0 slow queries.
[1] %0 {0,5}
Actual:
=============================--------------------------------
Inorder Dominator Tree:
[1] %0 {0,17}
[2] %bb1 {1,16}
[3] %bb2.lver.check {2,15}
[4] %bb2.ph.lver.orig {3,6}
[5] %bb2.lver.orig {4,5}
[4] %bb2.ph.ldist1 {7,14}
[5] %bb2.ldist1 {8,13}
[6] %bb2.ph {9,12}
[7] %bb2 {10,11}
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20161109/63f75f0c/attachment.html>
More information about the llvm-bugs
mailing list