1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-26 04:32:44 +01:00
llvm-mirror/test/Transforms/NewGVN/todo-pr35074-phi-of-ops.ll
Florian Hahn d2a571702a [NewGVN] Require asserts for crashing tests.
Without asserts, it might take a long time for the tests to crash.
Only run them with assert builds.
2020-07-29 12:41:05 +01:00

38 lines
1.1 KiB
LLVM

; REQUIRES: asserts
; RUN: opt -newgvn -S %s | FileCheck %s
XFAIL: *
; TODO: Test case for PR35074. Crashes caused by phi-of-ops.
define void @crash1_pr35074(i32 %this, i1 %c) {
entry:
br label %for.cond
for.cond: ; preds = %for.inc6, %entry
%y.0 = phi i32 [ 1, %entry ], [ %inc7, %for.inc6 ]
br i1 %c, label %for.inc6, label %for.body.lr.ph
for.body.lr.ph: ; preds = %for.cond
%sub = add nsw i32 %y.0, -1
br label %for.body4
for.body4: ; preds = %for.body.lr.ph
%cmp = icmp ugt i32 %sub, %y.0
br i1 %cmp, label %for.end, label %for.body4.1
for.end: ; preds = %for.body4.1, %for.body4
ret void
for.inc6: ; preds = %for.cond
%inc7 = add nuw nsw i32 %y.0, 1
br label %for.cond
for.body4.1: ; preds = %for.body4
%inc.1 = add nuw nsw i32 %y.0, 1
tail call void @_blah(i32 %inc.1)
br label %for.end
}
declare void @_blah(i32)