[llvm-bugs] [Bug 38674] New: 'Assertion `L->isRecursivelyLCSSAForm(*DT, *LI) && "Indvars did not preserve LCSSA!"' failed.' with -indvars
via llvm-bugs
llvm-bugs at lists.llvm.org
Wed Aug 22 22:38:26 PDT 2018
https://bugs.llvm.org/show_bug.cgi?id=38674
Bug ID: 38674
Summary: 'Assertion `L->isRecursivelyLCSSAForm(*DT, *LI) &&
"Indvars did not preserve LCSSA!"' failed.' with
-indvars
Product: new-bugs
Version: unspecified
Hardware: PC
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: new bugs
Assignee: unassignedbugs at nondot.org
Reporter: mikael.holmen at ericsson.com
CC: llvm-bugs at lists.llvm.org
Created attachment 20758
--> https://bugs.llvm.org/attachment.cgi?id=20758&action=edit
reproducer
opt -S -o - bbi-16913.ll -indvars
crashes with
opt: ../lib/Transforms/Scalar/IndVarSimplify.cpp:2519: bool (anonymous
namespace)::IndVarSimplify::run(llvm::Loop *): Assertion
`L->isRecursivelyLCSSAForm(*DT, *LI) && "Indvars did not preserve LCSSA!"'
failed.
The function looks like this when the assertion fails
define i32 @f1() {
entry:
br label %for.cond1.preheader
for.cond1.preheader: ; preds = %for.end9,
%entry
br label %for.cond4.preheader
for.cond4.preheader: ; preds = %for.end,
%for.cond1.preheader
%zext = zext i16 1 to i32
br label %for.body6
for.cond4: ; preds = %for.body6
%cmp5 = icmp ult i32 %inc, 2
br i1 %cmp5, label %for.body6, label %for.end
for.body6: ; preds = %for.cond4,
%for.cond4.preheader
%storemerge26 = phi i32 [ 0, %for.cond4.preheader ], [ %inc, %for.cond4 ]
%0 = icmp eq i32 %storemerge26, %zext
%inc = add nuw nsw i32 %storemerge26, 1
br i1 %0, label %return.loopexit, label %for.cond4
for.end: ; preds = %for.cond4
br i1 false, label %for.cond4.preheader, label %for.end9
for.end9: ; preds = %for.end
br i1 false, label %for.cond1.preheader, label %return.loopexit3
return.loopexit: ; preds = %for.body6
unreachable
return.loopexit3: ; preds = %for.end9
%inc11.lcssa = phi i32 [ %zext, %for.end9 ]
br label %return
return: ; preds =
%return.loopexit3
ret i32 %inc11.lcssa
}
This started happening with r335020.
--
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/20180823/0a0fd32f/attachment-0001.html>
More information about the llvm-bugs
mailing list