1 ; RUN: opt -passes=simplifycfg -simplifycfg-require-and-preserve-domtree=1 -S < %s | FileCheck %s
3 ; Just checking for lack of crash here, but we should be able to check the IR?
4 ; Earlier version using auto-generated checks from utils/update_test_checks.py
5 ; had bot problems though...
7 define void @patatino() {
9 ; CHECK-LABEL: @patatino
12 bb1: ; preds = %bb36, %0
14 bb2: ; preds = %bb3, %bb1
15 br i1 undef, label %bb4, label %bb3
16 bb3: ; preds = %bb4, %bb2
17 br i1 undef, label %bb2, label %bb5
19 switch i32 undef, label %bb3 [
24 br i1 undef, label %bb7, label %bb9
26 %tmp = or i64 undef, 1
27 %tmp8 = icmp ult i64 %tmp, 0
28 br i1 %tmp8, label %bb12, label %bb9
29 bb9: ; preds = %bb35, %bb34, %bb33, %bb32, %bb31, %bb30, %bb27, %bb24, %bb21, %bb18, %bb16, %bb14, %bb12, %bb7, %bb6
33 bb11: ; preds = %bb10, %bb9
36 %tmp13 = icmp ult i64 0, 0
37 br i1 %tmp13, label %bb14, label %bb9
39 %tmp15 = icmp ult i64 undef, 0
40 br i1 %tmp15, label %bb16, label %bb9
42 %tmp17 = icmp ult i64 undef, 0
43 br i1 %tmp17, label %bb18, label %bb9
45 %tmp19 = or i64 undef, 5
46 %tmp20 = icmp ult i64 %tmp19, 0
47 br i1 %tmp20, label %bb21, label %bb9
49 %tmp22 = or i64 undef, 6
50 %tmp23 = icmp ult i64 %tmp22, 0
51 br i1 %tmp23, label %bb24, label %bb9
53 %tmp25 = or i64 undef, 7
54 %tmp26 = icmp ult i64 %tmp25, 0
55 br i1 %tmp26, label %bb27, label %bb9
57 %tmp28 = or i64 undef, 8
58 %tmp29 = icmp ult i64 %tmp28, 0
59 br i1 %tmp29, label %bb30, label %bb9
61 br i1 undef, label %bb31, label %bb9
63 br i1 undef, label %bb32, label %bb9
65 br i1 undef, label %bb33, label %bb9
67 br i1 undef, label %bb34, label %bb9
69 br i1 undef, label %bb35, label %bb9
71 br i1 undef, label %bb36, label %bb9
73 br i1 undef, label %bb1, label %bb10