1 ; RUN: llc -march=hexagon -hexagon-emit-jump-tables=0 < %s
3 ; Check for successful compilation.
5 target triple = "hexagon"
8 %s.1 = type { i32, i32, i32 }
10 @g0 = external global %s.0
11 @g1 = external global %s.0
12 @g2 = external global %s.0
13 @g3 = external global %s.0
14 @g4 = external global %s.0
16 ; Function Attrs: nounwind optsize
17 define zeroext i8 @f0(ptr %a0, ptr nocapture %a1) #0 {
19 store ptr null, ptr %a1, align 4, !tbaa !0
20 %v0 = getelementptr inbounds %s.1, ptr %a0, i32 0, i32 1
21 %v1 = load i32, ptr %v0, align 4, !tbaa !4
22 %v2 = icmp eq i32 %v1, 0
23 br i1 %v2, label %b1, label %b8
26 %v4 = load i32, ptr %a0, align 4, !tbaa !7
27 switch i32 %v4, label %b8 [
36 %v5 = getelementptr inbounds %s.1, ptr %a0, i32 0, i32 2
37 %v6 = load i32, ptr %v5, align 4, !tbaa !8
38 switch i32 %v6, label %b8 [
43 b3: ; preds = %b7, %b7, %b7, %b6, %b6, %b5, %b5, %b4, %b4, %b2, %b2
44 %v7 = phi ptr [ @g0, %b2 ], [ @g0, %b2 ], [ @g1, %b4 ], [ @g1, %b4 ], [ @g2, %b5 ], [ @g2, %b5 ], [ @g3, %b6 ], [ @g3, %b6 ], [ @g4, %b7 ], [ @g4, %b7 ], [ @g4, %b7 ]
45 store ptr %v7, ptr %a1, align 4, !tbaa !0
49 %v8 = getelementptr inbounds %s.1, ptr %a0, i32 0, i32 2
50 %v9 = load i32, ptr %v8, align 4, !tbaa !8
51 switch i32 %v9, label %b8 [
57 %v10 = getelementptr inbounds %s.1, ptr %a0, i32 0, i32 2
58 %v11 = load i32, ptr %v10, align 4, !tbaa !8
59 switch i32 %v11, label %b8 [
65 %v12 = getelementptr inbounds %s.1, ptr %a0, i32 0, i32 2
66 %v13 = load i32, ptr %v12, align 4, !tbaa !8
67 switch i32 %v13, label %b8 [
73 %v14 = getelementptr inbounds %s.1, ptr %a0, i32 0, i32 2
74 %v15 = load i32, ptr %v14, align 4, !tbaa !8
75 switch i32 %v15, label %b8 [
81 b8: ; preds = %b7, %b6, %b5, %b4, %b3, %b2, %b1, %b0
82 %v16 = phi i8 [ 1, %b3 ], [ 0, %b0 ], [ 0, %b2 ], [ 0, %b4 ], [ 0, %b5 ], [ 0, %b6 ], [ 0, %b1 ], [ 0, %b7 ]
86 attributes #0 = { nounwind optsize }
89 !1 = !{!"any pointer", !2, i64 0}
90 !2 = !{!"omnipotent char", !3, i64 0}
91 !3 = !{!"Simple C/C++ TBAA"}
93 !5 = !{!"_ZTS3bar", !6, i64 0, !6, i64 4, !6, i64 8}
94 !6 = !{!"int", !2, i64 0}