llvm.org GIT mirror llvm / a052fad
Add a test for r61358, which I forgot to add way back when. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@64904 91177308-0d34-0410-b5e6-96231b3b80d8 Owen Anderson 10 years ago
1 changed file(s) with 193 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
0 ; RUN: llvm-as < %s | opt -gvn -enable-load-pre -disable-output
1
2 %struct.VEC_rtx_base = type { i32, i32, [1 x %struct.rtx_def*] }
3 %struct.VEC_rtx_gc = type { %struct.VEC_rtx_base }
4 %struct.block_symbol = type { [3 x %struct.cgraph_rtl_info], %struct.object_block*, i64 }
5 %struct.cgraph_rtl_info = type { i32 }
6 %struct.object_block = type { %struct.section*, i32, i64, %struct.VEC_rtx_gc*, %struct.VEC_rtx_gc* }
7 %struct.rtvec_def = type { i32, [1 x %struct.rtx_def*] }
8 %struct.rtx_def = type { i16, i8, i8, %struct.u }
9 %struct.section = type { %struct.unnamed_section }
10 %struct.u = type { %struct.block_symbol }
11 %struct.unnamed_section = type { %struct.cgraph_rtl_info, void (i8*)*, i8*, %struct.section* }
12
13 declare %struct.rtvec_def* @gen_rtvec(i32, ...)
14
15 declare %struct.rtx_def* @plus_constant(%struct.rtx_def*, i64)
16
17 declare %struct.rtx_def* @gen_rtx_fmt_Ei(i32, i32, %struct.rtvec_def*, i32)
18
19 declare i32 @local_symbolic_operand(%struct.rtx_def*, i32)
20
21 define %struct.rtx_def* @legitimize_pic_address(%struct.rtx_def* %orig, %struct.rtx_def* %reg) nounwind {
22 entry:
23 %addr = alloca %struct.rtx_def* ; <%struct.rtx_def**> [#uses=5]
24 %iftmp.1532 = alloca %struct.rtx_def* ; <%struct.rtx_def**> [#uses=3]
25 store %struct.rtx_def* %orig, %struct.rtx_def** null
26 %0 = load %struct.rtx_def** null, align 4 ; <%struct.rtx_def*> [#uses=0]
27 br i1 false, label %bb96, label %bb59
28
29 bb59: ; preds = %entry
30 %1 = load %struct.rtx_def** %addr, align 4 ; <%struct.rtx_def*> [#uses=1]
31 %2 = call i32 @local_symbolic_operand(%struct.rtx_def* %1, i32 0) nounwind ; [#uses=0]
32 br i1 false, label %bb96, label %bb63
33
34 bb63: ; preds = %bb59
35 br i1 false, label %bb64, label %bb74
36
37 bb64: ; preds = %bb63
38 br i1 false, label %bb72, label %bb65
39
40 bb65: ; preds = %bb64
41 br label %bb72
42
43 bb72: ; preds = %bb65, %bb64
44 br label %bb74
45
46 bb74: ; preds = %bb72, %bb63
47 br i1 false, label %bb75, label %bb76
48
49 bb75: ; preds = %bb74
50 br label %bb76
51
52 bb76: ; preds = %bb75, %bb74
53 br i1 false, label %bb77, label %bb84
54
55 bb77: ; preds = %bb76
56 %3 = getelementptr [1 x %struct.cgraph_rtl_info]* null, i32 0, i32 0 ; <%struct.cgraph_rtl_info*> [#uses=0]
57 unreachable
58
59 bb84: ; preds = %bb76
60 br i1 false, label %bb85, label %bb86
61
62 bb85: ; preds = %bb84
63 br label %bb87
64
65 bb86: ; preds = %bb84
66 br label %bb87
67
68 bb87: ; preds = %bb86, %bb85
69 %4 = call %struct.rtx_def* @gen_rtx_fmt_Ei(i32 16, i32 0, %struct.rtvec_def* null, i32 1) nounwind ; <%struct.rtx_def*> [#uses=0]
70 br i1 false, label %bb89, label %bb90
71
72 bb89: ; preds = %bb87
73 br label %bb91
74
75 bb90: ; preds = %bb87
76 br label %bb91
77
78 bb91: ; preds = %bb90, %bb89
79 br i1 false, label %bb92, label %bb93
80
81 bb92: ; preds = %bb91
82 br label %bb94
83
84 bb93: ; preds = %bb91
85 br label %bb94
86
87 bb94: ; preds = %bb93, %bb92
88 unreachable
89
90 bb96: ; preds = %bb59, %entry
91 %5 = load %struct.rtx_def** %addr, align 4 ; <%struct.rtx_def*> [#uses=1]
92 %6 = getelementptr %struct.rtx_def* %5, i32 0, i32 0 ; [#uses=1]
93 %7 = load i16* %6, align 2 ; [#uses=0]
94 br i1 false, label %bb147, label %bb97
95
96 bb97: ; preds = %bb96
97 %8 = load %struct.rtx_def** %addr, align 4 ; <%struct.rtx_def*> [#uses=0]
98 br i1 false, label %bb147, label %bb99
99
100 bb99: ; preds = %bb97
101 unreachable
102
103 bb147: ; preds = %bb97, %bb96
104 %9 = load %struct.rtx_def** %addr, align 4 ; <%struct.rtx_def*> [#uses=1]
105 %10 = getelementptr %struct.rtx_def* %9, i32 0, i32 0 ; [#uses=1]
106 %11 = load i16* %10, align 2 ; [#uses=0]
107 br i1 false, label %bb164, label %bb148
108
109 bb148: ; preds = %bb147
110 br i1 false, label %bb164, label %bb149
111
112 bb149: ; preds = %bb148
113 br i1 false, label %bb150, label %bb152
114
115 bb150: ; preds = %bb149
116 unreachable
117
118 bb152: ; preds = %bb149
119 br label %bb164
120
121 bb164: ; preds = %bb152, %bb148, %bb147
122 %12 = getelementptr [1 x %struct.cgraph_rtl_info]* null, i32 0, i32 1 ; <%struct.cgraph_rtl_info*> [#uses=0]
123 br i1 false, label %bb165, label %bb166
124
125 bb165: ; preds = %bb164
126 br label %bb167
127
128 bb166: ; preds = %bb164
129 br label %bb167
130
131 bb167: ; preds = %bb166, %bb165
132 br i1 false, label %bb211, label %bb168
133
134 bb168: ; preds = %bb167
135 br i1 false, label %bb211, label %bb170
136
137 bb170: ; preds = %bb168
138 br i1 false, label %bb172, label %bb181
139
140 bb172: ; preds = %bb170
141 br i1 false, label %bb179, label %bb174
142
143 bb174: ; preds = %bb172
144 br i1 false, label %bb177, label %bb175
145
146 bb175: ; preds = %bb174
147 br i1 false, label %bb177, label %bb176
148
149 bb176: ; preds = %bb175
150 br label %bb178
151
152 bb177: ; preds = %bb175, %bb174
153 br label %bb178
154
155 bb178: ; preds = %bb177, %bb176
156 br label %bb180
157
158 bb179: ; preds = %bb172
159 br label %bb180
160
161 bb180: ; preds = %bb179, %bb178
162 br label %bb181
163
164 bb181: ; preds = %bb180, %bb170
165 %13 = call %struct.rtvec_def* (i32, ...)* @gen_rtvec(i32 1, %struct.rtx_def* null) nounwind ; <%struct.rtvec_def*> [#uses=0]
166 unreachable
167
168 bb211: ; preds = %bb168, %bb167
169 %14 = load %struct.rtx_def** %addr, align 4 ; <%struct.rtx_def*> [#uses=0]
170 %15 = getelementptr [1 x %struct.cgraph_rtl_info]* null, i32 0, i32 0 ; <%struct.cgraph_rtl_info*> [#uses=0]
171 store %struct.rtx_def* null, %struct.rtx_def** null, align 4
172 br i1 false, label %bb212, label %bb213
173
174 bb212: ; preds = %bb211
175 store %struct.rtx_def* null, %struct.rtx_def** %iftmp.1532, align 4
176 br label %bb214
177
178 bb213: ; preds = %bb211
179 store %struct.rtx_def* null, %struct.rtx_def** %iftmp.1532, align 4
180 br label %bb214
181
182 bb214: ; preds = %bb213, %bb212
183 %16 = bitcast %struct.block_symbol* null to [1 x %struct.cgraph_rtl_info]* ; <[1 x %struct.cgraph_rtl_info]*> [#uses=1]
184 %17 = getelementptr [1 x %struct.cgraph_rtl_info]* %16, i32 0, i32 1 ; <%struct.cgraph_rtl_info*> [#uses=0]
185 %18 = load %struct.rtx_def** %iftmp.1532, align 4 ; <%struct.rtx_def*> [#uses=0]
186 %19 = getelementptr %struct.rtx_def* null, i32 0, i32 3 ; <%struct.u*> [#uses=1]
187 %20 = getelementptr %struct.u* %19, i32 0, i32 0 ; <%struct.block_symbol*> [#uses=1]
188 %21 = bitcast %struct.block_symbol* %20 to [1 x i64]* ; <[1 x i64]*> [#uses=1]
189 %22 = getelementptr [1 x i64]* %21, i32 0, i32 0 ; [#uses=0]
190 %23 = call %struct.rtx_def* @plus_constant(%struct.rtx_def* null, i64 0) nounwind ; <%struct.rtx_def*> [#uses=0]
191 unreachable
192 }