Branch data Line data Source code
1 : : /* Generated automatically by the program `genmatch' from
2 : : a IL pattern matching and simplification description. */
3 : : #pragma GCC diagnostic push
4 : : #pragma GCC diagnostic ignored "-Wunused-variable"
5 : : #pragma GCC diagnostic ignored "-Wunused-function"
6 : :
7 : : #include "gimple-match-auto.h"
8 : :
9 : : bool
10 : 242159673 : gimple_truth_valued_p (tree t, tree (*valueize)(tree) ATTRIBUTE_UNUSED)
11 : : {
12 : 242159673 : const tree type = TREE_TYPE (t);
13 : 242159673 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
14 : 242159673 : {
15 : 242159673 : tree captures[1] ATTRIBUTE_UNUSED = { t };
16 : 242159673 : if (INTEGRAL_TYPE_P (type) && TYPE_PRECISION (type) == 1
17 : : )
18 : : {
19 : 31784440 : {
20 : 31784440 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 15, __FILE__, __LINE__, false);
21 : 31784440 : return true;
22 : : }
23 : : }
24 : : }
25 : 210375233 : switch (TREE_CODE (t))
26 : : {
27 : 203876882 : case SSA_NAME:
28 : 203876882 : if (gimple *_d1 = get_def (valueize, t))
29 : : {
30 : 79313808 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
31 : 90502221 : switch (gimple_assign_rhs_code (_a1))
32 : : {
33 : 2444 : case LT_EXPR:
34 : 2444 : {
35 : 2444 : tree _p0 = gimple_assign_rhs1 (_a1);
36 : 2444 : _p0 = do_valueize (valueize, _p0);
37 : 2444 : tree _p1 = gimple_assign_rhs2 (_a1);
38 : 2444 : _p1 = do_valueize (valueize, _p1);
39 : 2444 : {
40 : 2444 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
41 : 2444 : {
42 : 2444 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
43 : 2444 : return true;
44 : : }
45 : : }
46 : 114 : break;
47 : : }
48 : 114 : case LE_EXPR:
49 : 114 : {
50 : 114 : tree _p0 = gimple_assign_rhs1 (_a1);
51 : 114 : _p0 = do_valueize (valueize, _p0);
52 : 114 : tree _p1 = gimple_assign_rhs2 (_a1);
53 : 114 : _p1 = do_valueize (valueize, _p1);
54 : 114 : {
55 : 114 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
56 : 114 : {
57 : 114 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
58 : 114 : return true;
59 : : }
60 : : }
61 : 4343 : break;
62 : : }
63 : 4343 : case EQ_EXPR:
64 : 4343 : {
65 : 4343 : tree _p0 = gimple_assign_rhs1 (_a1);
66 : 4343 : _p0 = do_valueize (valueize, _p0);
67 : 4343 : tree _p1 = gimple_assign_rhs2 (_a1);
68 : 4343 : _p1 = do_valueize (valueize, _p1);
69 : 4343 : if (tree_swap_operands_p (_p0, _p1))
70 : : std::swap (_p0, _p1);
71 : 4343 : {
72 : 4343 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
73 : 4343 : {
74 : 4343 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
75 : 4343 : return true;
76 : : }
77 : : }
78 : 4343 : break;
79 : : }
80 : 10426 : case NE_EXPR:
81 : 10426 : {
82 : 10426 : tree _p0 = gimple_assign_rhs1 (_a1);
83 : 10426 : _p0 = do_valueize (valueize, _p0);
84 : 10426 : tree _p1 = gimple_assign_rhs2 (_a1);
85 : 10426 : _p1 = do_valueize (valueize, _p1);
86 : 10426 : if (tree_swap_operands_p (_p0, _p1))
87 : : std::swap (_p0, _p1);
88 : 10426 : {
89 : 10426 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
90 : 10426 : {
91 : 10426 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
92 : 10426 : return true;
93 : : }
94 : : }
95 : 10426 : break;
96 : : }
97 : 72 : case GE_EXPR:
98 : 72 : {
99 : 72 : tree _p0 = gimple_assign_rhs1 (_a1);
100 : 72 : _p0 = do_valueize (valueize, _p0);
101 : 72 : tree _p1 = gimple_assign_rhs2 (_a1);
102 : 72 : _p1 = do_valueize (valueize, _p1);
103 : 72 : {
104 : 72 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
105 : 72 : {
106 : 72 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
107 : 72 : return true;
108 : : }
109 : : }
110 : 1381 : break;
111 : : }
112 : 1381 : case GT_EXPR:
113 : 1381 : {
114 : 1381 : tree _p0 = gimple_assign_rhs1 (_a1);
115 : 1381 : _p0 = do_valueize (valueize, _p0);
116 : 1381 : tree _p1 = gimple_assign_rhs2 (_a1);
117 : 1381 : _p1 = do_valueize (valueize, _p1);
118 : 1381 : {
119 : 1381 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
120 : 1381 : {
121 : 1381 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
122 : 1381 : return true;
123 : : }
124 : : }
125 : 22 : break;
126 : : }
127 : 22 : case UNORDERED_EXPR:
128 : 22 : {
129 : 22 : tree _p0 = gimple_assign_rhs1 (_a1);
130 : 22 : _p0 = do_valueize (valueize, _p0);
131 : 22 : tree _p1 = gimple_assign_rhs2 (_a1);
132 : 22 : _p1 = do_valueize (valueize, _p1);
133 : 22 : if (tree_swap_operands_p (_p0, _p1))
134 : : std::swap (_p0, _p1);
135 : 22 : {
136 : 22 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
137 : 22 : {
138 : 22 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
139 : 22 : return true;
140 : : }
141 : : }
142 : 22 : break;
143 : : }
144 : 16 : case ORDERED_EXPR:
145 : 16 : {
146 : 16 : tree _p0 = gimple_assign_rhs1 (_a1);
147 : 16 : _p0 = do_valueize (valueize, _p0);
148 : 16 : tree _p1 = gimple_assign_rhs2 (_a1);
149 : 16 : _p1 = do_valueize (valueize, _p1);
150 : 16 : if (tree_swap_operands_p (_p0, _p1))
151 : : std::swap (_p0, _p1);
152 : 16 : {
153 : 16 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
154 : 16 : {
155 : 16 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
156 : 16 : return true;
157 : : }
158 : : }
159 : 16 : break;
160 : : }
161 : 23 : case UNLT_EXPR:
162 : 23 : {
163 : 23 : tree _p0 = gimple_assign_rhs1 (_a1);
164 : 23 : _p0 = do_valueize (valueize, _p0);
165 : 23 : tree _p1 = gimple_assign_rhs2 (_a1);
166 : 23 : _p1 = do_valueize (valueize, _p1);
167 : 23 : {
168 : 23 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
169 : 23 : {
170 : 23 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
171 : 23 : return true;
172 : : }
173 : : }
174 : 23 : break;
175 : : }
176 : 23 : case UNLE_EXPR:
177 : 23 : {
178 : 23 : tree _p0 = gimple_assign_rhs1 (_a1);
179 : 23 : _p0 = do_valueize (valueize, _p0);
180 : 23 : tree _p1 = gimple_assign_rhs2 (_a1);
181 : 23 : _p1 = do_valueize (valueize, _p1);
182 : 23 : {
183 : 23 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
184 : 23 : {
185 : 23 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
186 : 23 : return true;
187 : : }
188 : : }
189 : 23 : break;
190 : : }
191 : 23 : case UNGT_EXPR:
192 : 23 : {
193 : 23 : tree _p0 = gimple_assign_rhs1 (_a1);
194 : 23 : _p0 = do_valueize (valueize, _p0);
195 : 23 : tree _p1 = gimple_assign_rhs2 (_a1);
196 : 23 : _p1 = do_valueize (valueize, _p1);
197 : 23 : {
198 : 23 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
199 : 23 : {
200 : 23 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
201 : 23 : return true;
202 : : }
203 : : }
204 : 23 : break;
205 : : }
206 : 23 : case UNGE_EXPR:
207 : 23 : {
208 : 23 : tree _p0 = gimple_assign_rhs1 (_a1);
209 : 23 : _p0 = do_valueize (valueize, _p0);
210 : 23 : tree _p1 = gimple_assign_rhs2 (_a1);
211 : 23 : _p1 = do_valueize (valueize, _p1);
212 : 23 : {
213 : 23 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
214 : 23 : {
215 : 23 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
216 : 23 : return true;
217 : : }
218 : : }
219 : 23 : break;
220 : : }
221 : 23 : case UNEQ_EXPR:
222 : 23 : {
223 : 23 : tree _p0 = gimple_assign_rhs1 (_a1);
224 : 23 : _p0 = do_valueize (valueize, _p0);
225 : 23 : tree _p1 = gimple_assign_rhs2 (_a1);
226 : 23 : _p1 = do_valueize (valueize, _p1);
227 : 23 : if (tree_swap_operands_p (_p0, _p1))
228 : : std::swap (_p0, _p1);
229 : 23 : {
230 : 23 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
231 : 23 : {
232 : 23 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
233 : 23 : return true;
234 : : }
235 : : }
236 : 23 : break;
237 : : }
238 : 0 : case LTGT_EXPR:
239 : 0 : {
240 : 0 : tree _p0 = gimple_assign_rhs1 (_a1);
241 : 0 : _p0 = do_valueize (valueize, _p0);
242 : 0 : tree _p1 = gimple_assign_rhs2 (_a1);
243 : 0 : _p1 = do_valueize (valueize, _p1);
244 : 0 : if (tree_swap_operands_p (_p0, _p1))
245 : : std::swap (_p0, _p1);
246 : 0 : {
247 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
248 : 0 : {
249 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
250 : 0 : return true;
251 : : }
252 : : }
253 : 0 : break;
254 : : }
255 : 0 : case TRUTH_AND_EXPR:
256 : 0 : {
257 : 0 : tree _p0 = gimple_assign_rhs1 (_a1);
258 : 0 : _p0 = do_valueize (valueize, _p0);
259 : 0 : tree _p1 = gimple_assign_rhs2 (_a1);
260 : 0 : _p1 = do_valueize (valueize, _p1);
261 : 0 : if (tree_swap_operands_p (_p0, _p1))
262 : : std::swap (_p0, _p1);
263 : 0 : {
264 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
265 : 0 : {
266 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
267 : 0 : return true;
268 : : }
269 : : }
270 : 0 : break;
271 : : }
272 : 0 : case TRUTH_ANDIF_EXPR:
273 : 0 : {
274 : 0 : tree _p0 = gimple_assign_rhs1 (_a1);
275 : 0 : _p0 = do_valueize (valueize, _p0);
276 : 0 : tree _p1 = gimple_assign_rhs2 (_a1);
277 : 0 : _p1 = do_valueize (valueize, _p1);
278 : 0 : {
279 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
280 : 0 : {
281 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
282 : 0 : return true;
283 : : }
284 : : }
285 : 0 : break;
286 : : }
287 : 0 : case TRUTH_OR_EXPR:
288 : 0 : {
289 : 0 : tree _p0 = gimple_assign_rhs1 (_a1);
290 : 0 : _p0 = do_valueize (valueize, _p0);
291 : 0 : tree _p1 = gimple_assign_rhs2 (_a1);
292 : 0 : _p1 = do_valueize (valueize, _p1);
293 : 0 : if (tree_swap_operands_p (_p0, _p1))
294 : : std::swap (_p0, _p1);
295 : 0 : {
296 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
297 : 0 : {
298 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
299 : 0 : return true;
300 : : }
301 : : }
302 : 0 : break;
303 : : }
304 : 0 : case TRUTH_ORIF_EXPR:
305 : 0 : {
306 : 0 : tree _p0 = gimple_assign_rhs1 (_a1);
307 : 0 : _p0 = do_valueize (valueize, _p0);
308 : 0 : tree _p1 = gimple_assign_rhs2 (_a1);
309 : 0 : _p1 = do_valueize (valueize, _p1);
310 : 0 : {
311 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
312 : 0 : {
313 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
314 : 0 : return true;
315 : : }
316 : : }
317 : 0 : break;
318 : : }
319 : 0 : case TRUTH_XOR_EXPR:
320 : 0 : {
321 : 0 : tree _p0 = gimple_assign_rhs1 (_a1);
322 : 0 : _p0 = do_valueize (valueize, _p0);
323 : 0 : tree _p1 = gimple_assign_rhs2 (_a1);
324 : 0 : _p1 = do_valueize (valueize, _p1);
325 : 0 : if (tree_swap_operands_p (_p0, _p1))
326 : : std::swap (_p0, _p1);
327 : 0 : {
328 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
329 : 0 : {
330 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 16, __FILE__, __LINE__, false);
331 : 0 : return true;
332 : : }
333 : : }
334 : 0 : break;
335 : : }
336 : 0 : case TRUTH_NOT_EXPR:
337 : 0 : {
338 : 0 : tree _p0 = gimple_assign_rhs1 (_a1);
339 : 0 : _p0 = do_valueize (valueize, _p0);
340 : 0 : {
341 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
342 : 0 : {
343 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 17, __FILE__, __LINE__, false);
344 : 0 : return true;
345 : : }
346 : : }
347 : : break;
348 : : }
349 : : default:;
350 : : }
351 : : }
352 : : break;
353 : : default:;
354 : : }
355 : : return false;
356 : : }
357 : :
358 : : bool
359 : 0 : gimple_simplify_34 (gimple_match_op *res_op, gimple_seq *seq,
360 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
361 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
362 : : const enum tree_code ARG_UNUSED (op))
363 : : {
364 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
365 : 0 : if (INTEGRAL_TYPE_P (type) && TYPE_OVERFLOW_WRAPS (type)
366 : 0 : && tree_int_cst_sgn (captures[4]) > 0
367 : 0 : && (tree_nonzero_bits (captures[0]) & tree_nonzero_bits (captures[3])) == 0
368 : : )
369 : : {
370 : 0 : {
371 : 0 : wide_int wone = wi::one (TYPE_PRECISION (type));
372 : 0 : wide_int c = wi::add (wi::to_wide (captures[2]),
373 : 0 : wi::lshift (wone, wi::to_wide (captures[4])));
374 : 0 : gimple_seq *lseq = seq;
375 : 0 : if (lseq
376 : 0 : && (!single_use (captures[0])
377 : 0 : || !single_use (captures[3])))
378 : 0 : lseq = NULL;
379 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail196;
380 : 0 : {
381 : 0 : res_op->set_op (MULT_EXPR, type, 2);
382 : 0 : res_op->ops[0] = captures[1];
383 : 0 : res_op->ops[1] = wide_int_to_tree (type, c);
384 : 0 : res_op->resimplify (lseq, valueize);
385 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 88, __FILE__, __LINE__, true);
386 : 0 : return true;
387 : : }
388 : 0 : next_after_fail196:;
389 : 0 : }
390 : : }
391 : : return false;
392 : : }
393 : :
394 : : bool
395 : 2 : gimple_simplify_42 (gimple_match_op *res_op, gimple_seq *seq,
396 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
397 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
398 : : const combined_fn ARG_UNUSED (PARITY))
399 : : {
400 : 2 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
401 : 2 : if (types_match (TREE_TYPE (captures[1]), TREE_TYPE (captures[3]))
402 : : )
403 : : {
404 : 0 : gimple_seq *lseq = seq;
405 : 0 : if (lseq
406 : 0 : && (!single_use (captures[0])
407 : 0 : || !single_use (captures[2])))
408 : 0 : lseq = NULL;
409 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail205;
410 : 0 : {
411 : 0 : res_op->set_op (PARITY, type, 1);
412 : 0 : {
413 : 0 : tree _o1[2], _r1;
414 : 0 : _o1[0] = captures[1];
415 : 0 : _o1[1] = captures[3];
416 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_XOR_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
417 : 0 : tem_op.resimplify (lseq, valueize);
418 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
419 : 0 : if (!_r1) goto next_after_fail205;
420 : 0 : res_op->ops[0] = _r1;
421 : : }
422 : 0 : res_op->resimplify (lseq, valueize);
423 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 97, __FILE__, __LINE__, true);
424 : 0 : return true;
425 : : }
426 : : next_after_fail205:;
427 : : }
428 : : else
429 : : {
430 : 4 : if (INTEGRAL_TYPE_P (TREE_TYPE (captures[1]))
431 : 4 : && INTEGRAL_TYPE_P (TREE_TYPE (captures[3]))
432 : : )
433 : : {
434 : 2 : {
435 : 2 : tree utype = TREE_TYPE (captures[1]);
436 : 2 : if (TYPE_PRECISION (utype) < TYPE_PRECISION (TREE_TYPE (captures[3])))
437 : 2 : utype = TREE_TYPE (captures[3]);
438 : 2 : gimple_seq *lseq = seq;
439 : 2 : if (lseq
440 : 1 : && (!single_use (captures[0])
441 : 1 : || !single_use (captures[2])))
442 : 1 : lseq = NULL;
443 : 2 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail206;
444 : 2 : {
445 : 2 : res_op->set_op (PARITY, type, 1);
446 : 2 : {
447 : 2 : tree _o1[2], _r1;
448 : 2 : {
449 : 2 : tree _o2[1], _r2;
450 : 2 : _o2[0] = captures[1];
451 : 2 : if (utype != TREE_TYPE (_o2[0])
452 : 2 : && !useless_type_conversion_p (utype, TREE_TYPE (_o2[0])))
453 : : {
454 : 2 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, utype, _o2[0]);
455 : 2 : tem_op.resimplify (lseq, valueize);
456 : 2 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
457 : 2 : if (!_r2) goto next_after_fail206;
458 : : }
459 : : else
460 : : _r2 = _o2[0];
461 : 1 : _o1[0] = _r2;
462 : : }
463 : 1 : {
464 : 1 : tree _o2[1], _r2;
465 : 1 : _o2[0] = captures[3];
466 : 1 : if (utype != TREE_TYPE (_o2[0])
467 : 1 : && !useless_type_conversion_p (utype, TREE_TYPE (_o2[0])))
468 : : {
469 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, utype, _o2[0]);
470 : 0 : tem_op.resimplify (lseq, valueize);
471 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
472 : 0 : if (!_r2) goto next_after_fail206;
473 : : }
474 : : else
475 : : _r2 = _o2[0];
476 : 1 : _o1[1] = _r2;
477 : : }
478 : 1 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_XOR_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
479 : 1 : tem_op.resimplify (lseq, valueize);
480 : 1 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
481 : 1 : if (!_r1) goto next_after_fail206;
482 : 1 : res_op->ops[0] = _r1;
483 : : }
484 : 1 : res_op->resimplify (lseq, valueize);
485 : 1 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 98, __FILE__, __LINE__, true);
486 : 1 : return true;
487 : : }
488 : : next_after_fail206:;
489 : : }
490 : : }
491 : : }
492 : : return false;
493 : : }
494 : :
495 : : bool
496 : 1538 : gimple_simplify_57 (gimple_match_op *res_op, gimple_seq *seq,
497 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
498 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
499 : : {
500 : 1538 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
501 : 1538 : if (!TYPE_SATURATING (type)
502 : : )
503 : : {
504 : 1538 : if ((!FLOAT_TYPE_P (type) || flag_associative_math)
505 : 3076 : && !FIXED_POINT_TYPE_P (type)
506 : : )
507 : : {
508 : 1538 : gimple_seq *lseq = seq;
509 : 1538 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail232;
510 : 1538 : {
511 : 1538 : res_op->set_op (PLUS_EXPR, type, 2);
512 : 1538 : res_op->ops[0] = captures[2];
513 : 1538 : res_op->ops[1] = captures[1];
514 : 1538 : res_op->resimplify (lseq, valueize);
515 : 1538 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 124, __FILE__, __LINE__, true);
516 : 1538 : return true;
517 : : }
518 : 0 : next_after_fail232:;
519 : : }
520 : : }
521 : : return false;
522 : : }
523 : :
524 : : bool
525 : 6486 : gimple_simplify_62 (gimple_match_op *res_op, gimple_seq *seq,
526 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
527 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
528 : : {
529 : 6486 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
530 : 6486 : if (!TYPE_SATURATING (type)
531 : : )
532 : : {
533 : 6486 : if ((!FLOAT_TYPE_P (type) || flag_associative_math)
534 : 12972 : && !FIXED_POINT_TYPE_P (type)
535 : : )
536 : : {
537 : 6486 : if (!TYPE_OVERFLOW_TRAPS (type)
538 : : )
539 : : {
540 : 6486 : gimple_seq *lseq = seq;
541 : 6486 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail237;
542 : 6486 : {
543 : 6486 : res_op->set_op (NOP_EXPR, type, 1);
544 : 6486 : res_op->ops[0] = build_all_ones_cst (TREE_TYPE (captures[0]));
545 : 6486 : res_op->resimplify (lseq, valueize);
546 : 6486 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 129, __FILE__, __LINE__, true);
547 : 6486 : return true;
548 : : }
549 : 0 : next_after_fail237:;
550 : : }
551 : : }
552 : : }
553 : : return false;
554 : : }
555 : :
556 : : bool
557 : 174961 : gimple_simplify_66 (gimple_match_op *res_op, gimple_seq *seq,
558 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
559 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
560 : : const enum tree_code ARG_UNUSED (plusminus))
561 : : {
562 : 174961 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
563 : 174961 : if (!TYPE_SATURATING (type)
564 : 174961 : && (!FLOAT_TYPE_P (type) || flag_associative_math)
565 : : )
566 : : {
567 : 170715 : if (!ALL_FRACT_MODE_P (TYPE_MODE (type))
568 : : )
569 : : {
570 : 20 : if ((!ANY_INTEGRAL_TYPE_P (type)
571 : 170707 : || TYPE_OVERFLOW_WRAPS (type)
572 : 82815 : || (INTEGRAL_TYPE_P (type)
573 : 82811 : && ((tree_expr_nonzero_p (captures[1])
574 : 46030 : && (plusminus == MINUS_EXPR
575 : 83746 : || expr_not_equal_to (captures[1],
576 : 212588 : wi::minus_one (TYPE_PRECISION (type)))))
577 : 36991 : || expr_not_equal_to (captures[2],
578 : : (plusminus == PLUS_EXPR
579 : 244697 : ? wi::max_value (TYPE_PRECISION (type), SIGNED)
580 : 34152 : : wi::min_value (TYPE_PRECISION (type), SIGNED))))))
581 : 319760 : && single_use (captures[0])
582 : : )
583 : : {
584 : 51431 : gimple_seq *lseq = seq;
585 : 51431 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail242;
586 : 51431 : {
587 : 51431 : res_op->set_op (MULT_EXPR, type, 2);
588 : 51431 : {
589 : 51431 : tree _o1[2], _r1;
590 : 51431 : _o1[0] = captures[2];
591 : 51431 : _o1[1] = build_one_cst (type);
592 : 51431 : gimple_match_op tem_op (res_op->cond.any_else (), plusminus, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
593 : 51431 : tem_op.resimplify (lseq, valueize);
594 : 51431 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
595 : 51431 : if (!_r1) goto next_after_fail242;
596 : 19744 : res_op->ops[0] = _r1;
597 : : }
598 : 19744 : res_op->ops[1] = captures[1];
599 : 19744 : res_op->resimplify (lseq, valueize);
600 : 19744 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 134, __FILE__, __LINE__, true);
601 : 19744 : return true;
602 : : }
603 : : next_after_fail242:;
604 : : }
605 : : }
606 : : }
607 : : return false;
608 : : }
609 : :
610 : : bool
611 : 0 : gimple_simplify_73 (gimple_match_op *res_op, gimple_seq *seq,
612 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
613 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
614 : : const enum tree_code ARG_UNUSED (log1),
615 : : const enum tree_code ARG_UNUSED (log2),
616 : : const combined_fn ARG_UNUSED (popcount))
617 : : {
618 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
619 : 0 : gimple_seq *lseq = seq;
620 : 0 : if (lseq
621 : 0 : && (!single_use (captures[0])
622 : 0 : || !single_use (captures[1])
623 : 0 : || !single_use (captures[3])
624 : 0 : || !single_use (captures[4])
625 : 0 : || !single_use (captures[6])))
626 : 0 : lseq = NULL;
627 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail249;
628 : 0 : {
629 : 0 : res_op->set_op (popcount, type, 1);
630 : 0 : {
631 : 0 : tree _o1[2], _r1;
632 : 0 : _o1[0] = captures[2];
633 : 0 : _o1[1] = captures[5];
634 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), log2, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
635 : 0 : tem_op.resimplify (lseq, valueize);
636 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
637 : 0 : if (!_r1) goto next_after_fail249;
638 : 0 : res_op->ops[0] = _r1;
639 : : }
640 : 0 : res_op->resimplify (lseq, valueize);
641 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 141, __FILE__, __LINE__, true);
642 : : return true;
643 : : }
644 : : next_after_fail249:;
645 : : return false;
646 : : }
647 : :
648 : : bool
649 : 0 : gimple_simplify_78 (gimple_match_op *res_op, gimple_seq *seq,
650 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
651 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
652 : : {
653 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
654 : 0 : gimple_seq *lseq = seq;
655 : 0 : if (lseq
656 : 0 : && (!single_use (captures[0])
657 : 0 : || !single_use (captures[3])))
658 : 0 : lseq = NULL;
659 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail254;
660 : 0 : {
661 : 0 : res_op->set_op (MINUS_EXPR, type, 2);
662 : 0 : {
663 : 0 : tree _o1[2], _r1;
664 : 0 : _o1[0] = captures[1];
665 : 0 : _o1[1] = captures[2];
666 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_XOR_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
667 : 0 : tem_op.resimplify (lseq, valueize);
668 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
669 : 0 : if (!_r1) goto next_after_fail254;
670 : 0 : res_op->ops[0] = _r1;
671 : : }
672 : 0 : res_op->ops[1] = captures[2];
673 : 0 : res_op->resimplify (lseq, valueize);
674 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 146, __FILE__, __LINE__, true);
675 : : return true;
676 : : }
677 : : next_after_fail254:;
678 : : return false;
679 : : }
680 : :
681 : : bool
682 : 5587 : gimple_simplify_84 (gimple_match_op *res_op, gimple_seq *seq,
683 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
684 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
685 : : {
686 : 5587 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
687 : 5587 : if (tree_nop_conversion_p (type, TREE_TYPE (captures[0]))
688 : 5587 : && tree_nop_conversion_p (type, TREE_TYPE (captures[3]))
689 : : )
690 : : {
691 : 5587 : gimple_seq *lseq = seq;
692 : 5587 : if (lseq
693 : 2775 : && (!single_use (captures[1])
694 : 1756 : || !single_use (captures[2])))
695 : 3831 : lseq = NULL;
696 : 5587 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail260;
697 : 5587 : {
698 : 5587 : res_op->set_op (NOP_EXPR, type, 1);
699 : 5587 : {
700 : 5587 : tree _o1[2], _r1;
701 : 5587 : {
702 : 5587 : tree _o2[1], _r2;
703 : 5587 : _o2[0] = captures[3];
704 : 5587 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_NOT_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
705 : 5587 : tem_op.resimplify (lseq, valueize);
706 : 5587 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
707 : 5587 : if (!_r2) goto next_after_fail260;
708 : 5325 : _o1[0] = _r2;
709 : : }
710 : 5325 : _o1[1] = captures[0];
711 : 5325 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_AND_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
712 : 5325 : tem_op.resimplify (lseq, valueize);
713 : 5325 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
714 : 5325 : if (!_r1) goto next_after_fail260;
715 : 1842 : res_op->ops[0] = _r1;
716 : : }
717 : 1842 : res_op->resimplify (lseq, valueize);
718 : 1842 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 151, __FILE__, __LINE__, true);
719 : 1842 : return true;
720 : : }
721 : : next_after_fail260:;
722 : : }
723 : : return false;
724 : : }
725 : :
726 : : bool
727 : 9 : gimple_simplify_92 (gimple_match_op *res_op, gimple_seq *seq,
728 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
729 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
730 : : {
731 : 9 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
732 : 9 : if (!TYPE_SATURATING (type)
733 : : )
734 : : {
735 : 9 : if ((!FLOAT_TYPE_P (type) || flag_associative_math)
736 : 18 : && !FIXED_POINT_TYPE_P (type)
737 : : )
738 : : {
739 : 18 : if (!TYPE_OVERFLOW_TRAPS (type)
740 : 9 : && TREE_CODE (type) != COMPLEX_TYPE
741 : 9 : && tree_nop_conversion_p (type, TREE_TYPE (captures[0]))
742 : : )
743 : : {
744 : 0 : gimple_seq *lseq = seq;
745 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail272;
746 : 0 : {
747 : 0 : res_op->set_op (BIT_NOT_EXPR, type, 1);
748 : 0 : {
749 : 0 : tree _o1[1], _r1;
750 : 0 : _o1[0] = captures[0];
751 : 0 : if (type != TREE_TYPE (_o1[0])
752 : 0 : && !useless_type_conversion_p (type, TREE_TYPE (_o1[0])))
753 : : {
754 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type, _o1[0]);
755 : 0 : tem_op.resimplify (lseq, valueize);
756 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
757 : 0 : if (!_r1) goto next_after_fail272;
758 : : }
759 : : else
760 : : _r1 = _o1[0];
761 : 0 : res_op->ops[0] = _r1;
762 : : }
763 : 0 : res_op->resimplify (lseq, valueize);
764 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 163, __FILE__, __LINE__, true);
765 : 0 : return true;
766 : : }
767 : : next_after_fail272:;
768 : : }
769 : : }
770 : : }
771 : : return false;
772 : : }
773 : :
774 : : bool
775 : 3 : gimple_simplify_99 (gimple_match_op *res_op, gimple_seq *seq,
776 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
777 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
778 : : {
779 : 3 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
780 : 3 : if (TREE_CODE (captures[1]) == SSA_NAME && num_imm_uses (captures[1]) == 2
781 : : )
782 : : {
783 : 0 : gimple_seq *lseq = seq;
784 : 0 : if (lseq
785 : 0 : && (!single_use (captures[0])))
786 : 0 : lseq = NULL;
787 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail281;
788 : 0 : {
789 : 0 : res_op->set_op (MINUS_EXPR, type, 2);
790 : 0 : {
791 : 0 : tree _o1[2], _r1;
792 : 0 : {
793 : 0 : tree _o2[3], _r2;
794 : 0 : _o2[0] = captures[2];
795 : 0 : _o2[1] = captures[2];
796 : 0 : _o2[2] = captures[4];
797 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), VEC_PERM_EXPR, TREE_TYPE (_o2[0]), _o2[0], _o2[1], _o2[2]);
798 : 0 : tem_op.resimplify (lseq, valueize);
799 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
800 : 0 : if (!_r2) goto next_after_fail281;
801 : 0 : _o1[0] = _r2;
802 : : }
803 : 0 : _o1[1] = captures[3];
804 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), MULT_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
805 : 0 : tem_op.resimplify (lseq, valueize);
806 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
807 : 0 : if (!_r1) goto next_after_fail281;
808 : 0 : res_op->ops[0] = _r1;
809 : : }
810 : 0 : res_op->ops[1] = captures[5];
811 : 0 : res_op->resimplify (lseq, valueize);
812 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 172, __FILE__, __LINE__, true);
813 : 0 : return true;
814 : : }
815 : : next_after_fail281:;
816 : : }
817 : : return false;
818 : : }
819 : :
820 : : bool
821 : 0 : gimple_simplify_103 (gimple_match_op *res_op, gimple_seq *seq,
822 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
823 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
824 : : {
825 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
826 : 0 : gimple_seq *lseq = seq;
827 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail285;
828 : 0 : {
829 : 0 : tree tem;
830 : 0 : tem = captures[2];
831 : 0 : res_op->set_value (tem);
832 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 176, __FILE__, __LINE__, true);
833 : : return true;
834 : : }
835 : 0 : next_after_fail285:;
836 : 0 : return false;
837 : : }
838 : :
839 : : bool
840 : 1 : gimple_simplify_108 (gimple_match_op *res_op, gimple_seq *seq,
841 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
842 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
843 : : const enum tree_code ARG_UNUSED (op))
844 : : {
845 : 1 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
846 : 1 : gimple_seq *lseq = seq;
847 : 1 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail290;
848 : 1 : {
849 : 1 : tree tem;
850 : 1 : tem = captures[0];
851 : 1 : res_op->set_value (tem);
852 : 1 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 180, __FILE__, __LINE__, true);
853 : : return true;
854 : : }
855 : 0 : next_after_fail290:;
856 : 0 : return false;
857 : : }
858 : :
859 : : bool
860 : 0 : gimple_simplify_111 (gimple_match_op *res_op, gimple_seq *seq,
861 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
862 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
863 : : {
864 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
865 : 0 : gimple_seq *lseq = seq;
866 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail293;
867 : 0 : {
868 : 0 : tree tem;
869 : 0 : tem = captures[2];
870 : 0 : res_op->set_value (tem);
871 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 182, __FILE__, __LINE__, true);
872 : : return true;
873 : : }
874 : 0 : next_after_fail293:;
875 : 0 : return false;
876 : : }
877 : :
878 : : bool
879 : 1206 : gimple_simplify_118 (gimple_match_op *res_op, gimple_seq *seq,
880 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
881 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
882 : : const enum tree_code ARG_UNUSED (bitop))
883 : : {
884 : 1206 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
885 : 1206 : gimple_seq *lseq = seq;
886 : 1206 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail300;
887 : 1206 : {
888 : 1206 : tree tem;
889 : 1206 : tem = captures[0];
890 : 1206 : res_op->set_value (tem);
891 : 1206 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 186, __FILE__, __LINE__, true);
892 : : return true;
893 : : }
894 : 0 : next_after_fail300:;
895 : 0 : return false;
896 : : }
897 : :
898 : : bool
899 : 326506 : gimple_simplify_125 (gimple_match_op *res_op, gimple_seq *seq,
900 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
901 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
902 : : {
903 : 326506 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
904 : 326506 : {
905 : 326506 : bool wascmp;
906 : 326506 : if ((bitwise_inverted_equal_p (captures[0], captures[2], wascmp)
907 : 326505 : || bitwise_inverted_equal_p (captures[1], captures[2], wascmp))
908 : 326508 : && (!wascmp || element_precision (type) == 1)
909 : : )
910 : : {
911 : 3 : gimple_seq *lseq = seq;
912 : 3 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail307;
913 : 3 : {
914 : 3 : tree tem;
915 : 3 : tem = build_all_ones_cst (TREE_TYPE (captures[0]));
916 : 3 : res_op->set_value (tem);
917 : 3 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 191, __FILE__, __LINE__, true);
918 : 3 : return true;
919 : : }
920 : 0 : next_after_fail307:;
921 : : }
922 : : }
923 : 326503 : return false;
924 : : }
925 : :
926 : : bool
927 : 1 : gimple_simplify_132 (gimple_match_op *res_op, gimple_seq *seq,
928 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
929 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
930 : : const enum tree_code ARG_UNUSED (bitop),
931 : : const enum tree_code ARG_UNUSED (rbitop))
932 : : {
933 : 1 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
934 : 1 : gimple_seq *lseq = seq;
935 : 1 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail318;
936 : 1 : {
937 : 1 : tree tem;
938 : 1 : tem = captures[2];
939 : 1 : res_op->set_value (tem);
940 : 1 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 196, __FILE__, __LINE__, true);
941 : : return true;
942 : : }
943 : 0 : next_after_fail318:;
944 : 0 : return false;
945 : : }
946 : :
947 : : bool
948 : 0 : gimple_simplify_134 (gimple_match_op *res_op, gimple_seq *seq,
949 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
950 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
951 : : const enum tree_code ARG_UNUSED (op))
952 : : {
953 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
954 : 0 : if (bitwise_equal_p (captures[4], captures[7])
955 : : )
956 : : {
957 : 0 : gimple_seq *lseq = seq;
958 : 0 : if (lseq
959 : 0 : && (!single_use (captures[0])
960 : 0 : || !single_use (captures[1])
961 : 0 : || !single_use (captures[2])
962 : 0 : || !single_use (captures[3])))
963 : 0 : lseq = NULL;
964 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail320;
965 : 0 : {
966 : 0 : res_op->set_op (NOP_EXPR, type, 1);
967 : 0 : {
968 : 0 : tree _o1[2], _r1;
969 : 0 : {
970 : 0 : tree _o2[2], _r2;
971 : 0 : _o2[0] = captures[5];
972 : 0 : {
973 : 0 : tree _o3[1], _r3;
974 : 0 : _o3[0] = captures[6];
975 : 0 : if (TREE_TYPE (_o2[0]) != TREE_TYPE (_o3[0])
976 : 0 : && !useless_type_conversion_p (TREE_TYPE (_o2[0]), TREE_TYPE (_o3[0])))
977 : : {
978 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, TREE_TYPE (_o2[0]), _o3[0]);
979 : 0 : tem_op.resimplify (lseq, valueize);
980 : 0 : _r3 = maybe_push_res_to_seq (&tem_op, lseq);
981 : 0 : if (!_r3) goto next_after_fail320;
982 : : }
983 : : else
984 : : _r3 = _o3[0];
985 : 0 : _o2[1] = _r3;
986 : : }
987 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_AND_EXPR, TREE_TYPE (_o2[0]), _o2[0], _o2[1]);
988 : 0 : tem_op.resimplify (lseq, valueize);
989 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
990 : 0 : if (!_r2) goto next_after_fail320;
991 : 0 : _o1[0] = _r2;
992 : : }
993 : 0 : {
994 : 0 : tree _o2[1], _r2;
995 : 0 : _o2[0] = captures[4];
996 : 0 : if (TREE_TYPE (_o1[0]) != TREE_TYPE (_o2[0])
997 : 0 : && !useless_type_conversion_p (TREE_TYPE (_o1[0]), TREE_TYPE (_o2[0])))
998 : : {
999 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, TREE_TYPE (_o1[0]), _o2[0]);
1000 : 0 : tem_op.resimplify (lseq, valueize);
1001 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
1002 : 0 : if (!_r2) goto next_after_fail320;
1003 : : }
1004 : : else
1005 : : _r2 = _o2[0];
1006 : 0 : _o1[1] = _r2;
1007 : : }
1008 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_IOR_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
1009 : 0 : tem_op.resimplify (lseq, valueize);
1010 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
1011 : 0 : if (!_r1) goto next_after_fail320;
1012 : 0 : res_op->ops[0] = _r1;
1013 : : }
1014 : 0 : res_op->resimplify (lseq, valueize);
1015 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 198, __FILE__, __LINE__, true);
1016 : 0 : return true;
1017 : : }
1018 : : next_after_fail320:;
1019 : : }
1020 : : return false;
1021 : : }
1022 : :
1023 : : bool
1024 : 68 : gimple_simplify_148 (gimple_match_op *res_op, gimple_seq *seq,
1025 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1026 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
1027 : : {
1028 : 68 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1029 : 136 : if (INTEGRAL_TYPE_P (TREE_TYPE (captures[1]))
1030 : 134 : && TYPE_OVERFLOW_WRAPS (TREE_TYPE (captures[1]))
1031 : : )
1032 : : {
1033 : 61 : gimple_seq *lseq = seq;
1034 : 61 : if (lseq
1035 : 40 : && (!single_use (captures[0])
1036 : 40 : || !single_use (captures[2])))
1037 : 21 : lseq = NULL;
1038 : 61 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail338;
1039 : 61 : {
1040 : 61 : res_op->set_op (LE_EXPR, type, 2);
1041 : 61 : res_op->ops[0] = captures[3];
1042 : 61 : {
1043 : 61 : tree _o1[2], _r1;
1044 : 61 : _o1[0] = captures[1];
1045 : 61 : _o1[1] = build_int_cst (TREE_TYPE (captures[1]), 1);
1046 : 61 : gimple_match_op tem_op (res_op->cond.any_else (), MINUS_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
1047 : 61 : tem_op.resimplify (lseq, valueize);
1048 : 61 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
1049 : 61 : if (!_r1) goto next_after_fail338;
1050 : 40 : res_op->ops[1] = _r1;
1051 : : }
1052 : 40 : res_op->resimplify (lseq, valueize);
1053 : 40 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 211, __FILE__, __LINE__, true);
1054 : 40 : return true;
1055 : : }
1056 : : next_after_fail338:;
1057 : : }
1058 : : return false;
1059 : : }
1060 : :
1061 : : bool
1062 : 18 : gimple_simplify_158 (gimple_match_op *res_op, gimple_seq *seq,
1063 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1064 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
1065 : : {
1066 : 18 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1067 : 18 : gimple_seq *lseq = seq;
1068 : 18 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail379;
1069 : 18 : {
1070 : 18 : tree tem;
1071 : 18 : tem = constant_boolean_node (true, type);
1072 : 18 : res_op->set_value (tem);
1073 : 18 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 226, __FILE__, __LINE__, true);
1074 : : return true;
1075 : : }
1076 : 0 : next_after_fail379:;
1077 : 0 : return false;
1078 : : }
1079 : :
1080 : : bool
1081 : 53 : gimple_simplify_160 (gimple_match_op *res_op, gimple_seq *seq,
1082 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1083 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
1084 : : {
1085 : 53 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1086 : 53 : gimple_seq *lseq = seq;
1087 : 53 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail382;
1088 : 53 : {
1089 : 53 : tree tem;
1090 : 53 : tem = captures[0];
1091 : 53 : res_op->set_value (tem);
1092 : 53 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 229, __FILE__, __LINE__, true);
1093 : : return true;
1094 : : }
1095 : 0 : next_after_fail382:;
1096 : 0 : return false;
1097 : : }
1098 : :
1099 : : bool
1100 : 2 : gimple_simplify_163 (gimple_match_op *res_op, gimple_seq *seq,
1101 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1102 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
1103 : : {
1104 : 2 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1105 : 2 : gimple_seq *lseq = seq;
1106 : 2 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail385;
1107 : 2 : {
1108 : 2 : tree tem;
1109 : 2 : tem = captures[1];
1110 : 2 : res_op->set_value (tem);
1111 : 2 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 230, __FILE__, __LINE__, true);
1112 : : return true;
1113 : : }
1114 : 0 : next_after_fail385:;
1115 : 0 : return false;
1116 : : }
1117 : :
1118 : : bool
1119 : 0 : gimple_simplify_166 (gimple_match_op *res_op, gimple_seq *seq,
1120 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1121 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
1122 : : {
1123 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1124 : 0 : if (!tree_expr_maybe_nan_p (captures[0]) && !HONOR_SIGNED_ZEROS (type)
1125 : : )
1126 : : {
1127 : 0 : gimple_seq *lseq = seq;
1128 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail388;
1129 : 0 : {
1130 : 0 : res_op->set_op (NOP_EXPR, type, 1);
1131 : 0 : {
1132 : 0 : tree _o1[1], _r1;
1133 : 0 : _o1[0] = captures[0];
1134 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), ABS_EXPR, TREE_TYPE (_o1[0]), _o1[0]);
1135 : 0 : tem_op.resimplify (lseq, valueize);
1136 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
1137 : 0 : if (!_r1) goto next_after_fail388;
1138 : 0 : res_op->ops[0] = _r1;
1139 : : }
1140 : 0 : res_op->resimplify (lseq, valueize);
1141 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 232, __FILE__, __LINE__, true);
1142 : 0 : return true;
1143 : : }
1144 : : next_after_fail388:;
1145 : : }
1146 : : return false;
1147 : : }
1148 : :
1149 : : bool
1150 : 0 : gimple_simplify_170 (gimple_match_op *res_op, gimple_seq *seq,
1151 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1152 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
1153 : : {
1154 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1155 : 0 : if (!tree_expr_maybe_nan_p (captures[0]) && !HONOR_SIGNED_ZEROS (type)
1156 : : )
1157 : : {
1158 : 0 : gimple_seq *lseq = seq;
1159 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail392;
1160 : 0 : {
1161 : 0 : res_op->set_op (NEGATE_EXPR, type, 1);
1162 : 0 : {
1163 : 0 : tree _o1[1], _r1;
1164 : 0 : _o1[0] = captures[0];
1165 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), ABS_EXPR, TREE_TYPE (_o1[0]), _o1[0]);
1166 : 0 : tem_op.resimplify (lseq, valueize);
1167 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
1168 : 0 : if (!_r1) goto next_after_fail392;
1169 : 0 : res_op->ops[0] = _r1;
1170 : : }
1171 : 0 : res_op->resimplify (lseq, valueize);
1172 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 233, __FILE__, __LINE__, true);
1173 : 0 : return true;
1174 : : }
1175 : : next_after_fail392:;
1176 : : }
1177 : : return false;
1178 : : }
1179 : :
1180 : : bool
1181 : 0 : gimple_simplify_175 (gimple_match_op *res_op, gimple_seq *seq,
1182 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1183 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
1184 : : {
1185 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1186 : 0 : if (!tree_expr_maybe_nan_p (captures[0]) && !HONOR_SIGNED_ZEROS (type)
1187 : : )
1188 : : {
1189 : 0 : gimple_seq *lseq = seq;
1190 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail397;
1191 : 0 : {
1192 : 0 : res_op->set_op (NEGATE_EXPR, type, 1);
1193 : 0 : {
1194 : 0 : tree _o1[1], _r1;
1195 : 0 : _o1[0] = captures[0];
1196 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), ABS_EXPR, TREE_TYPE (_o1[0]), _o1[0]);
1197 : 0 : tem_op.resimplify (lseq, valueize);
1198 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
1199 : 0 : if (!_r1) goto next_after_fail397;
1200 : 0 : res_op->ops[0] = _r1;
1201 : : }
1202 : 0 : res_op->resimplify (lseq, valueize);
1203 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 232, __FILE__, __LINE__, true);
1204 : 0 : return true;
1205 : : }
1206 : : next_after_fail397:;
1207 : : }
1208 : : return false;
1209 : : }
1210 : :
1211 : : bool
1212 : 2 : gimple_simplify_181 (gimple_match_op *res_op, gimple_seq *seq,
1213 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1214 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
1215 : : const combined_fn ARG_UNUSED (COPYSIGN_ALL))
1216 : : {
1217 : 2 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1218 : 2 : if (!tree_expr_maybe_nan_p (captures[0]) && !HONOR_SIGNED_ZEROS (type)
1219 : : )
1220 : : {
1221 : 2 : gimple_seq *lseq = seq;
1222 : 2 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail403;
1223 : 2 : {
1224 : 2 : res_op->set_op (ABS_EXPR, type, 1);
1225 : 2 : res_op->ops[0] = captures[0];
1226 : 2 : res_op->resimplify (lseq, valueize);
1227 : 2 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 234, __FILE__, __LINE__, true);
1228 : 2 : return true;
1229 : : }
1230 : 0 : next_after_fail403:;
1231 : : }
1232 : : return false;
1233 : : }
1234 : :
1235 : : bool
1236 : 2 : gimple_simplify_186 (gimple_match_op *res_op, gimple_seq *seq,
1237 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1238 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
1239 : : const combined_fn ARG_UNUSED (copysigns))
1240 : : {
1241 : 2 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1242 : 2 : gimple_seq *lseq = seq;
1243 : 2 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail408;
1244 : 2 : {
1245 : 2 : res_op->set_op (MULT_EXPR, type, 2);
1246 : 2 : res_op->ops[0] = captures[1];
1247 : 2 : res_op->ops[1] = captures[1];
1248 : 2 : res_op->resimplify (lseq, valueize);
1249 : 2 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 237, __FILE__, __LINE__, true);
1250 : : return true;
1251 : : }
1252 : 0 : next_after_fail408:;
1253 : 0 : return false;
1254 : : }
1255 : :
1256 : : bool
1257 : 20676 : gimple_simplify_197 (gimple_match_op *res_op, gimple_seq *seq,
1258 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1259 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
1260 : : {
1261 : 20676 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1262 : 20676 : if (TREE_CODE (captures[3]) != INTEGER_CST
1263 : 20603 : && single_use (captures[0])
1264 : 26951 : && !integer_zerop (captures[2]) && !integer_minus_onep (captures[2])
1265 : : )
1266 : : {
1267 : 6274 : gimple_seq *lseq = seq;
1268 : 6274 : if (lseq
1269 : 2016 : && (!single_use (captures[0])))
1270 : 4258 : lseq = NULL;
1271 : 6274 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail422;
1272 : 6274 : {
1273 : 6274 : res_op->set_op (MULT_EXPR, type, 2);
1274 : 6274 : {
1275 : 6274 : tree _o1[2], _r1;
1276 : 6274 : _o1[0] = captures[1];
1277 : 6274 : _o1[1] = captures[3];
1278 : 6274 : gimple_match_op tem_op (res_op->cond.any_else (), MULT_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
1279 : 6274 : tem_op.resimplify (lseq, valueize);
1280 : 6274 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
1281 : 6274 : if (!_r1) goto next_after_fail422;
1282 : 3018 : res_op->ops[0] = _r1;
1283 : : }
1284 : 3018 : res_op->ops[1] = captures[2];
1285 : 3018 : res_op->resimplify (lseq, valueize);
1286 : 3018 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 247, __FILE__, __LINE__, true);
1287 : 3018 : return true;
1288 : : }
1289 : : next_after_fail422:;
1290 : : }
1291 : : return false;
1292 : : }
1293 : :
1294 : : bool
1295 : 0 : gimple_simplify_205 (gimple_match_op *res_op, gimple_seq *seq,
1296 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1297 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
1298 : : const enum tree_code ARG_UNUSED (op))
1299 : : {
1300 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1301 : 0 : gimple_seq *lseq = seq;
1302 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail430;
1303 : 0 : {
1304 : 0 : tree tem;
1305 : 0 : tem = constant_boolean_node (op == NE_EXPR ? true : false, type);
1306 : 0 : res_op->set_value (tem);
1307 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 255, __FILE__, __LINE__, true);
1308 : : return true;
1309 : : }
1310 : 0 : next_after_fail430:;
1311 : 0 : return false;
1312 : : }
1313 : :
1314 : : bool
1315 : 32453 : gimple_simplify_212 (gimple_match_op *res_op, gimple_seq *seq,
1316 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1317 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
1318 : : const enum tree_code ARG_UNUSED (cmp))
1319 : : {
1320 : 32453 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1321 : 64906 : if (INTEGRAL_TYPE_P (TREE_TYPE (captures[1]))
1322 : 32453 : && integer_nonzerop (captures[2])
1323 : 31662 : && !TREE_OVERFLOW (captures[2])
1324 : 64115 : && !TREE_OVERFLOW (captures[3])
1325 : : )
1326 : : {
1327 : 31662 : {
1328 : 31662 : tree lo, hi; bool neg_overflow;
1329 : 31662 : enum tree_code code = fold_div_compare (cmp, captures[2], captures[3], &lo, &hi,
1330 : : &neg_overflow);
1331 : 31662 : if (code == LT_EXPR || code == GE_EXPR
1332 : : )
1333 : : {
1334 : 3747 : if (TREE_OVERFLOW (lo)
1335 : : )
1336 : : {
1337 : 12 : gimple_seq *lseq = seq;
1338 : 12 : if (lseq
1339 : : && (!single_use (captures[0])))
1340 : : lseq = NULL;
1341 : 12 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail440;
1342 : 12 : {
1343 : 12 : tree tem;
1344 : 12 : tem = build_int_cst (type, (code == LT_EXPR) ^ neg_overflow);
1345 : 12 : res_op->set_value (tem);
1346 : 12 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 264, __FILE__, __LINE__, true);
1347 : 20032 : return true;
1348 : : }
1349 : 0 : next_after_fail440:;
1350 : : }
1351 : : else
1352 : : {
1353 : 3735 : if (code == LT_EXPR
1354 : : )
1355 : : {
1356 : 811 : gimple_seq *lseq = seq;
1357 : 811 : if (lseq
1358 : 90 : && (!single_use (captures[0])))
1359 : 792 : lseq = NULL;
1360 : 811 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail441;
1361 : 811 : {
1362 : 811 : res_op->set_op (LT_EXPR, type, 2);
1363 : 811 : res_op->ops[0] = captures[1];
1364 : 811 : res_op->ops[1] = lo;
1365 : 811 : res_op->resimplify (lseq, valueize);
1366 : 811 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 265, __FILE__, __LINE__, true);
1367 : 811 : return true;
1368 : : }
1369 : 0 : next_after_fail441:;
1370 : : }
1371 : : else
1372 : : {
1373 : 2924 : gimple_seq *lseq = seq;
1374 : 2924 : if (lseq
1375 : 779 : && (!single_use (captures[0])))
1376 : 2907 : lseq = NULL;
1377 : 2924 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail442;
1378 : 2924 : {
1379 : 2924 : res_op->set_op (GE_EXPR, type, 2);
1380 : 2924 : res_op->ops[0] = captures[1];
1381 : 2924 : res_op->ops[1] = lo;
1382 : 2924 : res_op->resimplify (lseq, valueize);
1383 : 2924 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 266, __FILE__, __LINE__, true);
1384 : 2924 : return true;
1385 : : }
1386 : 0 : next_after_fail442:;
1387 : : }
1388 : : }
1389 : : }
1390 : : else
1391 : : {
1392 : 27915 : if (code == LE_EXPR || code == GT_EXPR
1393 : : )
1394 : : {
1395 : 14793 : if (TREE_OVERFLOW (hi)
1396 : : )
1397 : : {
1398 : 52 : gimple_seq *lseq = seq;
1399 : 52 : if (lseq
1400 : : && (!single_use (captures[0])))
1401 : : lseq = NULL;
1402 : 52 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail443;
1403 : 52 : {
1404 : 52 : tree tem;
1405 : 52 : tem = build_int_cst (type, (code == LE_EXPR) ^ neg_overflow);
1406 : 52 : res_op->set_value (tem);
1407 : 52 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 267, __FILE__, __LINE__, true);
1408 : 52 : return true;
1409 : : }
1410 : 0 : next_after_fail443:;
1411 : : }
1412 : : else
1413 : : {
1414 : 14741 : if (code == LE_EXPR
1415 : : )
1416 : : {
1417 : 2775 : gimple_seq *lseq = seq;
1418 : 2775 : if (lseq
1419 : 2277 : && (!single_use (captures[0])))
1420 : 2720 : lseq = NULL;
1421 : 2775 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail444;
1422 : 2775 : {
1423 : 2775 : res_op->set_op (LE_EXPR, type, 2);
1424 : 2775 : res_op->ops[0] = captures[1];
1425 : 2775 : res_op->ops[1] = hi;
1426 : 2775 : res_op->resimplify (lseq, valueize);
1427 : 2775 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 268, __FILE__, __LINE__, true);
1428 : 2775 : return true;
1429 : : }
1430 : 0 : next_after_fail444:;
1431 : : }
1432 : : else
1433 : : {
1434 : 11966 : gimple_seq *lseq = seq;
1435 : 11966 : if (lseq
1436 : 2832 : && (!single_use (captures[0])))
1437 : 11854 : lseq = NULL;
1438 : 11966 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail445;
1439 : 11966 : {
1440 : 11966 : res_op->set_op (GT_EXPR, type, 2);
1441 : 11966 : res_op->ops[0] = captures[1];
1442 : 11966 : res_op->ops[1] = hi;
1443 : 11966 : res_op->resimplify (lseq, valueize);
1444 : 11966 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 269, __FILE__, __LINE__, true);
1445 : 11966 : return true;
1446 : : }
1447 : 0 : next_after_fail445:;
1448 : : }
1449 : : }
1450 : : }
1451 : : else
1452 : : {
1453 : 13122 : if (!lo && !hi
1454 : : )
1455 : : {
1456 : 22 : gimple_seq *lseq = seq;
1457 : 22 : if (lseq
1458 : : && (!single_use (captures[0])))
1459 : : lseq = NULL;
1460 : 22 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail446;
1461 : 22 : {
1462 : 22 : tree tem;
1463 : 22 : tem = build_int_cst (type, code == NE_EXPR);
1464 : 22 : res_op->set_value (tem);
1465 : 22 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 270, __FILE__, __LINE__, true);
1466 : 22 : return true;
1467 : : }
1468 : 0 : next_after_fail446:;
1469 : 0 : }
1470 : : else
1471 : : {
1472 : 13100 : if (code == EQ_EXPR && !hi
1473 : : )
1474 : : {
1475 : 11 : gimple_seq *lseq = seq;
1476 : 11 : if (lseq
1477 : 7 : && (!single_use (captures[0])))
1478 : 6 : lseq = NULL;
1479 : 11 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail447;
1480 : 11 : {
1481 : 11 : res_op->set_op (GE_EXPR, type, 2);
1482 : 11 : res_op->ops[0] = captures[1];
1483 : 11 : res_op->ops[1] = lo;
1484 : 11 : res_op->resimplify (lseq, valueize);
1485 : 11 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 271, __FILE__, __LINE__, true);
1486 : 11 : return true;
1487 : : }
1488 : 0 : next_after_fail447:;
1489 : 0 : }
1490 : : else
1491 : : {
1492 : 4302 : if (code == EQ_EXPR && !lo
1493 : : )
1494 : : {
1495 : 468 : gimple_seq *lseq = seq;
1496 : 468 : if (lseq
1497 : 143 : && (!single_use (captures[0])))
1498 : 428 : lseq = NULL;
1499 : 468 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail448;
1500 : 468 : {
1501 : 468 : res_op->set_op (LE_EXPR, type, 2);
1502 : 468 : res_op->ops[0] = captures[1];
1503 : 468 : res_op->ops[1] = hi;
1504 : 468 : res_op->resimplify (lseq, valueize);
1505 : 468 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 272, __FILE__, __LINE__, true);
1506 : 468 : return true;
1507 : : }
1508 : 0 : next_after_fail448:;
1509 : 0 : }
1510 : : else
1511 : : {
1512 : 12621 : if (code == NE_EXPR && !hi
1513 : : )
1514 : : {
1515 : 13 : gimple_seq *lseq = seq;
1516 : 13 : if (lseq
1517 : 9 : && (!single_use (captures[0])))
1518 : 9 : lseq = NULL;
1519 : 13 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail449;
1520 : 13 : {
1521 : 13 : res_op->set_op (LT_EXPR, type, 2);
1522 : 13 : res_op->ops[0] = captures[1];
1523 : 13 : res_op->ops[1] = lo;
1524 : 13 : res_op->resimplify (lseq, valueize);
1525 : 13 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 273, __FILE__, __LINE__, true);
1526 : 13 : return true;
1527 : : }
1528 : 0 : next_after_fail449:;
1529 : 0 : }
1530 : : else
1531 : : {
1532 : 8774 : if (code == NE_EXPR && !lo
1533 : : )
1534 : : {
1535 : 788 : gimple_seq *lseq = seq;
1536 : 788 : if (lseq
1537 : 504 : && (!single_use (captures[0])))
1538 : 771 : lseq = NULL;
1539 : 788 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail450;
1540 : 788 : {
1541 : 788 : res_op->set_op (GT_EXPR, type, 2);
1542 : 788 : res_op->ops[0] = captures[1];
1543 : 788 : res_op->ops[1] = hi;
1544 : 788 : res_op->resimplify (lseq, valueize);
1545 : 788 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 274, __FILE__, __LINE__, true);
1546 : 788 : return true;
1547 : : }
1548 : 0 : next_after_fail450:;
1549 : 0 : }
1550 : : else
1551 : : {
1552 : 11820 : if (0
1553 : : )
1554 : : {
1555 : : gimple_seq *lseq = seq;
1556 : : if (lseq
1557 : : && (!single_use (captures[0])))
1558 : : lseq = NULL;
1559 : : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail451;
1560 : : {
1561 : : tree tem;
1562 : : tem = build_range_check (UNKNOWN_LOCATION, type, captures[1], code == EQ_EXPR,
1563 : : lo, hi);
1564 : : res_op->set_value (tem);
1565 : : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 275, __FILE__, __LINE__, true);
1566 : : return true;
1567 : : }
1568 : : next_after_fail451:;
1569 : : }
1570 : : else
1571 : : {
1572 : 11820 : {
1573 : 11820 : tree etype = range_check_type (TREE_TYPE (captures[1]));
1574 : 11820 : if (etype)
1575 : : {
1576 : 11820 : hi = fold_convert (etype, hi);
1577 : 11820 : lo = fold_convert (etype, lo);
1578 : 11820 : hi = const_binop (MINUS_EXPR, etype, hi, lo);
1579 : : }
1580 : 11820 : if (etype && hi && !TREE_OVERFLOW (hi)
1581 : : )
1582 : : {
1583 : 11820 : if (code == EQ_EXPR
1584 : : )
1585 : : {
1586 : 3834 : gimple_seq *lseq = seq;
1587 : 3834 : if (lseq
1588 : 670 : && (!single_use (captures[0])))
1589 : 3766 : lseq = NULL;
1590 : 3834 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail452;
1591 : 3834 : {
1592 : 3834 : res_op->set_op (LE_EXPR, type, 2);
1593 : 3834 : {
1594 : 3834 : tree _o1[2], _r1;
1595 : 3834 : {
1596 : 3834 : tree _o2[1], _r2;
1597 : 3834 : _o2[0] = captures[1];
1598 : 3834 : if (etype != TREE_TYPE (_o2[0])
1599 : 3834 : && !useless_type_conversion_p (etype, TREE_TYPE (_o2[0])))
1600 : : {
1601 : 3582 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, etype, _o2[0]);
1602 : 3582 : tem_op.resimplify (lseq, valueize);
1603 : 3582 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
1604 : 3582 : if (!_r2) goto next_after_fail452;
1605 : : }
1606 : : else
1607 : : _r2 = _o2[0];
1608 : 594 : _o1[0] = _r2;
1609 : : }
1610 : 594 : _o1[1] = lo;
1611 : 594 : gimple_match_op tem_op (res_op->cond.any_else (), MINUS_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
1612 : 594 : tem_op.resimplify (lseq, valueize);
1613 : 594 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
1614 : 594 : if (!_r1) goto next_after_fail452;
1615 : 68 : res_op->ops[0] = _r1;
1616 : : }
1617 : 68 : res_op->ops[1] = hi;
1618 : 68 : res_op->resimplify (lseq, valueize);
1619 : 68 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 276, __FILE__, __LINE__, true);
1620 : 68 : return true;
1621 : : }
1622 : 11630 : next_after_fail452:;
1623 : : }
1624 : : else
1625 : : {
1626 : 7986 : gimple_seq *lseq = seq;
1627 : 7986 : if (lseq
1628 : 2101 : && (!single_use (captures[0])))
1629 : 7864 : lseq = NULL;
1630 : 7986 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail453;
1631 : 7986 : {
1632 : 7986 : res_op->set_op (GT_EXPR, type, 2);
1633 : 7986 : {
1634 : 7986 : tree _o1[2], _r1;
1635 : 7986 : {
1636 : 7986 : tree _o2[1], _r2;
1637 : 7986 : _o2[0] = captures[1];
1638 : 7986 : if (etype != TREE_TYPE (_o2[0])
1639 : 7986 : && !useless_type_conversion_p (etype, TREE_TYPE (_o2[0])))
1640 : : {
1641 : 7358 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, etype, _o2[0]);
1642 : 7358 : tem_op.resimplify (lseq, valueize);
1643 : 7358 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
1644 : 7358 : if (!_r2) goto next_after_fail453;
1645 : : }
1646 : : else
1647 : : _r2 = _o2[0];
1648 : 2537 : _o1[0] = _r2;
1649 : : }
1650 : 2537 : _o1[1] = lo;
1651 : 2537 : gimple_match_op tem_op (res_op->cond.any_else (), MINUS_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
1652 : 2537 : tem_op.resimplify (lseq, valueize);
1653 : 2537 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
1654 : 2537 : if (!_r1) goto next_after_fail453;
1655 : 122 : res_op->ops[0] = _r1;
1656 : : }
1657 : 122 : res_op->ops[1] = hi;
1658 : 122 : res_op->resimplify (lseq, valueize);
1659 : 122 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 277, __FILE__, __LINE__, true);
1660 : 122 : return true;
1661 : : }
1662 : 11630 : next_after_fail453:;
1663 : : }
1664 : : }
1665 : : }
1666 : : }
1667 : : }
1668 : : }
1669 : : }
1670 : : }
1671 : : }
1672 : : }
1673 : : }
1674 : : }
1675 : : }
1676 : : return false;
1677 : : }
1678 : :
1679 : : bool
1680 : 6748 : gimple_simplify_266 (gimple_match_op *res_op, gimple_seq *seq,
1681 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1682 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
1683 : : const enum tree_code ARG_UNUSED (cmp))
1684 : : {
1685 : 6748 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1686 : 6748 : gimple_seq *lseq = seq;
1687 : 6748 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail581;
1688 : 6748 : {
1689 : 6748 : res_op->set_op (cmp, type, 2);
1690 : 6748 : res_op->ops[0] = captures[0];
1691 : 6748 : res_op->ops[1] = captures[1];
1692 : 6748 : res_op->resimplify (lseq, valueize);
1693 : 6748 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 395, __FILE__, __LINE__, true);
1694 : : return true;
1695 : : }
1696 : 0 : next_after_fail581:;
1697 : 0 : return false;
1698 : : }
1699 : :
1700 : : bool
1701 : 182428 : gimple_simplify_268 (gimple_match_op *res_op, gimple_seq *seq,
1702 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1703 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
1704 : : const enum tree_code ARG_UNUSED (cmp))
1705 : : {
1706 : 182428 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1707 : 182428 : gimple_seq *lseq = seq;
1708 : 182428 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail583;
1709 : 182428 : {
1710 : 182428 : res_op->set_op (cmp, type, 2);
1711 : 182428 : {
1712 : 182428 : tree _o1[2], _r1;
1713 : 182428 : _o1[0] = captures[0];
1714 : 182428 : {
1715 : 182428 : tree _o2[1], _r2;
1716 : 182428 : _o2[0] = captures[1];
1717 : 182428 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_NOT_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
1718 : 182428 : tem_op.resimplify (NULL, valueize);
1719 : 182428 : _r2 = maybe_push_res_to_seq (&tem_op, NULL);
1720 : 182428 : if (!_r2) goto next_after_fail583;
1721 : 20022 : _o1[1] = _r2;
1722 : : }
1723 : 20022 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_AND_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
1724 : 20022 : tem_op.resimplify (lseq, valueize);
1725 : 20022 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
1726 : 20022 : if (!_r1) goto next_after_fail583;
1727 : 10806 : res_op->ops[0] = _r1;
1728 : : }
1729 : 10806 : res_op->ops[1] = build_zero_cst (TREE_TYPE (captures[0]));
1730 : 10806 : res_op->resimplify (lseq, valueize);
1731 : 10806 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 397, __FILE__, __LINE__, true);
1732 : : return true;
1733 : : }
1734 : : next_after_fail583:;
1735 : : return false;
1736 : : }
1737 : :
1738 : : bool
1739 : 103935925 : gimple_simplify_272 (gimple_match_op *res_op, gimple_seq *seq,
1740 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1741 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
1742 : : const enum tree_code ARG_UNUSED (cmp))
1743 : : {
1744 : 103935925 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1745 : 103935925 : if (tree_expr_nonzero_p (captures[0])
1746 : : )
1747 : : {
1748 : 76411 : gimple_seq *lseq = seq;
1749 : 76411 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail587;
1750 : 76411 : {
1751 : 76411 : tree tem;
1752 : 76411 : tem = constant_boolean_node (cmp == NE_EXPR, type);
1753 : 76411 : res_op->set_value (tem);
1754 : 76411 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 401, __FILE__, __LINE__, true);
1755 : 76411 : return true;
1756 : : }
1757 : 0 : next_after_fail587:;
1758 : : }
1759 : : return false;
1760 : : }
1761 : :
1762 : : bool
1763 : 1185 : gimple_simplify_274 (gimple_match_op *res_op, gimple_seq *seq,
1764 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1765 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
1766 : : const enum tree_code ARG_UNUSED (cmp),
1767 : : const enum tree_code ARG_UNUSED (icmp))
1768 : : {
1769 : 1185 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1770 : 1185 : gimple_seq *lseq = seq;
1771 : 1185 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail589;
1772 : 1185 : {
1773 : 1185 : res_op->set_op (icmp, type, 2);
1774 : 1185 : res_op->ops[0] = captures[0];
1775 : 1185 : res_op->ops[1] = build_zero_cst (TREE_TYPE (captures[1]));
1776 : 1185 : res_op->resimplify (lseq, valueize);
1777 : 1185 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 403, __FILE__, __LINE__, true);
1778 : : return true;
1779 : : }
1780 : 0 : next_after_fail589:;
1781 : 0 : return false;
1782 : : }
1783 : :
1784 : : bool
1785 : 32866 : gimple_simplify_278 (gimple_match_op *res_op, gimple_seq *seq,
1786 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1787 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
1788 : : const enum tree_code ARG_UNUSED (cmp))
1789 : : {
1790 : 32866 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1791 : 53554 : if (!FLOAT_TYPE_P (TREE_TYPE (captures[3]))
1792 : 32866 : || !operation_could_trap_p (cmp, true, false, captures[3])
1793 : : )
1794 : : {
1795 : 23597 : gimple_seq *lseq = seq;
1796 : 23597 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail593;
1797 : 23597 : {
1798 : 23597 : res_op->set_op (COND_EXPR, type, 3);
1799 : 23597 : res_op->ops[0] = captures[0];
1800 : 23597 : res_op->ops[0] = unshare_expr (res_op->ops[0]);
1801 : 23597 : {
1802 : 23597 : tree _o1[2], _r1;
1803 : 23597 : _o1[0] = captures[1];
1804 : 23597 : _o1[1] = captures[3];
1805 : 23597 : gimple_match_op tem_op (res_op->cond.any_else (), cmp, type, _o1[0], _o1[1]);
1806 : 23597 : tem_op.resimplify (NULL, valueize);
1807 : 23597 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
1808 : 23597 : if (!_r1) goto next_after_fail593;
1809 : 1977 : res_op->ops[1] = _r1;
1810 : : }
1811 : 1977 : {
1812 : 1977 : tree _o1[2], _r1;
1813 : 1977 : _o1[0] = captures[2];
1814 : 1977 : _o1[1] = captures[3];
1815 : 1977 : gimple_match_op tem_op (res_op->cond.any_else (), cmp, type, _o1[0], _o1[1]);
1816 : 1977 : tem_op.resimplify (NULL, valueize);
1817 : 1977 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
1818 : 1977 : if (!_r1) goto next_after_fail593;
1819 : 730 : res_op->ops[2] = _r1;
1820 : : }
1821 : 730 : res_op->resimplify (lseq, valueize);
1822 : 730 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 406, __FILE__, __LINE__, true);
1823 : 730 : return true;
1824 : : }
1825 : : next_after_fail593:;
1826 : : }
1827 : : return false;
1828 : : }
1829 : :
1830 : : bool
1831 : 184633737 : gimple_simplify_283 (gimple_match_op *res_op, gimple_seq *seq,
1832 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1833 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
1834 : : const enum tree_code ARG_UNUSED (neeq))
1835 : : {
1836 : 184633737 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1837 : 330098875 : if (POINTER_TYPE_P (TREE_TYPE (captures[0]))
1838 : 184745914 : && ptrs_compare_unequal (captures[0], captures[1])
1839 : : )
1840 : : {
1841 : 2602 : gimple_seq *lseq = seq;
1842 : 2602 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail612;
1843 : 2602 : {
1844 : 2602 : tree tem;
1845 : 2602 : tem = constant_boolean_node (neeq != EQ_EXPR, type);
1846 : 2602 : res_op->set_value (tem);
1847 : 2602 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 416, __FILE__, __LINE__, true);
1848 : 2602 : return true;
1849 : : }
1850 : 0 : next_after_fail612:;
1851 : : }
1852 : : return false;
1853 : : }
1854 : :
1855 : : bool
1856 : 1222626 : gimple_simplify_287 (gimple_match_op *res_op, gimple_seq *seq,
1857 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1858 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
1859 : : const enum tree_code ARG_UNUSED (op),
1860 : : const enum tree_code ARG_UNUSED (rop),
1861 : : const enum tree_code ARG_UNUSED (cmp))
1862 : : {
1863 : 1222626 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1864 : 2445252 : if (!TREE_OVERFLOW (captures[2]) && !TREE_OVERFLOW (captures[3])
1865 : 1222626 : && !TYPE_OVERFLOW_SANITIZED (TREE_TYPE (captures[1]))
1866 : 1221697 : && !TYPE_OVERFLOW_TRAPS (TREE_TYPE (captures[1]))
1867 : 2444220 : && !TYPE_SATURATING (TREE_TYPE (captures[1]))
1868 : : )
1869 : : {
1870 : 1221594 : {
1871 : 1221594 : tree res = int_const_binop (rop, captures[3], captures[2]);
1872 : 1221594 : if (TREE_OVERFLOW (res)
1873 : 1221594 : && TYPE_OVERFLOW_UNDEFINED (TREE_TYPE (captures[1]))
1874 : : )
1875 : : {
1876 : 0 : gimple_seq *lseq = seq;
1877 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail620;
1878 : 0 : {
1879 : 0 : tree tem;
1880 : 0 : tem = constant_boolean_node (cmp == NE_EXPR, type);
1881 : 0 : res_op->set_value (tem);
1882 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 424, __FILE__, __LINE__, true);
1883 : 0 : return true;
1884 : : }
1885 : 0 : next_after_fail620:;
1886 : : }
1887 : : else
1888 : : {
1889 : 1221594 : if (single_use (captures[0])
1890 : : )
1891 : : {
1892 : 62738 : gimple_seq *lseq = seq;
1893 : 62738 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail621;
1894 : 62738 : {
1895 : 62738 : res_op->set_op (cmp, type, 2);
1896 : 62738 : res_op->ops[0] = captures[1];
1897 : 62738 : res_op->ops[1] = TREE_OVERFLOW (res)
1898 : 62738 : ? drop_tree_overflow (res) : res;
1899 : 62738 : res_op->resimplify (lseq, valueize);
1900 : 62738 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 425, __FILE__, __LINE__, true);
1901 : 62738 : return true;
1902 : : }
1903 : 0 : next_after_fail621:;
1904 : : }
1905 : : }
1906 : : }
1907 : : }
1908 : : return false;
1909 : : }
1910 : :
1911 : : bool
1912 : 0 : gimple_simplify_289 (gimple_match_op *res_op, gimple_seq *seq,
1913 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1914 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
1915 : : const enum tree_code ARG_UNUSED (op),
1916 : : const enum tree_code ARG_UNUSED (cmp))
1917 : : {
1918 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1919 : 0 : if (integer_zerop (captures[3]) && single_use (captures[0])
1920 : : )
1921 : : {
1922 : 0 : {
1923 : 0 : tree type0 = TREE_TYPE (captures[1]);
1924 : 0 : tree stype = signed_type_for (TREE_TYPE (captures[1]));
1925 : 0 : if (integer_zerop (captures[2]))
1926 : : stype = NULL_TREE;
1927 : 0 : if (stype
1928 : : )
1929 : : {
1930 : 0 : gimple_seq *lseq = seq;
1931 : 0 : if (lseq
1932 : 0 : && (!single_use (captures[0])))
1933 : 0 : lseq = NULL;
1934 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail624;
1935 : 0 : {
1936 : 0 : res_op->set_op (cmp, type, 2);
1937 : 0 : {
1938 : 0 : tree _o1[1], _r1;
1939 : 0 : _o1[0] = captures[1];
1940 : 0 : if (stype != TREE_TYPE (_o1[0])
1941 : 0 : && !useless_type_conversion_p (stype, TREE_TYPE (_o1[0])))
1942 : : {
1943 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, stype, _o1[0]);
1944 : 0 : tem_op.resimplify (lseq, valueize);
1945 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
1946 : 0 : if (!_r1) goto next_after_fail624;
1947 : : }
1948 : : else
1949 : : _r1 = _o1[0];
1950 : 0 : res_op->ops[0] = _r1;
1951 : : }
1952 : 0 : res_op->ops[1] = build_zero_cst (stype);
1953 : 0 : res_op->resimplify (lseq, valueize);
1954 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 428, __FILE__, __LINE__, true);
1955 : 0 : return true;
1956 : : }
1957 : : next_after_fail624:;
1958 : : }
1959 : : }
1960 : : }
1961 : : else
1962 : : {
1963 : 0 : {
1964 : 0 : bool ok = true;
1965 : 0 : tree type0 = TREE_TYPE (captures[1]);
1966 : 0 : if (wi::to_widest (captures[2]) == TYPE_PRECISION (type0) - 1)
1967 : : ok = false;
1968 : 0 : if (ok && wi::to_wide (captures[3]) == (TYPE_PRECISION (type0) - 1)
1969 : : )
1970 : : {
1971 : 0 : gimple_seq *lseq = seq;
1972 : 0 : if (lseq
1973 : 0 : && (!single_use (captures[0])))
1974 : 0 : lseq = NULL;
1975 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail625;
1976 : 0 : {
1977 : 0 : res_op->set_op (op, type, 2);
1978 : 0 : res_op->ops[0] = captures[1];
1979 : 0 : res_op->ops[1] = build_one_cst (type0);
1980 : 0 : res_op->resimplify (lseq, valueize);
1981 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 429, __FILE__, __LINE__, true);
1982 : 0 : return true;
1983 : : }
1984 : 0 : next_after_fail625:;
1985 : : }
1986 : : }
1987 : : }
1988 : : return false;
1989 : : }
1990 : :
1991 : : bool
1992 : 6 : gimple_simplify_300 (gimple_match_op *res_op, gimple_seq *seq,
1993 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
1994 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
1995 : : const combined_fn ARG_UNUSED (COPYSIGN_ALL))
1996 : : {
1997 : 6 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
1998 : 6 : gimple_seq *lseq = seq;
1999 : 6 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail642;
2000 : 6 : {
2001 : 6 : tree tem;
2002 : 6 : tem = captures[0];
2003 : 6 : res_op->set_value (tem);
2004 : 6 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 446, __FILE__, __LINE__, true);
2005 : : return true;
2006 : : }
2007 : 0 : next_after_fail642:;
2008 : 0 : return false;
2009 : : }
2010 : :
2011 : : bool
2012 : 20613 : gimple_simplify_305 (gimple_match_op *res_op, gimple_seq *seq,
2013 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
2014 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
2015 : : const enum tree_code ARG_UNUSED (div))
2016 : : {
2017 : 20613 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
2018 : 20613 : if (!integer_zerop (captures[1])
2019 : : )
2020 : : {
2021 : 19472 : gimple_seq *lseq = seq;
2022 : 19472 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail649;
2023 : 19472 : {
2024 : 19472 : tree tem;
2025 : 19472 : tem = captures[0];
2026 : 19472 : res_op->set_value (tem);
2027 : 19472 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 451, __FILE__, __LINE__, true);
2028 : 19472 : return true;
2029 : : }
2030 : 0 : next_after_fail649:;
2031 : : }
2032 : : return false;
2033 : : }
2034 : :
2035 : : bool
2036 : 15576 : gimple_simplify_311 (gimple_match_op *res_op, gimple_seq *seq,
2037 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
2038 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
2039 : : const enum tree_code ARG_UNUSED (div))
2040 : : {
2041 : 15576 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
2042 : 15576 : {
2043 : 15576 : wi::overflow_type overflow;
2044 : 15576 : wide_int mul = wi::mul (wi::to_wide (captures[2]), wi::to_wide (captures[3]),
2045 : 31152 : TYPE_SIGN (type), &overflow);
2046 : 15576 : if (div == EXACT_DIV_EXPR
2047 : 15576 : || optimize_successive_divisions_p (captures[3], captures[0])
2048 : : )
2049 : : {
2050 : 2957 : if (!overflow
2051 : : )
2052 : : {
2053 : 2863 : gimple_seq *lseq = seq;
2054 : 2863 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail655;
2055 : 2863 : {
2056 : 2863 : res_op->set_op (div, type, 2);
2057 : 2863 : res_op->ops[0] = captures[1];
2058 : 2863 : res_op->ops[1] = wide_int_to_tree (type, mul);
2059 : 2863 : res_op->resimplify (lseq, valueize);
2060 : 2863 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 457, __FILE__, __LINE__, true);
2061 : 2863 : return true;
2062 : : }
2063 : 0 : next_after_fail655:;
2064 : : }
2065 : : else
2066 : : {
2067 : 94 : if (TYPE_UNSIGNED (type)
2068 : 182 : || mul != wi::min_value (TYPE_PRECISION (type), SIGNED)
2069 : : )
2070 : : {
2071 : 9 : gimple_seq *lseq = seq;
2072 : 9 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail656;
2073 : 9 : {
2074 : 9 : tree tem;
2075 : 9 : tem = build_zero_cst (type);
2076 : 9 : res_op->set_value (tem);
2077 : 9 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 458, __FILE__, __LINE__, true);
2078 : 9 : return true;
2079 : : }
2080 : 0 : next_after_fail656:;
2081 : : }
2082 : : }
2083 : : }
2084 : 2872 : }
2085 : 12704 : return false;
2086 : : }
2087 : :
2088 : : bool
2089 : 18575 : gimple_simplify_318 (gimple_match_op *res_op, gimple_seq *seq,
2090 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
2091 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
2092 : : const enum tree_code ARG_UNUSED (floor_divmod),
2093 : : const enum tree_code ARG_UNUSED (trunc_divmod))
2094 : : {
2095 : 18575 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
2096 : 0 : if ((INTEGRAL_TYPE_P (type) || VECTOR_INTEGER_TYPE_P (type))
2097 : 18575 : && TYPE_UNSIGNED (type)
2098 : : )
2099 : : {
2100 : 0 : gimple_seq *lseq = seq;
2101 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail666;
2102 : 0 : {
2103 : 0 : res_op->set_op (trunc_divmod, type, 2);
2104 : 0 : res_op->ops[0] = captures[0];
2105 : 0 : res_op->ops[1] = captures[1];
2106 : 0 : res_op->resimplify (lseq, valueize);
2107 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 468, __FILE__, __LINE__, true);
2108 : 0 : return true;
2109 : : }
2110 : 0 : next_after_fail666:;
2111 : : }
2112 : : return false;
2113 : : }
2114 : :
2115 : : bool
2116 : 0 : gimple_simplify_328 (gimple_match_op *res_op, gimple_seq *seq,
2117 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
2118 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
2119 : : const combined_fn ARG_UNUSED (SIN),
2120 : : const combined_fn ARG_UNUSED (COS),
2121 : : const combined_fn ARG_UNUSED (TAN))
2122 : : {
2123 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
2124 : 0 : if (flag_unsafe_math_optimizations && canonicalize_math_p ()
2125 : : )
2126 : : {
2127 : 0 : gimple_seq *lseq = seq;
2128 : 0 : if (lseq
2129 : 0 : && (!single_use (captures[0])
2130 : 0 : || !single_use (captures[2])))
2131 : 0 : lseq = NULL;
2132 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail678;
2133 : 0 : {
2134 : 0 : res_op->set_op (TAN, type, 1);
2135 : 0 : res_op->ops[0] = captures[1];
2136 : 0 : res_op->resimplify (lseq, valueize);
2137 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 480, __FILE__, __LINE__, true);
2138 : 0 : return true;
2139 : : }
2140 : 0 : next_after_fail678:;
2141 : : }
2142 : : return false;
2143 : : }
2144 : :
2145 : : bool
2146 : 233 : gimple_simplify_335 (gimple_match_op *res_op, gimple_seq *seq,
2147 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
2148 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
2149 : : const combined_fn ARG_UNUSED (POW))
2150 : : {
2151 : 233 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
2152 : 233 : if (flag_unsafe_math_optimizations && canonicalize_math_p ()
2153 : : )
2154 : : {
2155 : 0 : gimple_seq *lseq = seq;
2156 : 0 : if (lseq
2157 : 0 : && (!single_use (captures[1])))
2158 : 0 : lseq = NULL;
2159 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail685;
2160 : 0 : {
2161 : 0 : res_op->set_op (MULT_EXPR, type, 2);
2162 : 0 : res_op->ops[0] = captures[0];
2163 : 0 : {
2164 : 0 : tree _o1[2], _r1;
2165 : 0 : _o1[0] = captures[2];
2166 : 0 : {
2167 : 0 : tree _o2[1], _r2;
2168 : 0 : _o2[0] = captures[3];
2169 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
2170 : 0 : tem_op.resimplify (lseq, valueize);
2171 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
2172 : 0 : if (!_r2) goto next_after_fail685;
2173 : 0 : _o1[1] = _r2;
2174 : : }
2175 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), POW, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
2176 : 0 : tem_op.resimplify (lseq, valueize);
2177 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
2178 : 0 : if (!_r1) goto next_after_fail685;
2179 : 0 : res_op->ops[1] = _r1;
2180 : : }
2181 : 0 : res_op->resimplify (lseq, valueize);
2182 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 487, __FILE__, __LINE__, true);
2183 : 0 : return true;
2184 : : }
2185 : : next_after_fail685:;
2186 : : }
2187 : : return false;
2188 : : }
2189 : :
2190 : : bool
2191 : 2538 : gimple_simplify_344 (gimple_match_op *res_op, gimple_seq *seq,
2192 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
2193 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
2194 : : const enum tree_code ARG_UNUSED (cmp),
2195 : : const enum tree_code ARG_UNUSED (bitop))
2196 : : {
2197 : 2538 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
2198 : 2538 : if (INTEGRAL_TYPE_P (TREE_TYPE (captures[0]))
2199 : : )
2200 : : {
2201 : 2538 : if (bitop == BIT_AND_EXPR || tree_expr_nonnegative_p (captures[1])
2202 : : )
2203 : : {
2204 : 2512 : gimple_seq *lseq = seq;
2205 : 2512 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail696;
2206 : 2512 : {
2207 : 2512 : tree tem;
2208 : 2512 : tem = constant_boolean_node (cmp == GE_EXPR || cmp == LE_EXPR, type);
2209 : 2512 : res_op->set_value (tem);
2210 : 2512 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 498, __FILE__, __LINE__, true);
2211 : 2512 : return true;
2212 : : }
2213 : 0 : next_after_fail696:;
2214 : : }
2215 : : else
2216 : : {
2217 : 26 : if (TREE_CODE (captures[1]) == INTEGER_CST && wi::neg_p (wi::to_wide (captures[1]))
2218 : : )
2219 : : {
2220 : 2 : gimple_seq *lseq = seq;
2221 : 2 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail697;
2222 : 2 : {
2223 : 2 : tree tem;
2224 : 2 : tem = constant_boolean_node (cmp == LT_EXPR, type);
2225 : 2 : res_op->set_value (tem);
2226 : 2 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 499, __FILE__, __LINE__, true);
2227 : 2 : return true;
2228 : : }
2229 : 0 : next_after_fail697:;
2230 : : }
2231 : : }
2232 : : }
2233 : : return false;
2234 : : }
2235 : :
2236 : : bool
2237 : 321 : gimple_simplify_355 (gimple_match_op *res_op, gimple_seq *seq,
2238 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
2239 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
2240 : : const enum tree_code ARG_UNUSED (cmp))
2241 : : {
2242 : 321 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
2243 : 642 : if (ANY_INTEGRAL_TYPE_P (TREE_TYPE (captures[0]))
2244 : 642 : && TYPE_UNSIGNED (TREE_TYPE (captures[0]))
2245 : : )
2246 : : {
2247 : 4 : gimple_seq *lseq = seq;
2248 : 4 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail740;
2249 : 4 : {
2250 : 4 : res_op->set_op (cmp, type, 2);
2251 : 4 : res_op->ops[0] = captures[1];
2252 : 4 : res_op->ops[1] = captures[0];
2253 : 4 : res_op->resimplify (lseq, valueize);
2254 : 4 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 525, __FILE__, __LINE__, true);
2255 : 4 : return true;
2256 : : }
2257 : 0 : next_after_fail740:;
2258 : : }
2259 : : return false;
2260 : : }
2261 : :
2262 : : bool
2263 : 903 : gimple_simplify_358 (gimple_match_op *res_op, gimple_seq *seq,
2264 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
2265 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
2266 : : const enum tree_code ARG_UNUSED (cmp),
2267 : : const enum tree_code ARG_UNUSED (out))
2268 : : {
2269 : 903 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
2270 : 903 : if (TYPE_UNSIGNED (TREE_TYPE (captures[2])) && !VECTOR_TYPE_P (TREE_TYPE (captures[2]))
2271 : : )
2272 : : {
2273 : 879 : {
2274 : 879 : tree t = TREE_TYPE (captures[2]), cpx = build_complex_type (t);
2275 : 879 : gimple_seq *lseq = seq;
2276 : 879 : if (lseq
2277 : 303 : && (!single_use (captures[0])))
2278 : 849 : lseq = NULL;
2279 : 879 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail743;
2280 : 879 : {
2281 : 879 : res_op->set_op (out, type, 2);
2282 : 879 : {
2283 : 879 : tree _o1[1], _r1;
2284 : 879 : {
2285 : 879 : tree _o2[2], _r2;
2286 : 879 : _o2[0] = captures[2];
2287 : 879 : _o2[1] = captures[1];
2288 : 879 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_MUL_OVERFLOW, cpx, _o2[0], _o2[1]);
2289 : 879 : tem_op.resimplify (lseq, valueize);
2290 : 879 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
2291 : 879 : if (!_r2) goto next_after_fail743;
2292 : 30 : _o1[0] = _r2;
2293 : : }
2294 : 30 : gimple_match_op tem_op (res_op->cond.any_else (), IMAGPART_EXPR, TREE_TYPE (TREE_TYPE (_o1[0])), _o1[0]);
2295 : 30 : tem_op.resimplify (lseq, valueize);
2296 : 30 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
2297 : 30 : if (!_r1) goto next_after_fail743;
2298 : 30 : res_op->ops[0] = _r1;
2299 : : }
2300 : 30 : res_op->ops[1] = build_zero_cst (t);
2301 : 30 : res_op->resimplify (lseq, valueize);
2302 : 30 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 528, __FILE__, __LINE__, true);
2303 : 30 : return true;
2304 : : }
2305 : : next_after_fail743:;
2306 : : }
2307 : : }
2308 : : return false;
2309 : : }
2310 : :
2311 : : bool
2312 : 523 : gimple_simplify_366 (gimple_match_op *res_op, gimple_seq *seq,
2313 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
2314 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
2315 : : const enum tree_code ARG_UNUSED (cmp))
2316 : : {
2317 : 523 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
2318 : 1046 : if (ANY_INTEGRAL_TYPE_P (TREE_TYPE (captures[0]))
2319 : 1046 : && TYPE_UNSIGNED (TREE_TYPE (captures[0]))
2320 : : )
2321 : : {
2322 : 0 : gimple_seq *lseq = seq;
2323 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail757;
2324 : 0 : {
2325 : 0 : res_op->set_op (cmp, type, 2);
2326 : 0 : res_op->ops[0] = captures[1];
2327 : 0 : res_op->ops[1] = captures[0];
2328 : 0 : res_op->resimplify (lseq, valueize);
2329 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 525, __FILE__, __LINE__, true);
2330 : 0 : return true;
2331 : : }
2332 : 0 : next_after_fail757:;
2333 : : }
2334 : : return false;
2335 : : }
2336 : :
2337 : : bool
2338 : 945 : gimple_simplify_369 (gimple_match_op *res_op, gimple_seq *seq,
2339 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
2340 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
2341 : : const enum tree_code ARG_UNUSED (cmp),
2342 : : const enum tree_code ARG_UNUSED (out))
2343 : : {
2344 : 945 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
2345 : 945 : if (TYPE_UNSIGNED (TREE_TYPE (captures[2])) && !VECTOR_TYPE_P (TREE_TYPE (captures[2]))
2346 : : )
2347 : : {
2348 : 881 : {
2349 : 881 : tree t = TREE_TYPE (captures[2]), cpx = build_complex_type (t);
2350 : 881 : gimple_seq *lseq = seq;
2351 : 881 : if (lseq
2352 : 187 : && (!single_use (captures[0])))
2353 : 879 : lseq = NULL;
2354 : 881 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail760;
2355 : 881 : {
2356 : 881 : res_op->set_op (out, type, 2);
2357 : 881 : {
2358 : 881 : tree _o1[1], _r1;
2359 : 881 : {
2360 : 881 : tree _o2[2], _r2;
2361 : 881 : _o2[0] = captures[2];
2362 : 881 : _o2[1] = captures[1];
2363 : 881 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_MUL_OVERFLOW, cpx, _o2[0], _o2[1]);
2364 : 881 : tem_op.resimplify (lseq, valueize);
2365 : 881 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
2366 : 881 : if (!_r2) goto next_after_fail760;
2367 : 2 : _o1[0] = _r2;
2368 : : }
2369 : 2 : gimple_match_op tem_op (res_op->cond.any_else (), IMAGPART_EXPR, TREE_TYPE (TREE_TYPE (_o1[0])), _o1[0]);
2370 : 2 : tem_op.resimplify (lseq, valueize);
2371 : 2 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
2372 : 2 : if (!_r1) goto next_after_fail760;
2373 : 2 : res_op->ops[0] = _r1;
2374 : : }
2375 : 2 : res_op->ops[1] = build_zero_cst (t);
2376 : 2 : res_op->resimplify (lseq, valueize);
2377 : 2 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 528, __FILE__, __LINE__, true);
2378 : 2 : return true;
2379 : : }
2380 : : next_after_fail760:;
2381 : : }
2382 : : }
2383 : : return false;
2384 : : }
2385 : :
2386 : : bool
2387 : 3203 : gimple_simplify_377 (gimple_match_op *res_op, gimple_seq *seq,
2388 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
2389 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
2390 : : const enum tree_code ARG_UNUSED (shiftrotate))
2391 : : {
2392 : 3203 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
2393 : 3203 : {
2394 : 3203 : tree tem = uniform_vector_p (captures[1]);
2395 : 3203 : if (tem
2396 : : )
2397 : : {
2398 : 485 : gimple_seq *lseq = seq;
2399 : 485 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail772;
2400 : 485 : {
2401 : 485 : res_op->set_op (shiftrotate, type, 2);
2402 : 485 : res_op->ops[0] = captures[0];
2403 : 485 : res_op->ops[1] = tem;
2404 : 485 : res_op->resimplify (lseq, valueize);
2405 : 485 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 553, __FILE__, __LINE__, true);
2406 : 485 : return true;
2407 : : }
2408 : 0 : next_after_fail772:;
2409 : : }
2410 : : }
2411 : : return false;
2412 : : }
2413 : :
2414 : : bool
2415 : 3724 : gimple_simplify_383 (gimple_match_op *res_op, gimple_seq *seq,
2416 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
2417 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
2418 : : {
2419 : 3724 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
2420 : 3724 : if (wi::ltu_p (wi::to_wide (captures[1]), element_precision (type))
2421 : : )
2422 : : {
2423 : 3724 : if (TYPE_UNSIGNED (type)
2424 : : )
2425 : : {
2426 : 568 : gimple_seq *lseq = seq;
2427 : 568 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail781;
2428 : 568 : {
2429 : 568 : res_op->set_op (BIT_AND_EXPR, type, 2);
2430 : 568 : {
2431 : 568 : tree _o1[1], _r1;
2432 : 568 : _o1[0] = captures[0];
2433 : 568 : if (type != TREE_TYPE (_o1[0])
2434 : 568 : && !useless_type_conversion_p (type, TREE_TYPE (_o1[0])))
2435 : : {
2436 : 12 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type, _o1[0]);
2437 : 12 : tem_op.resimplify (lseq, valueize);
2438 : 12 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
2439 : 12 : if (!_r1) goto next_after_fail781;
2440 : : }
2441 : : else
2442 : : _r1 = _o1[0];
2443 : 560 : res_op->ops[0] = _r1;
2444 : : }
2445 : 560 : {
2446 : 560 : tree _o1[2], _r1;
2447 : 560 : _o1[0] = build_minus_one_cst (type);
2448 : 560 : _o1[1] = captures[1];
2449 : 560 : gimple_match_op tem_op (res_op->cond.any_else (), RSHIFT_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
2450 : 560 : tem_op.resimplify (lseq, valueize);
2451 : 560 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
2452 : 560 : if (!_r1) goto next_after_fail781;
2453 : 560 : res_op->ops[1] = _r1;
2454 : : }
2455 : 560 : res_op->resimplify (lseq, valueize);
2456 : 560 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 560, __FILE__, __LINE__, true);
2457 : 560 : return true;
2458 : : }
2459 : : next_after_fail781:;
2460 : : }
2461 : : else
2462 : : {
2463 : 3156 : if (INTEGRAL_TYPE_P (type)
2464 : : )
2465 : : {
2466 : 2996 : {
2467 : 2996 : int width = element_precision (type) - tree_to_uhwi (captures[1]);
2468 : 2996 : tree stype = NULL_TREE;
2469 : 5992 : if (width <= MAX_FIXED_MODE_SIZE)
2470 : 2996 : stype = build_nonstandard_integer_type (width, 0);
2471 : 2996 : if (stype && (width == 1 || type_has_mode_precision_p (stype))
2472 : : )
2473 : : {
2474 : 176 : gimple_seq *lseq = seq;
2475 : 176 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail782;
2476 : 176 : {
2477 : 176 : res_op->set_op (NOP_EXPR, type, 1);
2478 : 176 : {
2479 : 176 : tree _o1[1], _r1;
2480 : 176 : _o1[0] = captures[0];
2481 : 176 : if (stype != TREE_TYPE (_o1[0])
2482 : 176 : && !useless_type_conversion_p (stype, TREE_TYPE (_o1[0])))
2483 : : {
2484 : 176 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, stype, _o1[0]);
2485 : 176 : tem_op.resimplify (lseq, valueize);
2486 : 176 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
2487 : 176 : if (!_r1) goto next_after_fail782;
2488 : : }
2489 : : else
2490 : : _r1 = _o1[0];
2491 : 157 : res_op->ops[0] = _r1;
2492 : : }
2493 : 157 : res_op->resimplify (lseq, valueize);
2494 : 157 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 561, __FILE__, __LINE__, true);
2495 : 157 : return true;
2496 : : }
2497 : : next_after_fail782:;
2498 : : }
2499 : : }
2500 : : }
2501 : : }
2502 : : }
2503 : : return false;
2504 : : }
2505 : :
2506 : : bool
2507 : 368 : gimple_simplify_390 (gimple_match_op *res_op, gimple_seq *seq,
2508 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
2509 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
2510 : : const combined_fn ARG_UNUSED (copysigns))
2511 : : {
2512 : 368 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
2513 : 368 : if (optimize
2514 : 368 : && !HONOR_SNANS (captures[0])
2515 : 368 : && types_match (type, TREE_TYPE (captures[1]))
2516 : 368 : && types_match (type, TREE_TYPE (captures[2]))
2517 : 368 : && TYPE_PRECISION (type) < TYPE_PRECISION (TREE_TYPE (captures[0]))
2518 : 736 : && direct_internal_fn_supported_p (IFN_COPYSIGN,
2519 : : type, OPTIMIZE_FOR_BOTH)
2520 : : )
2521 : : {
2522 : 24 : gimple_seq *lseq = seq;
2523 : 24 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail794;
2524 : 24 : {
2525 : 24 : res_op->set_op (CFN_COPYSIGN, type, 2);
2526 : 24 : res_op->ops[0] = captures[1];
2527 : 24 : res_op->ops[1] = captures[2];
2528 : 24 : res_op->resimplify (lseq, valueize);
2529 : 24 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 573, __FILE__, __LINE__, true);
2530 : 24 : return true;
2531 : : }
2532 : 0 : next_after_fail794:;
2533 : : }
2534 : : return false;
2535 : : }
2536 : :
2537 : : bool
2538 : 607094 : gimple_simplify_395 (gimple_match_op *res_op, gimple_seq *seq,
2539 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
2540 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
2541 : : const enum tree_code ARG_UNUSED (op))
2542 : : {
2543 : 607094 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
2544 : 607094 : if (INTEGRAL_TYPE_P (type)
2545 : 408504 : && op != MULT_EXPR
2546 : 408504 : && op != RDIV_EXPR
2547 : 309359 : && INTEGRAL_TYPE_P (TREE_TYPE (captures[2]))
2548 : 309359 : && INTEGRAL_TYPE_P (TREE_TYPE (captures[1]))
2549 : 309359 : && type_has_mode_precision_p (TREE_TYPE (captures[2]))
2550 : 308241 : && type_has_mode_precision_p (TREE_TYPE (captures[4]))
2551 : 304056 : && type_has_mode_precision_p (type)
2552 : 266660 : && TYPE_PRECISION (TREE_TYPE (captures[1])) > TYPE_PRECISION (TREE_TYPE (captures[2]))
2553 : 0 : && types_match (captures[2], type)
2554 : 607094 : && (types_match (captures[2], captures[4])
2555 : 0 : || poly_int_tree_p (captures[3]))
2556 : : )
2557 : : {
2558 : 0 : if (TYPE_OVERFLOW_WRAPS (TREE_TYPE (captures[2]))
2559 : : )
2560 : : {
2561 : 0 : gimple_seq *lseq = seq;
2562 : 0 : if (lseq
2563 : 0 : && (!single_use (captures[0])))
2564 : 0 : lseq = NULL;
2565 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail805;
2566 : 0 : {
2567 : 0 : res_op->set_op (op, type, 2);
2568 : 0 : res_op->ops[0] = captures[2];
2569 : 0 : {
2570 : 0 : tree _o1[1], _r1;
2571 : 0 : _o1[0] = captures[4];
2572 : 0 : if (type != TREE_TYPE (_o1[0])
2573 : 0 : && !useless_type_conversion_p (type, TREE_TYPE (_o1[0])))
2574 : : {
2575 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type, _o1[0]);
2576 : 0 : tem_op.resimplify (lseq, valueize);
2577 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
2578 : 0 : if (!_r1) goto next_after_fail805;
2579 : : }
2580 : : else
2581 : : _r1 = _o1[0];
2582 : 0 : res_op->ops[1] = _r1;
2583 : : }
2584 : 0 : res_op->resimplify (lseq, valueize);
2585 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 576, __FILE__, __LINE__, true);
2586 : 0 : return true;
2587 : : }
2588 : : next_after_fail805:;
2589 : : }
2590 : : else
2591 : : {
2592 : 0 : {
2593 : 0 : tree utype = unsigned_type_for (TREE_TYPE (captures[2]));
2594 : 0 : gimple_seq *lseq = seq;
2595 : 0 : if (lseq
2596 : 0 : && (!single_use (captures[0])))
2597 : 0 : lseq = NULL;
2598 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail806;
2599 : 0 : {
2600 : 0 : res_op->set_op (NOP_EXPR, type, 1);
2601 : 0 : {
2602 : 0 : tree _o1[2], _r1;
2603 : 0 : {
2604 : 0 : tree _o2[1], _r2;
2605 : 0 : _o2[0] = captures[2];
2606 : 0 : if (utype != TREE_TYPE (_o2[0])
2607 : 0 : && !useless_type_conversion_p (utype, TREE_TYPE (_o2[0])))
2608 : : {
2609 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, utype, _o2[0]);
2610 : 0 : tem_op.resimplify (lseq, valueize);
2611 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
2612 : 0 : if (!_r2) goto next_after_fail806;
2613 : : }
2614 : : else
2615 : : _r2 = _o2[0];
2616 : 0 : _o1[0] = _r2;
2617 : : }
2618 : 0 : {
2619 : 0 : tree _o2[1], _r2;
2620 : 0 : _o2[0] = captures[4];
2621 : 0 : if (utype != TREE_TYPE (_o2[0])
2622 : 0 : && !useless_type_conversion_p (utype, TREE_TYPE (_o2[0])))
2623 : : {
2624 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, utype, _o2[0]);
2625 : 0 : tem_op.resimplify (lseq, valueize);
2626 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
2627 : 0 : if (!_r2) goto next_after_fail806;
2628 : : }
2629 : : else
2630 : : _r2 = _o2[0];
2631 : 0 : _o1[1] = _r2;
2632 : : }
2633 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), op, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
2634 : 0 : tem_op.resimplify (lseq, valueize);
2635 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
2636 : 0 : if (!_r1) goto next_after_fail806;
2637 : 0 : res_op->ops[0] = _r1;
2638 : : }
2639 : 0 : res_op->resimplify (lseq, valueize);
2640 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 577, __FILE__, __LINE__, true);
2641 : 0 : return true;
2642 : : }
2643 : : next_after_fail806:;
2644 : : }
2645 : : }
2646 : : }
2647 : : else
2648 : : {
2649 : 543906 : if (FLOAT_TYPE_P (type)
2650 : 670302 : && DECIMAL_FLOAT_TYPE_P (TREE_TYPE (captures[0]))
2651 : 63198 : == DECIMAL_FLOAT_TYPE_P (type)
2652 : : )
2653 : : {
2654 : 63198 : {
2655 : 63198 : tree arg0 = strip_float_extensions (captures[2]);
2656 : 63198 : tree arg1 = strip_float_extensions (captures[4]);
2657 : 63198 : tree itype = TREE_TYPE (captures[0]);
2658 : 63198 : tree ty1 = TREE_TYPE (arg0);
2659 : 63198 : tree ty2 = TREE_TYPE (arg1);
2660 : 63198 : enum tree_code code = TREE_CODE (itype);
2661 : 10 : if (FLOAT_TYPE_P (ty1)
2662 : 63208 : && FLOAT_TYPE_P (ty2)
2663 : : )
2664 : : {
2665 : 63198 : {
2666 : 63198 : tree newtype = type;
2667 : 63198 : if (TYPE_MODE (ty1) == SDmode
2668 : 63198 : || TYPE_MODE (ty2) == SDmode
2669 : 126396 : || TYPE_MODE (type) == SDmode)
2670 : 0 : newtype = dfloat32_type_node;
2671 : 63198 : if (TYPE_MODE (ty1) == DDmode
2672 : 63198 : || TYPE_MODE (ty2) == DDmode
2673 : 126396 : || TYPE_MODE (type) == DDmode)
2674 : 0 : newtype = dfloat64_type_node;
2675 : 63198 : if (TYPE_MODE (ty1) == TDmode
2676 : 63198 : || TYPE_MODE (ty2) == TDmode
2677 : 126396 : || TYPE_MODE (type) == TDmode)
2678 : 0 : newtype = dfloat128_type_node;
2679 : 63198 : if ((newtype == dfloat32_type_node
2680 : 63198 : || newtype == dfloat64_type_node
2681 : 63198 : || newtype == dfloat128_type_node)
2682 : 0 : && newtype == type
2683 : 63198 : && types_match (newtype, type)
2684 : : )
2685 : : {
2686 : 0 : gimple_seq *lseq = seq;
2687 : 0 : if (lseq
2688 : 0 : && (!single_use (captures[0])))
2689 : 0 : lseq = NULL;
2690 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail807;
2691 : 0 : {
2692 : 0 : res_op->set_op (op, type, 2);
2693 : 0 : {
2694 : 0 : tree _o1[1], _r1;
2695 : 0 : _o1[0] = captures[2];
2696 : 0 : if (newtype != TREE_TYPE (_o1[0])
2697 : 0 : && !useless_type_conversion_p (newtype, TREE_TYPE (_o1[0])))
2698 : : {
2699 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, newtype, _o1[0]);
2700 : 0 : tem_op.resimplify (lseq, valueize);
2701 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
2702 : 0 : if (!_r1) goto next_after_fail807;
2703 : : }
2704 : : else
2705 : : _r1 = _o1[0];
2706 : 0 : res_op->ops[0] = _r1;
2707 : : }
2708 : 0 : {
2709 : 0 : tree _o1[1], _r1;
2710 : 0 : _o1[0] = captures[4];
2711 : 0 : if (newtype != TREE_TYPE (_o1[0])
2712 : 0 : && !useless_type_conversion_p (newtype, TREE_TYPE (_o1[0])))
2713 : : {
2714 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, newtype, _o1[0]);
2715 : 0 : tem_op.resimplify (lseq, valueize);
2716 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
2717 : 0 : if (!_r1) goto next_after_fail807;
2718 : : }
2719 : : else
2720 : : _r1 = _o1[0];
2721 : 0 : res_op->ops[1] = _r1;
2722 : : }
2723 : 0 : res_op->resimplify (lseq, valueize);
2724 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 578, __FILE__, __LINE__, true);
2725 : 0 : return true;
2726 : : }
2727 : : next_after_fail807:;
2728 : : }
2729 : : else
2730 : : {
2731 : 63198 : {
2732 : 63198 : if (element_precision (ty1) > element_precision (newtype))
2733 : 59541 : newtype = ty1;
2734 : 63198 : if (element_precision (ty2) > element_precision (newtype))
2735 : 0 : newtype = ty2;
2736 : 63198 : if (element_precision (newtype) < element_precision (itype)
2737 : 3235 : && (!VECTOR_MODE_P (TYPE_MODE (newtype))
2738 : 0 : || target_supports_op_p (newtype, op, optab_default))
2739 : 3235 : && (flag_unsafe_math_optimizations
2740 : 3235 : || (element_precision (newtype) == element_precision (type)
2741 : 3235 : && real_can_shorten_arithmetic (element_mode (itype),
2742 : : element_mode (type))
2743 : 29 : && !excess_precision_type (newtype)))
2744 : 63212 : && !types_match (itype, newtype)
2745 : : )
2746 : : {
2747 : 14 : gimple_seq *lseq = seq;
2748 : 14 : if (lseq
2749 : 7 : && (!single_use (captures[0])))
2750 : 7 : lseq = NULL;
2751 : 14 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail808;
2752 : 14 : {
2753 : 14 : res_op->set_op (NOP_EXPR, type, 1);
2754 : 14 : {
2755 : 14 : tree _o1[2], _r1;
2756 : 14 : {
2757 : 14 : tree _o2[1], _r2;
2758 : 14 : _o2[0] = captures[2];
2759 : 14 : if (newtype != TREE_TYPE (_o2[0])
2760 : 14 : && !useless_type_conversion_p (newtype, TREE_TYPE (_o2[0])))
2761 : : {
2762 : 14 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, newtype, _o2[0]);
2763 : 14 : tem_op.resimplify (lseq, valueize);
2764 : 14 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
2765 : 14 : if (!_r2) goto next_after_fail808;
2766 : : }
2767 : : else
2768 : : _r2 = _o2[0];
2769 : 14 : _o1[0] = _r2;
2770 : : }
2771 : 14 : {
2772 : 14 : tree _o2[1], _r2;
2773 : 14 : _o2[0] = captures[4];
2774 : 14 : if (newtype != TREE_TYPE (_o2[0])
2775 : 14 : && !useless_type_conversion_p (newtype, TREE_TYPE (_o2[0])))
2776 : : {
2777 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, newtype, _o2[0]);
2778 : 0 : tem_op.resimplify (lseq, valueize);
2779 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
2780 : 0 : if (!_r2) goto next_after_fail808;
2781 : : }
2782 : : else
2783 : : _r2 = _o2[0];
2784 : 14 : _o1[1] = _r2;
2785 : : }
2786 : 14 : gimple_match_op tem_op (res_op->cond.any_else (), op, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
2787 : 14 : tem_op.resimplify (lseq, valueize);
2788 : 14 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
2789 : 14 : if (!_r1) goto next_after_fail808;
2790 : 7 : res_op->ops[0] = _r1;
2791 : : }
2792 : 7 : res_op->resimplify (lseq, valueize);
2793 : 7 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 579, __FILE__, __LINE__, true);
2794 : 7 : return true;
2795 : : }
2796 : : next_after_fail808:;
2797 : : }
2798 : : }
2799 : : }
2800 : : }
2801 : : }
2802 : : }
2803 : : }
2804 : : }
2805 : : return false;
2806 : : }
2807 : :
2808 : : bool
2809 : 10 : gimple_simplify_430 (gimple_match_op *res_op, gimple_seq *seq,
2810 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
2811 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
2812 : : {
2813 : 10 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
2814 : 10 : {
2815 : 10 : bool wascmp;
2816 : 10 : if (bitwise_inverted_equal_p (captures[0], captures[2], wascmp)
2817 : 10 : && (!wascmp || element_precision (type) == 1)
2818 : : )
2819 : : {
2820 : 8 : gimple_seq *lseq = seq;
2821 : 8 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail848;
2822 : 8 : {
2823 : 8 : res_op->set_op (BIT_AND_EXPR, type, 2);
2824 : 8 : res_op->ops[0] = captures[0];
2825 : 8 : res_op->ops[1] = captures[1];
2826 : 8 : res_op->resimplify (lseq, valueize);
2827 : 8 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 614, __FILE__, __LINE__, true);
2828 : 8 : return true;
2829 : : }
2830 : 0 : next_after_fail848:;
2831 : : }
2832 : : }
2833 : 2 : return false;
2834 : : }
2835 : :
2836 : : bool
2837 : 0 : gimple_simplify_435 (gimple_match_op *res_op, gimple_seq *seq,
2838 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
2839 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
2840 : : const enum tree_code ARG_UNUSED (cmp))
2841 : : {
2842 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
2843 : 0 : if (!canonicalize_math_p ()
2844 : : )
2845 : : {
2846 : 0 : if (INTEGRAL_TYPE_P (type)
2847 : 0 : && INTEGRAL_TYPE_P (TREE_TYPE (captures[0]))
2848 : : )
2849 : : {
2850 : 0 : gimple_seq *lseq = seq;
2851 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail853;
2852 : 0 : {
2853 : 0 : res_op->set_op (COND_EXPR, type, 3);
2854 : 0 : res_op->ops[0] = captures[0];
2855 : 0 : res_op->ops[1] = captures[3];
2856 : 0 : res_op->ops[2] = build_zero_cst (type);
2857 : 0 : res_op->resimplify (lseq, valueize);
2858 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 618, __FILE__, __LINE__, true);
2859 : 0 : return true;
2860 : : }
2861 : 0 : next_after_fail853:;
2862 : : }
2863 : : }
2864 : : return false;
2865 : : }
2866 : :
2867 : : bool
2868 : 160059 : gimple_simplify_444 (gimple_match_op *res_op, gimple_seq *seq,
2869 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
2870 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
2871 : : const enum tree_code ARG_UNUSED (code2),
2872 : : const enum tree_code ARG_UNUSED (code1))
2873 : : {
2874 : 160059 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
2875 : 160059 : if ((TREE_CODE (captures[2]) == INTEGER_CST
2876 : 51032 : && TREE_CODE (captures[5]) == INTEGER_CST)
2877 : 166678 : || ((INTEGRAL_TYPE_P (TREE_TYPE (captures[2]))
2878 : 25584 : || POINTER_TYPE_P (TREE_TYPE (captures[2])))
2879 : 110638 : && bitwise_equal_p (captures[2], captures[5]))
2880 : : )
2881 : : {
2882 : 44415 : {
2883 : 44415 : bool one_before = false;
2884 : 44415 : bool one_after = false;
2885 : 44415 : int cmp = 0;
2886 : 44415 : bool allbits = true;
2887 : 44415 : if (TREE_CODE (captures[2]) == INTEGER_CST
2888 : 44413 : && TREE_CODE (captures[5]) == INTEGER_CST)
2889 : : {
2890 : 44413 : allbits = TYPE_PRECISION (TREE_TYPE (captures[2])) <= TYPE_PRECISION (TREE_TYPE (captures[5]));
2891 : 44413 : auto t1 = wi::to_wide (fold_convert (TREE_TYPE (captures[5]), captures[2]));
2892 : 44413 : auto t2 = wi::to_wide (captures[5]);
2893 : 44413 : cmp = wi::cmp (t1, t2, TYPE_SIGN (TREE_TYPE (captures[5])));
2894 : 44413 : if (cmp < 0
2895 : 44413 : && t1 == t2 - 1)
2896 : : one_before = true;
2897 : 44413 : if (cmp > 0
2898 : 44413 : && t1 == t2 + 1)
2899 : : one_after = true;
2900 : : }
2901 : 44415 : bool val;
2902 : 44415 : switch (code2)
2903 : : {
2904 : 0 : case EQ_EXPR: val = (cmp == 0); break;
2905 : 42351 : case NE_EXPR: val = (cmp != 0); break;
2906 : 34 : case LT_EXPR: val = (cmp < 0); break;
2907 : 1358 : case GT_EXPR: val = (cmp > 0); break;
2908 : 476 : case LE_EXPR: val = (cmp <= 0); break;
2909 : 196 : case GE_EXPR: val = (cmp >= 0); break;
2910 : 0 : default: gcc_unreachable ();
2911 : : }
2912 : 44415 : if (code1 == EQ_EXPR && val
2913 : : )
2914 : : {
2915 : 19 : gimple_seq *lseq = seq;
2916 : 19 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail875;
2917 : 19 : {
2918 : 19 : tree tem;
2919 : 19 : tem = captures[0];
2920 : 19 : res_op->set_value (tem);
2921 : 19 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 630, __FILE__, __LINE__, true);
2922 : 19 : return true;
2923 : : }
2924 : 0 : next_after_fail875:;
2925 : : }
2926 : : else
2927 : : {
2928 : 44396 : if (code1 == EQ_EXPR && !val
2929 : : )
2930 : : {
2931 : 2 : gimple_seq *lseq = seq;
2932 : 2 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail876;
2933 : 2 : {
2934 : 2 : tree tem;
2935 : 2 : tem = constant_boolean_node (false, type);
2936 : 2 : res_op->set_value (tem);
2937 : 2 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 631, __FILE__, __LINE__, true);
2938 : 2 : return true;
2939 : : }
2940 : 0 : next_after_fail876:;
2941 : : }
2942 : : else
2943 : : {
2944 : 44394 : if (code1 == NE_EXPR && !val && allbits
2945 : : )
2946 : : {
2947 : 90 : gimple_seq *lseq = seq;
2948 : 90 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail877;
2949 : 90 : {
2950 : 90 : tree tem;
2951 : 90 : tem = captures[3];
2952 : 90 : res_op->set_value (tem);
2953 : 90 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 632, __FILE__, __LINE__, true);
2954 : 90 : return true;
2955 : : }
2956 : 0 : next_after_fail877:;
2957 : 0 : }
2958 : : else
2959 : : {
2960 : 44304 : if (code1 == NE_EXPR
2961 : 44304 : && code2 == GE_EXPR
2962 : 195 : && cmp == 0
2963 : 195 : && allbits
2964 : : )
2965 : : {
2966 : 5 : gimple_seq *lseq = seq;
2967 : 5 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail878;
2968 : 5 : {
2969 : 5 : res_op->set_op (GT_EXPR, type, 2);
2970 : 5 : res_op->ops[0] = captures[4];
2971 : 5 : {
2972 : 5 : tree _o1[1], _r1;
2973 : 5 : _o1[0] = captures[2];
2974 : 5 : if (TREE_TYPE (res_op->ops[0]) != TREE_TYPE (_o1[0])
2975 : 5 : && !useless_type_conversion_p (TREE_TYPE (res_op->ops[0]), TREE_TYPE (_o1[0])))
2976 : : {
2977 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, TREE_TYPE (res_op->ops[0]), _o1[0]);
2978 : 0 : tem_op.resimplify (lseq, valueize);
2979 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
2980 : 0 : if (!_r1) goto next_after_fail878;
2981 : : }
2982 : : else
2983 : : _r1 = _o1[0];
2984 : 5 : res_op->ops[1] = _r1;
2985 : : }
2986 : 5 : res_op->resimplify (lseq, valueize);
2987 : 5 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 633, __FILE__, __LINE__, true);
2988 : 5 : return true;
2989 : : }
2990 : : next_after_fail878:;
2991 : : }
2992 : : else
2993 : : {
2994 : 44299 : if (code1 == NE_EXPR
2995 : 44299 : && code2 == LE_EXPR
2996 : 455 : && cmp == 0
2997 : 455 : && allbits
2998 : : )
2999 : : {
3000 : 10 : gimple_seq *lseq = seq;
3001 : 10 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail879;
3002 : 10 : {
3003 : 10 : res_op->set_op (LT_EXPR, type, 2);
3004 : 10 : res_op->ops[0] = captures[4];
3005 : 10 : {
3006 : 10 : tree _o1[1], _r1;
3007 : 10 : _o1[0] = captures[2];
3008 : 10 : if (TREE_TYPE (res_op->ops[0]) != TREE_TYPE (_o1[0])
3009 : 10 : && !useless_type_conversion_p (TREE_TYPE (res_op->ops[0]), TREE_TYPE (_o1[0])))
3010 : : {
3011 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, TREE_TYPE (res_op->ops[0]), _o1[0]);
3012 : 0 : tem_op.resimplify (lseq, valueize);
3013 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
3014 : 0 : if (!_r1) goto next_after_fail879;
3015 : : }
3016 : : else
3017 : : _r1 = _o1[0];
3018 : 10 : res_op->ops[1] = _r1;
3019 : : }
3020 : 10 : res_op->resimplify (lseq, valueize);
3021 : 10 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 634, __FILE__, __LINE__, true);
3022 : 10 : return true;
3023 : : }
3024 : : next_after_fail879:;
3025 : : }
3026 : : else
3027 : : {
3028 : 44289 : if (code1 == NE_EXPR
3029 : 44289 : && code2 == GT_EXPR
3030 : : && one_after
3031 : 1303 : && allbits
3032 : : )
3033 : : {
3034 : 13 : gimple_seq *lseq = seq;
3035 : 13 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail880;
3036 : 13 : {
3037 : 13 : res_op->set_op (GT_EXPR, type, 2);
3038 : 13 : res_op->ops[0] = captures[4];
3039 : 13 : {
3040 : 13 : tree _o1[1], _r1;
3041 : 13 : _o1[0] = captures[2];
3042 : 13 : if (TREE_TYPE (res_op->ops[0]) != TREE_TYPE (_o1[0])
3043 : 13 : && !useless_type_conversion_p (TREE_TYPE (res_op->ops[0]), TREE_TYPE (_o1[0])))
3044 : : {
3045 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, TREE_TYPE (res_op->ops[0]), _o1[0]);
3046 : 0 : tem_op.resimplify (lseq, valueize);
3047 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
3048 : 0 : if (!_r1) goto next_after_fail880;
3049 : : }
3050 : : else
3051 : : _r1 = _o1[0];
3052 : 13 : res_op->ops[1] = _r1;
3053 : : }
3054 : 13 : res_op->resimplify (lseq, valueize);
3055 : 13 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 635, __FILE__, __LINE__, true);
3056 : 13 : return true;
3057 : : }
3058 : : next_after_fail880:;
3059 : : }
3060 : : else
3061 : : {
3062 : 44276 : if (code1 == NE_EXPR
3063 : 44276 : && code2 == LT_EXPR
3064 : : && one_before
3065 : 0 : && allbits
3066 : : )
3067 : : {
3068 : 0 : gimple_seq *lseq = seq;
3069 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail881;
3070 : 0 : {
3071 : 0 : res_op->set_op (LT_EXPR, type, 2);
3072 : 0 : res_op->ops[0] = captures[4];
3073 : 0 : {
3074 : 0 : tree _o1[1], _r1;
3075 : 0 : _o1[0] = captures[2];
3076 : 0 : if (TREE_TYPE (res_op->ops[0]) != TREE_TYPE (_o1[0])
3077 : 0 : && !useless_type_conversion_p (TREE_TYPE (res_op->ops[0]), TREE_TYPE (_o1[0])))
3078 : : {
3079 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, TREE_TYPE (res_op->ops[0]), _o1[0]);
3080 : 0 : tem_op.resimplify (lseq, valueize);
3081 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
3082 : 0 : if (!_r1) goto next_after_fail881;
3083 : : }
3084 : : else
3085 : : _r1 = _o1[0];
3086 : 0 : res_op->ops[1] = _r1;
3087 : : }
3088 : 0 : res_op->resimplify (lseq, valueize);
3089 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 636, __FILE__, __LINE__, true);
3090 : 0 : return true;
3091 : : }
3092 : : next_after_fail881:;
3093 : : }
3094 : : }
3095 : : }
3096 : : }
3097 : : }
3098 : : }
3099 : : }
3100 : : }
3101 : : }
3102 : : return false;
3103 : : }
3104 : :
3105 : : bool
3106 : 149 : gimple_simplify_468 (gimple_match_op *res_op, gimple_seq *seq,
3107 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3108 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
3109 : : {
3110 : 149 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3111 : 149 : gimple_seq *lseq = seq;
3112 : 149 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail932;
3113 : 149 : {
3114 : 149 : res_op->set_op (MINUS_EXPR, type, 2);
3115 : 149 : res_op->ops[0] = captures[0];
3116 : 149 : res_op->ops[1] = captures[1];
3117 : 149 : res_op->resimplify (lseq, valueize);
3118 : 149 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 657, __FILE__, __LINE__, true);
3119 : : return true;
3120 : : }
3121 : 0 : next_after_fail932:;
3122 : 0 : return false;
3123 : : }
3124 : :
3125 : : bool
3126 : 116 : gimple_simplify_470 (gimple_match_op *res_op, gimple_seq *seq,
3127 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3128 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
3129 : : {
3130 : 116 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3131 : 116 : if (!TYPE_UNSIGNED (TREE_TYPE (captures[2]))
3132 : 126 : && (element_precision (TREE_TYPE (captures[2]))
3133 : 10 : <= element_precision (TREE_TYPE (captures[3]))
3134 : 10 : || !TYPE_UNSIGNED (TREE_TYPE (captures[3])))
3135 : : )
3136 : : {
3137 : 0 : {
3138 : 0 : tree shift_type = TREE_TYPE (captures[2]);
3139 : 0 : gimple_seq *lseq = seq;
3140 : 0 : if (lseq
3141 : 0 : && (!single_use (captures[0])
3142 : 0 : || !single_use (captures[1])))
3143 : 0 : lseq = NULL;
3144 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail934;
3145 : 0 : {
3146 : 0 : res_op->set_op (NOP_EXPR, type, 1);
3147 : 0 : {
3148 : 0 : tree _o1[2], _r1;
3149 : 0 : {
3150 : 0 : tree _o2[1], _r2;
3151 : 0 : _o2[0] = captures[3];
3152 : 0 : if (shift_type != TREE_TYPE (_o2[0])
3153 : 0 : && !useless_type_conversion_p (shift_type, TREE_TYPE (_o2[0])))
3154 : : {
3155 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, shift_type, _o2[0]);
3156 : 0 : tem_op.resimplify (lseq, valueize);
3157 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
3158 : 0 : if (!_r2) goto next_after_fail934;
3159 : : }
3160 : : else
3161 : : _r2 = _o2[0];
3162 : 0 : _o1[0] = _r2;
3163 : : }
3164 : 0 : _o1[1] = captures[4];
3165 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), RSHIFT_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
3166 : 0 : tem_op.resimplify (lseq, valueize);
3167 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
3168 : 0 : if (!_r1) goto next_after_fail934;
3169 : 0 : res_op->ops[0] = _r1;
3170 : : }
3171 : 0 : res_op->resimplify (lseq, valueize);
3172 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 659, __FILE__, __LINE__, true);
3173 : 0 : return true;
3174 : : }
3175 : : next_after_fail934:;
3176 : : }
3177 : : }
3178 : : return false;
3179 : : }
3180 : :
3181 : : bool
3182 : 217197 : gimple_simplify_478 (gimple_match_op *res_op, gimple_seq *seq,
3183 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3184 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
3185 : : const enum tree_code ARG_UNUSED (cmp),
3186 : : const enum tree_code ARG_UNUSED (icmp),
3187 : : const enum tree_code ARG_UNUSED (ncmp))
3188 : : {
3189 : 217197 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3190 : 217197 : if (VECTOR_TYPE_P (type)
3191 : 217197 : || (INTEGRAL_TYPE_P (type) && TYPE_PRECISION (type) == 1)
3192 : : )
3193 : : {
3194 : 217197 : {
3195 : 217197 : enum tree_code ic = invert_tree_comparison
3196 : 217197 : (cmp, HONOR_NANS (captures[0]));
3197 : 217197 : if (ic == icmp
3198 : : )
3199 : : {
3200 : 189690 : gimple_seq *lseq = seq;
3201 : 189690 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail942;
3202 : 189690 : {
3203 : 189690 : res_op->set_op (icmp, type, 2);
3204 : 189690 : res_op->ops[0] = captures[0];
3205 : 189690 : res_op->ops[1] = captures[1];
3206 : 189690 : res_op->resimplify (lseq, valueize);
3207 : 189690 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 665, __FILE__, __LINE__, true);
3208 : 189690 : return true;
3209 : : }
3210 : 0 : next_after_fail942:;
3211 : : }
3212 : : else
3213 : : {
3214 : 27507 : if (ic == ncmp
3215 : : )
3216 : : {
3217 : 70 : gimple_seq *lseq = seq;
3218 : 70 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail943;
3219 : 70 : {
3220 : 70 : res_op->set_op (ncmp, type, 2);
3221 : 70 : res_op->ops[0] = captures[0];
3222 : 70 : res_op->ops[1] = captures[1];
3223 : 70 : res_op->resimplify (lseq, valueize);
3224 : 70 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 666, __FILE__, __LINE__, true);
3225 : 70 : return true;
3226 : : }
3227 : 0 : next_after_fail943:;
3228 : : }
3229 : : }
3230 : : }
3231 : : }
3232 : : return false;
3233 : : }
3234 : :
3235 : : bool
3236 : 149 : gimple_simplify_488 (gimple_match_op *res_op, gimple_seq *seq,
3237 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3238 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
3239 : : const enum tree_code ARG_UNUSED (minmax),
3240 : : const enum tree_code ARG_UNUSED (maxmin))
3241 : : {
3242 : 149 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3243 : 149 : gimple_seq *lseq = seq;
3244 : 149 : if (lseq
3245 : 68 : && (!single_use (captures[0])
3246 : 11 : || !single_use (captures[2])))
3247 : 140 : lseq = NULL;
3248 : 149 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail965;
3249 : 149 : {
3250 : 149 : res_op->set_op (BIT_NOT_EXPR, type, 1);
3251 : 149 : {
3252 : 149 : tree _o1[2], _r1;
3253 : 149 : _o1[0] = captures[1];
3254 : 149 : _o1[1] = captures[3];
3255 : 149 : gimple_match_op tem_op (res_op->cond.any_else (), maxmin, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
3256 : 149 : tem_op.resimplify (lseq, valueize);
3257 : 149 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
3258 : 149 : if (!_r1) goto next_after_fail965;
3259 : 9 : res_op->ops[0] = _r1;
3260 : : }
3261 : 9 : res_op->resimplify (lseq, valueize);
3262 : 9 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 675, __FILE__, __LINE__, true);
3263 : : return true;
3264 : : }
3265 : : next_after_fail965:;
3266 : : return false;
3267 : : }
3268 : :
3269 : : bool
3270 : 1384 : gimple_simplify_497 (gimple_match_op *res_op, gimple_seq *seq,
3271 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3272 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
3273 : : const enum tree_code ARG_UNUSED (op))
3274 : : {
3275 : 1384 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3276 : 1384 : if (INTEGRAL_TYPE_P (type)
3277 : 1381 : && TYPE_PRECISION (type) > 1
3278 : 2765 : && (INTEGRAL_TYPE_P (TREE_TYPE (captures[0])))
3279 : : )
3280 : : {
3281 : 1381 : gimple_seq *lseq = seq;
3282 : 1381 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail974;
3283 : 1381 : {
3284 : 1381 : res_op->set_op (op, type, 2);
3285 : 1381 : {
3286 : 1381 : tree _o1[2], _r1;
3287 : 1381 : {
3288 : 1381 : tree _o2[1], _r2;
3289 : 1381 : _o2[0] = captures[0];
3290 : 1381 : if (type != TREE_TYPE (_o2[0])
3291 : 1381 : && !useless_type_conversion_p (type, TREE_TYPE (_o2[0])))
3292 : : {
3293 : 1225 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type, _o2[0]);
3294 : 1225 : tem_op.resimplify (lseq, valueize);
3295 : 1225 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
3296 : 1225 : if (!_r2) goto next_after_fail974;
3297 : : }
3298 : : else
3299 : : _r2 = _o2[0];
3300 : 1381 : _o1[0] = _r2;
3301 : : }
3302 : 1381 : _o1[1] = captures[2];
3303 : 1381 : gimple_match_op tem_op (res_op->cond.any_else (), MULT_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
3304 : 1381 : tem_op.resimplify (lseq, valueize);
3305 : 1381 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
3306 : 1381 : if (!_r1) goto next_after_fail974;
3307 : 1381 : res_op->ops[0] = _r1;
3308 : : }
3309 : 1381 : res_op->ops[1] = captures[1];
3310 : 1381 : res_op->resimplify (lseq, valueize);
3311 : 1381 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 684, __FILE__, __LINE__, true);
3312 : 1381 : return true;
3313 : : }
3314 : : next_after_fail974:;
3315 : : }
3316 : : return false;
3317 : : }
3318 : :
3319 : : bool
3320 : 19 : gimple_simplify_511 (gimple_match_op *res_op, gimple_seq *seq,
3321 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3322 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
3323 : : const enum tree_code ARG_UNUSED (cmp),
3324 : : const enum tree_code ARG_UNUSED (minmax))
3325 : : {
3326 : 19 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3327 : 19 : {
3328 : 19 : tree_code code = minmax_from_comparison (cmp, captures[0], captures[3], captures[0], captures[1]);
3329 : 19 : if (code == MIN_EXPR
3330 : : )
3331 : : {
3332 : 11 : gimple_seq *lseq = seq;
3333 : 11 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1035;
3334 : 11 : {
3335 : 11 : res_op->set_op (minmax, type, 2);
3336 : 11 : {
3337 : 11 : tree _o1[2], _r1;
3338 : 11 : _o1[0] = captures[0];
3339 : 11 : _o1[1] = captures[3];
3340 : 11 : gimple_match_op tem_op (res_op->cond.any_else (), MIN_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
3341 : 11 : tem_op.resimplify (lseq, valueize);
3342 : 11 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
3343 : 11 : if (!_r1) goto next_after_fail1035;
3344 : 11 : res_op->ops[0] = _r1;
3345 : : }
3346 : 11 : res_op->ops[1] = captures[2];
3347 : 11 : res_op->resimplify (lseq, valueize);
3348 : 11 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 709, __FILE__, __LINE__, true);
3349 : 11 : return true;
3350 : : }
3351 : : next_after_fail1035:;
3352 : : }
3353 : : else
3354 : : {
3355 : 8 : if (code == MAX_EXPR
3356 : : )
3357 : : {
3358 : 8 : gimple_seq *lseq = seq;
3359 : 8 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1036;
3360 : 8 : {
3361 : 8 : res_op->set_op (minmax, type, 2);
3362 : 8 : {
3363 : 8 : tree _o1[2], _r1;
3364 : 8 : _o1[0] = captures[0];
3365 : 8 : _o1[1] = captures[3];
3366 : 8 : gimple_match_op tem_op (res_op->cond.any_else (), MAX_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
3367 : 8 : tem_op.resimplify (lseq, valueize);
3368 : 8 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
3369 : 8 : if (!_r1) goto next_after_fail1036;
3370 : 8 : res_op->ops[0] = _r1;
3371 : : }
3372 : 8 : res_op->ops[1] = captures[2];
3373 : 8 : res_op->resimplify (lseq, valueize);
3374 : 8 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 710, __FILE__, __LINE__, true);
3375 : 8 : return true;
3376 : : }
3377 : : next_after_fail1036:;
3378 : : }
3379 : : }
3380 : : }
3381 : : return false;
3382 : : }
3383 : :
3384 : : bool
3385 : 1 : gimple_simplify_515 (gimple_match_op *res_op, gimple_seq *seq,
3386 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3387 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
3388 : : {
3389 : 1 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3390 : 1 : gimple_seq *lseq = seq;
3391 : 1 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1042;
3392 : 1 : {
3393 : 1 : tree tem;
3394 : 1 : tem = captures[2];
3395 : 1 : res_op->set_value (tem);
3396 : 1 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 716, __FILE__, __LINE__, true);
3397 : : return true;
3398 : : }
3399 : 0 : next_after_fail1042:;
3400 : 0 : return false;
3401 : : }
3402 : :
3403 : : bool
3404 : 1 : gimple_simplify_517 (gimple_match_op *res_op, gimple_seq *seq,
3405 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3406 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
3407 : : const enum tree_code ARG_UNUSED (op))
3408 : : {
3409 : 1 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3410 : 1 : if (ANY_INTEGRAL_TYPE_P (type)
3411 : : )
3412 : : {
3413 : 1 : gimple_seq *lseq = seq;
3414 : 1 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1044;
3415 : 1 : {
3416 : 1 : tree tem;
3417 : 1 : tem = captures[2];
3418 : 1 : res_op->set_value (tem);
3419 : 1 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 718, __FILE__, __LINE__, true);
3420 : 1 : return true;
3421 : : }
3422 : 0 : next_after_fail1044:;
3423 : : }
3424 : : return false;
3425 : : }
3426 : :
3427 : : bool
3428 : 2 : gimple_simplify_520 (gimple_match_op *res_op, gimple_seq *seq,
3429 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3430 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
3431 : : {
3432 : 2 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3433 : 2 : if (wi::to_wide (uniform_integer_cst_p (captures[3])) == 2
3434 : : )
3435 : : {
3436 : 2 : gimple_seq *lseq = seq;
3437 : 2 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1047;
3438 : 2 : {
3439 : 2 : tree tem;
3440 : 2 : tem = captures[2];
3441 : 2 : res_op->set_value (tem);
3442 : 2 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 719, __FILE__, __LINE__, true);
3443 : 2 : return true;
3444 : : }
3445 : 0 : next_after_fail1047:;
3446 : : }
3447 : : return false;
3448 : : }
3449 : :
3450 : : bool
3451 : 0 : gimple_simplify_523 (gimple_match_op *res_op, gimple_seq *seq,
3452 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3453 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
3454 : : {
3455 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3456 : 0 : if (wi::to_wide (uniform_integer_cst_p (captures[3])) == 2
3457 : : )
3458 : : {
3459 : 0 : gimple_seq *lseq = seq;
3460 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1050;
3461 : 0 : {
3462 : 0 : tree tem;
3463 : 0 : tem = captures[2];
3464 : 0 : res_op->set_value (tem);
3465 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 719, __FILE__, __LINE__, true);
3466 : 0 : return true;
3467 : : }
3468 : 0 : next_after_fail1050:;
3469 : : }
3470 : : return false;
3471 : : }
3472 : :
3473 : : bool
3474 : 0 : gimple_simplify_526 (gimple_match_op *res_op, gimple_seq *seq,
3475 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3476 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
3477 : : {
3478 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3479 : 0 : if (wi::eq_p (wi::bit_not (wi::to_wide (captures[1])), wi::to_wide (captures[3]))
3480 : : )
3481 : : {
3482 : 0 : gimple_seq *lseq = seq;
3483 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1053;
3484 : 0 : {
3485 : 0 : tree tem;
3486 : 0 : tem = captures[2];
3487 : 0 : res_op->set_value (tem);
3488 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 721, __FILE__, __LINE__, true);
3489 : 0 : return true;
3490 : : }
3491 : 0 : next_after_fail1053:;
3492 : : }
3493 : : return false;
3494 : : }
3495 : :
3496 : : bool
3497 : 50 : gimple_simplify_531 (gimple_match_op *res_op, gimple_seq *seq,
3498 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3499 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
3500 : : const enum tree_code ARG_UNUSED (cmp))
3501 : : {
3502 : 50 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3503 : 50 : if (!HONOR_SIGNED_ZEROS (type)
3504 : 50 : && bitwise_equal_p (captures[0], captures[2])
3505 : : )
3506 : : {
3507 : 9 : gimple_seq *lseq = seq;
3508 : 9 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1060;
3509 : 9 : {
3510 : 9 : tree tem;
3511 : 9 : tem = captures[1];
3512 : 9 : res_op->set_value (tem);
3513 : 9 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 726, __FILE__, __LINE__, true);
3514 : 9 : return true;
3515 : : }
3516 : 0 : next_after_fail1060:;
3517 : : }
3518 : : return false;
3519 : : }
3520 : :
3521 : : bool
3522 : 1 : gimple_simplify_533 (gimple_match_op *res_op, gimple_seq *seq,
3523 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3524 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
3525 : : const enum tree_code ARG_UNUSED (cmp))
3526 : : {
3527 : 1 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3528 : 1 : gimple_seq *lseq = seq;
3529 : 1 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1062;
3530 : 1 : {
3531 : 1 : tree tem;
3532 : 1 : tem = captures[3];
3533 : 1 : res_op->set_value (tem);
3534 : 1 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 728, __FILE__, __LINE__, true);
3535 : : return true;
3536 : : }
3537 : 0 : next_after_fail1062:;
3538 : 0 : return false;
3539 : : }
3540 : :
3541 : : bool
3542 : 64 : gimple_simplify_537 (gimple_match_op *res_op, gimple_seq *seq,
3543 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3544 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
3545 : : const enum tree_code ARG_UNUSED (cmp))
3546 : : {
3547 : 64 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3548 : 64 : if (!HONOR_SIGNED_ZEROS (type)
3549 : 64 : && bitwise_equal_p (captures[0], captures[1])
3550 : : )
3551 : : {
3552 : 1 : gimple_seq *lseq = seq;
3553 : 1 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1066;
3554 : 1 : {
3555 : 1 : tree tem;
3556 : 1 : tem = captures[1];
3557 : 1 : res_op->set_value (tem);
3558 : 1 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 729, __FILE__, __LINE__, true);
3559 : 1 : return true;
3560 : : }
3561 : 0 : next_after_fail1066:;
3562 : : }
3563 : : return false;
3564 : : }
3565 : :
3566 : : bool
3567 : 0 : gimple_simplify_544 (gimple_match_op *res_op, gimple_seq *seq,
3568 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3569 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
3570 : : const enum tree_code ARG_UNUSED (cmp))
3571 : : {
3572 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3573 : 0 : if (!HONOR_SIGNED_ZEROS (type)
3574 : : )
3575 : : {
3576 : 0 : gimple_seq *lseq = seq;
3577 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1074;
3578 : 0 : {
3579 : 0 : tree tem;
3580 : 0 : tem = captures[0];
3581 : 0 : res_op->set_value (tem);
3582 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 731, __FILE__, __LINE__, true);
3583 : 0 : return true;
3584 : : }
3585 : 0 : next_after_fail1074:;
3586 : : }
3587 : : return false;
3588 : : }
3589 : :
3590 : : bool
3591 : 24 : gimple_simplify_551 (gimple_match_op *res_op, gimple_seq *seq,
3592 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3593 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
3594 : : const enum tree_code ARG_UNUSED (cmp))
3595 : : {
3596 : 24 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3597 : 24 : if (!HONOR_SIGNED_ZEROS (TREE_TYPE(captures[0]))
3598 : 24 : && !TYPE_UNSIGNED (TREE_TYPE(captures[0]))
3599 : 48 : && bitwise_equal_p (captures[0], captures[1])
3600 : : )
3601 : : {
3602 : 48 : if ((ANY_INTEGRAL_TYPE_P (TREE_TYPE (captures[0]))
3603 : 22 : && !TYPE_OVERFLOW_WRAPS (TREE_TYPE (captures[0])))
3604 : 26 : || TYPE_UNSIGNED (type)
3605 : : )
3606 : : {
3607 : 22 : {
3608 : 22 : tree utype = unsigned_type_for (TREE_TYPE(captures[0]));
3609 : 22 : gimple_seq *lseq = seq;
3610 : 22 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1085;
3611 : 22 : {
3612 : 22 : res_op->set_op (NOP_EXPR, type, 1);
3613 : 22 : {
3614 : 22 : tree _o1[1], _r1;
3615 : 22 : {
3616 : 22 : tree _o2[1], _r2;
3617 : 22 : _o2[0] = captures[0];
3618 : 22 : gimple_match_op tem_op (res_op->cond.any_else (), ABSU_EXPR, utype, _o2[0]);
3619 : 22 : tem_op.resimplify (lseq, valueize);
3620 : 22 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
3621 : 22 : if (!_r2) goto next_after_fail1085;
3622 : 22 : _o1[0] = _r2;
3623 : : }
3624 : 22 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o1[0]), _o1[0]);
3625 : 22 : tem_op.resimplify (lseq, valueize);
3626 : 22 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
3627 : 22 : if (!_r1) goto next_after_fail1085;
3628 : 22 : res_op->ops[0] = _r1;
3629 : : }
3630 : 22 : res_op->resimplify (lseq, valueize);
3631 : 22 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 742, __FILE__, __LINE__, true);
3632 : 22 : return true;
3633 : : }
3634 : : next_after_fail1085:;
3635 : : }
3636 : : }
3637 : : else
3638 : : {
3639 : 2 : gimple_seq *lseq = seq;
3640 : 2 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1086;
3641 : 2 : {
3642 : 2 : res_op->set_op (NEGATE_EXPR, type, 1);
3643 : 2 : {
3644 : 2 : tree _o1[1], _r1;
3645 : 2 : _o1[0] = captures[0];
3646 : 2 : gimple_match_op tem_op (res_op->cond.any_else (), ABS_EXPR, TREE_TYPE (_o1[0]), _o1[0]);
3647 : 2 : tem_op.resimplify (lseq, valueize);
3648 : 2 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
3649 : 2 : if (!_r1) goto next_after_fail1086;
3650 : 2 : res_op->ops[0] = _r1;
3651 : : }
3652 : 2 : res_op->resimplify (lseq, valueize);
3653 : 2 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 743, __FILE__, __LINE__, true);
3654 : 2 : return true;
3655 : : }
3656 : : next_after_fail1086:;
3657 : : }
3658 : : }
3659 : : return false;
3660 : : }
3661 : :
3662 : : bool
3663 : 3 : gimple_simplify_559 (gimple_match_op *res_op, gimple_seq *seq,
3664 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3665 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
3666 : : const combined_fn ARG_UNUSED (func))
3667 : : {
3668 : 3 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3669 : 3 : if (wi::to_widest (captures[4]) == TYPE_PRECISION (TREE_TYPE (captures[3])) - 1
3670 : : )
3671 : : {
3672 : 3 : gimple_seq *lseq = seq;
3673 : 3 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1099;
3674 : 3 : {
3675 : 3 : tree tem;
3676 : 3 : tem = captures[2];
3677 : 3 : res_op->set_value (tem);
3678 : 3 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 751, __FILE__, __LINE__, true);
3679 : 3 : return true;
3680 : : }
3681 : 0 : next_after_fail1099:;
3682 : : }
3683 : : return false;
3684 : : }
3685 : :
3686 : : bool
3687 : 0 : gimple_simplify_566 (gimple_match_op *res_op, gimple_seq *seq,
3688 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3689 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
3690 : : {
3691 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3692 : 0 : {
3693 : 0 : int val;
3694 : 0 : internal_fn ifn = IFN_LAST;
3695 : 0 : if (TREE_CODE (TREE_TYPE (captures[2])) == BITINT_TYPE)
3696 : : ifn = IFN_CTZ;
3697 : 0 : else if (direct_internal_fn_supported_p (IFN_CTZ, TREE_TYPE (captures[2]),
3698 : : OPTIMIZE_FOR_BOTH))
3699 : : ifn = IFN_CTZ;
3700 : : if (ifn == IFN_CTZ
3701 : : )
3702 : : {
3703 : 0 : gimple_seq *lseq = seq;
3704 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1106;
3705 : 0 : {
3706 : 0 : res_op->set_op (CFN_CTZ, type, 2);
3707 : 0 : res_op->ops[0] = captures[2];
3708 : 0 : res_op->ops[1] = captures[3];
3709 : 0 : res_op->resimplify (lseq, valueize);
3710 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 755, __FILE__, __LINE__, true);
3711 : 0 : return true;
3712 : : }
3713 : 0 : next_after_fail1106:;
3714 : : }
3715 : : }
3716 : : return false;
3717 : : }
3718 : :
3719 : : bool
3720 : 16 : gimple_simplify_574 (gimple_match_op *res_op, gimple_seq *seq,
3721 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3722 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
3723 : : const enum tree_code ARG_UNUSED (cmp))
3724 : : {
3725 : 16 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3726 : 32 : if (VECTOR_INTEGER_TYPE_P (TREE_TYPE (captures[3]))
3727 : 16 : && VECTOR_INTEGER_TYPE_P (TREE_TYPE (captures[0]))
3728 : 16 : && !TYPE_UNSIGNED (TREE_TYPE (captures[0]))
3729 : 16 : && VECTOR_TYPE_P (TREE_TYPE (captures[1]))
3730 : 16 : && VECTOR_TYPE_P (type)
3731 : 16 : && tree_int_cst_le (TYPE_SIZE (TREE_TYPE (type)),
3732 : 16 : TYPE_SIZE (TREE_TYPE (TREE_TYPE (captures[1]))))
3733 : 32 : && TYPE_SIZE (type) == TYPE_SIZE (TREE_TYPE (captures[1]))
3734 : : )
3735 : : {
3736 : 16 : {
3737 : 16 : tree vtype = TREE_TYPE (captures[1]);
3738 : 16 : gimple_seq *lseq = seq;
3739 : 16 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1116;
3740 : 16 : {
3741 : 16 : res_op->set_op (VIEW_CONVERT_EXPR, type, 1);
3742 : 16 : {
3743 : 16 : tree _o1[3], _r1;
3744 : 16 : _o1[0] = captures[2];
3745 : 16 : {
3746 : 16 : tree _o2[1], _r2;
3747 : 16 : _o2[0] = captures[5];
3748 : 16 : gimple_match_op tem_op (res_op->cond.any_else (), VIEW_CONVERT_EXPR, vtype, _o2[0]);
3749 : 16 : tem_op.resimplify (lseq, valueize);
3750 : 16 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
3751 : 16 : if (!_r2) goto next_after_fail1116;
3752 : 16 : _o1[1] = _r2;
3753 : : }
3754 : 16 : {
3755 : 16 : tree _o2[1], _r2;
3756 : 16 : _o2[0] = captures[6];
3757 : 16 : gimple_match_op tem_op (res_op->cond.any_else (), VIEW_CONVERT_EXPR, vtype, _o2[0]);
3758 : 16 : tem_op.resimplify (lseq, valueize);
3759 : 16 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
3760 : 16 : if (!_r2) goto next_after_fail1116;
3761 : 16 : _o1[2] = _r2;
3762 : : }
3763 : 16 : gimple_match_op tem_op (res_op->cond.any_else (), VEC_COND_EXPR, TREE_TYPE (_o1[1]), _o1[0], _o1[1], _o1[2]);
3764 : 16 : tem_op.resimplify (lseq, valueize);
3765 : 16 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
3766 : 16 : if (!_r1) goto next_after_fail1116;
3767 : 12 : res_op->ops[0] = _r1;
3768 : : }
3769 : 12 : res_op->resimplify (lseq, valueize);
3770 : 12 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 764, __FILE__, __LINE__, true);
3771 : 12 : return true;
3772 : : }
3773 : : next_after_fail1116:;
3774 : : }
3775 : : }
3776 : : return false;
3777 : : }
3778 : :
3779 : : bool
3780 : 0 : gimple_simplify_589 (gimple_match_op *res_op, gimple_seq *seq,
3781 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3782 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
3783 : : const combined_fn ARG_UNUSED (cond_len_op))
3784 : : {
3785 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3786 : 0 : {
3787 : 0 : tree op_type = TREE_TYPE (captures[5]);
3788 : 0 : if (inverse_conditions_p (captures[0], captures[2])
3789 : 0 : && element_precision (type) == element_precision (op_type)
3790 : : )
3791 : : {
3792 : 0 : gimple_seq *lseq = seq;
3793 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1131;
3794 : 0 : {
3795 : 0 : res_op->set_op (VIEW_CONVERT_EXPR, type, 1);
3796 : 0 : {
3797 : 0 : tree _o1[6], _r1;
3798 : 0 : _o1[0] = captures[2];
3799 : 0 : _o1[1] = captures[3];
3800 : 0 : _o1[2] = captures[4];
3801 : 0 : {
3802 : 0 : tree _o2[1], _r2;
3803 : 0 : _o2[0] = captures[1];
3804 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), VIEW_CONVERT_EXPR, op_type, _o2[0]);
3805 : 0 : tem_op.resimplify (lseq, valueize);
3806 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
3807 : 0 : if (!_r2) goto next_after_fail1131;
3808 : 0 : _o1[3] = _r2;
3809 : : }
3810 : 0 : _o1[4] = captures[6];
3811 : 0 : _o1[5] = captures[7];
3812 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), cond_len_op, TREE_TYPE (_o1[1]), _o1[0], _o1[1], _o1[2], _o1[3], _o1[4], _o1[5]);
3813 : 0 : tem_op.resimplify (lseq, valueize);
3814 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
3815 : 0 : if (!_r1) goto next_after_fail1131;
3816 : 0 : res_op->ops[0] = _r1;
3817 : : }
3818 : 0 : res_op->resimplify (lseq, valueize);
3819 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 774, __FILE__, __LINE__, true);
3820 : 0 : return true;
3821 : : }
3822 : : next_after_fail1131:;
3823 : : }
3824 : : }
3825 : : return false;
3826 : : }
3827 : :
3828 : : bool
3829 : 12 : gimple_simplify_600 (gimple_match_op *res_op, gimple_seq *seq,
3830 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3831 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
3832 : : const combined_fn ARG_UNUSED (tans),
3833 : : const combined_fn ARG_UNUSED (atans))
3834 : : {
3835 : 12 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3836 : 12 : if (flag_unsafe_math_optimizations
3837 : : )
3838 : : {
3839 : 12 : gimple_seq *lseq = seq;
3840 : 12 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1142;
3841 : 12 : {
3842 : 12 : tree tem;
3843 : 12 : tem = captures[0];
3844 : 12 : res_op->set_value (tem);
3845 : 12 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 785, __FILE__, __LINE__, true);
3846 : 12 : return true;
3847 : : }
3848 : 0 : next_after_fail1142:;
3849 : : }
3850 : : return false;
3851 : : }
3852 : :
3853 : : bool
3854 : 246 : gimple_simplify_606 (gimple_match_op *res_op, gimple_seq *seq,
3855 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3856 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
3857 : : const combined_fn ARG_UNUSED (froms),
3858 : : const combined_fn ARG_UNUSED (tos))
3859 : : {
3860 : 246 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3861 : 246 : if (optimize && canonicalize_math_p ()
3862 : : )
3863 : : {
3864 : 246 : gimple_seq *lseq = seq;
3865 : 246 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1148;
3866 : 246 : {
3867 : 246 : res_op->set_op (NOP_EXPR, type, 1);
3868 : 246 : {
3869 : 246 : tree _o1[1], _r1;
3870 : 246 : _o1[0] = captures[0];
3871 : 246 : gimple_match_op tem_op (res_op->cond.any_else (), tos, TREE_TYPE (_o1[0]), _o1[0]);
3872 : 246 : tem_op.resimplify (lseq, valueize);
3873 : 246 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
3874 : 246 : if (!_r1) goto next_after_fail1148;
3875 : 123 : res_op->ops[0] = _r1;
3876 : : }
3877 : 123 : res_op->resimplify (lseq, valueize);
3878 : 123 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 791, __FILE__, __LINE__, true);
3879 : 123 : return true;
3880 : : }
3881 : : next_after_fail1148:;
3882 : : }
3883 : : return false;
3884 : : }
3885 : :
3886 : : bool
3887 : 2568 : gimple_simplify_615 (gimple_match_op *res_op, gimple_seq *seq,
3888 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3889 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
3890 : : const combined_fn ARG_UNUSED (ifn),
3891 : : const combined_fn ARG_UNUSED (lfn),
3892 : : const combined_fn ARG_UNUSED (llfn))
3893 : : {
3894 : 2568 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3895 : 2568 : if (canonicalize_math_p ()
3896 : : )
3897 : : {
3898 : 2184 : if (TYPE_PRECISION (long_long_integer_type_node)
3899 : 2184 : == TYPE_PRECISION (long_integer_type_node)
3900 : : )
3901 : : {
3902 : 2184 : gimple_seq *lseq = seq;
3903 : 2184 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1157;
3904 : 2184 : {
3905 : 2184 : res_op->set_op (lfn, type, 1);
3906 : 2184 : res_op->ops[0] = captures[0];
3907 : 2184 : res_op->resimplify (lseq, valueize);
3908 : 2184 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 800, __FILE__, __LINE__, true);
3909 : 2184 : return true;
3910 : : }
3911 : 0 : next_after_fail1157:;
3912 : : }
3913 : : }
3914 : : return false;
3915 : : }
3916 : :
3917 : : bool
3918 : 0 : gimple_simplify_625 (gimple_match_op *res_op, gimple_seq *seq,
3919 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3920 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures))
3921 : : {
3922 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3923 : 0 : if (canonicalize_math_after_vectorization_p ()
3924 : : )
3925 : : {
3926 : 0 : gimple_seq *lseq = seq;
3927 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1167;
3928 : 0 : {
3929 : 0 : res_op->set_op (CFN_FMS, type, 3);
3930 : 0 : res_op->ops[0] = captures[0];
3931 : 0 : res_op->ops[1] = captures[1];
3932 : 0 : res_op->ops[2] = captures[2];
3933 : 0 : res_op->resimplify (lseq, valueize);
3934 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 810, __FILE__, __LINE__, true);
3935 : 0 : return true;
3936 : : }
3937 : 0 : next_after_fail1167:;
3938 : : }
3939 : : return false;
3940 : : }
3941 : :
3942 : : bool
3943 : 13944 : gimple_simplify_634 (gimple_match_op *res_op, gimple_seq *seq,
3944 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
3945 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
3946 : : const combined_fn ARG_UNUSED (pfun))
3947 : : {
3948 : 13944 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
3949 : 13944 : if (INTEGRAL_TYPE_P (type)
3950 : : )
3951 : : {
3952 : 13562 : {
3953 : 13562 : wide_int nz = tree_nonzero_bits (captures[0]);
3954 : 13562 : if (nz == 1
3955 : : )
3956 : : {
3957 : 19 : gimple_seq *lseq = seq;
3958 : 19 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1180;
3959 : 19 : {
3960 : 19 : res_op->set_op (NOP_EXPR, type, 1);
3961 : 19 : res_op->ops[0] = captures[0];
3962 : 19 : res_op->resimplify (lseq, valueize);
3963 : 19 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 821, __FILE__, __LINE__, true);
3964 : 19 : return true;
3965 : : }
3966 : 0 : next_after_fail1180:;
3967 : : }
3968 : : else
3969 : : {
3970 : 13543 : if (wi::popcount (nz) == 1
3971 : : )
3972 : : {
3973 : 13 : {
3974 : 13 : tree utype = unsigned_type_for (TREE_TYPE (captures[0]));
3975 : 13 : gimple_seq *lseq = seq;
3976 : 13 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1181;
3977 : 13 : {
3978 : 13 : res_op->set_op (NOP_EXPR, type, 1);
3979 : 13 : {
3980 : 13 : tree _o1[2], _r1;
3981 : 13 : {
3982 : 13 : tree _o2[1], _r2;
3983 : 13 : _o2[0] = captures[0];
3984 : 13 : if (utype != TREE_TYPE (_o2[0])
3985 : 13 : && !useless_type_conversion_p (utype, TREE_TYPE (_o2[0])))
3986 : : {
3987 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, utype, _o2[0]);
3988 : 0 : tem_op.resimplify (lseq, valueize);
3989 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
3990 : 0 : if (!_r2) goto next_after_fail1181;
3991 : : }
3992 : : else
3993 : : _r2 = _o2[0];
3994 : 13 : _o1[0] = _r2;
3995 : : }
3996 : 26 : _o1[1] = build_int_cst (integer_type_node,
3997 : 13 : wi::ctz (nz));
3998 : 13 : gimple_match_op tem_op (res_op->cond.any_else (), RSHIFT_EXPR, utype, _o1[0], _o1[1]);
3999 : 13 : tem_op.resimplify (lseq, valueize);
4000 : 13 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
4001 : 13 : if (!_r1) goto next_after_fail1181;
4002 : 13 : res_op->ops[0] = _r1;
4003 : : }
4004 : 13 : res_op->resimplify (lseq, valueize);
4005 : 13 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 822, __FILE__, __LINE__, true);
4006 : 13 : return true;
4007 : : }
4008 : 13530 : next_after_fail1181:;
4009 : : }
4010 : : }
4011 : : }
4012 : 13562 : }
4013 : : }
4014 : : return false;
4015 : : }
4016 : :
4017 : : bool
4018 : 688 : gimple_simplify_642 (gimple_match_op *res_op, gimple_seq *seq,
4019 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
4020 : : const tree ARG_UNUSED (type), tree *ARG_UNUSED (captures),
4021 : : const combined_fn ARG_UNUSED (FFS))
4022 : : {
4023 : 688 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
4024 : 1376 : if (INTEGRAL_TYPE_P (TREE_TYPE (captures[0]))
4025 : 688 : && INTEGRAL_TYPE_P (TREE_TYPE (captures[1]))
4026 : 1376 : && TYPE_PRECISION (TREE_TYPE (captures[0])) > TYPE_PRECISION (TREE_TYPE (captures[1]))
4027 : : )
4028 : : {
4029 : 204 : {
4030 : 204 : combined_fn cfn = CFN_LAST;
4031 : 204 : tree type0 = TREE_TYPE (captures[1]);
4032 : 204 : if (TREE_CODE (type0) == BITINT_TYPE)
4033 : : {
4034 : 8 : if (TYPE_PRECISION (type0) > MAX_FIXED_MODE_SIZE)
4035 : : cfn = CFN_FFS;
4036 : : else
4037 : 0 : type0
4038 : 0 : = build_nonstandard_integer_type (TYPE_PRECISION (type0),
4039 : : 0);
4040 : : }
4041 : 204 : type0 = signed_type_for (type0);
4042 : 204 : if (cfn == CFN_LAST
4043 : 204 : && direct_internal_fn_supported_p (IFN_FFS, type0,
4044 : : OPTIMIZE_FOR_BOTH))
4045 : : cfn = CFN_FFS;
4046 : 189 : if (cfn == CFN_LAST
4047 : 185 : && TYPE_PRECISION (TREE_TYPE (captures[0])) > BITS_PER_WORD
4048 : 189 : && !direct_internal_fn_supported_p (IFN_FFS,
4049 : 0 : TREE_TYPE (captures[0]),
4050 : : OPTIMIZE_FOR_BOTH))
4051 : : {
4052 : 0 : if (TYPE_PRECISION (type0)
4053 : 0 : == TYPE_PRECISION (integer_type_node))
4054 : : cfn = CFN_BUILT_IN_FFS;
4055 : 0 : else if (TYPE_PRECISION (type0)
4056 : 0 : == TYPE_PRECISION (long_long_integer_type_node))
4057 : : cfn = CFN_BUILT_IN_FFSLL;
4058 : : }
4059 : 204 : if (cfn == CFN_FFS
4060 : : )
4061 : : {
4062 : 19 : gimple_seq *lseq = seq;
4063 : 19 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1191;
4064 : 19 : {
4065 : 19 : res_op->set_op (CFN_FFS, type, 1);
4066 : 19 : {
4067 : 19 : tree _o1[1], _r1;
4068 : 19 : _o1[0] = captures[1];
4069 : 19 : if (type0 != TREE_TYPE (_o1[0])
4070 : 19 : && !useless_type_conversion_p (type0, TREE_TYPE (_o1[0])))
4071 : : {
4072 : 12 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type0, _o1[0]);
4073 : 12 : tem_op.resimplify (lseq, valueize);
4074 : 12 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
4075 : 12 : if (!_r1) goto next_after_fail1191;
4076 : : }
4077 : : else
4078 : : _r1 = _o1[0];
4079 : 13 : res_op->ops[0] = _r1;
4080 : : }
4081 : 13 : res_op->resimplify (lseq, valueize);
4082 : 13 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 830, __FILE__, __LINE__, true);
4083 : 13 : return true;
4084 : : }
4085 : : next_after_fail1191:;
4086 : : }
4087 : : else
4088 : : {
4089 : 185 : if (cfn == CFN_BUILT_IN_FFS
4090 : : )
4091 : : {
4092 : 0 : gimple_seq *lseq = seq;
4093 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1192;
4094 : 0 : {
4095 : 0 : res_op->set_op (CFN_BUILT_IN_FFS, type, 1);
4096 : 0 : {
4097 : 0 : tree _o1[1], _r1;
4098 : 0 : _o1[0] = captures[1];
4099 : 0 : if (type0 != TREE_TYPE (_o1[0])
4100 : 0 : && !useless_type_conversion_p (type0, TREE_TYPE (_o1[0])))
4101 : : {
4102 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type0, _o1[0]);
4103 : 0 : tem_op.resimplify (lseq, valueize);
4104 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
4105 : 0 : if (!_r1) goto next_after_fail1192;
4106 : : }
4107 : : else
4108 : : _r1 = _o1[0];
4109 : 0 : res_op->ops[0] = _r1;
4110 : : }
4111 : 0 : res_op->resimplify (lseq, valueize);
4112 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 831, __FILE__, __LINE__, true);
4113 : 0 : return true;
4114 : : }
4115 : : next_after_fail1192:;
4116 : : }
4117 : : else
4118 : : {
4119 : 185 : if (cfn == CFN_BUILT_IN_FFSLL
4120 : : )
4121 : : {
4122 : 0 : gimple_seq *lseq = seq;
4123 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1193;
4124 : 0 : {
4125 : 0 : res_op->set_op (CFN_BUILT_IN_FFSLL, type, 1);
4126 : 0 : {
4127 : 0 : tree _o1[1], _r1;
4128 : 0 : _o1[0] = captures[1];
4129 : 0 : if (type0 != TREE_TYPE (_o1[0])
4130 : 0 : && !useless_type_conversion_p (type0, TREE_TYPE (_o1[0])))
4131 : : {
4132 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type0, _o1[0]);
4133 : 0 : tem_op.resimplify (lseq, valueize);
4134 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
4135 : 0 : if (!_r1) goto next_after_fail1193;
4136 : : }
4137 : : else
4138 : : _r1 = _o1[0];
4139 : 0 : res_op->ops[0] = _r1;
4140 : : }
4141 : 0 : res_op->resimplify (lseq, valueize);
4142 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 832, __FILE__, __LINE__, true);
4143 : 0 : return true;
4144 : : }
4145 : : next_after_fail1193:;
4146 : : }
4147 : : }
4148 : : }
4149 : : }
4150 : : }
4151 : : return false;
4152 : : }
4153 : :
4154 : : bool
4155 : 1747 : gimple_simplify_CFN_BUILT_IN_COSH (gimple_match_op *res_op, gimple_seq *seq,
4156 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
4157 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
4158 : : {
4159 : 1747 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
4160 : 1747 : switch (TREE_CODE (_p0))
4161 : : {
4162 : 1624 : case SSA_NAME:
4163 : 1624 : if (gimple *_d1 = get_def (valueize, _p0))
4164 : : {
4165 : 737 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
4166 : 515 : switch (gimple_assign_rhs_code (_a1))
4167 : : {
4168 : 16 : case NEGATE_EXPR:
4169 : 16 : {
4170 : 16 : tree _q20 = gimple_assign_rhs1 (_a1);
4171 : 16 : _q20 = do_valueize (valueize, _q20);
4172 : 16 : {
4173 : 16 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
4174 : 16 : const combined_fn coss = CFN_BUILT_IN_COSH;
4175 : 16 : gimple_seq *lseq = seq;
4176 : 16 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1238;
4177 : 16 : {
4178 : 16 : res_op->set_op (coss, type, 1);
4179 : 16 : res_op->ops[0] = captures[0];
4180 : 16 : res_op->resimplify (lseq, valueize);
4181 : 16 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 860, __FILE__, __LINE__, true);
4182 : 16 : return true;
4183 : : }
4184 : 0 : next_after_fail1238:;
4185 : : }
4186 : 0 : break;
4187 : : }
4188 : 0 : case ABS_EXPR:
4189 : 0 : {
4190 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
4191 : 0 : _q20 = do_valueize (valueize, _q20);
4192 : 0 : {
4193 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
4194 : 0 : const combined_fn coss = CFN_BUILT_IN_COSH;
4195 : 0 : gimple_seq *lseq = seq;
4196 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1239;
4197 : 0 : {
4198 : 0 : res_op->set_op (coss, type, 1);
4199 : 0 : res_op->ops[0] = captures[0];
4200 : 0 : res_op->resimplify (lseq, valueize);
4201 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 860, __FILE__, __LINE__, true);
4202 : 0 : return true;
4203 : : }
4204 : 0 : next_after_fail1239:;
4205 : : }
4206 : 0 : break;
4207 : : }
4208 : : default:;
4209 : : }
4210 : 327 : else if (gcall *_c1 = dyn_cast <gcall *> (_d1))
4211 : 53 : switch (gimple_call_combined_fn (_c1))
4212 : : {
4213 : 0 : case CFN_BUILT_IN_COPYSIGN:
4214 : 0 : if (gimple_call_num_args (_c1) == 2)
4215 : : {
4216 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
4217 : 0 : _q20 = do_valueize (valueize, _q20);
4218 : 0 : tree _q21 = gimple_call_arg (_c1, 1);
4219 : 0 : _q21 = do_valueize (valueize, _q21);
4220 : 0 : {
4221 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
4222 : 0 : if (gimple_simplify_398 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_COPYSIGN, CFN_BUILT_IN_COSH))
4223 : 0 : return true;
4224 : : }
4225 : : }
4226 : : break;
4227 : 0 : case CFN_BUILT_IN_COPYSIGNF:
4228 : 0 : if (gimple_call_num_args (_c1) == 2)
4229 : : {
4230 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
4231 : 0 : _q20 = do_valueize (valueize, _q20);
4232 : 0 : tree _q21 = gimple_call_arg (_c1, 1);
4233 : 0 : _q21 = do_valueize (valueize, _q21);
4234 : 0 : {
4235 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
4236 : 0 : if (gimple_simplify_398 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_COPYSIGNF, CFN_BUILT_IN_COSH))
4237 : 0 : return true;
4238 : : }
4239 : : }
4240 : : break;
4241 : 0 : case CFN_BUILT_IN_COPYSIGNL:
4242 : 0 : if (gimple_call_num_args (_c1) == 2)
4243 : : {
4244 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
4245 : 0 : _q20 = do_valueize (valueize, _q20);
4246 : 0 : tree _q21 = gimple_call_arg (_c1, 1);
4247 : 0 : _q21 = do_valueize (valueize, _q21);
4248 : 0 : {
4249 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
4250 : 0 : if (gimple_simplify_398 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_COPYSIGNL, CFN_BUILT_IN_COSH))
4251 : 0 : return true;
4252 : : }
4253 : : }
4254 : : break;
4255 : 21 : case CFN_BUILT_IN_ATANH:
4256 : 21 : if (gimple_call_num_args (_c1) == 1)
4257 : : {
4258 : 21 : tree _q20 = gimple_call_arg (_c1, 0);
4259 : 21 : _q20 = do_valueize (valueize, _q20);
4260 : 21 : {
4261 : 21 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q20 };
4262 : 21 : if (gimple_simplify_400 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_COSH, CFN_BUILT_IN_ATANH, CFN_BUILT_IN_SQRT))
4263 : 1 : return true;
4264 : : }
4265 : : }
4266 : : break;
4267 : 0 : case CFN_COPYSIGN:
4268 : 0 : if (gimple_call_num_args (_c1) == 2)
4269 : : {
4270 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
4271 : 0 : _q20 = do_valueize (valueize, _q20);
4272 : 0 : tree _q21 = gimple_call_arg (_c1, 1);
4273 : 0 : _q21 = do_valueize (valueize, _q21);
4274 : 0 : {
4275 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
4276 : 0 : if (gimple_simplify_398 (res_op, seq, valueize, type, captures, CFN_COPYSIGN, CFN_BUILT_IN_COSH))
4277 : 0 : return true;
4278 : : }
4279 : : }
4280 : : break;
4281 : : default:;
4282 : : }
4283 : : }
4284 : : break;
4285 : : default:;
4286 : : }
4287 : : return false;
4288 : : }
4289 : :
4290 : : bool
4291 : 341 : gimple_simplify_CFN_BUILT_IN_CCOSH (gimple_match_op *res_op, gimple_seq *seq,
4292 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
4293 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
4294 : : {
4295 : 341 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
4296 : 341 : switch (TREE_CODE (_p0))
4297 : : {
4298 : 333 : case SSA_NAME:
4299 : 333 : if (gimple *_d1 = get_def (valueize, _p0))
4300 : : {
4301 : 202 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
4302 : 322 : switch (gimple_assign_rhs_code (_a1))
4303 : : {
4304 : 14 : case NEGATE_EXPR:
4305 : 14 : {
4306 : 14 : tree _q20 = gimple_assign_rhs1 (_a1);
4307 : 14 : _q20 = do_valueize (valueize, _q20);
4308 : 14 : {
4309 : 14 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
4310 : 14 : gimple_seq *lseq = seq;
4311 : 14 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1261;
4312 : 14 : {
4313 : 14 : res_op->set_op (CFN_BUILT_IN_CCOSH, type, 1);
4314 : 14 : res_op->ops[0] = captures[0];
4315 : 14 : res_op->resimplify (lseq, valueize);
4316 : 14 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 872, __FILE__, __LINE__, true);
4317 : 14 : return true;
4318 : : }
4319 : 0 : next_after_fail1261:;
4320 : : }
4321 : 0 : break;
4322 : : }
4323 : : default:;
4324 : : }
4325 : : }
4326 : : break;
4327 : : default:;
4328 : : }
4329 : : return false;
4330 : : }
4331 : :
4332 : : bool
4333 : 4776 : gimple_simplify_CFN_BUILT_IN_CABSL (gimple_match_op *res_op, gimple_seq *seq,
4334 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
4335 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
4336 : : {
4337 : 4776 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
4338 : 4776 : switch (TREE_CODE (_p0))
4339 : : {
4340 : 4763 : case SSA_NAME:
4341 : 4763 : if (gimple *_d1 = get_def (valueize, _p0))
4342 : : {
4343 : 2383 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
4344 : 2469 : switch (gimple_assign_rhs_code (_a1))
4345 : : {
4346 : 2 : case CONJ_EXPR:
4347 : 2 : {
4348 : 2 : tree _q20 = gimple_assign_rhs1 (_a1);
4349 : 2 : _q20 = do_valueize (valueize, _q20);
4350 : 2 : {
4351 : 2 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
4352 : 2 : gimple_seq *lseq = seq;
4353 : 2 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1273;
4354 : 2 : {
4355 : 2 : res_op->set_op (CFN_BUILT_IN_CABSL, type, 1);
4356 : 2 : res_op->ops[0] = captures[0];
4357 : 2 : res_op->resimplify (lseq, valueize);
4358 : 2 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 873, __FILE__, __LINE__, true);
4359 : 2 : return true;
4360 : : }
4361 : 0 : next_after_fail1273:;
4362 : : }
4363 : 0 : break;
4364 : : }
4365 : 16 : case NEGATE_EXPR:
4366 : 16 : {
4367 : 16 : tree _q20 = gimple_assign_rhs1 (_a1);
4368 : 16 : _q20 = do_valueize (valueize, _q20);
4369 : 16 : {
4370 : 16 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
4371 : 16 : gimple_seq *lseq = seq;
4372 : 16 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1274;
4373 : 16 : {
4374 : 16 : res_op->set_op (CFN_BUILT_IN_CABSL, type, 1);
4375 : 16 : res_op->ops[0] = captures[0];
4376 : 16 : res_op->resimplify (lseq, valueize);
4377 : 16 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 873, __FILE__, __LINE__, true);
4378 : 16 : return true;
4379 : : }
4380 : 0 : next_after_fail1274:;
4381 : : }
4382 : 0 : break;
4383 : : }
4384 : 1184 : case COMPLEX_EXPR:
4385 : 1184 : {
4386 : 1184 : tree _q20 = gimple_assign_rhs1 (_a1);
4387 : 1184 : _q20 = do_valueize (valueize, _q20);
4388 : 1184 : tree _q21 = gimple_assign_rhs2 (_a1);
4389 : 1184 : _q21 = do_valueize (valueize, _q21);
4390 : 1184 : if (real_zerop (_q21))
4391 : : {
4392 : 14 : {
4393 : 14 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
4394 : 14 : gimple_seq *lseq = seq;
4395 : 14 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1275;
4396 : 14 : {
4397 : 14 : res_op->set_op (ABS_EXPR, type, 1);
4398 : 14 : res_op->ops[0] = captures[0];
4399 : 14 : res_op->resimplify (lseq, valueize);
4400 : 14 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 874, __FILE__, __LINE__, true);
4401 : 14 : return true;
4402 : : }
4403 : 0 : next_after_fail1275:;
4404 : : }
4405 : : }
4406 : 1170 : if (real_zerop (_q20))
4407 : : {
4408 : 0 : {
4409 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q21, _q20 };
4410 : 0 : gimple_seq *lseq = seq;
4411 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1276;
4412 : 0 : {
4413 : 0 : res_op->set_op (ABS_EXPR, type, 1);
4414 : 0 : res_op->ops[0] = captures[0];
4415 : 0 : res_op->resimplify (lseq, valueize);
4416 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 874, __FILE__, __LINE__, true);
4417 : 0 : return true;
4418 : : }
4419 : 0 : next_after_fail1276:;
4420 : : }
4421 : : }
4422 : 1170 : if ((_q21 == _q20 && ! TREE_SIDE_EFFECTS (_q21)) || (operand_equal_p (_q21, _q20, 0) && types_match (_q21, _q20)))
4423 : : {
4424 : 6 : {
4425 : 6 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
4426 : 6 : if (flag_unsafe_math_optimizations && canonicalize_math_p ()
4427 : : )
4428 : : {
4429 : 6 : gimple_seq *lseq = seq;
4430 : 6 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1277;
4431 : 6 : {
4432 : 6 : res_op->set_op (MULT_EXPR, type, 2);
4433 : 6 : {
4434 : 6 : tree _o1[1], _r1;
4435 : 6 : _o1[0] = captures[0];
4436 : 6 : gimple_match_op tem_op (res_op->cond.any_else (), ABS_EXPR, TREE_TYPE (_o1[0]), _o1[0]);
4437 : 6 : tem_op.resimplify (lseq, valueize);
4438 : 6 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
4439 : 6 : if (!_r1) goto next_after_fail1277;
4440 : 4 : res_op->ops[0] = _r1;
4441 : : }
4442 : 4 : res_op->ops[1] = build_real_truncate (type, dconst_sqrt2 ());
4443 : 4 : res_op->resimplify (lseq, valueize);
4444 : 4 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 875, __FILE__, __LINE__, true);
4445 : 4 : return true;
4446 : : }
4447 : : next_after_fail1277:;
4448 : : }
4449 : : }
4450 : : }
4451 : : break;
4452 : : }
4453 : : default:;
4454 : : }
4455 : : }
4456 : : break;
4457 : : default:;
4458 : : }
4459 : : return false;
4460 : : }
4461 : :
4462 : : bool
4463 : 1519357 : gimple_simplify_REALPART_EXPR (gimple_match_op *res_op, gimple_seq *seq,
4464 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
4465 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
4466 : : {
4467 : 1519357 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
4468 : 1519357 : switch (TREE_CODE (_p0))
4469 : : {
4470 : 1119854 : case SSA_NAME:
4471 : 1119854 : if (gimple *_d1 = get_def (valueize, _p0))
4472 : : {
4473 : 775055 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
4474 : 354545 : switch (gimple_assign_rhs_code (_a1))
4475 : : {
4476 : 6687 : case COMPLEX_EXPR:
4477 : 6687 : {
4478 : 6687 : tree _q20 = gimple_assign_rhs1 (_a1);
4479 : 6687 : _q20 = do_valueize (valueize, _q20);
4480 : 6687 : tree _q21 = gimple_assign_rhs2 (_a1);
4481 : 6687 : _q21 = do_valueize (valueize, _q21);
4482 : 6687 : {
4483 : 6687 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
4484 : 6687 : gimple_seq *lseq = seq;
4485 : 6687 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1330;
4486 : 6687 : {
4487 : 6687 : tree tem;
4488 : 6687 : tem = captures[0];
4489 : 6687 : res_op->set_value (tem);
4490 : 6687 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 895, __FILE__, __LINE__, true);
4491 : 6687 : return true;
4492 : : }
4493 : 0 : next_after_fail1330:;
4494 : : }
4495 : 0 : break;
4496 : : }
4497 : 0 : CASE_CONVERT:
4498 : 0 : {
4499 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
4500 : 0 : _q20 = do_valueize (valueize, _q20);
4501 : 0 : switch (TREE_CODE (_q20))
4502 : : {
4503 : 0 : case SSA_NAME:
4504 : 0 : if (gimple *_d2 = get_def (valueize, _q20))
4505 : : {
4506 : 0 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
4507 : 0 : switch (gimple_assign_rhs_code (_a2))
4508 : : {
4509 : 0 : case CONJ_EXPR:
4510 : 0 : {
4511 : 0 : tree _q30 = gimple_assign_rhs1 (_a2);
4512 : 0 : _q30 = do_valueize (valueize, _q30);
4513 : 0 : {
4514 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q30 };
4515 : 0 : gimple_seq *lseq = seq;
4516 : 0 : if (lseq
4517 : 0 : && (!single_use (captures[0])
4518 : 0 : || !single_use (captures[1])))
4519 : 0 : lseq = NULL;
4520 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1331;
4521 : 0 : {
4522 : 0 : res_op->set_op (NOP_EXPR, type, 1);
4523 : 0 : {
4524 : 0 : tree _o1[1], _r1;
4525 : 0 : _o1[0] = captures[2];
4526 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), REALPART_EXPR, TREE_TYPE (TREE_TYPE (_o1[0])), _o1[0]);
4527 : 0 : tem_op.resimplify (lseq, valueize);
4528 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
4529 : 0 : if (!_r1) goto next_after_fail1331;
4530 : 0 : res_op->ops[0] = _r1;
4531 : : }
4532 : 0 : res_op->resimplify (lseq, valueize);
4533 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 896, __FILE__, __LINE__, true);
4534 : 0 : return true;
4535 : : }
4536 : 0 : next_after_fail1331:;
4537 : : }
4538 : 0 : break;
4539 : : }
4540 : 0 : case PLUS_EXPR:
4541 : 0 : {
4542 : 0 : tree _q30 = gimple_assign_rhs1 (_a2);
4543 : 0 : _q30 = do_valueize (valueize, _q30);
4544 : 0 : tree _q31 = gimple_assign_rhs2 (_a2);
4545 : 0 : _q31 = do_valueize (valueize, _q31);
4546 : 0 : if (tree_swap_operands_p (_q30, _q31))
4547 : 0 : std::swap (_q30, _q31);
4548 : 0 : {
4549 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q31 };
4550 : 0 : const enum tree_code op = PLUS_EXPR;
4551 : 0 : gimple_seq *lseq = seq;
4552 : 0 : if (lseq
4553 : 0 : && (!single_use (captures[0])
4554 : 0 : || !single_use (captures[1])))
4555 : 0 : lseq = NULL;
4556 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1332;
4557 : 0 : {
4558 : 0 : res_op->set_op (NOP_EXPR, type, 1);
4559 : 0 : {
4560 : 0 : tree _o1[2], _r1;
4561 : 0 : {
4562 : 0 : tree _o2[1], _r2;
4563 : 0 : _o2[0] = captures[2];
4564 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), REALPART_EXPR, TREE_TYPE (TREE_TYPE (_o2[0])), _o2[0]);
4565 : 0 : tem_op.resimplify (lseq, valueize);
4566 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
4567 : 0 : if (!_r2) goto next_after_fail1332;
4568 : 0 : _o1[0] = _r2;
4569 : : }
4570 : 0 : {
4571 : 0 : tree _o2[1], _r2;
4572 : 0 : _o2[0] = captures[3];
4573 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), REALPART_EXPR, TREE_TYPE (TREE_TYPE (_o2[0])), _o2[0]);
4574 : 0 : tem_op.resimplify (lseq, valueize);
4575 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
4576 : 0 : if (!_r2) goto next_after_fail1332;
4577 : 0 : _o1[1] = _r2;
4578 : : }
4579 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), op, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
4580 : 0 : tem_op.resimplify (lseq, valueize);
4581 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
4582 : 0 : if (!_r1) goto next_after_fail1332;
4583 : 0 : res_op->ops[0] = _r1;
4584 : : }
4585 : 0 : res_op->resimplify (lseq, valueize);
4586 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 897, __FILE__, __LINE__, true);
4587 : 0 : return true;
4588 : : }
4589 : 0 : next_after_fail1332:;
4590 : : }
4591 : 0 : break;
4592 : : }
4593 : 0 : case MINUS_EXPR:
4594 : 0 : {
4595 : 0 : tree _q30 = gimple_assign_rhs1 (_a2);
4596 : 0 : _q30 = do_valueize (valueize, _q30);
4597 : 0 : tree _q31 = gimple_assign_rhs2 (_a2);
4598 : 0 : _q31 = do_valueize (valueize, _q31);
4599 : 0 : {
4600 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q31 };
4601 : 0 : const enum tree_code op = MINUS_EXPR;
4602 : 0 : gimple_seq *lseq = seq;
4603 : 0 : if (lseq
4604 : 0 : && (!single_use (captures[0])
4605 : 0 : || !single_use (captures[1])))
4606 : 0 : lseq = NULL;
4607 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1333;
4608 : 0 : {
4609 : 0 : res_op->set_op (NOP_EXPR, type, 1);
4610 : 0 : {
4611 : 0 : tree _o1[2], _r1;
4612 : 0 : {
4613 : 0 : tree _o2[1], _r2;
4614 : 0 : _o2[0] = captures[2];
4615 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), REALPART_EXPR, TREE_TYPE (TREE_TYPE (_o2[0])), _o2[0]);
4616 : 0 : tem_op.resimplify (lseq, valueize);
4617 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
4618 : 0 : if (!_r2) goto next_after_fail1333;
4619 : 0 : _o1[0] = _r2;
4620 : : }
4621 : 0 : {
4622 : 0 : tree _o2[1], _r2;
4623 : 0 : _o2[0] = captures[3];
4624 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), REALPART_EXPR, TREE_TYPE (TREE_TYPE (_o2[0])), _o2[0]);
4625 : 0 : tem_op.resimplify (lseq, valueize);
4626 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
4627 : 0 : if (!_r2) goto next_after_fail1333;
4628 : 0 : _o1[1] = _r2;
4629 : : }
4630 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), op, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
4631 : 0 : tem_op.resimplify (lseq, valueize);
4632 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
4633 : 0 : if (!_r1) goto next_after_fail1333;
4634 : 0 : res_op->ops[0] = _r1;
4635 : : }
4636 : 0 : res_op->resimplify (lseq, valueize);
4637 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 897, __FILE__, __LINE__, true);
4638 : 0 : return true;
4639 : : }
4640 : 0 : next_after_fail1333:;
4641 : : }
4642 : 0 : break;
4643 : : }
4644 : : default:;
4645 : : }
4646 : 0 : else if (gcall *_c2 = dyn_cast <gcall *> (_d2))
4647 : 0 : switch (gimple_call_combined_fn (_c2))
4648 : : {
4649 : 0 : case CFN_BUILT_IN_CEXPIF:
4650 : 0 : if (gimple_call_num_args (_c2) == 1)
4651 : : {
4652 : 0 : tree _q30 = gimple_call_arg (_c2, 0);
4653 : 0 : _q30 = do_valueize (valueize, _q30);
4654 : 0 : {
4655 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q30 };
4656 : 0 : gimple_seq *lseq = seq;
4657 : 0 : if (lseq
4658 : 0 : && (!single_use (captures[0])
4659 : 0 : || !single_use (captures[1])))
4660 : 0 : lseq = NULL;
4661 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1334;
4662 : 0 : {
4663 : 0 : res_op->set_op (NOP_EXPR, type, 1);
4664 : 0 : {
4665 : 0 : tree _o1[1], _r1;
4666 : 0 : _o1[0] = captures[2];
4667 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_COSF, TREE_TYPE (_o1[0]), _o1[0]);
4668 : 0 : tem_op.resimplify (lseq, valueize);
4669 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
4670 : 0 : if (!_r1) goto next_after_fail1334;
4671 : 0 : res_op->ops[0] = _r1;
4672 : : }
4673 : 0 : res_op->resimplify (lseq, valueize);
4674 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 898, __FILE__, __LINE__, true);
4675 : 0 : return true;
4676 : : }
4677 : 0 : next_after_fail1334:;
4678 : : }
4679 : : }
4680 : : break;
4681 : 0 : case CFN_BUILT_IN_CEXPIL:
4682 : 0 : if (gimple_call_num_args (_c2) == 1)
4683 : : {
4684 : 0 : tree _q30 = gimple_call_arg (_c2, 0);
4685 : 0 : _q30 = do_valueize (valueize, _q30);
4686 : 0 : {
4687 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q30 };
4688 : 0 : gimple_seq *lseq = seq;
4689 : 0 : if (lseq
4690 : 0 : && (!single_use (captures[0])
4691 : 0 : || !single_use (captures[1])))
4692 : 0 : lseq = NULL;
4693 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1335;
4694 : 0 : {
4695 : 0 : res_op->set_op (NOP_EXPR, type, 1);
4696 : 0 : {
4697 : 0 : tree _o1[1], _r1;
4698 : 0 : _o1[0] = captures[2];
4699 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_COSL, TREE_TYPE (_o1[0]), _o1[0]);
4700 : 0 : tem_op.resimplify (lseq, valueize);
4701 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
4702 : 0 : if (!_r1) goto next_after_fail1335;
4703 : 0 : res_op->ops[0] = _r1;
4704 : : }
4705 : 0 : res_op->resimplify (lseq, valueize);
4706 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 898, __FILE__, __LINE__, true);
4707 : 0 : return true;
4708 : : }
4709 : 0 : next_after_fail1335:;
4710 : : }
4711 : : }
4712 : : break;
4713 : 0 : case CFN_BUILT_IN_CEXPI:
4714 : 0 : if (gimple_call_num_args (_c2) == 1)
4715 : : {
4716 : 0 : tree _q30 = gimple_call_arg (_c2, 0);
4717 : 0 : _q30 = do_valueize (valueize, _q30);
4718 : 0 : {
4719 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q30 };
4720 : 0 : gimple_seq *lseq = seq;
4721 : 0 : if (lseq
4722 : 0 : && (!single_use (captures[0])
4723 : 0 : || !single_use (captures[1])))
4724 : 0 : lseq = NULL;
4725 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1336;
4726 : 0 : {
4727 : 0 : res_op->set_op (NOP_EXPR, type, 1);
4728 : 0 : {
4729 : 0 : tree _o1[1], _r1;
4730 : 0 : _o1[0] = captures[2];
4731 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_COS, TREE_TYPE (_o1[0]), _o1[0]);
4732 : 0 : tem_op.resimplify (lseq, valueize);
4733 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
4734 : 0 : if (!_r1) goto next_after_fail1336;
4735 : 0 : res_op->ops[0] = _r1;
4736 : : }
4737 : 0 : res_op->resimplify (lseq, valueize);
4738 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 898, __FILE__, __LINE__, true);
4739 : 0 : return true;
4740 : : }
4741 : 0 : next_after_fail1336:;
4742 : : }
4743 : : }
4744 : : break;
4745 : : default:;
4746 : : }
4747 : : }
4748 : : break;
4749 : : default:;
4750 : : }
4751 : : break;
4752 : : }
4753 : 0 : case CONJ_EXPR:
4754 : 0 : {
4755 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
4756 : 0 : _q20 = do_valueize (valueize, _q20);
4757 : 0 : {
4758 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p0, _q20 };
4759 : 0 : gimple_seq *lseq = seq;
4760 : 0 : if (lseq
4761 : 0 : && (!single_use (captures[0])
4762 : : || !single_use (captures[1])))
4763 : : lseq = NULL;
4764 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1337;
4765 : 0 : {
4766 : 0 : res_op->set_op (NOP_EXPR, type, 1);
4767 : 0 : {
4768 : 0 : tree _o1[1], _r1;
4769 : 0 : _o1[0] = captures[2];
4770 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), REALPART_EXPR, TREE_TYPE (TREE_TYPE (_o1[0])), _o1[0]);
4771 : 0 : tem_op.resimplify (lseq, valueize);
4772 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
4773 : 0 : if (!_r1) goto next_after_fail1337;
4774 : 0 : res_op->ops[0] = _r1;
4775 : : }
4776 : 0 : res_op->resimplify (lseq, valueize);
4777 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 896, __FILE__, __LINE__, true);
4778 : 0 : return true;
4779 : : }
4780 : 0 : next_after_fail1337:;
4781 : : }
4782 : 0 : break;
4783 : : }
4784 : 1090 : case PLUS_EXPR:
4785 : 1090 : {
4786 : 1090 : tree _q20 = gimple_assign_rhs1 (_a1);
4787 : 1090 : _q20 = do_valueize (valueize, _q20);
4788 : 1090 : tree _q21 = gimple_assign_rhs2 (_a1);
4789 : 1090 : _q21 = do_valueize (valueize, _q21);
4790 : 1090 : if (tree_swap_operands_p (_q20, _q21))
4791 : 62 : std::swap (_q20, _q21);
4792 : 1090 : {
4793 : 1090 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p0, _q20, _q21 };
4794 : 1090 : const enum tree_code op = PLUS_EXPR;
4795 : 1090 : gimple_seq *lseq = seq;
4796 : 1090 : if (lseq
4797 : 275 : && (!single_use (captures[0])
4798 : : || !single_use (captures[1])))
4799 : : lseq = NULL;
4800 : 1090 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1338;
4801 : 1090 : {
4802 : 1090 : res_op->set_op (NOP_EXPR, type, 1);
4803 : 1090 : {
4804 : 1090 : tree _o1[2], _r1;
4805 : 1090 : {
4806 : 1090 : tree _o2[1], _r2;
4807 : 1090 : _o2[0] = captures[2];
4808 : 1090 : gimple_match_op tem_op (res_op->cond.any_else (), REALPART_EXPR, TREE_TYPE (TREE_TYPE (_o2[0])), _o2[0]);
4809 : 1090 : tem_op.resimplify (lseq, valueize);
4810 : 1090 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
4811 : 1090 : if (!_r2) goto next_after_fail1338;
4812 : 837 : _o1[0] = _r2;
4813 : : }
4814 : 837 : {
4815 : 837 : tree _o2[1], _r2;
4816 : 837 : _o2[0] = captures[3];
4817 : 837 : gimple_match_op tem_op (res_op->cond.any_else (), REALPART_EXPR, TREE_TYPE (TREE_TYPE (_o2[0])), _o2[0]);
4818 : 837 : tem_op.resimplify (lseq, valueize);
4819 : 837 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
4820 : 837 : if (!_r2) goto next_after_fail1338;
4821 : 435 : _o1[1] = _r2;
4822 : : }
4823 : 435 : gimple_match_op tem_op (res_op->cond.any_else (), op, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
4824 : 435 : tem_op.resimplify (lseq, valueize);
4825 : 435 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
4826 : 435 : if (!_r1) goto next_after_fail1338;
4827 : 26 : res_op->ops[0] = _r1;
4828 : : }
4829 : 26 : res_op->resimplify (lseq, valueize);
4830 : 26 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 897, __FILE__, __LINE__, true);
4831 : 26 : return true;
4832 : : }
4833 : 1064 : next_after_fail1338:;
4834 : : }
4835 : 1064 : break;
4836 : : }
4837 : 815 : case MINUS_EXPR:
4838 : 815 : {
4839 : 815 : tree _q20 = gimple_assign_rhs1 (_a1);
4840 : 815 : _q20 = do_valueize (valueize, _q20);
4841 : 815 : tree _q21 = gimple_assign_rhs2 (_a1);
4842 : 815 : _q21 = do_valueize (valueize, _q21);
4843 : 815 : {
4844 : 815 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p0, _q20, _q21 };
4845 : 815 : const enum tree_code op = MINUS_EXPR;
4846 : 815 : gimple_seq *lseq = seq;
4847 : 815 : if (lseq
4848 : 234 : && (!single_use (captures[0])
4849 : : || !single_use (captures[1])))
4850 : : lseq = NULL;
4851 : 815 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1339;
4852 : 815 : {
4853 : 815 : res_op->set_op (NOP_EXPR, type, 1);
4854 : 815 : {
4855 : 815 : tree _o1[2], _r1;
4856 : 815 : {
4857 : 815 : tree _o2[1], _r2;
4858 : 815 : _o2[0] = captures[2];
4859 : 815 : gimple_match_op tem_op (res_op->cond.any_else (), REALPART_EXPR, TREE_TYPE (TREE_TYPE (_o2[0])), _o2[0]);
4860 : 815 : tem_op.resimplify (lseq, valueize);
4861 : 815 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
4862 : 815 : if (!_r2) goto next_after_fail1339;
4863 : 485 : _o1[0] = _r2;
4864 : : }
4865 : 485 : {
4866 : 485 : tree _o2[1], _r2;
4867 : 485 : _o2[0] = captures[3];
4868 : 485 : gimple_match_op tem_op (res_op->cond.any_else (), REALPART_EXPR, TREE_TYPE (TREE_TYPE (_o2[0])), _o2[0]);
4869 : 485 : tem_op.resimplify (lseq, valueize);
4870 : 485 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
4871 : 485 : if (!_r2) goto next_after_fail1339;
4872 : 425 : _o1[1] = _r2;
4873 : : }
4874 : 425 : gimple_match_op tem_op (res_op->cond.any_else (), op, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
4875 : 425 : tem_op.resimplify (lseq, valueize);
4876 : 425 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
4877 : 425 : if (!_r1) goto next_after_fail1339;
4878 : 2 : res_op->ops[0] = _r1;
4879 : : }
4880 : 2 : res_op->resimplify (lseq, valueize);
4881 : 2 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 897, __FILE__, __LINE__, true);
4882 : 2 : return true;
4883 : : }
4884 : 813 : next_after_fail1339:;
4885 : : }
4886 : 813 : break;
4887 : : }
4888 : : default:;
4889 : : }
4890 : 590557 : else if (gcall *_c1 = dyn_cast <gcall *> (_d1))
4891 : 564938 : switch (gimple_call_combined_fn (_c1))
4892 : : {
4893 : 153 : case CFN_BUILT_IN_CEXPIF:
4894 : 153 : if (gimple_call_num_args (_c1) == 1)
4895 : : {
4896 : 153 : tree _q20 = gimple_call_arg (_c1, 0);
4897 : 153 : _q20 = do_valueize (valueize, _q20);
4898 : 153 : {
4899 : 153 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p0, _q20 };
4900 : 153 : gimple_seq *lseq = seq;
4901 : 153 : if (lseq
4902 : 54 : && (!single_use (captures[0])
4903 : : || !single_use (captures[1])))
4904 : : lseq = NULL;
4905 : 153 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1340;
4906 : 153 : {
4907 : 153 : res_op->set_op (NOP_EXPR, type, 1);
4908 : 153 : {
4909 : 153 : tree _o1[1], _r1;
4910 : 153 : _o1[0] = captures[2];
4911 : 153 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_COSF, TREE_TYPE (_o1[0]), _o1[0]);
4912 : 153 : tem_op.resimplify (lseq, valueize);
4913 : 153 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
4914 : 153 : if (!_r1) goto next_after_fail1340;
4915 : 0 : res_op->ops[0] = _r1;
4916 : : }
4917 : 0 : res_op->resimplify (lseq, valueize);
4918 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 898, __FILE__, __LINE__, true);
4919 : 0 : return true;
4920 : : }
4921 : 153 : next_after_fail1340:;
4922 : : }
4923 : : }
4924 : : break;
4925 : 56 : case CFN_BUILT_IN_CEXPIL:
4926 : 56 : if (gimple_call_num_args (_c1) == 1)
4927 : : {
4928 : 56 : tree _q20 = gimple_call_arg (_c1, 0);
4929 : 56 : _q20 = do_valueize (valueize, _q20);
4930 : 56 : {
4931 : 56 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p0, _q20 };
4932 : 56 : gimple_seq *lseq = seq;
4933 : 56 : if (lseq
4934 : 19 : && (!single_use (captures[0])
4935 : : || !single_use (captures[1])))
4936 : : lseq = NULL;
4937 : 56 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1341;
4938 : 56 : {
4939 : 56 : res_op->set_op (NOP_EXPR, type, 1);
4940 : 56 : {
4941 : 56 : tree _o1[1], _r1;
4942 : 56 : _o1[0] = captures[2];
4943 : 56 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_COSL, TREE_TYPE (_o1[0]), _o1[0]);
4944 : 56 : tem_op.resimplify (lseq, valueize);
4945 : 56 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
4946 : 56 : if (!_r1) goto next_after_fail1341;
4947 : 0 : res_op->ops[0] = _r1;
4948 : : }
4949 : 0 : res_op->resimplify (lseq, valueize);
4950 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 898, __FILE__, __LINE__, true);
4951 : 0 : return true;
4952 : : }
4953 : 56 : next_after_fail1341:;
4954 : : }
4955 : : }
4956 : : break;
4957 : 305 : case CFN_BUILT_IN_CEXPI:
4958 : 305 : if (gimple_call_num_args (_c1) == 1)
4959 : : {
4960 : 305 : tree _q20 = gimple_call_arg (_c1, 0);
4961 : 305 : _q20 = do_valueize (valueize, _q20);
4962 : 305 : {
4963 : 305 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p0, _q20 };
4964 : 305 : gimple_seq *lseq = seq;
4965 : 305 : if (lseq
4966 : 109 : && (!single_use (captures[0])
4967 : : || !single_use (captures[1])))
4968 : : lseq = NULL;
4969 : 305 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1342;
4970 : 305 : {
4971 : 305 : res_op->set_op (NOP_EXPR, type, 1);
4972 : 305 : {
4973 : 305 : tree _o1[1], _r1;
4974 : 305 : _o1[0] = captures[2];
4975 : 305 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_COS, TREE_TYPE (_o1[0]), _o1[0]);
4976 : 305 : tem_op.resimplify (lseq, valueize);
4977 : 305 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
4978 : 305 : if (!_r1) goto next_after_fail1342;
4979 : 5 : res_op->ops[0] = _r1;
4980 : : }
4981 : 5 : res_op->resimplify (lseq, valueize);
4982 : 5 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 898, __FILE__, __LINE__, true);
4983 : 5 : return true;
4984 : : }
4985 : 300 : next_after_fail1342:;
4986 : : }
4987 : : }
4988 : : break;
4989 : : default:;
4990 : : }
4991 : : }
4992 : : break;
4993 : : default:;
4994 : : }
4995 : : return false;
4996 : : }
4997 : :
4998 : : bool
4999 : 927 : gimple_simplify_CFN_BUILT_IN_LOG2F (gimple_match_op *res_op, gimple_seq *seq,
5000 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
5001 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
5002 : : {
5003 : 927 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
5004 : 927 : switch (TREE_CODE (_p0))
5005 : : {
5006 : 575 : case SSA_NAME:
5007 : 575 : if (gimple *_d1 = get_def (valueize, _p0))
5008 : : {
5009 : 366 : if (gcall *_c1 = dyn_cast <gcall *> (_d1))
5010 : 84 : switch (gimple_call_combined_fn (_c1))
5011 : : {
5012 : 12 : case CFN_BUILT_IN_SQRTF:
5013 : 12 : if (gimple_call_num_args (_c1) == 1)
5014 : : {
5015 : 12 : tree _q20 = gimple_call_arg (_c1, 0);
5016 : 12 : _q20 = do_valueize (valueize, _q20);
5017 : 12 : {
5018 : 12 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5019 : 12 : if (flag_unsafe_math_optimizations
5020 : : )
5021 : : {
5022 : 12 : if (SCALAR_FLOAT_TYPE_P (type)
5023 : : )
5024 : : {
5025 : 12 : {
5026 : 12 : tree x;
5027 : 12 : switch (CFN_BUILT_IN_SQRTF)
5028 : : {
5029 : 12 : CASE_CFN_SQRT:
5030 : 12 : x = build_real (type, dconsthalf);
5031 : 12 : break;
5032 : : CASE_CFN_CBRT:
5033 : : x = build_real_truncate (type, dconst_third ());
5034 : : break;
5035 : : default:
5036 : : gcc_unreachable ();
5037 : : }
5038 : 12 : gimple_seq *lseq = seq;
5039 : 12 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1380;
5040 : 12 : {
5041 : 12 : res_op->set_op (MULT_EXPR, type, 2);
5042 : 12 : res_op->ops[0] = x;
5043 : 12 : {
5044 : 12 : tree _o1[1], _r1;
5045 : 12 : _o1[0] = captures[0];
5046 : 12 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_LOG2F, TREE_TYPE (_o1[0]), _o1[0]);
5047 : 12 : tem_op.resimplify (lseq, valueize);
5048 : 12 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
5049 : 12 : if (!_r1) goto next_after_fail1380;
5050 : 6 : res_op->ops[1] = _r1;
5051 : : }
5052 : 6 : res_op->resimplify (lseq, valueize);
5053 : 6 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 903, __FILE__, __LINE__, true);
5054 : 6 : return true;
5055 : : }
5056 : : next_after_fail1380:;
5057 : : }
5058 : : }
5059 : : }
5060 : : }
5061 : : }
5062 : : break;
5063 : 12 : case CFN_BUILT_IN_EXP10F:
5064 : 12 : if (gimple_call_num_args (_c1) == 1)
5065 : : {
5066 : 12 : tree _q20 = gimple_call_arg (_c1, 0);
5067 : 12 : _q20 = do_valueize (valueize, _q20);
5068 : 12 : {
5069 : 12 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5070 : 12 : if (flag_unsafe_math_optimizations
5071 : : )
5072 : : {
5073 : 12 : if (SCALAR_FLOAT_TYPE_P (type)
5074 : : )
5075 : : {
5076 : 12 : {
5077 : 12 : tree x;
5078 : 12 : switch (CFN_BUILT_IN_EXP10F)
5079 : : {
5080 : : CASE_CFN_EXP:
5081 : : x = build_real_truncate (type, dconst_e ());
5082 : : break;
5083 : : CASE_CFN_EXP2:
5084 : : x = build_real (type, dconst2);
5085 : : break;
5086 : 12 : CASE_CFN_EXP10:
5087 : 12 : CASE_CFN_POW10:
5088 : 12 : {
5089 : 12 : REAL_VALUE_TYPE dconst10;
5090 : 12 : real_from_integer (&dconst10, VOIDmode, 10, SIGNED);
5091 : 12 : x = build_real (type, dconst10);
5092 : : }
5093 : 12 : break;
5094 : : default:
5095 : : gcc_unreachable ();
5096 : : }
5097 : 12 : gimple_seq *lseq = seq;
5098 : 12 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1381;
5099 : 12 : {
5100 : 12 : res_op->set_op (MULT_EXPR, type, 2);
5101 : 12 : {
5102 : 12 : tree _o1[1], _r1;
5103 : 12 : _o1[0] = x;
5104 : 12 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_LOG2F, TREE_TYPE (_o1[0]), _o1[0]);
5105 : 12 : tem_op.resimplify (lseq, valueize);
5106 : 12 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
5107 : 12 : if (!_r1) goto next_after_fail1381;
5108 : 12 : res_op->ops[0] = _r1;
5109 : : }
5110 : 12 : res_op->ops[1] = captures[0];
5111 : 12 : res_op->resimplify (lseq, valueize);
5112 : 12 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 904, __FILE__, __LINE__, true);
5113 : 12 : return true;
5114 : : }
5115 : : next_after_fail1381:;
5116 : : }
5117 : : }
5118 : : }
5119 : : }
5120 : : }
5121 : : break;
5122 : 12 : case CFN_BUILT_IN_EXPF:
5123 : 12 : if (gimple_call_num_args (_c1) == 1)
5124 : : {
5125 : 12 : tree _q20 = gimple_call_arg (_c1, 0);
5126 : 12 : _q20 = do_valueize (valueize, _q20);
5127 : 12 : {
5128 : 12 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5129 : 12 : if (flag_unsafe_math_optimizations
5130 : : )
5131 : : {
5132 : 12 : if (SCALAR_FLOAT_TYPE_P (type)
5133 : : )
5134 : : {
5135 : 12 : {
5136 : 12 : tree x;
5137 : 12 : switch (CFN_BUILT_IN_EXPF)
5138 : : {
5139 : 12 : CASE_CFN_EXP:
5140 : 12 : x = build_real_truncate (type, dconst_e ());
5141 : 12 : break;
5142 : : CASE_CFN_EXP2:
5143 : : x = build_real (type, dconst2);
5144 : : break;
5145 : : CASE_CFN_EXP10:
5146 : : CASE_CFN_POW10:
5147 : : {
5148 : : REAL_VALUE_TYPE dconst10;
5149 : : real_from_integer (&dconst10, VOIDmode, 10, SIGNED);
5150 : : x = build_real (type, dconst10);
5151 : : }
5152 : : break;
5153 : : default:
5154 : : gcc_unreachable ();
5155 : : }
5156 : 12 : gimple_seq *lseq = seq;
5157 : 12 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1382;
5158 : 12 : {
5159 : 12 : res_op->set_op (MULT_EXPR, type, 2);
5160 : 12 : {
5161 : 12 : tree _o1[1], _r1;
5162 : 12 : _o1[0] = x;
5163 : 12 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_LOG2F, TREE_TYPE (_o1[0]), _o1[0]);
5164 : 12 : tem_op.resimplify (lseq, valueize);
5165 : 12 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
5166 : 12 : if (!_r1) goto next_after_fail1382;
5167 : 12 : res_op->ops[0] = _r1;
5168 : : }
5169 : 12 : res_op->ops[1] = captures[0];
5170 : 12 : res_op->resimplify (lseq, valueize);
5171 : 12 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 904, __FILE__, __LINE__, true);
5172 : 12 : return true;
5173 : : }
5174 : : next_after_fail1382:;
5175 : : }
5176 : : }
5177 : : }
5178 : : }
5179 : : }
5180 : : break;
5181 : 12 : case CFN_BUILT_IN_POWF:
5182 : 12 : if (gimple_call_num_args (_c1) == 2)
5183 : : {
5184 : 12 : tree _q20 = gimple_call_arg (_c1, 0);
5185 : 12 : _q20 = do_valueize (valueize, _q20);
5186 : 12 : tree _q21 = gimple_call_arg (_c1, 1);
5187 : 12 : _q21 = do_valueize (valueize, _q21);
5188 : 12 : {
5189 : 12 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
5190 : 12 : if (gimple_simplify_599 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_LOG2F, CFN_BUILT_IN_POWF))
5191 : 6 : return true;
5192 : : }
5193 : : }
5194 : : break;
5195 : 12 : case CFN_BUILT_IN_POW10F:
5196 : 12 : if (gimple_call_num_args (_c1) == 1)
5197 : : {
5198 : 12 : tree _q20 = gimple_call_arg (_c1, 0);
5199 : 12 : _q20 = do_valueize (valueize, _q20);
5200 : 12 : {
5201 : 12 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5202 : 12 : if (flag_unsafe_math_optimizations
5203 : : )
5204 : : {
5205 : 12 : if (SCALAR_FLOAT_TYPE_P (type)
5206 : : )
5207 : : {
5208 : 12 : {
5209 : 12 : tree x;
5210 : 12 : switch (CFN_BUILT_IN_POW10F)
5211 : : {
5212 : : CASE_CFN_EXP:
5213 : : x = build_real_truncate (type, dconst_e ());
5214 : : break;
5215 : : CASE_CFN_EXP2:
5216 : : x = build_real (type, dconst2);
5217 : : break;
5218 : 12 : CASE_CFN_EXP10:
5219 : 12 : CASE_CFN_POW10:
5220 : 12 : {
5221 : 12 : REAL_VALUE_TYPE dconst10;
5222 : 12 : real_from_integer (&dconst10, VOIDmode, 10, SIGNED);
5223 : 12 : x = build_real (type, dconst10);
5224 : : }
5225 : 12 : break;
5226 : : default:
5227 : : gcc_unreachable ();
5228 : : }
5229 : 12 : gimple_seq *lseq = seq;
5230 : 12 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1383;
5231 : 12 : {
5232 : 12 : res_op->set_op (MULT_EXPR, type, 2);
5233 : 12 : {
5234 : 12 : tree _o1[1], _r1;
5235 : 12 : _o1[0] = x;
5236 : 12 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_LOG2F, TREE_TYPE (_o1[0]), _o1[0]);
5237 : 12 : tem_op.resimplify (lseq, valueize);
5238 : 12 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
5239 : 12 : if (!_r1) goto next_after_fail1383;
5240 : 12 : res_op->ops[0] = _r1;
5241 : : }
5242 : 12 : res_op->ops[1] = captures[0];
5243 : 12 : res_op->resimplify (lseq, valueize);
5244 : 12 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 904, __FILE__, __LINE__, true);
5245 : 12 : return true;
5246 : : }
5247 : : next_after_fail1383:;
5248 : : }
5249 : : }
5250 : : }
5251 : : }
5252 : : }
5253 : : break;
5254 : 12 : case CFN_BUILT_IN_CBRTF:
5255 : 12 : if (gimple_call_num_args (_c1) == 1)
5256 : : {
5257 : 12 : tree _q20 = gimple_call_arg (_c1, 0);
5258 : 12 : _q20 = do_valueize (valueize, _q20);
5259 : 12 : {
5260 : 12 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5261 : 12 : if (flag_unsafe_math_optimizations
5262 : : )
5263 : : {
5264 : 12 : if (SCALAR_FLOAT_TYPE_P (type)
5265 : : )
5266 : : {
5267 : 12 : {
5268 : 12 : tree x;
5269 : 12 : switch (CFN_BUILT_IN_CBRTF)
5270 : : {
5271 : : CASE_CFN_SQRT:
5272 : : x = build_real (type, dconsthalf);
5273 : : break;
5274 : 12 : CASE_CFN_CBRT:
5275 : 12 : x = build_real_truncate (type, dconst_third ());
5276 : 12 : break;
5277 : : default:
5278 : : gcc_unreachable ();
5279 : : }
5280 : 12 : gimple_seq *lseq = seq;
5281 : 12 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1384;
5282 : 12 : {
5283 : 12 : res_op->set_op (MULT_EXPR, type, 2);
5284 : 12 : res_op->ops[0] = x;
5285 : 12 : {
5286 : 12 : tree _o1[1], _r1;
5287 : 12 : _o1[0] = captures[0];
5288 : 12 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_LOG2F, TREE_TYPE (_o1[0]), _o1[0]);
5289 : 12 : tem_op.resimplify (lseq, valueize);
5290 : 12 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
5291 : 12 : if (!_r1) goto next_after_fail1384;
5292 : 6 : res_op->ops[1] = _r1;
5293 : : }
5294 : 6 : res_op->resimplify (lseq, valueize);
5295 : 6 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 903, __FILE__, __LINE__, true);
5296 : 6 : return true;
5297 : : }
5298 : : next_after_fail1384:;
5299 : : }
5300 : : }
5301 : : }
5302 : : }
5303 : : }
5304 : : break;
5305 : 12 : case CFN_BUILT_IN_EXP2F:
5306 : 12 : if (gimple_call_num_args (_c1) == 1)
5307 : : {
5308 : 12 : tree _q20 = gimple_call_arg (_c1, 0);
5309 : 12 : _q20 = do_valueize (valueize, _q20);
5310 : 12 : {
5311 : 12 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5312 : 12 : if (flag_unsafe_math_optimizations
5313 : : )
5314 : : {
5315 : 12 : gimple_seq *lseq = seq;
5316 : 12 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1385;
5317 : 12 : {
5318 : 12 : tree tem;
5319 : 12 : tem = captures[0];
5320 : 12 : res_op->set_value (tem);
5321 : 12 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 905, __FILE__, __LINE__, true);
5322 : 12 : return true;
5323 : : }
5324 : 0 : next_after_fail1385:;
5325 : : }
5326 : : }
5327 : : }
5328 : : break;
5329 : : default:;
5330 : : }
5331 : : }
5332 : : break;
5333 : : default:;
5334 : : }
5335 : : return false;
5336 : : }
5337 : :
5338 : : bool
5339 : 8962 : gimple_simplify_CFN_BUILT_IN_EXP (gimple_match_op *res_op, gimple_seq *seq,
5340 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
5341 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
5342 : : {
5343 : 8962 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
5344 : 8962 : switch (TREE_CODE (_p0))
5345 : : {
5346 : 8640 : case SSA_NAME:
5347 : 8640 : if (gimple *_d1 = get_def (valueize, _p0))
5348 : : {
5349 : 4628 : if (gcall *_c1 = dyn_cast <gcall *> (_d1))
5350 : 242 : switch (gimple_call_combined_fn (_c1))
5351 : : {
5352 : 15 : case CFN_BUILT_IN_LOG:
5353 : 15 : if (gimple_call_num_args (_c1) == 1)
5354 : : {
5355 : 15 : tree _q20 = gimple_call_arg (_c1, 0);
5356 : 15 : _q20 = do_valueize (valueize, _q20);
5357 : 15 : {
5358 : 15 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5359 : 15 : if (flag_unsafe_math_optimizations
5360 : : )
5361 : : {
5362 : 7 : gimple_seq *lseq = seq;
5363 : 7 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1425;
5364 : 7 : {
5365 : 7 : tree tem;
5366 : 7 : tem = captures[0];
5367 : 7 : res_op->set_value (tem);
5368 : 7 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 906, __FILE__, __LINE__, true);
5369 : 7 : return true;
5370 : : }
5371 : 0 : next_after_fail1425:;
5372 : : }
5373 : : }
5374 : : }
5375 : : break;
5376 : : default:;
5377 : : }
5378 : : }
5379 : : break;
5380 : : default:;
5381 : : }
5382 : : return false;
5383 : : }
5384 : :
5385 : : bool
5386 : 1515 : gimple_simplify_CFN_BUILT_IN_EXP2F (gimple_match_op *res_op, gimple_seq *seq,
5387 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
5388 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
5389 : : {
5390 : 1515 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
5391 : 1515 : switch (TREE_CODE (_p0))
5392 : : {
5393 : 531 : case SSA_NAME:
5394 : 531 : if (gimple *_d1 = get_def (valueize, _p0))
5395 : : {
5396 : 348 : if (gcall *_c1 = dyn_cast <gcall *> (_d1))
5397 : 6 : switch (gimple_call_combined_fn (_c1))
5398 : : {
5399 : 6 : case CFN_BUILT_IN_LOG2F:
5400 : 6 : if (gimple_call_num_args (_c1) == 1)
5401 : : {
5402 : 6 : tree _q20 = gimple_call_arg (_c1, 0);
5403 : 6 : _q20 = do_valueize (valueize, _q20);
5404 : 6 : {
5405 : 6 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5406 : 6 : if (flag_unsafe_math_optimizations
5407 : : )
5408 : : {
5409 : 6 : gimple_seq *lseq = seq;
5410 : 6 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1428;
5411 : 6 : {
5412 : 6 : tree tem;
5413 : 6 : tem = captures[0];
5414 : 6 : res_op->set_value (tem);
5415 : 6 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 906, __FILE__, __LINE__, true);
5416 : 6 : return true;
5417 : : }
5418 : 0 : next_after_fail1428:;
5419 : : }
5420 : : }
5421 : : }
5422 : : break;
5423 : : default:;
5424 : : }
5425 : : }
5426 : : break;
5427 : : default:;
5428 : : }
5429 : : return false;
5430 : : }
5431 : :
5432 : : bool
5433 : 296 : gimple_simplify_CFN_BUILT_IN_EXP10F (gimple_match_op *res_op, gimple_seq *seq,
5434 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
5435 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
5436 : : {
5437 : 296 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
5438 : 296 : switch (TREE_CODE (_p0))
5439 : : {
5440 : 246 : case SSA_NAME:
5441 : 246 : if (gimple *_d1 = get_def (valueize, _p0))
5442 : : {
5443 : 170 : if (gcall *_c1 = dyn_cast <gcall *> (_d1))
5444 : 6 : switch (gimple_call_combined_fn (_c1))
5445 : : {
5446 : 6 : case CFN_BUILT_IN_LOG10F:
5447 : 6 : if (gimple_call_num_args (_c1) == 1)
5448 : : {
5449 : 6 : tree _q20 = gimple_call_arg (_c1, 0);
5450 : 6 : _q20 = do_valueize (valueize, _q20);
5451 : 6 : {
5452 : 6 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5453 : 6 : if (flag_unsafe_math_optimizations
5454 : : )
5455 : : {
5456 : 6 : gimple_seq *lseq = seq;
5457 : 6 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1432;
5458 : 6 : {
5459 : 6 : tree tem;
5460 : 6 : tem = captures[0];
5461 : 6 : res_op->set_value (tem);
5462 : 6 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 906, __FILE__, __LINE__, true);
5463 : 6 : return true;
5464 : : }
5465 : 0 : next_after_fail1432:;
5466 : : }
5467 : : }
5468 : : }
5469 : : break;
5470 : : default:;
5471 : : }
5472 : : }
5473 : : break;
5474 : : default:;
5475 : : }
5476 : : return false;
5477 : : }
5478 : :
5479 : : bool
5480 : 23957 : gimple_simplify_CFN_BUILT_IN_SQRT (gimple_match_op *res_op, gimple_seq *seq,
5481 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
5482 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
5483 : : {
5484 : 23957 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
5485 : 23957 : switch (TREE_CODE (_p0))
5486 : : {
5487 : 22921 : case SSA_NAME:
5488 : 22921 : if (gimple *_d1 = get_def (valueize, _p0))
5489 : : {
5490 : 10563 : if (gcall *_c1 = dyn_cast <gcall *> (_d1))
5491 : 330 : switch (gimple_call_combined_fn (_c1))
5492 : : {
5493 : 14 : case CFN_BUILT_IN_EXP:
5494 : 14 : if (gimple_call_num_args (_c1) == 1)
5495 : : {
5496 : 14 : tree _q20 = gimple_call_arg (_c1, 0);
5497 : 14 : _q20 = do_valueize (valueize, _q20);
5498 : 14 : {
5499 : 14 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5500 : 14 : if (flag_unsafe_math_optimizations
5501 : : )
5502 : : {
5503 : 14 : gimple_seq *lseq = seq;
5504 : 14 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1446;
5505 : 14 : {
5506 : 14 : res_op->set_op (CFN_BUILT_IN_EXP, type, 1);
5507 : 14 : {
5508 : 14 : tree _o1[2], _r1;
5509 : 14 : _o1[0] = captures[0];
5510 : 14 : _o1[1] = build_real (type, dconsthalf);
5511 : 14 : gimple_match_op tem_op (res_op->cond.any_else (), MULT_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
5512 : 14 : tem_op.resimplify (lseq, valueize);
5513 : 14 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
5514 : 14 : if (!_r1) goto next_after_fail1446;
5515 : 7 : res_op->ops[0] = _r1;
5516 : : }
5517 : 7 : res_op->resimplify (lseq, valueize);
5518 : 7 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 908, __FILE__, __LINE__, true);
5519 : 7 : return true;
5520 : : }
5521 : : next_after_fail1446:;
5522 : : }
5523 : : }
5524 : : }
5525 : : break;
5526 : 18 : case CFN_BUILT_IN_POW:
5527 : 18 : if (gimple_call_num_args (_c1) == 2)
5528 : : {
5529 : 18 : tree _q20 = gimple_call_arg (_c1, 0);
5530 : 18 : _q20 = do_valueize (valueize, _q20);
5531 : 18 : tree _q21 = gimple_call_arg (_c1, 1);
5532 : 18 : _q21 = do_valueize (valueize, _q21);
5533 : 18 : {
5534 : 18 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
5535 : 18 : if (flag_unsafe_math_optimizations && canonicalize_math_p ()
5536 : : )
5537 : : {
5538 : 18 : gimple_seq *lseq = seq;
5539 : 18 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1447;
5540 : 18 : {
5541 : 18 : res_op->set_op (CFN_BUILT_IN_POW, type, 2);
5542 : 18 : {
5543 : 18 : tree _o1[1], _r1;
5544 : 18 : _o1[0] = captures[0];
5545 : 18 : gimple_match_op tem_op (res_op->cond.any_else (), ABS_EXPR, TREE_TYPE (_o1[0]), _o1[0]);
5546 : 18 : tem_op.resimplify (lseq, valueize);
5547 : 18 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
5548 : 18 : if (!_r1) goto next_after_fail1447;
5549 : 15 : res_op->ops[0] = _r1;
5550 : : }
5551 : 15 : {
5552 : 15 : tree _o1[2], _r1;
5553 : 15 : _o1[0] = captures[1];
5554 : 15 : _o1[1] = build_real (type, dconsthalf);
5555 : 15 : gimple_match_op tem_op (res_op->cond.any_else (), MULT_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
5556 : 15 : tem_op.resimplify (lseq, valueize);
5557 : 15 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
5558 : 15 : if (!_r1) goto next_after_fail1447;
5559 : 9 : res_op->ops[1] = _r1;
5560 : : }
5561 : 9 : res_op->resimplify (lseq, valueize);
5562 : 9 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 909, __FILE__, __LINE__, true);
5563 : 9 : return true;
5564 : : }
5565 : 9 : next_after_fail1447:;
5566 : : }
5567 : : }
5568 : : }
5569 : : break;
5570 : 12 : case CFN_BUILT_IN_CBRT:
5571 : 12 : if (gimple_call_num_args (_c1) == 1)
5572 : : {
5573 : 12 : tree _q20 = gimple_call_arg (_c1, 0);
5574 : 12 : _q20 = do_valueize (valueize, _q20);
5575 : 12 : {
5576 : 12 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5577 : 12 : if (flag_unsafe_math_optimizations && canonicalize_math_p ()
5578 : : )
5579 : : {
5580 : 12 : gimple_seq *lseq = seq;
5581 : 12 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1448;
5582 : 12 : {
5583 : 12 : res_op->set_op (CFN_BUILT_IN_POW, type, 2);
5584 : 12 : res_op->ops[0] = captures[0];
5585 : 12 : res_op->ops[1] = build_real_truncate (type, dconst_sixth ());
5586 : 12 : res_op->resimplify (lseq, valueize);
5587 : 12 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 910, __FILE__, __LINE__, true);
5588 : 12 : return true;
5589 : : }
5590 : 0 : next_after_fail1448:;
5591 : : }
5592 : : }
5593 : : }
5594 : : break;
5595 : 12 : case CFN_BUILT_IN_EXP2:
5596 : 12 : if (gimple_call_num_args (_c1) == 1)
5597 : : {
5598 : 12 : tree _q20 = gimple_call_arg (_c1, 0);
5599 : 12 : _q20 = do_valueize (valueize, _q20);
5600 : 12 : {
5601 : 12 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5602 : 12 : if (flag_unsafe_math_optimizations
5603 : : )
5604 : : {
5605 : 12 : gimple_seq *lseq = seq;
5606 : 12 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1449;
5607 : 12 : {
5608 : 12 : res_op->set_op (CFN_BUILT_IN_EXP2, type, 1);
5609 : 12 : {
5610 : 12 : tree _o1[2], _r1;
5611 : 12 : _o1[0] = captures[0];
5612 : 12 : _o1[1] = build_real (type, dconsthalf);
5613 : 12 : gimple_match_op tem_op (res_op->cond.any_else (), MULT_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
5614 : 12 : tem_op.resimplify (lseq, valueize);
5615 : 12 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
5616 : 12 : if (!_r1) goto next_after_fail1449;
5617 : 6 : res_op->ops[0] = _r1;
5618 : : }
5619 : 6 : res_op->resimplify (lseq, valueize);
5620 : 6 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 908, __FILE__, __LINE__, true);
5621 : 6 : return true;
5622 : : }
5623 : : next_after_fail1449:;
5624 : : }
5625 : : }
5626 : : }
5627 : : break;
5628 : 62 : case CFN_BUILT_IN_SQRT:
5629 : 62 : if (gimple_call_num_args (_c1) == 1)
5630 : : {
5631 : 62 : tree _q20 = gimple_call_arg (_c1, 0);
5632 : 62 : _q20 = do_valueize (valueize, _q20);
5633 : 62 : {
5634 : 62 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5635 : 62 : if (flag_unsafe_math_optimizations && canonicalize_math_p ()
5636 : : )
5637 : : {
5638 : 12 : gimple_seq *lseq = seq;
5639 : 12 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1450;
5640 : 12 : {
5641 : 12 : res_op->set_op (CFN_BUILT_IN_POW, type, 2);
5642 : 12 : res_op->ops[0] = captures[0];
5643 : 12 : res_op->ops[1] = build_real (type, dconst_quarter ());
5644 : 12 : res_op->resimplify (lseq, valueize);
5645 : 12 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 907, __FILE__, __LINE__, true);
5646 : 12 : return true;
5647 : : }
5648 : 0 : next_after_fail1450:;
5649 : : }
5650 : : }
5651 : : }
5652 : : break;
5653 : 12 : case CFN_BUILT_IN_EXP10:
5654 : 12 : if (gimple_call_num_args (_c1) == 1)
5655 : : {
5656 : 12 : tree _q20 = gimple_call_arg (_c1, 0);
5657 : 12 : _q20 = do_valueize (valueize, _q20);
5658 : 12 : {
5659 : 12 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5660 : 12 : if (flag_unsafe_math_optimizations
5661 : : )
5662 : : {
5663 : 12 : gimple_seq *lseq = seq;
5664 : 12 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1451;
5665 : 12 : {
5666 : 12 : res_op->set_op (CFN_BUILT_IN_EXP10, type, 1);
5667 : 12 : {
5668 : 12 : tree _o1[2], _r1;
5669 : 12 : _o1[0] = captures[0];
5670 : 12 : _o1[1] = build_real (type, dconsthalf);
5671 : 12 : gimple_match_op tem_op (res_op->cond.any_else (), MULT_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
5672 : 12 : tem_op.resimplify (lseq, valueize);
5673 : 12 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
5674 : 12 : if (!_r1) goto next_after_fail1451;
5675 : 6 : res_op->ops[0] = _r1;
5676 : : }
5677 : 6 : res_op->resimplify (lseq, valueize);
5678 : 6 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 908, __FILE__, __LINE__, true);
5679 : 6 : return true;
5680 : : }
5681 : : next_after_fail1451:;
5682 : : }
5683 : : }
5684 : : }
5685 : : break;
5686 : 12 : case CFN_BUILT_IN_POW10:
5687 : 12 : if (gimple_call_num_args (_c1) == 1)
5688 : : {
5689 : 12 : tree _q20 = gimple_call_arg (_c1, 0);
5690 : 12 : _q20 = do_valueize (valueize, _q20);
5691 : 12 : {
5692 : 12 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5693 : 12 : if (flag_unsafe_math_optimizations
5694 : : )
5695 : : {
5696 : 12 : gimple_seq *lseq = seq;
5697 : 12 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1452;
5698 : 12 : {
5699 : 12 : res_op->set_op (CFN_BUILT_IN_POW10, type, 1);
5700 : 12 : {
5701 : 12 : tree _o1[2], _r1;
5702 : 12 : _o1[0] = captures[0];
5703 : 12 : _o1[1] = build_real (type, dconsthalf);
5704 : 12 : gimple_match_op tem_op (res_op->cond.any_else (), MULT_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
5705 : 12 : tem_op.resimplify (lseq, valueize);
5706 : 12 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
5707 : 12 : if (!_r1) goto next_after_fail1452;
5708 : 6 : res_op->ops[0] = _r1;
5709 : : }
5710 : 6 : res_op->resimplify (lseq, valueize);
5711 : 6 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 908, __FILE__, __LINE__, true);
5712 : 6 : return true;
5713 : : }
5714 : : next_after_fail1452:;
5715 : : }
5716 : : }
5717 : : }
5718 : : break;
5719 : : default:;
5720 : : }
5721 : : }
5722 : : break;
5723 : : default:;
5724 : : }
5725 : : return false;
5726 : : }
5727 : :
5728 : : bool
5729 : 1687 : gimple_simplify_CFN_BUILT_IN_TRUNC (gimple_match_op *res_op, gimple_seq *seq,
5730 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
5731 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
5732 : : {
5733 : 1687 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
5734 : 1687 : switch (TREE_CODE (_p0))
5735 : : {
5736 : 1631 : case SSA_NAME:
5737 : 1631 : if (gimple *_d1 = get_def (valueize, _p0))
5738 : : {
5739 : 959 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
5740 : 1096 : switch (gimple_assign_rhs_code (_a1))
5741 : : {
5742 : 114 : CASE_CONVERT:
5743 : 114 : {
5744 : 114 : tree _q20 = gimple_assign_rhs1 (_a1);
5745 : 114 : _q20 = do_valueize (valueize, _q20);
5746 : 114 : if (gimple_float_value_p (_q20, valueize))
5747 : : {
5748 : 70 : {
5749 : 70 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5750 : 70 : if (gimple_simplify_605 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_TRUNC, CFN_BUILT_IN_TRUNCF))
5751 : 35 : return true;
5752 : : }
5753 : : }
5754 : : break;
5755 : : }
5756 : : default:;
5757 : : }
5758 : 290 : else if (gcall *_c1 = dyn_cast <gcall *> (_d1))
5759 : 0 : switch (gimple_call_combined_fn (_c1))
5760 : : {
5761 : 0 : case CFN_BUILT_IN_TRUNC:
5762 : 0 : if (gimple_call_num_args (_c1) == 1)
5763 : : {
5764 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
5765 : 0 : _q20 = do_valueize (valueize, _q20);
5766 : 0 : {
5767 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5768 : 0 : if (gimple_simplify_603 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_TRUNC))
5769 : 0 : return true;
5770 : : }
5771 : : }
5772 : : break;
5773 : : default:;
5774 : : }
5775 : : }
5776 : : break;
5777 : 1652 : default:;
5778 : : }
5779 : 1652 : if (integer_valued_real_p (_p0))
5780 : : {
5781 : 10 : {
5782 : 10 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
5783 : 10 : if (gimple_simplify_604 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_TRUNC))
5784 : 10 : return true;
5785 : : }
5786 : : }
5787 : : return false;
5788 : : }
5789 : :
5790 : : bool
5791 : 5156 : gimple_simplify_CFN_BUILT_IN_FLOOR (gimple_match_op *res_op, gimple_seq *seq,
5792 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
5793 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
5794 : : {
5795 : 5156 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
5796 : 5156 : switch (TREE_CODE (_p0))
5797 : : {
5798 : 5066 : case SSA_NAME:
5799 : 5066 : if (gimple *_d1 = get_def (valueize, _p0))
5800 : : {
5801 : 2668 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
5802 : 2915 : switch (gimple_assign_rhs_code (_a1))
5803 : : {
5804 : 188 : CASE_CONVERT:
5805 : 188 : {
5806 : 188 : tree _q20 = gimple_assign_rhs1 (_a1);
5807 : 188 : _q20 = do_valueize (valueize, _q20);
5808 : 188 : if (gimple_float_value_p (_q20, valueize))
5809 : : {
5810 : 96 : {
5811 : 96 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5812 : 96 : if (gimple_simplify_605 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_FLOOR, CFN_BUILT_IN_FLOORF))
5813 : 48 : return true;
5814 : : }
5815 : : }
5816 : : break;
5817 : : }
5818 : : default:;
5819 : : }
5820 : 394 : else if (gcall *_c1 = dyn_cast <gcall *> (_d1))
5821 : 0 : switch (gimple_call_combined_fn (_c1))
5822 : : {
5823 : 0 : case CFN_BUILT_IN_FLOOR:
5824 : 0 : if (gimple_call_num_args (_c1) == 1)
5825 : : {
5826 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
5827 : 0 : _q20 = do_valueize (valueize, _q20);
5828 : 0 : {
5829 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5830 : 0 : if (gimple_simplify_603 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_FLOOR))
5831 : 0 : return true;
5832 : : }
5833 : : }
5834 : : break;
5835 : : default:;
5836 : : }
5837 : : }
5838 : : break;
5839 : 5108 : default:;
5840 : : }
5841 : 5108 : if (integer_valued_real_p (_p0))
5842 : : {
5843 : 14 : {
5844 : 14 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
5845 : 14 : if (gimple_simplify_604 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_FLOOR))
5846 : 14 : return true;
5847 : : }
5848 : : }
5849 : 5094 : if (tree_expr_nonnegative_p (_p0))
5850 : : {
5851 : 34 : {
5852 : 34 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
5853 : 34 : if (gimple_simplify_607 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_FLOOR, CFN_BUILT_IN_TRUNC))
5854 : 34 : return true;
5855 : : }
5856 : : }
5857 : : return false;
5858 : : }
5859 : :
5860 : : bool
5861 : 154 : gimple_simplify_CFN_BUILT_IN_CEILF16 (gimple_match_op *res_op, gimple_seq *seq,
5862 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
5863 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
5864 : : {
5865 : 154 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
5866 : 154 : switch (TREE_CODE (_p0))
5867 : : {
5868 : 152 : case SSA_NAME:
5869 : 152 : if (gimple *_d1 = get_def (valueize, _p0))
5870 : : {
5871 : 100 : if (gcall *_c1 = dyn_cast <gcall *> (_d1))
5872 : 0 : switch (gimple_call_combined_fn (_c1))
5873 : : {
5874 : 0 : case CFN_BUILT_IN_CEILF16:
5875 : 0 : if (gimple_call_num_args (_c1) == 1)
5876 : : {
5877 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
5878 : 0 : _q20 = do_valueize (valueize, _q20);
5879 : 0 : {
5880 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5881 : 0 : if (gimple_simplify_603 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_CEILF16))
5882 : 0 : return true;
5883 : : }
5884 : : }
5885 : : break;
5886 : : default:;
5887 : : }
5888 : : }
5889 : : break;
5890 : 154 : default:;
5891 : : }
5892 : 154 : if (integer_valued_real_p (_p0))
5893 : : {
5894 : 0 : {
5895 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
5896 : 0 : if (gimple_simplify_604 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_CEILF16))
5897 : 0 : return true;
5898 : : }
5899 : : }
5900 : : return false;
5901 : : }
5902 : :
5903 : : bool
5904 : 213 : gimple_simplify_CFN_CEIL (gimple_match_op *res_op, gimple_seq *seq,
5905 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
5906 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
5907 : : {
5908 : 213 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
5909 : 213 : switch (TREE_CODE (_p0))
5910 : : {
5911 : 213 : case SSA_NAME:
5912 : 213 : if (gimple *_d1 = get_def (valueize, _p0))
5913 : : {
5914 : 123 : if (gcall *_c1 = dyn_cast <gcall *> (_d1))
5915 : 0 : switch (gimple_call_combined_fn (_c1))
5916 : : {
5917 : 0 : case CFN_CEIL:
5918 : 0 : if (gimple_call_num_args (_c1) == 1)
5919 : : {
5920 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
5921 : 0 : _q20 = do_valueize (valueize, _q20);
5922 : 0 : {
5923 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5924 : 0 : if (gimple_simplify_603 (res_op, seq, valueize, type, captures, CFN_CEIL))
5925 : 0 : return true;
5926 : : }
5927 : : }
5928 : : break;
5929 : : default:;
5930 : : }
5931 : : }
5932 : : break;
5933 : 213 : default:;
5934 : : }
5935 : 213 : if (integer_valued_real_p (_p0))
5936 : : {
5937 : 0 : {
5938 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
5939 : 0 : if (gimple_simplify_604 (res_op, seq, valueize, type, captures, CFN_CEIL))
5940 : 0 : return true;
5941 : : }
5942 : : }
5943 : : return false;
5944 : : }
5945 : :
5946 : : bool
5947 : 0 : gimple_simplify_CFN_BUILT_IN_ROUNDF64X (gimple_match_op *res_op, gimple_seq *seq,
5948 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
5949 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
5950 : : {
5951 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
5952 : 0 : switch (TREE_CODE (_p0))
5953 : : {
5954 : 0 : case SSA_NAME:
5955 : 0 : if (gimple *_d1 = get_def (valueize, _p0))
5956 : : {
5957 : 0 : if (gcall *_c1 = dyn_cast <gcall *> (_d1))
5958 : 0 : switch (gimple_call_combined_fn (_c1))
5959 : : {
5960 : 0 : case CFN_BUILT_IN_ROUNDF64X:
5961 : 0 : if (gimple_call_num_args (_c1) == 1)
5962 : : {
5963 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
5964 : 0 : _q20 = do_valueize (valueize, _q20);
5965 : 0 : {
5966 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
5967 : 0 : if (gimple_simplify_603 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_ROUNDF64X))
5968 : 0 : return true;
5969 : : }
5970 : : }
5971 : : break;
5972 : : default:;
5973 : : }
5974 : : }
5975 : : break;
5976 : 0 : default:;
5977 : : }
5978 : 0 : if (integer_valued_real_p (_p0))
5979 : : {
5980 : 0 : {
5981 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
5982 : 0 : if (gimple_simplify_604 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_ROUNDF64X))
5983 : 0 : return true;
5984 : : }
5985 : : }
5986 : : return false;
5987 : : }
5988 : :
5989 : : bool
5990 : 0 : gimple_simplify_CFN_BUILT_IN_NEARBYINTF64 (gimple_match_op *res_op, gimple_seq *seq,
5991 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
5992 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
5993 : : {
5994 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
5995 : 0 : switch (TREE_CODE (_p0))
5996 : : {
5997 : 0 : case SSA_NAME:
5998 : 0 : if (gimple *_d1 = get_def (valueize, _p0))
5999 : : {
6000 : 0 : if (gcall *_c1 = dyn_cast <gcall *> (_d1))
6001 : 0 : switch (gimple_call_combined_fn (_c1))
6002 : : {
6003 : 0 : case CFN_BUILT_IN_NEARBYINTF64:
6004 : 0 : if (gimple_call_num_args (_c1) == 1)
6005 : : {
6006 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
6007 : 0 : _q20 = do_valueize (valueize, _q20);
6008 : 0 : {
6009 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
6010 : 0 : if (gimple_simplify_603 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_NEARBYINTF64))
6011 : 0 : return true;
6012 : : }
6013 : : }
6014 : : break;
6015 : : default:;
6016 : : }
6017 : : }
6018 : : break;
6019 : 0 : default:;
6020 : : }
6021 : 0 : if (integer_valued_real_p (_p0))
6022 : : {
6023 : 0 : {
6024 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
6025 : 0 : if (gimple_simplify_604 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_NEARBYINTF64))
6026 : 0 : return true;
6027 : : }
6028 : : }
6029 : : return false;
6030 : : }
6031 : :
6032 : : bool
6033 : 1589 : gimple_simplify_CFN_BUILT_IN_RINT (gimple_match_op *res_op, gimple_seq *seq,
6034 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
6035 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
6036 : : {
6037 : 1589 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
6038 : 1589 : switch (TREE_CODE (_p0))
6039 : : {
6040 : 1166 : case SSA_NAME:
6041 : 1166 : if (gimple *_d1 = get_def (valueize, _p0))
6042 : : {
6043 : 704 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
6044 : 634 : switch (gimple_assign_rhs_code (_a1))
6045 : : {
6046 : 104 : CASE_CONVERT:
6047 : 104 : {
6048 : 104 : tree _q20 = gimple_assign_rhs1 (_a1);
6049 : 104 : _q20 = do_valueize (valueize, _q20);
6050 : 104 : if (gimple_float_value_p (_q20, valueize))
6051 : : {
6052 : 60 : {
6053 : 60 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
6054 : 60 : if (gimple_simplify_605 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_RINT, CFN_BUILT_IN_RINTF))
6055 : 30 : return true;
6056 : : }
6057 : : }
6058 : : break;
6059 : : }
6060 : : default:;
6061 : : }
6062 : 326 : else if (gcall *_c1 = dyn_cast <gcall *> (_d1))
6063 : 0 : switch (gimple_call_combined_fn (_c1))
6064 : : {
6065 : 0 : case CFN_BUILT_IN_RINT:
6066 : 0 : if (gimple_call_num_args (_c1) == 1)
6067 : : {
6068 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
6069 : 0 : _q20 = do_valueize (valueize, _q20);
6070 : 0 : {
6071 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
6072 : 0 : if (gimple_simplify_603 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_RINT))
6073 : 0 : return true;
6074 : : }
6075 : : }
6076 : : break;
6077 : : default:;
6078 : : }
6079 : : }
6080 : : break;
6081 : 1559 : default:;
6082 : : }
6083 : 1559 : if (integer_valued_real_p (_p0))
6084 : : {
6085 : 28 : {
6086 : 28 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
6087 : 28 : if (gimple_simplify_604 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_RINT))
6088 : 28 : return true;
6089 : : }
6090 : : }
6091 : : return false;
6092 : : }
6093 : :
6094 : : bool
6095 : 327 : gimple_simplify_CFN_BUILT_IN_CEXPL (gimple_match_op *res_op, gimple_seq *seq,
6096 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
6097 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
6098 : : {
6099 : 327 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
6100 : 327 : if (gimple_compositional_complex (_p0, valueize))
6101 : : {
6102 : 4 : {
6103 : 4 : tree captures[3] ATTRIBUTE_UNUSED = { _p0 };
6104 : 4 : if (flag_unsafe_math_optimizations && canonicalize_math_p ()
6105 : : )
6106 : : {
6107 : 0 : if (targetm.libc_has_function (function_c99_math_complex, TREE_TYPE (captures[0]))
6108 : : )
6109 : : {
6110 : 0 : gimple_seq *lseq = seq;
6111 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1488;
6112 : 0 : {
6113 : 0 : res_op->set_op (COMPLEX_EXPR, type, 2);
6114 : 0 : {
6115 : 0 : tree _o1[2], _r1;
6116 : 0 : {
6117 : 0 : tree _o2[1], _r2;
6118 : 0 : {
6119 : 0 : tree _o3[1], _r3;
6120 : 0 : _o3[0] = captures[0];
6121 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), REALPART_EXPR, TREE_TYPE (TREE_TYPE (_o3[0])), _o3[0]);
6122 : 0 : tem_op.resimplify (lseq, valueize);
6123 : 0 : _r3 = maybe_push_res_to_seq (&tem_op, lseq);
6124 : 0 : if (!_r3) goto next_after_fail1488;
6125 : 0 : _o2[0] = _r3;
6126 : : }
6127 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_EXPL, TREE_TYPE (_o2[0]), _o2[0]);
6128 : 0 : tem_op.resimplify (lseq, valueize);
6129 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
6130 : 0 : if (!_r2) goto next_after_fail1488;
6131 : 0 : captures[1] = _r2;
6132 : : }
6133 : 0 : _o1[0] = captures[1];
6134 : 0 : {
6135 : 0 : tree _o2[1], _r2;
6136 : 0 : {
6137 : 0 : tree _o3[1], _r3;
6138 : 0 : {
6139 : 0 : tree _o4[1], _r4;
6140 : 0 : _o4[0] = captures[0];
6141 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), IMAGPART_EXPR, TREE_TYPE (TREE_TYPE (_o4[0])), _o4[0]);
6142 : 0 : tem_op.resimplify (lseq, valueize);
6143 : 0 : _r4 = maybe_push_res_to_seq (&tem_op, lseq);
6144 : 0 : if (!_r4) goto next_after_fail1488;
6145 : 0 : _o3[0] = _r4;
6146 : : }
6147 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_CEXPIL, type, _o3[0]);
6148 : 0 : tem_op.resimplify (lseq, valueize);
6149 : 0 : _r3 = maybe_push_res_to_seq (&tem_op, lseq);
6150 : 0 : if (!_r3) goto next_after_fail1488;
6151 : 0 : captures[2] = _r3;
6152 : : }
6153 : 0 : _o2[0] = captures[2];
6154 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), REALPART_EXPR, TREE_TYPE (TREE_TYPE (_o2[0])), _o2[0]);
6155 : 0 : tem_op.resimplify (lseq, valueize);
6156 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
6157 : 0 : if (!_r2) goto next_after_fail1488;
6158 : 0 : _o1[1] = _r2;
6159 : : }
6160 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), MULT_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
6161 : 0 : tem_op.resimplify (lseq, valueize);
6162 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
6163 : 0 : if (!_r1) goto next_after_fail1488;
6164 : 0 : res_op->ops[0] = _r1;
6165 : : }
6166 : 0 : {
6167 : 0 : tree _o1[2], _r1;
6168 : 0 : _o1[0] = captures[1];
6169 : 0 : {
6170 : 0 : tree _o2[1], _r2;
6171 : 0 : _o2[0] = captures[2];
6172 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), IMAGPART_EXPR, TREE_TYPE (TREE_TYPE (_o2[0])), _o2[0]);
6173 : 0 : tem_op.resimplify (lseq, valueize);
6174 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
6175 : 0 : if (!_r2) goto next_after_fail1488;
6176 : 0 : _o1[1] = _r2;
6177 : : }
6178 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), MULT_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
6179 : 0 : tem_op.resimplify (lseq, valueize);
6180 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
6181 : 0 : if (!_r1) goto next_after_fail1488;
6182 : 0 : res_op->ops[1] = _r1;
6183 : : }
6184 : 0 : res_op->resimplify (lseq, valueize);
6185 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 915, __FILE__, __LINE__, true);
6186 : 0 : return true;
6187 : : }
6188 : : next_after_fail1488:;
6189 : : }
6190 : : }
6191 : : }
6192 : : }
6193 : : return false;
6194 : : }
6195 : :
6196 : : bool
6197 : 185 : gimple_simplify_CFN_BUILT_IN_ICEIL (gimple_match_op *res_op, gimple_seq *seq,
6198 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
6199 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
6200 : : {
6201 : 185 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
6202 : 185 : switch (TREE_CODE (_p0))
6203 : : {
6204 : 184 : case SSA_NAME:
6205 : 184 : if (gimple *_d1 = get_def (valueize, _p0))
6206 : : {
6207 : 92 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
6208 : 184 : switch (gimple_assign_rhs_code (_a1))
6209 : : {
6210 : 0 : CASE_CONVERT:
6211 : 0 : {
6212 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
6213 : 0 : _q20 = do_valueize (valueize, _q20);
6214 : 0 : if (gimple_float_value_p (_q20, valueize))
6215 : : {
6216 : 0 : {
6217 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
6218 : 0 : if (gimple_simplify_611 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_ICEIL, CFN_BUILT_IN_ICEILF))
6219 : 0 : return true;
6220 : : }
6221 : : }
6222 : : break;
6223 : : }
6224 : : default:;
6225 : : }
6226 : : }
6227 : : break;
6228 : 185 : default:;
6229 : : }
6230 : 185 : if (integer_valued_real_p (_p0))
6231 : : {
6232 : 0 : {
6233 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
6234 : 0 : if (gimple_simplify_613 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_ICEIL))
6235 : 0 : return true;
6236 : : }
6237 : : }
6238 : 185 : {
6239 : 185 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
6240 : 185 : if (gimple_simplify_614 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_ICEIL, CFN_BUILT_IN_LCEIL, CFN_BUILT_IN_LLCEIL))
6241 : 0 : return true;
6242 : : }
6243 : 185 : return false;
6244 : : }
6245 : :
6246 : : bool
6247 : 183 : gimple_simplify_CFN_BUILT_IN_IFLOORF (gimple_match_op *res_op, gimple_seq *seq,
6248 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
6249 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
6250 : : {
6251 : 183 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
6252 : 183 : if (tree_expr_nonnegative_p (_p0))
6253 : : {
6254 : 0 : {
6255 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
6256 : 0 : if (gimple_simplify_612 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_IFLOORF))
6257 : 0 : return true;
6258 : : }
6259 : : }
6260 : 183 : if (integer_valued_real_p (_p0))
6261 : : {
6262 : 0 : {
6263 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
6264 : 0 : if (gimple_simplify_613 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_IFLOORF))
6265 : 0 : return true;
6266 : : }
6267 : : }
6268 : 183 : {
6269 : 183 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
6270 : 183 : if (gimple_simplify_614 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_IFLOORF, CFN_BUILT_IN_LFLOORF, CFN_BUILT_IN_LLFLOORF))
6271 : 0 : return true;
6272 : : }
6273 : 183 : return false;
6274 : : }
6275 : :
6276 : : bool
6277 : 1923 : gimple_simplify_CFN_BUILT_IN_LCEILF (gimple_match_op *res_op, gimple_seq *seq,
6278 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
6279 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
6280 : : {
6281 : 1923 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
6282 : 1923 : if (integer_valued_real_p (_p0))
6283 : : {
6284 : 20 : {
6285 : 20 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
6286 : 20 : if (gimple_simplify_613 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_LCEILF))
6287 : 20 : return true;
6288 : : }
6289 : : }
6290 : : return false;
6291 : : }
6292 : :
6293 : : bool
6294 : 2199 : gimple_simplify_CFN_BUILT_IN_LROUNDF (gimple_match_op *res_op, gimple_seq *seq,
6295 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
6296 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
6297 : : {
6298 : 2199 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
6299 : 2199 : if (integer_valued_real_p (_p0))
6300 : : {
6301 : 23 : {
6302 : 23 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
6303 : 23 : if (gimple_simplify_613 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_LROUNDF))
6304 : 23 : return true;
6305 : : }
6306 : : }
6307 : : return false;
6308 : : }
6309 : :
6310 : : bool
6311 : 467 : gimple_simplify_CFN_BUILT_IN_LLRINTF (gimple_match_op *res_op, gimple_seq *seq,
6312 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
6313 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
6314 : : {
6315 : 467 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
6316 : 467 : if (integer_valued_real_p (_p0))
6317 : : {
6318 : 31 : {
6319 : 31 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
6320 : 31 : if (gimple_simplify_616 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_LLRINTF))
6321 : 20 : return true;
6322 : : }
6323 : : }
6324 : 447 : {
6325 : 447 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
6326 : 447 : if (gimple_simplify_615 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_IRINTF, CFN_BUILT_IN_LRINTF, CFN_BUILT_IN_LLRINTF))
6327 : 351 : return true;
6328 : : }
6329 : 96 : return false;
6330 : : }
6331 : :
6332 : : bool
6333 : 5969 : gimple_simplify_CFN_BUILT_IN_CTZL (gimple_match_op *res_op, gimple_seq *seq,
6334 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
6335 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
6336 : : {
6337 : 5969 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
6338 : 5969 : switch (TREE_CODE (_p0))
6339 : : {
6340 : 5873 : case SSA_NAME:
6341 : 5873 : if (gimple *_d1 = get_def (valueize, _p0))
6342 : : {
6343 : 2629 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
6344 : 2736 : switch (gimple_assign_rhs_code (_a1))
6345 : : {
6346 : 441 : CASE_CONVERT:
6347 : 441 : {
6348 : 441 : tree _q20 = gimple_assign_rhs1 (_a1);
6349 : 441 : _q20 = do_valueize (valueize, _q20);
6350 : 441 : {
6351 : 441 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q20 };
6352 : 441 : if (gimple_simplify_628 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_CTZL))
6353 : 8 : return true;
6354 : : }
6355 : 433 : break;
6356 : : }
6357 : : default:;
6358 : : }
6359 : : }
6360 : : break;
6361 : : default:;
6362 : : }
6363 : : return false;
6364 : : }
6365 : :
6366 : : bool
6367 : 1772 : gimple_simplify_CFN_BUILT_IN_POPCOUNTLL (gimple_match_op *res_op, gimple_seq *seq,
6368 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
6369 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
6370 : : {
6371 : 1772 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
6372 : 1772 : switch (TREE_CODE (_p0))
6373 : : {
6374 : 1718 : case SSA_NAME:
6375 : 1718 : if (gimple *_d1 = get_def (valueize, _p0))
6376 : : {
6377 : 930 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
6378 : 856 : switch (gimple_assign_rhs_code (_a1))
6379 : : {
6380 : 287 : CASE_CONVERT:
6381 : 287 : {
6382 : 287 : tree _q20 = gimple_assign_rhs1 (_a1);
6383 : 287 : _q20 = do_valueize (valueize, _q20);
6384 : 287 : switch (TREE_CODE (_q20))
6385 : : {
6386 : 287 : case SSA_NAME:
6387 : 287 : if (gimple *_d2 = get_def (valueize, _q20))
6388 : : {
6389 : 278 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
6390 : 398 : switch (gimple_assign_rhs_code (_a2))
6391 : : {
6392 : 0 : case LROTATE_EXPR:
6393 : 0 : {
6394 : 0 : tree _q30 = gimple_assign_rhs1 (_a2);
6395 : 0 : _q30 = do_valueize (valueize, _q30);
6396 : 0 : tree _q31 = gimple_assign_rhs2 (_a2);
6397 : 0 : _q31 = do_valueize (valueize, _q31);
6398 : 0 : {
6399 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q31 };
6400 : 0 : if (gimple_simplify_630 (res_op, seq, valueize, type, captures, LROTATE_EXPR, CFN_BUILT_IN_POPCOUNTLL))
6401 : 0 : return true;
6402 : : }
6403 : 0 : break;
6404 : : }
6405 : 0 : case RROTATE_EXPR:
6406 : 0 : {
6407 : 0 : tree _q30 = gimple_assign_rhs1 (_a2);
6408 : 0 : _q30 = do_valueize (valueize, _q30);
6409 : 0 : tree _q31 = gimple_assign_rhs2 (_a2);
6410 : 0 : _q31 = do_valueize (valueize, _q31);
6411 : 0 : {
6412 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q31 };
6413 : 0 : if (gimple_simplify_630 (res_op, seq, valueize, type, captures, RROTATE_EXPR, CFN_BUILT_IN_POPCOUNTLL))
6414 : 0 : return true;
6415 : : }
6416 : 0 : break;
6417 : : }
6418 : : default:;
6419 : : }
6420 : 36 : else if (gcall *_c2 = dyn_cast <gcall *> (_d2))
6421 : 2 : switch (gimple_call_combined_fn (_c2))
6422 : : {
6423 : 0 : case CFN_BUILT_IN_BSWAP128:
6424 : 0 : if (gimple_call_num_args (_c2) == 1)
6425 : : {
6426 : 0 : tree _q30 = gimple_call_arg (_c2, 0);
6427 : 0 : _q30 = do_valueize (valueize, _q30);
6428 : 0 : {
6429 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q30 };
6430 : 0 : if (gimple_simplify_629 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP128, CFN_BUILT_IN_POPCOUNTLL))
6431 : 0 : return true;
6432 : : }
6433 : : }
6434 : : break;
6435 : 2 : case CFN_BUILT_IN_BSWAP16:
6436 : 2 : if (gimple_call_num_args (_c2) == 1)
6437 : : {
6438 : 2 : tree _q30 = gimple_call_arg (_c2, 0);
6439 : 2 : _q30 = do_valueize (valueize, _q30);
6440 : 2 : {
6441 : 2 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q30 };
6442 : 2 : if (gimple_simplify_629 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP16, CFN_BUILT_IN_POPCOUNTLL))
6443 : 1 : return true;
6444 : : }
6445 : : }
6446 : : break;
6447 : 0 : case CFN_BUILT_IN_BSWAP32:
6448 : 0 : if (gimple_call_num_args (_c2) == 1)
6449 : : {
6450 : 0 : tree _q30 = gimple_call_arg (_c2, 0);
6451 : 0 : _q30 = do_valueize (valueize, _q30);
6452 : 0 : {
6453 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q30 };
6454 : 0 : if (gimple_simplify_629 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP32, CFN_BUILT_IN_POPCOUNTLL))
6455 : 0 : return true;
6456 : : }
6457 : : }
6458 : : break;
6459 : 0 : case CFN_BUILT_IN_BSWAP64:
6460 : 0 : if (gimple_call_num_args (_c2) == 1)
6461 : : {
6462 : 0 : tree _q30 = gimple_call_arg (_c2, 0);
6463 : 0 : _q30 = do_valueize (valueize, _q30);
6464 : 0 : {
6465 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q30 };
6466 : 0 : if (gimple_simplify_629 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP64, CFN_BUILT_IN_POPCOUNTLL))
6467 : 0 : return true;
6468 : : }
6469 : : }
6470 : : break;
6471 : : default:;
6472 : : }
6473 : : }
6474 : : break;
6475 : 286 : default:;
6476 : : }
6477 : 286 : {
6478 : 286 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q20 };
6479 : 286 : if (gimple_simplify_631 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_POPCOUNTLL))
6480 : 12 : return true;
6481 : : }
6482 : 274 : break;
6483 : : }
6484 : 0 : case LROTATE_EXPR:
6485 : 0 : {
6486 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
6487 : 0 : _q20 = do_valueize (valueize, _q20);
6488 : 0 : tree _q21 = gimple_assign_rhs2 (_a1);
6489 : 0 : _q21 = do_valueize (valueize, _q21);
6490 : 0 : {
6491 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p0, _q20, _q21 };
6492 : 0 : if (gimple_simplify_633 (res_op, seq, valueize, type, captures, LROTATE_EXPR, CFN_BUILT_IN_POPCOUNTLL))
6493 : 0 : return true;
6494 : : }
6495 : 0 : break;
6496 : : }
6497 : 2 : case RROTATE_EXPR:
6498 : 2 : {
6499 : 2 : tree _q20 = gimple_assign_rhs1 (_a1);
6500 : 2 : _q20 = do_valueize (valueize, _q20);
6501 : 2 : tree _q21 = gimple_assign_rhs2 (_a1);
6502 : 2 : _q21 = do_valueize (valueize, _q21);
6503 : 2 : {
6504 : 2 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p0, _q20, _q21 };
6505 : 2 : if (gimple_simplify_633 (res_op, seq, valueize, type, captures, RROTATE_EXPR, CFN_BUILT_IN_POPCOUNTLL))
6506 : 2 : return true;
6507 : : }
6508 : 0 : break;
6509 : : }
6510 : : default:;
6511 : : }
6512 : 341 : else if (gcall *_c1 = dyn_cast <gcall *> (_d1))
6513 : 2 : switch (gimple_call_combined_fn (_c1))
6514 : : {
6515 : 0 : case CFN_BUILT_IN_BSWAP128:
6516 : 0 : if (gimple_call_num_args (_c1) == 1)
6517 : : {
6518 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
6519 : 0 : _q20 = do_valueize (valueize, _q20);
6520 : 0 : {
6521 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p0, _q20 };
6522 : 0 : if (gimple_simplify_632 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP128, CFN_BUILT_IN_POPCOUNTLL))
6523 : 0 : return true;
6524 : : }
6525 : : }
6526 : : break;
6527 : 0 : case CFN_BUILT_IN_BSWAP16:
6528 : 0 : if (gimple_call_num_args (_c1) == 1)
6529 : : {
6530 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
6531 : 0 : _q20 = do_valueize (valueize, _q20);
6532 : 0 : {
6533 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p0, _q20 };
6534 : 0 : if (gimple_simplify_632 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP16, CFN_BUILT_IN_POPCOUNTLL))
6535 : 0 : return true;
6536 : : }
6537 : : }
6538 : : break;
6539 : 0 : case CFN_BUILT_IN_BSWAP32:
6540 : 0 : if (gimple_call_num_args (_c1) == 1)
6541 : : {
6542 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
6543 : 0 : _q20 = do_valueize (valueize, _q20);
6544 : 0 : {
6545 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p0, _q20 };
6546 : 0 : if (gimple_simplify_632 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP32, CFN_BUILT_IN_POPCOUNTLL))
6547 : 0 : return true;
6548 : : }
6549 : : }
6550 : : break;
6551 : 2 : case CFN_BUILT_IN_BSWAP64:
6552 : 2 : if (gimple_call_num_args (_c1) == 1)
6553 : : {
6554 : 2 : tree _q20 = gimple_call_arg (_c1, 0);
6555 : 2 : _q20 = do_valueize (valueize, _q20);
6556 : 2 : {
6557 : 2 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p0, _q20 };
6558 : 2 : if (gimple_simplify_632 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP64, CFN_BUILT_IN_POPCOUNTLL))
6559 : 2 : return true;
6560 : : }
6561 : : }
6562 : : break;
6563 : : default:;
6564 : : }
6565 : : }
6566 : : break;
6567 : 1755 : default:;
6568 : : }
6569 : 1755 : {
6570 : 1755 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
6571 : 1755 : if (gimple_simplify_634 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_POPCOUNTLL))
6572 : 7 : return true;
6573 : : }
6574 : 1748 : return false;
6575 : : }
6576 : :
6577 : : bool
6578 : 426 : gimple_simplify_CFN_BUILT_IN_FFSL (gimple_match_op *res_op, gimple_seq *seq,
6579 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
6580 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
6581 : : {
6582 : 426 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
6583 : 426 : switch (TREE_CODE (_p0))
6584 : : {
6585 : 413 : case SSA_NAME:
6586 : 413 : if (gimple *_d1 = get_def (valueize, _p0))
6587 : : {
6588 : 217 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
6589 : 107 : switch (gimple_assign_rhs_code (_a1))
6590 : : {
6591 : 91 : CASE_CONVERT:
6592 : 91 : {
6593 : 91 : tree _q20 = gimple_assign_rhs1 (_a1);
6594 : 91 : _q20 = do_valueize (valueize, _q20);
6595 : 91 : {
6596 : 91 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q20 };
6597 : 91 : if (gimple_simplify_642 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_FFSL))
6598 : 1 : return true;
6599 : : }
6600 : 90 : break;
6601 : : }
6602 : : default:;
6603 : : }
6604 : : }
6605 : : break;
6606 : 425 : default:;
6607 : : }
6608 : 425 : if (tree_expr_nonzero_p (_p0))
6609 : : {
6610 : 16 : {
6611 : 16 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
6612 : 16 : if (gimple_simplify_641 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_FFSL, CFN_BUILT_IN_CTZL))
6613 : 16 : return true;
6614 : : }
6615 : : }
6616 : : return false;
6617 : : }
6618 : :
6619 : : bool
6620 : 4873 : gimple_simplify_CFN_REDUC_IOR (gimple_match_op *res_op, gimple_seq *seq,
6621 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
6622 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0)
6623 : : {
6624 : 4873 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
6625 : 4873 : switch (TREE_CODE (_p0))
6626 : : {
6627 : 4873 : case SSA_NAME:
6628 : 4873 : if (gimple *_d1 = get_def (valueize, _p0))
6629 : : {
6630 : 2570 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
6631 : 4442 : switch (gimple_assign_rhs_code (_a1))
6632 : : {
6633 : 6 : case VIEW_CONVERT_EXPR:
6634 : 6 : {
6635 : 6 : tree _q20 = TREE_OPERAND (gimple_assign_rhs1 (_a1), 0);
6636 : 6 : if ((TREE_CODE (_q20) == SSA_NAME
6637 : 6 : || is_gimple_min_invariant (_q20)))
6638 : : {
6639 : 6 : _q20 = do_valueize (valueize, _q20);
6640 : 6 : switch (TREE_CODE (_q20))
6641 : : {
6642 : 6 : case SSA_NAME:
6643 : 6 : if (gimple *_d2 = get_def (valueize, _q20))
6644 : : {
6645 : 6 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
6646 : 12 : switch (gimple_assign_rhs_code (_a2))
6647 : : {
6648 : 0 : case BIT_AND_EXPR:
6649 : 0 : {
6650 : 0 : tree _q30 = gimple_assign_rhs1 (_a2);
6651 : 0 : _q30 = do_valueize (valueize, _q30);
6652 : 0 : tree _q31 = gimple_assign_rhs2 (_a2);
6653 : 0 : _q31 = do_valueize (valueize, _q31);
6654 : 0 : if (tree_swap_operands_p (_q30, _q31))
6655 : 0 : std::swap (_q30, _q31);
6656 : 0 : switch (TREE_CODE (_q31))
6657 : : {
6658 : 0 : case VECTOR_CST:
6659 : 0 : {
6660 : 0 : {
6661 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q30, _q31 };
6662 : 0 : if (gimple_simplify_645 (res_op, seq, valueize, type, captures, CFN_REDUC_IOR))
6663 : 0 : return true;
6664 : : }
6665 : 0 : break;
6666 : : }
6667 : : default:;
6668 : : }
6669 : 4873 : break;
6670 : : }
6671 : : default:;
6672 : : }
6673 : : }
6674 : : break;
6675 : : default:;
6676 : : }
6677 : : }
6678 : : break;
6679 : : }
6680 : 3 : case BIT_AND_EXPR:
6681 : 3 : {
6682 : 3 : tree _q20 = gimple_assign_rhs1 (_a1);
6683 : 3 : _q20 = do_valueize (valueize, _q20);
6684 : 3 : tree _q21 = gimple_assign_rhs2 (_a1);
6685 : 3 : _q21 = do_valueize (valueize, _q21);
6686 : 3 : if (tree_swap_operands_p (_q20, _q21))
6687 : 0 : std::swap (_q20, _q21);
6688 : 3 : switch (TREE_CODE (_q21))
6689 : : {
6690 : 0 : case VECTOR_CST:
6691 : 0 : {
6692 : 0 : {
6693 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
6694 : 0 : if (gimple_simplify_645 (res_op, seq, valueize, type, captures, CFN_REDUC_IOR))
6695 : 0 : return true;
6696 : : }
6697 : 0 : break;
6698 : : }
6699 : : default:;
6700 : : }
6701 : 4873 : break;
6702 : : }
6703 : 33 : case CONSTRUCTOR:
6704 : 33 : {
6705 : 33 : {
6706 : 33 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
6707 : 33 : if (gimple_simplify_646 (res_op, seq, valueize, type, captures, CFN_REDUC_IOR))
6708 : 0 : return true;
6709 : : }
6710 : 33 : break;
6711 : : }
6712 : 447 : case BIT_IOR_EXPR:
6713 : 447 : {
6714 : 447 : tree _q20 = gimple_assign_rhs1 (_a1);
6715 : 447 : _q20 = do_valueize (valueize, _q20);
6716 : 447 : tree _q21 = gimple_assign_rhs2 (_a1);
6717 : 447 : _q21 = do_valueize (valueize, _q21);
6718 : 447 : if (tree_swap_operands_p (_q20, _q21))
6719 : 29 : std::swap (_q20, _q21);
6720 : 447 : switch (TREE_CODE (_q21))
6721 : : {
6722 : 4 : case VECTOR_CST:
6723 : 4 : {
6724 : 4 : {
6725 : 4 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
6726 : 4 : gimple_seq *lseq = seq;
6727 : 4 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1499;
6728 : 4 : {
6729 : 4 : res_op->set_op (BIT_IOR_EXPR, type, 2);
6730 : 4 : {
6731 : 4 : tree _o1[1], _r1;
6732 : 4 : _o1[0] = captures[0];
6733 : 4 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_REDUC_IOR, type, _o1[0]);
6734 : 4 : tem_op.resimplify (lseq, valueize);
6735 : 4 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
6736 : 4 : if (!_r1) goto next_after_fail1499;
6737 : 2 : res_op->ops[0] = _r1;
6738 : : }
6739 : 2 : {
6740 : 2 : tree _o1[1], _r1;
6741 : 2 : _o1[0] = captures[1];
6742 : 2 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_REDUC_IOR, type, _o1[0]);
6743 : 2 : tem_op.resimplify (lseq, valueize);
6744 : 2 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
6745 : 2 : if (!_r1) goto next_after_fail1499;
6746 : 2 : res_op->ops[1] = _r1;
6747 : : }
6748 : 2 : res_op->resimplify (lseq, valueize);
6749 : 2 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 919, __FILE__, __LINE__, true);
6750 : 2 : return true;
6751 : : }
6752 : 2 : next_after_fail1499:;
6753 : : }
6754 : 2 : break;
6755 : : }
6756 : : default:;
6757 : : }
6758 : 4873 : break;
6759 : : }
6760 : : default:;
6761 : : }
6762 : : }
6763 : : break;
6764 : : default:;
6765 : : }
6766 : : return false;
6767 : : }
6768 : :
6769 : : bool
6770 : 2095700 : gimple_simplify_POINTER_DIFF_EXPR (gimple_match_op *res_op, gimple_seq *seq,
6771 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
6772 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0, tree _p1)
6773 : : {
6774 : 2095700 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
6775 : 2095700 : if (integer_zerop (_p1))
6776 : : {
6777 : 42167 : {
6778 : 42167 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
6779 : 42167 : gimple_seq *lseq = seq;
6780 : 42167 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1654;
6781 : 42167 : {
6782 : 42167 : res_op->set_op (NOP_EXPR, type, 1);
6783 : 42167 : res_op->ops[0] = captures[0];
6784 : 42167 : res_op->resimplify (lseq, valueize);
6785 : 42167 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 975, __FILE__, __LINE__, true);
6786 : 42167 : return true;
6787 : : }
6788 : 0 : next_after_fail1654:;
6789 : : }
6790 : : }
6791 : 2053533 : if ((_p1 == _p0 && ! TREE_SIDE_EFFECTS (_p1)) || operand_equal_p (_p1, _p0, 0))
6792 : : {
6793 : 10854 : {
6794 : 10854 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p0 };
6795 : 10854 : gimple_seq *lseq = seq;
6796 : 10854 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1655;
6797 : 10854 : {
6798 : 10854 : tree tem;
6799 : 10854 : tem = build_zero_cst (type);
6800 : 10854 : res_op->set_value (tem);
6801 : 10854 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 976, __FILE__, __LINE__, true);
6802 : 10854 : return true;
6803 : : }
6804 : 0 : next_after_fail1655:;
6805 : : }
6806 : : }
6807 : 2042679 : switch (TREE_CODE (_p0))
6808 : : {
6809 : 1954046 : case SSA_NAME:
6810 : 1954046 : if (gimple *_d1 = get_def (valueize, _p0))
6811 : : {
6812 : 1353125 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
6813 : 1781858 : switch (gimple_assign_rhs_code (_a1))
6814 : : {
6815 : 106103 : case POINTER_PLUS_EXPR:
6816 : 106103 : {
6817 : 106103 : tree _q20 = gimple_assign_rhs1 (_a1);
6818 : 106103 : _q20 = do_valueize (valueize, _q20);
6819 : 106103 : tree _q21 = gimple_assign_rhs2 (_a1);
6820 : 106103 : _q21 = do_valueize (valueize, _q21);
6821 : 106103 : switch (TREE_CODE (_p1))
6822 : : {
6823 : 88497 : case SSA_NAME:
6824 : 88497 : if (gimple *_d2 = get_def (valueize, _p1))
6825 : : {
6826 : 85384 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
6827 : 98339 : switch (gimple_assign_rhs_code (_a2))
6828 : : {
6829 : 11239 : case POINTER_PLUS_EXPR:
6830 : 11239 : {
6831 : 11239 : tree _q50 = gimple_assign_rhs1 (_a2);
6832 : 11239 : _q50 = do_valueize (valueize, _q50);
6833 : 11239 : tree _q51 = gimple_assign_rhs2 (_a2);
6834 : 11239 : _q51 = do_valueize (valueize, _q51);
6835 : 11239 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
6836 : : {
6837 : 406 : {
6838 : 406 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _q51 };
6839 : 406 : if (TYPE_OVERFLOW_WRAPS (TREE_TYPE (captures[1]))
6840 : : )
6841 : : {
6842 : 406 : gimple_seq *lseq = seq;
6843 : 406 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1656;
6844 : 406 : {
6845 : 406 : res_op->set_op (NOP_EXPR, type, 1);
6846 : 406 : {
6847 : 406 : tree _o1[2], _r1;
6848 : 406 : _o1[0] = captures[1];
6849 : 406 : _o1[1] = captures[2];
6850 : 406 : gimple_match_op tem_op (res_op->cond.any_else (), MINUS_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
6851 : 406 : tem_op.resimplify (lseq, valueize);
6852 : 406 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
6853 : 406 : if (!_r1) goto next_after_fail1656;
6854 : 224 : res_op->ops[0] = _r1;
6855 : : }
6856 : 224 : res_op->resimplify (lseq, valueize);
6857 : 224 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 977, __FILE__, __LINE__, true);
6858 : 224 : return true;
6859 : : }
6860 : 182 : next_after_fail1656:;
6861 : : }
6862 : : }
6863 : : }
6864 : : break;
6865 : : }
6866 : : default:;
6867 : : }
6868 : : }
6869 : : break;
6870 : : default:;
6871 : : }
6872 : : break;
6873 : : }
6874 : 8770 : CASE_CONVERT:
6875 : 8770 : {
6876 : 8770 : tree _q20 = gimple_assign_rhs1 (_a1);
6877 : 8770 : _q20 = do_valueize (valueize, _q20);
6878 : 8770 : switch (TREE_CODE (_q20))
6879 : : {
6880 : 8770 : case SSA_NAME:
6881 : 8770 : if (gimple *_d2 = get_def (valueize, _q20))
6882 : : {
6883 : 8399 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
6884 : 5422 : switch (gimple_assign_rhs_code (_a2))
6885 : : {
6886 : 0 : case ADDR_EXPR:
6887 : 0 : {
6888 : 0 : switch (TREE_CODE (_p1))
6889 : : {
6890 : 0 : case SSA_NAME:
6891 : 0 : if (gimple *_d3 = get_def (valueize, _p1))
6892 : : {
6893 : 0 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
6894 : 0 : switch (gimple_assign_rhs_code (_a3))
6895 : : {
6896 : 0 : CASE_CONVERT:
6897 : 0 : {
6898 : 0 : tree _q40 = gimple_assign_rhs1 (_a3);
6899 : 0 : _q40 = do_valueize (valueize, _q40);
6900 : 0 : {
6901 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _p1, _q40 };
6902 : 0 : if (tree_nop_conversion_p (TREE_TYPE(captures[0]), TREE_TYPE (captures[1]))
6903 : 0 : && tree_nop_conversion_p (TREE_TYPE(captures[2]), TREE_TYPE (captures[3]))
6904 : : )
6905 : : {
6906 : 0 : {
6907 : 0 : poly_int64 diff;
6908 : 0 : if (ptr_difference_const (captures[1], captures[3], &diff)
6909 : : )
6910 : : {
6911 : 0 : gimple_seq *lseq = seq;
6912 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1657;
6913 : 0 : {
6914 : 0 : tree tem;
6915 : 0 : tem = build_int_cst_type (type, diff);
6916 : 0 : res_op->set_value (tem);
6917 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 978, __FILE__, __LINE__, true);
6918 : 0 : return true;
6919 : : }
6920 : 0 : next_after_fail1657:;
6921 : : }
6922 : : }
6923 : : }
6924 : : }
6925 : 0 : break;
6926 : : }
6927 : : default:;
6928 : : }
6929 : : }
6930 : : break;
6931 : 0 : default:;
6932 : : }
6933 : 0 : {
6934 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _p1, _p1 };
6935 : 0 : if (tree_nop_conversion_p (TREE_TYPE(captures[0]), TREE_TYPE (captures[1]))
6936 : 0 : && tree_nop_conversion_p (TREE_TYPE(captures[2]), TREE_TYPE (captures[3]))
6937 : : )
6938 : : {
6939 : 0 : {
6940 : 0 : poly_int64 diff;
6941 : 0 : if (ptr_difference_const (captures[1], captures[3], &diff)
6942 : : )
6943 : : {
6944 : 0 : gimple_seq *lseq = seq;
6945 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1658;
6946 : 0 : {
6947 : 0 : tree tem;
6948 : 0 : tem = build_int_cst_type (type, diff);
6949 : 0 : res_op->set_value (tem);
6950 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 978, __FILE__, __LINE__, true);
6951 : 0 : return true;
6952 : : }
6953 : 0 : next_after_fail1658:;
6954 : : }
6955 : : }
6956 : : }
6957 : : }
6958 : 0 : break;
6959 : : }
6960 : : default:;
6961 : : }
6962 : : }
6963 : : break;
6964 : 0 : case ADDR_EXPR:
6965 : 0 : {
6966 : 0 : switch (TREE_CODE (_p1))
6967 : : {
6968 : 0 : case SSA_NAME:
6969 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
6970 : : {
6971 : 0 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
6972 : 0 : switch (gimple_assign_rhs_code (_a2))
6973 : : {
6974 : 0 : CASE_CONVERT:
6975 : 0 : {
6976 : 0 : tree _q40 = gimple_assign_rhs1 (_a2);
6977 : 0 : _q40 = do_valueize (valueize, _q40);
6978 : 0 : {
6979 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _p1, _q40 };
6980 : 0 : if (tree_nop_conversion_p (TREE_TYPE(captures[0]), TREE_TYPE (captures[1]))
6981 : 0 : && tree_nop_conversion_p (TREE_TYPE(captures[2]), TREE_TYPE (captures[3]))
6982 : : )
6983 : : {
6984 : 0 : {
6985 : 0 : poly_int64 diff;
6986 : 0 : if (ptr_difference_const (captures[1], captures[3], &diff)
6987 : : )
6988 : : {
6989 : 0 : gimple_seq *lseq = seq;
6990 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1659;
6991 : 0 : {
6992 : 0 : tree tem;
6993 : 0 : tem = build_int_cst_type (type, diff);
6994 : 0 : res_op->set_value (tem);
6995 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 978, __FILE__, __LINE__, true);
6996 : 0 : return true;
6997 : : }
6998 : 0 : next_after_fail1659:;
6999 : : }
7000 : : }
7001 : : }
7002 : : }
7003 : 0 : break;
7004 : : }
7005 : : default:;
7006 : : }
7007 : : }
7008 : : break;
7009 : 0 : default:;
7010 : : }
7011 : 0 : {
7012 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _p1, _p1 };
7013 : 0 : if (tree_nop_conversion_p (TREE_TYPE(captures[0]), TREE_TYPE (captures[1]))
7014 : 0 : && tree_nop_conversion_p (TREE_TYPE(captures[2]), TREE_TYPE (captures[3]))
7015 : : )
7016 : : {
7017 : 0 : {
7018 : 0 : poly_int64 diff;
7019 : 0 : if (ptr_difference_const (captures[1], captures[3], &diff)
7020 : : )
7021 : : {
7022 : 0 : gimple_seq *lseq = seq;
7023 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1660;
7024 : 0 : {
7025 : 0 : tree tem;
7026 : 0 : tem = build_int_cst_type (type, diff);
7027 : 0 : res_op->set_value (tem);
7028 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 978, __FILE__, __LINE__, true);
7029 : 0 : return true;
7030 : : }
7031 : 0 : next_after_fail1660:;
7032 : : }
7033 : : }
7034 : : }
7035 : : }
7036 : 0 : break;
7037 : : }
7038 : 8770 : default:;
7039 : : }
7040 : 8770 : switch (TREE_CODE (_p1))
7041 : : {
7042 : 7115 : case SSA_NAME:
7043 : 7115 : if (gimple *_d2 = get_def (valueize, _p1))
7044 : : {
7045 : 6818 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
7046 : 7068 : switch (gimple_assign_rhs_code (_a2))
7047 : : {
7048 : 4917 : CASE_CONVERT:
7049 : 4917 : {
7050 : 4917 : tree _q40 = gimple_assign_rhs1 (_a2);
7051 : 4917 : _q40 = do_valueize (valueize, _q40);
7052 : 4917 : switch (TREE_CODE (_q40))
7053 : : {
7054 : 4917 : case SSA_NAME:
7055 : 4917 : if (gimple *_d3 = get_def (valueize, _q40))
7056 : : {
7057 : 4903 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
7058 : 3835 : switch (gimple_assign_rhs_code (_a3))
7059 : : {
7060 : 0 : case ADDR_EXPR:
7061 : 0 : {
7062 : 0 : {
7063 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _p1, _q40 };
7064 : 0 : if (tree_nop_conversion_p (TREE_TYPE(captures[0]), TREE_TYPE (captures[1]))
7065 : 0 : && tree_nop_conversion_p (TREE_TYPE(captures[2]), TREE_TYPE (captures[3]))
7066 : : )
7067 : : {
7068 : 0 : {
7069 : 0 : poly_int64 diff;
7070 : 0 : if (ptr_difference_const (captures[1], captures[3], &diff)
7071 : : )
7072 : : {
7073 : 0 : gimple_seq *lseq = seq;
7074 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1661;
7075 : 0 : {
7076 : 0 : tree tem;
7077 : 0 : tem = build_int_cst_type (type, diff);
7078 : 0 : res_op->set_value (tem);
7079 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 979, __FILE__, __LINE__, true);
7080 : 0 : return true;
7081 : : }
7082 : 0 : next_after_fail1661:;
7083 : : }
7084 : : }
7085 : : }
7086 : : }
7087 : 0 : break;
7088 : : }
7089 : : default:;
7090 : : }
7091 : : }
7092 : : break;
7093 : 0 : case ADDR_EXPR:
7094 : 0 : {
7095 : 0 : {
7096 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _p1, _q40 };
7097 : 0 : if (tree_nop_conversion_p (TREE_TYPE(captures[0]), TREE_TYPE (captures[1]))
7098 : 0 : && tree_nop_conversion_p (TREE_TYPE(captures[2]), TREE_TYPE (captures[3]))
7099 : : )
7100 : : {
7101 : 0 : {
7102 : 0 : poly_int64 diff;
7103 : 0 : if (ptr_difference_const (captures[1], captures[3], &diff)
7104 : : )
7105 : : {
7106 : 0 : gimple_seq *lseq = seq;
7107 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1662;
7108 : 0 : {
7109 : 0 : tree tem;
7110 : 0 : tem = build_int_cst_type (type, diff);
7111 : 0 : res_op->set_value (tem);
7112 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 979, __FILE__, __LINE__, true);
7113 : 0 : return true;
7114 : : }
7115 : 0 : next_after_fail1662:;
7116 : : }
7117 : : }
7118 : : }
7119 : : }
7120 : 0 : break;
7121 : : }
7122 : : default:;
7123 : : }
7124 : : break;
7125 : : }
7126 : 4 : case ADDR_EXPR:
7127 : 4 : {
7128 : 4 : {
7129 : 4 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _p1, _p1 };
7130 : 4 : if (tree_nop_conversion_p (TREE_TYPE(captures[0]), TREE_TYPE (captures[1]))
7131 : 4 : && tree_nop_conversion_p (TREE_TYPE(captures[2]), TREE_TYPE (captures[3]))
7132 : : )
7133 : : {
7134 : 4 : {
7135 : 4 : poly_int64 diff;
7136 : 4 : if (ptr_difference_const (captures[1], captures[3], &diff)
7137 : : )
7138 : : {
7139 : 0 : gimple_seq *lseq = seq;
7140 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1663;
7141 : 0 : {
7142 : 0 : tree tem;
7143 : 0 : tem = build_int_cst_type (type, diff);
7144 : 0 : res_op->set_value (tem);
7145 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 979, __FILE__, __LINE__, true);
7146 : 0 : return true;
7147 : : }
7148 : 0 : next_after_fail1663:;
7149 : : }
7150 : : }
7151 : : }
7152 : : }
7153 : 4 : break;
7154 : : }
7155 : : default:;
7156 : : }
7157 : : }
7158 : : break;
7159 : 1655 : case ADDR_EXPR:
7160 : 1655 : {
7161 : 1655 : {
7162 : 1655 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _p1, _p1 };
7163 : 1655 : if (tree_nop_conversion_p (TREE_TYPE(captures[0]), TREE_TYPE (captures[1]))
7164 : 1655 : && tree_nop_conversion_p (TREE_TYPE(captures[2]), TREE_TYPE (captures[3]))
7165 : : )
7166 : : {
7167 : 1655 : {
7168 : 1655 : poly_int64 diff;
7169 : 1655 : if (ptr_difference_const (captures[1], captures[3], &diff)
7170 : : )
7171 : : {
7172 : 0 : gimple_seq *lseq = seq;
7173 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1664;
7174 : 0 : {
7175 : 0 : tree tem;
7176 : 0 : tem = build_int_cst_type (type, diff);
7177 : 0 : res_op->set_value (tem);
7178 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 979, __FILE__, __LINE__, true);
7179 : 0 : return true;
7180 : : }
7181 : 0 : next_after_fail1664:;
7182 : : }
7183 : : }
7184 : : }
7185 : : }
7186 : 1655 : break;
7187 : : }
7188 : : default:;
7189 : : }
7190 : : break;
7191 : : }
7192 : 272 : case ADDR_EXPR:
7193 : 272 : {
7194 : 272 : switch (TREE_CODE (_p1))
7195 : : {
7196 : 268 : case SSA_NAME:
7197 : 268 : if (gimple *_d2 = get_def (valueize, _p1))
7198 : : {
7199 : 257 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
7200 : 380 : switch (gimple_assign_rhs_code (_a2))
7201 : : {
7202 : 0 : CASE_CONVERT:
7203 : 0 : {
7204 : 0 : tree _q30 = gimple_assign_rhs1 (_a2);
7205 : 0 : _q30 = do_valueize (valueize, _q30);
7206 : 0 : {
7207 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p0, _p1, _q30 };
7208 : 0 : if (tree_nop_conversion_p (TREE_TYPE(captures[0]), TREE_TYPE (captures[1]))
7209 : 0 : && tree_nop_conversion_p (TREE_TYPE(captures[2]), TREE_TYPE (captures[3]))
7210 : : )
7211 : : {
7212 : 0 : {
7213 : 0 : poly_int64 diff;
7214 : 0 : if (ptr_difference_const (captures[1], captures[3], &diff)
7215 : : )
7216 : : {
7217 : 0 : gimple_seq *lseq = seq;
7218 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1665;
7219 : 0 : {
7220 : 0 : tree tem;
7221 : 0 : tem = build_int_cst_type (type, diff);
7222 : 0 : res_op->set_value (tem);
7223 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 978, __FILE__, __LINE__, true);
7224 : 0 : return true;
7225 : : }
7226 : 0 : next_after_fail1665:;
7227 : : }
7228 : : }
7229 : : }
7230 : : }
7231 : 0 : break;
7232 : : }
7233 : : default:;
7234 : : }
7235 : : }
7236 : : break;
7237 : 272 : default:;
7238 : : }
7239 : 272 : {
7240 : 272 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p0, _p1, _p1 };
7241 : 272 : if (tree_nop_conversion_p (TREE_TYPE(captures[0]), TREE_TYPE (captures[1]))
7242 : 272 : && tree_nop_conversion_p (TREE_TYPE(captures[2]), TREE_TYPE (captures[3]))
7243 : : )
7244 : : {
7245 : 272 : {
7246 : 272 : poly_int64 diff;
7247 : 272 : if (ptr_difference_const (captures[1], captures[3], &diff)
7248 : : )
7249 : : {
7250 : 94 : gimple_seq *lseq = seq;
7251 : 94 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1666;
7252 : 94 : {
7253 : 94 : tree tem;
7254 : 94 : tem = build_int_cst_type (type, diff);
7255 : 94 : res_op->set_value (tem);
7256 : 94 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 978, __FILE__, __LINE__, true);
7257 : 94 : return true;
7258 : : }
7259 : 0 : next_after_fail1666:;
7260 : : }
7261 : : }
7262 : : }
7263 : : }
7264 : 178 : break;
7265 : : }
7266 : : default:;
7267 : : }
7268 : : }
7269 : : break;
7270 : 63801 : case ADDR_EXPR:
7271 : 63801 : {
7272 : 63801 : switch (TREE_CODE (_p1))
7273 : : {
7274 : 26652 : case SSA_NAME:
7275 : 26652 : if (gimple *_d1 = get_def (valueize, _p1))
7276 : : {
7277 : 15860 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
7278 : 3731 : switch (gimple_assign_rhs_code (_a1))
7279 : : {
7280 : 38 : CASE_CONVERT:
7281 : 38 : {
7282 : 38 : tree _q30 = gimple_assign_rhs1 (_a1);
7283 : 38 : _q30 = do_valueize (valueize, _q30);
7284 : 38 : {
7285 : 38 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p0, _p1, _q30 };
7286 : 38 : if (tree_nop_conversion_p (TREE_TYPE(captures[0]), TREE_TYPE (captures[1]))
7287 : 38 : && tree_nop_conversion_p (TREE_TYPE(captures[2]), TREE_TYPE (captures[3]))
7288 : : )
7289 : : {
7290 : 38 : {
7291 : 38 : poly_int64 diff;
7292 : 38 : if (ptr_difference_const (captures[1], captures[3], &diff)
7293 : : )
7294 : : {
7295 : 0 : gimple_seq *lseq = seq;
7296 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1667;
7297 : 0 : {
7298 : 0 : tree tem;
7299 : 0 : tem = build_int_cst_type (type, diff);
7300 : 0 : res_op->set_value (tem);
7301 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 978, __FILE__, __LINE__, true);
7302 : 0 : return true;
7303 : : }
7304 : 0 : next_after_fail1667:;
7305 : : }
7306 : : }
7307 : : }
7308 : : }
7309 : 38 : break;
7310 : : }
7311 : : default:;
7312 : : }
7313 : : }
7314 : : break;
7315 : 63801 : default:;
7316 : : }
7317 : 63801 : {
7318 : 63801 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p0, _p1, _p1 };
7319 : 63801 : if (tree_nop_conversion_p (TREE_TYPE(captures[0]), TREE_TYPE (captures[1]))
7320 : 63801 : && tree_nop_conversion_p (TREE_TYPE(captures[2]), TREE_TYPE (captures[3]))
7321 : : )
7322 : : {
7323 : 63801 : {
7324 : 63801 : poly_int64 diff;
7325 : 63801 : if (ptr_difference_const (captures[1], captures[3], &diff)
7326 : : )
7327 : : {
7328 : 34239 : gimple_seq *lseq = seq;
7329 : 34239 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1668;
7330 : 34239 : {
7331 : 34239 : tree tem;
7332 : 34239 : tem = build_int_cst_type (type, diff);
7333 : 34239 : res_op->set_value (tem);
7334 : 34239 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 978, __FILE__, __LINE__, true);
7335 : 34239 : return true;
7336 : : }
7337 : 0 : next_after_fail1668:;
7338 : : }
7339 : : }
7340 : : }
7341 : : }
7342 : 29562 : break;
7343 : : }
7344 : 2008122 : default:;
7345 : : }
7346 : 2008122 : switch (TREE_CODE (_p1))
7347 : : {
7348 : 1845359 : case SSA_NAME:
7349 : 1845359 : if (gimple *_d1 = get_def (valueize, _p1))
7350 : : {
7351 : 1236654 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
7352 : 1780375 : switch (gimple_assign_rhs_code (_a1))
7353 : : {
7354 : 8072 : CASE_CONVERT:
7355 : 8072 : {
7356 : 8072 : tree _q30 = gimple_assign_rhs1 (_a1);
7357 : 8072 : _q30 = do_valueize (valueize, _q30);
7358 : 8072 : switch (TREE_CODE (_q30))
7359 : : {
7360 : 8072 : case SSA_NAME:
7361 : 8072 : if (gimple *_d2 = get_def (valueize, _q30))
7362 : : {
7363 : 7961 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
7364 : 7923 : switch (gimple_assign_rhs_code (_a2))
7365 : : {
7366 : 0 : case ADDR_EXPR:
7367 : 0 : {
7368 : 0 : {
7369 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p0, _p1, _q30 };
7370 : 0 : if (tree_nop_conversion_p (TREE_TYPE(captures[0]), TREE_TYPE (captures[1]))
7371 : 0 : && tree_nop_conversion_p (TREE_TYPE(captures[2]), TREE_TYPE (captures[3]))
7372 : : )
7373 : : {
7374 : 0 : {
7375 : 0 : poly_int64 diff;
7376 : 0 : if (ptr_difference_const (captures[1], captures[3], &diff)
7377 : : )
7378 : : {
7379 : 0 : gimple_seq *lseq = seq;
7380 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1669;
7381 : 0 : {
7382 : 0 : tree tem;
7383 : 0 : tem = build_int_cst_type (type, diff);
7384 : 0 : res_op->set_value (tem);
7385 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 979, __FILE__, __LINE__, true);
7386 : 0 : return true;
7387 : : }
7388 : 0 : next_after_fail1669:;
7389 : : }
7390 : : }
7391 : : }
7392 : : }
7393 : 0 : break;
7394 : : }
7395 : : default:;
7396 : : }
7397 : : }
7398 : : break;
7399 : 0 : case ADDR_EXPR:
7400 : 0 : {
7401 : 0 : {
7402 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p0, _p1, _q30 };
7403 : 0 : if (tree_nop_conversion_p (TREE_TYPE(captures[0]), TREE_TYPE (captures[1]))
7404 : 0 : && tree_nop_conversion_p (TREE_TYPE(captures[2]), TREE_TYPE (captures[3]))
7405 : : )
7406 : : {
7407 : 0 : {
7408 : 0 : poly_int64 diff;
7409 : 0 : if (ptr_difference_const (captures[1], captures[3], &diff)
7410 : : )
7411 : : {
7412 : 0 : gimple_seq *lseq = seq;
7413 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1670;
7414 : 0 : {
7415 : 0 : tree tem;
7416 : 0 : tem = build_int_cst_type (type, diff);
7417 : 0 : res_op->set_value (tem);
7418 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 979, __FILE__, __LINE__, true);
7419 : 0 : return true;
7420 : : }
7421 : 0 : next_after_fail1670:;
7422 : : }
7423 : : }
7424 : : }
7425 : : }
7426 : 0 : break;
7427 : : }
7428 : : default:;
7429 : : }
7430 : : break;
7431 : : }
7432 : 2145 : case ADDR_EXPR:
7433 : 2145 : {
7434 : 2145 : {
7435 : 2145 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p0, _p1, _p1 };
7436 : 2145 : if (tree_nop_conversion_p (TREE_TYPE(captures[0]), TREE_TYPE (captures[1]))
7437 : 2145 : && tree_nop_conversion_p (TREE_TYPE(captures[2]), TREE_TYPE (captures[3]))
7438 : : )
7439 : : {
7440 : 2145 : {
7441 : 2145 : poly_int64 diff;
7442 : 2145 : if (ptr_difference_const (captures[1], captures[3], &diff)
7443 : : )
7444 : : {
7445 : 0 : gimple_seq *lseq = seq;
7446 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1671;
7447 : 0 : {
7448 : 0 : tree tem;
7449 : 0 : tem = build_int_cst_type (type, diff);
7450 : 0 : res_op->set_value (tem);
7451 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 979, __FILE__, __LINE__, true);
7452 : 0 : return true;
7453 : : }
7454 : 0 : next_after_fail1671:;
7455 : : }
7456 : : }
7457 : : }
7458 : : }
7459 : 2145 : break;
7460 : : }
7461 : : default:;
7462 : : }
7463 : : }
7464 : : break;
7465 : 136286 : case ADDR_EXPR:
7466 : 136286 : {
7467 : 136286 : {
7468 : 136286 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p0, _p1, _p1 };
7469 : 136286 : if (tree_nop_conversion_p (TREE_TYPE(captures[0]), TREE_TYPE (captures[1]))
7470 : 136286 : && tree_nop_conversion_p (TREE_TYPE(captures[2]), TREE_TYPE (captures[3]))
7471 : : )
7472 : : {
7473 : 136286 : {
7474 : 136286 : poly_int64 diff;
7475 : 136286 : if (ptr_difference_const (captures[1], captures[3], &diff)
7476 : : )
7477 : : {
7478 : 1 : gimple_seq *lseq = seq;
7479 : 1 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1672;
7480 : 1 : {
7481 : 1 : tree tem;
7482 : 1 : tem = build_int_cst_type (type, diff);
7483 : 1 : res_op->set_value (tem);
7484 : 1 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 979, __FILE__, __LINE__, true);
7485 : 1 : return true;
7486 : : }
7487 : 0 : next_after_fail1672:;
7488 : : }
7489 : : }
7490 : : }
7491 : : }
7492 : 136285 : break;
7493 : : }
7494 : 2008121 : default:;
7495 : : }
7496 : 2008121 : switch (TREE_CODE (_p0))
7497 : : {
7498 : 1953727 : case SSA_NAME:
7499 : 1953727 : if (gimple *_d1 = get_def (valueize, _p0))
7500 : : {
7501 : 1352807 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
7502 : 1781446 : switch (gimple_assign_rhs_code (_a1))
7503 : : {
7504 : 105879 : case POINTER_PLUS_EXPR:
7505 : 105879 : {
7506 : 105879 : tree _q20 = gimple_assign_rhs1 (_a1);
7507 : 105879 : _q20 = do_valueize (valueize, _q20);
7508 : 105879 : tree _q21 = gimple_assign_rhs2 (_a1);
7509 : 105879 : _q21 = do_valueize (valueize, _q21);
7510 : 105879 : switch (TREE_CODE (_q20))
7511 : : {
7512 : 92596 : case SSA_NAME:
7513 : 92596 : if (gimple *_d2 = get_def (valueize, _q20))
7514 : : {
7515 : 89284 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
7516 : 108069 : switch (gimple_assign_rhs_code (_a2))
7517 : : {
7518 : 647 : case ADDR_EXPR:
7519 : 647 : {
7520 : 647 : switch (TREE_CODE (_p1))
7521 : : {
7522 : 647 : case SSA_NAME:
7523 : 647 : if (gimple *_d3 = get_def (valueize, _p1))
7524 : : {
7525 : 631 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
7526 : 1262 : switch (gimple_assign_rhs_code (_a3))
7527 : : {
7528 : 0 : case POINTER_PLUS_EXPR:
7529 : 0 : {
7530 : 0 : tree _q50 = gimple_assign_rhs1 (_a3);
7531 : 0 : _q50 = do_valueize (valueize, _q50);
7532 : 0 : tree _q51 = gimple_assign_rhs2 (_a3);
7533 : 0 : _q51 = do_valueize (valueize, _q51);
7534 : 0 : switch (TREE_CODE (_q50))
7535 : : {
7536 : 0 : case SSA_NAME:
7537 : 0 : if (gimple *_d4 = get_def (valueize, _q50))
7538 : : {
7539 : 0 : if (gassign *_a4 = dyn_cast <gassign *> (_d4))
7540 : 0 : switch (gimple_assign_rhs_code (_a4))
7541 : : {
7542 : 0 : case ADDR_EXPR:
7543 : 0 : {
7544 : 0 : {
7545 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q20, _q21, _q50, _q51 };
7546 : 0 : {
7547 : 0 : poly_int64 diff;
7548 : 0 : if (ptr_difference_const (captures[0], captures[2], &diff)
7549 : : )
7550 : : {
7551 : 0 : gimple_seq *lseq = seq;
7552 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1673;
7553 : 0 : {
7554 : 0 : res_op->set_op (PLUS_EXPR, type, 2);
7555 : 0 : res_op->ops[0] = build_int_cst_type (type, diff);
7556 : 0 : {
7557 : 0 : tree _o1[1], _r1;
7558 : 0 : {
7559 : 0 : tree _o2[2], _r2;
7560 : 0 : _o2[0] = captures[1];
7561 : 0 : _o2[1] = captures[3];
7562 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), MINUS_EXPR, TREE_TYPE (_o2[0]), _o2[0], _o2[1]);
7563 : 0 : tem_op.resimplify (lseq, valueize);
7564 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
7565 : 0 : if (!_r2) goto next_after_fail1673;
7566 : 0 : _o1[0] = _r2;
7567 : : }
7568 : 0 : if (type != TREE_TYPE (_o1[0])
7569 : 0 : && !useless_type_conversion_p (type, TREE_TYPE (_o1[0])))
7570 : : {
7571 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type, _o1[0]);
7572 : 0 : tem_op.resimplify (lseq, valueize);
7573 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
7574 : 0 : if (!_r1) goto next_after_fail1673;
7575 : : }
7576 : : else
7577 : : _r1 = _o1[0];
7578 : 0 : res_op->ops[1] = _r1;
7579 : : }
7580 : 0 : res_op->resimplify (lseq, valueize);
7581 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 980, __FILE__, __LINE__, true);
7582 : 0 : return true;
7583 : : }
7584 : 0 : next_after_fail1673:;
7585 : : }
7586 : : }
7587 : : }
7588 : 0 : break;
7589 : : }
7590 : : default:;
7591 : : }
7592 : : }
7593 : : break;
7594 : 0 : case ADDR_EXPR:
7595 : 0 : {
7596 : 0 : {
7597 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q20, _q21, _q50, _q51 };
7598 : 0 : {
7599 : 0 : poly_int64 diff;
7600 : 0 : if (ptr_difference_const (captures[0], captures[2], &diff)
7601 : : )
7602 : : {
7603 : 0 : gimple_seq *lseq = seq;
7604 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1674;
7605 : 0 : {
7606 : 0 : res_op->set_op (PLUS_EXPR, type, 2);
7607 : 0 : res_op->ops[0] = build_int_cst_type (type, diff);
7608 : 0 : {
7609 : 0 : tree _o1[1], _r1;
7610 : 0 : {
7611 : 0 : tree _o2[2], _r2;
7612 : 0 : _o2[0] = captures[1];
7613 : 0 : _o2[1] = captures[3];
7614 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), MINUS_EXPR, TREE_TYPE (_o2[0]), _o2[0], _o2[1]);
7615 : 0 : tem_op.resimplify (lseq, valueize);
7616 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
7617 : 0 : if (!_r2) goto next_after_fail1674;
7618 : 0 : _o1[0] = _r2;
7619 : : }
7620 : 0 : if (type != TREE_TYPE (_o1[0])
7621 : 0 : && !useless_type_conversion_p (type, TREE_TYPE (_o1[0])))
7622 : : {
7623 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type, _o1[0]);
7624 : 0 : tem_op.resimplify (lseq, valueize);
7625 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
7626 : 0 : if (!_r1) goto next_after_fail1674;
7627 : : }
7628 : : else
7629 : : _r1 = _o1[0];
7630 : 0 : res_op->ops[1] = _r1;
7631 : : }
7632 : 0 : res_op->resimplify (lseq, valueize);
7633 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 980, __FILE__, __LINE__, true);
7634 : 0 : return true;
7635 : : }
7636 : 0 : next_after_fail1674:;
7637 : : }
7638 : : }
7639 : : }
7640 : 0 : break;
7641 : : }
7642 : : default:;
7643 : : }
7644 : : break;
7645 : : }
7646 : : default:;
7647 : : }
7648 : : }
7649 : : break;
7650 : : default:;
7651 : : }
7652 : : break;
7653 : : }
7654 : : default:;
7655 : : }
7656 : : }
7657 : : break;
7658 : 13283 : case ADDR_EXPR:
7659 : 13283 : {
7660 : 13283 : switch (TREE_CODE (_p1))
7661 : : {
7662 : 137 : case SSA_NAME:
7663 : 137 : if (gimple *_d2 = get_def (valueize, _p1))
7664 : : {
7665 : 127 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
7666 : 124 : switch (gimple_assign_rhs_code (_a2))
7667 : : {
7668 : 80 : case POINTER_PLUS_EXPR:
7669 : 80 : {
7670 : 80 : tree _q50 = gimple_assign_rhs1 (_a2);
7671 : 80 : _q50 = do_valueize (valueize, _q50);
7672 : 80 : tree _q51 = gimple_assign_rhs2 (_a2);
7673 : 80 : _q51 = do_valueize (valueize, _q51);
7674 : 80 : switch (TREE_CODE (_q50))
7675 : : {
7676 : 80 : case SSA_NAME:
7677 : 80 : if (gimple *_d3 = get_def (valueize, _q50))
7678 : : {
7679 : 80 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
7680 : 2 : switch (gimple_assign_rhs_code (_a3))
7681 : : {
7682 : 0 : case ADDR_EXPR:
7683 : 0 : {
7684 : 0 : {
7685 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q20, _q21, _q50, _q51 };
7686 : 0 : {
7687 : 0 : poly_int64 diff;
7688 : 0 : if (ptr_difference_const (captures[0], captures[2], &diff)
7689 : : )
7690 : : {
7691 : 0 : gimple_seq *lseq = seq;
7692 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1675;
7693 : 0 : {
7694 : 0 : res_op->set_op (PLUS_EXPR, type, 2);
7695 : 0 : res_op->ops[0] = build_int_cst_type (type, diff);
7696 : 0 : {
7697 : 0 : tree _o1[1], _r1;
7698 : 0 : {
7699 : 0 : tree _o2[2], _r2;
7700 : 0 : _o2[0] = captures[1];
7701 : 0 : _o2[1] = captures[3];
7702 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), MINUS_EXPR, TREE_TYPE (_o2[0]), _o2[0], _o2[1]);
7703 : 0 : tem_op.resimplify (lseq, valueize);
7704 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
7705 : 0 : if (!_r2) goto next_after_fail1675;
7706 : 0 : _o1[0] = _r2;
7707 : : }
7708 : 0 : if (type != TREE_TYPE (_o1[0])
7709 : 0 : && !useless_type_conversion_p (type, TREE_TYPE (_o1[0])))
7710 : : {
7711 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type, _o1[0]);
7712 : 0 : tem_op.resimplify (lseq, valueize);
7713 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
7714 : 0 : if (!_r1) goto next_after_fail1675;
7715 : : }
7716 : : else
7717 : : _r1 = _o1[0];
7718 : 0 : res_op->ops[1] = _r1;
7719 : : }
7720 : 0 : res_op->resimplify (lseq, valueize);
7721 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 980, __FILE__, __LINE__, true);
7722 : 0 : return true;
7723 : : }
7724 : 0 : next_after_fail1675:;
7725 : : }
7726 : : }
7727 : : }
7728 : 0 : break;
7729 : : }
7730 : : default:;
7731 : : }
7732 : : }
7733 : : break;
7734 : 0 : case ADDR_EXPR:
7735 : 0 : {
7736 : 0 : {
7737 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q20, _q21, _q50, _q51 };
7738 : 0 : {
7739 : 0 : poly_int64 diff;
7740 : 0 : if (ptr_difference_const (captures[0], captures[2], &diff)
7741 : : )
7742 : : {
7743 : 0 : gimple_seq *lseq = seq;
7744 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1676;
7745 : 0 : {
7746 : 0 : res_op->set_op (PLUS_EXPR, type, 2);
7747 : 0 : res_op->ops[0] = build_int_cst_type (type, diff);
7748 : 0 : {
7749 : 0 : tree _o1[1], _r1;
7750 : 0 : {
7751 : 0 : tree _o2[2], _r2;
7752 : 0 : _o2[0] = captures[1];
7753 : 0 : _o2[1] = captures[3];
7754 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), MINUS_EXPR, TREE_TYPE (_o2[0]), _o2[0], _o2[1]);
7755 : 0 : tem_op.resimplify (lseq, valueize);
7756 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
7757 : 0 : if (!_r2) goto next_after_fail1676;
7758 : 0 : _o1[0] = _r2;
7759 : : }
7760 : 0 : if (type != TREE_TYPE (_o1[0])
7761 : 0 : && !useless_type_conversion_p (type, TREE_TYPE (_o1[0])))
7762 : : {
7763 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type, _o1[0]);
7764 : 0 : tem_op.resimplify (lseq, valueize);
7765 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
7766 : 0 : if (!_r1) goto next_after_fail1676;
7767 : : }
7768 : : else
7769 : : _r1 = _o1[0];
7770 : 0 : res_op->ops[1] = _r1;
7771 : : }
7772 : 0 : res_op->resimplify (lseq, valueize);
7773 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 980, __FILE__, __LINE__, true);
7774 : 0 : return true;
7775 : : }
7776 : 0 : next_after_fail1676:;
7777 : : }
7778 : : }
7779 : : }
7780 : 0 : break;
7781 : : }
7782 : : default:;
7783 : : }
7784 : : break;
7785 : : }
7786 : : default:;
7787 : : }
7788 : : }
7789 : : break;
7790 : : default:;
7791 : : }
7792 : : break;
7793 : : }
7794 : 105879 : default:;
7795 : : }
7796 : 105879 : switch (TREE_CODE (_p1))
7797 : : {
7798 : 88273 : case SSA_NAME:
7799 : 88273 : if (gimple *_d2 = get_def (valueize, _p1))
7800 : : {
7801 : 85160 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
7802 : 98115 : switch (gimple_assign_rhs_code (_a2))
7803 : : {
7804 : 583 : case ADDR_EXPR:
7805 : 583 : {
7806 : 583 : {
7807 : 583 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
7808 : 583 : {
7809 : 583 : poly_int64 diff;
7810 : 583 : if (ptr_difference_const (captures[0], captures[2], &diff)
7811 : : )
7812 : : {
7813 : 130 : gimple_seq *lseq = seq;
7814 : 130 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1677;
7815 : 130 : {
7816 : 130 : res_op->set_op (PLUS_EXPR, type, 2);
7817 : 130 : res_op->ops[0] = build_int_cst_type (type, diff);
7818 : 130 : {
7819 : 130 : tree _o1[1], _r1;
7820 : 130 : _o1[0] = captures[1];
7821 : 130 : if (type != TREE_TYPE (_o1[0])
7822 : 130 : && !useless_type_conversion_p (type, TREE_TYPE (_o1[0])))
7823 : : {
7824 : 130 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type, _o1[0]);
7825 : 130 : tem_op.resimplify (lseq, valueize);
7826 : 130 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
7827 : 130 : if (!_r1) goto next_after_fail1677;
7828 : : }
7829 : : else
7830 : : _r1 = _o1[0];
7831 : 86 : res_op->ops[1] = _r1;
7832 : : }
7833 : 86 : res_op->resimplify (lseq, valueize);
7834 : 86 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 981, __FILE__, __LINE__, true);
7835 : 86 : return true;
7836 : : }
7837 : 497 : next_after_fail1677:;
7838 : : }
7839 : : }
7840 : : }
7841 : 497 : break;
7842 : : }
7843 : : default:;
7844 : : }
7845 : : }
7846 : : break;
7847 : 17606 : case ADDR_EXPR:
7848 : 17606 : {
7849 : 17606 : {
7850 : 17606 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
7851 : 17606 : {
7852 : 17606 : poly_int64 diff;
7853 : 17606 : if (ptr_difference_const (captures[0], captures[2], &diff)
7854 : : )
7855 : : {
7856 : 13146 : gimple_seq *lseq = seq;
7857 : 13146 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1678;
7858 : 13146 : {
7859 : 13146 : res_op->set_op (PLUS_EXPR, type, 2);
7860 : 13146 : res_op->ops[0] = build_int_cst_type (type, diff);
7861 : 13146 : {
7862 : 13146 : tree _o1[1], _r1;
7863 : 13146 : _o1[0] = captures[1];
7864 : 13146 : if (type != TREE_TYPE (_o1[0])
7865 : 13146 : && !useless_type_conversion_p (type, TREE_TYPE (_o1[0])))
7866 : : {
7867 : 13146 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type, _o1[0]);
7868 : 13146 : tem_op.resimplify (lseq, valueize);
7869 : 13146 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
7870 : 13146 : if (!_r1) goto next_after_fail1678;
7871 : : }
7872 : : else
7873 : : _r1 = _o1[0];
7874 : 10929 : res_op->ops[1] = _r1;
7875 : : }
7876 : 10929 : res_op->resimplify (lseq, valueize);
7877 : 10929 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 981, __FILE__, __LINE__, true);
7878 : 10929 : return true;
7879 : : }
7880 : 6677 : next_after_fail1678:;
7881 : : }
7882 : : }
7883 : : }
7884 : 6677 : break;
7885 : : }
7886 : 94864 : default:;
7887 : : }
7888 : 94864 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || operand_equal_p (_p1, _q20, 0))
7889 : : {
7890 : 33906 : {
7891 : 33906 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _q20 };
7892 : 33906 : if (!TYPE_SATURATING (type)
7893 : : )
7894 : : {
7895 : 33906 : if ((!FLOAT_TYPE_P (type) || flag_associative_math)
7896 : 67812 : && !FIXED_POINT_TYPE_P (type)
7897 : : )
7898 : : {
7899 : 33906 : {
7900 : 33906 : tree stype = signed_type_for (TREE_TYPE (captures[1]));
7901 : 33906 : gimple_seq *lseq = seq;
7902 : 33906 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1679;
7903 : 33906 : {
7904 : 33906 : res_op->set_op (NOP_EXPR, type, 1);
7905 : 33906 : {
7906 : 33906 : tree _o1[1], _r1;
7907 : 33906 : _o1[0] = captures[1];
7908 : 33906 : gimple_match_op tem_op (res_op->cond.any_else (), VIEW_CONVERT_EXPR, stype, _o1[0]);
7909 : 33906 : tem_op.resimplify (lseq, valueize);
7910 : 33906 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
7911 : 33906 : if (!_r1) goto next_after_fail1679;
7912 : 17051 : res_op->ops[0] = _r1;
7913 : : }
7914 : 17051 : res_op->resimplify (lseq, valueize);
7915 : 17051 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 982, __FILE__, __LINE__, true);
7916 : 17051 : return true;
7917 : : }
7918 : 16855 : next_after_fail1679:;
7919 : : }
7920 : : }
7921 : : }
7922 : : }
7923 : : }
7924 : : break;
7925 : : }
7926 : 178 : case ADDR_EXPR:
7927 : 178 : {
7928 : 178 : switch (TREE_CODE (_p1))
7929 : : {
7930 : 174 : case SSA_NAME:
7931 : 174 : if (gimple *_d2 = get_def (valueize, _p1))
7932 : : {
7933 : 163 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
7934 : 192 : switch (gimple_assign_rhs_code (_a2))
7935 : : {
7936 : 16 : case POINTER_PLUS_EXPR:
7937 : 16 : {
7938 : 16 : tree _q30 = gimple_assign_rhs1 (_a2);
7939 : 16 : _q30 = do_valueize (valueize, _q30);
7940 : 16 : tree _q31 = gimple_assign_rhs2 (_a2);
7941 : 16 : _q31 = do_valueize (valueize, _q31);
7942 : 16 : {
7943 : 16 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q30, _q31 };
7944 : 16 : {
7945 : 16 : poly_int64 diff;
7946 : 16 : if (ptr_difference_const (captures[0], captures[1], &diff)
7947 : : )
7948 : : {
7949 : 0 : gimple_seq *lseq = seq;
7950 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1680;
7951 : 0 : {
7952 : 0 : res_op->set_op (MINUS_EXPR, type, 2);
7953 : 0 : res_op->ops[0] = build_int_cst_type (type, diff);
7954 : 0 : {
7955 : 0 : tree _o1[1], _r1;
7956 : 0 : _o1[0] = captures[2];
7957 : 0 : if (type != TREE_TYPE (_o1[0])
7958 : 0 : && !useless_type_conversion_p (type, TREE_TYPE (_o1[0])))
7959 : : {
7960 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type, _o1[0]);
7961 : 0 : tem_op.resimplify (lseq, valueize);
7962 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
7963 : 0 : if (!_r1) goto next_after_fail1680;
7964 : : }
7965 : : else
7966 : : _r1 = _o1[0];
7967 : 0 : res_op->ops[1] = _r1;
7968 : : }
7969 : 0 : res_op->resimplify (lseq, valueize);
7970 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 983, __FILE__, __LINE__, true);
7971 : 0 : return true;
7972 : : }
7973 : 16 : next_after_fail1680:;
7974 : : }
7975 : : }
7976 : : }
7977 : 16 : break;
7978 : : }
7979 : : default:;
7980 : : }
7981 : : }
7982 : : break;
7983 : : default:;
7984 : : }
7985 : : break;
7986 : : }
7987 : : default:;
7988 : : }
7989 : : }
7990 : : break;
7991 : 29562 : case ADDR_EXPR:
7992 : 29562 : {
7993 : 29562 : switch (TREE_CODE (_p1))
7994 : : {
7995 : 26645 : case SSA_NAME:
7996 : 26645 : if (gimple *_d1 = get_def (valueize, _p1))
7997 : : {
7998 : 15860 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
7999 : 3731 : switch (gimple_assign_rhs_code (_a1))
8000 : : {
8001 : 2727 : case POINTER_PLUS_EXPR:
8002 : 2727 : {
8003 : 2727 : tree _q30 = gimple_assign_rhs1 (_a1);
8004 : 2727 : _q30 = do_valueize (valueize, _q30);
8005 : 2727 : tree _q31 = gimple_assign_rhs2 (_a1);
8006 : 2727 : _q31 = do_valueize (valueize, _q31);
8007 : 2727 : {
8008 : 2727 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q30, _q31 };
8009 : 2727 : {
8010 : 2727 : poly_int64 diff;
8011 : 2727 : if (ptr_difference_const (captures[0], captures[1], &diff)
8012 : : )
8013 : : {
8014 : 37 : gimple_seq *lseq = seq;
8015 : 37 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1681;
8016 : 37 : {
8017 : 37 : res_op->set_op (MINUS_EXPR, type, 2);
8018 : 37 : res_op->ops[0] = build_int_cst_type (type, diff);
8019 : 37 : {
8020 : 37 : tree _o1[1], _r1;
8021 : 37 : _o1[0] = captures[2];
8022 : 37 : if (type != TREE_TYPE (_o1[0])
8023 : 37 : && !useless_type_conversion_p (type, TREE_TYPE (_o1[0])))
8024 : : {
8025 : 37 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type, _o1[0]);
8026 : 37 : tem_op.resimplify (lseq, valueize);
8027 : 37 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
8028 : 37 : if (!_r1) goto next_after_fail1681;
8029 : : }
8030 : : else
8031 : : _r1 = _o1[0];
8032 : 31 : res_op->ops[1] = _r1;
8033 : : }
8034 : 31 : res_op->resimplify (lseq, valueize);
8035 : 31 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 983, __FILE__, __LINE__, true);
8036 : 31 : return true;
8037 : : }
8038 : 2696 : next_after_fail1681:;
8039 : : }
8040 : : }
8041 : : }
8042 : 2696 : break;
8043 : : }
8044 : : default:;
8045 : : }
8046 : : }
8047 : : break;
8048 : : default:;
8049 : : }
8050 : : break;
8051 : : }
8052 : 1980024 : default:;
8053 : : }
8054 : 1980024 : switch (TREE_CODE (_p1))
8055 : : {
8056 : 1828191 : case SSA_NAME:
8057 : 1828191 : if (gimple *_d1 = get_def (valueize, _p1))
8058 : : {
8059 : 1219543 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
8060 : 1758585 : switch (gimple_assign_rhs_code (_a1))
8061 : : {
8062 : 56405 : case POINTER_PLUS_EXPR:
8063 : 56405 : {
8064 : 56405 : tree _q30 = gimple_assign_rhs1 (_a1);
8065 : 56405 : _q30 = do_valueize (valueize, _q30);
8066 : 56405 : tree _q31 = gimple_assign_rhs2 (_a1);
8067 : 56405 : _q31 = do_valueize (valueize, _q31);
8068 : 56405 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || operand_equal_p (_q30, _p0, 0))
8069 : : {
8070 : 298 : {
8071 : 298 : tree captures[3] ATTRIBUTE_UNUSED = { _q30, _q31, _p0 };
8072 : 298 : if (!TYPE_SATURATING (type)
8073 : : )
8074 : : {
8075 : 298 : if ((!FLOAT_TYPE_P (type) || flag_associative_math)
8076 : 596 : && !FIXED_POINT_TYPE_P (type)
8077 : : )
8078 : : {
8079 : 298 : {
8080 : 298 : tree stype = signed_type_for (TREE_TYPE (captures[1]));
8081 : 298 : gimple_seq *lseq = seq;
8082 : 298 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1682;
8083 : 298 : {
8084 : 298 : res_op->set_op (NEGATE_EXPR, type, 1);
8085 : 298 : {
8086 : 298 : tree _o1[1], _r1;
8087 : 298 : {
8088 : 298 : tree _o2[1], _r2;
8089 : 298 : _o2[0] = captures[1];
8090 : 298 : gimple_match_op tem_op (res_op->cond.any_else (), VIEW_CONVERT_EXPR, stype, _o2[0]);
8091 : 298 : tem_op.resimplify (lseq, valueize);
8092 : 298 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
8093 : 298 : if (!_r2) goto next_after_fail1682;
8094 : 147 : _o1[0] = _r2;
8095 : : }
8096 : 147 : if (type != TREE_TYPE (_o1[0])
8097 : 147 : && !useless_type_conversion_p (type, TREE_TYPE (_o1[0])))
8098 : : {
8099 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type, _o1[0]);
8100 : 0 : tem_op.resimplify (lseq, valueize);
8101 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
8102 : 0 : if (!_r1) goto next_after_fail1682;
8103 : : }
8104 : : else
8105 : : _r1 = _o1[0];
8106 : 147 : res_op->ops[0] = _r1;
8107 : : }
8108 : 147 : res_op->resimplify (lseq, valueize);
8109 : 147 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 984, __FILE__, __LINE__, true);
8110 : 147 : return true;
8111 : : }
8112 : 151 : next_after_fail1682:;
8113 : : }
8114 : : }
8115 : : }
8116 : : }
8117 : : }
8118 : : break;
8119 : : }
8120 : : default:;
8121 : : }
8122 : : }
8123 : : break;
8124 : 1979877 : default:;
8125 : : }
8126 : 1979877 : switch (TREE_CODE (_p0))
8127 : : {
8128 : 1925514 : case SSA_NAME:
8129 : 1925514 : if (gimple *_d1 = get_def (valueize, _p0))
8130 : : {
8131 : 1324594 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
8132 : 1753233 : switch (gimple_assign_rhs_code (_a1))
8133 : : {
8134 : 77792 : case POINTER_PLUS_EXPR:
8135 : 77792 : {
8136 : 77792 : tree _q20 = gimple_assign_rhs1 (_a1);
8137 : 77792 : _q20 = do_valueize (valueize, _q20);
8138 : 77792 : tree _q21 = gimple_assign_rhs2 (_a1);
8139 : 77792 : _q21 = do_valueize (valueize, _q21);
8140 : 77792 : switch (TREE_CODE (_p1))
8141 : : {
8142 : 71115 : case SSA_NAME:
8143 : 71115 : if (gimple *_d2 = get_def (valueize, _p1))
8144 : : {
8145 : 68059 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
8146 : 76335 : switch (gimple_assign_rhs_code (_a2))
8147 : : {
8148 : 10735 : case POINTER_PLUS_EXPR:
8149 : 10735 : {
8150 : 10735 : tree _q50 = gimple_assign_rhs1 (_a2);
8151 : 10735 : _q50 = do_valueize (valueize, _q50);
8152 : 10735 : tree _q51 = gimple_assign_rhs2 (_a2);
8153 : 10735 : _q51 = do_valueize (valueize, _q51);
8154 : 10735 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
8155 : : {
8156 : 68 : {
8157 : 68 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _q50 };
8158 : 68 : if (!TYPE_SATURATING (type)
8159 : : )
8160 : : {
8161 : 68 : if ((!FLOAT_TYPE_P (type) || flag_associative_math)
8162 : 136 : && !FIXED_POINT_TYPE_P (type)
8163 : : )
8164 : : {
8165 : 68 : gimple_seq *lseq = seq;
8166 : 68 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1683;
8167 : 68 : {
8168 : 68 : res_op->set_op (POINTER_DIFF_EXPR, type, 2);
8169 : 68 : res_op->ops[0] = captures[0];
8170 : 68 : res_op->ops[1] = captures[2];
8171 : 68 : res_op->resimplify (lseq, valueize);
8172 : 68 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 985, __FILE__, __LINE__, true);
8173 : 68 : return true;
8174 : : }
8175 : 0 : next_after_fail1683:;
8176 : : }
8177 : : }
8178 : : }
8179 : : }
8180 : 10667 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || operand_equal_p (_q50, _q20, 0))
8181 : : {
8182 : 182 : {
8183 : 182 : tree captures[4] ATTRIBUTE_UNUSED = { _q20, _q21, _q51, _q20 };
8184 : 182 : if (!TYPE_SATURATING (type)
8185 : : )
8186 : : {
8187 : 182 : if ((!FLOAT_TYPE_P (type) || flag_associative_math)
8188 : 364 : && !FIXED_POINT_TYPE_P (type)
8189 : : )
8190 : : {
8191 : 182 : {
8192 : 182 : tree stype = signed_type_for (TREE_TYPE (captures[1]));
8193 : 182 : gimple_seq *lseq = seq;
8194 : 182 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1684;
8195 : 182 : {
8196 : 182 : res_op->set_op (MINUS_EXPR, type, 2);
8197 : 182 : {
8198 : 182 : tree _o1[1], _r1;
8199 : 182 : {
8200 : 182 : tree _o2[1], _r2;
8201 : 182 : _o2[0] = captures[1];
8202 : 182 : gimple_match_op tem_op (res_op->cond.any_else (), VIEW_CONVERT_EXPR, stype, _o2[0]);
8203 : 182 : tem_op.resimplify (lseq, valueize);
8204 : 182 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
8205 : 182 : if (!_r2) goto next_after_fail1684;
8206 : 87 : _o1[0] = _r2;
8207 : : }
8208 : 87 : if (type != TREE_TYPE (_o1[0])
8209 : 87 : && !useless_type_conversion_p (type, TREE_TYPE (_o1[0])))
8210 : : {
8211 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type, _o1[0]);
8212 : 0 : tem_op.resimplify (lseq, valueize);
8213 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
8214 : 0 : if (!_r1) goto next_after_fail1684;
8215 : : }
8216 : : else
8217 : : _r1 = _o1[0];
8218 : 87 : res_op->ops[0] = _r1;
8219 : : }
8220 : 87 : {
8221 : 87 : tree _o1[1], _r1;
8222 : 87 : {
8223 : 87 : tree _o2[1], _r2;
8224 : 87 : _o2[0] = captures[2];
8225 : 87 : gimple_match_op tem_op (res_op->cond.any_else (), VIEW_CONVERT_EXPR, stype, _o2[0]);
8226 : 87 : tem_op.resimplify (lseq, valueize);
8227 : 87 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
8228 : 87 : if (!_r2) goto next_after_fail1684;
8229 : 62 : _o1[0] = _r2;
8230 : : }
8231 : 62 : if (type != TREE_TYPE (_o1[0])
8232 : 62 : && !useless_type_conversion_p (type, TREE_TYPE (_o1[0])))
8233 : : {
8234 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type, _o1[0]);
8235 : 0 : tem_op.resimplify (lseq, valueize);
8236 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
8237 : 0 : if (!_r1) goto next_after_fail1684;
8238 : : }
8239 : : else
8240 : : _r1 = _o1[0];
8241 : 62 : res_op->ops[1] = _r1;
8242 : : }
8243 : 62 : res_op->resimplify (lseq, valueize);
8244 : 62 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 986, __FILE__, __LINE__, true);
8245 : 62 : return true;
8246 : : }
8247 : 120 : next_after_fail1684:;
8248 : : }
8249 : : }
8250 : : }
8251 : : }
8252 : : }
8253 : : break;
8254 : : }
8255 : : default:;
8256 : : }
8257 : : }
8258 : : break;
8259 : : default:;
8260 : : }
8261 : : break;
8262 : : }
8263 : : default:;
8264 : : }
8265 : : }
8266 : : break;
8267 : 1979747 : default:;
8268 : : }
8269 : 1979747 : if (integer_zerop (_p0))
8270 : : {
8271 : 867 : {
8272 : 867 : tree captures[1] ATTRIBUTE_UNUSED = { _p1 };
8273 : 867 : gimple_seq *lseq = seq;
8274 : 867 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1685;
8275 : 867 : {
8276 : 867 : res_op->set_op (NEGATE_EXPR, type, 1);
8277 : 867 : {
8278 : 867 : tree _o1[1], _r1;
8279 : 867 : _o1[0] = captures[0];
8280 : 867 : if (type != TREE_TYPE (_o1[0])
8281 : 867 : && !useless_type_conversion_p (type, TREE_TYPE (_o1[0])))
8282 : : {
8283 : 867 : gimple_match_op tem_op (res_op->cond.any_else (), NOP_EXPR, type, _o1[0]);
8284 : 867 : tem_op.resimplify (lseq, valueize);
8285 : 867 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
8286 : 867 : if (!_r1) goto next_after_fail1685;
8287 : : }
8288 : : else
8289 : : _r1 = _o1[0];
8290 : 105 : res_op->ops[0] = _r1;
8291 : : }
8292 : 105 : res_op->resimplify (lseq, valueize);
8293 : 105 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 987, __FILE__, __LINE__, true);
8294 : 105 : return true;
8295 : : }
8296 : : next_after_fail1685:;
8297 : : }
8298 : : }
8299 : : return false;
8300 : : }
8301 : :
8302 : : bool
8303 : 1626 : gimple_simplify_CEIL_DIV_EXPR (gimple_match_op *res_op, gimple_seq *seq,
8304 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
8305 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0, tree _p1)
8306 : : {
8307 : 1626 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
8308 : 1626 : if (integer_onep (_p1))
8309 : : {
8310 : 72 : {
8311 : 72 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
8312 : 72 : if (gimple_simplify_185 (res_op, seq, valueize, type, captures, CEIL_DIV_EXPR))
8313 : 72 : return true;
8314 : : }
8315 : : }
8316 : 1554 : if (integer_zerop (_p0))
8317 : : {
8318 : 0 : {
8319 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
8320 : 0 : if (gimple_simplify_305 (res_op, seq, valueize, type, captures, CEIL_DIV_EXPR))
8321 : 0 : return true;
8322 : : }
8323 : : }
8324 : 1554 : switch (TREE_CODE (_p1))
8325 : : {
8326 : 444 : case SSA_NAME:
8327 : 444 : {
8328 : 444 : {
8329 : 444 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
8330 : 444 : if (gimple_simplify_307 (res_op, seq, valueize, type, captures, CEIL_DIV_EXPR))
8331 : 0 : return true;
8332 : : }
8333 : 444 : break;
8334 : : }
8335 : 1554 : default:;
8336 : : }
8337 : 1554 : if (integer_minus_onep (_p1))
8338 : : {
8339 : 0 : {
8340 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
8341 : 0 : if (gimple_simplify_306 (res_op, seq, valueize, type, captures, CEIL_DIV_EXPR))
8342 : 0 : return true;
8343 : : }
8344 : : }
8345 : 1554 : if ((_p1 == _p0 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _p0, 0) && types_match (_p1, _p0)))
8346 : : {
8347 : 0 : {
8348 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
8349 : 0 : if (gimple_simplify_308 (res_op, seq, valueize, type, captures, CEIL_DIV_EXPR))
8350 : 0 : return true;
8351 : : }
8352 : : }
8353 : 1554 : switch (TREE_CODE (_p1))
8354 : : {
8355 : 444 : case SSA_NAME:
8356 : 444 : if (gimple *_d1 = get_def (valueize, _p1))
8357 : : {
8358 : 334 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
8359 : 189 : switch (gimple_assign_rhs_code (_a1))
8360 : : {
8361 : 0 : case ABS_EXPR:
8362 : 0 : {
8363 : 0 : tree _q30 = gimple_assign_rhs1 (_a1);
8364 : 0 : _q30 = do_valueize (valueize, _q30);
8365 : 0 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || (operand_equal_p (_q30, _p0, 0) && types_match (_q30, _p0)))
8366 : : {
8367 : 0 : {
8368 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
8369 : 0 : if (gimple_simplify_309 (res_op, seq, valueize, type, captures, CEIL_DIV_EXPR))
8370 : 0 : return true;
8371 : : }
8372 : : }
8373 : : break;
8374 : : }
8375 : : default:;
8376 : : }
8377 : : }
8378 : : break;
8379 : 1554 : default:;
8380 : : }
8381 : 1554 : switch (TREE_CODE (_p0))
8382 : : {
8383 : 724 : case SSA_NAME:
8384 : 724 : if (gimple *_d1 = get_def (valueize, _p0))
8385 : : {
8386 : 543 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
8387 : 558 : switch (gimple_assign_rhs_code (_a1))
8388 : : {
8389 : 0 : case ABS_EXPR:
8390 : 0 : {
8391 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
8392 : 0 : _q20 = do_valueize (valueize, _q20);
8393 : 0 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
8394 : : {
8395 : 0 : {
8396 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
8397 : 0 : if (gimple_simplify_309 (res_op, seq, valueize, type, captures, CEIL_DIV_EXPR))
8398 : 0 : return true;
8399 : : }
8400 : : }
8401 : : break;
8402 : : }
8403 : : default:;
8404 : : }
8405 : : }
8406 : : break;
8407 : 1554 : default:;
8408 : : }
8409 : 1554 : switch (TREE_CODE (_p1))
8410 : : {
8411 : 444 : case SSA_NAME:
8412 : 444 : if (gimple *_d1 = get_def (valueize, _p1))
8413 : : {
8414 : 334 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
8415 : 189 : switch (gimple_assign_rhs_code (_a1))
8416 : : {
8417 : 0 : case NEGATE_EXPR:
8418 : 0 : {
8419 : 0 : tree _q30 = gimple_assign_rhs1 (_a1);
8420 : 0 : _q30 = do_valueize (valueize, _q30);
8421 : 0 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || (operand_equal_p (_q30, _p0, 0) && types_match (_q30, _p0)))
8422 : : {
8423 : 0 : {
8424 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
8425 : 0 : if (gimple_simplify_310 (res_op, seq, valueize, type, captures, CEIL_DIV_EXPR))
8426 : 0 : return true;
8427 : : }
8428 : : }
8429 : : break;
8430 : : }
8431 : : default:;
8432 : : }
8433 : : }
8434 : : break;
8435 : 1554 : default:;
8436 : : }
8437 : 1554 : switch (TREE_CODE (_p0))
8438 : : {
8439 : 724 : case SSA_NAME:
8440 : 724 : if (gimple *_d1 = get_def (valueize, _p0))
8441 : : {
8442 : 543 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
8443 : 558 : switch (gimple_assign_rhs_code (_a1))
8444 : : {
8445 : 0 : case NEGATE_EXPR:
8446 : 0 : {
8447 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
8448 : 0 : _q20 = do_valueize (valueize, _q20);
8449 : 0 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
8450 : : {
8451 : 0 : {
8452 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
8453 : 0 : if (gimple_simplify_310 (res_op, seq, valueize, type, captures, CEIL_DIV_EXPR))
8454 : 0 : return true;
8455 : : }
8456 : : }
8457 : : break;
8458 : : }
8459 : 0 : CASE_CONVERT:
8460 : 0 : {
8461 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
8462 : 0 : _q20 = do_valueize (valueize, _q20);
8463 : 0 : switch (TREE_CODE (_q20))
8464 : : {
8465 : 0 : case SSA_NAME:
8466 : 0 : if (gimple *_d2 = get_def (valueize, _q20))
8467 : : {
8468 : 0 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
8469 : 0 : switch (gimple_assign_rhs_code (_a2))
8470 : : {
8471 : 0 : case BIT_AND_EXPR:
8472 : 0 : {
8473 : 0 : tree _q30 = gimple_assign_rhs1 (_a2);
8474 : 0 : _q30 = do_valueize (valueize, _q30);
8475 : 0 : tree _q31 = gimple_assign_rhs2 (_a2);
8476 : 0 : _q31 = do_valueize (valueize, _q31);
8477 : 0 : if (tree_swap_operands_p (_q30, _q31))
8478 : 0 : std::swap (_q30, _q31);
8479 : 0 : switch (TREE_CODE (_q31))
8480 : : {
8481 : 0 : case INTEGER_CST:
8482 : 0 : {
8483 : 0 : switch (TREE_CODE (_p1))
8484 : : {
8485 : 0 : case INTEGER_CST:
8486 : 0 : {
8487 : 0 : {
8488 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q30, _q31, _p1 };
8489 : 0 : if (gimple_simplify_312 (res_op, seq, valueize, type, captures, CEIL_DIV_EXPR))
8490 : 0 : return true;
8491 : : }
8492 : 0 : break;
8493 : : }
8494 : : default:;
8495 : : }
8496 : : break;
8497 : : }
8498 : : default:;
8499 : : }
8500 : 1436 : break;
8501 : : }
8502 : : default:;
8503 : : }
8504 : : }
8505 : : break;
8506 : : default:;
8507 : : }
8508 : : break;
8509 : : }
8510 : 0 : case BIT_AND_EXPR:
8511 : 0 : {
8512 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
8513 : 0 : _q20 = do_valueize (valueize, _q20);
8514 : 0 : tree _q21 = gimple_assign_rhs2 (_a1);
8515 : 0 : _q21 = do_valueize (valueize, _q21);
8516 : 0 : if (tree_swap_operands_p (_q20, _q21))
8517 : 0 : std::swap (_q20, _q21);
8518 : 0 : switch (TREE_CODE (_q21))
8519 : : {
8520 : 0 : case INTEGER_CST:
8521 : 0 : {
8522 : 0 : switch (TREE_CODE (_p1))
8523 : : {
8524 : 0 : case INTEGER_CST:
8525 : 0 : {
8526 : 0 : {
8527 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
8528 : 0 : if (gimple_simplify_312 (res_op, seq, valueize, type, captures, CEIL_DIV_EXPR))
8529 : 0 : return true;
8530 : : }
8531 : 0 : break;
8532 : : }
8533 : : default:;
8534 : : }
8535 : : break;
8536 : : }
8537 : : default:;
8538 : : }
8539 : 1436 : break;
8540 : : }
8541 : 153 : case MULT_EXPR:
8542 : 153 : {
8543 : 153 : tree _q20 = gimple_assign_rhs1 (_a1);
8544 : 153 : _q20 = do_valueize (valueize, _q20);
8545 : 153 : tree _q21 = gimple_assign_rhs2 (_a1);
8546 : 153 : _q21 = do_valueize (valueize, _q21);
8547 : 153 : if (tree_swap_operands_p (_q20, _q21))
8548 : 64 : std::swap (_q20, _q21);
8549 : 153 : if ((_p1 == _q21 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q21, 0) && types_match (_p1, _q21)))
8550 : : {
8551 : 92 : {
8552 : 92 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
8553 : 92 : if (gimple_simplify_313 (res_op, seq, valueize, type, captures, CEIL_DIV_EXPR))
8554 : 92 : return true;
8555 : : }
8556 : : }
8557 : 61 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
8558 : : {
8559 : 0 : {
8560 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q21, _q20 };
8561 : 0 : if (gimple_simplify_313 (res_op, seq, valueize, type, captures, CEIL_DIV_EXPR))
8562 : 0 : return true;
8563 : : }
8564 : : }
8565 : 61 : switch (TREE_CODE (_q21))
8566 : : {
8567 : 41 : case INTEGER_CST:
8568 : 41 : {
8569 : 41 : switch (TREE_CODE (_p1))
8570 : : {
8571 : 0 : case SSA_NAME:
8572 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
8573 : : {
8574 : 0 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
8575 : 0 : switch (gimple_assign_rhs_code (_a2))
8576 : : {
8577 : 0 : case MULT_EXPR:
8578 : 0 : {
8579 : 0 : tree _q50 = gimple_assign_rhs1 (_a2);
8580 : 0 : _q50 = do_valueize (valueize, _q50);
8581 : 0 : tree _q51 = gimple_assign_rhs2 (_a2);
8582 : 0 : _q51 = do_valueize (valueize, _q51);
8583 : 0 : if (tree_swap_operands_p (_q50, _q51))
8584 : 0 : std::swap (_q50, _q51);
8585 : 0 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
8586 : : {
8587 : 0 : switch (TREE_CODE (_q51))
8588 : : {
8589 : 0 : case INTEGER_CST:
8590 : 0 : {
8591 : 0 : {
8592 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _q51 };
8593 : 0 : if (gimple_simplify_315 (res_op, seq, valueize, type, captures, CEIL_DIV_EXPR))
8594 : 0 : return true;
8595 : : }
8596 : 0 : break;
8597 : : }
8598 : : default:;
8599 : : }
8600 : : }
8601 : 1436 : break;
8602 : : }
8603 : : default:;
8604 : : }
8605 : : }
8606 : : break;
8607 : 41 : case INTEGER_CST:
8608 : 41 : {
8609 : 41 : {
8610 : 41 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
8611 : 41 : if (gimple_simplify_314 (res_op, seq, valueize, type, captures, CEIL_DIV_EXPR))
8612 : 26 : return true;
8613 : : }
8614 : 15 : break;
8615 : : }
8616 : : default:;
8617 : : }
8618 : : break;
8619 : : }
8620 : : default:;
8621 : : }
8622 : 1436 : break;
8623 : : }
8624 : 0 : case VEC_COND_EXPR:
8625 : 0 : {
8626 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
8627 : 0 : _q20 = do_valueize (valueize, _q20);
8628 : 0 : tree _q21 = gimple_assign_rhs2 (_a1);
8629 : 0 : _q21 = do_valueize (valueize, _q21);
8630 : 0 : tree _q22 = gimple_assign_rhs3 (_a1);
8631 : 0 : _q22 = do_valueize (valueize, _q22);
8632 : 0 : switch (TREE_CODE (_p1))
8633 : : {
8634 : 0 : case SSA_NAME:
8635 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
8636 : : {
8637 : 0 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
8638 : 0 : switch (gimple_assign_rhs_code (_a2))
8639 : : {
8640 : 0 : case VEC_COND_EXPR:
8641 : 0 : {
8642 : 0 : tree _q60 = gimple_assign_rhs1 (_a2);
8643 : 0 : _q60 = do_valueize (valueize, _q60);
8644 : 0 : tree _q61 = gimple_assign_rhs2 (_a2);
8645 : 0 : _q61 = do_valueize (valueize, _q61);
8646 : 0 : tree _q62 = gimple_assign_rhs3 (_a2);
8647 : 0 : _q62 = do_valueize (valueize, _q62);
8648 : 0 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
8649 : : {
8650 : 0 : {
8651 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q22, _p1, _q61, _q62 };
8652 : 0 : if (TREE_CODE_CLASS (CEIL_DIV_EXPR) != tcc_comparison
8653 : : || types_match (type, TREE_TYPE (captures[2]))
8654 : : || expand_vec_cond_expr_p (type, TREE_TYPE (captures[1]), ERROR_MARK)
8655 : : || (optimize_vectors_before_lowering_p ()
8656 : : && !expand_vec_cond_expr_p (TREE_TYPE (captures[2]),
8657 : : TREE_TYPE (captures[1]), ERROR_MARK))
8658 : : )
8659 : : {
8660 : 0 : gimple_seq *lseq = seq;
8661 : 0 : if (lseq
8662 : 0 : && (!single_use (captures[0])
8663 : 0 : || !single_use (captures[4])))
8664 : 0 : lseq = NULL;
8665 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1891;
8666 : 0 : {
8667 : 0 : res_op->set_op (VEC_COND_EXPR, type, 3);
8668 : 0 : res_op->ops[0] = captures[1];
8669 : 0 : {
8670 : 0 : tree _o1[2], _r1;
8671 : 0 : _o1[0] = captures[2];
8672 : 0 : _o1[1] = captures[5];
8673 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CEIL_DIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
8674 : 0 : tem_op.resimplify (NULL, valueize);
8675 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
8676 : 0 : if (!_r1) goto next_after_fail1891;
8677 : 0 : res_op->ops[1] = _r1;
8678 : : }
8679 : 0 : {
8680 : 0 : tree _o1[2], _r1;
8681 : 0 : _o1[0] = captures[3];
8682 : 0 : _o1[1] = captures[6];
8683 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CEIL_DIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
8684 : 0 : tem_op.resimplify (NULL, valueize);
8685 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
8686 : 0 : if (!_r1) goto next_after_fail1891;
8687 : 0 : res_op->ops[2] = _r1;
8688 : : }
8689 : 0 : res_op->resimplify (lseq, valueize);
8690 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 925, __FILE__, __LINE__, true);
8691 : 0 : return true;
8692 : : }
8693 : 0 : next_after_fail1891:;
8694 : : }
8695 : : }
8696 : : }
8697 : : break;
8698 : : }
8699 : : default:;
8700 : : }
8701 : : }
8702 : : break;
8703 : 0 : default:;
8704 : : }
8705 : 0 : {
8706 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q22, _p1 };
8707 : 0 : if (TREE_CODE_CLASS (CEIL_DIV_EXPR) != tcc_comparison
8708 : : || types_match (type, TREE_TYPE (captures[2]))
8709 : : || expand_vec_cond_expr_p (type, TREE_TYPE (captures[1]), ERROR_MARK)
8710 : : || (optimize_vectors_before_lowering_p ()
8711 : : && !expand_vec_cond_expr_p (TREE_TYPE (captures[2]),
8712 : : TREE_TYPE (captures[1]), ERROR_MARK))
8713 : : )
8714 : : {
8715 : 0 : gimple_seq *lseq = seq;
8716 : 0 : if (lseq
8717 : 0 : && (!single_use (captures[0])))
8718 : 0 : lseq = NULL;
8719 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1892;
8720 : 0 : {
8721 : 0 : res_op->set_op (VEC_COND_EXPR, type, 3);
8722 : 0 : res_op->ops[0] = captures[1];
8723 : 0 : {
8724 : 0 : tree _o1[2], _r1;
8725 : 0 : _o1[0] = captures[2];
8726 : 0 : _o1[1] = captures[4];
8727 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CEIL_DIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
8728 : 0 : tem_op.resimplify (NULL, valueize);
8729 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
8730 : 0 : if (!_r1) goto next_after_fail1892;
8731 : 0 : res_op->ops[1] = _r1;
8732 : : }
8733 : 0 : {
8734 : 0 : tree _o1[2], _r1;
8735 : 0 : _o1[0] = captures[3];
8736 : 0 : _o1[1] = captures[4];
8737 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CEIL_DIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
8738 : 0 : tem_op.resimplify (NULL, valueize);
8739 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
8740 : 0 : if (!_r1) goto next_after_fail1892;
8741 : 0 : res_op->ops[2] = _r1;
8742 : : }
8743 : 0 : res_op->resimplify (lseq, valueize);
8744 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 926, __FILE__, __LINE__, true);
8745 : 0 : return true;
8746 : : }
8747 : 0 : next_after_fail1892:;
8748 : : }
8749 : : }
8750 : 0 : break;
8751 : : }
8752 : : default:;
8753 : : }
8754 : : }
8755 : : break;
8756 : 1436 : default:;
8757 : : }
8758 : 1436 : switch (TREE_CODE (_p1))
8759 : : {
8760 : 444 : case SSA_NAME:
8761 : 444 : if (gimple *_d1 = get_def (valueize, _p1))
8762 : : {
8763 : 334 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
8764 : 189 : switch (gimple_assign_rhs_code (_a1))
8765 : : {
8766 : 0 : case VEC_COND_EXPR:
8767 : 0 : {
8768 : 0 : tree _q30 = gimple_assign_rhs1 (_a1);
8769 : 0 : _q30 = do_valueize (valueize, _q30);
8770 : 0 : tree _q31 = gimple_assign_rhs2 (_a1);
8771 : 0 : _q31 = do_valueize (valueize, _q31);
8772 : 0 : tree _q32 = gimple_assign_rhs3 (_a1);
8773 : 0 : _q32 = do_valueize (valueize, _q32);
8774 : 0 : {
8775 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q31, _q32 };
8776 : 0 : if (TREE_CODE_CLASS (CEIL_DIV_EXPR) != tcc_comparison
8777 : : || types_match (type, TREE_TYPE (captures[3]))
8778 : : || expand_vec_cond_expr_p (type, TREE_TYPE (captures[2]), ERROR_MARK)
8779 : : || (optimize_vectors_before_lowering_p ()
8780 : : && !expand_vec_cond_expr_p (TREE_TYPE (captures[3]),
8781 : : TREE_TYPE (captures[2]), ERROR_MARK))
8782 : : )
8783 : : {
8784 : 0 : gimple_seq *lseq = seq;
8785 : 0 : if (lseq
8786 : 0 : && (!single_use (captures[1])))
8787 : 0 : lseq = NULL;
8788 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1893;
8789 : 0 : {
8790 : 0 : res_op->set_op (VEC_COND_EXPR, type, 3);
8791 : 0 : res_op->ops[0] = captures[2];
8792 : 0 : {
8793 : 0 : tree _o1[2], _r1;
8794 : 0 : _o1[0] = captures[0];
8795 : 0 : _o1[1] = captures[3];
8796 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CEIL_DIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
8797 : 0 : tem_op.resimplify (NULL, valueize);
8798 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
8799 : 0 : if (!_r1) goto next_after_fail1893;
8800 : 0 : res_op->ops[1] = _r1;
8801 : : }
8802 : 0 : {
8803 : 0 : tree _o1[2], _r1;
8804 : 0 : _o1[0] = captures[0];
8805 : 0 : _o1[1] = captures[4];
8806 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CEIL_DIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
8807 : 0 : tem_op.resimplify (NULL, valueize);
8808 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
8809 : 0 : if (!_r1) goto next_after_fail1893;
8810 : 0 : res_op->ops[2] = _r1;
8811 : : }
8812 : 0 : res_op->resimplify (lseq, valueize);
8813 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 927, __FILE__, __LINE__, true);
8814 : 0 : return true;
8815 : : }
8816 : 0 : next_after_fail1893:;
8817 : : }
8818 : : }
8819 : 0 : break;
8820 : : }
8821 : : default:;
8822 : : }
8823 : : }
8824 : : break;
8825 : : default:;
8826 : : }
8827 : : return false;
8828 : : }
8829 : :
8830 : : bool
8831 : 0 : gimple_simplify_ROUND_DIV_EXPR (gimple_match_op *res_op, gimple_seq *seq,
8832 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
8833 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0, tree _p1)
8834 : : {
8835 : 0 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
8836 : 0 : if (integer_onep (_p1))
8837 : : {
8838 : 0 : {
8839 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
8840 : 0 : if (gimple_simplify_185 (res_op, seq, valueize, type, captures, ROUND_DIV_EXPR))
8841 : 0 : return true;
8842 : : }
8843 : : }
8844 : 0 : if (integer_zerop (_p0))
8845 : : {
8846 : 0 : {
8847 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
8848 : 0 : if (gimple_simplify_305 (res_op, seq, valueize, type, captures, ROUND_DIV_EXPR))
8849 : 0 : return true;
8850 : : }
8851 : : }
8852 : 0 : switch (TREE_CODE (_p1))
8853 : : {
8854 : 0 : case SSA_NAME:
8855 : 0 : {
8856 : 0 : {
8857 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
8858 : 0 : if (gimple_simplify_307 (res_op, seq, valueize, type, captures, ROUND_DIV_EXPR))
8859 : 0 : return true;
8860 : : }
8861 : 0 : break;
8862 : : }
8863 : 0 : default:;
8864 : : }
8865 : 0 : if (integer_minus_onep (_p1))
8866 : : {
8867 : 0 : {
8868 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
8869 : 0 : if (gimple_simplify_306 (res_op, seq, valueize, type, captures, ROUND_DIV_EXPR))
8870 : 0 : return true;
8871 : : }
8872 : : }
8873 : 0 : if ((_p1 == _p0 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _p0, 0) && types_match (_p1, _p0)))
8874 : : {
8875 : 0 : {
8876 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
8877 : 0 : if (gimple_simplify_308 (res_op, seq, valueize, type, captures, ROUND_DIV_EXPR))
8878 : 0 : return true;
8879 : : }
8880 : : }
8881 : 0 : switch (TREE_CODE (_p1))
8882 : : {
8883 : 0 : case SSA_NAME:
8884 : 0 : if (gimple *_d1 = get_def (valueize, _p1))
8885 : : {
8886 : 0 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
8887 : 0 : switch (gimple_assign_rhs_code (_a1))
8888 : : {
8889 : 0 : case ABS_EXPR:
8890 : 0 : {
8891 : 0 : tree _q30 = gimple_assign_rhs1 (_a1);
8892 : 0 : _q30 = do_valueize (valueize, _q30);
8893 : 0 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || (operand_equal_p (_q30, _p0, 0) && types_match (_q30, _p0)))
8894 : : {
8895 : 0 : {
8896 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
8897 : 0 : if (gimple_simplify_309 (res_op, seq, valueize, type, captures, ROUND_DIV_EXPR))
8898 : 0 : return true;
8899 : : }
8900 : : }
8901 : : break;
8902 : : }
8903 : : default:;
8904 : : }
8905 : : }
8906 : : break;
8907 : 0 : default:;
8908 : : }
8909 : 0 : switch (TREE_CODE (_p0))
8910 : : {
8911 : 0 : case SSA_NAME:
8912 : 0 : if (gimple *_d1 = get_def (valueize, _p0))
8913 : : {
8914 : 0 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
8915 : 0 : switch (gimple_assign_rhs_code (_a1))
8916 : : {
8917 : 0 : case ABS_EXPR:
8918 : 0 : {
8919 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
8920 : 0 : _q20 = do_valueize (valueize, _q20);
8921 : 0 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
8922 : : {
8923 : 0 : {
8924 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
8925 : 0 : if (gimple_simplify_309 (res_op, seq, valueize, type, captures, ROUND_DIV_EXPR))
8926 : 0 : return true;
8927 : : }
8928 : : }
8929 : : break;
8930 : : }
8931 : : default:;
8932 : : }
8933 : : }
8934 : : break;
8935 : 0 : default:;
8936 : : }
8937 : 0 : switch (TREE_CODE (_p1))
8938 : : {
8939 : 0 : case SSA_NAME:
8940 : 0 : if (gimple *_d1 = get_def (valueize, _p1))
8941 : : {
8942 : 0 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
8943 : 0 : switch (gimple_assign_rhs_code (_a1))
8944 : : {
8945 : 0 : case NEGATE_EXPR:
8946 : 0 : {
8947 : 0 : tree _q30 = gimple_assign_rhs1 (_a1);
8948 : 0 : _q30 = do_valueize (valueize, _q30);
8949 : 0 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || (operand_equal_p (_q30, _p0, 0) && types_match (_q30, _p0)))
8950 : : {
8951 : 0 : {
8952 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
8953 : 0 : if (gimple_simplify_310 (res_op, seq, valueize, type, captures, ROUND_DIV_EXPR))
8954 : 0 : return true;
8955 : : }
8956 : : }
8957 : : break;
8958 : : }
8959 : : default:;
8960 : : }
8961 : : }
8962 : : break;
8963 : 0 : default:;
8964 : : }
8965 : 0 : switch (TREE_CODE (_p0))
8966 : : {
8967 : 0 : case SSA_NAME:
8968 : 0 : if (gimple *_d1 = get_def (valueize, _p0))
8969 : : {
8970 : 0 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
8971 : 0 : switch (gimple_assign_rhs_code (_a1))
8972 : : {
8973 : 0 : case NEGATE_EXPR:
8974 : 0 : {
8975 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
8976 : 0 : _q20 = do_valueize (valueize, _q20);
8977 : 0 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
8978 : : {
8979 : 0 : {
8980 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
8981 : 0 : if (gimple_simplify_310 (res_op, seq, valueize, type, captures, ROUND_DIV_EXPR))
8982 : 0 : return true;
8983 : : }
8984 : : }
8985 : : break;
8986 : : }
8987 : 0 : CASE_CONVERT:
8988 : 0 : {
8989 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
8990 : 0 : _q20 = do_valueize (valueize, _q20);
8991 : 0 : switch (TREE_CODE (_q20))
8992 : : {
8993 : 0 : case SSA_NAME:
8994 : 0 : if (gimple *_d2 = get_def (valueize, _q20))
8995 : : {
8996 : 0 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
8997 : 0 : switch (gimple_assign_rhs_code (_a2))
8998 : : {
8999 : 0 : case BIT_AND_EXPR:
9000 : 0 : {
9001 : 0 : tree _q30 = gimple_assign_rhs1 (_a2);
9002 : 0 : _q30 = do_valueize (valueize, _q30);
9003 : 0 : tree _q31 = gimple_assign_rhs2 (_a2);
9004 : 0 : _q31 = do_valueize (valueize, _q31);
9005 : 0 : if (tree_swap_operands_p (_q30, _q31))
9006 : 0 : std::swap (_q30, _q31);
9007 : 0 : switch (TREE_CODE (_q31))
9008 : : {
9009 : 0 : case INTEGER_CST:
9010 : 0 : {
9011 : 0 : switch (TREE_CODE (_p1))
9012 : : {
9013 : 0 : case INTEGER_CST:
9014 : 0 : {
9015 : 0 : {
9016 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q30, _q31, _p1 };
9017 : 0 : if (gimple_simplify_312 (res_op, seq, valueize, type, captures, ROUND_DIV_EXPR))
9018 : 0 : return true;
9019 : : }
9020 : 0 : break;
9021 : : }
9022 : : default:;
9023 : : }
9024 : : break;
9025 : : }
9026 : : default:;
9027 : : }
9028 : 0 : break;
9029 : : }
9030 : : default:;
9031 : : }
9032 : : }
9033 : : break;
9034 : : default:;
9035 : : }
9036 : : break;
9037 : : }
9038 : 0 : case BIT_AND_EXPR:
9039 : 0 : {
9040 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
9041 : 0 : _q20 = do_valueize (valueize, _q20);
9042 : 0 : tree _q21 = gimple_assign_rhs2 (_a1);
9043 : 0 : _q21 = do_valueize (valueize, _q21);
9044 : 0 : if (tree_swap_operands_p (_q20, _q21))
9045 : 0 : std::swap (_q20, _q21);
9046 : 0 : switch (TREE_CODE (_q21))
9047 : : {
9048 : 0 : case INTEGER_CST:
9049 : 0 : {
9050 : 0 : switch (TREE_CODE (_p1))
9051 : : {
9052 : 0 : case INTEGER_CST:
9053 : 0 : {
9054 : 0 : {
9055 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
9056 : 0 : if (gimple_simplify_312 (res_op, seq, valueize, type, captures, ROUND_DIV_EXPR))
9057 : 0 : return true;
9058 : : }
9059 : 0 : break;
9060 : : }
9061 : : default:;
9062 : : }
9063 : : break;
9064 : : }
9065 : : default:;
9066 : : }
9067 : 0 : break;
9068 : : }
9069 : 0 : case MULT_EXPR:
9070 : 0 : {
9071 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
9072 : 0 : _q20 = do_valueize (valueize, _q20);
9073 : 0 : tree _q21 = gimple_assign_rhs2 (_a1);
9074 : 0 : _q21 = do_valueize (valueize, _q21);
9075 : 0 : if (tree_swap_operands_p (_q20, _q21))
9076 : 0 : std::swap (_q20, _q21);
9077 : 0 : if ((_p1 == _q21 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q21, 0) && types_match (_p1, _q21)))
9078 : : {
9079 : 0 : {
9080 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
9081 : 0 : if (gimple_simplify_313 (res_op, seq, valueize, type, captures, ROUND_DIV_EXPR))
9082 : 0 : return true;
9083 : : }
9084 : : }
9085 : 0 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
9086 : : {
9087 : 0 : {
9088 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q21, _q20 };
9089 : 0 : if (gimple_simplify_313 (res_op, seq, valueize, type, captures, ROUND_DIV_EXPR))
9090 : 0 : return true;
9091 : : }
9092 : : }
9093 : 0 : switch (TREE_CODE (_q21))
9094 : : {
9095 : 0 : case INTEGER_CST:
9096 : 0 : {
9097 : 0 : switch (TREE_CODE (_p1))
9098 : : {
9099 : 0 : case SSA_NAME:
9100 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
9101 : : {
9102 : 0 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
9103 : 0 : switch (gimple_assign_rhs_code (_a2))
9104 : : {
9105 : 0 : case MULT_EXPR:
9106 : 0 : {
9107 : 0 : tree _q50 = gimple_assign_rhs1 (_a2);
9108 : 0 : _q50 = do_valueize (valueize, _q50);
9109 : 0 : tree _q51 = gimple_assign_rhs2 (_a2);
9110 : 0 : _q51 = do_valueize (valueize, _q51);
9111 : 0 : if (tree_swap_operands_p (_q50, _q51))
9112 : 0 : std::swap (_q50, _q51);
9113 : 0 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
9114 : : {
9115 : 0 : switch (TREE_CODE (_q51))
9116 : : {
9117 : 0 : case INTEGER_CST:
9118 : 0 : {
9119 : 0 : {
9120 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _q51 };
9121 : 0 : if (gimple_simplify_315 (res_op, seq, valueize, type, captures, ROUND_DIV_EXPR))
9122 : 0 : return true;
9123 : : }
9124 : 0 : break;
9125 : : }
9126 : : default:;
9127 : : }
9128 : : }
9129 : 0 : break;
9130 : : }
9131 : : default:;
9132 : : }
9133 : : }
9134 : : break;
9135 : 0 : case INTEGER_CST:
9136 : 0 : {
9137 : 0 : {
9138 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
9139 : 0 : if (gimple_simplify_314 (res_op, seq, valueize, type, captures, ROUND_DIV_EXPR))
9140 : 0 : return true;
9141 : : }
9142 : 0 : break;
9143 : : }
9144 : : default:;
9145 : : }
9146 : : break;
9147 : : }
9148 : : default:;
9149 : : }
9150 : 0 : break;
9151 : : }
9152 : 0 : case VEC_COND_EXPR:
9153 : 0 : {
9154 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
9155 : 0 : _q20 = do_valueize (valueize, _q20);
9156 : 0 : tree _q21 = gimple_assign_rhs2 (_a1);
9157 : 0 : _q21 = do_valueize (valueize, _q21);
9158 : 0 : tree _q22 = gimple_assign_rhs3 (_a1);
9159 : 0 : _q22 = do_valueize (valueize, _q22);
9160 : 0 : switch (TREE_CODE (_p1))
9161 : : {
9162 : 0 : case SSA_NAME:
9163 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
9164 : : {
9165 : 0 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
9166 : 0 : switch (gimple_assign_rhs_code (_a2))
9167 : : {
9168 : 0 : case VEC_COND_EXPR:
9169 : 0 : {
9170 : 0 : tree _q60 = gimple_assign_rhs1 (_a2);
9171 : 0 : _q60 = do_valueize (valueize, _q60);
9172 : 0 : tree _q61 = gimple_assign_rhs2 (_a2);
9173 : 0 : _q61 = do_valueize (valueize, _q61);
9174 : 0 : tree _q62 = gimple_assign_rhs3 (_a2);
9175 : 0 : _q62 = do_valueize (valueize, _q62);
9176 : 0 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
9177 : : {
9178 : 0 : {
9179 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q22, _p1, _q61, _q62 };
9180 : 0 : if (TREE_CODE_CLASS (ROUND_DIV_EXPR) != tcc_comparison
9181 : : || types_match (type, TREE_TYPE (captures[2]))
9182 : : || expand_vec_cond_expr_p (type, TREE_TYPE (captures[1]), ERROR_MARK)
9183 : : || (optimize_vectors_before_lowering_p ()
9184 : : && !expand_vec_cond_expr_p (TREE_TYPE (captures[2]),
9185 : : TREE_TYPE (captures[1]), ERROR_MARK))
9186 : : )
9187 : : {
9188 : 0 : gimple_seq *lseq = seq;
9189 : 0 : if (lseq
9190 : 0 : && (!single_use (captures[0])
9191 : 0 : || !single_use (captures[4])))
9192 : 0 : lseq = NULL;
9193 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1897;
9194 : 0 : {
9195 : 0 : res_op->set_op (VEC_COND_EXPR, type, 3);
9196 : 0 : res_op->ops[0] = captures[1];
9197 : 0 : {
9198 : 0 : tree _o1[2], _r1;
9199 : 0 : _o1[0] = captures[2];
9200 : 0 : _o1[1] = captures[5];
9201 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), ROUND_DIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
9202 : 0 : tem_op.resimplify (NULL, valueize);
9203 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
9204 : 0 : if (!_r1) goto next_after_fail1897;
9205 : 0 : res_op->ops[1] = _r1;
9206 : : }
9207 : 0 : {
9208 : 0 : tree _o1[2], _r1;
9209 : 0 : _o1[0] = captures[3];
9210 : 0 : _o1[1] = captures[6];
9211 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), ROUND_DIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
9212 : 0 : tem_op.resimplify (NULL, valueize);
9213 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
9214 : 0 : if (!_r1) goto next_after_fail1897;
9215 : 0 : res_op->ops[2] = _r1;
9216 : : }
9217 : 0 : res_op->resimplify (lseq, valueize);
9218 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 925, __FILE__, __LINE__, true);
9219 : 0 : return true;
9220 : : }
9221 : 0 : next_after_fail1897:;
9222 : : }
9223 : : }
9224 : : }
9225 : : break;
9226 : : }
9227 : : default:;
9228 : : }
9229 : : }
9230 : : break;
9231 : 0 : default:;
9232 : : }
9233 : 0 : {
9234 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q22, _p1 };
9235 : 0 : if (TREE_CODE_CLASS (ROUND_DIV_EXPR) != tcc_comparison
9236 : : || types_match (type, TREE_TYPE (captures[2]))
9237 : : || expand_vec_cond_expr_p (type, TREE_TYPE (captures[1]), ERROR_MARK)
9238 : : || (optimize_vectors_before_lowering_p ()
9239 : : && !expand_vec_cond_expr_p (TREE_TYPE (captures[2]),
9240 : : TREE_TYPE (captures[1]), ERROR_MARK))
9241 : : )
9242 : : {
9243 : 0 : gimple_seq *lseq = seq;
9244 : 0 : if (lseq
9245 : 0 : && (!single_use (captures[0])))
9246 : 0 : lseq = NULL;
9247 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1898;
9248 : 0 : {
9249 : 0 : res_op->set_op (VEC_COND_EXPR, type, 3);
9250 : 0 : res_op->ops[0] = captures[1];
9251 : 0 : {
9252 : 0 : tree _o1[2], _r1;
9253 : 0 : _o1[0] = captures[2];
9254 : 0 : _o1[1] = captures[4];
9255 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), ROUND_DIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
9256 : 0 : tem_op.resimplify (NULL, valueize);
9257 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
9258 : 0 : if (!_r1) goto next_after_fail1898;
9259 : 0 : res_op->ops[1] = _r1;
9260 : : }
9261 : 0 : {
9262 : 0 : tree _o1[2], _r1;
9263 : 0 : _o1[0] = captures[3];
9264 : 0 : _o1[1] = captures[4];
9265 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), ROUND_DIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
9266 : 0 : tem_op.resimplify (NULL, valueize);
9267 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
9268 : 0 : if (!_r1) goto next_after_fail1898;
9269 : 0 : res_op->ops[2] = _r1;
9270 : : }
9271 : 0 : res_op->resimplify (lseq, valueize);
9272 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 926, __FILE__, __LINE__, true);
9273 : 0 : return true;
9274 : : }
9275 : 0 : next_after_fail1898:;
9276 : : }
9277 : : }
9278 : 0 : break;
9279 : : }
9280 : : default:;
9281 : : }
9282 : : }
9283 : : break;
9284 : 0 : default:;
9285 : : }
9286 : 0 : switch (TREE_CODE (_p1))
9287 : : {
9288 : 0 : case SSA_NAME:
9289 : 0 : if (gimple *_d1 = get_def (valueize, _p1))
9290 : : {
9291 : 0 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
9292 : 0 : switch (gimple_assign_rhs_code (_a1))
9293 : : {
9294 : 0 : case VEC_COND_EXPR:
9295 : 0 : {
9296 : 0 : tree _q30 = gimple_assign_rhs1 (_a1);
9297 : 0 : _q30 = do_valueize (valueize, _q30);
9298 : 0 : tree _q31 = gimple_assign_rhs2 (_a1);
9299 : 0 : _q31 = do_valueize (valueize, _q31);
9300 : 0 : tree _q32 = gimple_assign_rhs3 (_a1);
9301 : 0 : _q32 = do_valueize (valueize, _q32);
9302 : 0 : {
9303 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q31, _q32 };
9304 : 0 : if (TREE_CODE_CLASS (ROUND_DIV_EXPR) != tcc_comparison
9305 : : || types_match (type, TREE_TYPE (captures[3]))
9306 : : || expand_vec_cond_expr_p (type, TREE_TYPE (captures[2]), ERROR_MARK)
9307 : : || (optimize_vectors_before_lowering_p ()
9308 : : && !expand_vec_cond_expr_p (TREE_TYPE (captures[3]),
9309 : : TREE_TYPE (captures[2]), ERROR_MARK))
9310 : : )
9311 : : {
9312 : 0 : gimple_seq *lseq = seq;
9313 : 0 : if (lseq
9314 : 0 : && (!single_use (captures[1])))
9315 : 0 : lseq = NULL;
9316 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1899;
9317 : 0 : {
9318 : 0 : res_op->set_op (VEC_COND_EXPR, type, 3);
9319 : 0 : res_op->ops[0] = captures[2];
9320 : 0 : {
9321 : 0 : tree _o1[2], _r1;
9322 : 0 : _o1[0] = captures[0];
9323 : 0 : _o1[1] = captures[3];
9324 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), ROUND_DIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
9325 : 0 : tem_op.resimplify (NULL, valueize);
9326 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
9327 : 0 : if (!_r1) goto next_after_fail1899;
9328 : 0 : res_op->ops[1] = _r1;
9329 : : }
9330 : 0 : {
9331 : 0 : tree _o1[2], _r1;
9332 : 0 : _o1[0] = captures[0];
9333 : 0 : _o1[1] = captures[4];
9334 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), ROUND_DIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
9335 : 0 : tem_op.resimplify (NULL, valueize);
9336 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
9337 : 0 : if (!_r1) goto next_after_fail1899;
9338 : 0 : res_op->ops[2] = _r1;
9339 : : }
9340 : 0 : res_op->resimplify (lseq, valueize);
9341 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 927, __FILE__, __LINE__, true);
9342 : 0 : return true;
9343 : : }
9344 : 0 : next_after_fail1899:;
9345 : : }
9346 : : }
9347 : 0 : break;
9348 : : }
9349 : : default:;
9350 : : }
9351 : : }
9352 : : break;
9353 : : default:;
9354 : : }
9355 : : return false;
9356 : : }
9357 : :
9358 : : bool
9359 : 548984 : gimple_simplify_RDIV_EXPR (gimple_match_op *res_op, gimple_seq *seq,
9360 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
9361 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0, tree _p1)
9362 : : {
9363 : 548984 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
9364 : 548984 : if ((_p1 == _p0 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _p0, 0) && types_match (_p1, _p0)))
9365 : : {
9366 : 2997 : {
9367 : 2997 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
9368 : 220 : if (FLOAT_TYPE_P (type)
9369 : 2997 : && ! HONOR_NANS (type)
9370 : 2997 : && ! HONOR_INFINITIES (type)
9371 : : )
9372 : : {
9373 : 0 : gimple_seq *lseq = seq;
9374 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1905;
9375 : 0 : {
9376 : 0 : tree tem;
9377 : 0 : tem = build_one_cst (type);
9378 : 0 : res_op->set_value (tem);
9379 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1021, __FILE__, __LINE__, true);
9380 : 0 : return true;
9381 : : }
9382 : 0 : next_after_fail1905:;
9383 : : }
9384 : : }
9385 : : }
9386 : 548984 : switch (TREE_CODE (_p1))
9387 : : {
9388 : 452833 : case SSA_NAME:
9389 : 452833 : if (gimple *_d1 = get_def (valueize, _p1))
9390 : : {
9391 : 339032 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
9392 : 300760 : switch (gimple_assign_rhs_code (_a1))
9393 : : {
9394 : 74 : case NEGATE_EXPR:
9395 : 74 : {
9396 : 74 : tree _q30 = gimple_assign_rhs1 (_a1);
9397 : 74 : _q30 = do_valueize (valueize, _q30);
9398 : 74 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || (operand_equal_p (_q30, _p0, 0) && types_match (_q30, _p0)))
9399 : : {
9400 : 0 : {
9401 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
9402 : 0 : if (gimple_simplify_326 (res_op, seq, valueize, type, captures))
9403 : 0 : return true;
9404 : : }
9405 : : }
9406 : : break;
9407 : : }
9408 : : default:;
9409 : : }
9410 : : }
9411 : : break;
9412 : 548984 : default:;
9413 : : }
9414 : 548984 : switch (TREE_CODE (_p0))
9415 : : {
9416 : 326108 : case SSA_NAME:
9417 : 326108 : if (gimple *_d1 = get_def (valueize, _p0))
9418 : : {
9419 : 257566 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
9420 : 250916 : switch (gimple_assign_rhs_code (_a1))
9421 : : {
9422 : 5023 : case NEGATE_EXPR:
9423 : 5023 : {
9424 : 5023 : tree _q20 = gimple_assign_rhs1 (_a1);
9425 : 5023 : _q20 = do_valueize (valueize, _q20);
9426 : 5023 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
9427 : : {
9428 : 48 : {
9429 : 48 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
9430 : 48 : if (gimple_simplify_326 (res_op, seq, valueize, type, captures))
9431 : 0 : return true;
9432 : : }
9433 : : }
9434 : : break;
9435 : : }
9436 : 14782 : CASE_CONVERT:
9437 : 14782 : {
9438 : 14782 : tree _q20 = gimple_assign_rhs1 (_a1);
9439 : 14782 : _q20 = do_valueize (valueize, _q20);
9440 : 14782 : switch (TREE_CODE (_p1))
9441 : : {
9442 : 12535 : case SSA_NAME:
9443 : 12535 : if (gimple *_d2 = get_def (valueize, _p1))
9444 : : {
9445 : 11824 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
9446 : 12149 : switch (gimple_assign_rhs_code (_a2))
9447 : : {
9448 : 9350 : CASE_CONVERT:
9449 : 9350 : {
9450 : 9350 : tree _q40 = gimple_assign_rhs1 (_a2);
9451 : 9350 : _q40 = do_valueize (valueize, _q40);
9452 : 9350 : switch (TREE_CODE (_q40))
9453 : : {
9454 : 9350 : case SSA_NAME:
9455 : 9350 : if (gimple *_d3 = get_def (valueize, _q40))
9456 : : {
9457 : 9178 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
9458 : 8763 : switch (gimple_assign_rhs_code (_a3))
9459 : : {
9460 : 47 : case ABS_EXPR:
9461 : 47 : {
9462 : 47 : tree _q50 = gimple_assign_rhs1 (_a3);
9463 : 47 : _q50 = do_valueize (valueize, _q50);
9464 : 47 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
9465 : : {
9466 : 2 : {
9467 : 2 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
9468 : 2 : if (gimple_simplify_327 (res_op, seq, valueize, type, captures))
9469 : 1 : return true;
9470 : : }
9471 : : }
9472 : : break;
9473 : : }
9474 : : default:;
9475 : : }
9476 : : }
9477 : : break;
9478 : : default:;
9479 : : }
9480 : : break;
9481 : : }
9482 : : default:;
9483 : : }
9484 : : }
9485 : : break;
9486 : 14781 : default:;
9487 : : }
9488 : 14781 : switch (TREE_CODE (_q20))
9489 : : {
9490 : 14781 : case SSA_NAME:
9491 : 14781 : if (gimple *_d2 = get_def (valueize, _q20))
9492 : : {
9493 : 14218 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
9494 : 15273 : switch (gimple_assign_rhs_code (_a2))
9495 : : {
9496 : 382 : case ABS_EXPR:
9497 : 382 : {
9498 : 382 : tree _q30 = gimple_assign_rhs1 (_a2);
9499 : 382 : _q30 = do_valueize (valueize, _q30);
9500 : 382 : switch (TREE_CODE (_p1))
9501 : : {
9502 : 350 : case SSA_NAME:
9503 : 350 : if (gimple *_d3 = get_def (valueize, _p1))
9504 : : {
9505 : 350 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
9506 : 346 : switch (gimple_assign_rhs_code (_a3))
9507 : : {
9508 : 282 : CASE_CONVERT:
9509 : 282 : {
9510 : 282 : tree _q50 = gimple_assign_rhs1 (_a3);
9511 : 282 : _q50 = do_valueize (valueize, _q50);
9512 : 282 : if ((_q50 == _q30 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q30, 0) && types_match (_q50, _q30)))
9513 : : {
9514 : 0 : {
9515 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q30 };
9516 : 0 : if (gimple_simplify_327 (res_op, seq, valueize, type, captures))
9517 : 0 : return true;
9518 : : }
9519 : : }
9520 : : break;
9521 : : }
9522 : : default:;
9523 : : }
9524 : : }
9525 : : break;
9526 : : default:;
9527 : : }
9528 : : break;
9529 : : }
9530 : : default:;
9531 : : }
9532 : : }
9533 : : break;
9534 : : default:;
9535 : : }
9536 : : break;
9537 : : }
9538 : : default:;
9539 : : }
9540 : : }
9541 : : break;
9542 : 548983 : default:;
9543 : : }
9544 : 548983 : switch (TREE_CODE (_p1))
9545 : : {
9546 : 452832 : case SSA_NAME:
9547 : 452832 : if (gimple *_d1 = get_def (valueize, _p1))
9548 : : {
9549 : 339031 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
9550 : 300759 : switch (gimple_assign_rhs_code (_a1))
9551 : : {
9552 : 1512 : case ABS_EXPR:
9553 : 1512 : {
9554 : 1512 : tree _q30 = gimple_assign_rhs1 (_a1);
9555 : 1512 : _q30 = do_valueize (valueize, _q30);
9556 : 1512 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || (operand_equal_p (_q30, _p0, 0) && types_match (_q30, _p0)))
9557 : : {
9558 : 23 : {
9559 : 23 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
9560 : 23 : if (gimple_simplify_327 (res_op, seq, valueize, type, captures))
9561 : 8 : return true;
9562 : : }
9563 : : }
9564 : : break;
9565 : : }
9566 : : default:;
9567 : : }
9568 : : }
9569 : : break;
9570 : 548975 : default:;
9571 : : }
9572 : 548975 : switch (TREE_CODE (_p0))
9573 : : {
9574 : 326099 : case SSA_NAME:
9575 : 326099 : if (gimple *_d1 = get_def (valueize, _p0))
9576 : : {
9577 : 257557 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
9578 : 250913 : switch (gimple_assign_rhs_code (_a1))
9579 : : {
9580 : 2893 : case ABS_EXPR:
9581 : 2893 : {
9582 : 2893 : tree _q20 = gimple_assign_rhs1 (_a1);
9583 : 2893 : _q20 = do_valueize (valueize, _q20);
9584 : 2893 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
9585 : : {
9586 : 6 : {
9587 : 6 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
9588 : 6 : if (gimple_simplify_327 (res_op, seq, valueize, type, captures))
9589 : 6 : return true;
9590 : : }
9591 : : }
9592 : : break;
9593 : : }
9594 : : default:;
9595 : : }
9596 : : }
9597 : : break;
9598 : 548969 : default:;
9599 : : }
9600 : 548969 : if (real_onep (_p1))
9601 : : {
9602 : 3690 : {
9603 : 3690 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
9604 : 3690 : if (!tree_expr_maybe_signaling_nan_p (captures[0])
9605 : : )
9606 : : {
9607 : 3690 : gimple_seq *lseq = seq;
9608 : 3690 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1906;
9609 : 3690 : {
9610 : 3690 : tree tem;
9611 : 3690 : tem = captures[0];
9612 : 3690 : res_op->set_value (tem);
9613 : 3690 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1022, __FILE__, __LINE__, true);
9614 : 3690 : return true;
9615 : : }
9616 : 0 : next_after_fail1906:;
9617 : : }
9618 : : }
9619 : : }
9620 : 545279 : if (real_minus_onep (_p1))
9621 : : {
9622 : 48 : {
9623 : 48 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
9624 : 48 : if (!tree_expr_maybe_signaling_nan_p (captures[0])
9625 : : )
9626 : : {
9627 : 48 : gimple_seq *lseq = seq;
9628 : 48 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1907;
9629 : 48 : {
9630 : 48 : res_op->set_op (NEGATE_EXPR, type, 1);
9631 : 48 : res_op->ops[0] = captures[0];
9632 : 48 : res_op->resimplify (lseq, valueize);
9633 : 48 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1023, __FILE__, __LINE__, true);
9634 : 48 : return true;
9635 : : }
9636 : 0 : next_after_fail1907:;
9637 : : }
9638 : : }
9639 : : }
9640 : 545231 : switch (TREE_CODE (_p0))
9641 : : {
9642 : 322355 : case SSA_NAME:
9643 : 322355 : if (gimple *_d1 = get_def (valueize, _p0))
9644 : : {
9645 : 254362 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
9646 : 248013 : switch (gimple_assign_rhs_code (_a1))
9647 : : {
9648 : 7547 : case RDIV_EXPR:
9649 : 7547 : {
9650 : 7547 : tree _q20 = gimple_assign_rhs1 (_a1);
9651 : 7547 : _q20 = do_valueize (valueize, _q20);
9652 : 7547 : tree _q21 = gimple_assign_rhs2 (_a1);
9653 : 7547 : _q21 = do_valueize (valueize, _q21);
9654 : 7547 : {
9655 : 7547 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1 };
9656 : 7547 : if (flag_reciprocal_math
9657 : : )
9658 : : {
9659 : 96 : gimple_seq *lseq = seq;
9660 : 96 : if (lseq
9661 : 27 : && (!single_use (captures[0])))
9662 : 96 : lseq = NULL;
9663 : 96 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1908;
9664 : 96 : {
9665 : 96 : res_op->set_op (RDIV_EXPR, type, 2);
9666 : 96 : res_op->ops[0] = captures[1];
9667 : 96 : {
9668 : 96 : tree _o1[2], _r1;
9669 : 96 : _o1[0] = captures[2];
9670 : 96 : _o1[1] = captures[3];
9671 : 96 : gimple_match_op tem_op (res_op->cond.any_else (), MULT_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
9672 : 96 : tem_op.resimplify (lseq, valueize);
9673 : 96 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
9674 : 96 : if (!_r1) goto next_after_fail1908;
9675 : 0 : res_op->ops[1] = _r1;
9676 : : }
9677 : 0 : res_op->resimplify (lseq, valueize);
9678 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1024, __FILE__, __LINE__, true);
9679 : 0 : return true;
9680 : : }
9681 : 7547 : next_after_fail1908:;
9682 : : }
9683 : : }
9684 : 7547 : break;
9685 : : }
9686 : : default:;
9687 : : }
9688 : : }
9689 : : break;
9690 : 545231 : default:;
9691 : : }
9692 : 545231 : switch (TREE_CODE (_p1))
9693 : : {
9694 : 452818 : case SSA_NAME:
9695 : 452818 : if (gimple *_d1 = get_def (valueize, _p1))
9696 : : {
9697 : 339017 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
9698 : 300751 : switch (gimple_assign_rhs_code (_a1))
9699 : : {
9700 : 28004 : case MULT_EXPR:
9701 : 28004 : {
9702 : 28004 : tree _q30 = gimple_assign_rhs1 (_a1);
9703 : 28004 : _q30 = do_valueize (valueize, _q30);
9704 : 28004 : tree _q31 = gimple_assign_rhs2 (_a1);
9705 : 28004 : _q31 = do_valueize (valueize, _q31);
9706 : 28004 : if (tree_swap_operands_p (_q30, _q31))
9707 : 765 : std::swap (_q30, _q31);
9708 : 28004 : switch (TREE_CODE (_q31))
9709 : : {
9710 : 13520 : case REAL_CST:
9711 : 13520 : {
9712 : 13520 : {
9713 : 13520 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q31 };
9714 : 13520 : if (flag_reciprocal_math
9715 : : )
9716 : : {
9717 : 126 : {
9718 : 126 : tree tem = const_binop (RDIV_EXPR, type, build_one_cst (type), captures[3]);
9719 : 126 : if (tem
9720 : : )
9721 : : {
9722 : 126 : gimple_seq *lseq = seq;
9723 : 126 : if (lseq
9724 : 43 : && (!single_use (captures[1])))
9725 : 126 : lseq = NULL;
9726 : 126 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1909;
9727 : 126 : {
9728 : 126 : res_op->set_op (RDIV_EXPR, type, 2);
9729 : 126 : {
9730 : 126 : tree _o1[2], _r1;
9731 : 126 : _o1[0] = captures[0];
9732 : 126 : _o1[1] = tem;
9733 : 126 : gimple_match_op tem_op (res_op->cond.any_else (), MULT_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
9734 : 126 : tem_op.resimplify (lseq, valueize);
9735 : 126 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
9736 : 126 : if (!_r1) goto next_after_fail1909;
9737 : 4 : res_op->ops[0] = _r1;
9738 : : }
9739 : 4 : res_op->ops[1] = captures[2];
9740 : 4 : res_op->resimplify (lseq, valueize);
9741 : 4 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1025, __FILE__, __LINE__, true);
9742 : 4 : return true;
9743 : : }
9744 : 13516 : next_after_fail1909:;
9745 : : }
9746 : : }
9747 : : }
9748 : : }
9749 : 13516 : break;
9750 : : }
9751 : : default:;
9752 : : }
9753 : 541489 : break;
9754 : : }
9755 : 13403 : case RDIV_EXPR:
9756 : 13403 : {
9757 : 13403 : tree _q30 = gimple_assign_rhs1 (_a1);
9758 : 13403 : _q30 = do_valueize (valueize, _q30);
9759 : 13403 : tree _q31 = gimple_assign_rhs2 (_a1);
9760 : 13403 : _q31 = do_valueize (valueize, _q31);
9761 : 13403 : {
9762 : 13403 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q31 };
9763 : 13403 : if (flag_reciprocal_math
9764 : : )
9765 : : {
9766 : 0 : gimple_seq *lseq = seq;
9767 : 0 : if (lseq
9768 : 0 : && (!single_use (captures[1])))
9769 : 0 : lseq = NULL;
9770 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1910;
9771 : 0 : {
9772 : 0 : res_op->set_op (MULT_EXPR, type, 2);
9773 : 0 : {
9774 : 0 : tree _o1[2], _r1;
9775 : 0 : _o1[0] = captures[0];
9776 : 0 : _o1[1] = captures[2];
9777 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), RDIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
9778 : 0 : tem_op.resimplify (lseq, valueize);
9779 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
9780 : 0 : if (!_r1) goto next_after_fail1910;
9781 : 0 : res_op->ops[0] = _r1;
9782 : : }
9783 : 0 : res_op->ops[1] = captures[3];
9784 : 0 : res_op->resimplify (lseq, valueize);
9785 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1026, __FILE__, __LINE__, true);
9786 : 0 : return true;
9787 : : }
9788 : 13403 : next_after_fail1910:;
9789 : : }
9790 : : }
9791 : 13403 : break;
9792 : : }
9793 : 74 : case NEGATE_EXPR:
9794 : 74 : {
9795 : 74 : tree _q30 = gimple_assign_rhs1 (_a1);
9796 : 74 : _q30 = do_valueize (valueize, _q30);
9797 : 74 : {
9798 : 74 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q30 };
9799 : 74 : gimple_seq *lseq = seq;
9800 : 74 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1911;
9801 : 74 : {
9802 : 74 : res_op->set_op (RDIV_EXPR, type, 2);
9803 : 74 : {
9804 : 74 : tree _o1[1], _r1;
9805 : 74 : _o1[0] = captures[0];
9806 : 74 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o1[0]), _o1[0]);
9807 : 74 : tem_op.resimplify (lseq, valueize);
9808 : 74 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
9809 : 74 : if (!_r1) goto next_after_fail1911;
9810 : 45 : res_op->ops[0] = _r1;
9811 : : }
9812 : 45 : res_op->ops[1] = captures[1];
9813 : 45 : res_op->resimplify (lseq, valueize);
9814 : 45 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1027, __FILE__, __LINE__, true);
9815 : 45 : return true;
9816 : : }
9817 : 29 : next_after_fail1911:;
9818 : : }
9819 : 29 : break;
9820 : : }
9821 : : default:;
9822 : : }
9823 : : }
9824 : : break;
9825 : 77960 : case REAL_CST:
9826 : 77960 : {
9827 : 77960 : {
9828 : 77960 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
9829 : 77960 : if (optimize
9830 : : )
9831 : : {
9832 : 77529 : if (flag_reciprocal_math
9833 : 77529 : && !real_zerop (captures[1])
9834 : : )
9835 : : {
9836 : 56 : {
9837 : 56 : tree tem = const_binop (RDIV_EXPR, type, build_one_cst (type), captures[1]);
9838 : 56 : if (tem
9839 : : )
9840 : : {
9841 : 38 : gimple_seq *lseq = seq;
9842 : 38 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1912;
9843 : 38 : {
9844 : 38 : res_op->set_op (MULT_EXPR, type, 2);
9845 : 38 : res_op->ops[0] = captures[0];
9846 : 38 : res_op->ops[1] = tem;
9847 : 38 : res_op->resimplify (lseq, valueize);
9848 : 38 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1028, __FILE__, __LINE__, true);
9849 : 38 : return true;
9850 : : }
9851 : 0 : next_after_fail1912:;
9852 : : }
9853 : : }
9854 : : }
9855 : : else
9856 : : {
9857 : 77473 : if (REAL_CST != COMPLEX_CST
9858 : : )
9859 : : {
9860 : 77473 : {
9861 : 77473 : tree inverse = exact_inverse (type, captures[1]);
9862 : 77473 : if (inverse
9863 : : )
9864 : : {
9865 : 3622 : gimple_seq *lseq = seq;
9866 : 3622 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1913;
9867 : 3622 : {
9868 : 3622 : res_op->set_op (MULT_EXPR, type, 2);
9869 : 3622 : res_op->ops[0] = captures[0];
9870 : 3622 : res_op->ops[1] = inverse;
9871 : 3622 : res_op->resimplify (lseq, valueize);
9872 : 3622 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1029, __FILE__, __LINE__, true);
9873 : 3622 : return true;
9874 : : }
9875 : 0 : next_after_fail1913:;
9876 : : }
9877 : : }
9878 : : }
9879 : : }
9880 : : }
9881 : : }
9882 : 74300 : break;
9883 : : }
9884 : 3944 : case COMPLEX_CST:
9885 : 3944 : {
9886 : 3944 : {
9887 : 3944 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
9888 : 3944 : if (optimize
9889 : : )
9890 : : {
9891 : 3936 : if (flag_reciprocal_math
9892 : 3936 : && !real_zerop (captures[1])
9893 : : )
9894 : : {
9895 : 2 : {
9896 : 2 : tree tem = const_binop (RDIV_EXPR, type, build_one_cst (type), captures[1]);
9897 : 2 : if (tem
9898 : : )
9899 : : {
9900 : 2 : gimple_seq *lseq = seq;
9901 : 2 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1914;
9902 : 2 : {
9903 : 2 : res_op->set_op (MULT_EXPR, type, 2);
9904 : 2 : res_op->ops[0] = captures[0];
9905 : 2 : res_op->ops[1] = tem;
9906 : 2 : res_op->resimplify (lseq, valueize);
9907 : 2 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1028, __FILE__, __LINE__, true);
9908 : 2 : return true;
9909 : : }
9910 : 0 : next_after_fail1914:;
9911 : : }
9912 : : }
9913 : : }
9914 : : else
9915 : : {
9916 : : if (COMPLEX_CST != COMPLEX_CST
9917 : : )
9918 : : {
9919 : : {
9920 : : tree inverse = exact_inverse (type, captures[1]);
9921 : : if (inverse
9922 : : )
9923 : : {
9924 : : gimple_seq *lseq = seq;
9925 : : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1915;
9926 : : {
9927 : : res_op->set_op (MULT_EXPR, type, 2);
9928 : : res_op->ops[0] = captures[0];
9929 : : res_op->ops[1] = inverse;
9930 : : res_op->resimplify (lseq, valueize);
9931 : : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1029, __FILE__, __LINE__, true);
9932 : : return true;
9933 : : }
9934 : : next_after_fail1915:;
9935 : : }
9936 : : }
9937 : : }
9938 : : }
9939 : : }
9940 : : }
9941 : 3942 : break;
9942 : : }
9943 : 524 : case VECTOR_CST:
9944 : 524 : {
9945 : 524 : {
9946 : 524 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
9947 : 524 : if (optimize
9948 : : )
9949 : : {
9950 : 514 : if (flag_reciprocal_math
9951 : 514 : && !real_zerop (captures[1])
9952 : : )
9953 : : {
9954 : 30 : {
9955 : 30 : tree tem = const_binop (RDIV_EXPR, type, build_one_cst (type), captures[1]);
9956 : 30 : if (tem
9957 : : )
9958 : : {
9959 : 2 : gimple_seq *lseq = seq;
9960 : 2 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1916;
9961 : 2 : {
9962 : 2 : res_op->set_op (MULT_EXPR, type, 2);
9963 : 2 : res_op->ops[0] = captures[0];
9964 : 2 : res_op->ops[1] = tem;
9965 : 2 : res_op->resimplify (lseq, valueize);
9966 : 2 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1028, __FILE__, __LINE__, true);
9967 : 2 : return true;
9968 : : }
9969 : 0 : next_after_fail1916:;
9970 : : }
9971 : : }
9972 : : }
9973 : : else
9974 : : {
9975 : 484 : if (VECTOR_CST != COMPLEX_CST
9976 : : )
9977 : : {
9978 : 484 : {
9979 : 484 : tree inverse = exact_inverse (type, captures[1]);
9980 : 484 : if (inverse
9981 : : )
9982 : : {
9983 : 29 : gimple_seq *lseq = seq;
9984 : 29 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1917;
9985 : 29 : {
9986 : 29 : res_op->set_op (MULT_EXPR, type, 2);
9987 : 29 : res_op->ops[0] = captures[0];
9988 : 29 : res_op->ops[1] = inverse;
9989 : 29 : res_op->resimplify (lseq, valueize);
9990 : 29 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1029, __FILE__, __LINE__, true);
9991 : 29 : return true;
9992 : : }
9993 : 0 : next_after_fail1917:;
9994 : : }
9995 : : }
9996 : : }
9997 : : }
9998 : : }
9999 : : }
10000 : 493 : break;
10001 : : }
10002 : 541489 : default:;
10003 : : }
10004 : 541489 : switch (TREE_CODE (_p0))
10005 : : {
10006 : 318659 : case SSA_NAME:
10007 : 318659 : if (gimple *_d1 = get_def (valueize, _p0))
10008 : : {
10009 : 251512 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
10010 : 244809 : switch (gimple_assign_rhs_code (_a1))
10011 : : {
10012 : 0 : case VEC_COND_EXPR:
10013 : 0 : {
10014 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
10015 : 0 : _q20 = do_valueize (valueize, _q20);
10016 : 0 : tree _q21 = gimple_assign_rhs2 (_a1);
10017 : 0 : _q21 = do_valueize (valueize, _q21);
10018 : 0 : tree _q22 = gimple_assign_rhs3 (_a1);
10019 : 0 : _q22 = do_valueize (valueize, _q22);
10020 : 0 : switch (TREE_CODE (_p1))
10021 : : {
10022 : 0 : case SSA_NAME:
10023 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
10024 : : {
10025 : 0 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
10026 : 0 : switch (gimple_assign_rhs_code (_a2))
10027 : : {
10028 : 0 : case VEC_COND_EXPR:
10029 : 0 : {
10030 : 0 : tree _q60 = gimple_assign_rhs1 (_a2);
10031 : 0 : _q60 = do_valueize (valueize, _q60);
10032 : 0 : tree _q61 = gimple_assign_rhs2 (_a2);
10033 : 0 : _q61 = do_valueize (valueize, _q61);
10034 : 0 : tree _q62 = gimple_assign_rhs3 (_a2);
10035 : 0 : _q62 = do_valueize (valueize, _q62);
10036 : 0 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
10037 : : {
10038 : 0 : {
10039 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q22, _p1, _q61, _q62 };
10040 : 0 : if (TREE_CODE_CLASS (RDIV_EXPR) != tcc_comparison
10041 : : || types_match (type, TREE_TYPE (captures[2]))
10042 : : || expand_vec_cond_expr_p (type, TREE_TYPE (captures[1]), ERROR_MARK)
10043 : : || (optimize_vectors_before_lowering_p ()
10044 : : && !expand_vec_cond_expr_p (TREE_TYPE (captures[2]),
10045 : : TREE_TYPE (captures[1]), ERROR_MARK))
10046 : : )
10047 : : {
10048 : 0 : gimple_seq *lseq = seq;
10049 : 0 : if (lseq
10050 : 0 : && (!single_use (captures[0])
10051 : 0 : || !single_use (captures[4])))
10052 : 0 : lseq = NULL;
10053 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1918;
10054 : 0 : {
10055 : 0 : res_op->set_op (VEC_COND_EXPR, type, 3);
10056 : 0 : res_op->ops[0] = captures[1];
10057 : 0 : {
10058 : 0 : tree _o1[2], _r1;
10059 : 0 : _o1[0] = captures[2];
10060 : 0 : _o1[1] = captures[5];
10061 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), RDIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
10062 : 0 : tem_op.resimplify (NULL, valueize);
10063 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
10064 : 0 : if (!_r1) goto next_after_fail1918;
10065 : 0 : res_op->ops[1] = _r1;
10066 : : }
10067 : 0 : {
10068 : 0 : tree _o1[2], _r1;
10069 : 0 : _o1[0] = captures[3];
10070 : 0 : _o1[1] = captures[6];
10071 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), RDIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
10072 : 0 : tem_op.resimplify (NULL, valueize);
10073 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
10074 : 0 : if (!_r1) goto next_after_fail1918;
10075 : 0 : res_op->ops[2] = _r1;
10076 : : }
10077 : 0 : res_op->resimplify (lseq, valueize);
10078 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 925, __FILE__, __LINE__, true);
10079 : 0 : return true;
10080 : : }
10081 : 0 : next_after_fail1918:;
10082 : : }
10083 : : }
10084 : : }
10085 : : break;
10086 : : }
10087 : : default:;
10088 : : }
10089 : : }
10090 : : break;
10091 : 0 : default:;
10092 : : }
10093 : 0 : {
10094 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q22, _p1 };
10095 : 0 : if (TREE_CODE_CLASS (RDIV_EXPR) != tcc_comparison
10096 : : || types_match (type, TREE_TYPE (captures[2]))
10097 : : || expand_vec_cond_expr_p (type, TREE_TYPE (captures[1]), ERROR_MARK)
10098 : : || (optimize_vectors_before_lowering_p ()
10099 : : && !expand_vec_cond_expr_p (TREE_TYPE (captures[2]),
10100 : : TREE_TYPE (captures[1]), ERROR_MARK))
10101 : : )
10102 : : {
10103 : 0 : gimple_seq *lseq = seq;
10104 : 0 : if (lseq
10105 : 0 : && (!single_use (captures[0])))
10106 : 0 : lseq = NULL;
10107 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1919;
10108 : 0 : {
10109 : 0 : res_op->set_op (VEC_COND_EXPR, type, 3);
10110 : 0 : res_op->ops[0] = captures[1];
10111 : 0 : {
10112 : 0 : tree _o1[2], _r1;
10113 : 0 : _o1[0] = captures[2];
10114 : 0 : _o1[1] = captures[4];
10115 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), RDIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
10116 : 0 : tem_op.resimplify (NULL, valueize);
10117 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
10118 : 0 : if (!_r1) goto next_after_fail1919;
10119 : 0 : res_op->ops[1] = _r1;
10120 : : }
10121 : 0 : {
10122 : 0 : tree _o1[2], _r1;
10123 : 0 : _o1[0] = captures[3];
10124 : 0 : _o1[1] = captures[4];
10125 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), RDIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
10126 : 0 : tem_op.resimplify (NULL, valueize);
10127 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
10128 : 0 : if (!_r1) goto next_after_fail1919;
10129 : 0 : res_op->ops[2] = _r1;
10130 : : }
10131 : 0 : res_op->resimplify (lseq, valueize);
10132 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 926, __FILE__, __LINE__, true);
10133 : 0 : return true;
10134 : : }
10135 : 0 : next_after_fail1919:;
10136 : : }
10137 : : }
10138 : 0 : break;
10139 : : }
10140 : : default:;
10141 : : }
10142 : : }
10143 : : break;
10144 : 541489 : default:;
10145 : : }
10146 : 541489 : switch (TREE_CODE (_p1))
10147 : : {
10148 : 452769 : case SSA_NAME:
10149 : 452769 : if (gimple *_d1 = get_def (valueize, _p1))
10150 : : {
10151 : 338968 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
10152 : 300702 : switch (gimple_assign_rhs_code (_a1))
10153 : : {
10154 : 0 : case VEC_COND_EXPR:
10155 : 0 : {
10156 : 0 : tree _q30 = gimple_assign_rhs1 (_a1);
10157 : 0 : _q30 = do_valueize (valueize, _q30);
10158 : 0 : tree _q31 = gimple_assign_rhs2 (_a1);
10159 : 0 : _q31 = do_valueize (valueize, _q31);
10160 : 0 : tree _q32 = gimple_assign_rhs3 (_a1);
10161 : 0 : _q32 = do_valueize (valueize, _q32);
10162 : 0 : {
10163 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q31, _q32 };
10164 : 0 : if (TREE_CODE_CLASS (RDIV_EXPR) != tcc_comparison
10165 : : || types_match (type, TREE_TYPE (captures[3]))
10166 : : || expand_vec_cond_expr_p (type, TREE_TYPE (captures[2]), ERROR_MARK)
10167 : : || (optimize_vectors_before_lowering_p ()
10168 : : && !expand_vec_cond_expr_p (TREE_TYPE (captures[3]),
10169 : : TREE_TYPE (captures[2]), ERROR_MARK))
10170 : : )
10171 : : {
10172 : 0 : gimple_seq *lseq = seq;
10173 : 0 : if (lseq
10174 : 0 : && (!single_use (captures[1])))
10175 : 0 : lseq = NULL;
10176 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1920;
10177 : 0 : {
10178 : 0 : res_op->set_op (VEC_COND_EXPR, type, 3);
10179 : 0 : res_op->ops[0] = captures[2];
10180 : 0 : {
10181 : 0 : tree _o1[2], _r1;
10182 : 0 : _o1[0] = captures[0];
10183 : 0 : _o1[1] = captures[3];
10184 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), RDIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
10185 : 0 : tem_op.resimplify (NULL, valueize);
10186 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
10187 : 0 : if (!_r1) goto next_after_fail1920;
10188 : 0 : res_op->ops[1] = _r1;
10189 : : }
10190 : 0 : {
10191 : 0 : tree _o1[2], _r1;
10192 : 0 : _o1[0] = captures[0];
10193 : 0 : _o1[1] = captures[4];
10194 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), RDIV_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
10195 : 0 : tem_op.resimplify (NULL, valueize);
10196 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
10197 : 0 : if (!_r1) goto next_after_fail1920;
10198 : 0 : res_op->ops[2] = _r1;
10199 : : }
10200 : 0 : res_op->resimplify (lseq, valueize);
10201 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 927, __FILE__, __LINE__, true);
10202 : 0 : return true;
10203 : : }
10204 : 0 : next_after_fail1920:;
10205 : : }
10206 : : }
10207 : 0 : break;
10208 : : }
10209 : : default:;
10210 : : }
10211 : 74346 : else if (gcall *_c1 = dyn_cast <gcall *> (_d1))
10212 : 23467 : switch (gimple_call_combined_fn (_c1))
10213 : : {
10214 : 1107 : case CFN_BUILT_IN_SQRTF:
10215 : 1107 : if (gimple_call_num_args (_c1) == 1)
10216 : : {
10217 : 1107 : tree _q30 = gimple_call_arg (_c1, 0);
10218 : 1107 : _q30 = do_valueize (valueize, _q30);
10219 : 1107 : switch (TREE_CODE (_q30))
10220 : : {
10221 : 1107 : case SSA_NAME:
10222 : 1107 : if (gimple *_d2 = get_def (valueize, _q30))
10223 : : {
10224 : 1067 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
10225 : 598 : switch (gimple_assign_rhs_code (_a2))
10226 : : {
10227 : 20 : case RDIV_EXPR:
10228 : 20 : {
10229 : 20 : tree _q40 = gimple_assign_rhs1 (_a2);
10230 : 20 : _q40 = do_valueize (valueize, _q40);
10231 : 20 : tree _q41 = gimple_assign_rhs2 (_a2);
10232 : 20 : _q41 = do_valueize (valueize, _q41);
10233 : 20 : {
10234 : 20 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q40, _q41 };
10235 : 20 : if (flag_unsafe_math_optimizations
10236 : : )
10237 : : {
10238 : 0 : gimple_seq *lseq = seq;
10239 : 0 : if (lseq
10240 : 0 : && (!single_use (captures[1])
10241 : 0 : || !single_use (captures[2])))
10242 : 0 : lseq = NULL;
10243 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1921;
10244 : 0 : {
10245 : 0 : res_op->set_op (MULT_EXPR, type, 2);
10246 : 0 : res_op->ops[0] = captures[0];
10247 : 0 : {
10248 : 0 : tree _o1[1], _r1;
10249 : 0 : {
10250 : 0 : tree _o2[2], _r2;
10251 : 0 : _o2[0] = captures[4];
10252 : 0 : _o2[1] = captures[3];
10253 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), RDIV_EXPR, TREE_TYPE (_o2[0]), _o2[0], _o2[1]);
10254 : 0 : tem_op.resimplify (lseq, valueize);
10255 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
10256 : 0 : if (!_r2) goto next_after_fail1921;
10257 : 0 : _o1[0] = _r2;
10258 : : }
10259 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_SQRTF, TREE_TYPE (_o1[0]), _o1[0]);
10260 : 0 : tem_op.resimplify (lseq, valueize);
10261 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
10262 : 0 : if (!_r1) goto next_after_fail1921;
10263 : 0 : res_op->ops[1] = _r1;
10264 : : }
10265 : 0 : res_op->resimplify (lseq, valueize);
10266 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1030, __FILE__, __LINE__, true);
10267 : 0 : return true;
10268 : : }
10269 : 20 : next_after_fail1921:;
10270 : : }
10271 : : }
10272 : 20 : break;
10273 : : }
10274 : : default:;
10275 : : }
10276 : : }
10277 : : break;
10278 : : default:;
10279 : : }
10280 : : }
10281 : : break;
10282 : 708 : case CFN_BUILT_IN_SQRTL:
10283 : 708 : if (gimple_call_num_args (_c1) == 1)
10284 : : {
10285 : 708 : tree _q30 = gimple_call_arg (_c1, 0);
10286 : 708 : _q30 = do_valueize (valueize, _q30);
10287 : 708 : switch (TREE_CODE (_q30))
10288 : : {
10289 : 708 : case SSA_NAME:
10290 : 708 : if (gimple *_d2 = get_def (valueize, _q30))
10291 : : {
10292 : 692 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
10293 : 242 : switch (gimple_assign_rhs_code (_a2))
10294 : : {
10295 : 16 : case RDIV_EXPR:
10296 : 16 : {
10297 : 16 : tree _q40 = gimple_assign_rhs1 (_a2);
10298 : 16 : _q40 = do_valueize (valueize, _q40);
10299 : 16 : tree _q41 = gimple_assign_rhs2 (_a2);
10300 : 16 : _q41 = do_valueize (valueize, _q41);
10301 : 16 : {
10302 : 16 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q40, _q41 };
10303 : 16 : if (flag_unsafe_math_optimizations
10304 : : )
10305 : : {
10306 : 0 : gimple_seq *lseq = seq;
10307 : 0 : if (lseq
10308 : 0 : && (!single_use (captures[1])
10309 : 0 : || !single_use (captures[2])))
10310 : 0 : lseq = NULL;
10311 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1922;
10312 : 0 : {
10313 : 0 : res_op->set_op (MULT_EXPR, type, 2);
10314 : 0 : res_op->ops[0] = captures[0];
10315 : 0 : {
10316 : 0 : tree _o1[1], _r1;
10317 : 0 : {
10318 : 0 : tree _o2[2], _r2;
10319 : 0 : _o2[0] = captures[4];
10320 : 0 : _o2[1] = captures[3];
10321 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), RDIV_EXPR, TREE_TYPE (_o2[0]), _o2[0], _o2[1]);
10322 : 0 : tem_op.resimplify (lseq, valueize);
10323 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
10324 : 0 : if (!_r2) goto next_after_fail1922;
10325 : 0 : _o1[0] = _r2;
10326 : : }
10327 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_SQRTL, TREE_TYPE (_o1[0]), _o1[0]);
10328 : 0 : tem_op.resimplify (lseq, valueize);
10329 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
10330 : 0 : if (!_r1) goto next_after_fail1922;
10331 : 0 : res_op->ops[1] = _r1;
10332 : : }
10333 : 0 : res_op->resimplify (lseq, valueize);
10334 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1030, __FILE__, __LINE__, true);
10335 : 0 : return true;
10336 : : }
10337 : 16 : next_after_fail1922:;
10338 : : }
10339 : : }
10340 : 16 : break;
10341 : : }
10342 : : default:;
10343 : : }
10344 : : }
10345 : : break;
10346 : : default:;
10347 : : }
10348 : : }
10349 : : break;
10350 : 394 : case CFN_BUILT_IN_EXP:
10351 : 394 : if (gimple_call_num_args (_c1) == 1)
10352 : : {
10353 : 394 : tree _q30 = gimple_call_arg (_c1, 0);
10354 : 394 : _q30 = do_valueize (valueize, _q30);
10355 : 394 : {
10356 : 394 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p1, _q30 };
10357 : 394 : if (flag_unsafe_math_optimizations
10358 : : )
10359 : : {
10360 : 0 : gimple_seq *lseq = seq;
10361 : 0 : if (lseq
10362 : 0 : && (!single_use (captures[1])))
10363 : 0 : lseq = NULL;
10364 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1923;
10365 : 0 : {
10366 : 0 : res_op->set_op (MULT_EXPR, type, 2);
10367 : 0 : res_op->ops[0] = captures[0];
10368 : 0 : {
10369 : 0 : tree _o1[1], _r1;
10370 : 0 : {
10371 : 0 : tree _o2[1], _r2;
10372 : 0 : _o2[0] = captures[2];
10373 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
10374 : 0 : tem_op.resimplify (lseq, valueize);
10375 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
10376 : 0 : if (!_r2) goto next_after_fail1923;
10377 : 0 : _o1[0] = _r2;
10378 : : }
10379 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_EXP, TREE_TYPE (_o1[0]), _o1[0]);
10380 : 0 : tem_op.resimplify (lseq, valueize);
10381 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
10382 : 0 : if (!_r1) goto next_after_fail1923;
10383 : 0 : res_op->ops[1] = _r1;
10384 : : }
10385 : 0 : res_op->resimplify (lseq, valueize);
10386 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1031, __FILE__, __LINE__, true);
10387 : 0 : return true;
10388 : : }
10389 : 394 : next_after_fail1923:;
10390 : : }
10391 : : }
10392 : : }
10393 : : break;
10394 : 0 : case CFN_BUILT_IN_EXP10F:
10395 : 0 : if (gimple_call_num_args (_c1) == 1)
10396 : : {
10397 : 0 : tree _q30 = gimple_call_arg (_c1, 0);
10398 : 0 : _q30 = do_valueize (valueize, _q30);
10399 : 0 : {
10400 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p1, _q30 };
10401 : 0 : if (flag_unsafe_math_optimizations
10402 : : )
10403 : : {
10404 : 0 : gimple_seq *lseq = seq;
10405 : 0 : if (lseq
10406 : 0 : && (!single_use (captures[1])))
10407 : 0 : lseq = NULL;
10408 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1924;
10409 : 0 : {
10410 : 0 : res_op->set_op (MULT_EXPR, type, 2);
10411 : 0 : res_op->ops[0] = captures[0];
10412 : 0 : {
10413 : 0 : tree _o1[1], _r1;
10414 : 0 : {
10415 : 0 : tree _o2[1], _r2;
10416 : 0 : _o2[0] = captures[2];
10417 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
10418 : 0 : tem_op.resimplify (lseq, valueize);
10419 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
10420 : 0 : if (!_r2) goto next_after_fail1924;
10421 : 0 : _o1[0] = _r2;
10422 : : }
10423 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_EXP10F, TREE_TYPE (_o1[0]), _o1[0]);
10424 : 0 : tem_op.resimplify (lseq, valueize);
10425 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
10426 : 0 : if (!_r1) goto next_after_fail1924;
10427 : 0 : res_op->ops[1] = _r1;
10428 : : }
10429 : 0 : res_op->resimplify (lseq, valueize);
10430 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1031, __FILE__, __LINE__, true);
10431 : 0 : return true;
10432 : : }
10433 : 0 : next_after_fail1924:;
10434 : : }
10435 : : }
10436 : : }
10437 : : break;
10438 : 0 : case CFN_BUILT_IN_EXP10L:
10439 : 0 : if (gimple_call_num_args (_c1) == 1)
10440 : : {
10441 : 0 : tree _q30 = gimple_call_arg (_c1, 0);
10442 : 0 : _q30 = do_valueize (valueize, _q30);
10443 : 0 : {
10444 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p1, _q30 };
10445 : 0 : if (flag_unsafe_math_optimizations
10446 : : )
10447 : : {
10448 : 0 : gimple_seq *lseq = seq;
10449 : 0 : if (lseq
10450 : 0 : && (!single_use (captures[1])))
10451 : 0 : lseq = NULL;
10452 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1925;
10453 : 0 : {
10454 : 0 : res_op->set_op (MULT_EXPR, type, 2);
10455 : 0 : res_op->ops[0] = captures[0];
10456 : 0 : {
10457 : 0 : tree _o1[1], _r1;
10458 : 0 : {
10459 : 0 : tree _o2[1], _r2;
10460 : 0 : _o2[0] = captures[2];
10461 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
10462 : 0 : tem_op.resimplify (lseq, valueize);
10463 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
10464 : 0 : if (!_r2) goto next_after_fail1925;
10465 : 0 : _o1[0] = _r2;
10466 : : }
10467 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_EXP10L, TREE_TYPE (_o1[0]), _o1[0]);
10468 : 0 : tem_op.resimplify (lseq, valueize);
10469 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
10470 : 0 : if (!_r1) goto next_after_fail1925;
10471 : 0 : res_op->ops[1] = _r1;
10472 : : }
10473 : 0 : res_op->resimplify (lseq, valueize);
10474 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1031, __FILE__, __LINE__, true);
10475 : 0 : return true;
10476 : : }
10477 : 0 : next_after_fail1925:;
10478 : : }
10479 : : }
10480 : : }
10481 : : break;
10482 : 11 : case CFN_BUILT_IN_CBRT:
10483 : 11 : if (gimple_call_num_args (_c1) == 1)
10484 : : {
10485 : 11 : tree _q30 = gimple_call_arg (_c1, 0);
10486 : 11 : _q30 = do_valueize (valueize, _q30);
10487 : 11 : switch (TREE_CODE (_q30))
10488 : : {
10489 : 11 : case SSA_NAME:
10490 : 11 : if (gimple *_d2 = get_def (valueize, _q30))
10491 : : {
10492 : 9 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
10493 : 18 : switch (gimple_assign_rhs_code (_a2))
10494 : : {
10495 : 0 : case RDIV_EXPR:
10496 : 0 : {
10497 : 0 : tree _q40 = gimple_assign_rhs1 (_a2);
10498 : 0 : _q40 = do_valueize (valueize, _q40);
10499 : 0 : tree _q41 = gimple_assign_rhs2 (_a2);
10500 : 0 : _q41 = do_valueize (valueize, _q41);
10501 : 0 : {
10502 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q40, _q41 };
10503 : 0 : if (flag_unsafe_math_optimizations
10504 : : )
10505 : : {
10506 : 0 : gimple_seq *lseq = seq;
10507 : 0 : if (lseq
10508 : 0 : && (!single_use (captures[1])
10509 : 0 : || !single_use (captures[2])))
10510 : 0 : lseq = NULL;
10511 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1926;
10512 : 0 : {
10513 : 0 : res_op->set_op (MULT_EXPR, type, 2);
10514 : 0 : res_op->ops[0] = captures[0];
10515 : 0 : {
10516 : 0 : tree _o1[1], _r1;
10517 : 0 : {
10518 : 0 : tree _o2[2], _r2;
10519 : 0 : _o2[0] = captures[4];
10520 : 0 : _o2[1] = captures[3];
10521 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), RDIV_EXPR, TREE_TYPE (_o2[0]), _o2[0], _o2[1]);
10522 : 0 : tem_op.resimplify (lseq, valueize);
10523 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
10524 : 0 : if (!_r2) goto next_after_fail1926;
10525 : 0 : _o1[0] = _r2;
10526 : : }
10527 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_CBRT, TREE_TYPE (_o1[0]), _o1[0]);
10528 : 0 : tem_op.resimplify (lseq, valueize);
10529 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
10530 : 0 : if (!_r1) goto next_after_fail1926;
10531 : 0 : res_op->ops[1] = _r1;
10532 : : }
10533 : 0 : res_op->resimplify (lseq, valueize);
10534 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1030, __FILE__, __LINE__, true);
10535 : 0 : return true;
10536 : : }
10537 : 0 : next_after_fail1926:;
10538 : : }
10539 : : }
10540 : 0 : break;
10541 : : }
10542 : : default:;
10543 : : }
10544 : : }
10545 : : break;
10546 : : default:;
10547 : : }
10548 : : }
10549 : : break;
10550 : 0 : case CFN_BUILT_IN_EXP2:
10551 : 0 : if (gimple_call_num_args (_c1) == 1)
10552 : : {
10553 : 0 : tree _q30 = gimple_call_arg (_c1, 0);
10554 : 0 : _q30 = do_valueize (valueize, _q30);
10555 : 0 : {
10556 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p1, _q30 };
10557 : 0 : if (flag_unsafe_math_optimizations
10558 : : )
10559 : : {
10560 : 0 : gimple_seq *lseq = seq;
10561 : 0 : if (lseq
10562 : 0 : && (!single_use (captures[1])))
10563 : 0 : lseq = NULL;
10564 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1927;
10565 : 0 : {
10566 : 0 : res_op->set_op (MULT_EXPR, type, 2);
10567 : 0 : res_op->ops[0] = captures[0];
10568 : 0 : {
10569 : 0 : tree _o1[1], _r1;
10570 : 0 : {
10571 : 0 : tree _o2[1], _r2;
10572 : 0 : _o2[0] = captures[2];
10573 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
10574 : 0 : tem_op.resimplify (lseq, valueize);
10575 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
10576 : 0 : if (!_r2) goto next_after_fail1927;
10577 : 0 : _o1[0] = _r2;
10578 : : }
10579 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_EXP2, TREE_TYPE (_o1[0]), _o1[0]);
10580 : 0 : tem_op.resimplify (lseq, valueize);
10581 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
10582 : 0 : if (!_r1) goto next_after_fail1927;
10583 : 0 : res_op->ops[1] = _r1;
10584 : : }
10585 : 0 : res_op->resimplify (lseq, valueize);
10586 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1031, __FILE__, __LINE__, true);
10587 : 0 : return true;
10588 : : }
10589 : 0 : next_after_fail1927:;
10590 : : }
10591 : : }
10592 : : }
10593 : : break;
10594 : 0 : case CFN_BUILT_IN_EXPF:
10595 : 0 : if (gimple_call_num_args (_c1) == 1)
10596 : : {
10597 : 0 : tree _q30 = gimple_call_arg (_c1, 0);
10598 : 0 : _q30 = do_valueize (valueize, _q30);
10599 : 0 : {
10600 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p1, _q30 };
10601 : 0 : if (flag_unsafe_math_optimizations
10602 : : )
10603 : : {
10604 : 0 : gimple_seq *lseq = seq;
10605 : 0 : if (lseq
10606 : 0 : && (!single_use (captures[1])))
10607 : 0 : lseq = NULL;
10608 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1928;
10609 : 0 : {
10610 : 0 : res_op->set_op (MULT_EXPR, type, 2);
10611 : 0 : res_op->ops[0] = captures[0];
10612 : 0 : {
10613 : 0 : tree _o1[1], _r1;
10614 : 0 : {
10615 : 0 : tree _o2[1], _r2;
10616 : 0 : _o2[0] = captures[2];
10617 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
10618 : 0 : tem_op.resimplify (lseq, valueize);
10619 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
10620 : 0 : if (!_r2) goto next_after_fail1928;
10621 : 0 : _o1[0] = _r2;
10622 : : }
10623 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_EXPF, TREE_TYPE (_o1[0]), _o1[0]);
10624 : 0 : tem_op.resimplify (lseq, valueize);
10625 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
10626 : 0 : if (!_r1) goto next_after_fail1928;
10627 : 0 : res_op->ops[1] = _r1;
10628 : : }
10629 : 0 : res_op->resimplify (lseq, valueize);
10630 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1031, __FILE__, __LINE__, true);
10631 : 0 : return true;
10632 : : }
10633 : 0 : next_after_fail1928:;
10634 : : }
10635 : : }
10636 : : }
10637 : : break;
10638 : 0 : case CFN_BUILT_IN_EXPL:
10639 : 0 : if (gimple_call_num_args (_c1) == 1)
10640 : : {
10641 : 0 : tree _q30 = gimple_call_arg (_c1, 0);
10642 : 0 : _q30 = do_valueize (valueize, _q30);
10643 : 0 : {
10644 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p1, _q30 };
10645 : 0 : if (flag_unsafe_math_optimizations
10646 : : )
10647 : : {
10648 : 0 : gimple_seq *lseq = seq;
10649 : 0 : if (lseq
10650 : 0 : && (!single_use (captures[1])))
10651 : 0 : lseq = NULL;
10652 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1929;
10653 : 0 : {
10654 : 0 : res_op->set_op (MULT_EXPR, type, 2);
10655 : 0 : res_op->ops[0] = captures[0];
10656 : 0 : {
10657 : 0 : tree _o1[1], _r1;
10658 : 0 : {
10659 : 0 : tree _o2[1], _r2;
10660 : 0 : _o2[0] = captures[2];
10661 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
10662 : 0 : tem_op.resimplify (lseq, valueize);
10663 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
10664 : 0 : if (!_r2) goto next_after_fail1929;
10665 : 0 : _o1[0] = _r2;
10666 : : }
10667 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_EXPL, TREE_TYPE (_o1[0]), _o1[0]);
10668 : 0 : tem_op.resimplify (lseq, valueize);
10669 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
10670 : 0 : if (!_r1) goto next_after_fail1929;
10671 : 0 : res_op->ops[1] = _r1;
10672 : : }
10673 : 0 : res_op->resimplify (lseq, valueize);
10674 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1031, __FILE__, __LINE__, true);
10675 : 0 : return true;
10676 : : }
10677 : 0 : next_after_fail1929:;
10678 : : }
10679 : : }
10680 : : }
10681 : : break;
10682 : 3832 : case CFN_BUILT_IN_SQRT:
10683 : 3832 : if (gimple_call_num_args (_c1) == 1)
10684 : : {
10685 : 3832 : tree _q30 = gimple_call_arg (_c1, 0);
10686 : 3832 : _q30 = do_valueize (valueize, _q30);
10687 : 3832 : switch (TREE_CODE (_q30))
10688 : : {
10689 : 3832 : case SSA_NAME:
10690 : 3832 : if (gimple *_d2 = get_def (valueize, _q30))
10691 : : {
10692 : 3599 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
10693 : 2335 : switch (gimple_assign_rhs_code (_a2))
10694 : : {
10695 : 44 : case RDIV_EXPR:
10696 : 44 : {
10697 : 44 : tree _q40 = gimple_assign_rhs1 (_a2);
10698 : 44 : _q40 = do_valueize (valueize, _q40);
10699 : 44 : tree _q41 = gimple_assign_rhs2 (_a2);
10700 : 44 : _q41 = do_valueize (valueize, _q41);
10701 : 44 : {
10702 : 44 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q40, _q41 };
10703 : 44 : if (flag_unsafe_math_optimizations
10704 : : )
10705 : : {
10706 : 0 : gimple_seq *lseq = seq;
10707 : 0 : if (lseq
10708 : 0 : && (!single_use (captures[1])
10709 : 0 : || !single_use (captures[2])))
10710 : 0 : lseq = NULL;
10711 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1930;
10712 : 0 : {
10713 : 0 : res_op->set_op (MULT_EXPR, type, 2);
10714 : 0 : res_op->ops[0] = captures[0];
10715 : 0 : {
10716 : 0 : tree _o1[1], _r1;
10717 : 0 : {
10718 : 0 : tree _o2[2], _r2;
10719 : 0 : _o2[0] = captures[4];
10720 : 0 : _o2[1] = captures[3];
10721 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), RDIV_EXPR, TREE_TYPE (_o2[0]), _o2[0], _o2[1]);
10722 : 0 : tem_op.resimplify (lseq, valueize);
10723 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
10724 : 0 : if (!_r2) goto next_after_fail1930;
10725 : 0 : _o1[0] = _r2;
10726 : : }
10727 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_SQRT, TREE_TYPE (_o1[0]), _o1[0]);
10728 : 0 : tem_op.resimplify (lseq, valueize);
10729 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
10730 : 0 : if (!_r1) goto next_after_fail1930;
10731 : 0 : res_op->ops[1] = _r1;
10732 : : }
10733 : 0 : res_op->resimplify (lseq, valueize);
10734 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1030, __FILE__, __LINE__, true);
10735 : 0 : return true;
10736 : : }
10737 : 44 : next_after_fail1930:;
10738 : : }
10739 : : }
10740 : 44 : break;
10741 : : }
10742 : : default:;
10743 : : }
10744 : : }
10745 : : break;
10746 : : default:;
10747 : : }
10748 : : }
10749 : : break;
10750 : 0 : case CFN_EXP:
10751 : 0 : if (gimple_call_num_args (_c1) == 1)
10752 : : {
10753 : 0 : tree _q30 = gimple_call_arg (_c1, 0);
10754 : 0 : _q30 = do_valueize (valueize, _q30);
10755 : 0 : {
10756 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p1, _q30 };
10757 : 0 : if (flag_unsafe_math_optimizations
10758 : : )
10759 : : {
10760 : 0 : gimple_seq *lseq = seq;
10761 : 0 : if (lseq
10762 : 0 : && (!single_use (captures[1])))
10763 : 0 : lseq = NULL;
10764 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1931;
10765 : 0 : {
10766 : 0 : res_op->set_op (MULT_EXPR, type, 2);
10767 : 0 : res_op->ops[0] = captures[0];
10768 : 0 : {
10769 : 0 : tree _o1[1], _r1;
10770 : 0 : {
10771 : 0 : tree _o2[1], _r2;
10772 : 0 : _o2[0] = captures[2];
10773 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
10774 : 0 : tem_op.resimplify (lseq, valueize);
10775 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
10776 : 0 : if (!_r2) goto next_after_fail1931;
10777 : 0 : _o1[0] = _r2;
10778 : : }
10779 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_EXP, TREE_TYPE (_o1[0]), _o1[0]);
10780 : 0 : tem_op.resimplify (lseq, valueize);
10781 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
10782 : 0 : if (!_r1) goto next_after_fail1931;
10783 : 0 : res_op->ops[1] = _r1;
10784 : : }
10785 : 0 : res_op->resimplify (lseq, valueize);
10786 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1031, __FILE__, __LINE__, true);
10787 : 0 : return true;
10788 : : }
10789 : 0 : next_after_fail1931:;
10790 : : }
10791 : : }
10792 : : }
10793 : : break;
10794 : 24 : case CFN_BUILT_IN_POW10F:
10795 : 24 : if (gimple_call_num_args (_c1) == 1)
10796 : : {
10797 : 24 : tree _q30 = gimple_call_arg (_c1, 0);
10798 : 24 : _q30 = do_valueize (valueize, _q30);
10799 : 24 : {
10800 : 24 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p1, _q30 };
10801 : 24 : if (flag_unsafe_math_optimizations
10802 : : )
10803 : : {
10804 : 24 : gimple_seq *lseq = seq;
10805 : 24 : if (lseq
10806 : 12 : && (!single_use (captures[1])))
10807 : 12 : lseq = NULL;
10808 : 24 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1932;
10809 : 24 : {
10810 : 24 : res_op->set_op (MULT_EXPR, type, 2);
10811 : 24 : res_op->ops[0] = captures[0];
10812 : 24 : {
10813 : 24 : tree _o1[1], _r1;
10814 : 24 : {
10815 : 24 : tree _o2[1], _r2;
10816 : 24 : _o2[0] = captures[2];
10817 : 24 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
10818 : 24 : tem_op.resimplify (lseq, valueize);
10819 : 24 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
10820 : 24 : if (!_r2) goto next_after_fail1932;
10821 : 12 : _o1[0] = _r2;
10822 : : }
10823 : 12 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_POW10F, TREE_TYPE (_o1[0]), _o1[0]);
10824 : 12 : tem_op.resimplify (lseq, valueize);
10825 : 12 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
10826 : 12 : if (!_r1) goto next_after_fail1932;
10827 : 12 : res_op->ops[1] = _r1;
10828 : : }
10829 : 12 : res_op->resimplify (lseq, valueize);
10830 : 12 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1031, __FILE__, __LINE__, true);
10831 : 12 : return true;
10832 : : }
10833 : 12 : next_after_fail1932:;
10834 : : }
10835 : : }
10836 : : }
10837 : : break;
10838 : 24 : case CFN_BUILT_IN_POW10L:
10839 : 24 : if (gimple_call_num_args (_c1) == 1)
10840 : : {
10841 : 24 : tree _q30 = gimple_call_arg (_c1, 0);
10842 : 24 : _q30 = do_valueize (valueize, _q30);
10843 : 24 : {
10844 : 24 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p1, _q30 };
10845 : 24 : if (flag_unsafe_math_optimizations
10846 : : )
10847 : : {
10848 : 24 : gimple_seq *lseq = seq;
10849 : 24 : if (lseq
10850 : 12 : && (!single_use (captures[1])))
10851 : 12 : lseq = NULL;
10852 : 24 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1933;
10853 : 24 : {
10854 : 24 : res_op->set_op (MULT_EXPR, type, 2);
10855 : 24 : res_op->ops[0] = captures[0];
10856 : 24 : {
10857 : 24 : tree _o1[1], _r1;
10858 : 24 : {
10859 : 24 : tree _o2[1], _r2;
10860 : 24 : _o2[0] = captures[2];
10861 : 24 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
10862 : 24 : tem_op.resimplify (lseq, valueize);
10863 : 24 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
10864 : 24 : if (!_r2) goto next_after_fail1933;
10865 : 12 : _o1[0] = _r2;
10866 : : }
10867 : 12 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_POW10L, TREE_TYPE (_o1[0]), _o1[0]);
10868 : 12 : tem_op.resimplify (lseq, valueize);
10869 : 12 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
10870 : 12 : if (!_r1) goto next_after_fail1933;
10871 : 12 : res_op->ops[1] = _r1;
10872 : : }
10873 : 12 : res_op->resimplify (lseq, valueize);
10874 : 12 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1031, __FILE__, __LINE__, true);
10875 : 12 : return true;
10876 : : }
10877 : 12 : next_after_fail1933:;
10878 : : }
10879 : : }
10880 : : }
10881 : : break;
10882 : 0 : case CFN_EXP2:
10883 : 0 : if (gimple_call_num_args (_c1) == 1)
10884 : : {
10885 : 0 : tree _q30 = gimple_call_arg (_c1, 0);
10886 : 0 : _q30 = do_valueize (valueize, _q30);
10887 : 0 : {
10888 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p1, _q30 };
10889 : 0 : if (flag_unsafe_math_optimizations
10890 : : )
10891 : : {
10892 : 0 : gimple_seq *lseq = seq;
10893 : 0 : if (lseq
10894 : 0 : && (!single_use (captures[1])))
10895 : 0 : lseq = NULL;
10896 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1934;
10897 : 0 : {
10898 : 0 : res_op->set_op (MULT_EXPR, type, 2);
10899 : 0 : res_op->ops[0] = captures[0];
10900 : 0 : {
10901 : 0 : tree _o1[1], _r1;
10902 : 0 : {
10903 : 0 : tree _o2[1], _r2;
10904 : 0 : _o2[0] = captures[2];
10905 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
10906 : 0 : tem_op.resimplify (lseq, valueize);
10907 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
10908 : 0 : if (!_r2) goto next_after_fail1934;
10909 : 0 : _o1[0] = _r2;
10910 : : }
10911 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_EXP2, TREE_TYPE (_o1[0]), _o1[0]);
10912 : 0 : tem_op.resimplify (lseq, valueize);
10913 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
10914 : 0 : if (!_r1) goto next_after_fail1934;
10915 : 0 : res_op->ops[1] = _r1;
10916 : : }
10917 : 0 : res_op->resimplify (lseq, valueize);
10918 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1031, __FILE__, __LINE__, true);
10919 : 0 : return true;
10920 : : }
10921 : 0 : next_after_fail1934:;
10922 : : }
10923 : : }
10924 : : }
10925 : : break;
10926 : 763 : case CFN_SQRT:
10927 : 763 : if (gimple_call_num_args (_c1) == 1)
10928 : : {
10929 : 763 : tree _q30 = gimple_call_arg (_c1, 0);
10930 : 763 : _q30 = do_valueize (valueize, _q30);
10931 : 763 : switch (TREE_CODE (_q30))
10932 : : {
10933 : 763 : case SSA_NAME:
10934 : 763 : if (gimple *_d2 = get_def (valueize, _q30))
10935 : : {
10936 : 728 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
10937 : 738 : switch (gimple_assign_rhs_code (_a2))
10938 : : {
10939 : 80 : case RDIV_EXPR:
10940 : 80 : {
10941 : 80 : tree _q40 = gimple_assign_rhs1 (_a2);
10942 : 80 : _q40 = do_valueize (valueize, _q40);
10943 : 80 : tree _q41 = gimple_assign_rhs2 (_a2);
10944 : 80 : _q41 = do_valueize (valueize, _q41);
10945 : 80 : {
10946 : 80 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q40, _q41 };
10947 : 80 : if (flag_unsafe_math_optimizations
10948 : : )
10949 : : {
10950 : 0 : gimple_seq *lseq = seq;
10951 : 0 : if (lseq
10952 : 0 : && (!single_use (captures[1])
10953 : 0 : || !single_use (captures[2])))
10954 : 0 : lseq = NULL;
10955 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1935;
10956 : 0 : {
10957 : 0 : res_op->set_op (MULT_EXPR, type, 2);
10958 : 0 : res_op->ops[0] = captures[0];
10959 : 0 : {
10960 : 0 : tree _o1[1], _r1;
10961 : 0 : {
10962 : 0 : tree _o2[2], _r2;
10963 : 0 : _o2[0] = captures[4];
10964 : 0 : _o2[1] = captures[3];
10965 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), RDIV_EXPR, TREE_TYPE (_o2[0]), _o2[0], _o2[1]);
10966 : 0 : tem_op.resimplify (lseq, valueize);
10967 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
10968 : 0 : if (!_r2) goto next_after_fail1935;
10969 : 0 : _o1[0] = _r2;
10970 : : }
10971 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_SQRT, TREE_TYPE (_o1[0]), _o1[0]);
10972 : 0 : tem_op.resimplify (lseq, valueize);
10973 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
10974 : 0 : if (!_r1) goto next_after_fail1935;
10975 : 0 : res_op->ops[1] = _r1;
10976 : : }
10977 : 0 : res_op->resimplify (lseq, valueize);
10978 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1030, __FILE__, __LINE__, true);
10979 : 0 : return true;
10980 : : }
10981 : 80 : next_after_fail1935:;
10982 : : }
10983 : : }
10984 : 80 : break;
10985 : : }
10986 : : default:;
10987 : : }
10988 : : }
10989 : : break;
10990 : : default:;
10991 : : }
10992 : : }
10993 : : break;
10994 : 0 : case CFN_EXP10:
10995 : 0 : if (gimple_call_num_args (_c1) == 1)
10996 : : {
10997 : 0 : tree _q30 = gimple_call_arg (_c1, 0);
10998 : 0 : _q30 = do_valueize (valueize, _q30);
10999 : 0 : {
11000 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p1, _q30 };
11001 : 0 : if (flag_unsafe_math_optimizations
11002 : : )
11003 : : {
11004 : 0 : gimple_seq *lseq = seq;
11005 : 0 : if (lseq
11006 : 0 : && (!single_use (captures[1])))
11007 : 0 : lseq = NULL;
11008 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1936;
11009 : 0 : {
11010 : 0 : res_op->set_op (MULT_EXPR, type, 2);
11011 : 0 : res_op->ops[0] = captures[0];
11012 : 0 : {
11013 : 0 : tree _o1[1], _r1;
11014 : 0 : {
11015 : 0 : tree _o2[1], _r2;
11016 : 0 : _o2[0] = captures[2];
11017 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
11018 : 0 : tem_op.resimplify (lseq, valueize);
11019 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
11020 : 0 : if (!_r2) goto next_after_fail1936;
11021 : 0 : _o1[0] = _r2;
11022 : : }
11023 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_EXP10, TREE_TYPE (_o1[0]), _o1[0]);
11024 : 0 : tem_op.resimplify (lseq, valueize);
11025 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
11026 : 0 : if (!_r1) goto next_after_fail1936;
11027 : 0 : res_op->ops[1] = _r1;
11028 : : }
11029 : 0 : res_op->resimplify (lseq, valueize);
11030 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1031, __FILE__, __LINE__, true);
11031 : 0 : return true;
11032 : : }
11033 : 0 : next_after_fail1936:;
11034 : : }
11035 : : }
11036 : : }
11037 : : break;
11038 : 0 : case CFN_BUILT_IN_CBRTF:
11039 : 0 : if (gimple_call_num_args (_c1) == 1)
11040 : : {
11041 : 0 : tree _q30 = gimple_call_arg (_c1, 0);
11042 : 0 : _q30 = do_valueize (valueize, _q30);
11043 : 0 : switch (TREE_CODE (_q30))
11044 : : {
11045 : 0 : case SSA_NAME:
11046 : 0 : if (gimple *_d2 = get_def (valueize, _q30))
11047 : : {
11048 : 0 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
11049 : 0 : switch (gimple_assign_rhs_code (_a2))
11050 : : {
11051 : 0 : case RDIV_EXPR:
11052 : 0 : {
11053 : 0 : tree _q40 = gimple_assign_rhs1 (_a2);
11054 : 0 : _q40 = do_valueize (valueize, _q40);
11055 : 0 : tree _q41 = gimple_assign_rhs2 (_a2);
11056 : 0 : _q41 = do_valueize (valueize, _q41);
11057 : 0 : {
11058 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q40, _q41 };
11059 : 0 : if (flag_unsafe_math_optimizations
11060 : : )
11061 : : {
11062 : 0 : gimple_seq *lseq = seq;
11063 : 0 : if (lseq
11064 : 0 : && (!single_use (captures[1])
11065 : 0 : || !single_use (captures[2])))
11066 : 0 : lseq = NULL;
11067 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1937;
11068 : 0 : {
11069 : 0 : res_op->set_op (MULT_EXPR, type, 2);
11070 : 0 : res_op->ops[0] = captures[0];
11071 : 0 : {
11072 : 0 : tree _o1[1], _r1;
11073 : 0 : {
11074 : 0 : tree _o2[2], _r2;
11075 : 0 : _o2[0] = captures[4];
11076 : 0 : _o2[1] = captures[3];
11077 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), RDIV_EXPR, TREE_TYPE (_o2[0]), _o2[0], _o2[1]);
11078 : 0 : tem_op.resimplify (lseq, valueize);
11079 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
11080 : 0 : if (!_r2) goto next_after_fail1937;
11081 : 0 : _o1[0] = _r2;
11082 : : }
11083 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_CBRTF, TREE_TYPE (_o1[0]), _o1[0]);
11084 : 0 : tem_op.resimplify (lseq, valueize);
11085 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
11086 : 0 : if (!_r1) goto next_after_fail1937;
11087 : 0 : res_op->ops[1] = _r1;
11088 : : }
11089 : 0 : res_op->resimplify (lseq, valueize);
11090 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1030, __FILE__, __LINE__, true);
11091 : 0 : return true;
11092 : : }
11093 : 0 : next_after_fail1937:;
11094 : : }
11095 : : }
11096 : 0 : break;
11097 : : }
11098 : : default:;
11099 : : }
11100 : : }
11101 : : break;
11102 : : default:;
11103 : : }
11104 : : }
11105 : : break;
11106 : 0 : case CFN_BUILT_IN_CBRTL:
11107 : 0 : if (gimple_call_num_args (_c1) == 1)
11108 : : {
11109 : 0 : tree _q30 = gimple_call_arg (_c1, 0);
11110 : 0 : _q30 = do_valueize (valueize, _q30);
11111 : 0 : switch (TREE_CODE (_q30))
11112 : : {
11113 : 0 : case SSA_NAME:
11114 : 0 : if (gimple *_d2 = get_def (valueize, _q30))
11115 : : {
11116 : 0 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
11117 : 0 : switch (gimple_assign_rhs_code (_a2))
11118 : : {
11119 : 0 : case RDIV_EXPR:
11120 : 0 : {
11121 : 0 : tree _q40 = gimple_assign_rhs1 (_a2);
11122 : 0 : _q40 = do_valueize (valueize, _q40);
11123 : 0 : tree _q41 = gimple_assign_rhs2 (_a2);
11124 : 0 : _q41 = do_valueize (valueize, _q41);
11125 : 0 : {
11126 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q40, _q41 };
11127 : 0 : if (flag_unsafe_math_optimizations
11128 : : )
11129 : : {
11130 : 0 : gimple_seq *lseq = seq;
11131 : 0 : if (lseq
11132 : 0 : && (!single_use (captures[1])
11133 : 0 : || !single_use (captures[2])))
11134 : 0 : lseq = NULL;
11135 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1938;
11136 : 0 : {
11137 : 0 : res_op->set_op (MULT_EXPR, type, 2);
11138 : 0 : res_op->ops[0] = captures[0];
11139 : 0 : {
11140 : 0 : tree _o1[1], _r1;
11141 : 0 : {
11142 : 0 : tree _o2[2], _r2;
11143 : 0 : _o2[0] = captures[4];
11144 : 0 : _o2[1] = captures[3];
11145 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), RDIV_EXPR, TREE_TYPE (_o2[0]), _o2[0], _o2[1]);
11146 : 0 : tem_op.resimplify (lseq, valueize);
11147 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
11148 : 0 : if (!_r2) goto next_after_fail1938;
11149 : 0 : _o1[0] = _r2;
11150 : : }
11151 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_CBRTL, TREE_TYPE (_o1[0]), _o1[0]);
11152 : 0 : tem_op.resimplify (lseq, valueize);
11153 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
11154 : 0 : if (!_r1) goto next_after_fail1938;
11155 : 0 : res_op->ops[1] = _r1;
11156 : : }
11157 : 0 : res_op->resimplify (lseq, valueize);
11158 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1030, __FILE__, __LINE__, true);
11159 : 0 : return true;
11160 : : }
11161 : 0 : next_after_fail1938:;
11162 : : }
11163 : : }
11164 : 0 : break;
11165 : : }
11166 : : default:;
11167 : : }
11168 : : }
11169 : : break;
11170 : : default:;
11171 : : }
11172 : : }
11173 : : break;
11174 : 0 : case CFN_BUILT_IN_EXP10:
11175 : 0 : if (gimple_call_num_args (_c1) == 1)
11176 : : {
11177 : 0 : tree _q30 = gimple_call_arg (_c1, 0);
11178 : 0 : _q30 = do_valueize (valueize, _q30);
11179 : 0 : {
11180 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p1, _q30 };
11181 : 0 : if (flag_unsafe_math_optimizations
11182 : : )
11183 : : {
11184 : 0 : gimple_seq *lseq = seq;
11185 : 0 : if (lseq
11186 : 0 : && (!single_use (captures[1])))
11187 : 0 : lseq = NULL;
11188 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1939;
11189 : 0 : {
11190 : 0 : res_op->set_op (MULT_EXPR, type, 2);
11191 : 0 : res_op->ops[0] = captures[0];
11192 : 0 : {
11193 : 0 : tree _o1[1], _r1;
11194 : 0 : {
11195 : 0 : tree _o2[1], _r2;
11196 : 0 : _o2[0] = captures[2];
11197 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
11198 : 0 : tem_op.resimplify (lseq, valueize);
11199 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
11200 : 0 : if (!_r2) goto next_after_fail1939;
11201 : 0 : _o1[0] = _r2;
11202 : : }
11203 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_EXP10, TREE_TYPE (_o1[0]), _o1[0]);
11204 : 0 : tem_op.resimplify (lseq, valueize);
11205 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
11206 : 0 : if (!_r1) goto next_after_fail1939;
11207 : 0 : res_op->ops[1] = _r1;
11208 : : }
11209 : 0 : res_op->resimplify (lseq, valueize);
11210 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1031, __FILE__, __LINE__, true);
11211 : 0 : return true;
11212 : : }
11213 : 0 : next_after_fail1939:;
11214 : : }
11215 : : }
11216 : : }
11217 : : break;
11218 : 0 : case CFN_BUILT_IN_EXP2F:
11219 : 0 : if (gimple_call_num_args (_c1) == 1)
11220 : : {
11221 : 0 : tree _q30 = gimple_call_arg (_c1, 0);
11222 : 0 : _q30 = do_valueize (valueize, _q30);
11223 : 0 : {
11224 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p1, _q30 };
11225 : 0 : if (flag_unsafe_math_optimizations
11226 : : )
11227 : : {
11228 : 0 : gimple_seq *lseq = seq;
11229 : 0 : if (lseq
11230 : 0 : && (!single_use (captures[1])))
11231 : 0 : lseq = NULL;
11232 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1940;
11233 : 0 : {
11234 : 0 : res_op->set_op (MULT_EXPR, type, 2);
11235 : 0 : res_op->ops[0] = captures[0];
11236 : 0 : {
11237 : 0 : tree _o1[1], _r1;
11238 : 0 : {
11239 : 0 : tree _o2[1], _r2;
11240 : 0 : _o2[0] = captures[2];
11241 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
11242 : 0 : tem_op.resimplify (lseq, valueize);
11243 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
11244 : 0 : if (!_r2) goto next_after_fail1940;
11245 : 0 : _o1[0] = _r2;
11246 : : }
11247 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_EXP2F, TREE_TYPE (_o1[0]), _o1[0]);
11248 : 0 : tem_op.resimplify (lseq, valueize);
11249 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
11250 : 0 : if (!_r1) goto next_after_fail1940;
11251 : 0 : res_op->ops[1] = _r1;
11252 : : }
11253 : 0 : res_op->resimplify (lseq, valueize);
11254 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1031, __FILE__, __LINE__, true);
11255 : 0 : return true;
11256 : : }
11257 : 0 : next_after_fail1940:;
11258 : : }
11259 : : }
11260 : : }
11261 : : break;
11262 : 0 : case CFN_BUILT_IN_EXP2L:
11263 : 0 : if (gimple_call_num_args (_c1) == 1)
11264 : : {
11265 : 0 : tree _q30 = gimple_call_arg (_c1, 0);
11266 : 0 : _q30 = do_valueize (valueize, _q30);
11267 : 0 : {
11268 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p1, _q30 };
11269 : 0 : if (flag_unsafe_math_optimizations
11270 : : )
11271 : : {
11272 : 0 : gimple_seq *lseq = seq;
11273 : 0 : if (lseq
11274 : 0 : && (!single_use (captures[1])))
11275 : 0 : lseq = NULL;
11276 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1941;
11277 : 0 : {
11278 : 0 : res_op->set_op (MULT_EXPR, type, 2);
11279 : 0 : res_op->ops[0] = captures[0];
11280 : 0 : {
11281 : 0 : tree _o1[1], _r1;
11282 : 0 : {
11283 : 0 : tree _o2[1], _r2;
11284 : 0 : _o2[0] = captures[2];
11285 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
11286 : 0 : tem_op.resimplify (lseq, valueize);
11287 : 0 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
11288 : 0 : if (!_r2) goto next_after_fail1941;
11289 : 0 : _o1[0] = _r2;
11290 : : }
11291 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_EXP2L, TREE_TYPE (_o1[0]), _o1[0]);
11292 : 0 : tem_op.resimplify (lseq, valueize);
11293 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
11294 : 0 : if (!_r1) goto next_after_fail1941;
11295 : 0 : res_op->ops[1] = _r1;
11296 : : }
11297 : 0 : res_op->resimplify (lseq, valueize);
11298 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1031, __FILE__, __LINE__, true);
11299 : 0 : return true;
11300 : : }
11301 : 0 : next_after_fail1941:;
11302 : : }
11303 : : }
11304 : : }
11305 : : break;
11306 : 24 : case CFN_BUILT_IN_POW10:
11307 : 24 : if (gimple_call_num_args (_c1) == 1)
11308 : : {
11309 : 24 : tree _q30 = gimple_call_arg (_c1, 0);
11310 : 24 : _q30 = do_valueize (valueize, _q30);
11311 : 24 : {
11312 : 24 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p1, _q30 };
11313 : 24 : if (flag_unsafe_math_optimizations
11314 : : )
11315 : : {
11316 : 24 : gimple_seq *lseq = seq;
11317 : 24 : if (lseq
11318 : 12 : && (!single_use (captures[1])))
11319 : 12 : lseq = NULL;
11320 : 24 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1942;
11321 : 24 : {
11322 : 24 : res_op->set_op (MULT_EXPR, type, 2);
11323 : 24 : res_op->ops[0] = captures[0];
11324 : 24 : {
11325 : 24 : tree _o1[1], _r1;
11326 : 24 : {
11327 : 24 : tree _o2[1], _r2;
11328 : 24 : _o2[0] = captures[2];
11329 : 24 : gimple_match_op tem_op (res_op->cond.any_else (), NEGATE_EXPR, TREE_TYPE (_o2[0]), _o2[0]);
11330 : 24 : tem_op.resimplify (lseq, valueize);
11331 : 24 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
11332 : 24 : if (!_r2) goto next_after_fail1942;
11333 : 12 : _o1[0] = _r2;
11334 : : }
11335 : 12 : gimple_match_op tem_op (res_op->cond.any_else (), CFN_BUILT_IN_POW10, TREE_TYPE (_o1[0]), _o1[0]);
11336 : 12 : tem_op.resimplify (lseq, valueize);
11337 : 12 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
11338 : 12 : if (!_r1) goto next_after_fail1942;
11339 : 12 : res_op->ops[1] = _r1;
11340 : : }
11341 : 12 : res_op->resimplify (lseq, valueize);
11342 : 12 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1031, __FILE__, __LINE__, true);
11343 : 12 : return true;
11344 : : }
11345 : 12 : next_after_fail1942:;
11346 : : }
11347 : : }
11348 : : }
11349 : : break;
11350 : : default:;
11351 : : }
11352 : : }
11353 : : break;
11354 : 541453 : default:;
11355 : : }
11356 : 541453 : switch (TREE_CODE (_p0))
11357 : : {
11358 : 318623 : case SSA_NAME:
11359 : 318623 : if (gimple *_d1 = get_def (valueize, _p0))
11360 : : {
11361 : 251476 : if (gcall *_c1 = dyn_cast <gcall *> (_d1))
11362 : 12250 : switch (gimple_call_combined_fn (_c1))
11363 : : {
11364 : 676 : case CFN_BUILT_IN_SINHF:
11365 : 676 : if (gimple_call_num_args (_c1) == 1)
11366 : : {
11367 : 676 : tree _q20 = gimple_call_arg (_c1, 0);
11368 : 676 : _q20 = do_valueize (valueize, _q20);
11369 : 676 : switch (TREE_CODE (_p1))
11370 : : {
11371 : 676 : case SSA_NAME:
11372 : 676 : if (gimple *_d2 = get_def (valueize, _p1))
11373 : : {
11374 : 540 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
11375 : 0 : switch (gimple_call_combined_fn (_c2))
11376 : : {
11377 : 0 : case CFN_BUILT_IN_COSHF:
11378 : 0 : if (gimple_call_num_args (_c2) == 1)
11379 : : {
11380 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
11381 : 0 : _q40 = do_valueize (valueize, _q40);
11382 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
11383 : : {
11384 : 0 : {
11385 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
11386 : 0 : if (gimple_simplify_330 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_SINHF, CFN_BUILT_IN_COSHF, CFN_BUILT_IN_TANHF))
11387 : 0 : return true;
11388 : : }
11389 : : }
11390 : : }
11391 : : break;
11392 : : default:;
11393 : : }
11394 : : }
11395 : : break;
11396 : : default:;
11397 : : }
11398 : : }
11399 : : break;
11400 : 616 : case CFN_BUILT_IN_SINHL:
11401 : 616 : if (gimple_call_num_args (_c1) == 1)
11402 : : {
11403 : 616 : tree _q20 = gimple_call_arg (_c1, 0);
11404 : 616 : _q20 = do_valueize (valueize, _q20);
11405 : 616 : switch (TREE_CODE (_p1))
11406 : : {
11407 : 616 : case SSA_NAME:
11408 : 616 : if (gimple *_d2 = get_def (valueize, _p1))
11409 : : {
11410 : 492 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
11411 : 0 : switch (gimple_call_combined_fn (_c2))
11412 : : {
11413 : 0 : case CFN_BUILT_IN_COSHL:
11414 : 0 : if (gimple_call_num_args (_c2) == 1)
11415 : : {
11416 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
11417 : 0 : _q40 = do_valueize (valueize, _q40);
11418 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
11419 : : {
11420 : 0 : {
11421 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
11422 : 0 : if (gimple_simplify_330 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_SINHL, CFN_BUILT_IN_COSHL, CFN_BUILT_IN_TANHL))
11423 : 0 : return true;
11424 : : }
11425 : : }
11426 : : }
11427 : : break;
11428 : : default:;
11429 : : }
11430 : : }
11431 : : break;
11432 : : default:;
11433 : : }
11434 : : }
11435 : : break;
11436 : 0 : case CFN_BUILT_IN_TANHF:
11437 : 0 : if (gimple_call_num_args (_c1) == 1)
11438 : : {
11439 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
11440 : 0 : _q20 = do_valueize (valueize, _q20);
11441 : 0 : switch (TREE_CODE (_p1))
11442 : : {
11443 : 0 : case SSA_NAME:
11444 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
11445 : : {
11446 : 0 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
11447 : 0 : switch (gimple_call_combined_fn (_c2))
11448 : : {
11449 : 0 : case CFN_BUILT_IN_SINHF:
11450 : 0 : if (gimple_call_num_args (_c2) == 1)
11451 : : {
11452 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
11453 : 0 : _q40 = do_valueize (valueize, _q40);
11454 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
11455 : : {
11456 : 0 : {
11457 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
11458 : 0 : if (gimple_simplify_331 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_TANHF, CFN_BUILT_IN_SINHF, CFN_BUILT_IN_COSHF))
11459 : 0 : return true;
11460 : : }
11461 : : }
11462 : : }
11463 : : break;
11464 : : default:;
11465 : : }
11466 : : }
11467 : : break;
11468 : : default:;
11469 : : }
11470 : : }
11471 : : break;
11472 : 0 : case CFN_BUILT_IN_TANHL:
11473 : 0 : if (gimple_call_num_args (_c1) == 1)
11474 : : {
11475 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
11476 : 0 : _q20 = do_valueize (valueize, _q20);
11477 : 0 : switch (TREE_CODE (_p1))
11478 : : {
11479 : 0 : case SSA_NAME:
11480 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
11481 : : {
11482 : 0 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
11483 : 0 : switch (gimple_call_combined_fn (_c2))
11484 : : {
11485 : 0 : case CFN_BUILT_IN_SINHL:
11486 : 0 : if (gimple_call_num_args (_c2) == 1)
11487 : : {
11488 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
11489 : 0 : _q40 = do_valueize (valueize, _q40);
11490 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
11491 : : {
11492 : 0 : {
11493 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
11494 : 0 : if (gimple_simplify_331 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_TANHL, CFN_BUILT_IN_SINHL, CFN_BUILT_IN_COSHL))
11495 : 0 : return true;
11496 : : }
11497 : : }
11498 : : }
11499 : : break;
11500 : : default:;
11501 : : }
11502 : : }
11503 : : break;
11504 : : default:;
11505 : : }
11506 : : }
11507 : : break;
11508 : 96 : case CFN_BUILT_IN_COS:
11509 : 96 : if (gimple_call_num_args (_c1) == 1)
11510 : : {
11511 : 96 : tree _q20 = gimple_call_arg (_c1, 0);
11512 : 96 : _q20 = do_valueize (valueize, _q20);
11513 : 96 : switch (TREE_CODE (_p1))
11514 : : {
11515 : 96 : case SSA_NAME:
11516 : 96 : if (gimple *_d2 = get_def (valueize, _p1))
11517 : : {
11518 : 96 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
11519 : 0 : switch (gimple_call_combined_fn (_c2))
11520 : : {
11521 : 0 : case CFN_BUILT_IN_SIN:
11522 : 0 : if (gimple_call_num_args (_c2) == 1)
11523 : : {
11524 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
11525 : 0 : _q40 = do_valueize (valueize, _q40);
11526 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
11527 : : {
11528 : 0 : {
11529 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
11530 : 0 : if (gimple_simplify_332 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_COS, CFN_BUILT_IN_SIN, CFN_BUILT_IN_TAN))
11531 : 0 : return true;
11532 : : }
11533 : : }
11534 : : }
11535 : : break;
11536 : : default:;
11537 : : }
11538 : : }
11539 : : break;
11540 : : default:;
11541 : : }
11542 : : }
11543 : : break;
11544 : 0 : case CFN_BUILT_IN_POW:
11545 : 0 : if (gimple_call_num_args (_c1) == 2)
11546 : : {
11547 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
11548 : 0 : _q20 = do_valueize (valueize, _q20);
11549 : 0 : tree _q21 = gimple_call_arg (_c1, 1);
11550 : 0 : _q21 = do_valueize (valueize, _q21);
11551 : 0 : switch (TREE_CODE (_q21))
11552 : : {
11553 : 0 : case REAL_CST:
11554 : 0 : {
11555 : 0 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
11556 : : {
11557 : 0 : {
11558 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q21 };
11559 : 0 : if (gimple_simplify_334 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_POW))
11560 : 0 : return true;
11561 : : }
11562 : : }
11563 : : break;
11564 : : }
11565 : : default:;
11566 : : }
11567 : : }
11568 : : break;
11569 : 615 : case CFN_BUILT_IN_SIN:
11570 : 615 : if (gimple_call_num_args (_c1) == 1)
11571 : : {
11572 : 615 : tree _q20 = gimple_call_arg (_c1, 0);
11573 : 615 : _q20 = do_valueize (valueize, _q20);
11574 : 615 : switch (TREE_CODE (_p1))
11575 : : {
11576 : 615 : case SSA_NAME:
11577 : 615 : if (gimple *_d2 = get_def (valueize, _p1))
11578 : : {
11579 : 489 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
11580 : 0 : switch (gimple_call_combined_fn (_c2))
11581 : : {
11582 : 0 : case CFN_BUILT_IN_COS:
11583 : 0 : if (gimple_call_num_args (_c2) == 1)
11584 : : {
11585 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
11586 : 0 : _q40 = do_valueize (valueize, _q40);
11587 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
11588 : : {
11589 : 0 : {
11590 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
11591 : 0 : if (gimple_simplify_328 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_SIN, CFN_BUILT_IN_COS, CFN_BUILT_IN_TAN))
11592 : 0 : return true;
11593 : : }
11594 : : }
11595 : : }
11596 : : break;
11597 : 0 : case CFN_BUILT_IN_TAN:
11598 : 0 : if (gimple_call_num_args (_c2) == 1)
11599 : : {
11600 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
11601 : 0 : _q40 = do_valueize (valueize, _q40);
11602 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
11603 : : {
11604 : 0 : {
11605 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
11606 : 0 : if (gimple_simplify_329 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_SIN, CFN_BUILT_IN_TAN, CFN_BUILT_IN_COS))
11607 : 0 : return true;
11608 : : }
11609 : : }
11610 : : }
11611 : : break;
11612 : : default:;
11613 : : }
11614 : : }
11615 : : break;
11616 : : default:;
11617 : : }
11618 : : }
11619 : : break;
11620 : 0 : case CFN_BUILT_IN_TAN:
11621 : 0 : if (gimple_call_num_args (_c1) == 1)
11622 : : {
11623 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
11624 : 0 : _q20 = do_valueize (valueize, _q20);
11625 : 0 : switch (TREE_CODE (_p1))
11626 : : {
11627 : 0 : case SSA_NAME:
11628 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
11629 : : {
11630 : 0 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
11631 : 0 : switch (gimple_call_combined_fn (_c2))
11632 : : {
11633 : 0 : case CFN_BUILT_IN_SIN:
11634 : 0 : if (gimple_call_num_args (_c2) == 1)
11635 : : {
11636 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
11637 : 0 : _q40 = do_valueize (valueize, _q40);
11638 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
11639 : : {
11640 : 0 : {
11641 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
11642 : 0 : if (gimple_simplify_333 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_TAN, CFN_BUILT_IN_SIN, CFN_BUILT_IN_COS))
11643 : 0 : return true;
11644 : : }
11645 : : }
11646 : : }
11647 : : break;
11648 : : default:;
11649 : : }
11650 : : }
11651 : : break;
11652 : : default:;
11653 : : }
11654 : : }
11655 : : break;
11656 : 0 : case CFN_BUILT_IN_COSF:
11657 : 0 : if (gimple_call_num_args (_c1) == 1)
11658 : : {
11659 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
11660 : 0 : _q20 = do_valueize (valueize, _q20);
11661 : 0 : switch (TREE_CODE (_p1))
11662 : : {
11663 : 0 : case SSA_NAME:
11664 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
11665 : : {
11666 : 0 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
11667 : 0 : switch (gimple_call_combined_fn (_c2))
11668 : : {
11669 : 0 : case CFN_BUILT_IN_SINF:
11670 : 0 : if (gimple_call_num_args (_c2) == 1)
11671 : : {
11672 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
11673 : 0 : _q40 = do_valueize (valueize, _q40);
11674 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
11675 : : {
11676 : 0 : {
11677 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
11678 : 0 : if (gimple_simplify_332 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_COSF, CFN_BUILT_IN_SINF, CFN_BUILT_IN_TANF))
11679 : 0 : return true;
11680 : : }
11681 : : }
11682 : : }
11683 : : break;
11684 : : default:;
11685 : : }
11686 : : }
11687 : : break;
11688 : : default:;
11689 : : }
11690 : : }
11691 : : break;
11692 : 12 : case CFN_BUILT_IN_COSL:
11693 : 12 : if (gimple_call_num_args (_c1) == 1)
11694 : : {
11695 : 12 : tree _q20 = gimple_call_arg (_c1, 0);
11696 : 12 : _q20 = do_valueize (valueize, _q20);
11697 : 12 : switch (TREE_CODE (_p1))
11698 : : {
11699 : 12 : case SSA_NAME:
11700 : 12 : if (gimple *_d2 = get_def (valueize, _p1))
11701 : : {
11702 : 11 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
11703 : 4 : switch (gimple_call_combined_fn (_c2))
11704 : : {
11705 : 0 : case CFN_BUILT_IN_SINL:
11706 : 0 : if (gimple_call_num_args (_c2) == 1)
11707 : : {
11708 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
11709 : 0 : _q40 = do_valueize (valueize, _q40);
11710 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
11711 : : {
11712 : 0 : {
11713 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
11714 : 0 : if (gimple_simplify_332 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_COSL, CFN_BUILT_IN_SINL, CFN_BUILT_IN_TANL))
11715 : 0 : return true;
11716 : : }
11717 : : }
11718 : : }
11719 : : break;
11720 : : default:;
11721 : : }
11722 : : }
11723 : : break;
11724 : : default:;
11725 : : }
11726 : : }
11727 : : break;
11728 : 0 : case CFN_BUILT_IN_POWF:
11729 : 0 : if (gimple_call_num_args (_c1) == 2)
11730 : : {
11731 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
11732 : 0 : _q20 = do_valueize (valueize, _q20);
11733 : 0 : tree _q21 = gimple_call_arg (_c1, 1);
11734 : 0 : _q21 = do_valueize (valueize, _q21);
11735 : 0 : switch (TREE_CODE (_q21))
11736 : : {
11737 : 0 : case REAL_CST:
11738 : 0 : {
11739 : 0 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
11740 : : {
11741 : 0 : {
11742 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q21 };
11743 : 0 : if (gimple_simplify_334 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_POWF))
11744 : 0 : return true;
11745 : : }
11746 : : }
11747 : : break;
11748 : : }
11749 : : default:;
11750 : : }
11751 : : }
11752 : : break;
11753 : 0 : case CFN_BUILT_IN_POWL:
11754 : 0 : if (gimple_call_num_args (_c1) == 2)
11755 : : {
11756 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
11757 : 0 : _q20 = do_valueize (valueize, _q20);
11758 : 0 : tree _q21 = gimple_call_arg (_c1, 1);
11759 : 0 : _q21 = do_valueize (valueize, _q21);
11760 : 0 : switch (TREE_CODE (_q21))
11761 : : {
11762 : 0 : case REAL_CST:
11763 : 0 : {
11764 : 0 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
11765 : : {
11766 : 0 : {
11767 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q21 };
11768 : 0 : if (gimple_simplify_334 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_POWL))
11769 : 0 : return true;
11770 : : }
11771 : : }
11772 : : break;
11773 : : }
11774 : : default:;
11775 : : }
11776 : : }
11777 : : break;
11778 : 406 : case CFN_BUILT_IN_SINF:
11779 : 406 : if (gimple_call_num_args (_c1) == 1)
11780 : : {
11781 : 406 : tree _q20 = gimple_call_arg (_c1, 0);
11782 : 406 : _q20 = do_valueize (valueize, _q20);
11783 : 406 : switch (TREE_CODE (_p1))
11784 : : {
11785 : 406 : case SSA_NAME:
11786 : 406 : if (gimple *_d2 = get_def (valueize, _p1))
11787 : : {
11788 : 324 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
11789 : 0 : switch (gimple_call_combined_fn (_c2))
11790 : : {
11791 : 0 : case CFN_BUILT_IN_COSF:
11792 : 0 : if (gimple_call_num_args (_c2) == 1)
11793 : : {
11794 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
11795 : 0 : _q40 = do_valueize (valueize, _q40);
11796 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
11797 : : {
11798 : 0 : {
11799 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
11800 : 0 : if (gimple_simplify_328 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_SINF, CFN_BUILT_IN_COSF, CFN_BUILT_IN_TANF))
11801 : 0 : return true;
11802 : : }
11803 : : }
11804 : : }
11805 : : break;
11806 : 0 : case CFN_BUILT_IN_TANF:
11807 : 0 : if (gimple_call_num_args (_c2) == 1)
11808 : : {
11809 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
11810 : 0 : _q40 = do_valueize (valueize, _q40);
11811 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
11812 : : {
11813 : 0 : {
11814 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
11815 : 0 : if (gimple_simplify_329 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_SINF, CFN_BUILT_IN_TANF, CFN_BUILT_IN_COSF))
11816 : 0 : return true;
11817 : : }
11818 : : }
11819 : : }
11820 : : break;
11821 : : default:;
11822 : : }
11823 : : }
11824 : : break;
11825 : : default:;
11826 : : }
11827 : : }
11828 : : break;
11829 : 775 : case CFN_BUILT_IN_SINH:
11830 : 775 : if (gimple_call_num_args (_c1) == 1)
11831 : : {
11832 : 775 : tree _q20 = gimple_call_arg (_c1, 0);
11833 : 775 : _q20 = do_valueize (valueize, _q20);
11834 : 775 : switch (TREE_CODE (_p1))
11835 : : {
11836 : 775 : case SSA_NAME:
11837 : 775 : if (gimple *_d2 = get_def (valueize, _p1))
11838 : : {
11839 : 615 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
11840 : 0 : switch (gimple_call_combined_fn (_c2))
11841 : : {
11842 : 0 : case CFN_BUILT_IN_COSH:
11843 : 0 : if (gimple_call_num_args (_c2) == 1)
11844 : : {
11845 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
11846 : 0 : _q40 = do_valueize (valueize, _q40);
11847 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
11848 : : {
11849 : 0 : {
11850 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
11851 : 0 : if (gimple_simplify_330 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_SINH, CFN_BUILT_IN_COSH, CFN_BUILT_IN_TANH))
11852 : 0 : return true;
11853 : : }
11854 : : }
11855 : : }
11856 : : break;
11857 : : default:;
11858 : : }
11859 : : }
11860 : : break;
11861 : : default:;
11862 : : }
11863 : : }
11864 : : break;
11865 : 376 : case CFN_BUILT_IN_SINL:
11866 : 376 : if (gimple_call_num_args (_c1) == 1)
11867 : : {
11868 : 376 : tree _q20 = gimple_call_arg (_c1, 0);
11869 : 376 : _q20 = do_valueize (valueize, _q20);
11870 : 376 : switch (TREE_CODE (_p1))
11871 : : {
11872 : 376 : case SSA_NAME:
11873 : 376 : if (gimple *_d2 = get_def (valueize, _p1))
11874 : : {
11875 : 300 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
11876 : 0 : switch (gimple_call_combined_fn (_c2))
11877 : : {
11878 : 0 : case CFN_BUILT_IN_COSL:
11879 : 0 : if (gimple_call_num_args (_c2) == 1)
11880 : : {
11881 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
11882 : 0 : _q40 = do_valueize (valueize, _q40);
11883 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
11884 : : {
11885 : 0 : {
11886 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
11887 : 0 : if (gimple_simplify_328 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_SINL, CFN_BUILT_IN_COSL, CFN_BUILT_IN_TANL))
11888 : 0 : return true;
11889 : : }
11890 : : }
11891 : : }
11892 : : break;
11893 : 0 : case CFN_BUILT_IN_TANL:
11894 : 0 : if (gimple_call_num_args (_c2) == 1)
11895 : : {
11896 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
11897 : 0 : _q40 = do_valueize (valueize, _q40);
11898 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
11899 : : {
11900 : 0 : {
11901 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
11902 : 0 : if (gimple_simplify_329 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_SINL, CFN_BUILT_IN_TANL, CFN_BUILT_IN_COSL))
11903 : 0 : return true;
11904 : : }
11905 : : }
11906 : : }
11907 : : break;
11908 : : default:;
11909 : : }
11910 : : }
11911 : : break;
11912 : : default:;
11913 : : }
11914 : : }
11915 : : break;
11916 : 0 : case CFN_BUILT_IN_TANF:
11917 : 0 : if (gimple_call_num_args (_c1) == 1)
11918 : : {
11919 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
11920 : 0 : _q20 = do_valueize (valueize, _q20);
11921 : 0 : switch (TREE_CODE (_p1))
11922 : : {
11923 : 0 : case SSA_NAME:
11924 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
11925 : : {
11926 : 0 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
11927 : 0 : switch (gimple_call_combined_fn (_c2))
11928 : : {
11929 : 0 : case CFN_BUILT_IN_SINF:
11930 : 0 : if (gimple_call_num_args (_c2) == 1)
11931 : : {
11932 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
11933 : 0 : _q40 = do_valueize (valueize, _q40);
11934 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
11935 : : {
11936 : 0 : {
11937 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
11938 : 0 : if (gimple_simplify_333 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_TANF, CFN_BUILT_IN_SINF, CFN_BUILT_IN_COSF))
11939 : 0 : return true;
11940 : : }
11941 : : }
11942 : : }
11943 : : break;
11944 : : default:;
11945 : : }
11946 : : }
11947 : : break;
11948 : : default:;
11949 : : }
11950 : : }
11951 : : break;
11952 : 0 : case CFN_BUILT_IN_TANH:
11953 : 0 : if (gimple_call_num_args (_c1) == 1)
11954 : : {
11955 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
11956 : 0 : _q20 = do_valueize (valueize, _q20);
11957 : 0 : switch (TREE_CODE (_p1))
11958 : : {
11959 : 0 : case SSA_NAME:
11960 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
11961 : : {
11962 : 0 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
11963 : 0 : switch (gimple_call_combined_fn (_c2))
11964 : : {
11965 : 0 : case CFN_BUILT_IN_SINH:
11966 : 0 : if (gimple_call_num_args (_c2) == 1)
11967 : : {
11968 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
11969 : 0 : _q40 = do_valueize (valueize, _q40);
11970 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
11971 : : {
11972 : 0 : {
11973 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
11974 : 0 : if (gimple_simplify_331 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_TANH, CFN_BUILT_IN_SINH, CFN_BUILT_IN_COSH))
11975 : 0 : return true;
11976 : : }
11977 : : }
11978 : : }
11979 : : break;
11980 : : default:;
11981 : : }
11982 : : }
11983 : : break;
11984 : : default:;
11985 : : }
11986 : : }
11987 : : break;
11988 : 0 : case CFN_BUILT_IN_TANL:
11989 : 0 : if (gimple_call_num_args (_c1) == 1)
11990 : : {
11991 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
11992 : 0 : _q20 = do_valueize (valueize, _q20);
11993 : 0 : switch (TREE_CODE (_p1))
11994 : : {
11995 : 0 : case SSA_NAME:
11996 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
11997 : : {
11998 : 0 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
11999 : 0 : switch (gimple_call_combined_fn (_c2))
12000 : : {
12001 : 0 : case CFN_BUILT_IN_SINL:
12002 : 0 : if (gimple_call_num_args (_c2) == 1)
12003 : : {
12004 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
12005 : 0 : _q40 = do_valueize (valueize, _q40);
12006 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
12007 : : {
12008 : 0 : {
12009 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
12010 : 0 : if (gimple_simplify_333 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_TANL, CFN_BUILT_IN_SINL, CFN_BUILT_IN_COSL))
12011 : 0 : return true;
12012 : : }
12013 : : }
12014 : : }
12015 : : break;
12016 : : default:;
12017 : : }
12018 : : }
12019 : : break;
12020 : : default:;
12021 : : }
12022 : : }
12023 : : break;
12024 : 0 : case CFN_COS:
12025 : 0 : if (gimple_call_num_args (_c1) == 1)
12026 : : {
12027 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
12028 : 0 : _q20 = do_valueize (valueize, _q20);
12029 : 0 : switch (TREE_CODE (_p1))
12030 : : {
12031 : 0 : case SSA_NAME:
12032 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
12033 : : {
12034 : 0 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
12035 : 0 : switch (gimple_call_combined_fn (_c2))
12036 : : {
12037 : 0 : case CFN_SIN:
12038 : 0 : if (gimple_call_num_args (_c2) == 1)
12039 : : {
12040 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
12041 : 0 : _q40 = do_valueize (valueize, _q40);
12042 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
12043 : : {
12044 : 0 : {
12045 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
12046 : 0 : if (gimple_simplify_332 (res_op, seq, valueize, type, captures, CFN_COS, CFN_SIN, CFN_TAN))
12047 : 0 : return true;
12048 : : }
12049 : : }
12050 : : }
12051 : : break;
12052 : : default:;
12053 : : }
12054 : : }
12055 : : break;
12056 : : default:;
12057 : : }
12058 : : }
12059 : : break;
12060 : 0 : case CFN_POW:
12061 : 0 : if (gimple_call_num_args (_c1) == 2)
12062 : : {
12063 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
12064 : 0 : _q20 = do_valueize (valueize, _q20);
12065 : 0 : tree _q21 = gimple_call_arg (_c1, 1);
12066 : 0 : _q21 = do_valueize (valueize, _q21);
12067 : 0 : switch (TREE_CODE (_q21))
12068 : : {
12069 : 0 : case REAL_CST:
12070 : 0 : {
12071 : 0 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
12072 : : {
12073 : 0 : {
12074 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q21 };
12075 : 0 : if (gimple_simplify_334 (res_op, seq, valueize, type, captures, CFN_POW))
12076 : 0 : return true;
12077 : : }
12078 : : }
12079 : : break;
12080 : : }
12081 : : default:;
12082 : : }
12083 : : }
12084 : : break;
12085 : 0 : case CFN_SIN:
12086 : 0 : if (gimple_call_num_args (_c1) == 1)
12087 : : {
12088 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
12089 : 0 : _q20 = do_valueize (valueize, _q20);
12090 : 0 : switch (TREE_CODE (_p1))
12091 : : {
12092 : 0 : case SSA_NAME:
12093 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
12094 : : {
12095 : 0 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
12096 : 0 : switch (gimple_call_combined_fn (_c2))
12097 : : {
12098 : 0 : case CFN_COS:
12099 : 0 : if (gimple_call_num_args (_c2) == 1)
12100 : : {
12101 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
12102 : 0 : _q40 = do_valueize (valueize, _q40);
12103 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
12104 : : {
12105 : 0 : {
12106 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
12107 : 0 : if (gimple_simplify_328 (res_op, seq, valueize, type, captures, CFN_SIN, CFN_COS, CFN_TAN))
12108 : 0 : return true;
12109 : : }
12110 : : }
12111 : : }
12112 : : break;
12113 : 0 : case CFN_TAN:
12114 : 0 : if (gimple_call_num_args (_c2) == 1)
12115 : : {
12116 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
12117 : 0 : _q40 = do_valueize (valueize, _q40);
12118 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
12119 : : {
12120 : 0 : {
12121 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
12122 : 0 : if (gimple_simplify_329 (res_op, seq, valueize, type, captures, CFN_SIN, CFN_TAN, CFN_COS))
12123 : 0 : return true;
12124 : : }
12125 : : }
12126 : : }
12127 : : break;
12128 : : default:;
12129 : : }
12130 : : }
12131 : : break;
12132 : : default:;
12133 : : }
12134 : : }
12135 : : break;
12136 : 0 : case CFN_TAN:
12137 : 0 : if (gimple_call_num_args (_c1) == 1)
12138 : : {
12139 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
12140 : 0 : _q20 = do_valueize (valueize, _q20);
12141 : 0 : switch (TREE_CODE (_p1))
12142 : : {
12143 : 0 : case SSA_NAME:
12144 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
12145 : : {
12146 : 0 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
12147 : 0 : switch (gimple_call_combined_fn (_c2))
12148 : : {
12149 : 0 : case CFN_SIN:
12150 : 0 : if (gimple_call_num_args (_c2) == 1)
12151 : : {
12152 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
12153 : 0 : _q40 = do_valueize (valueize, _q40);
12154 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
12155 : : {
12156 : 0 : {
12157 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
12158 : 0 : if (gimple_simplify_333 (res_op, seq, valueize, type, captures, CFN_TAN, CFN_SIN, CFN_COS))
12159 : 0 : return true;
12160 : : }
12161 : : }
12162 : : }
12163 : : break;
12164 : : default:;
12165 : : }
12166 : : }
12167 : : break;
12168 : : default:;
12169 : : }
12170 : : }
12171 : : break;
12172 : 0 : case CFN_SINH:
12173 : 0 : if (gimple_call_num_args (_c1) == 1)
12174 : : {
12175 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
12176 : 0 : _q20 = do_valueize (valueize, _q20);
12177 : 0 : switch (TREE_CODE (_p1))
12178 : : {
12179 : 0 : case SSA_NAME:
12180 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
12181 : : {
12182 : 0 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
12183 : 0 : switch (gimple_call_combined_fn (_c2))
12184 : : {
12185 : 0 : case CFN_COSH:
12186 : 0 : if (gimple_call_num_args (_c2) == 1)
12187 : : {
12188 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
12189 : 0 : _q40 = do_valueize (valueize, _q40);
12190 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
12191 : : {
12192 : 0 : {
12193 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
12194 : 0 : if (gimple_simplify_330 (res_op, seq, valueize, type, captures, CFN_SINH, CFN_COSH, CFN_TANH))
12195 : 0 : return true;
12196 : : }
12197 : : }
12198 : : }
12199 : : break;
12200 : : default:;
12201 : : }
12202 : : }
12203 : : break;
12204 : : default:;
12205 : : }
12206 : : }
12207 : : break;
12208 : 0 : case CFN_TANH:
12209 : 0 : if (gimple_call_num_args (_c1) == 1)
12210 : : {
12211 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
12212 : 0 : _q20 = do_valueize (valueize, _q20);
12213 : 0 : switch (TREE_CODE (_p1))
12214 : : {
12215 : 0 : case SSA_NAME:
12216 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
12217 : : {
12218 : 0 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
12219 : 0 : switch (gimple_call_combined_fn (_c2))
12220 : : {
12221 : 0 : case CFN_SINH:
12222 : 0 : if (gimple_call_num_args (_c2) == 1)
12223 : : {
12224 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
12225 : 0 : _q40 = do_valueize (valueize, _q40);
12226 : 0 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _q20, 0) && types_match (_q40, _q20)))
12227 : : {
12228 : 0 : {
12229 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
12230 : 0 : if (gimple_simplify_331 (res_op, seq, valueize, type, captures, CFN_TANH, CFN_SINH, CFN_COSH))
12231 : 0 : return true;
12232 : : }
12233 : : }
12234 : : }
12235 : : break;
12236 : : default:;
12237 : : }
12238 : : }
12239 : : break;
12240 : : default:;
12241 : : }
12242 : : }
12243 : : break;
12244 : : default:;
12245 : : }
12246 : : }
12247 : : break;
12248 : 541453 : default:;
12249 : : }
12250 : 541453 : switch (TREE_CODE (_p1))
12251 : : {
12252 : 452733 : case SSA_NAME:
12253 : 452733 : if (gimple *_d1 = get_def (valueize, _p1))
12254 : : {
12255 : 338932 : if (gcall *_c1 = dyn_cast <gcall *> (_d1))
12256 : 23431 : switch (gimple_call_combined_fn (_c1))
12257 : : {
12258 : 233 : case CFN_BUILT_IN_POW:
12259 : 233 : if (gimple_call_num_args (_c1) == 2)
12260 : : {
12261 : 233 : tree _q30 = gimple_call_arg (_c1, 0);
12262 : 233 : _q30 = do_valueize (valueize, _q30);
12263 : 233 : tree _q31 = gimple_call_arg (_c1, 1);
12264 : 233 : _q31 = do_valueize (valueize, _q31);
12265 : 233 : {
12266 : 233 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q31 };
12267 : 233 : if (gimple_simplify_335 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_POW))
12268 : 0 : return true;
12269 : : }
12270 : : }
12271 : : break;
12272 : 0 : case CFN_BUILT_IN_POWF:
12273 : 0 : if (gimple_call_num_args (_c1) == 2)
12274 : : {
12275 : 0 : tree _q30 = gimple_call_arg (_c1, 0);
12276 : 0 : _q30 = do_valueize (valueize, _q30);
12277 : 0 : tree _q31 = gimple_call_arg (_c1, 1);
12278 : 0 : _q31 = do_valueize (valueize, _q31);
12279 : 0 : {
12280 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q31 };
12281 : 0 : if (gimple_simplify_335 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_POWF))
12282 : 0 : return true;
12283 : : }
12284 : : }
12285 : : break;
12286 : 0 : case CFN_BUILT_IN_POWL:
12287 : 0 : if (gimple_call_num_args (_c1) == 2)
12288 : : {
12289 : 0 : tree _q30 = gimple_call_arg (_c1, 0);
12290 : 0 : _q30 = do_valueize (valueize, _q30);
12291 : 0 : tree _q31 = gimple_call_arg (_c1, 1);
12292 : 0 : _q31 = do_valueize (valueize, _q31);
12293 : 0 : {
12294 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q31 };
12295 : 0 : if (gimple_simplify_335 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_POWL))
12296 : 0 : return true;
12297 : : }
12298 : : }
12299 : : break;
12300 : 0 : case CFN_POW:
12301 : 0 : if (gimple_call_num_args (_c1) == 2)
12302 : : {
12303 : 0 : tree _q30 = gimple_call_arg (_c1, 0);
12304 : 0 : _q30 = do_valueize (valueize, _q30);
12305 : 0 : tree _q31 = gimple_call_arg (_c1, 1);
12306 : 0 : _q31 = do_valueize (valueize, _q31);
12307 : 0 : {
12308 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q31 };
12309 : 0 : if (gimple_simplify_335 (res_op, seq, valueize, type, captures, CFN_POW))
12310 : 0 : return true;
12311 : : }
12312 : : }
12313 : : break;
12314 : : default:;
12315 : : }
12316 : : }
12317 : : break;
12318 : : default:;
12319 : : }
12320 : : return false;
12321 : : }
12322 : :
12323 : : bool
12324 : 8111550 : gimple_simplify_GE_EXPR (gimple_match_op *res_op, gimple_seq *seq,
12325 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
12326 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0, tree _p1)
12327 : : {
12328 : 8111550 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
12329 : 8111550 : switch (TREE_CODE (_p0))
12330 : : {
12331 : 7860698 : case SSA_NAME:
12332 : 7860698 : if (gimple *_d1 = get_def (valueize, _p0))
12333 : : {
12334 : 2374656 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
12335 : 2226557 : switch (gimple_assign_rhs_code (_a1))
12336 : : {
12337 : 10957 : case RDIV_EXPR:
12338 : 10957 : {
12339 : 10957 : tree _q20 = gimple_assign_rhs1 (_a1);
12340 : 10957 : _q20 = do_valueize (valueize, _q20);
12341 : 10957 : tree _q21 = gimple_assign_rhs2 (_a1);
12342 : 10957 : _q21 = do_valueize (valueize, _q21);
12343 : 10957 : switch (TREE_CODE (_q20))
12344 : : {
12345 : 1885 : case REAL_CST:
12346 : 1885 : {
12347 : 1885 : if (real_zerop (_p1))
12348 : : {
12349 : 59 : {
12350 : 59 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
12351 : 59 : if (gimple_simplify_336 (res_op, seq, valueize, type, captures, GE_EXPR, LE_EXPR))
12352 : 0 : return true;
12353 : : }
12354 : : }
12355 : : break;
12356 : : }
12357 : : default:;
12358 : : }
12359 : : break;
12360 : : }
12361 : 2255 : case TRUNC_MOD_EXPR:
12362 : 2255 : {
12363 : 2255 : tree _q20 = gimple_assign_rhs1 (_a1);
12364 : 2255 : _q20 = do_valueize (valueize, _q20);
12365 : 2255 : tree _q21 = gimple_assign_rhs2 (_a1);
12366 : 2255 : _q21 = do_valueize (valueize, _q21);
12367 : 2255 : if ((_p1 == _q21 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q21, 0) && types_match (_p1, _q21)))
12368 : : {
12369 : 0 : {
12370 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
12371 : 0 : if (gimple_simplify_337 (res_op, seq, valueize, type, captures, GE_EXPR))
12372 : 0 : return true;
12373 : : }
12374 : : }
12375 : : break;
12376 : : }
12377 : 23346 : case MULT_EXPR:
12378 : 23346 : {
12379 : 23346 : tree _q20 = gimple_assign_rhs1 (_a1);
12380 : 23346 : _q20 = do_valueize (valueize, _q20);
12381 : 23346 : tree _q21 = gimple_assign_rhs2 (_a1);
12382 : 23346 : _q21 = do_valueize (valueize, _q21);
12383 : 23346 : if (tree_swap_operands_p (_q20, _q21))
12384 : 711 : std::swap (_q20, _q21);
12385 : 23346 : switch (TREE_CODE (_p1))
12386 : : {
12387 : 14090 : case SSA_NAME:
12388 : 14090 : if (gimple *_d2 = get_def (valueize, _p1))
12389 : : {
12390 : 13811 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
12391 : 13629 : switch (gimple_assign_rhs_code (_a2))
12392 : : {
12393 : 6655 : case MULT_EXPR:
12394 : 6655 : {
12395 : 6655 : tree _q50 = gimple_assign_rhs1 (_a2);
12396 : 6655 : _q50 = do_valueize (valueize, _q50);
12397 : 6655 : tree _q51 = gimple_assign_rhs2 (_a2);
12398 : 6655 : _q51 = do_valueize (valueize, _q51);
12399 : 6655 : if (tree_swap_operands_p (_q50, _q51))
12400 : 134 : std::swap (_q50, _q51);
12401 : 6655 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
12402 : : {
12403 : 107 : {
12404 : 107 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _q50 };
12405 : 107 : if (gimple_simplify_338 (res_op, seq, valueize, type, captures, GE_EXPR))
12406 : 0 : return true;
12407 : : }
12408 : : }
12409 : 6655 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
12410 : : {
12411 : 0 : {
12412 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _q51 };
12413 : 0 : if (gimple_simplify_338 (res_op, seq, valueize, type, captures, GE_EXPR))
12414 : 0 : return true;
12415 : : }
12416 : : }
12417 : 6655 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
12418 : : {
12419 : 0 : {
12420 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q21, _q20, _q50 };
12421 : 0 : if (gimple_simplify_338 (res_op, seq, valueize, type, captures, GE_EXPR))
12422 : 0 : return true;
12423 : : }
12424 : : }
12425 : 6655 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
12426 : : {
12427 : 2 : {
12428 : 2 : tree captures[3] ATTRIBUTE_UNUSED = { _q21, _q20, _q51 };
12429 : 2 : if (gimple_simplify_338 (res_op, seq, valueize, type, captures, GE_EXPR))
12430 : 0 : return true;
12431 : : }
12432 : : }
12433 : 8107546 : break;
12434 : : }
12435 : : default:;
12436 : : }
12437 : : }
12438 : : break;
12439 : : default:;
12440 : : }
12441 : 8107546 : break;
12442 : : }
12443 : 225435 : CASE_CONVERT:
12444 : 225435 : {
12445 : 225435 : tree _q20 = gimple_assign_rhs1 (_a1);
12446 : 225435 : _q20 = do_valueize (valueize, _q20);
12447 : 225435 : switch (TREE_CODE (_q20))
12448 : : {
12449 : 224443 : case SSA_NAME:
12450 : 224443 : if (gimple *_d2 = get_def (valueize, _q20))
12451 : : {
12452 : 216610 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
12453 : 225623 : switch (gimple_assign_rhs_code (_a2))
12454 : : {
12455 : 2166 : case EXACT_DIV_EXPR:
12456 : 2166 : {
12457 : 2166 : tree _q30 = gimple_assign_rhs1 (_a2);
12458 : 2166 : _q30 = do_valueize (valueize, _q30);
12459 : 2166 : tree _q31 = gimple_assign_rhs2 (_a2);
12460 : 2166 : _q31 = do_valueize (valueize, _q31);
12461 : 2166 : switch (TREE_CODE (_q31))
12462 : : {
12463 : 2166 : case INTEGER_CST:
12464 : 2166 : {
12465 : 2166 : switch (TREE_CODE (_p1))
12466 : : {
12467 : 1976 : case SSA_NAME:
12468 : 1976 : if (gimple *_d3 = get_def (valueize, _p1))
12469 : : {
12470 : 1772 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
12471 : 899 : switch (gimple_assign_rhs_code (_a3))
12472 : : {
12473 : 196 : CASE_CONVERT:
12474 : 196 : {
12475 : 196 : tree _q60 = gimple_assign_rhs1 (_a3);
12476 : 196 : _q60 = do_valueize (valueize, _q60);
12477 : 196 : switch (TREE_CODE (_q60))
12478 : : {
12479 : 196 : case SSA_NAME:
12480 : 196 : if (gimple *_d4 = get_def (valueize, _q60))
12481 : : {
12482 : 196 : if (gassign *_a4 = dyn_cast <gassign *> (_d4))
12483 : 144 : switch (gimple_assign_rhs_code (_a4))
12484 : : {
12485 : 140 : case EXACT_DIV_EXPR:
12486 : 140 : {
12487 : 140 : tree _q70 = gimple_assign_rhs1 (_a4);
12488 : 140 : _q70 = do_valueize (valueize, _q70);
12489 : 140 : tree _q71 = gimple_assign_rhs2 (_a4);
12490 : 140 : _q71 = do_valueize (valueize, _q71);
12491 : 140 : if ((_q71 == _q31 && ! TREE_SIDE_EFFECTS (_q71)) || (operand_equal_p (_q71, _q31, 0) && types_match (_q71, _q31)))
12492 : : {
12493 : 124 : {
12494 : 124 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q30, _q31, _q70 };
12495 : 124 : if (gimple_simplify_209 (res_op, seq, valueize, type, captures, GE_EXPR))
12496 : 39 : return true;
12497 : : }
12498 : : }
12499 : : break;
12500 : : }
12501 : : default:;
12502 : : }
12503 : : }
12504 : : break;
12505 : : default:;
12506 : : }
12507 : : break;
12508 : : }
12509 : : default:;
12510 : : }
12511 : : }
12512 : : break;
12513 : : default:;
12514 : : }
12515 : : break;
12516 : : }
12517 : : default:;
12518 : : }
12519 : : break;
12520 : : }
12521 : : default:;
12522 : : }
12523 : : }
12524 : : break;
12525 : : default:;
12526 : : }
12527 : : break;
12528 : : }
12529 : 3068 : case EXACT_DIV_EXPR:
12530 : 3068 : {
12531 : 3068 : tree _q20 = gimple_assign_rhs1 (_a1);
12532 : 3068 : _q20 = do_valueize (valueize, _q20);
12533 : 3068 : tree _q21 = gimple_assign_rhs2 (_a1);
12534 : 3068 : _q21 = do_valueize (valueize, _q21);
12535 : 3068 : switch (TREE_CODE (_q21))
12536 : : {
12537 : 3068 : case INTEGER_CST:
12538 : 3068 : {
12539 : 3068 : switch (TREE_CODE (_p1))
12540 : : {
12541 : 2227 : case SSA_NAME:
12542 : 2227 : if (gimple *_d2 = get_def (valueize, _p1))
12543 : : {
12544 : 1931 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
12545 : 802 : switch (gimple_assign_rhs_code (_a2))
12546 : : {
12547 : 9 : case EXACT_DIV_EXPR:
12548 : 9 : {
12549 : 9 : tree _q50 = gimple_assign_rhs1 (_a2);
12550 : 9 : _q50 = do_valueize (valueize, _q50);
12551 : 9 : tree _q51 = gimple_assign_rhs2 (_a2);
12552 : 9 : _q51 = do_valueize (valueize, _q51);
12553 : 9 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
12554 : : {
12555 : 9 : {
12556 : 9 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q50 };
12557 : 9 : if (gimple_simplify_209 (res_op, seq, valueize, type, captures, GE_EXPR))
12558 : 9 : return true;
12559 : : }
12560 : : }
12561 : : break;
12562 : : }
12563 : : default:;
12564 : : }
12565 : : }
12566 : : break;
12567 : : default:;
12568 : : }
12569 : : break;
12570 : : }
12571 : : default:;
12572 : : }
12573 : : break;
12574 : : }
12575 : 5305 : case TRUNC_DIV_EXPR:
12576 : 5305 : {
12577 : 5305 : tree _q20 = gimple_assign_rhs1 (_a1);
12578 : 5305 : _q20 = do_valueize (valueize, _q20);
12579 : 5305 : tree _q21 = gimple_assign_rhs2 (_a1);
12580 : 5305 : _q21 = do_valueize (valueize, _q21);
12581 : 5305 : switch (TREE_CODE (_q21))
12582 : : {
12583 : 4082 : case INTEGER_CST:
12584 : 4082 : {
12585 : 4082 : switch (TREE_CODE (_p1))
12586 : : {
12587 : 2942 : case INTEGER_CST:
12588 : 2942 : {
12589 : 2942 : {
12590 : 2942 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1 };
12591 : 2942 : if (gimple_simplify_212 (res_op, seq, valueize, type, captures, GE_EXPR))
12592 : 2942 : return true;
12593 : : }
12594 : 0 : break;
12595 : : }
12596 : : default:;
12597 : : }
12598 : : break;
12599 : : }
12600 : : default:;
12601 : : }
12602 : : break;
12603 : : }
12604 : 429654 : case PLUS_EXPR:
12605 : 429654 : {
12606 : 429654 : tree _q20 = gimple_assign_rhs1 (_a1);
12607 : 429654 : _q20 = do_valueize (valueize, _q20);
12608 : 429654 : tree _q21 = gimple_assign_rhs2 (_a1);
12609 : 429654 : _q21 = do_valueize (valueize, _q21);
12610 : 429654 : if (tree_swap_operands_p (_q20, _q21))
12611 : 26268 : std::swap (_q20, _q21);
12612 : 429654 : switch (TREE_CODE (_p1))
12613 : : {
12614 : 232492 : case SSA_NAME:
12615 : 232492 : if (gimple *_d2 = get_def (valueize, _p1))
12616 : : {
12617 : 228692 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
12618 : 203796 : switch (gimple_assign_rhs_code (_a2))
12619 : : {
12620 : 174748 : case PLUS_EXPR:
12621 : 174748 : {
12622 : 174748 : tree _q50 = gimple_assign_rhs1 (_a2);
12623 : 174748 : _q50 = do_valueize (valueize, _q50);
12624 : 174748 : tree _q51 = gimple_assign_rhs2 (_a2);
12625 : 174748 : _q51 = do_valueize (valueize, _q51);
12626 : 174748 : if (tree_swap_operands_p (_q50, _q51))
12627 : 21728 : std::swap (_q50, _q51);
12628 : 174748 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
12629 : : {
12630 : 1556 : {
12631 : 1556 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _q50 };
12632 : 1556 : if (gimple_simplify_339 (res_op, seq, valueize, type, captures, GE_EXPR))
12633 : 16 : return true;
12634 : : }
12635 : : }
12636 : 174732 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
12637 : : {
12638 : 167 : {
12639 : 167 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _q51 };
12640 : 167 : if (gimple_simplify_339 (res_op, seq, valueize, type, captures, GE_EXPR))
12641 : 67 : return true;
12642 : : }
12643 : : }
12644 : 174665 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
12645 : : {
12646 : 55 : {
12647 : 55 : tree captures[3] ATTRIBUTE_UNUSED = { _q21, _q20, _q50 };
12648 : 55 : if (gimple_simplify_339 (res_op, seq, valueize, type, captures, GE_EXPR))
12649 : 5 : return true;
12650 : : }
12651 : : }
12652 : 174660 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
12653 : : {
12654 : 1331 : {
12655 : 1331 : tree captures[3] ATTRIBUTE_UNUSED = { _q21, _q20, _q51 };
12656 : 1331 : if (gimple_simplify_339 (res_op, seq, valueize, type, captures, GE_EXPR))
12657 : 721 : return true;
12658 : : }
12659 : : }
12660 : 428845 : break;
12661 : : }
12662 : : default:;
12663 : : }
12664 : : }
12665 : : break;
12666 : 428845 : default:;
12667 : : }
12668 : 428845 : switch (TREE_CODE (_q21))
12669 : : {
12670 : 225280 : case INTEGER_CST:
12671 : 225280 : {
12672 : 225280 : switch (TREE_CODE (_p1))
12673 : : {
12674 : 74320 : case SSA_NAME:
12675 : 74320 : if (gimple *_d2 = get_def (valueize, _p1))
12676 : : {
12677 : 71437 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
12678 : 48565 : switch (gimple_assign_rhs_code (_a2))
12679 : : {
12680 : 30567 : case PLUS_EXPR:
12681 : 30567 : {
12682 : 30567 : tree _q50 = gimple_assign_rhs1 (_a2);
12683 : 30567 : _q50 = do_valueize (valueize, _q50);
12684 : 30567 : tree _q51 = gimple_assign_rhs2 (_a2);
12685 : 30567 : _q51 = do_valueize (valueize, _q51);
12686 : 30567 : if (tree_swap_operands_p (_q50, _q51))
12687 : 148 : std::swap (_q50, _q51);
12688 : 30567 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
12689 : : {
12690 : 1513 : {
12691 : 1513 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _q50 };
12692 : 1513 : if (gimple_simplify_340 (res_op, seq, valueize, type, captures, GE_EXPR))
12693 : 0 : return true;
12694 : : }
12695 : : }
12696 : 428845 : break;
12697 : : }
12698 : : default:;
12699 : : }
12700 : : }
12701 : : break;
12702 : : default:;
12703 : : }
12704 : : break;
12705 : : }
12706 : 428845 : default:;
12707 : : }
12708 : 428845 : if ((_p1 == _q21 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q21, 0) && types_match (_p1, _q21)))
12709 : : {
12710 : 3610 : {
12711 : 3610 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q21 };
12712 : 3610 : if (gimple_simplify_341 (res_op, seq, valueize, type, captures, GE_EXPR))
12713 : 139 : return true;
12714 : : }
12715 : : }
12716 : 428706 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
12717 : : {
12718 : 3319 : {
12719 : 3319 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q21, _q20 };
12720 : 3319 : if (gimple_simplify_341 (res_op, seq, valueize, type, captures, GE_EXPR))
12721 : 42 : return true;
12722 : : }
12723 : : }
12724 : 8107546 : break;
12725 : : }
12726 : 127558 : case MINUS_EXPR:
12727 : 127558 : {
12728 : 127558 : tree _q20 = gimple_assign_rhs1 (_a1);
12729 : 127558 : _q20 = do_valueize (valueize, _q20);
12730 : 127558 : tree _q21 = gimple_assign_rhs2 (_a1);
12731 : 127558 : _q21 = do_valueize (valueize, _q21);
12732 : 127558 : switch (TREE_CODE (_p1))
12733 : : {
12734 : 29627 : case SSA_NAME:
12735 : 29627 : if (gimple *_d2 = get_def (valueize, _p1))
12736 : : {
12737 : 27784 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
12738 : 25206 : switch (gimple_assign_rhs_code (_a2))
12739 : : {
12740 : 14530 : case MINUS_EXPR:
12741 : 14530 : {
12742 : 14530 : tree _q50 = gimple_assign_rhs1 (_a2);
12743 : 14530 : _q50 = do_valueize (valueize, _q50);
12744 : 14530 : tree _q51 = gimple_assign_rhs2 (_a2);
12745 : 14530 : _q51 = do_valueize (valueize, _q51);
12746 : 14530 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
12747 : : {
12748 : 72 : {
12749 : 72 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _q50 };
12750 : 72 : if (gimple_simplify_342 (res_op, seq, valueize, type, captures, GE_EXPR))
12751 : 0 : return true;
12752 : : }
12753 : : }
12754 : 14530 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
12755 : : {
12756 : 180 : {
12757 : 180 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _q51 };
12758 : 180 : if (gimple_simplify_343 (res_op, seq, valueize, type, captures, GE_EXPR))
12759 : 24 : return true;
12760 : : }
12761 : : }
12762 : : break;
12763 : : }
12764 : : default:;
12765 : : }
12766 : : }
12767 : : break;
12768 : : default:;
12769 : : }
12770 : : break;
12771 : : }
12772 : 2783 : case POINTER_DIFF_EXPR:
12773 : 2783 : {
12774 : 2783 : tree _q20 = gimple_assign_rhs1 (_a1);
12775 : 2783 : _q20 = do_valueize (valueize, _q20);
12776 : 2783 : tree _q21 = gimple_assign_rhs2 (_a1);
12777 : 2783 : _q21 = do_valueize (valueize, _q21);
12778 : 2783 : switch (TREE_CODE (_p1))
12779 : : {
12780 : 1886 : case SSA_NAME:
12781 : 1886 : if (gimple *_d2 = get_def (valueize, _p1))
12782 : : {
12783 : 1613 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
12784 : 549 : switch (gimple_assign_rhs_code (_a2))
12785 : : {
12786 : 36 : case POINTER_DIFF_EXPR:
12787 : 36 : {
12788 : 36 : tree _q50 = gimple_assign_rhs1 (_a2);
12789 : 36 : _q50 = do_valueize (valueize, _q50);
12790 : 36 : tree _q51 = gimple_assign_rhs2 (_a2);
12791 : 36 : _q51 = do_valueize (valueize, _q51);
12792 : 36 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
12793 : : {
12794 : 0 : {
12795 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q50 };
12796 : 0 : if (gimple_simplify_216 (res_op, seq, valueize, type, captures, GE_EXPR))
12797 : 0 : return true;
12798 : : }
12799 : : }
12800 : 36 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
12801 : : {
12802 : 0 : {
12803 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q51 };
12804 : 0 : if (gimple_simplify_217 (res_op, seq, valueize, type, captures, GE_EXPR))
12805 : 0 : return true;
12806 : : }
12807 : : }
12808 : : break;
12809 : : }
12810 : : default:;
12811 : : }
12812 : : }
12813 : : break;
12814 : : default:;
12815 : : }
12816 : : break;
12817 : : }
12818 : : default:;
12819 : : }
12820 : : }
12821 : : break;
12822 : 8107546 : default:;
12823 : : }
12824 : 8107546 : switch (TREE_CODE (_p1))
12825 : : {
12826 : 2966818 : case SSA_NAME:
12827 : 2966818 : if (gimple *_d1 = get_def (valueize, _p1))
12828 : : {
12829 : 1037606 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
12830 : 1140118 : switch (gimple_assign_rhs_code (_a1))
12831 : : {
12832 : 293276 : case PLUS_EXPR:
12833 : 293276 : {
12834 : 293276 : tree _q30 = gimple_assign_rhs1 (_a1);
12835 : 293276 : _q30 = do_valueize (valueize, _q30);
12836 : 293276 : tree _q31 = gimple_assign_rhs2 (_a1);
12837 : 293276 : _q31 = do_valueize (valueize, _q31);
12838 : 293276 : if (tree_swap_operands_p (_q30, _q31))
12839 : 24808 : std::swap (_q30, _q31);
12840 : 293276 : if ((_q31 == _p0 && ! TREE_SIDE_EFFECTS (_q31)) || (operand_equal_p (_q31, _p0, 0) && types_match (_q31, _p0)))
12841 : : {
12842 : 140628 : {
12843 : 140628 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _q30, _p0 };
12844 : 140628 : if (gimple_simplify_341 (res_op, seq, valueize, type, captures, LE_EXPR))
12845 : 1395 : return true;
12846 : : }
12847 : : }
12848 : 291881 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || (operand_equal_p (_q30, _p0, 0) && types_match (_q30, _p0)))
12849 : : {
12850 : 6447 : {
12851 : 6447 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _q31, _p0 };
12852 : 6447 : if (gimple_simplify_341 (res_op, seq, valueize, type, captures, LE_EXPR))
12853 : 442 : return true;
12854 : : }
12855 : : }
12856 : 8105709 : break;
12857 : : }
12858 : 35728 : case MINUS_EXPR:
12859 : 35728 : {
12860 : 35728 : tree _q30 = gimple_assign_rhs1 (_a1);
12861 : 35728 : _q30 = do_valueize (valueize, _q30);
12862 : 35728 : tree _q31 = gimple_assign_rhs2 (_a1);
12863 : 35728 : _q31 = do_valueize (valueize, _q31);
12864 : 35728 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || (operand_equal_p (_q30, _p0, 0) && types_match (_q30, _p0)))
12865 : : {
12866 : 6985 : {
12867 : 6985 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p1, _q31 };
12868 : 6985 : if (gimple_simplify_215 (res_op, seq, valueize, type, captures, GE_EXPR))
12869 : 0 : return true;
12870 : : }
12871 : : }
12872 : : break;
12873 : : }
12874 : : default:;
12875 : : }
12876 : : }
12877 : : break;
12878 : 8105709 : default:;
12879 : : }
12880 : 8105709 : switch (TREE_CODE (_p0))
12881 : : {
12882 : 7854857 : case SSA_NAME:
12883 : 7854857 : if (gimple *_d1 = get_def (valueize, _p0))
12884 : : {
12885 : 2368843 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
12886 : 2221177 : switch (gimple_assign_rhs_code (_a1))
12887 : : {
12888 : 127534 : case MINUS_EXPR:
12889 : 127534 : {
12890 : 127534 : tree _q20 = gimple_assign_rhs1 (_a1);
12891 : 127534 : _q20 = do_valueize (valueize, _q20);
12892 : 127534 : tree _q21 = gimple_assign_rhs2 (_a1);
12893 : 127534 : _q21 = do_valueize (valueize, _q21);
12894 : 127534 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
12895 : : {
12896 : 86 : {
12897 : 86 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _p0, _q21 };
12898 : 86 : if (gimple_simplify_215 (res_op, seq, valueize, type, captures, LE_EXPR))
12899 : 4 : return true;
12900 : : }
12901 : : }
12902 : : break;
12903 : : }
12904 : 2883 : case BIT_IOR_EXPR:
12905 : 2883 : {
12906 : 2883 : tree _q20 = gimple_assign_rhs1 (_a1);
12907 : 2883 : _q20 = do_valueize (valueize, _q20);
12908 : 2883 : tree _q21 = gimple_assign_rhs2 (_a1);
12909 : 2883 : _q21 = do_valueize (valueize, _q21);
12910 : 2883 : if (tree_swap_operands_p (_q20, _q21))
12911 : 286 : std::swap (_q20, _q21);
12912 : 2883 : if (tree_expr_nonnegative_p (_q20))
12913 : : {
12914 : 417 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
12915 : : {
12916 : 1 : {
12917 : 1 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
12918 : 1 : if (gimple_simplify_344 (res_op, seq, valueize, type, captures, GE_EXPR, BIT_IOR_EXPR))
12919 : 1 : return true;
12920 : : }
12921 : : }
12922 : : }
12923 : 2882 : if (tree_expr_nonnegative_p (_q21))
12924 : : {
12925 : 853 : if ((_p1 == _q21 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q21, 0) && types_match (_p1, _q21)))
12926 : : {
12927 : 25 : {
12928 : 25 : tree captures[2] ATTRIBUTE_UNUSED = { _q21, _q20 };
12929 : 25 : if (gimple_simplify_344 (res_op, seq, valueize, type, captures, GE_EXPR, BIT_IOR_EXPR))
12930 : 1 : return true;
12931 : : }
12932 : : }
12933 : : }
12934 : 8105703 : break;
12935 : : }
12936 : : default:;
12937 : : }
12938 : : }
12939 : : break;
12940 : 8105703 : default:;
12941 : : }
12942 : 8105703 : switch (TREE_CODE (_p1))
12943 : : {
12944 : 2964979 : case SSA_NAME:
12945 : 2964979 : if (gimple *_d1 = get_def (valueize, _p1))
12946 : : {
12947 : 1035767 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
12948 : 1138281 : switch (gimple_assign_rhs_code (_a1))
12949 : : {
12950 : 1657 : case BIT_AND_EXPR:
12951 : 1657 : {
12952 : 1657 : tree _q30 = gimple_assign_rhs1 (_a1);
12953 : 1657 : _q30 = do_valueize (valueize, _q30);
12954 : 1657 : tree _q31 = gimple_assign_rhs2 (_a1);
12955 : 1657 : _q31 = do_valueize (valueize, _q31);
12956 : 1657 : if (tree_swap_operands_p (_q30, _q31))
12957 : 31 : std::swap (_q30, _q31);
12958 : 1657 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || (operand_equal_p (_q30, _p0, 0) && types_match (_q30, _p0)))
12959 : : {
12960 : 17 : if (tree_expr_nonnegative_p (_q30))
12961 : : {
12962 : 2 : {
12963 : 2 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q31 };
12964 : 2 : if (gimple_simplify_344 (res_op, seq, valueize, type, captures, LE_EXPR, BIT_AND_EXPR))
12965 : 2 : return true;
12966 : : }
12967 : : }
12968 : : }
12969 : 1655 : if ((_q31 == _p0 && ! TREE_SIDE_EFFECTS (_q31)) || (operand_equal_p (_q31, _p0, 0) && types_match (_q31, _p0)))
12970 : : {
12971 : 1 : if (tree_expr_nonnegative_p (_q31))
12972 : : {
12973 : 1 : {
12974 : 1 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q30 };
12975 : 1 : if (gimple_simplify_344 (res_op, seq, valueize, type, captures, LE_EXPR, BIT_AND_EXPR))
12976 : 1 : return true;
12977 : : }
12978 : : }
12979 : : }
12980 : 8105700 : break;
12981 : : }
12982 : : default:;
12983 : : }
12984 : : }
12985 : : break;
12986 : 8105700 : default:;
12987 : : }
12988 : 8105700 : switch (TREE_CODE (_p0))
12989 : : {
12990 : 7854848 : case SSA_NAME:
12991 : 7854848 : if (gimple *_d1 = get_def (valueize, _p0))
12992 : : {
12993 : 2368834 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
12994 : 2221169 : switch (gimple_assign_rhs_code (_a1))
12995 : : {
12996 : 26439 : case MIN_EXPR:
12997 : 26439 : {
12998 : 26439 : tree _q20 = gimple_assign_rhs1 (_a1);
12999 : 26439 : _q20 = do_valueize (valueize, _q20);
13000 : 26439 : tree _q21 = gimple_assign_rhs2 (_a1);
13001 : 26439 : _q21 = do_valueize (valueize, _q21);
13002 : 26439 : if (tree_swap_operands_p (_q20, _q21))
13003 : 1132 : std::swap (_q20, _q21);
13004 : 26439 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
13005 : : {
13006 : 60 : {
13007 : 60 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
13008 : 60 : if (gimple_simplify_225 (res_op, seq, valueize, type, captures, MIN_EXPR, GE_EXPR, LE_EXPR))
13009 : 60 : return true;
13010 : : }
13011 : : }
13012 : 26379 : if ((_p1 == _q21 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q21, 0) && types_match (_p1, _q21)))
13013 : : {
13014 : 30 : {
13015 : 30 : tree captures[2] ATTRIBUTE_UNUSED = { _q21, _q20 };
13016 : 30 : if (gimple_simplify_225 (res_op, seq, valueize, type, captures, MIN_EXPR, GE_EXPR, LE_EXPR))
13017 : 30 : return true;
13018 : : }
13019 : : }
13020 : 26349 : switch (TREE_CODE (_q21))
13021 : : {
13022 : 19526 : case INTEGER_CST:
13023 : 19526 : {
13024 : 19526 : switch (TREE_CODE (_p1))
13025 : : {
13026 : 10124 : case INTEGER_CST:
13027 : 10124 : {
13028 : 10124 : {
13029 : 10124 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
13030 : 10124 : if (gimple_simplify_345 (res_op, seq, valueize, type, captures, MIN_EXPR, GE_EXPR, BIT_AND_EXPR))
13031 : 71 : return true;
13032 : : }
13033 : 10053 : break;
13034 : : }
13035 : : default:;
13036 : : }
13037 : : break;
13038 : : }
13039 : : default:;
13040 : : }
13041 : 8105539 : break;
13042 : : }
13043 : : default:;
13044 : : }
13045 : : }
13046 : : break;
13047 : 8105539 : default:;
13048 : : }
13049 : 8105539 : switch (TREE_CODE (_p1))
13050 : : {
13051 : 2964886 : case SSA_NAME:
13052 : 2964886 : if (gimple *_d1 = get_def (valueize, _p1))
13053 : : {
13054 : 1035674 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
13055 : 1138098 : switch (gimple_assign_rhs_code (_a1))
13056 : : {
13057 : 2495 : case MAX_EXPR:
13058 : 2495 : {
13059 : 2495 : tree _q30 = gimple_assign_rhs1 (_a1);
13060 : 2495 : _q30 = do_valueize (valueize, _q30);
13061 : 2495 : tree _q31 = gimple_assign_rhs2 (_a1);
13062 : 2495 : _q31 = do_valueize (valueize, _q31);
13063 : 2495 : if (tree_swap_operands_p (_q30, _q31))
13064 : 31 : std::swap (_q30, _q31);
13065 : 2495 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || (operand_equal_p (_q30, _p0, 0) && types_match (_q30, _p0)))
13066 : : {
13067 : 2 : {
13068 : 2 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q31 };
13069 : 2 : if (gimple_simplify_225 (res_op, seq, valueize, type, captures, MAX_EXPR, LE_EXPR, GE_EXPR))
13070 : 2 : return true;
13071 : : }
13072 : : }
13073 : 2493 : if ((_q31 == _p0 && ! TREE_SIDE_EFFECTS (_q31)) || (operand_equal_p (_q31, _p0, 0) && types_match (_q31, _p0)))
13074 : : {
13075 : 14 : {
13076 : 14 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q30 };
13077 : 14 : if (gimple_simplify_225 (res_op, seq, valueize, type, captures, MAX_EXPR, LE_EXPR, GE_EXPR))
13078 : 14 : return true;
13079 : : }
13080 : : }
13081 : 8105389 : break;
13082 : : }
13083 : 3847 : case MIN_EXPR:
13084 : 3847 : {
13085 : 3847 : tree _q30 = gimple_assign_rhs1 (_a1);
13086 : 3847 : _q30 = do_valueize (valueize, _q30);
13087 : 3847 : tree _q31 = gimple_assign_rhs2 (_a1);
13088 : 3847 : _q31 = do_valueize (valueize, _q31);
13089 : 3847 : if (tree_swap_operands_p (_q30, _q31))
13090 : 164 : std::swap (_q30, _q31);
13091 : 3847 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || (operand_equal_p (_q30, _p0, 0) && types_match (_q30, _p0)))
13092 : : {
13093 : 59 : {
13094 : 59 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q31 };
13095 : 59 : if (gimple_simplify_346 (res_op, seq, valueize, type, captures, MIN_EXPR, GE_EXPR))
13096 : 59 : return true;
13097 : : }
13098 : : }
13099 : 3788 : if ((_q31 == _p0 && ! TREE_SIDE_EFFECTS (_q31)) || (operand_equal_p (_q31, _p0, 0) && types_match (_q31, _p0)))
13100 : : {
13101 : 75 : {
13102 : 75 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q30 };
13103 : 75 : if (gimple_simplify_346 (res_op, seq, valueize, type, captures, MIN_EXPR, GE_EXPR))
13104 : 75 : return true;
13105 : : }
13106 : : }
13107 : 8105389 : break;
13108 : : }
13109 : : default:;
13110 : : }
13111 : : }
13112 : : break;
13113 : 8105389 : default:;
13114 : : }
13115 : 8105389 : switch (TREE_CODE (_p0))
13116 : : {
13117 : 7854537 : case SSA_NAME:
13118 : 7854537 : if (gimple *_d1 = get_def (valueize, _p0))
13119 : : {
13120 : 2368523 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
13121 : 2220916 : switch (gimple_assign_rhs_code (_a1))
13122 : : {
13123 : 3297 : case MAX_EXPR:
13124 : 3297 : {
13125 : 3297 : tree _q20 = gimple_assign_rhs1 (_a1);
13126 : 3297 : _q20 = do_valueize (valueize, _q20);
13127 : 3297 : tree _q21 = gimple_assign_rhs2 (_a1);
13128 : 3297 : _q21 = do_valueize (valueize, _q21);
13129 : 3297 : if (tree_swap_operands_p (_q20, _q21))
13130 : 40 : std::swap (_q20, _q21);
13131 : 3297 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
13132 : : {
13133 : 1 : {
13134 : 1 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
13135 : 1 : if (gimple_simplify_346 (res_op, seq, valueize, type, captures, MAX_EXPR, LE_EXPR))
13136 : 1 : return true;
13137 : : }
13138 : : }
13139 : 3296 : if ((_p1 == _q21 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q21, 0) && types_match (_p1, _q21)))
13140 : : {
13141 : 46 : {
13142 : 46 : tree captures[2] ATTRIBUTE_UNUSED = { _q21, _q20 };
13143 : 46 : if (gimple_simplify_346 (res_op, seq, valueize, type, captures, MAX_EXPR, LE_EXPR))
13144 : 46 : return true;
13145 : : }
13146 : : }
13147 : 3250 : switch (TREE_CODE (_q21))
13148 : : {
13149 : 2985 : case INTEGER_CST:
13150 : 2985 : {
13151 : 2985 : switch (TREE_CODE (_p1))
13152 : : {
13153 : 1229 : case INTEGER_CST:
13154 : 1229 : {
13155 : 1229 : {
13156 : 1229 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
13157 : 1229 : if (gimple_simplify_345 (res_op, seq, valueize, type, captures, MAX_EXPR, GE_EXPR, BIT_IOR_EXPR))
13158 : 174 : return true;
13159 : : }
13160 : 1055 : break;
13161 : : }
13162 : : default:;
13163 : : }
13164 : : break;
13165 : : }
13166 : : default:;
13167 : : }
13168 : 8105156 : break;
13169 : : }
13170 : 18 : case VEC_COND_EXPR:
13171 : 18 : {
13172 : 18 : tree _q20 = gimple_assign_rhs1 (_a1);
13173 : 18 : _q20 = do_valueize (valueize, _q20);
13174 : 18 : tree _q21 = gimple_assign_rhs2 (_a1);
13175 : 18 : _q21 = do_valueize (valueize, _q21);
13176 : 18 : tree _q22 = gimple_assign_rhs3 (_a1);
13177 : 18 : _q22 = do_valueize (valueize, _q22);
13178 : 18 : switch (TREE_CODE (_p1))
13179 : : {
13180 : 2 : case SSA_NAME:
13181 : 2 : if (gimple *_d2 = get_def (valueize, _p1))
13182 : : {
13183 : 2 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
13184 : 2 : switch (gimple_assign_rhs_code (_a2))
13185 : : {
13186 : 2 : case VEC_COND_EXPR:
13187 : 2 : {
13188 : 2 : tree _q60 = gimple_assign_rhs1 (_a2);
13189 : 2 : _q60 = do_valueize (valueize, _q60);
13190 : 2 : tree _q61 = gimple_assign_rhs2 (_a2);
13191 : 2 : _q61 = do_valueize (valueize, _q61);
13192 : 2 : tree _q62 = gimple_assign_rhs3 (_a2);
13193 : 2 : _q62 = do_valueize (valueize, _q62);
13194 : 2 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
13195 : : {
13196 : 0 : {
13197 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q22, _p1, _q61, _q62 };
13198 : 0 : if (TREE_CODE_CLASS (GE_EXPR) != tcc_comparison
13199 : 0 : || types_match (type, TREE_TYPE (captures[2]))
13200 : 0 : || expand_vec_cond_expr_p (type, TREE_TYPE (captures[1]), ERROR_MARK)
13201 : : || (optimize_vectors_before_lowering_p ()
13202 : 0 : && !expand_vec_cond_expr_p (TREE_TYPE (captures[2]),
13203 : 0 : TREE_TYPE (captures[1]), ERROR_MARK))
13204 : : )
13205 : : {
13206 : 0 : gimple_seq *lseq = seq;
13207 : 0 : if (lseq
13208 : 0 : && (!single_use (captures[0])
13209 : 0 : || !single_use (captures[4])))
13210 : 0 : lseq = NULL;
13211 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1954;
13212 : 0 : {
13213 : 0 : res_op->set_op (VEC_COND_EXPR, type, 3);
13214 : 0 : res_op->ops[0] = captures[1];
13215 : 0 : {
13216 : 0 : tree _o1[2], _r1;
13217 : 0 : _o1[0] = captures[2];
13218 : 0 : _o1[1] = captures[5];
13219 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), GE_EXPR, type, _o1[0], _o1[1]);
13220 : 0 : tem_op.resimplify (NULL, valueize);
13221 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
13222 : 0 : if (!_r1) goto next_after_fail1954;
13223 : 0 : res_op->ops[1] = _r1;
13224 : : }
13225 : 0 : {
13226 : 0 : tree _o1[2], _r1;
13227 : 0 : _o1[0] = captures[3];
13228 : 0 : _o1[1] = captures[6];
13229 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), GE_EXPR, type, _o1[0], _o1[1]);
13230 : 0 : tem_op.resimplify (NULL, valueize);
13231 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
13232 : 0 : if (!_r1) goto next_after_fail1954;
13233 : 0 : res_op->ops[2] = _r1;
13234 : : }
13235 : 0 : res_op->resimplify (lseq, valueize);
13236 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 925, __FILE__, __LINE__, true);
13237 : 0 : return true;
13238 : : }
13239 : 0 : next_after_fail1954:;
13240 : : }
13241 : : }
13242 : : }
13243 : : break;
13244 : : }
13245 : : default:;
13246 : : }
13247 : : }
13248 : : break;
13249 : 18 : default:;
13250 : : }
13251 : 18 : {
13252 : 18 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q22, _p1 };
13253 : 18 : if (TREE_CODE_CLASS (GE_EXPR) != tcc_comparison
13254 : 18 : || types_match (type, TREE_TYPE (captures[2]))
13255 : 18 : || expand_vec_cond_expr_p (type, TREE_TYPE (captures[1]), ERROR_MARK)
13256 : : || (optimize_vectors_before_lowering_p ()
13257 : 11 : && !expand_vec_cond_expr_p (TREE_TYPE (captures[2]),
13258 : 11 : TREE_TYPE (captures[1]), ERROR_MARK))
13259 : : )
13260 : : {
13261 : 14 : gimple_seq *lseq = seq;
13262 : 14 : if (lseq
13263 : 3 : && (!single_use (captures[0])))
13264 : 12 : lseq = NULL;
13265 : 14 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1955;
13266 : 14 : {
13267 : 14 : res_op->set_op (VEC_COND_EXPR, type, 3);
13268 : 14 : res_op->ops[0] = captures[1];
13269 : 14 : {
13270 : 14 : tree _o1[2], _r1;
13271 : 14 : _o1[0] = captures[2];
13272 : 14 : _o1[1] = captures[4];
13273 : 14 : gimple_match_op tem_op (res_op->cond.any_else (), GE_EXPR, type, _o1[0], _o1[1]);
13274 : 14 : tem_op.resimplify (NULL, valueize);
13275 : 14 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
13276 : 14 : if (!_r1) goto next_after_fail1955;
13277 : 14 : res_op->ops[1] = _r1;
13278 : : }
13279 : 14 : {
13280 : 14 : tree _o1[2], _r1;
13281 : 14 : _o1[0] = captures[3];
13282 : 14 : _o1[1] = captures[4];
13283 : 14 : gimple_match_op tem_op (res_op->cond.any_else (), GE_EXPR, type, _o1[0], _o1[1]);
13284 : 14 : tem_op.resimplify (NULL, valueize);
13285 : 14 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
13286 : 14 : if (!_r1) goto next_after_fail1955;
13287 : 12 : res_op->ops[2] = _r1;
13288 : : }
13289 : 12 : res_op->resimplify (lseq, valueize);
13290 : 12 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 926, __FILE__, __LINE__, true);
13291 : 12 : return true;
13292 : : }
13293 : 6 : next_after_fail1955:;
13294 : : }
13295 : : }
13296 : 6 : break;
13297 : : }
13298 : : default:;
13299 : : }
13300 : : }
13301 : : break;
13302 : 8105156 : default:;
13303 : : }
13304 : 8105156 : switch (TREE_CODE (_p1))
13305 : : {
13306 : 2964735 : case SSA_NAME:
13307 : 2964735 : if (gimple *_d1 = get_def (valueize, _p1))
13308 : : {
13309 : 1035523 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
13310 : 1137948 : switch (gimple_assign_rhs_code (_a1))
13311 : : {
13312 : 2 : case VEC_COND_EXPR:
13313 : 2 : {
13314 : 2 : tree _q30 = gimple_assign_rhs1 (_a1);
13315 : 2 : _q30 = do_valueize (valueize, _q30);
13316 : 2 : tree _q31 = gimple_assign_rhs2 (_a1);
13317 : 2 : _q31 = do_valueize (valueize, _q31);
13318 : 2 : tree _q32 = gimple_assign_rhs3 (_a1);
13319 : 2 : _q32 = do_valueize (valueize, _q32);
13320 : 2 : {
13321 : 2 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q31, _q32 };
13322 : 2 : if (TREE_CODE_CLASS (GE_EXPR) != tcc_comparison
13323 : 2 : || types_match (type, TREE_TYPE (captures[3]))
13324 : 2 : || expand_vec_cond_expr_p (type, TREE_TYPE (captures[2]), ERROR_MARK)
13325 : : || (optimize_vectors_before_lowering_p ()
13326 : 2 : && !expand_vec_cond_expr_p (TREE_TYPE (captures[3]),
13327 : 2 : TREE_TYPE (captures[2]), ERROR_MARK))
13328 : : )
13329 : : {
13330 : 2 : gimple_seq *lseq = seq;
13331 : 2 : if (lseq
13332 : 1 : && (!single_use (captures[1])))
13333 : 1 : lseq = NULL;
13334 : 2 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail1956;
13335 : 2 : {
13336 : 2 : res_op->set_op (VEC_COND_EXPR, type, 3);
13337 : 2 : res_op->ops[0] = captures[2];
13338 : 2 : {
13339 : 2 : tree _o1[2], _r1;
13340 : 2 : _o1[0] = captures[0];
13341 : 2 : _o1[1] = captures[3];
13342 : 2 : gimple_match_op tem_op (res_op->cond.any_else (), GE_EXPR, type, _o1[0], _o1[1]);
13343 : 2 : tem_op.resimplify (NULL, valueize);
13344 : 2 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
13345 : 2 : if (!_r1) goto next_after_fail1956;
13346 : 2 : res_op->ops[1] = _r1;
13347 : : }
13348 : 2 : {
13349 : 2 : tree _o1[2], _r1;
13350 : 2 : _o1[0] = captures[0];
13351 : 2 : _o1[1] = captures[4];
13352 : 2 : gimple_match_op tem_op (res_op->cond.any_else (), GE_EXPR, type, _o1[0], _o1[1]);
13353 : 2 : tem_op.resimplify (NULL, valueize);
13354 : 2 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
13355 : 2 : if (!_r1) goto next_after_fail1956;
13356 : 2 : res_op->ops[2] = _r1;
13357 : : }
13358 : 2 : res_op->resimplify (lseq, valueize);
13359 : 2 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 927, __FILE__, __LINE__, true);
13360 : 2 : return true;
13361 : : }
13362 : 0 : next_after_fail1956:;
13363 : : }
13364 : : }
13365 : 0 : break;
13366 : : }
13367 : : default:;
13368 : : }
13369 : : }
13370 : : break;
13371 : 8105154 : default:;
13372 : : }
13373 : 8105154 : if (uniform_integer_cst_p (_p1))
13374 : : {
13375 : 4868426 : {
13376 : 4868426 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
13377 : 4868426 : if (gimple_simplify_347 (res_op, seq, valueize, type, captures, GE_EXPR, GT_EXPR))
13378 : 172598 : return true;
13379 : : }
13380 : : }
13381 : 7932556 : switch (TREE_CODE (_p0))
13382 : : {
13383 : 7711348 : case SSA_NAME:
13384 : 7711348 : if (gimple *_d1 = get_def (valueize, _p0))
13385 : : {
13386 : 2266862 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
13387 : 2118561 : switch (gimple_assign_rhs_code (_a1))
13388 : : {
13389 : 23083 : case MULT_EXPR:
13390 : 23083 : {
13391 : 23083 : tree _q20 = gimple_assign_rhs1 (_a1);
13392 : 23083 : _q20 = do_valueize (valueize, _q20);
13393 : 23083 : tree _q21 = gimple_assign_rhs2 (_a1);
13394 : 23083 : _q21 = do_valueize (valueize, _q21);
13395 : 23083 : if (tree_swap_operands_p (_q20, _q21))
13396 : 660 : std::swap (_q20, _q21);
13397 : 23083 : switch (TREE_CODE (_q21))
13398 : : {
13399 : 14727 : case INTEGER_CST:
13400 : 14727 : {
13401 : 14727 : if (integer_zerop (_p1))
13402 : : {
13403 : 5671 : {
13404 : 5671 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1 };
13405 : 5671 : if (gimple_simplify_245 (res_op, seq, valueize, type, captures, GE_EXPR, LE_EXPR))
13406 : 26 : return true;
13407 : : }
13408 : : }
13409 : : break;
13410 : : }
13411 : : default:;
13412 : : }
13413 : 7932530 : break;
13414 : : }
13415 : : default:;
13416 : : }
13417 : : }
13418 : : break;
13419 : 7932530 : default:;
13420 : : }
13421 : 7932530 : if ((_p1 == _p0 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _p0, 0) && types_match (_p1, _p0)))
13422 : : {
13423 : 4015 : {
13424 : 4015 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
13425 : 4015 : if (gimple_simplify_247 (res_op, seq, valueize, type, captures, GE_EXPR))
13426 : 3430 : return true;
13427 : : }
13428 : : }
13429 : 7929100 : switch (TREE_CODE (_p0))
13430 : : {
13431 : 7707916 : case SSA_NAME:
13432 : 7707916 : if (gimple *_d1 = get_def (valueize, _p0))
13433 : : {
13434 : 2265007 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
13435 : 2117733 : switch (gimple_assign_rhs_code (_a1))
13436 : : {
13437 : 1086 : case BIT_NOT_EXPR:
13438 : 1086 : {
13439 : 1086 : tree _q20 = gimple_assign_rhs1 (_a1);
13440 : 1086 : _q20 = do_valueize (valueize, _q20);
13441 : 1086 : switch (TREE_CODE (_p1))
13442 : : {
13443 : 744 : case SSA_NAME:
13444 : 744 : if (gimple *_d2 = get_def (valueize, _p1))
13445 : : {
13446 : 616 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
13447 : 653 : switch (gimple_assign_rhs_code (_a2))
13448 : : {
13449 : 0 : case BIT_NOT_EXPR:
13450 : 0 : {
13451 : 0 : tree _q40 = gimple_assign_rhs1 (_a2);
13452 : 0 : _q40 = do_valueize (valueize, _q40);
13453 : 0 : {
13454 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _p0, _q20, _p1, _q40 };
13455 : 0 : if (gimple_simplify_249 (res_op, seq, valueize, type, captures, GE_EXPR))
13456 : 0 : return true;
13457 : : }
13458 : 0 : break;
13459 : : }
13460 : : default:;
13461 : : }
13462 : : }
13463 : : break;
13464 : 1086 : default:;
13465 : : }
13466 : 1086 : {
13467 : 1086 : tree _p1_pops[1];
13468 : 1086 : if (gimple_nop_convert (_p1, _p1_pops, valueize))
13469 : : {
13470 : 108 : tree _q40 = _p1_pops[0];
13471 : 108 : switch (TREE_CODE (_q40))
13472 : : {
13473 : 108 : case SSA_NAME:
13474 : 108 : if (gimple *_d2 = get_def (valueize, _q40))
13475 : : {
13476 : 90 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
13477 : 180 : switch (gimple_assign_rhs_code (_a2))
13478 : : {
13479 : 0 : case BIT_NOT_EXPR:
13480 : 0 : {
13481 : 0 : tree _q50 = gimple_assign_rhs1 (_a2);
13482 : 0 : _q50 = do_valueize (valueize, _q50);
13483 : 0 : {
13484 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _p0, _q20, _q40, _q50 };
13485 : 0 : if (gimple_simplify_249 (res_op, seq, valueize, type, captures, GE_EXPR))
13486 : 0 : return true;
13487 : : }
13488 : 0 : break;
13489 : : }
13490 : : default:;
13491 : : }
13492 : : }
13493 : : break;
13494 : : default:;
13495 : : }
13496 : : }
13497 : : }
13498 : 1086 : if (CONSTANT_CLASS_P (_p1))
13499 : : {
13500 : 342 : {
13501 : 342 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
13502 : 342 : if (gimple_simplify_250 (res_op, seq, valueize, type, captures, GE_EXPR, LE_EXPR))
13503 : 24 : return true;
13504 : : }
13505 : : }
13506 : : break;
13507 : : }
13508 : : default:;
13509 : : }
13510 : : }
13511 : : break;
13512 : 7929076 : default:;
13513 : : }
13514 : 7929076 : {
13515 : 7929076 : tree _p0_pops[1];
13516 : 7929076 : if (gimple_nop_convert (_p0, _p0_pops, valueize))
13517 : : {
13518 : 142000 : tree _q20 = _p0_pops[0];
13519 : 142000 : switch (TREE_CODE (_q20))
13520 : : {
13521 : 141008 : case SSA_NAME:
13522 : 141008 : if (gimple *_d1 = get_def (valueize, _q20))
13523 : : {
13524 : 134891 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
13525 : 150757 : switch (gimple_assign_rhs_code (_a1))
13526 : : {
13527 : 37 : case BIT_NOT_EXPR:
13528 : 37 : {
13529 : 37 : tree _q30 = gimple_assign_rhs1 (_a1);
13530 : 37 : _q30 = do_valueize (valueize, _q30);
13531 : 37 : switch (TREE_CODE (_p1))
13532 : : {
13533 : 0 : case SSA_NAME:
13534 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
13535 : : {
13536 : 0 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
13537 : 0 : switch (gimple_assign_rhs_code (_a2))
13538 : : {
13539 : 0 : case BIT_NOT_EXPR:
13540 : 0 : {
13541 : 0 : tree _q50 = gimple_assign_rhs1 (_a2);
13542 : 0 : _q50 = do_valueize (valueize, _q50);
13543 : 0 : {
13544 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _p1, _q50 };
13545 : 0 : if (gimple_simplify_251 (res_op, seq, valueize, type, captures, GE_EXPR))
13546 : 0 : return true;
13547 : : }
13548 : 0 : break;
13549 : : }
13550 : : default:;
13551 : : }
13552 : : }
13553 : : break;
13554 : 37 : default:;
13555 : : }
13556 : 37 : {
13557 : 37 : tree _p1_pops[1];
13558 : 37 : if (gimple_nop_convert (_p1, _p1_pops, valueize))
13559 : : {
13560 : 0 : tree _q50 = _p1_pops[0];
13561 : 0 : switch (TREE_CODE (_q50))
13562 : : {
13563 : 0 : case SSA_NAME:
13564 : 0 : if (gimple *_d2 = get_def (valueize, _q50))
13565 : : {
13566 : 0 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
13567 : 0 : switch (gimple_assign_rhs_code (_a2))
13568 : : {
13569 : 0 : case BIT_NOT_EXPR:
13570 : 0 : {
13571 : 0 : tree _q60 = gimple_assign_rhs1 (_a2);
13572 : 0 : _q60 = do_valueize (valueize, _q60);
13573 : 0 : {
13574 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q50, _q60 };
13575 : 0 : if (gimple_simplify_251 (res_op, seq, valueize, type, captures, GE_EXPR))
13576 : 0 : return true;
13577 : : }
13578 : 0 : break;
13579 : : }
13580 : : default:;
13581 : : }
13582 : : }
13583 : : break;
13584 : : default:;
13585 : : }
13586 : : }
13587 : : }
13588 : 37 : if (CONSTANT_CLASS_P (_p1))
13589 : : {
13590 : 37 : {
13591 : 37 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q30, _p1 };
13592 : 37 : if (gimple_simplify_250 (res_op, seq, valueize, type, captures, GE_EXPR, LE_EXPR))
13593 : 7 : return true;
13594 : : }
13595 : : }
13596 : : break;
13597 : : }
13598 : : default:;
13599 : : }
13600 : : }
13601 : : break;
13602 : : default:;
13603 : : }
13604 : : }
13605 : : }
13606 : 7929069 : switch (TREE_CODE (_p1))
13607 : : {
13608 : 205034 : case REAL_CST:
13609 : 205034 : {
13610 : 205034 : {
13611 : 205034 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
13612 : 205034 : if (gimple_simplify_252 (res_op, seq, valueize, type, captures, GE_EXPR))
13613 : 40 : return true;
13614 : : }
13615 : 204994 : break;
13616 : : }
13617 : 7929029 : default:;
13618 : : }
13619 : 7929029 : switch (TREE_CODE (_p0))
13620 : : {
13621 : 7707845 : case SSA_NAME:
13622 : 7707845 : if (gimple *_d1 = get_def (valueize, _p0))
13623 : : {
13624 : 2264948 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
13625 : 2117670 : switch (gimple_assign_rhs_code (_a1))
13626 : : {
13627 : 419921 : case PLUS_EXPR:
13628 : 419921 : {
13629 : 419921 : tree _q20 = gimple_assign_rhs1 (_a1);
13630 : 419921 : _q20 = do_valueize (valueize, _q20);
13631 : 419921 : tree _q21 = gimple_assign_rhs2 (_a1);
13632 : 419921 : _q21 = do_valueize (valueize, _q21);
13633 : 419921 : if (tree_swap_operands_p (_q20, _q21))
13634 : 26075 : std::swap (_q20, _q21);
13635 : 419921 : switch (TREE_CODE (_q21))
13636 : : {
13637 : 445 : case REAL_CST:
13638 : 445 : {
13639 : 445 : switch (TREE_CODE (_p1))
13640 : : {
13641 : 131 : case REAL_CST:
13642 : 131 : {
13643 : 131 : {
13644 : 131 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
13645 : 131 : if (gimple_simplify_253 (res_op, seq, valueize, type, captures, PLUS_EXPR, GE_EXPR))
13646 : 0 : return true;
13647 : : }
13648 : 131 : break;
13649 : : }
13650 : : default:;
13651 : : }
13652 : : break;
13653 : : }
13654 : 217994 : case INTEGER_CST:
13655 : 217994 : {
13656 : 217994 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
13657 : : {
13658 : 2719 : {
13659 : 2719 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _p0, _q20, _q20, _q21 };
13660 : 2719 : if (gimple_simplify_348 (res_op, seq, valueize, type, captures, GE_EXPR, LE_EXPR))
13661 : 42 : return true;
13662 : : }
13663 : : }
13664 : : break;
13665 : : }
13666 : : default:;
13667 : : }
13668 : 7926433 : break;
13669 : : }
13670 : 122849 : case MINUS_EXPR:
13671 : 122849 : {
13672 : 122849 : tree _q20 = gimple_assign_rhs1 (_a1);
13673 : 122849 : _q20 = do_valueize (valueize, _q20);
13674 : 122849 : tree _q21 = gimple_assign_rhs2 (_a1);
13675 : 122849 : _q21 = do_valueize (valueize, _q21);
13676 : 122849 : switch (TREE_CODE (_q21))
13677 : : {
13678 : 126 : case REAL_CST:
13679 : 126 : {
13680 : 126 : switch (TREE_CODE (_p1))
13681 : : {
13682 : 126 : case REAL_CST:
13683 : 126 : {
13684 : 126 : {
13685 : 126 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
13686 : 126 : if (gimple_simplify_253 (res_op, seq, valueize, type, captures, MINUS_EXPR, GE_EXPR))
13687 : 0 : return true;
13688 : : }
13689 : 126 : break;
13690 : : }
13691 : : default:;
13692 : : }
13693 : : break;
13694 : : }
13695 : 122849 : default:;
13696 : : }
13697 : 122849 : switch (TREE_CODE (_q20))
13698 : : {
13699 : 0 : case REAL_CST:
13700 : 0 : {
13701 : 0 : switch (TREE_CODE (_p1))
13702 : : {
13703 : 0 : case REAL_CST:
13704 : 0 : {
13705 : 0 : {
13706 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
13707 : 0 : if (gimple_simplify_254 (res_op, seq, valueize, type, captures, GE_EXPR))
13708 : 0 : return true;
13709 : : }
13710 : 0 : break;
13711 : : }
13712 : : default:;
13713 : : }
13714 : : break;
13715 : : }
13716 : : default:;
13717 : : }
13718 : : break;
13719 : : }
13720 : 1737 : case FLOAT_EXPR:
13721 : 1737 : {
13722 : 1737 : tree _q20 = gimple_assign_rhs1 (_a1);
13723 : 1737 : _q20 = do_valueize (valueize, _q20);
13724 : 1737 : switch (TREE_CODE (_p1))
13725 : : {
13726 : 844 : case SSA_NAME:
13727 : 844 : if (gimple *_d2 = get_def (valueize, _p1))
13728 : : {
13729 : 796 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
13730 : 932 : switch (gimple_assign_rhs_code (_a2))
13731 : : {
13732 : 192 : case FLOAT_EXPR:
13733 : 192 : {
13734 : 192 : tree _q40 = gimple_assign_rhs1 (_a2);
13735 : 192 : _q40 = do_valueize (valueize, _q40);
13736 : 192 : {
13737 : 192 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q40 };
13738 : 192 : if (gimple_simplify_257 (res_op, seq, valueize, type, captures, GE_EXPR, GE_EXPR))
13739 : 12 : return true;
13740 : : }
13741 : 180 : break;
13742 : : }
13743 : : default:;
13744 : : }
13745 : : }
13746 : : break;
13747 : 893 : case REAL_CST:
13748 : 893 : {
13749 : 893 : {
13750 : 893 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _p1 };
13751 : 893 : if (gimple_simplify_258 (res_op, seq, valueize, type, captures, GE_EXPR, GE_EXPR))
13752 : 44 : return true;
13753 : : }
13754 : 849 : break;
13755 : : }
13756 : : default:;
13757 : : }
13758 : : break;
13759 : : }
13760 : 2704 : case EXACT_DIV_EXPR:
13761 : 2704 : {
13762 : 2704 : tree _q20 = gimple_assign_rhs1 (_a1);
13763 : 2704 : _q20 = do_valueize (valueize, _q20);
13764 : 2704 : tree _q21 = gimple_assign_rhs2 (_a1);
13765 : 2704 : _q21 = do_valueize (valueize, _q21);
13766 : 2704 : switch (TREE_CODE (_q21))
13767 : : {
13768 : 2704 : case INTEGER_CST:
13769 : 2704 : {
13770 : 2704 : switch (TREE_CODE (_p1))
13771 : : {
13772 : 486 : case INTEGER_CST:
13773 : 486 : {
13774 : 486 : {
13775 : 486 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
13776 : 486 : if (gimple_simplify_349 (res_op, seq, valueize, type, captures, GE_EXPR))
13777 : 486 : return true;
13778 : : }
13779 : 0 : break;
13780 : : }
13781 : : default:;
13782 : : }
13783 : : break;
13784 : : }
13785 : : default:;
13786 : : }
13787 : : break;
13788 : : }
13789 : 222411 : CASE_CONVERT:
13790 : 222411 : {
13791 : 222411 : tree _q20 = gimple_assign_rhs1 (_a1);
13792 : 222411 : _q20 = do_valueize (valueize, _q20);
13793 : 222411 : switch (TREE_CODE (_q20))
13794 : : {
13795 : 221419 : case SSA_NAME:
13796 : 221419 : if (gimple *_d2 = get_def (valueize, _q20))
13797 : : {
13798 : 213622 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
13799 : 222103 : switch (gimple_assign_rhs_code (_a2))
13800 : : {
13801 : 1953 : case EXACT_DIV_EXPR:
13802 : 1953 : {
13803 : 1953 : tree _q30 = gimple_assign_rhs1 (_a2);
13804 : 1953 : _q30 = do_valueize (valueize, _q30);
13805 : 1953 : tree _q31 = gimple_assign_rhs2 (_a2);
13806 : 1953 : _q31 = do_valueize (valueize, _q31);
13807 : 1953 : switch (TREE_CODE (_q31))
13808 : : {
13809 : 1953 : case INTEGER_CST:
13810 : 1953 : {
13811 : 1953 : switch (TREE_CODE (_p1))
13812 : : {
13813 : 16 : case INTEGER_CST:
13814 : 16 : {
13815 : 16 : {
13816 : 16 : tree captures[3] ATTRIBUTE_UNUSED = { _q30, _q31, _p1 };
13817 : 16 : if (gimple_simplify_350 (res_op, seq, valueize, type, captures, GE_EXPR, LT_EXPR))
13818 : 4 : return true;
13819 : : }
13820 : 12 : break;
13821 : : }
13822 : : default:;
13823 : : }
13824 : : break;
13825 : : }
13826 : : default:;
13827 : : }
13828 : : break;
13829 : : }
13830 : : default:;
13831 : : }
13832 : : }
13833 : : break;
13834 : 222407 : default:;
13835 : : }
13836 : 222407 : switch (TREE_CODE (_p1))
13837 : : {
13838 : 125339 : case SSA_NAME:
13839 : 125339 : if (gimple *_d2 = get_def (valueize, _p1))
13840 : : {
13841 : 121018 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
13842 : 110671 : switch (gimple_assign_rhs_code (_a2))
13843 : : {
13844 : 71796 : CASE_CONVERT:
13845 : 71796 : {
13846 : 71796 : tree _q40 = gimple_assign_rhs1 (_a2);
13847 : 71796 : _q40 = do_valueize (valueize, _q40);
13848 : 71796 : {
13849 : 71796 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _p1, _q40 };
13850 : 71796 : if (gimple_simplify_262 (res_op, seq, valueize, type, captures, GE_EXPR))
13851 : 131 : return true;
13852 : : }
13853 : 71665 : break;
13854 : : }
13855 : : default:;
13856 : : }
13857 : : }
13858 : : break;
13859 : 222276 : default:;
13860 : : }
13861 : 222276 : {
13862 : 222276 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _p1, _p1 };
13863 : 222276 : if (gimple_simplify_263 (res_op, seq, valueize, type, captures, GE_EXPR))
13864 : 589 : return true;
13865 : : }
13866 : 221687 : break;
13867 : : }
13868 : 2867 : case NEGATE_EXPR:
13869 : 2867 : {
13870 : 2867 : tree _q20 = gimple_assign_rhs1 (_a1);
13871 : 2867 : _q20 = do_valueize (valueize, _q20);
13872 : 2867 : switch (TREE_CODE (_p1))
13873 : : {
13874 : 1270 : case SSA_NAME:
13875 : 1270 : if (gimple *_d2 = get_def (valueize, _p1))
13876 : : {
13877 : 1230 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
13878 : 1108 : switch (gimple_assign_rhs_code (_a2))
13879 : : {
13880 : 90 : case NEGATE_EXPR:
13881 : 90 : {
13882 : 90 : tree _q40 = gimple_assign_rhs1 (_a2);
13883 : 90 : _q40 = do_valueize (valueize, _q40);
13884 : 90 : {
13885 : 90 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q40 };
13886 : 90 : if (gimple_simplify_260 (res_op, seq, valueize, type, captures, GE_EXPR, LE_EXPR))
13887 : 90 : return true;
13888 : : }
13889 : 0 : break;
13890 : : }
13891 : : default:;
13892 : : }
13893 : : }
13894 : : break;
13895 : 2777 : default:;
13896 : : }
13897 : 2777 : if (CONSTANT_CLASS_P (_p1))
13898 : : {
13899 : 1597 : {
13900 : 1597 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _p1 };
13901 : 1597 : if (gimple_simplify_261 (res_op, seq, valueize, type, captures, GE_EXPR, LE_EXPR))
13902 : 1163 : return true;
13903 : : }
13904 : : }
13905 : : break;
13906 : : }
13907 : 99 : case COND_EXPR:
13908 : 99 : {
13909 : 99 : tree _q20 = gimple_assign_rhs1 (_a1);
13910 : 99 : _q20 = do_valueize (valueize, _q20);
13911 : 99 : tree _q21 = gimple_assign_rhs2 (_a1);
13912 : 99 : _q21 = do_valueize (valueize, _q21);
13913 : 99 : tree _q22 = gimple_assign_rhs3 (_a1);
13914 : 99 : _q22 = do_valueize (valueize, _q22);
13915 : 99 : {
13916 : 99 : tree captures[4] ATTRIBUTE_UNUSED = { _q20, _q21, _q22, _p1 };
13917 : 99 : if (gimple_simplify_278 (res_op, seq, valueize, type, captures, GE_EXPR))
13918 : 11 : return true;
13919 : : }
13920 : 88 : break;
13921 : : }
13922 : : default:;
13923 : : }
13924 : 757936 : else if (gcall *_c1 = dyn_cast <gcall *> (_d1))
13925 : 167821 : switch (gimple_call_combined_fn (_c1))
13926 : : {
13927 : 8 : case CFN_BUILT_IN_SQRTF:
13928 : 8 : if (gimple_call_num_args (_c1) == 1)
13929 : : {
13930 : 8 : tree _q20 = gimple_call_arg (_c1, 0);
13931 : 8 : _q20 = do_valueize (valueize, _q20);
13932 : 8 : switch (TREE_CODE (_p1))
13933 : : {
13934 : 2 : case SSA_NAME:
13935 : 2 : if (gimple *_d2 = get_def (valueize, _p1))
13936 : : {
13937 : 2 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
13938 : 2 : switch (gimple_call_combined_fn (_c2))
13939 : : {
13940 : 2 : case CFN_BUILT_IN_SQRTF:
13941 : 2 : if (gimple_call_num_args (_c2) == 1)
13942 : : {
13943 : 2 : tree _q40 = gimple_call_arg (_c2, 0);
13944 : 2 : _q40 = do_valueize (valueize, _q40);
13945 : 2 : {
13946 : 2 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q40 };
13947 : 2 : if (gimple_simplify_256 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_SQRTF, GE_EXPR))
13948 : 2 : return true;
13949 : : }
13950 : : }
13951 : : break;
13952 : : default:;
13953 : : }
13954 : : }
13955 : : break;
13956 : 6 : case REAL_CST:
13957 : 6 : {
13958 : 6 : {
13959 : 6 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _p1 };
13960 : 6 : if (gimple_simplify_255 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_SQRTF, GE_EXPR))
13961 : 6 : return true;
13962 : : }
13963 : 0 : break;
13964 : : }
13965 : : default:;
13966 : : }
13967 : : }
13968 : : break;
13969 : 8 : case CFN_BUILT_IN_SQRTL:
13970 : 8 : if (gimple_call_num_args (_c1) == 1)
13971 : : {
13972 : 8 : tree _q20 = gimple_call_arg (_c1, 0);
13973 : 8 : _q20 = do_valueize (valueize, _q20);
13974 : 8 : switch (TREE_CODE (_p1))
13975 : : {
13976 : 2 : case SSA_NAME:
13977 : 2 : if (gimple *_d2 = get_def (valueize, _p1))
13978 : : {
13979 : 2 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
13980 : 2 : switch (gimple_call_combined_fn (_c2))
13981 : : {
13982 : 2 : case CFN_BUILT_IN_SQRTL:
13983 : 2 : if (gimple_call_num_args (_c2) == 1)
13984 : : {
13985 : 2 : tree _q40 = gimple_call_arg (_c2, 0);
13986 : 2 : _q40 = do_valueize (valueize, _q40);
13987 : 2 : {
13988 : 2 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q40 };
13989 : 2 : if (gimple_simplify_256 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_SQRTL, GE_EXPR))
13990 : 2 : return true;
13991 : : }
13992 : : }
13993 : : break;
13994 : : default:;
13995 : : }
13996 : : }
13997 : : break;
13998 : 6 : case REAL_CST:
13999 : 6 : {
14000 : 6 : {
14001 : 6 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _p1 };
14002 : 6 : if (gimple_simplify_255 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_SQRTL, GE_EXPR))
14003 : 6 : return true;
14004 : : }
14005 : 0 : break;
14006 : : }
14007 : : default:;
14008 : : }
14009 : : }
14010 : : break;
14011 : 25 : case CFN_BUILT_IN_SQRT:
14012 : 25 : if (gimple_call_num_args (_c1) == 1)
14013 : : {
14014 : 25 : tree _q20 = gimple_call_arg (_c1, 0);
14015 : 25 : _q20 = do_valueize (valueize, _q20);
14016 : 25 : switch (TREE_CODE (_p1))
14017 : : {
14018 : 2 : case SSA_NAME:
14019 : 2 : if (gimple *_d2 = get_def (valueize, _p1))
14020 : : {
14021 : 2 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
14022 : 2 : switch (gimple_call_combined_fn (_c2))
14023 : : {
14024 : 2 : case CFN_BUILT_IN_SQRT:
14025 : 2 : if (gimple_call_num_args (_c2) == 1)
14026 : : {
14027 : 2 : tree _q40 = gimple_call_arg (_c2, 0);
14028 : 2 : _q40 = do_valueize (valueize, _q40);
14029 : 2 : {
14030 : 2 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q40 };
14031 : 2 : if (gimple_simplify_256 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_SQRT, GE_EXPR))
14032 : 2 : return true;
14033 : : }
14034 : : }
14035 : : break;
14036 : : default:;
14037 : : }
14038 : : }
14039 : : break;
14040 : 23 : case REAL_CST:
14041 : 23 : {
14042 : 23 : {
14043 : 23 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _p1 };
14044 : 23 : if (gimple_simplify_255 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_SQRT, GE_EXPR))
14045 : 6 : return true;
14046 : : }
14047 : 17 : break;
14048 : : }
14049 : : default:;
14050 : : }
14051 : : }
14052 : : break;
14053 : 0 : case CFN_SQRT:
14054 : 0 : if (gimple_call_num_args (_c1) == 1)
14055 : : {
14056 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
14057 : 0 : _q20 = do_valueize (valueize, _q20);
14058 : 0 : switch (TREE_CODE (_p1))
14059 : : {
14060 : 0 : case SSA_NAME:
14061 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
14062 : : {
14063 : 0 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
14064 : 0 : switch (gimple_call_combined_fn (_c2))
14065 : : {
14066 : 0 : case CFN_SQRT:
14067 : 0 : if (gimple_call_num_args (_c2) == 1)
14068 : : {
14069 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
14070 : 0 : _q40 = do_valueize (valueize, _q40);
14071 : 0 : {
14072 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q40 };
14073 : 0 : if (gimple_simplify_256 (res_op, seq, valueize, type, captures, CFN_SQRT, GE_EXPR))
14074 : 0 : return true;
14075 : : }
14076 : : }
14077 : : break;
14078 : : default:;
14079 : : }
14080 : : }
14081 : : break;
14082 : 0 : case REAL_CST:
14083 : 0 : {
14084 : 0 : {
14085 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _p1 };
14086 : 0 : if (gimple_simplify_255 (res_op, seq, valueize, type, captures, CFN_SQRT, GE_EXPR))
14087 : 0 : return true;
14088 : : }
14089 : 0 : break;
14090 : : }
14091 : : default:;
14092 : : }
14093 : : }
14094 : : break;
14095 : : default:;
14096 : : }
14097 : : }
14098 : : break;
14099 : 7926433 : default:;
14100 : : }
14101 : 7926433 : switch (TREE_CODE (_p1))
14102 : : {
14103 : 2961041 : case SSA_NAME:
14104 : 2961041 : if (gimple *_d1 = get_def (valueize, _p1))
14105 : : {
14106 : 1033406 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
14107 : 1136870 : switch (gimple_assign_rhs_code (_a1))
14108 : : {
14109 : 229 : case COND_EXPR:
14110 : 229 : {
14111 : 229 : tree _q30 = gimple_assign_rhs1 (_a1);
14112 : 229 : _q30 = do_valueize (valueize, _q30);
14113 : 229 : tree _q31 = gimple_assign_rhs2 (_a1);
14114 : 229 : _q31 = do_valueize (valueize, _q31);
14115 : 229 : tree _q32 = gimple_assign_rhs3 (_a1);
14116 : 229 : _q32 = do_valueize (valueize, _q32);
14117 : 229 : {
14118 : 229 : tree captures[4] ATTRIBUTE_UNUSED = { _q30, _q31, _q32, _p0 };
14119 : 229 : if (gimple_simplify_278 (res_op, seq, valueize, type, captures, LE_EXPR))
14120 : 0 : return true;
14121 : : }
14122 : 229 : break;
14123 : : }
14124 : : default:;
14125 : : }
14126 : : }
14127 : : break;
14128 : 7926433 : default:;
14129 : : }
14130 : 7926433 : switch (TREE_CODE (_p0))
14131 : : {
14132 : 7705249 : case SSA_NAME:
14133 : 7705249 : if (gimple *_d1 = get_def (valueize, _p0))
14134 : : {
14135 : 2262352 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
14136 : 2115098 : switch (gimple_assign_rhs_code (_a1))
14137 : : {
14138 : 221687 : CASE_CONVERT:
14139 : 221687 : {
14140 : 221687 : tree _q20 = gimple_assign_rhs1 (_a1);
14141 : 221687 : _q20 = do_valueize (valueize, _q20);
14142 : 221687 : switch (TREE_CODE (_q20))
14143 : : {
14144 : 220695 : case SSA_NAME:
14145 : 220695 : if (gimple *_d2 = get_def (valueize, _q20))
14146 : : {
14147 : 212956 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
14148 : 221431 : switch (gimple_assign_rhs_code (_a2))
14149 : : {
14150 : 0 : case ADDR_EXPR:
14151 : 0 : {
14152 : 0 : switch (TREE_CODE (_p1))
14153 : : {
14154 : 0 : case SSA_NAME:
14155 : 0 : if (gimple *_d3 = get_def (valueize, _p1))
14156 : : {
14157 : 0 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
14158 : 0 : switch (gimple_assign_rhs_code (_a3))
14159 : : {
14160 : 0 : CASE_CONVERT:
14161 : 0 : {
14162 : 0 : tree _q40 = gimple_assign_rhs1 (_a3);
14163 : 0 : _q40 = do_valueize (valueize, _q40);
14164 : 0 : switch (TREE_CODE (_q40))
14165 : : {
14166 : 0 : case SSA_NAME:
14167 : 0 : if (gimple *_d4 = get_def (valueize, _q40))
14168 : : {
14169 : 0 : if (gassign *_a4 = dyn_cast <gassign *> (_d4))
14170 : 0 : switch (gimple_assign_rhs_code (_a4))
14171 : : {
14172 : 0 : case ADDR_EXPR:
14173 : 0 : {
14174 : 0 : {
14175 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q40 };
14176 : 0 : if (gimple_simplify_281 (res_op, seq, valueize, type, captures, GE_EXPR))
14177 : 0 : return true;
14178 : : }
14179 : 0 : break;
14180 : : }
14181 : : default:;
14182 : : }
14183 : : }
14184 : : break;
14185 : 0 : case ADDR_EXPR:
14186 : 0 : {
14187 : 0 : {
14188 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q40 };
14189 : 0 : if (gimple_simplify_281 (res_op, seq, valueize, type, captures, GE_EXPR))
14190 : 0 : return true;
14191 : : }
14192 : 0 : break;
14193 : : }
14194 : : default:;
14195 : : }
14196 : : break;
14197 : : }
14198 : 0 : case ADDR_EXPR:
14199 : 0 : {
14200 : 0 : {
14201 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
14202 : 0 : if (gimple_simplify_281 (res_op, seq, valueize, type, captures, GE_EXPR))
14203 : 0 : return true;
14204 : : }
14205 : 0 : break;
14206 : : }
14207 : : default:;
14208 : : }
14209 : : }
14210 : : break;
14211 : 0 : case ADDR_EXPR:
14212 : 0 : {
14213 : 0 : {
14214 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
14215 : 0 : if (gimple_simplify_281 (res_op, seq, valueize, type, captures, GE_EXPR))
14216 : 0 : return true;
14217 : : }
14218 : 0 : break;
14219 : : }
14220 : : default:;
14221 : : }
14222 : : break;
14223 : : }
14224 : : default:;
14225 : : }
14226 : : }
14227 : : break;
14228 : 992 : case ADDR_EXPR:
14229 : 992 : {
14230 : 992 : switch (TREE_CODE (_p1))
14231 : : {
14232 : 992 : case SSA_NAME:
14233 : 992 : if (gimple *_d2 = get_def (valueize, _p1))
14234 : : {
14235 : 991 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
14236 : 1775 : switch (gimple_assign_rhs_code (_a2))
14237 : : {
14238 : 152 : CASE_CONVERT:
14239 : 152 : {
14240 : 152 : tree _q40 = gimple_assign_rhs1 (_a2);
14241 : 152 : _q40 = do_valueize (valueize, _q40);
14242 : 152 : switch (TREE_CODE (_q40))
14243 : : {
14244 : 0 : case SSA_NAME:
14245 : 0 : if (gimple *_d3 = get_def (valueize, _q40))
14246 : : {
14247 : 0 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
14248 : 0 : switch (gimple_assign_rhs_code (_a3))
14249 : : {
14250 : 0 : case ADDR_EXPR:
14251 : 0 : {
14252 : 0 : {
14253 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q40 };
14254 : 0 : if (gimple_simplify_281 (res_op, seq, valueize, type, captures, GE_EXPR))
14255 : 0 : return true;
14256 : : }
14257 : 0 : break;
14258 : : }
14259 : : default:;
14260 : : }
14261 : : }
14262 : : break;
14263 : 152 : case ADDR_EXPR:
14264 : 152 : {
14265 : 152 : {
14266 : 152 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q40 };
14267 : 152 : if (gimple_simplify_281 (res_op, seq, valueize, type, captures, GE_EXPR))
14268 : 14 : return true;
14269 : : }
14270 : 138 : break;
14271 : : }
14272 : : default:;
14273 : : }
14274 : : break;
14275 : : }
14276 : 0 : case ADDR_EXPR:
14277 : 0 : {
14278 : 0 : {
14279 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
14280 : 0 : if (gimple_simplify_281 (res_op, seq, valueize, type, captures, GE_EXPR))
14281 : 0 : return true;
14282 : : }
14283 : 0 : break;
14284 : : }
14285 : : default:;
14286 : : }
14287 : : }
14288 : : break;
14289 : 0 : case ADDR_EXPR:
14290 : 0 : {
14291 : 0 : {
14292 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
14293 : 0 : if (gimple_simplify_281 (res_op, seq, valueize, type, captures, GE_EXPR))
14294 : 0 : return true;
14295 : : }
14296 : 0 : break;
14297 : : }
14298 : : default:;
14299 : : }
14300 : : break;
14301 : : }
14302 : 221673 : default:;
14303 : : }
14304 : 221673 : if (uniform_integer_cst_p (_p1))
14305 : : {
14306 : 94759 : {
14307 : 94759 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
14308 : 94759 : if (gimple_simplify_351 (res_op, seq, valueize, type, captures, GE_EXPR))
14309 : 344 : return true;
14310 : : }
14311 : : }
14312 : : break;
14313 : : }
14314 : 61 : case ADDR_EXPR:
14315 : 61 : {
14316 : 61 : switch (TREE_CODE (_p1))
14317 : : {
14318 : 61 : case SSA_NAME:
14319 : 61 : if (gimple *_d2 = get_def (valueize, _p1))
14320 : : {
14321 : 61 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
14322 : 117 : switch (gimple_assign_rhs_code (_a2))
14323 : : {
14324 : 2 : CASE_CONVERT:
14325 : 2 : {
14326 : 2 : tree _q30 = gimple_assign_rhs1 (_a2);
14327 : 2 : _q30 = do_valueize (valueize, _q30);
14328 : 2 : switch (TREE_CODE (_q30))
14329 : : {
14330 : 2 : case SSA_NAME:
14331 : 2 : if (gimple *_d3 = get_def (valueize, _q30))
14332 : : {
14333 : 2 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
14334 : 2 : switch (gimple_assign_rhs_code (_a3))
14335 : : {
14336 : 0 : case ADDR_EXPR:
14337 : 0 : {
14338 : 0 : {
14339 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p0, _q30 };
14340 : 0 : if (gimple_simplify_282 (res_op, seq, valueize, type, captures, GE_EXPR))
14341 : 0 : return true;
14342 : : }
14343 : 0 : break;
14344 : : }
14345 : : default:;
14346 : : }
14347 : : }
14348 : : break;
14349 : 0 : case ADDR_EXPR:
14350 : 0 : {
14351 : 0 : {
14352 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p0, _q30 };
14353 : 0 : if (gimple_simplify_282 (res_op, seq, valueize, type, captures, GE_EXPR))
14354 : 0 : return true;
14355 : : }
14356 : 0 : break;
14357 : : }
14358 : : default:;
14359 : : }
14360 : : break;
14361 : : }
14362 : 0 : case ADDR_EXPR:
14363 : 0 : {
14364 : 0 : {
14365 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p0, _p1 };
14366 : 0 : if (gimple_simplify_282 (res_op, seq, valueize, type, captures, GE_EXPR))
14367 : 0 : return true;
14368 : : }
14369 : 0 : break;
14370 : : }
14371 : : default:;
14372 : : }
14373 : : }
14374 : : break;
14375 : 0 : case ADDR_EXPR:
14376 : 0 : {
14377 : 0 : {
14378 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p0, _p1 };
14379 : 0 : if (gimple_simplify_282 (res_op, seq, valueize, type, captures, GE_EXPR))
14380 : 0 : return true;
14381 : : }
14382 : 0 : break;
14383 : : }
14384 : : default:;
14385 : : }
14386 : : break;
14387 : : }
14388 : : default:;
14389 : : }
14390 : : }
14391 : : break;
14392 : 7718 : case ADDR_EXPR:
14393 : 7718 : {
14394 : 7718 : switch (TREE_CODE (_p1))
14395 : : {
14396 : 5010 : case SSA_NAME:
14397 : 5010 : if (gimple *_d1 = get_def (valueize, _p1))
14398 : : {
14399 : 1302 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
14400 : 1297 : switch (gimple_assign_rhs_code (_a1))
14401 : : {
14402 : 15 : CASE_CONVERT:
14403 : 15 : {
14404 : 15 : tree _q30 = gimple_assign_rhs1 (_a1);
14405 : 15 : _q30 = do_valueize (valueize, _q30);
14406 : 15 : switch (TREE_CODE (_q30))
14407 : : {
14408 : 15 : case SSA_NAME:
14409 : 15 : if (gimple *_d2 = get_def (valueize, _q30))
14410 : : {
14411 : 15 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
14412 : 0 : switch (gimple_assign_rhs_code (_a2))
14413 : : {
14414 : 0 : case ADDR_EXPR:
14415 : 0 : {
14416 : 0 : {
14417 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p0, _q30 };
14418 : 0 : if (gimple_simplify_282 (res_op, seq, valueize, type, captures, GE_EXPR))
14419 : 0 : return true;
14420 : : }
14421 : 0 : break;
14422 : : }
14423 : : default:;
14424 : : }
14425 : : }
14426 : : break;
14427 : 0 : case ADDR_EXPR:
14428 : 0 : {
14429 : 0 : {
14430 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p0, _q30 };
14431 : 0 : if (gimple_simplify_282 (res_op, seq, valueize, type, captures, GE_EXPR))
14432 : 0 : return true;
14433 : : }
14434 : 0 : break;
14435 : : }
14436 : : default:;
14437 : : }
14438 : : break;
14439 : : }
14440 : 0 : case ADDR_EXPR:
14441 : 0 : {
14442 : 0 : {
14443 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p0, _p1 };
14444 : 0 : if (gimple_simplify_282 (res_op, seq, valueize, type, captures, GE_EXPR))
14445 : 0 : return true;
14446 : : }
14447 : 0 : break;
14448 : : }
14449 : : default:;
14450 : : }
14451 : : }
14452 : : break;
14453 : 2684 : case ADDR_EXPR:
14454 : 2684 : {
14455 : 2684 : {
14456 : 2684 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p0, _p1 };
14457 : 2684 : if (gimple_simplify_282 (res_op, seq, valueize, type, captures, GE_EXPR))
14458 : 2634 : return true;
14459 : : }
14460 : 50 : break;
14461 : : }
14462 : : default:;
14463 : : }
14464 : : break;
14465 : : }
14466 : 7923441 : default:;
14467 : : }
14468 : 7923441 : if (uniform_integer_cst_p (_p1))
14469 : : {
14470 : 4694064 : {
14471 : 4694064 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _p0, _p1 };
14472 : 4694064 : if (gimple_simplify_352 (res_op, seq, valueize, type, captures, GE_EXPR))
14473 : 10384 : return true;
14474 : : }
14475 : : }
14476 : 7913057 : switch (TREE_CODE (_p0))
14477 : : {
14478 : 7694521 : case SSA_NAME:
14479 : 7694521 : if (gimple *_d1 = get_def (valueize, _p0))
14480 : : {
14481 : 2254615 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
14482 : 2101956 : switch (gimple_assign_rhs_code (_a1))
14483 : : {
14484 : 221152 : CASE_CONVERT:
14485 : 221152 : {
14486 : 221152 : tree _q20 = gimple_assign_rhs1 (_a1);
14487 : 221152 : _q20 = do_valueize (valueize, _q20);
14488 : 221152 : switch (TREE_CODE (_q20))
14489 : : {
14490 : 220174 : case SSA_NAME:
14491 : 220174 : if (gimple *_d2 = get_def (valueize, _q20))
14492 : : {
14493 : 212436 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
14494 : 221022 : switch (gimple_assign_rhs_code (_a2))
14495 : : {
14496 : 28822 : case PLUS_EXPR:
14497 : 28822 : {
14498 : 28822 : tree _q30 = gimple_assign_rhs1 (_a2);
14499 : 28822 : _q30 = do_valueize (valueize, _q30);
14500 : 28822 : tree _q31 = gimple_assign_rhs2 (_a2);
14501 : 28822 : _q31 = do_valueize (valueize, _q31);
14502 : 28822 : if (tree_swap_operands_p (_q30, _q31))
14503 : 759 : std::swap (_q30, _q31);
14504 : 28822 : switch (TREE_CODE (_q30))
14505 : : {
14506 : 28822 : case SSA_NAME:
14507 : 28822 : if (gimple *_d3 = get_def (valueize, _q30))
14508 : : {
14509 : 28175 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
14510 : 29111 : switch (gimple_assign_rhs_code (_a3))
14511 : : {
14512 : 12435 : CASE_CONVERT:
14513 : 12435 : {
14514 : 12435 : tree _q40 = gimple_assign_rhs1 (_a3);
14515 : 12435 : _q40 = do_valueize (valueize, _q40);
14516 : 12435 : switch (TREE_CODE (_q31))
14517 : : {
14518 : 11161 : case INTEGER_CST:
14519 : 11161 : {
14520 : 11161 : if ((_p1 == _q40 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q40, 0) && types_match (_p1, _q40)))
14521 : : {
14522 : 78 : {
14523 : 78 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q40, _q31 };
14524 : 78 : if (gimple_simplify_353 (res_op, seq, valueize, type, captures, GE_EXPR, LE_EXPR))
14525 : 78 : return true;
14526 : : }
14527 : : }
14528 : : break;
14529 : : }
14530 : : default:;
14531 : : }
14532 : : break;
14533 : : }
14534 : : default:;
14535 : : }
14536 : : }
14537 : : break;
14538 : : default:;
14539 : : }
14540 : 7912979 : break;
14541 : : }
14542 : : default:;
14543 : : }
14544 : : }
14545 : : break;
14546 : : default:;
14547 : : }
14548 : : break;
14549 : : }
14550 : : default:;
14551 : : }
14552 : : }
14553 : : break;
14554 : 7912979 : default:;
14555 : : }
14556 : 7912979 : switch (TREE_CODE (_p1))
14557 : : {
14558 : 2960949 : case SSA_NAME:
14559 : 2960949 : if (gimple *_d1 = get_def (valueize, _p1))
14560 : : {
14561 : 1033314 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
14562 : 1136856 : switch (gimple_assign_rhs_code (_a1))
14563 : : {
14564 : 106670 : CASE_CONVERT:
14565 : 106670 : {
14566 : 106670 : tree _q30 = gimple_assign_rhs1 (_a1);
14567 : 106670 : _q30 = do_valueize (valueize, _q30);
14568 : 106670 : switch (TREE_CODE (_q30))
14569 : : {
14570 : 106464 : case SSA_NAME:
14571 : 106464 : if (gimple *_d2 = get_def (valueize, _q30))
14572 : : {
14573 : 98108 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
14574 : 106726 : switch (gimple_assign_rhs_code (_a2))
14575 : : {
14576 : 12057 : case PLUS_EXPR:
14577 : 12057 : {
14578 : 12057 : tree _q40 = gimple_assign_rhs1 (_a2);
14579 : 12057 : _q40 = do_valueize (valueize, _q40);
14580 : 12057 : tree _q41 = gimple_assign_rhs2 (_a2);
14581 : 12057 : _q41 = do_valueize (valueize, _q41);
14582 : 12057 : if (tree_swap_operands_p (_q40, _q41))
14583 : 358 : std::swap (_q40, _q41);
14584 : 12057 : switch (TREE_CODE (_q40))
14585 : : {
14586 : 12057 : case SSA_NAME:
14587 : 12057 : if (gimple *_d3 = get_def (valueize, _q40))
14588 : : {
14589 : 11369 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
14590 : 12365 : switch (gimple_assign_rhs_code (_a3))
14591 : : {
14592 : 1921 : CASE_CONVERT:
14593 : 1921 : {
14594 : 1921 : tree _q50 = gimple_assign_rhs1 (_a3);
14595 : 1921 : _q50 = do_valueize (valueize, _q50);
14596 : 1921 : if ((_q50 == _p0 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _p0, 0) && types_match (_q50, _p0)))
14597 : : {
14598 : 72 : switch (TREE_CODE (_q41))
14599 : : {
14600 : 72 : case INTEGER_CST:
14601 : 72 : {
14602 : 72 : {
14603 : 72 : tree captures[5] ATTRIBUTE_UNUSED = { _p1, _q30, _q40, _p0, _q41 };
14604 : 72 : if (gimple_simplify_353 (res_op, seq, valueize, type, captures, LE_EXPR, GT_EXPR))
14605 : 72 : return true;
14606 : : }
14607 : 0 : break;
14608 : : }
14609 : : default:;
14610 : : }
14611 : : }
14612 : : break;
14613 : : }
14614 : : default:;
14615 : : }
14616 : : }
14617 : : break;
14618 : : default:;
14619 : : }
14620 : 7912816 : break;
14621 : : }
14622 : : default:;
14623 : : }
14624 : : }
14625 : : break;
14626 : : default:;
14627 : : }
14628 : : break;
14629 : : }
14630 : 291430 : case PLUS_EXPR:
14631 : 291430 : {
14632 : 291430 : tree _q30 = gimple_assign_rhs1 (_a1);
14633 : 291430 : _q30 = do_valueize (valueize, _q30);
14634 : 291430 : tree _q31 = gimple_assign_rhs2 (_a1);
14635 : 291430 : _q31 = do_valueize (valueize, _q31);
14636 : 291430 : if (tree_swap_operands_p (_q30, _q31))
14637 : 24724 : std::swap (_q30, _q31);
14638 : 291430 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || (operand_equal_p (_q30, _p0, 0) && types_match (_q30, _p0)))
14639 : : {
14640 : 6005 : switch (TREE_CODE (_q31))
14641 : : {
14642 : 2689 : case INTEGER_CST:
14643 : 2689 : {
14644 : 2689 : {
14645 : 2689 : tree captures[5] ATTRIBUTE_UNUSED = { _p1, _p1, _q30, _p0, _q31 };
14646 : 2689 : if (gimple_simplify_348 (res_op, seq, valueize, type, captures, LE_EXPR, GT_EXPR))
14647 : 86 : return true;
14648 : : }
14649 : 2603 : break;
14650 : : }
14651 : : default:;
14652 : : }
14653 : : }
14654 : 7912816 : break;
14655 : : }
14656 : 35718 : case MINUS_EXPR:
14657 : 35718 : {
14658 : 35718 : tree _q30 = gimple_assign_rhs1 (_a1);
14659 : 35718 : _q30 = do_valueize (valueize, _q30);
14660 : 35718 : tree _q31 = gimple_assign_rhs2 (_a1);
14661 : 35718 : _q31 = do_valueize (valueize, _q31);
14662 : 35718 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || (operand_equal_p (_q30, _p0, 0) && types_match (_q30, _p0)))
14663 : : {
14664 : 6985 : {
14665 : 6985 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _p0, _q31 };
14666 : 6985 : if (gimple_simplify_354 (res_op, seq, valueize, type, captures, LE_EXPR))
14667 : 5 : return true;
14668 : : }
14669 : : }
14670 : : break;
14671 : : }
14672 : : default:;
14673 : : }
14674 : : }
14675 : : break;
14676 : 7912816 : default:;
14677 : : }
14678 : 7912816 : switch (TREE_CODE (_p0))
14679 : : {
14680 : 7694280 : case SSA_NAME:
14681 : 7694280 : if (gimple *_d1 = get_def (valueize, _p0))
14682 : : {
14683 : 2254374 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
14684 : 2101788 : switch (gimple_assign_rhs_code (_a1))
14685 : : {
14686 : 419658 : case PLUS_EXPR:
14687 : 419658 : {
14688 : 419658 : tree _q20 = gimple_assign_rhs1 (_a1);
14689 : 419658 : _q20 = do_valueize (valueize, _q20);
14690 : 419658 : tree _q21 = gimple_assign_rhs2 (_a1);
14691 : 419658 : _q21 = do_valueize (valueize, _q21);
14692 : 419658 : if (tree_swap_operands_p (_q20, _q21))
14693 : 26068 : std::swap (_q20, _q21);
14694 : 419658 : switch (TREE_CODE (_q20))
14695 : : {
14696 : 419658 : case SSA_NAME:
14697 : 419658 : if (gimple *_d2 = get_def (valueize, _q20))
14698 : : {
14699 : 407726 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
14700 : 260676 : switch (gimple_assign_rhs_code (_a2))
14701 : : {
14702 : 6986 : case MINUS_EXPR:
14703 : 6986 : {
14704 : 6986 : tree _q30 = gimple_assign_rhs1 (_a2);
14705 : 6986 : _q30 = do_valueize (valueize, _q30);
14706 : 6986 : tree _q31 = gimple_assign_rhs2 (_a2);
14707 : 6986 : _q31 = do_valueize (valueize, _q31);
14708 : 6986 : if (integer_minus_onep (_q21))
14709 : : {
14710 : 2522 : if ((_p1 == _q30 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q30, 0) && types_match (_p1, _q30)))
14711 : : {
14712 : 2 : {
14713 : 2 : tree captures[2] ATTRIBUTE_UNUSED = { _q30, _q31 };
14714 : 2 : if (gimple_simplify_355 (res_op, seq, valueize, type, captures, GE_EXPR))
14715 : 2 : return true;
14716 : : }
14717 : : }
14718 : : }
14719 : : break;
14720 : : }
14721 : : default:;
14722 : : }
14723 : : }
14724 : : break;
14725 : : default:;
14726 : : }
14727 : 7912814 : break;
14728 : : }
14729 : : default:;
14730 : : }
14731 : : }
14732 : : break;
14733 : 7912814 : default:;
14734 : : }
14735 : 7912814 : switch (TREE_CODE (_p1))
14736 : : {
14737 : 2960784 : case SSA_NAME:
14738 : 2960784 : if (gimple *_d1 = get_def (valueize, _p1))
14739 : : {
14740 : 1033149 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
14741 : 1136693 : switch (gimple_assign_rhs_code (_a1))
14742 : : {
14743 : 4 : case REALPART_EXPR:
14744 : 4 : {
14745 : 4 : tree _q30 = TREE_OPERAND (gimple_assign_rhs1 (_a1), 0);
14746 : 4 : if ((TREE_CODE (_q30) == SSA_NAME
14747 : 4 : || is_gimple_min_invariant (_q30)))
14748 : : {
14749 : 4 : _q30 = do_valueize (valueize, _q30);
14750 : 4 : switch (TREE_CODE (_q30))
14751 : : {
14752 : 4 : case SSA_NAME:
14753 : 4 : if (gimple *_d2 = get_def (valueize, _q30))
14754 : : {
14755 : 4 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
14756 : 4 : switch (gimple_call_combined_fn (_c2))
14757 : : {
14758 : 0 : case CFN_SUB_OVERFLOW:
14759 : 0 : if (gimple_call_num_args (_c2) == 2)
14760 : : {
14761 : 0 : tree _q40 = gimple_call_arg (_c2, 0);
14762 : 0 : _q40 = do_valueize (valueize, _q40);
14763 : 0 : tree _q41 = gimple_call_arg (_c2, 1);
14764 : 0 : _q41 = do_valueize (valueize, _q41);
14765 : 0 : if ((_q40 == _p0 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _p0, 0) && types_match (_q40, _p0)))
14766 : : {
14767 : 0 : {
14768 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q30, _p0, _q41 };
14769 : 0 : if (gimple_simplify_356 (res_op, seq, valueize, type, captures, LE_EXPR, EQ_EXPR))
14770 : 0 : return true;
14771 : : }
14772 : : }
14773 : : }
14774 : : break;
14775 : : default:;
14776 : : }
14777 : : }
14778 : : break;
14779 : : default:;
14780 : : }
14781 : : }
14782 : : break;
14783 : : }
14784 : : default:;
14785 : : }
14786 : : }
14787 : : break;
14788 : 7912814 : default:;
14789 : : }
14790 : 7912814 : switch (TREE_CODE (_p0))
14791 : : {
14792 : 7694278 : case SSA_NAME:
14793 : 7694278 : if (gimple *_d1 = get_def (valueize, _p0))
14794 : : {
14795 : 2254372 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
14796 : 2101786 : switch (gimple_assign_rhs_code (_a1))
14797 : : {
14798 : 49 : case REALPART_EXPR:
14799 : 49 : {
14800 : 49 : tree _q20 = TREE_OPERAND (gimple_assign_rhs1 (_a1), 0);
14801 : 49 : if ((TREE_CODE (_q20) == SSA_NAME
14802 : 49 : || is_gimple_min_invariant (_q20)))
14803 : : {
14804 : 49 : _q20 = do_valueize (valueize, _q20);
14805 : 49 : switch (TREE_CODE (_q20))
14806 : : {
14807 : 49 : case SSA_NAME:
14808 : 49 : if (gimple *_d2 = get_def (valueize, _q20))
14809 : : {
14810 : 49 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
14811 : 16 : switch (gimple_call_combined_fn (_c2))
14812 : : {
14813 : 16 : case CFN_ADD_OVERFLOW:
14814 : 16 : if (gimple_call_num_args (_c2) == 2)
14815 : : {
14816 : 16 : tree _q30 = gimple_call_arg (_c2, 0);
14817 : 16 : _q30 = do_valueize (valueize, _q30);
14818 : 16 : tree _q31 = gimple_call_arg (_c2, 1);
14819 : 16 : _q31 = do_valueize (valueize, _q31);
14820 : 16 : if ((_p1 == _q30 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q30, 0) && types_match (_p1, _q30)))
14821 : : {
14822 : 4 : {
14823 : 4 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q30, _q31 };
14824 : 4 : if (gimple_simplify_357 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
14825 : 2 : return true;
14826 : : }
14827 : : }
14828 : 14 : if ((_p1 == _q31 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q31, 0) && types_match (_p1, _q31)))
14829 : : {
14830 : 6 : {
14831 : 6 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q31, _q30 };
14832 : 6 : if (gimple_simplify_357 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
14833 : 3 : return true;
14834 : : }
14835 : : }
14836 : : }
14837 : : break;
14838 : : default:;
14839 : : }
14840 : : }
14841 : : break;
14842 : : default:;
14843 : : }
14844 : : }
14845 : : break;
14846 : : }
14847 : 2363 : case TRUNC_DIV_EXPR:
14848 : 2363 : {
14849 : 2363 : tree _q20 = gimple_assign_rhs1 (_a1);
14850 : 2363 : _q20 = do_valueize (valueize, _q20);
14851 : 2363 : tree _q21 = gimple_assign_rhs2 (_a1);
14852 : 2363 : _q21 = do_valueize (valueize, _q21);
14853 : 2363 : if (integer_all_onesp (_q20))
14854 : : {
14855 : 48 : {
14856 : 48 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q21, _p1 };
14857 : 48 : if (gimple_simplify_358 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
14858 : 6 : return true;
14859 : : }
14860 : : }
14861 : : break;
14862 : : }
14863 : 23013 : case MULT_EXPR:
14864 : 23013 : {
14865 : 23013 : tree _q20 = gimple_assign_rhs1 (_a1);
14866 : 23013 : _q20 = do_valueize (valueize, _q20);
14867 : 23013 : tree _q21 = gimple_assign_rhs2 (_a1);
14868 : 23013 : _q21 = do_valueize (valueize, _q21);
14869 : 23013 : if (tree_swap_operands_p (_q20, _q21))
14870 : 660 : std::swap (_q20, _q21);
14871 : 23013 : switch (TREE_CODE (_q21))
14872 : : {
14873 : 897 : case REAL_CST:
14874 : 897 : {
14875 : 897 : switch (TREE_CODE (_p1))
14876 : : {
14877 : 292 : case REAL_CST:
14878 : 292 : {
14879 : 292 : {
14880 : 292 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
14881 : 292 : if (gimple_simplify_359 (res_op, seq, valueize, type, captures, GE_EXPR, LE_EXPR))
14882 : 0 : return true;
14883 : : }
14884 : 292 : break;
14885 : : }
14886 : : default:;
14887 : : }
14888 : : break;
14889 : : }
14890 : : default:;
14891 : : }
14892 : 8111550 : break;
14893 : : }
14894 : 419656 : case PLUS_EXPR:
14895 : 419656 : {
14896 : 419656 : tree _q20 = gimple_assign_rhs1 (_a1);
14897 : 419656 : _q20 = do_valueize (valueize, _q20);
14898 : 419656 : tree _q21 = gimple_assign_rhs2 (_a1);
14899 : 419656 : _q21 = do_valueize (valueize, _q21);
14900 : 419656 : if (tree_swap_operands_p (_q20, _q21))
14901 : 26068 : std::swap (_q20, _q21);
14902 : 419656 : switch (TREE_CODE (_q21))
14903 : : {
14904 : 217813 : case INTEGER_CST:
14905 : 217813 : {
14906 : 217813 : switch (TREE_CODE (_p1))
14907 : : {
14908 : 143683 : case INTEGER_CST:
14909 : 143683 : {
14910 : 143683 : {
14911 : 143683 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1 };
14912 : 143683 : if (gimple_simplify_360 (res_op, seq, valueize, type, captures, PLUS_EXPR, MINUS_EXPR, GE_EXPR))
14913 : 3140 : return true;
14914 : : }
14915 : 140543 : break;
14916 : : }
14917 : : default:;
14918 : : }
14919 : : break;
14920 : : }
14921 : : default:;
14922 : : }
14923 : 8111550 : break;
14924 : : }
14925 : 122758 : case MINUS_EXPR:
14926 : 122758 : {
14927 : 122758 : tree _q20 = gimple_assign_rhs1 (_a1);
14928 : 122758 : _q20 = do_valueize (valueize, _q20);
14929 : 122758 : tree _q21 = gimple_assign_rhs2 (_a1);
14930 : 122758 : _q21 = do_valueize (valueize, _q21);
14931 : 122758 : switch (TREE_CODE (_q21))
14932 : : {
14933 : 3334 : case INTEGER_CST:
14934 : 3334 : {
14935 : 3334 : switch (TREE_CODE (_p1))
14936 : : {
14937 : 3306 : case INTEGER_CST:
14938 : 3306 : {
14939 : 3306 : {
14940 : 3306 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1 };
14941 : 3306 : if (gimple_simplify_360 (res_op, seq, valueize, type, captures, MINUS_EXPR, PLUS_EXPR, GE_EXPR))
14942 : 1192 : return true;
14943 : : }
14944 : 2114 : break;
14945 : : }
14946 : : default:;
14947 : : }
14948 : : break;
14949 : : }
14950 : : default:;
14951 : : }
14952 : : break;
14953 : : }
14954 : : default:;
14955 : : }
14956 : 757117 : else if (gcall *_c1 = dyn_cast <gcall *> (_d1))
14957 : 167741 : switch (gimple_call_combined_fn (_c1))
14958 : : {
14959 : 0 : case CFN_BUILT_IN_CTZ:
14960 : 0 : if (gimple_call_num_args (_c1) == 1)
14961 : : {
14962 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
14963 : 0 : _q20 = do_valueize (valueize, _q20);
14964 : 0 : switch (TREE_CODE (_p1))
14965 : : {
14966 : 0 : case INTEGER_CST:
14967 : 0 : {
14968 : 0 : {
14969 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
14970 : 0 : if (gimple_simplify_361 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR, CFN_BUILT_IN_CTZ))
14971 : 0 : return true;
14972 : : }
14973 : 0 : break;
14974 : : }
14975 : : default:;
14976 : : }
14977 : : }
14978 : : break;
14979 : 0 : case CFN_BUILT_IN_CTZL:
14980 : 0 : if (gimple_call_num_args (_c1) == 1)
14981 : : {
14982 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
14983 : 0 : _q20 = do_valueize (valueize, _q20);
14984 : 0 : switch (TREE_CODE (_p1))
14985 : : {
14986 : 0 : case INTEGER_CST:
14987 : 0 : {
14988 : 0 : {
14989 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
14990 : 0 : if (gimple_simplify_361 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR, CFN_BUILT_IN_CTZL))
14991 : 0 : return true;
14992 : : }
14993 : 0 : break;
14994 : : }
14995 : : default:;
14996 : : }
14997 : : }
14998 : : break;
14999 : 0 : case CFN_BUILT_IN_CTZIMAX:
15000 : 0 : if (gimple_call_num_args (_c1) == 1)
15001 : : {
15002 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
15003 : 0 : _q20 = do_valueize (valueize, _q20);
15004 : 0 : switch (TREE_CODE (_p1))
15005 : : {
15006 : 0 : case INTEGER_CST:
15007 : 0 : {
15008 : 0 : {
15009 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
15010 : 0 : if (gimple_simplify_361 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR, CFN_BUILT_IN_CTZIMAX))
15011 : 0 : return true;
15012 : : }
15013 : 0 : break;
15014 : : }
15015 : : default:;
15016 : : }
15017 : : }
15018 : : break;
15019 : 0 : case CFN_CTZ:
15020 : 0 : if (gimple_call_num_args (_c1) == 1)
15021 : : {
15022 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
15023 : 0 : _q20 = do_valueize (valueize, _q20);
15024 : 0 : switch (TREE_CODE (_p1))
15025 : : {
15026 : 0 : case INTEGER_CST:
15027 : 0 : {
15028 : 0 : {
15029 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
15030 : 0 : if (gimple_simplify_361 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR, CFN_CTZ))
15031 : 0 : return true;
15032 : : }
15033 : 0 : break;
15034 : : }
15035 : : default:;
15036 : : }
15037 : : }
15038 : 0 : if (gimple_call_num_args (_c1) == 2)
15039 : : {
15040 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
15041 : 0 : _q20 = do_valueize (valueize, _q20);
15042 : 0 : tree _q21 = gimple_call_arg (_c1, 1);
15043 : 0 : _q21 = do_valueize (valueize, _q21);
15044 : 0 : switch (TREE_CODE (_p1))
15045 : : {
15046 : 0 : case INTEGER_CST:
15047 : 0 : {
15048 : 0 : {
15049 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1 };
15050 : 0 : if (gimple_simplify_362 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
15051 : 0 : return true;
15052 : : }
15053 : 0 : break;
15054 : : }
15055 : : default:;
15056 : : }
15057 : : }
15058 : : break;
15059 : 28 : case CFN_BUILT_IN_CTZLL:
15060 : 28 : if (gimple_call_num_args (_c1) == 1)
15061 : : {
15062 : 28 : tree _q20 = gimple_call_arg (_c1, 0);
15063 : 28 : _q20 = do_valueize (valueize, _q20);
15064 : 28 : switch (TREE_CODE (_p1))
15065 : : {
15066 : 0 : case INTEGER_CST:
15067 : 0 : {
15068 : 0 : {
15069 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
15070 : 0 : if (gimple_simplify_361 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR, CFN_BUILT_IN_CTZLL))
15071 : 0 : return true;
15072 : : }
15073 : 0 : break;
15074 : : }
15075 : : default:;
15076 : : }
15077 : : }
15078 : : break;
15079 : : default:;
15080 : : }
15081 : : }
15082 : : break;
15083 : : default:;
15084 : : }
15085 : : return false;
15086 : : }
15087 : :
15088 : : bool
15089 : 73 : gimple_simplify_CFN_BUILT_IN_POWIL (gimple_match_op *res_op, gimple_seq *seq,
15090 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
15091 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0, tree _p1)
15092 : : {
15093 : 73 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
15094 : 73 : switch (TREE_CODE (_p0))
15095 : : {
15096 : 44 : case SSA_NAME:
15097 : 44 : if (gimple *_d1 = get_def (valueize, _p0))
15098 : : {
15099 : 34 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
15100 : 2 : switch (gimple_assign_rhs_code (_a1))
15101 : : {
15102 : 0 : case NEGATE_EXPR:
15103 : 0 : {
15104 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
15105 : 0 : _q20 = do_valueize (valueize, _q20);
15106 : 0 : switch (TREE_CODE (_p1))
15107 : : {
15108 : 0 : case INTEGER_CST:
15109 : 0 : {
15110 : 0 : {
15111 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _p1 };
15112 : 0 : if ((wi::to_wide (captures[1]) & 1) == 0
15113 : : )
15114 : : {
15115 : 0 : gimple_seq *lseq = seq;
15116 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2054;
15117 : 0 : {
15118 : 0 : res_op->set_op (CFN_BUILT_IN_POWIL, type, 2);
15119 : 0 : res_op->ops[0] = captures[0];
15120 : 0 : res_op->ops[1] = captures[1];
15121 : 0 : res_op->resimplify (lseq, valueize);
15122 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1052, __FILE__, __LINE__, true);
15123 : 0 : return true;
15124 : : }
15125 : 0 : next_after_fail2054:;
15126 : : }
15127 : : }
15128 : 0 : break;
15129 : : }
15130 : : default:;
15131 : : }
15132 : : break;
15133 : : }
15134 : 0 : case ABS_EXPR:
15135 : 0 : {
15136 : 0 : tree _q20 = gimple_assign_rhs1 (_a1);
15137 : 0 : _q20 = do_valueize (valueize, _q20);
15138 : 0 : switch (TREE_CODE (_p1))
15139 : : {
15140 : 0 : case INTEGER_CST:
15141 : 0 : {
15142 : 0 : {
15143 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _p1 };
15144 : 0 : if ((wi::to_wide (captures[1]) & 1) == 0
15145 : : )
15146 : : {
15147 : 0 : gimple_seq *lseq = seq;
15148 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2055;
15149 : 0 : {
15150 : 0 : res_op->set_op (CFN_BUILT_IN_POWIL, type, 2);
15151 : 0 : res_op->ops[0] = captures[0];
15152 : 0 : res_op->ops[1] = captures[1];
15153 : 0 : res_op->resimplify (lseq, valueize);
15154 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1052, __FILE__, __LINE__, true);
15155 : 0 : return true;
15156 : : }
15157 : 0 : next_after_fail2055:;
15158 : : }
15159 : : }
15160 : 0 : break;
15161 : : }
15162 : : default:;
15163 : : }
15164 : : break;
15165 : : }
15166 : : default:;
15167 : : }
15168 : 32 : else if (gcall *_c1 = dyn_cast <gcall *> (_d1))
15169 : 0 : switch (gimple_call_combined_fn (_c1))
15170 : : {
15171 : 0 : case CFN_BUILT_IN_COPYSIGN:
15172 : 0 : if (gimple_call_num_args (_c1) == 2)
15173 : : {
15174 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
15175 : 0 : _q20 = do_valueize (valueize, _q20);
15176 : 0 : tree _q21 = gimple_call_arg (_c1, 1);
15177 : 0 : _q21 = do_valueize (valueize, _q21);
15178 : 0 : switch (TREE_CODE (_p1))
15179 : : {
15180 : 0 : case INTEGER_CST:
15181 : 0 : {
15182 : 0 : {
15183 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
15184 : 0 : const combined_fn copysigns = CFN_BUILT_IN_COPYSIGN;
15185 : 0 : if ((wi::to_wide (captures[2]) & 1) == 0
15186 : : )
15187 : : {
15188 : 0 : gimple_seq *lseq = seq;
15189 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2056;
15190 : 0 : {
15191 : 0 : res_op->set_op (CFN_BUILT_IN_POWIL, type, 2);
15192 : 0 : res_op->ops[0] = captures[0];
15193 : 0 : res_op->ops[1] = captures[2];
15194 : 0 : res_op->resimplify (lseq, valueize);
15195 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1053, __FILE__, __LINE__, true);
15196 : 0 : return true;
15197 : : }
15198 : 0 : next_after_fail2056:;
15199 : : }
15200 : : }
15201 : 0 : break;
15202 : : }
15203 : : default:;
15204 : : }
15205 : : }
15206 : : break;
15207 : 0 : case CFN_BUILT_IN_COPYSIGNF:
15208 : 0 : if (gimple_call_num_args (_c1) == 2)
15209 : : {
15210 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
15211 : 0 : _q20 = do_valueize (valueize, _q20);
15212 : 0 : tree _q21 = gimple_call_arg (_c1, 1);
15213 : 0 : _q21 = do_valueize (valueize, _q21);
15214 : 0 : switch (TREE_CODE (_p1))
15215 : : {
15216 : 0 : case INTEGER_CST:
15217 : 0 : {
15218 : 0 : {
15219 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
15220 : 0 : const combined_fn copysigns = CFN_BUILT_IN_COPYSIGNF;
15221 : 0 : if ((wi::to_wide (captures[2]) & 1) == 0
15222 : : )
15223 : : {
15224 : 0 : gimple_seq *lseq = seq;
15225 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2057;
15226 : 0 : {
15227 : 0 : res_op->set_op (CFN_BUILT_IN_POWIL, type, 2);
15228 : 0 : res_op->ops[0] = captures[0];
15229 : 0 : res_op->ops[1] = captures[2];
15230 : 0 : res_op->resimplify (lseq, valueize);
15231 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1053, __FILE__, __LINE__, true);
15232 : 0 : return true;
15233 : : }
15234 : 0 : next_after_fail2057:;
15235 : : }
15236 : : }
15237 : 0 : break;
15238 : : }
15239 : : default:;
15240 : : }
15241 : : }
15242 : : break;
15243 : 0 : case CFN_BUILT_IN_COPYSIGNL:
15244 : 0 : if (gimple_call_num_args (_c1) == 2)
15245 : : {
15246 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
15247 : 0 : _q20 = do_valueize (valueize, _q20);
15248 : 0 : tree _q21 = gimple_call_arg (_c1, 1);
15249 : 0 : _q21 = do_valueize (valueize, _q21);
15250 : 0 : switch (TREE_CODE (_p1))
15251 : : {
15252 : 0 : case INTEGER_CST:
15253 : 0 : {
15254 : 0 : {
15255 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
15256 : 0 : const combined_fn copysigns = CFN_BUILT_IN_COPYSIGNL;
15257 : 0 : if ((wi::to_wide (captures[2]) & 1) == 0
15258 : : )
15259 : : {
15260 : 0 : gimple_seq *lseq = seq;
15261 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2058;
15262 : 0 : {
15263 : 0 : res_op->set_op (CFN_BUILT_IN_POWIL, type, 2);
15264 : 0 : res_op->ops[0] = captures[0];
15265 : 0 : res_op->ops[1] = captures[2];
15266 : 0 : res_op->resimplify (lseq, valueize);
15267 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1053, __FILE__, __LINE__, true);
15268 : 0 : return true;
15269 : : }
15270 : 0 : next_after_fail2058:;
15271 : : }
15272 : : }
15273 : 0 : break;
15274 : : }
15275 : : default:;
15276 : : }
15277 : : }
15278 : : break;
15279 : 0 : case CFN_COPYSIGN:
15280 : 0 : if (gimple_call_num_args (_c1) == 2)
15281 : : {
15282 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
15283 : 0 : _q20 = do_valueize (valueize, _q20);
15284 : 0 : tree _q21 = gimple_call_arg (_c1, 1);
15285 : 0 : _q21 = do_valueize (valueize, _q21);
15286 : 0 : switch (TREE_CODE (_p1))
15287 : : {
15288 : 0 : case INTEGER_CST:
15289 : 0 : {
15290 : 0 : {
15291 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
15292 : 0 : const combined_fn copysigns = CFN_COPYSIGN;
15293 : 0 : if ((wi::to_wide (captures[2]) & 1) == 0
15294 : : )
15295 : : {
15296 : 0 : gimple_seq *lseq = seq;
15297 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2059;
15298 : 0 : {
15299 : 0 : res_op->set_op (CFN_BUILT_IN_POWIL, type, 2);
15300 : 0 : res_op->ops[0] = captures[0];
15301 : 0 : res_op->ops[1] = captures[2];
15302 : 0 : res_op->resimplify (lseq, valueize);
15303 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1053, __FILE__, __LINE__, true);
15304 : 0 : return true;
15305 : : }
15306 : 0 : next_after_fail2059:;
15307 : : }
15308 : : }
15309 : 0 : break;
15310 : : }
15311 : : default:;
15312 : : }
15313 : : }
15314 : : break;
15315 : : default:;
15316 : : }
15317 : : }
15318 : : break;
15319 : 73 : default:;
15320 : : }
15321 : 73 : if (real_onep (_p0))
15322 : : {
15323 : 0 : {
15324 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
15325 : 0 : if (gimple_simplify_404 (res_op, seq, valueize, type, captures))
15326 : 0 : return true;
15327 : : }
15328 : : }
15329 : 73 : switch (TREE_CODE (_p1))
15330 : : {
15331 : 33 : case INTEGER_CST:
15332 : 33 : {
15333 : 33 : {
15334 : 33 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
15335 : 33 : if (wi::to_wide (captures[1]) == 0
15336 : : )
15337 : : {
15338 : 1 : gimple_seq *lseq = seq;
15339 : 1 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2060;
15340 : 1 : {
15341 : 1 : tree tem;
15342 : 1 : tem = build_real (type, dconst1);
15343 : 1 : res_op->set_value (tem);
15344 : 1 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1054, __FILE__, __LINE__, true);
15345 : 1 : return true;
15346 : : }
15347 : 0 : next_after_fail2060:;
15348 : : }
15349 : : else
15350 : : {
15351 : 32 : if (wi::to_wide (captures[1]) == 1
15352 : : )
15353 : : {
15354 : 1 : gimple_seq *lseq = seq;
15355 : 1 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2061;
15356 : 1 : {
15357 : 1 : tree tem;
15358 : 1 : tem = captures[0];
15359 : 1 : res_op->set_value (tem);
15360 : 1 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1055, __FILE__, __LINE__, true);
15361 : 1 : return true;
15362 : : }
15363 : 0 : next_after_fail2061:;
15364 : : }
15365 : : else
15366 : : {
15367 : 31 : if (wi::to_wide (captures[1]) == -1
15368 : : )
15369 : : {
15370 : 1 : gimple_seq *lseq = seq;
15371 : 1 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2062;
15372 : 1 : {
15373 : 1 : res_op->set_op (RDIV_EXPR, type, 2);
15374 : 1 : res_op->ops[0] = build_real (type, dconst1);
15375 : 1 : res_op->ops[1] = captures[0];
15376 : 1 : res_op->resimplify (lseq, valueize);
15377 : 1 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1056, __FILE__, __LINE__, true);
15378 : 1 : return true;
15379 : : }
15380 : 0 : next_after_fail2062:;
15381 : : }
15382 : : }
15383 : : }
15384 : : }
15385 : 30 : break;
15386 : : }
15387 : : default:;
15388 : : }
15389 : : return false;
15390 : : }
15391 : :
15392 : : bool
15393 : 8205480 : gimple_simplify_BIT_AND_EXPR (gimple_match_op *res_op, gimple_seq *seq,
15394 : : tree (*valueize)(tree) ATTRIBUTE_UNUSED,
15395 : : code_helper ARG_UNUSED (code), tree ARG_UNUSED (type), tree _p0, tree _p1)
15396 : : {
15397 : 8205480 : const bool debug_dump = dump_file && (dump_flags & TDF_FOLDING);
15398 : 8205480 : switch (TREE_CODE (_p0))
15399 : : {
15400 : 8115710 : case SSA_NAME:
15401 : 8115710 : if (gimple *_d1 = get_def (valueize, _p0))
15402 : : {
15403 : 5553121 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
15404 : 5879796 : switch (gimple_assign_rhs_code (_a1))
15405 : : {
15406 : 62257 : case LSHIFT_EXPR:
15407 : 62257 : {
15408 : 62257 : tree _q20 = gimple_assign_rhs1 (_a1);
15409 : 62257 : _q20 = do_valueize (valueize, _q20);
15410 : 62257 : tree _q21 = gimple_assign_rhs2 (_a1);
15411 : 62257 : _q21 = do_valueize (valueize, _q21);
15412 : 62257 : switch (TREE_CODE (_p1))
15413 : : {
15414 : 11814 : case SSA_NAME:
15415 : 11814 : if (gimple *_d2 = get_def (valueize, _p1))
15416 : : {
15417 : 11184 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
15418 : 15950 : switch (gimple_assign_rhs_code (_a2))
15419 : : {
15420 : 21 : case LSHIFT_EXPR:
15421 : 21 : {
15422 : 21 : tree _q50 = gimple_assign_rhs1 (_a2);
15423 : 21 : _q50 = do_valueize (valueize, _q50);
15424 : 21 : tree _q51 = gimple_assign_rhs2 (_a2);
15425 : 21 : _q51 = do_valueize (valueize, _q51);
15426 : 21 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
15427 : : {
15428 : 3 : {
15429 : 3 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
15430 : 3 : if (gimple_simplify_3 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
15431 : 0 : return true;
15432 : : }
15433 : : }
15434 : : break;
15435 : : }
15436 : : default:;
15437 : : }
15438 : : }
15439 : : break;
15440 : : default:;
15441 : : }
15442 : : break;
15443 : : }
15444 : 213169 : case RSHIFT_EXPR:
15445 : 213169 : {
15446 : 213169 : tree _q20 = gimple_assign_rhs1 (_a1);
15447 : 213169 : _q20 = do_valueize (valueize, _q20);
15448 : 213169 : tree _q21 = gimple_assign_rhs2 (_a1);
15449 : 213169 : _q21 = do_valueize (valueize, _q21);
15450 : 213169 : switch (TREE_CODE (_p1))
15451 : : {
15452 : 5946 : case SSA_NAME:
15453 : 5946 : if (gimple *_d2 = get_def (valueize, _p1))
15454 : : {
15455 : 5677 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
15456 : 5087 : switch (gimple_assign_rhs_code (_a2))
15457 : : {
15458 : 93 : case RSHIFT_EXPR:
15459 : 93 : {
15460 : 93 : tree _q50 = gimple_assign_rhs1 (_a2);
15461 : 93 : _q50 = do_valueize (valueize, _q50);
15462 : 93 : tree _q51 = gimple_assign_rhs2 (_a2);
15463 : 93 : _q51 = do_valueize (valueize, _q51);
15464 : 93 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
15465 : : {
15466 : 69 : {
15467 : 69 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
15468 : 69 : if (gimple_simplify_4 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
15469 : 19 : return true;
15470 : : }
15471 : : }
15472 : : break;
15473 : : }
15474 : : default:;
15475 : : }
15476 : : }
15477 : : break;
15478 : : default:;
15479 : : }
15480 : : break;
15481 : : }
15482 : 413904 : CASE_CONVERT:
15483 : 413904 : {
15484 : 413904 : tree _q20 = gimple_assign_rhs1 (_a1);
15485 : 413904 : _q20 = do_valueize (valueize, _q20);
15486 : 413904 : switch (TREE_CODE (_p1))
15487 : : {
15488 : 78653 : case SSA_NAME:
15489 : 78653 : if (gimple *_d2 = get_def (valueize, _p1))
15490 : : {
15491 : 75821 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
15492 : 57613 : switch (gimple_assign_rhs_code (_a2))
15493 : : {
15494 : 25343 : CASE_CONVERT:
15495 : 25343 : {
15496 : 25343 : tree _q40 = gimple_assign_rhs1 (_a2);
15497 : 25343 : _q40 = do_valueize (valueize, _q40);
15498 : 25343 : {
15499 : 25343 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q40 };
15500 : 25343 : if (gimple_simplify_415 (res_op, seq, valueize, type, captures))
15501 : 2 : return true;
15502 : : }
15503 : 25341 : break;
15504 : : }
15505 : : default:;
15506 : : }
15507 : : }
15508 : : break;
15509 : : default:;
15510 : : }
15511 : : break;
15512 : : }
15513 : : default:;
15514 : : }
15515 : : }
15516 : : break;
15517 : 8205459 : default:;
15518 : : }
15519 : 8205459 : {
15520 : 8205459 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
15521 : 8205459 : if (gimple_simplify_415 (res_op, seq, valueize, type, captures))
15522 : 1692 : return true;
15523 : : }
15524 : 8203767 : switch (TREE_CODE (_p1))
15525 : : {
15526 : 2724879 : case SSA_NAME:
15527 : 2724879 : if (gimple *_d1 = get_def (valueize, _p1))
15528 : : {
15529 : 2138236 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
15530 : 2074831 : switch (gimple_assign_rhs_code (_a1))
15531 : : {
15532 : 91658 : case PLUS_EXPR:
15533 : 91658 : {
15534 : 91658 : tree _q30 = gimple_assign_rhs1 (_a1);
15535 : 91658 : _q30 = do_valueize (valueize, _q30);
15536 : 91658 : tree _q31 = gimple_assign_rhs2 (_a1);
15537 : 91658 : _q31 = do_valueize (valueize, _q31);
15538 : 91658 : if (tree_swap_operands_p (_q30, _q31))
15539 : 4563 : std::swap (_q30, _q31);
15540 : 91658 : switch (TREE_CODE (_q30))
15541 : : {
15542 : 91658 : case SSA_NAME:
15543 : 91658 : if (gimple *_d2 = get_def (valueize, _q30))
15544 : : {
15545 : 85799 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
15546 : 82078 : switch (gimple_assign_rhs_code (_a2))
15547 : : {
15548 : 3710 : case LSHIFT_EXPR:
15549 : 3710 : {
15550 : 3710 : tree _q40 = gimple_assign_rhs1 (_a2);
15551 : 3710 : _q40 = do_valueize (valueize, _q40);
15552 : 3710 : tree _q41 = gimple_assign_rhs2 (_a2);
15553 : 3710 : _q41 = do_valueize (valueize, _q41);
15554 : 3710 : if (integer_onep (_q40))
15555 : : {
15556 : 3654 : if (integer_minus_onep (_q31))
15557 : : {
15558 : 3633 : {
15559 : 3633 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q41 };
15560 : 3633 : if (TYPE_UNSIGNED (type)
15561 : : )
15562 : : {
15563 : 3260 : gimple_seq *lseq = seq;
15564 : 3260 : if (lseq
15565 : 1318 : && (!single_use (captures[1])
15566 : 419 : || !single_use (captures[2])))
15567 : 2935 : lseq = NULL;
15568 : 3260 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2079;
15569 : 3260 : {
15570 : 3260 : res_op->set_op (BIT_AND_EXPR, type, 2);
15571 : 3260 : res_op->ops[0] = captures[0];
15572 : 3260 : {
15573 : 3260 : tree _o1[1], _r1;
15574 : 3260 : {
15575 : 3260 : tree _o2[2], _r2;
15576 : 3260 : _o2[0] = build_all_ones_cst (type);
15577 : 3260 : _o2[1] = captures[3];
15578 : 3260 : gimple_match_op tem_op (res_op->cond.any_else (), LSHIFT_EXPR, TREE_TYPE (_o2[0]), _o2[0], _o2[1]);
15579 : 3260 : tem_op.resimplify (lseq, valueize);
15580 : 3260 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
15581 : 3260 : if (!_r2) goto next_after_fail2079;
15582 : 325 : _o1[0] = _r2;
15583 : : }
15584 : 325 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_NOT_EXPR, TREE_TYPE (_o1[0]), _o1[0]);
15585 : 325 : tem_op.resimplify (lseq, valueize);
15586 : 325 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
15587 : 325 : if (!_r1) goto next_after_fail2079;
15588 : 325 : res_op->ops[1] = _r1;
15589 : : }
15590 : 325 : res_op->resimplify (lseq, valueize);
15591 : 325 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1059, __FILE__, __LINE__, true);
15592 : 325 : return true;
15593 : : }
15594 : 3308 : next_after_fail2079:;
15595 : : }
15596 : : }
15597 : : }
15598 : : }
15599 : : break;
15600 : : }
15601 : : default:;
15602 : : }
15603 : : }
15604 : : break;
15605 : : default:;
15606 : : }
15607 : 8203442 : break;
15608 : : }
15609 : : default:;
15610 : : }
15611 : : }
15612 : : break;
15613 : 8203442 : default:;
15614 : : }
15615 : 8203442 : switch (TREE_CODE (_p0))
15616 : : {
15617 : 8113672 : case SSA_NAME:
15618 : 8113672 : if (gimple *_d1 = get_def (valueize, _p0))
15619 : : {
15620 : 5551187 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
15621 : 5877818 : switch (gimple_assign_rhs_code (_a1))
15622 : : {
15623 : 372509 : case PLUS_EXPR:
15624 : 372509 : {
15625 : 372509 : tree _q20 = gimple_assign_rhs1 (_a1);
15626 : 372509 : _q20 = do_valueize (valueize, _q20);
15627 : 372509 : tree _q21 = gimple_assign_rhs2 (_a1);
15628 : 372509 : _q21 = do_valueize (valueize, _q21);
15629 : 372509 : if (tree_swap_operands_p (_q20, _q21))
15630 : 10801 : std::swap (_q20, _q21);
15631 : 372509 : switch (TREE_CODE (_q20))
15632 : : {
15633 : 372509 : case SSA_NAME:
15634 : 372509 : if (gimple *_d2 = get_def (valueize, _q20))
15635 : : {
15636 : 353829 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
15637 : 321820 : switch (gimple_assign_rhs_code (_a2))
15638 : : {
15639 : 6189 : case LSHIFT_EXPR:
15640 : 6189 : {
15641 : 6189 : tree _q30 = gimple_assign_rhs1 (_a2);
15642 : 6189 : _q30 = do_valueize (valueize, _q30);
15643 : 6189 : tree _q31 = gimple_assign_rhs2 (_a2);
15644 : 6189 : _q31 = do_valueize (valueize, _q31);
15645 : 6189 : if (integer_onep (_q30))
15646 : : {
15647 : 4911 : if (integer_minus_onep (_q21))
15648 : : {
15649 : 4352 : {
15650 : 4352 : tree captures[4] ATTRIBUTE_UNUSED = { _p1, _p0, _q20, _q31 };
15651 : 4352 : if (TYPE_UNSIGNED (type)
15652 : : )
15653 : : {
15654 : 3470 : gimple_seq *lseq = seq;
15655 : 3470 : if (lseq
15656 : 1072 : && (!single_use (captures[1])
15657 : 188 : || !single_use (captures[2])))
15658 : 3326 : lseq = NULL;
15659 : 3470 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2080;
15660 : 3470 : {
15661 : 3470 : res_op->set_op (BIT_AND_EXPR, type, 2);
15662 : 3470 : res_op->ops[0] = captures[0];
15663 : 3470 : {
15664 : 3470 : tree _o1[1], _r1;
15665 : 3470 : {
15666 : 3470 : tree _o2[2], _r2;
15667 : 3470 : _o2[0] = build_all_ones_cst (type);
15668 : 3470 : _o2[1] = captures[3];
15669 : 3470 : gimple_match_op tem_op (res_op->cond.any_else (), LSHIFT_EXPR, TREE_TYPE (_o2[0]), _o2[0], _o2[1]);
15670 : 3470 : tem_op.resimplify (lseq, valueize);
15671 : 3470 : _r2 = maybe_push_res_to_seq (&tem_op, lseq);
15672 : 3470 : if (!_r2) goto next_after_fail2080;
15673 : 144 : _o1[0] = _r2;
15674 : : }
15675 : 144 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_NOT_EXPR, TREE_TYPE (_o1[0]), _o1[0]);
15676 : 144 : tem_op.resimplify (lseq, valueize);
15677 : 144 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
15678 : 144 : if (!_r1) goto next_after_fail2080;
15679 : 144 : res_op->ops[1] = _r1;
15680 : : }
15681 : 144 : res_op->resimplify (lseq, valueize);
15682 : 144 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1059, __FILE__, __LINE__, true);
15683 : 144 : return true;
15684 : : }
15685 : 4208 : next_after_fail2080:;
15686 : : }
15687 : : }
15688 : : }
15689 : : }
15690 : : break;
15691 : : }
15692 : : default:;
15693 : : }
15694 : : }
15695 : : break;
15696 : : default:;
15697 : : }
15698 : 8202882 : break;
15699 : : }
15700 : 290694 : case EQ_EXPR:
15701 : 290694 : {
15702 : 290694 : tree _q20 = gimple_assign_rhs1 (_a1);
15703 : 290694 : _q20 = do_valueize (valueize, _q20);
15704 : 290694 : tree _q21 = gimple_assign_rhs2 (_a1);
15705 : 290694 : _q21 = do_valueize (valueize, _q21);
15706 : 290694 : if (tree_swap_operands_p (_q20, _q21))
15707 : 6051 : std::swap (_q20, _q21);
15708 : 290694 : if (integer_zerop (_q21))
15709 : : {
15710 : 96808 : switch (TREE_CODE (_p1))
15711 : : {
15712 : 95056 : case SSA_NAME:
15713 : 95056 : if (gimple *_d2 = get_def (valueize, _p1))
15714 : : {
15715 : 94319 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
15716 : 94136 : switch (gimple_assign_rhs_code (_a2))
15717 : : {
15718 : 19204 : case EQ_EXPR:
15719 : 19204 : {
15720 : 19204 : tree _q50 = gimple_assign_rhs1 (_a2);
15721 : 19204 : _q50 = do_valueize (valueize, _q50);
15722 : 19204 : tree _q51 = gimple_assign_rhs2 (_a2);
15723 : 19204 : _q51 = do_valueize (valueize, _q51);
15724 : 19204 : if (tree_swap_operands_p (_q50, _q51))
15725 : 15 : std::swap (_q50, _q51);
15726 : 19204 : if (integer_zerop (_q51))
15727 : : {
15728 : 10094 : {
15729 : 10094 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _q50 };
15730 : 10094 : if (gimple_simplify_100 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, EQ_EXPR))
15731 : 373 : return true;
15732 : : }
15733 : : }
15734 : 290321 : break;
15735 : : }
15736 : : default:;
15737 : : }
15738 : : }
15739 : : break;
15740 : : default:;
15741 : : }
15742 : : }
15743 : 290321 : if (integer_all_onesp (_q21))
15744 : : {
15745 : 22714 : switch (TREE_CODE (_p1))
15746 : : {
15747 : 21974 : case SSA_NAME:
15748 : 21974 : if (gimple *_d2 = get_def (valueize, _p1))
15749 : : {
15750 : 21955 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
15751 : 21296 : switch (gimple_assign_rhs_code (_a2))
15752 : : {
15753 : 14633 : case EQ_EXPR:
15754 : 14633 : {
15755 : 14633 : tree _q50 = gimple_assign_rhs1 (_a2);
15756 : 14633 : _q50 = do_valueize (valueize, _q50);
15757 : 14633 : tree _q51 = gimple_assign_rhs2 (_a2);
15758 : 14633 : _q51 = do_valueize (valueize, _q51);
15759 : 14633 : if (tree_swap_operands_p (_q50, _q51))
15760 : 1064 : std::swap (_q50, _q51);
15761 : 14633 : if (integer_all_onesp (_q51))
15762 : : {
15763 : 246 : {
15764 : 246 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _q50 };
15765 : 246 : if (gimple_simplify_101 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, EQ_EXPR))
15766 : 19 : return true;
15767 : : }
15768 : : }
15769 : 290302 : break;
15770 : : }
15771 : : default:;
15772 : : }
15773 : : }
15774 : : break;
15775 : : default:;
15776 : : }
15777 : : }
15778 : 290302 : switch (TREE_CODE (_p1))
15779 : : {
15780 : 281548 : case SSA_NAME:
15781 : 281548 : if (gimple *_d2 = get_def (valueize, _p1))
15782 : : {
15783 : 279914 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
15784 : 277100 : switch (gimple_assign_rhs_code (_a2))
15785 : : {
15786 : 282 : case BIT_IOR_EXPR:
15787 : 282 : {
15788 : 282 : tree _q50 = gimple_assign_rhs1 (_a2);
15789 : 282 : _q50 = do_valueize (valueize, _q50);
15790 : 282 : tree _q51 = gimple_assign_rhs2 (_a2);
15791 : 282 : _q51 = do_valueize (valueize, _q51);
15792 : 282 : if (tree_swap_operands_p (_q50, _q51))
15793 : 10 : std::swap (_q50, _q51);
15794 : 282 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
15795 : : {
15796 : 1 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
15797 : : {
15798 : 1 : {
15799 : 1 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
15800 : 1 : if (gimple_simplify_416 (res_op, seq, valueize, type, captures))
15801 : 1 : return true;
15802 : : }
15803 : : }
15804 : : }
15805 : 281 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
15806 : : {
15807 : 0 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
15808 : : {
15809 : 0 : {
15810 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q21, _q20 };
15811 : 0 : if (gimple_simplify_416 (res_op, seq, valueize, type, captures))
15812 : 0 : return true;
15813 : : }
15814 : : }
15815 : : }
15816 : 290301 : break;
15817 : : }
15818 : : default:;
15819 : : }
15820 : : }
15821 : : break;
15822 : 290301 : default:;
15823 : : }
15824 : 290301 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
15825 : : {
15826 : 0 : {
15827 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
15828 : 0 : if (gimple_simplify_417 (res_op, seq, valueize, type, captures))
15829 : 0 : return true;
15830 : : }
15831 : : }
15832 : 290301 : if ((_p1 == _q21 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q21, 0) && types_match (_p1, _q21)))
15833 : : {
15834 : 0 : {
15835 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q21, _q20 };
15836 : 0 : if (gimple_simplify_417 (res_op, seq, valueize, type, captures))
15837 : 0 : return true;
15838 : : }
15839 : : }
15840 : 8202882 : break;
15841 : : }
15842 : 152167 : case BIT_IOR_EXPR:
15843 : 152167 : {
15844 : 152167 : tree _q20 = gimple_assign_rhs1 (_a1);
15845 : 152167 : _q20 = do_valueize (valueize, _q20);
15846 : 152167 : tree _q21 = gimple_assign_rhs2 (_a1);
15847 : 152167 : _q21 = do_valueize (valueize, _q21);
15848 : 152167 : if (tree_swap_operands_p (_q20, _q21))
15849 : 8562 : std::swap (_q20, _q21);
15850 : 152167 : switch (TREE_CODE (_p1))
15851 : : {
15852 : 117779 : case SSA_NAME:
15853 : 117779 : if (gimple *_d2 = get_def (valueize, _p1))
15854 : : {
15855 : 113574 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
15856 : 110064 : switch (gimple_assign_rhs_code (_a2))
15857 : : {
15858 : 101839 : case BIT_NOT_EXPR:
15859 : 101839 : {
15860 : 101839 : tree _q50 = gimple_assign_rhs1 (_a2);
15861 : 101839 : _q50 = do_valueize (valueize, _q50);
15862 : 101839 : switch (TREE_CODE (_q50))
15863 : : {
15864 : 101839 : case SSA_NAME:
15865 : 101839 : if (gimple *_d3 = get_def (valueize, _q50))
15866 : : {
15867 : 85865 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
15868 : 85886 : switch (gimple_assign_rhs_code (_a3))
15869 : : {
15870 : 14 : case BIT_XOR_EXPR:
15871 : 14 : {
15872 : 14 : tree _q60 = gimple_assign_rhs1 (_a3);
15873 : 14 : _q60 = do_valueize (valueize, _q60);
15874 : 14 : tree _q61 = gimple_assign_rhs2 (_a3);
15875 : 14 : _q61 = do_valueize (valueize, _q61);
15876 : 14 : if (tree_swap_operands_p (_q60, _q61))
15877 : 2 : std::swap (_q60, _q61);
15878 : 14 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
15879 : : {
15880 : 9 : if ((_q61 == _q21 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q21, 0) && types_match (_q61, _q21)))
15881 : : {
15882 : 9 : {
15883 : 9 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
15884 : 9 : if (gimple_simplify_418 (res_op, seq, valueize, type, captures))
15885 : 9 : return true;
15886 : : }
15887 : : }
15888 : : }
15889 : 5 : if ((_q60 == _q21 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q21, 0) && types_match (_q60, _q21)))
15890 : : {
15891 : 0 : if ((_q61 == _q20 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q20, 0) && types_match (_q61, _q20)))
15892 : : {
15893 : 0 : {
15894 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
15895 : 0 : if (gimple_simplify_418 (res_op, seq, valueize, type, captures))
15896 : 0 : return true;
15897 : : }
15898 : : }
15899 : : }
15900 : 152155 : break;
15901 : : }
15902 : : default:;
15903 : : }
15904 : : }
15905 : : break;
15906 : : default:;
15907 : : }
15908 : : break;
15909 : : }
15910 : 127 : case EQ_EXPR:
15911 : 127 : {
15912 : 127 : tree _q50 = gimple_assign_rhs1 (_a2);
15913 : 127 : _q50 = do_valueize (valueize, _q50);
15914 : 127 : tree _q51 = gimple_assign_rhs2 (_a2);
15915 : 127 : _q51 = do_valueize (valueize, _q51);
15916 : 127 : if (tree_swap_operands_p (_q50, _q51))
15917 : 0 : std::swap (_q50, _q51);
15918 : 127 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
15919 : : {
15920 : 3 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
15921 : : {
15922 : 3 : {
15923 : 3 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
15924 : 3 : if (gimple_simplify_416 (res_op, seq, valueize, type, captures))
15925 : 3 : return true;
15926 : : }
15927 : : }
15928 : : }
15929 : 124 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
15930 : : {
15931 : 0 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
15932 : : {
15933 : 0 : {
15934 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
15935 : 0 : if (gimple_simplify_416 (res_op, seq, valueize, type, captures))
15936 : 0 : return true;
15937 : : }
15938 : : }
15939 : : }
15940 : 152155 : break;
15941 : : }
15942 : : default:;
15943 : : }
15944 : : }
15945 : : break;
15946 : 152155 : default:;
15947 : : }
15948 : 152155 : {
15949 : 152155 : tree _p1_pops[1];
15950 : 152155 : if (gimple_nop_convert (_p1, _p1_pops, valueize))
15951 : : {
15952 : 398 : tree _q50 = _p1_pops[0];
15953 : 398 : switch (TREE_CODE (_q50))
15954 : : {
15955 : 398 : case SSA_NAME:
15956 : 398 : if (gimple *_d2 = get_def (valueize, _q50))
15957 : : {
15958 : 382 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
15959 : 487 : switch (gimple_assign_rhs_code (_a2))
15960 : : {
15961 : 0 : case EQ_EXPR:
15962 : 0 : {
15963 : 0 : tree _q60 = gimple_assign_rhs1 (_a2);
15964 : 0 : _q60 = do_valueize (valueize, _q60);
15965 : 0 : tree _q61 = gimple_assign_rhs2 (_a2);
15966 : 0 : _q61 = do_valueize (valueize, _q61);
15967 : 0 : if (tree_swap_operands_p (_q60, _q61))
15968 : 0 : std::swap (_q60, _q61);
15969 : 0 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
15970 : : {
15971 : 0 : if ((_q61 == _q21 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q21, 0) && types_match (_q61, _q21)))
15972 : : {
15973 : 0 : {
15974 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
15975 : 0 : if (gimple_simplify_416 (res_op, seq, valueize, type, captures))
15976 : 0 : return true;
15977 : : }
15978 : : }
15979 : : }
15980 : 0 : if ((_q60 == _q21 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q21, 0) && types_match (_q60, _q21)))
15981 : : {
15982 : 0 : if ((_q61 == _q20 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q20, 0) && types_match (_q61, _q20)))
15983 : : {
15984 : 0 : {
15985 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
15986 : 0 : if (gimple_simplify_416 (res_op, seq, valueize, type, captures))
15987 : 0 : return true;
15988 : : }
15989 : : }
15990 : : }
15991 : 152155 : break;
15992 : : }
15993 : : default:;
15994 : : }
15995 : : }
15996 : : break;
15997 : : default:;
15998 : : }
15999 : : }
16000 : : }
16001 : 152155 : break;
16002 : : }
16003 : 53927 : case BIT_NOT_EXPR:
16004 : 53927 : {
16005 : 53927 : tree _q20 = gimple_assign_rhs1 (_a1);
16006 : 53927 : _q20 = do_valueize (valueize, _q20);
16007 : 53927 : switch (TREE_CODE (_q20))
16008 : : {
16009 : 53927 : case SSA_NAME:
16010 : 53927 : if (gimple *_d2 = get_def (valueize, _q20))
16011 : : {
16012 : 50809 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
16013 : 46612 : switch (gimple_assign_rhs_code (_a2))
16014 : : {
16015 : 531 : case BIT_XOR_EXPR:
16016 : 531 : {
16017 : 531 : tree _q30 = gimple_assign_rhs1 (_a2);
16018 : 531 : _q30 = do_valueize (valueize, _q30);
16019 : 531 : tree _q31 = gimple_assign_rhs2 (_a2);
16020 : 531 : _q31 = do_valueize (valueize, _q31);
16021 : 531 : if (tree_swap_operands_p (_q30, _q31))
16022 : 2 : std::swap (_q30, _q31);
16023 : 531 : switch (TREE_CODE (_p1))
16024 : : {
16025 : 366 : case SSA_NAME:
16026 : 366 : if (gimple *_d3 = get_def (valueize, _p1))
16027 : : {
16028 : 302 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
16029 : 302 : switch (gimple_assign_rhs_code (_a3))
16030 : : {
16031 : 10 : case BIT_IOR_EXPR:
16032 : 10 : {
16033 : 10 : tree _q60 = gimple_assign_rhs1 (_a3);
16034 : 10 : _q60 = do_valueize (valueize, _q60);
16035 : 10 : tree _q61 = gimple_assign_rhs2 (_a3);
16036 : 10 : _q61 = do_valueize (valueize, _q61);
16037 : 10 : if (tree_swap_operands_p (_q60, _q61))
16038 : 2 : std::swap (_q60, _q61);
16039 : 10 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
16040 : : {
16041 : 10 : if ((_q61 == _q31 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q31, 0) && types_match (_q61, _q31)))
16042 : : {
16043 : 10 : {
16044 : 10 : tree captures[2] ATTRIBUTE_UNUSED = { _q30, _q31 };
16045 : 10 : if (gimple_simplify_418 (res_op, seq, valueize, type, captures))
16046 : 10 : return true;
16047 : : }
16048 : : }
16049 : : }
16050 : 0 : if ((_q60 == _q31 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q31, 0) && types_match (_q60, _q31)))
16051 : : {
16052 : 0 : if ((_q61 == _q30 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q30, 0) && types_match (_q61, _q30)))
16053 : : {
16054 : 0 : {
16055 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q31, _q30 };
16056 : 0 : if (gimple_simplify_418 (res_op, seq, valueize, type, captures))
16057 : 0 : return true;
16058 : : }
16059 : : }
16060 : : }
16061 : 521 : break;
16062 : : }
16063 : : default:;
16064 : : }
16065 : : }
16066 : : break;
16067 : 521 : default:;
16068 : : }
16069 : 521 : if ((_p1 == _q30 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q30, 0) && types_match (_p1, _q30)))
16070 : : {
16071 : 0 : {
16072 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q30, _q31 };
16073 : 0 : if (gimple_simplify_419 (res_op, seq, valueize, type, captures))
16074 : 0 : return true;
16075 : : }
16076 : : }
16077 : 521 : if ((_p1 == _q31 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q31, 0) && types_match (_p1, _q31)))
16078 : : {
16079 : 1 : {
16080 : 1 : tree captures[2] ATTRIBUTE_UNUSED = { _q31, _q30 };
16081 : 1 : if (gimple_simplify_419 (res_op, seq, valueize, type, captures))
16082 : 1 : return true;
16083 : : }
16084 : : }
16085 : 8202882 : break;
16086 : : }
16087 : : default:;
16088 : : }
16089 : : }
16090 : : break;
16091 : : default:;
16092 : : }
16093 : : break;
16094 : : }
16095 : : default:;
16096 : : }
16097 : : }
16098 : : break;
16099 : 8202882 : default:;
16100 : : }
16101 : 8202882 : {
16102 : 8202882 : tree _p0_pops[1];
16103 : 8202882 : if (gimple_nop_convert (_p0, _p0_pops, valueize))
16104 : : {
16105 : 116016 : tree _q20 = _p0_pops[0];
16106 : 116016 : switch (TREE_CODE (_q20))
16107 : : {
16108 : 115075 : case SSA_NAME:
16109 : 115075 : if (gimple *_d1 = get_def (valueize, _q20))
16110 : : {
16111 : 112547 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
16112 : 108802 : switch (gimple_assign_rhs_code (_a1))
16113 : : {
16114 : 0 : case EQ_EXPR:
16115 : 0 : {
16116 : 0 : tree _q30 = gimple_assign_rhs1 (_a1);
16117 : 0 : _q30 = do_valueize (valueize, _q30);
16118 : 0 : tree _q31 = gimple_assign_rhs2 (_a1);
16119 : 0 : _q31 = do_valueize (valueize, _q31);
16120 : 0 : if (tree_swap_operands_p (_q30, _q31))
16121 : 0 : std::swap (_q30, _q31);
16122 : 0 : switch (TREE_CODE (_p1))
16123 : : {
16124 : 0 : case SSA_NAME:
16125 : 0 : if (gimple *_d2 = get_def (valueize, _p1))
16126 : : {
16127 : 0 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
16128 : 0 : switch (gimple_assign_rhs_code (_a2))
16129 : : {
16130 : 0 : case BIT_IOR_EXPR:
16131 : 0 : {
16132 : 0 : tree _q60 = gimple_assign_rhs1 (_a2);
16133 : 0 : _q60 = do_valueize (valueize, _q60);
16134 : 0 : tree _q61 = gimple_assign_rhs2 (_a2);
16135 : 0 : _q61 = do_valueize (valueize, _q61);
16136 : 0 : if (tree_swap_operands_p (_q60, _q61))
16137 : 0 : std::swap (_q60, _q61);
16138 : 0 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
16139 : : {
16140 : 0 : if ((_q61 == _q31 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q31, 0) && types_match (_q61, _q31)))
16141 : : {
16142 : 0 : {
16143 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q30, _q31 };
16144 : 0 : if (gimple_simplify_416 (res_op, seq, valueize, type, captures))
16145 : 0 : return true;
16146 : : }
16147 : : }
16148 : : }
16149 : 0 : if ((_q60 == _q31 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q31, 0) && types_match (_q60, _q31)))
16150 : : {
16151 : 0 : if ((_q61 == _q30 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q30, 0) && types_match (_q61, _q30)))
16152 : : {
16153 : 0 : {
16154 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q31, _q30 };
16155 : 0 : if (gimple_simplify_416 (res_op, seq, valueize, type, captures))
16156 : 0 : return true;
16157 : : }
16158 : : }
16159 : : }
16160 : 8202882 : break;
16161 : : }
16162 : : default:;
16163 : : }
16164 : : }
16165 : : break;
16166 : : default:;
16167 : : }
16168 : 8202882 : break;
16169 : : }
16170 : : default:;
16171 : : }
16172 : : }
16173 : : break;
16174 : : default:;
16175 : : }
16176 : : }
16177 : : }
16178 : 8202882 : switch (TREE_CODE (_p1))
16179 : : {
16180 : 2723998 : case SSA_NAME:
16181 : 2723998 : if (gimple *_d1 = get_def (valueize, _p1))
16182 : : {
16183 : 2137380 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
16184 : 2074015 : switch (gimple_assign_rhs_code (_a1))
16185 : : {
16186 : 164433 : case BIT_NOT_EXPR:
16187 : 164433 : {
16188 : 164433 : tree _q30 = gimple_assign_rhs1 (_a1);
16189 : 164433 : _q30 = do_valueize (valueize, _q30);
16190 : 164433 : switch (TREE_CODE (_q30))
16191 : : {
16192 : 164433 : case SSA_NAME:
16193 : 164433 : if (gimple *_d2 = get_def (valueize, _q30))
16194 : : {
16195 : 140654 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
16196 : 137285 : switch (gimple_assign_rhs_code (_a2))
16197 : : {
16198 : 2070 : case BIT_XOR_EXPR:
16199 : 2070 : {
16200 : 2070 : tree _q40 = gimple_assign_rhs1 (_a2);
16201 : 2070 : _q40 = do_valueize (valueize, _q40);
16202 : 2070 : tree _q41 = gimple_assign_rhs2 (_a2);
16203 : 2070 : _q41 = do_valueize (valueize, _q41);
16204 : 2070 : if (tree_swap_operands_p (_q40, _q41))
16205 : 20 : std::swap (_q40, _q41);
16206 : 2070 : if ((_q40 == _p0 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _p0, 0) && types_match (_q40, _p0)))
16207 : : {
16208 : 0 : {
16209 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q41 };
16210 : 0 : if (gimple_simplify_419 (res_op, seq, valueize, type, captures))
16211 : 0 : return true;
16212 : : }
16213 : : }
16214 : 2070 : if ((_q41 == _p0 && ! TREE_SIDE_EFFECTS (_q41)) || (operand_equal_p (_q41, _p0, 0) && types_match (_q41, _p0)))
16215 : : {
16216 : 0 : {
16217 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q40 };
16218 : 0 : if (gimple_simplify_419 (res_op, seq, valueize, type, captures))
16219 : 0 : return true;
16220 : : }
16221 : : }
16222 : 8202882 : break;
16223 : : }
16224 : : default:;
16225 : : }
16226 : : }
16227 : : break;
16228 : : default:;
16229 : : }
16230 : : break;
16231 : : }
16232 : : default:;
16233 : : }
16234 : : }
16235 : : break;
16236 : 8202882 : default:;
16237 : : }
16238 : 8202882 : {
16239 : 8202882 : tree _p1_pops[1];
16240 : 8202882 : if (gimple_nop_convert (_p1, _p1_pops, valueize))
16241 : : {
16242 : 69858 : tree _q30 = _p1_pops[0];
16243 : 69858 : switch (TREE_CODE (_q30))
16244 : : {
16245 : 69858 : case SSA_NAME:
16246 : 69858 : if (gimple *_d1 = get_def (valueize, _q30))
16247 : : {
16248 : 68121 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
16249 : 52338 : switch (gimple_assign_rhs_code (_a1))
16250 : : {
16251 : 36 : case EQ_EXPR:
16252 : 36 : {
16253 : 36 : tree _q40 = gimple_assign_rhs1 (_a1);
16254 : 36 : _q40 = do_valueize (valueize, _q40);
16255 : 36 : tree _q41 = gimple_assign_rhs2 (_a1);
16256 : 36 : _q41 = do_valueize (valueize, _q41);
16257 : 36 : if (tree_swap_operands_p (_q40, _q41))
16258 : 0 : std::swap (_q40, _q41);
16259 : 36 : if ((_q40 == _p0 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _p0, 0) && types_match (_q40, _p0)))
16260 : : {
16261 : 0 : {
16262 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q41 };
16263 : 0 : if (gimple_simplify_417 (res_op, seq, valueize, type, captures))
16264 : 0 : return true;
16265 : : }
16266 : : }
16267 : 36 : if ((_q41 == _p0 && ! TREE_SIDE_EFFECTS (_q41)) || (operand_equal_p (_q41, _p0, 0) && types_match (_q41, _p0)))
16268 : : {
16269 : 0 : {
16270 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q40 };
16271 : 0 : if (gimple_simplify_417 (res_op, seq, valueize, type, captures))
16272 : 0 : return true;
16273 : : }
16274 : : }
16275 : 8202882 : break;
16276 : : }
16277 : : default:;
16278 : : }
16279 : : }
16280 : : break;
16281 : : default:;
16282 : : }
16283 : : }
16284 : : }
16285 : 8202882 : {
16286 : 8202882 : tree _p0_pops[1];
16287 : 8202882 : if (gimple_nop_convert (_p0, _p0_pops, valueize))
16288 : : {
16289 : 116016 : tree _q20 = _p0_pops[0];
16290 : 116016 : switch (TREE_CODE (_q20))
16291 : : {
16292 : 115075 : case SSA_NAME:
16293 : 115075 : if (gimple *_d1 = get_def (valueize, _q20))
16294 : : {
16295 : 112547 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
16296 : 108802 : switch (gimple_assign_rhs_code (_a1))
16297 : : {
16298 : 0 : case EQ_EXPR:
16299 : 0 : {
16300 : 0 : tree _q30 = gimple_assign_rhs1 (_a1);
16301 : 0 : _q30 = do_valueize (valueize, _q30);
16302 : 0 : tree _q31 = gimple_assign_rhs2 (_a1);
16303 : 0 : _q31 = do_valueize (valueize, _q31);
16304 : 0 : if (tree_swap_operands_p (_q30, _q31))
16305 : 0 : std::swap (_q30, _q31);
16306 : 0 : if ((_p1 == _q30 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q30, 0) && types_match (_p1, _q30)))
16307 : : {
16308 : 0 : {
16309 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q30, _q31 };
16310 : 0 : if (gimple_simplify_417 (res_op, seq, valueize, type, captures))
16311 : 0 : return true;
16312 : : }
16313 : : }
16314 : 0 : if ((_p1 == _q31 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q31, 0) && types_match (_p1, _q31)))
16315 : : {
16316 : 0 : {
16317 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q31, _q30 };
16318 : 0 : if (gimple_simplify_417 (res_op, seq, valueize, type, captures))
16319 : 0 : return true;
16320 : : }
16321 : : }
16322 : 8202882 : break;
16323 : : }
16324 : : default:;
16325 : : }
16326 : : }
16327 : : break;
16328 : : default:;
16329 : : }
16330 : : }
16331 : : }
16332 : 8202882 : switch (TREE_CODE (_p1))
16333 : : {
16334 : 2723998 : case SSA_NAME:
16335 : 2723998 : if (gimple *_d1 = get_def (valueize, _p1))
16336 : : {
16337 : 2137380 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
16338 : 2074015 : switch (gimple_assign_rhs_code (_a1))
16339 : : {
16340 : 251251 : case EQ_EXPR:
16341 : 251251 : {
16342 : 251251 : tree _q30 = gimple_assign_rhs1 (_a1);
16343 : 251251 : _q30 = do_valueize (valueize, _q30);
16344 : 251251 : tree _q31 = gimple_assign_rhs2 (_a1);
16345 : 251251 : _q31 = do_valueize (valueize, _q31);
16346 : 251251 : if (tree_swap_operands_p (_q30, _q31))
16347 : 1646 : std::swap (_q30, _q31);
16348 : 251251 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || (operand_equal_p (_q30, _p0, 0) && types_match (_q30, _p0)))
16349 : : {
16350 : 1 : {
16351 : 1 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q31 };
16352 : 1 : if (gimple_simplify_417 (res_op, seq, valueize, type, captures))
16353 : 1 : return true;
16354 : : }
16355 : : }
16356 : 251250 : if ((_q31 == _p0 && ! TREE_SIDE_EFFECTS (_q31)) || (operand_equal_p (_q31, _p0, 0) && types_match (_q31, _p0)))
16357 : : {
16358 : 0 : {
16359 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q30 };
16360 : 0 : if (gimple_simplify_417 (res_op, seq, valueize, type, captures))
16361 : 0 : return true;
16362 : : }
16363 : : }
16364 : 8202881 : break;
16365 : : }
16366 : 14713 : case BIT_XOR_EXPR:
16367 : 14713 : {
16368 : 14713 : tree _q30 = gimple_assign_rhs1 (_a1);
16369 : 14713 : _q30 = do_valueize (valueize, _q30);
16370 : 14713 : tree _q31 = gimple_assign_rhs2 (_a1);
16371 : 14713 : _q31 = do_valueize (valueize, _q31);
16372 : 14713 : if (tree_swap_operands_p (_q30, _q31))
16373 : 476 : std::swap (_q30, _q31);
16374 : 14713 : {
16375 : 14713 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q30, _q31 };
16376 : 14713 : if (gimple_simplify_420 (res_op, seq, valueize, type, captures))
16377 : 0 : return true;
16378 : : }
16379 : 14713 : {
16380 : 14713 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q31, _q30 };
16381 : 14713 : if (gimple_simplify_420 (res_op, seq, valueize, type, captures))
16382 : 0 : return true;
16383 : : }
16384 : 14713 : break;
16385 : : }
16386 : : default:;
16387 : : }
16388 : : }
16389 : : break;
16390 : 8202881 : default:;
16391 : : }
16392 : 8202881 : switch (TREE_CODE (_p0))
16393 : : {
16394 : 8113111 : case SSA_NAME:
16395 : 8113111 : if (gimple *_d1 = get_def (valueize, _p0))
16396 : : {
16397 : 5550626 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
16398 : 5877258 : switch (gimple_assign_rhs_code (_a1))
16399 : : {
16400 : 67944 : case BIT_XOR_EXPR:
16401 : 67944 : {
16402 : 67944 : tree _q20 = gimple_assign_rhs1 (_a1);
16403 : 67944 : _q20 = do_valueize (valueize, _q20);
16404 : 67944 : tree _q21 = gimple_assign_rhs2 (_a1);
16405 : 67944 : _q21 = do_valueize (valueize, _q21);
16406 : 67944 : if (tree_swap_operands_p (_q20, _q21))
16407 : 3684 : std::swap (_q20, _q21);
16408 : 67944 : {
16409 : 67944 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _q20, _q21 };
16410 : 67944 : if (gimple_simplify_420 (res_op, seq, valueize, type, captures))
16411 : 3 : return true;
16412 : : }
16413 : 67941 : {
16414 : 67941 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _q21, _q20 };
16415 : 67941 : if (gimple_simplify_420 (res_op, seq, valueize, type, captures))
16416 : 28 : return true;
16417 : : }
16418 : 67913 : switch (TREE_CODE (_p1))
16419 : : {
16420 : 19442 : case SSA_NAME:
16421 : 19442 : if (gimple *_d2 = get_def (valueize, _p1))
16422 : : {
16423 : 11272 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
16424 : 11925 : switch (gimple_assign_rhs_code (_a2))
16425 : : {
16426 : 141 : case BIT_XOR_EXPR:
16427 : 141 : {
16428 : 141 : tree _q50 = gimple_assign_rhs1 (_a2);
16429 : 141 : _q50 = do_valueize (valueize, _q50);
16430 : 141 : tree _q51 = gimple_assign_rhs2 (_a2);
16431 : 141 : _q51 = do_valueize (valueize, _q51);
16432 : 141 : if (tree_swap_operands_p (_q50, _q51))
16433 : 28 : std::swap (_q50, _q51);
16434 : 141 : switch (TREE_CODE (_q50))
16435 : : {
16436 : 141 : case SSA_NAME:
16437 : 141 : if (gimple *_d3 = get_def (valueize, _q50))
16438 : : {
16439 : 127 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
16440 : 123 : switch (gimple_assign_rhs_code (_a3))
16441 : : {
16442 : 3 : case BIT_XOR_EXPR:
16443 : 3 : {
16444 : 3 : tree _q60 = gimple_assign_rhs1 (_a3);
16445 : 3 : _q60 = do_valueize (valueize, _q60);
16446 : 3 : tree _q61 = gimple_assign_rhs2 (_a3);
16447 : 3 : _q61 = do_valueize (valueize, _q61);
16448 : 3 : if (tree_swap_operands_p (_q60, _q61))
16449 : 1 : std::swap (_q60, _q61);
16450 : 3 : if ((_q60 == _q21 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q21, 0) && types_match (_q60, _q21)))
16451 : : {
16452 : 0 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
16453 : : {
16454 : 0 : {
16455 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q61 };
16456 : 0 : if (gimple_simplify_421 (res_op, seq, valueize, type, captures))
16457 : 0 : return true;
16458 : : }
16459 : : }
16460 : : }
16461 : 3 : if ((_q61 == _q21 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q21, 0) && types_match (_q61, _q21)))
16462 : : {
16463 : 3 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
16464 : : {
16465 : 0 : {
16466 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q60 };
16467 : 0 : if (gimple_simplify_421 (res_op, seq, valueize, type, captures))
16468 : 0 : return true;
16469 : : }
16470 : : }
16471 : : }
16472 : 3 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
16473 : : {
16474 : 3 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
16475 : : {
16476 : 0 : {
16477 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q61 };
16478 : 0 : if (gimple_simplify_421 (res_op, seq, valueize, type, captures))
16479 : 0 : return true;
16480 : : }
16481 : : }
16482 : : }
16483 : 3 : if ((_q61 == _q20 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q20, 0) && types_match (_q61, _q20)))
16484 : : {
16485 : 0 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
16486 : : {
16487 : 0 : {
16488 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q60 };
16489 : 0 : if (gimple_simplify_421 (res_op, seq, valueize, type, captures))
16490 : 0 : return true;
16491 : : }
16492 : : }
16493 : : }
16494 : 141 : break;
16495 : : }
16496 : : default:;
16497 : : }
16498 : : }
16499 : : break;
16500 : 141 : default:;
16501 : : }
16502 : 141 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
16503 : : {
16504 : 9 : switch (TREE_CODE (_q51))
16505 : : {
16506 : 9 : case SSA_NAME:
16507 : 9 : if (gimple *_d3 = get_def (valueize, _q51))
16508 : : {
16509 : 9 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
16510 : 9 : switch (gimple_assign_rhs_code (_a3))
16511 : : {
16512 : 2 : case BIT_XOR_EXPR:
16513 : 2 : {
16514 : 2 : tree _q70 = gimple_assign_rhs1 (_a3);
16515 : 2 : _q70 = do_valueize (valueize, _q70);
16516 : 2 : tree _q71 = gimple_assign_rhs2 (_a3);
16517 : 2 : _q71 = do_valueize (valueize, _q71);
16518 : 2 : if (tree_swap_operands_p (_q70, _q71))
16519 : 0 : std::swap (_q70, _q71);
16520 : 2 : if ((_q70 == _q21 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q21, 0) && types_match (_q70, _q21)))
16521 : : {
16522 : 2 : {
16523 : 2 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q71 };
16524 : 2 : if (gimple_simplify_421 (res_op, seq, valueize, type, captures))
16525 : 1 : return true;
16526 : : }
16527 : : }
16528 : 1 : if ((_q71 == _q21 && ! TREE_SIDE_EFFECTS (_q71)) || (operand_equal_p (_q71, _q21, 0) && types_match (_q71, _q21)))
16529 : : {
16530 : 0 : {
16531 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q70 };
16532 : 0 : if (gimple_simplify_421 (res_op, seq, valueize, type, captures))
16533 : 0 : return true;
16534 : : }
16535 : : }
16536 : 140 : break;
16537 : : }
16538 : : default:;
16539 : : }
16540 : : }
16541 : : break;
16542 : : default:;
16543 : : }
16544 : : }
16545 : 140 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
16546 : : {
16547 : 15 : switch (TREE_CODE (_q51))
16548 : : {
16549 : 15 : case SSA_NAME:
16550 : 15 : if (gimple *_d3 = get_def (valueize, _q51))
16551 : : {
16552 : 15 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
16553 : 15 : switch (gimple_assign_rhs_code (_a3))
16554 : : {
16555 : 2 : case BIT_XOR_EXPR:
16556 : 2 : {
16557 : 2 : tree _q70 = gimple_assign_rhs1 (_a3);
16558 : 2 : _q70 = do_valueize (valueize, _q70);
16559 : 2 : tree _q71 = gimple_assign_rhs2 (_a3);
16560 : 2 : _q71 = do_valueize (valueize, _q71);
16561 : 2 : if (tree_swap_operands_p (_q70, _q71))
16562 : 0 : std::swap (_q70, _q71);
16563 : 2 : if ((_q70 == _q20 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q20, 0) && types_match (_q70, _q20)))
16564 : : {
16565 : 2 : {
16566 : 2 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q71 };
16567 : 2 : if (gimple_simplify_421 (res_op, seq, valueize, type, captures))
16568 : 1 : return true;
16569 : : }
16570 : : }
16571 : 1 : if ((_q71 == _q20 && ! TREE_SIDE_EFFECTS (_q71)) || (operand_equal_p (_q71, _q20, 0) && types_match (_q71, _q20)))
16572 : : {
16573 : 0 : {
16574 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q70 };
16575 : 0 : if (gimple_simplify_421 (res_op, seq, valueize, type, captures))
16576 : 0 : return true;
16577 : : }
16578 : : }
16579 : 67911 : break;
16580 : : }
16581 : : default:;
16582 : : }
16583 : : }
16584 : : break;
16585 : : default:;
16586 : : }
16587 : : }
16588 : 67911 : break;
16589 : : }
16590 : : default:;
16591 : : }
16592 : : }
16593 : : break;
16594 : 67911 : default:;
16595 : : }
16596 : 67911 : switch (TREE_CODE (_q20))
16597 : : {
16598 : 67911 : case SSA_NAME:
16599 : 67911 : if (gimple *_d2 = get_def (valueize, _q20))
16600 : : {
16601 : 65296 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
16602 : 107069 : switch (gimple_assign_rhs_code (_a2))
16603 : : {
16604 : 1364 : case BIT_XOR_EXPR:
16605 : 1364 : {
16606 : 1364 : tree _q30 = gimple_assign_rhs1 (_a2);
16607 : 1364 : _q30 = do_valueize (valueize, _q30);
16608 : 1364 : tree _q31 = gimple_assign_rhs2 (_a2);
16609 : 1364 : _q31 = do_valueize (valueize, _q31);
16610 : 1364 : if (tree_swap_operands_p (_q30, _q31))
16611 : 50 : std::swap (_q30, _q31);
16612 : 1364 : switch (TREE_CODE (_p1))
16613 : : {
16614 : 80 : case SSA_NAME:
16615 : 80 : if (gimple *_d3 = get_def (valueize, _p1))
16616 : : {
16617 : 80 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
16618 : 95 : switch (gimple_assign_rhs_code (_a3))
16619 : : {
16620 : 0 : case BIT_XOR_EXPR:
16621 : 0 : {
16622 : 0 : tree _q70 = gimple_assign_rhs1 (_a3);
16623 : 0 : _q70 = do_valueize (valueize, _q70);
16624 : 0 : tree _q71 = gimple_assign_rhs2 (_a3);
16625 : 0 : _q71 = do_valueize (valueize, _q71);
16626 : 0 : if (tree_swap_operands_p (_q70, _q71))
16627 : 0 : std::swap (_q70, _q71);
16628 : 0 : if ((_q70 == _q21 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q21, 0) && types_match (_q70, _q21)))
16629 : : {
16630 : 0 : if ((_q71 == _q30 && ! TREE_SIDE_EFFECTS (_q71)) || (operand_equal_p (_q71, _q30, 0) && types_match (_q71, _q30)))
16631 : : {
16632 : 0 : {
16633 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q30, _p0, _q20, _q31 };
16634 : 0 : if (gimple_simplify_422 (res_op, seq, valueize, type, captures))
16635 : 0 : return true;
16636 : : }
16637 : : }
16638 : 0 : if ((_q71 == _q31 && ! TREE_SIDE_EFFECTS (_q71)) || (operand_equal_p (_q71, _q31, 0) && types_match (_q71, _q31)))
16639 : : {
16640 : 0 : {
16641 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q31, _p0, _q20, _q30 };
16642 : 0 : if (gimple_simplify_422 (res_op, seq, valueize, type, captures))
16643 : 0 : return true;
16644 : : }
16645 : : }
16646 : : }
16647 : 0 : if ((_q70 == _q30 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q30, 0) && types_match (_q70, _q30)))
16648 : : {
16649 : 0 : if ((_q71 == _q21 && ! TREE_SIDE_EFFECTS (_q71)) || (operand_equal_p (_q71, _q21, 0) && types_match (_q71, _q21)))
16650 : : {
16651 : 0 : {
16652 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q30, _p0, _q20, _q31 };
16653 : 0 : if (gimple_simplify_422 (res_op, seq, valueize, type, captures))
16654 : 0 : return true;
16655 : : }
16656 : : }
16657 : : }
16658 : 0 : if ((_q70 == _q31 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q31, 0) && types_match (_q70, _q31)))
16659 : : {
16660 : 0 : if ((_q71 == _q21 && ! TREE_SIDE_EFFECTS (_q71)) || (operand_equal_p (_q71, _q21, 0) && types_match (_q71, _q21)))
16661 : : {
16662 : 0 : {
16663 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q31, _p0, _q20, _q30 };
16664 : 0 : if (gimple_simplify_422 (res_op, seq, valueize, type, captures))
16665 : 0 : return true;
16666 : : }
16667 : : }
16668 : : }
16669 : 67911 : break;
16670 : : }
16671 : : default:;
16672 : : }
16673 : : }
16674 : : break;
16675 : : default:;
16676 : : }
16677 : 67911 : break;
16678 : : }
16679 : : default:;
16680 : : }
16681 : : }
16682 : : break;
16683 : 67911 : default:;
16684 : : }
16685 : 67911 : switch (TREE_CODE (_q21))
16686 : : {
16687 : 62197 : case SSA_NAME:
16688 : 62197 : if (gimple *_d2 = get_def (valueize, _q21))
16689 : : {
16690 : 59848 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
16691 : 101552 : switch (gimple_assign_rhs_code (_a2))
16692 : : {
16693 : 2423 : case BIT_XOR_EXPR:
16694 : 2423 : {
16695 : 2423 : tree _q40 = gimple_assign_rhs1 (_a2);
16696 : 2423 : _q40 = do_valueize (valueize, _q40);
16697 : 2423 : tree _q41 = gimple_assign_rhs2 (_a2);
16698 : 2423 : _q41 = do_valueize (valueize, _q41);
16699 : 2423 : if (tree_swap_operands_p (_q40, _q41))
16700 : 249 : std::swap (_q40, _q41);
16701 : 2423 : switch (TREE_CODE (_p1))
16702 : : {
16703 : 46 : case SSA_NAME:
16704 : 46 : if (gimple *_d3 = get_def (valueize, _p1))
16705 : : {
16706 : 44 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
16707 : 40 : switch (gimple_assign_rhs_code (_a3))
16708 : : {
16709 : 0 : case BIT_XOR_EXPR:
16710 : 0 : {
16711 : 0 : tree _q70 = gimple_assign_rhs1 (_a3);
16712 : 0 : _q70 = do_valueize (valueize, _q70);
16713 : 0 : tree _q71 = gimple_assign_rhs2 (_a3);
16714 : 0 : _q71 = do_valueize (valueize, _q71);
16715 : 0 : if (tree_swap_operands_p (_q70, _q71))
16716 : 0 : std::swap (_q70, _q71);
16717 : 0 : if ((_q70 == _q20 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q20, 0) && types_match (_q70, _q20)))
16718 : : {
16719 : 0 : if ((_q71 == _q40 && ! TREE_SIDE_EFFECTS (_q71)) || (operand_equal_p (_q71, _q40, 0) && types_match (_q71, _q40)))
16720 : : {
16721 : 0 : {
16722 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q40, _p0, _q21, _q41 };
16723 : 0 : if (gimple_simplify_422 (res_op, seq, valueize, type, captures))
16724 : 0 : return true;
16725 : : }
16726 : : }
16727 : 0 : if ((_q71 == _q41 && ! TREE_SIDE_EFFECTS (_q71)) || (operand_equal_p (_q71, _q41, 0) && types_match (_q71, _q41)))
16728 : : {
16729 : 0 : {
16730 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q41, _p0, _q21, _q40 };
16731 : 0 : if (gimple_simplify_422 (res_op, seq, valueize, type, captures))
16732 : 0 : return true;
16733 : : }
16734 : : }
16735 : : }
16736 : 0 : if ((_q70 == _q40 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q40, 0) && types_match (_q70, _q40)))
16737 : : {
16738 : 0 : if ((_q71 == _q20 && ! TREE_SIDE_EFFECTS (_q71)) || (operand_equal_p (_q71, _q20, 0) && types_match (_q71, _q20)))
16739 : : {
16740 : 0 : {
16741 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q40, _p0, _q21, _q41 };
16742 : 0 : if (gimple_simplify_422 (res_op, seq, valueize, type, captures))
16743 : 0 : return true;
16744 : : }
16745 : : }
16746 : : }
16747 : 0 : if ((_q70 == _q41 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q41, 0) && types_match (_q70, _q41)))
16748 : : {
16749 : 0 : if ((_q71 == _q20 && ! TREE_SIDE_EFFECTS (_q71)) || (operand_equal_p (_q71, _q20, 0) && types_match (_q71, _q20)))
16750 : : {
16751 : 0 : {
16752 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q41, _p0, _q21, _q40 };
16753 : 0 : if (gimple_simplify_422 (res_op, seq, valueize, type, captures))
16754 : 0 : return true;
16755 : : }
16756 : : }
16757 : : }
16758 : 8201433 : break;
16759 : : }
16760 : : default:;
16761 : : }
16762 : : }
16763 : : break;
16764 : : default:;
16765 : : }
16766 : 8201433 : break;
16767 : : }
16768 : : default:;
16769 : : }
16770 : : }
16771 : : break;
16772 : : default:;
16773 : : }
16774 : 8201433 : break;
16775 : : }
16776 : 53916 : case BIT_NOT_EXPR:
16777 : 53916 : {
16778 : 53916 : tree _q20 = gimple_assign_rhs1 (_a1);
16779 : 53916 : _q20 = do_valueize (valueize, _q20);
16780 : 53916 : switch (TREE_CODE (_q20))
16781 : : {
16782 : 53916 : case SSA_NAME:
16783 : 53916 : if (gimple *_d2 = get_def (valueize, _q20))
16784 : : {
16785 : 50798 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
16786 : 46601 : switch (gimple_assign_rhs_code (_a2))
16787 : : {
16788 : 585 : case BIT_AND_EXPR:
16789 : 585 : {
16790 : 585 : tree _q30 = gimple_assign_rhs1 (_a2);
16791 : 585 : _q30 = do_valueize (valueize, _q30);
16792 : 585 : tree _q31 = gimple_assign_rhs2 (_a2);
16793 : 585 : _q31 = do_valueize (valueize, _q31);
16794 : 585 : if (tree_swap_operands_p (_q30, _q31))
16795 : 24 : std::swap (_q30, _q31);
16796 : 585 : if ((_p1 == _q30 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q30, 0) && types_match (_p1, _q30)))
16797 : : {
16798 : 0 : {
16799 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q30, _q20, _q31 };
16800 : 0 : if (gimple_simplify_116 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
16801 : 0 : return true;
16802 : : }
16803 : : }
16804 : 585 : if ((_p1 == _q31 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q31, 0) && types_match (_p1, _q31)))
16805 : : {
16806 : 128 : {
16807 : 128 : tree captures[3] ATTRIBUTE_UNUSED = { _q31, _q20, _q30 };
16808 : 128 : if (gimple_simplify_116 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
16809 : 0 : return true;
16810 : : }
16811 : : }
16812 : 53916 : break;
16813 : : }
16814 : : default:;
16815 : : }
16816 : : }
16817 : 53916 : {
16818 : 53916 : switch (TREE_CODE (_p1))
16819 : : {
16820 : 10415 : case INTEGER_CST:
16821 : 10415 : {
16822 : 10415 : {
16823 : 10415 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _p1 };
16824 : 20809 : if (INTEGRAL_TYPE_P (TREE_TYPE (captures[0]))
16825 : 41639 : && wi::bit_and_not (get_nonzero_bits (captures[0]), wi::to_wide (captures[1])) == 0
16826 : : )
16827 : : {
16828 : 588 : gimple_seq *lseq = seq;
16829 : 588 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2081;
16830 : 588 : {
16831 : 588 : res_op->set_op (BIT_XOR_EXPR, type, 2);
16832 : 588 : res_op->ops[0] = captures[0];
16833 : 588 : res_op->ops[1] = captures[1];
16834 : 588 : res_op->resimplify (lseq, valueize);
16835 : 588 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1060, __FILE__, __LINE__, true);
16836 : 588 : return true;
16837 : : }
16838 : 0 : next_after_fail2081:;
16839 : : }
16840 : : }
16841 : 9827 : break;
16842 : : }
16843 : : default:;
16844 : : }
16845 : : }
16846 : : break;
16847 : : default:;
16848 : : }
16849 : : break;
16850 : : }
16851 : 372365 : case PLUS_EXPR:
16852 : 372365 : {
16853 : 372365 : tree _q20 = gimple_assign_rhs1 (_a1);
16854 : 372365 : _q20 = do_valueize (valueize, _q20);
16855 : 372365 : tree _q21 = gimple_assign_rhs2 (_a1);
16856 : 372365 : _q21 = do_valueize (valueize, _q21);
16857 : 372365 : if (tree_swap_operands_p (_q20, _q21))
16858 : 10801 : std::swap (_q20, _q21);
16859 : 372365 : switch (TREE_CODE (_q20))
16860 : : {
16861 : 372365 : case SSA_NAME:
16862 : 372365 : if (gimple *_d2 = get_def (valueize, _q20))
16863 : : {
16864 : 353685 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
16865 : 321676 : switch (gimple_assign_rhs_code (_a2))
16866 : : {
16867 : 15053 : case BIT_AND_EXPR:
16868 : 15053 : {
16869 : 15053 : tree _q30 = gimple_assign_rhs1 (_a2);
16870 : 15053 : _q30 = do_valueize (valueize, _q30);
16871 : 15053 : tree _q31 = gimple_assign_rhs2 (_a2);
16872 : 15053 : _q31 = do_valueize (valueize, _q31);
16873 : 15053 : if (tree_swap_operands_p (_q30, _q31))
16874 : 23 : std::swap (_q30, _q31);
16875 : 15053 : switch (TREE_CODE (_q31))
16876 : : {
16877 : 14766 : case INTEGER_CST:
16878 : 14766 : {
16879 : 14766 : switch (TREE_CODE (_p1))
16880 : : {
16881 : 11736 : case INTEGER_CST:
16882 : 11736 : {
16883 : 11736 : {
16884 : 11736 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q31, _q21, _p1 };
16885 : 11736 : if (gimple_simplify_423 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, PLUS_EXPR))
16886 : 9 : return true;
16887 : : }
16888 : 11727 : break;
16889 : : }
16890 : : default:;
16891 : : }
16892 : : break;
16893 : : }
16894 : : default:;
16895 : : }
16896 : 372348 : break;
16897 : : }
16898 : 1217 : case BIT_IOR_EXPR:
16899 : 1217 : {
16900 : 1217 : tree _q30 = gimple_assign_rhs1 (_a2);
16901 : 1217 : _q30 = do_valueize (valueize, _q30);
16902 : 1217 : tree _q31 = gimple_assign_rhs2 (_a2);
16903 : 1217 : _q31 = do_valueize (valueize, _q31);
16904 : 1217 : if (tree_swap_operands_p (_q30, _q31))
16905 : 84 : std::swap (_q30, _q31);
16906 : 1217 : switch (TREE_CODE (_q31))
16907 : : {
16908 : 353 : case INTEGER_CST:
16909 : 353 : {
16910 : 353 : switch (TREE_CODE (_p1))
16911 : : {
16912 : 353 : case INTEGER_CST:
16913 : 353 : {
16914 : 353 : {
16915 : 353 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q31, _q21, _p1 };
16916 : 353 : if (gimple_simplify_423 (res_op, seq, valueize, type, captures, BIT_IOR_EXPR, PLUS_EXPR))
16917 : 4 : return true;
16918 : : }
16919 : 349 : break;
16920 : : }
16921 : : default:;
16922 : : }
16923 : : break;
16924 : : }
16925 : : default:;
16926 : : }
16927 : 372348 : break;
16928 : : }
16929 : 158 : case BIT_XOR_EXPR:
16930 : 158 : {
16931 : 158 : tree _q30 = gimple_assign_rhs1 (_a2);
16932 : 158 : _q30 = do_valueize (valueize, _q30);
16933 : 158 : tree _q31 = gimple_assign_rhs2 (_a2);
16934 : 158 : _q31 = do_valueize (valueize, _q31);
16935 : 158 : if (tree_swap_operands_p (_q30, _q31))
16936 : 0 : std::swap (_q30, _q31);
16937 : 158 : switch (TREE_CODE (_q31))
16938 : : {
16939 : 143 : case INTEGER_CST:
16940 : 143 : {
16941 : 143 : switch (TREE_CODE (_p1))
16942 : : {
16943 : 43 : case INTEGER_CST:
16944 : 43 : {
16945 : 43 : {
16946 : 43 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q31, _q21, _p1 };
16947 : 43 : if (gimple_simplify_423 (res_op, seq, valueize, type, captures, BIT_XOR_EXPR, PLUS_EXPR))
16948 : 4 : return true;
16949 : : }
16950 : 39 : break;
16951 : : }
16952 : : default:;
16953 : : }
16954 : : break;
16955 : : }
16956 : : default:;
16957 : : }
16958 : 372348 : break;
16959 : : }
16960 : : default:;
16961 : : }
16962 : : }
16963 : : break;
16964 : 372348 : default:;
16965 : : }
16966 : 372348 : switch (TREE_CODE (_q21))
16967 : : {
16968 : 149946 : case SSA_NAME:
16969 : 149946 : if (gimple *_d2 = get_def (valueize, _q21))
16970 : : {
16971 : 145113 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
16972 : 135600 : switch (gimple_assign_rhs_code (_a2))
16973 : : {
16974 : 12251 : case BIT_AND_EXPR:
16975 : 12251 : {
16976 : 12251 : tree _q40 = gimple_assign_rhs1 (_a2);
16977 : 12251 : _q40 = do_valueize (valueize, _q40);
16978 : 12251 : tree _q41 = gimple_assign_rhs2 (_a2);
16979 : 12251 : _q41 = do_valueize (valueize, _q41);
16980 : 12251 : if (tree_swap_operands_p (_q40, _q41))
16981 : 16 : std::swap (_q40, _q41);
16982 : 12251 : switch (TREE_CODE (_q41))
16983 : : {
16984 : 12217 : case INTEGER_CST:
16985 : 12217 : {
16986 : 12217 : switch (TREE_CODE (_p1))
16987 : : {
16988 : 9889 : case INTEGER_CST:
16989 : 9889 : {
16990 : 9889 : {
16991 : 9889 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q40, _q41, _p1 };
16992 : 9889 : if (gimple_simplify_424 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, PLUS_EXPR))
16993 : 81 : return true;
16994 : : }
16995 : 9808 : break;
16996 : : }
16997 : : default:;
16998 : : }
16999 : : break;
17000 : : }
17001 : : default:;
17002 : : }
17003 : 372267 : break;
17004 : : }
17005 : 59 : case BIT_IOR_EXPR:
17006 : 59 : {
17007 : 59 : tree _q40 = gimple_assign_rhs1 (_a2);
17008 : 59 : _q40 = do_valueize (valueize, _q40);
17009 : 59 : tree _q41 = gimple_assign_rhs2 (_a2);
17010 : 59 : _q41 = do_valueize (valueize, _q41);
17011 : 59 : if (tree_swap_operands_p (_q40, _q41))
17012 : 6 : std::swap (_q40, _q41);
17013 : 59 : switch (TREE_CODE (_q41))
17014 : : {
17015 : 0 : case INTEGER_CST:
17016 : 0 : {
17017 : 0 : switch (TREE_CODE (_p1))
17018 : : {
17019 : 0 : case INTEGER_CST:
17020 : 0 : {
17021 : 0 : {
17022 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q40, _q41, _p1 };
17023 : 0 : if (gimple_simplify_424 (res_op, seq, valueize, type, captures, BIT_IOR_EXPR, PLUS_EXPR))
17024 : 0 : return true;
17025 : : }
17026 : 0 : break;
17027 : : }
17028 : : default:;
17029 : : }
17030 : : break;
17031 : : }
17032 : : default:;
17033 : : }
17034 : 372267 : break;
17035 : : }
17036 : 159 : case BIT_XOR_EXPR:
17037 : 159 : {
17038 : 159 : tree _q40 = gimple_assign_rhs1 (_a2);
17039 : 159 : _q40 = do_valueize (valueize, _q40);
17040 : 159 : tree _q41 = gimple_assign_rhs2 (_a2);
17041 : 159 : _q41 = do_valueize (valueize, _q41);
17042 : 159 : if (tree_swap_operands_p (_q40, _q41))
17043 : 2 : std::swap (_q40, _q41);
17044 : 159 : switch (TREE_CODE (_q41))
17045 : : {
17046 : 106 : case INTEGER_CST:
17047 : 106 : {
17048 : 106 : switch (TREE_CODE (_p1))
17049 : : {
17050 : 18 : case INTEGER_CST:
17051 : 18 : {
17052 : 18 : {
17053 : 18 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q40, _q41, _p1 };
17054 : 18 : if (gimple_simplify_424 (res_op, seq, valueize, type, captures, BIT_XOR_EXPR, PLUS_EXPR))
17055 : 0 : return true;
17056 : : }
17057 : 18 : break;
17058 : : }
17059 : : default:;
17060 : : }
17061 : : break;
17062 : : }
17063 : : default:;
17064 : : }
17065 : 372267 : break;
17066 : : }
17067 : : default:;
17068 : : }
17069 : : }
17070 : : break;
17071 : 372267 : default:;
17072 : : }
17073 : 372267 : switch (TREE_CODE (_p1))
17074 : : {
17075 : 249256 : case INTEGER_CST:
17076 : 249256 : {
17077 : 249256 : {
17078 : 249256 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1 };
17079 : 249256 : if (gimple_simplify_425 (res_op, seq, valueize, type, captures, PLUS_EXPR))
17080 : 571 : return true;
17081 : : }
17082 : 248685 : break;
17083 : : }
17084 : : default:;
17085 : : }
17086 : 8201433 : break;
17087 : : }
17088 : 45949 : case MINUS_EXPR:
17089 : 45949 : {
17090 : 45949 : tree _q20 = gimple_assign_rhs1 (_a1);
17091 : 45949 : _q20 = do_valueize (valueize, _q20);
17092 : 45949 : tree _q21 = gimple_assign_rhs2 (_a1);
17093 : 45949 : _q21 = do_valueize (valueize, _q21);
17094 : 45949 : switch (TREE_CODE (_q20))
17095 : : {
17096 : 43224 : case SSA_NAME:
17097 : 43224 : if (gimple *_d2 = get_def (valueize, _q20))
17098 : : {
17099 : 41160 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
17100 : 38515 : switch (gimple_assign_rhs_code (_a2))
17101 : : {
17102 : 566 : case BIT_AND_EXPR:
17103 : 566 : {
17104 : 566 : tree _q30 = gimple_assign_rhs1 (_a2);
17105 : 566 : _q30 = do_valueize (valueize, _q30);
17106 : 566 : tree _q31 = gimple_assign_rhs2 (_a2);
17107 : 566 : _q31 = do_valueize (valueize, _q31);
17108 : 566 : if (tree_swap_operands_p (_q30, _q31))
17109 : 0 : std::swap (_q30, _q31);
17110 : 566 : switch (TREE_CODE (_q31))
17111 : : {
17112 : 566 : case INTEGER_CST:
17113 : 566 : {
17114 : 566 : switch (TREE_CODE (_p1))
17115 : : {
17116 : 566 : case INTEGER_CST:
17117 : 566 : {
17118 : 566 : {
17119 : 566 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q31, _q21, _p1 };
17120 : 566 : if (gimple_simplify_423 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, MINUS_EXPR))
17121 : 2 : return true;
17122 : : }
17123 : 564 : break;
17124 : : }
17125 : : default:;
17126 : : }
17127 : : break;
17128 : : }
17129 : : default:;
17130 : : }
17131 : 45943 : break;
17132 : : }
17133 : 4 : case BIT_IOR_EXPR:
17134 : 4 : {
17135 : 4 : tree _q30 = gimple_assign_rhs1 (_a2);
17136 : 4 : _q30 = do_valueize (valueize, _q30);
17137 : 4 : tree _q31 = gimple_assign_rhs2 (_a2);
17138 : 4 : _q31 = do_valueize (valueize, _q31);
17139 : 4 : if (tree_swap_operands_p (_q30, _q31))
17140 : 0 : std::swap (_q30, _q31);
17141 : 4 : switch (TREE_CODE (_q31))
17142 : : {
17143 : 4 : case INTEGER_CST:
17144 : 4 : {
17145 : 4 : switch (TREE_CODE (_p1))
17146 : : {
17147 : 4 : case INTEGER_CST:
17148 : 4 : {
17149 : 4 : {
17150 : 4 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q31, _q21, _p1 };
17151 : 4 : if (gimple_simplify_423 (res_op, seq, valueize, type, captures, BIT_IOR_EXPR, MINUS_EXPR))
17152 : 2 : return true;
17153 : : }
17154 : 2 : break;
17155 : : }
17156 : : default:;
17157 : : }
17158 : : break;
17159 : : }
17160 : : default:;
17161 : : }
17162 : 45943 : break;
17163 : : }
17164 : 4 : case BIT_XOR_EXPR:
17165 : 4 : {
17166 : 4 : tree _q30 = gimple_assign_rhs1 (_a2);
17167 : 4 : _q30 = do_valueize (valueize, _q30);
17168 : 4 : tree _q31 = gimple_assign_rhs2 (_a2);
17169 : 4 : _q31 = do_valueize (valueize, _q31);
17170 : 4 : if (tree_swap_operands_p (_q30, _q31))
17171 : 0 : std::swap (_q30, _q31);
17172 : 4 : switch (TREE_CODE (_q31))
17173 : : {
17174 : 4 : case INTEGER_CST:
17175 : 4 : {
17176 : 4 : switch (TREE_CODE (_p1))
17177 : : {
17178 : 4 : case INTEGER_CST:
17179 : 4 : {
17180 : 4 : {
17181 : 4 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q31, _q21, _p1 };
17182 : 4 : if (gimple_simplify_423 (res_op, seq, valueize, type, captures, BIT_XOR_EXPR, MINUS_EXPR))
17183 : 2 : return true;
17184 : : }
17185 : 2 : break;
17186 : : }
17187 : : default:;
17188 : : }
17189 : : break;
17190 : : }
17191 : : default:;
17192 : : }
17193 : 45943 : break;
17194 : : }
17195 : : default:;
17196 : : }
17197 : : }
17198 : : break;
17199 : 45943 : default:;
17200 : : }
17201 : 45943 : switch (TREE_CODE (_q21))
17202 : : {
17203 : 45903 : case SSA_NAME:
17204 : 45903 : if (gimple *_d2 = get_def (valueize, _q21))
17205 : : {
17206 : 43605 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
17207 : 25011 : switch (gimple_assign_rhs_code (_a2))
17208 : : {
17209 : 777 : case BIT_AND_EXPR:
17210 : 777 : {
17211 : 777 : tree _q40 = gimple_assign_rhs1 (_a2);
17212 : 777 : _q40 = do_valueize (valueize, _q40);
17213 : 777 : tree _q41 = gimple_assign_rhs2 (_a2);
17214 : 777 : _q41 = do_valueize (valueize, _q41);
17215 : 777 : if (tree_swap_operands_p (_q40, _q41))
17216 : 0 : std::swap (_q40, _q41);
17217 : 777 : switch (TREE_CODE (_q41))
17218 : : {
17219 : 689 : case INTEGER_CST:
17220 : 689 : {
17221 : 689 : switch (TREE_CODE (_p1))
17222 : : {
17223 : 689 : case INTEGER_CST:
17224 : 689 : {
17225 : 689 : {
17226 : 689 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q40, _q41, _p1 };
17227 : 689 : if (gimple_simplify_424 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, MINUS_EXPR))
17228 : 2 : return true;
17229 : : }
17230 : 687 : break;
17231 : : }
17232 : : default:;
17233 : : }
17234 : : break;
17235 : : }
17236 : : default:;
17237 : : }
17238 : 45937 : break;
17239 : : }
17240 : 53 : case BIT_IOR_EXPR:
17241 : 53 : {
17242 : 53 : tree _q40 = gimple_assign_rhs1 (_a2);
17243 : 53 : _q40 = do_valueize (valueize, _q40);
17244 : 53 : tree _q41 = gimple_assign_rhs2 (_a2);
17245 : 53 : _q41 = do_valueize (valueize, _q41);
17246 : 53 : if (tree_swap_operands_p (_q40, _q41))
17247 : 0 : std::swap (_q40, _q41);
17248 : 53 : switch (TREE_CODE (_q41))
17249 : : {
17250 : 43 : case INTEGER_CST:
17251 : 43 : {
17252 : 43 : switch (TREE_CODE (_p1))
17253 : : {
17254 : 4 : case INTEGER_CST:
17255 : 4 : {
17256 : 4 : {
17257 : 4 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q40, _q41, _p1 };
17258 : 4 : if (gimple_simplify_424 (res_op, seq, valueize, type, captures, BIT_IOR_EXPR, MINUS_EXPR))
17259 : 2 : return true;
17260 : : }
17261 : 2 : break;
17262 : : }
17263 : : default:;
17264 : : }
17265 : : break;
17266 : : }
17267 : : default:;
17268 : : }
17269 : 45937 : break;
17270 : : }
17271 : 4 : case BIT_XOR_EXPR:
17272 : 4 : {
17273 : 4 : tree _q40 = gimple_assign_rhs1 (_a2);
17274 : 4 : _q40 = do_valueize (valueize, _q40);
17275 : 4 : tree _q41 = gimple_assign_rhs2 (_a2);
17276 : 4 : _q41 = do_valueize (valueize, _q41);
17277 : 4 : if (tree_swap_operands_p (_q40, _q41))
17278 : 0 : std::swap (_q40, _q41);
17279 : 4 : switch (TREE_CODE (_q41))
17280 : : {
17281 : 4 : case INTEGER_CST:
17282 : 4 : {
17283 : 4 : switch (TREE_CODE (_p1))
17284 : : {
17285 : 4 : case INTEGER_CST:
17286 : 4 : {
17287 : 4 : {
17288 : 4 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q40, _q41, _p1 };
17289 : 4 : if (gimple_simplify_424 (res_op, seq, valueize, type, captures, BIT_XOR_EXPR, MINUS_EXPR))
17290 : 2 : return true;
17291 : : }
17292 : 2 : break;
17293 : : }
17294 : : default:;
17295 : : }
17296 : : break;
17297 : : }
17298 : : default:;
17299 : : }
17300 : 45937 : break;
17301 : : }
17302 : : default:;
17303 : : }
17304 : : }
17305 : : break;
17306 : 45937 : default:;
17307 : : }
17308 : 45937 : switch (TREE_CODE (_p1))
17309 : : {
17310 : 38624 : case INTEGER_CST:
17311 : 38624 : {
17312 : 38624 : {
17313 : 38624 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1 };
17314 : 38624 : if (gimple_simplify_425 (res_op, seq, valueize, type, captures, MINUS_EXPR))
17315 : 26 : return true;
17316 : : }
17317 : 38598 : break;
17318 : : }
17319 : : default:;
17320 : : }
17321 : : break;
17322 : : }
17323 : 52844 : case NEGATE_EXPR:
17324 : 52844 : {
17325 : 52844 : tree _q20 = gimple_assign_rhs1 (_a1);
17326 : 52844 : _q20 = do_valueize (valueize, _q20);
17327 : 52844 : switch (TREE_CODE (_q20))
17328 : : {
17329 : 52844 : case SSA_NAME:
17330 : 52844 : if (gimple *_d2 = get_def (valueize, _q20))
17331 : : {
17332 : 43547 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
17333 : 24002 : switch (gimple_assign_rhs_code (_a2))
17334 : : {
17335 : 928 : case BIT_AND_EXPR:
17336 : 928 : {
17337 : 928 : tree _q30 = gimple_assign_rhs1 (_a2);
17338 : 928 : _q30 = do_valueize (valueize, _q30);
17339 : 928 : tree _q31 = gimple_assign_rhs2 (_a2);
17340 : 928 : _q31 = do_valueize (valueize, _q31);
17341 : 928 : if (tree_swap_operands_p (_q30, _q31))
17342 : 1 : std::swap (_q30, _q31);
17343 : 928 : switch (TREE_CODE (_q31))
17344 : : {
17345 : 879 : case INTEGER_CST:
17346 : 879 : {
17347 : 879 : switch (TREE_CODE (_p1))
17348 : : {
17349 : 879 : case INTEGER_CST:
17350 : 879 : {
17351 : 879 : {
17352 : 879 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q31, _p1 };
17353 : 879 : if (gimple_simplify_426 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
17354 : 3 : return true;
17355 : : }
17356 : 876 : break;
17357 : : }
17358 : : default:;
17359 : : }
17360 : : break;
17361 : : }
17362 : : default:;
17363 : : }
17364 : 52837 : break;
17365 : : }
17366 : 157 : case BIT_IOR_EXPR:
17367 : 157 : {
17368 : 157 : tree _q30 = gimple_assign_rhs1 (_a2);
17369 : 157 : _q30 = do_valueize (valueize, _q30);
17370 : 157 : tree _q31 = gimple_assign_rhs2 (_a2);
17371 : 157 : _q31 = do_valueize (valueize, _q31);
17372 : 157 : if (tree_swap_operands_p (_q30, _q31))
17373 : 3 : std::swap (_q30, _q31);
17374 : 157 : switch (TREE_CODE (_q31))
17375 : : {
17376 : 4 : case INTEGER_CST:
17377 : 4 : {
17378 : 4 : switch (TREE_CODE (_p1))
17379 : : {
17380 : 4 : case INTEGER_CST:
17381 : 4 : {
17382 : 4 : {
17383 : 4 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q31, _p1 };
17384 : 4 : if (gimple_simplify_426 (res_op, seq, valueize, type, captures, BIT_IOR_EXPR))
17385 : 2 : return true;
17386 : : }
17387 : 2 : break;
17388 : : }
17389 : : default:;
17390 : : }
17391 : : break;
17392 : : }
17393 : : default:;
17394 : : }
17395 : 52837 : break;
17396 : : }
17397 : 12 : case BIT_XOR_EXPR:
17398 : 12 : {
17399 : 12 : tree _q30 = gimple_assign_rhs1 (_a2);
17400 : 12 : _q30 = do_valueize (valueize, _q30);
17401 : 12 : tree _q31 = gimple_assign_rhs2 (_a2);
17402 : 12 : _q31 = do_valueize (valueize, _q31);
17403 : 12 : if (tree_swap_operands_p (_q30, _q31))
17404 : 0 : std::swap (_q30, _q31);
17405 : 12 : switch (TREE_CODE (_q31))
17406 : : {
17407 : 4 : case INTEGER_CST:
17408 : 4 : {
17409 : 4 : switch (TREE_CODE (_p1))
17410 : : {
17411 : 4 : case INTEGER_CST:
17412 : 4 : {
17413 : 4 : {
17414 : 4 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q31, _p1 };
17415 : 4 : if (gimple_simplify_426 (res_op, seq, valueize, type, captures, BIT_XOR_EXPR))
17416 : 2 : return true;
17417 : : }
17418 : 2 : break;
17419 : : }
17420 : : default:;
17421 : : }
17422 : : break;
17423 : : }
17424 : : default:;
17425 : : }
17426 : 52837 : break;
17427 : : }
17428 : : default:;
17429 : : }
17430 : : }
17431 : : break;
17432 : 52837 : default:;
17433 : : }
17434 : 52837 : if (gimple_zero_one_valued_p (_q20, valueize))
17435 : : {
17436 : 113 : {
17437 : 113 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _p1 };
17438 : 113 : if (gimple_simplify_427 (res_op, seq, valueize, type, captures))
17439 : 113 : return true;
17440 : : }
17441 : : }
17442 : : break;
17443 : : }
17444 : : default:;
17445 : : }
17446 : : }
17447 : : break;
17448 : 8201433 : default:;
17449 : : }
17450 : 8201433 : if (integer_zerop (_p1))
17451 : : {
17452 : 51161 : {
17453 : 51161 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
17454 : 51161 : gimple_seq *lseq = seq;
17455 : 51161 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2082;
17456 : 51161 : {
17457 : 51161 : tree tem;
17458 : 51161 : tem = captures[1];
17459 : 51161 : res_op->set_value (tem);
17460 : 51161 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1061, __FILE__, __LINE__, true);
17461 : 51161 : return true;
17462 : : }
17463 : 0 : next_after_fail2082:;
17464 : : }
17465 : : }
17466 : 8150272 : if (integer_all_onesp (_p1))
17467 : : {
17468 : 346566 : {
17469 : 346566 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
17470 : 346566 : gimple_seq *lseq = seq;
17471 : 346566 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2083;
17472 : 346566 : {
17473 : 346566 : tree tem;
17474 : 346566 : tem = captures[0];
17475 : 346566 : res_op->set_value (tem);
17476 : 346566 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1062, __FILE__, __LINE__, true);
17477 : 346566 : return true;
17478 : : }
17479 : 0 : next_after_fail2083:;
17480 : : }
17481 : : }
17482 : 7803706 : if ((_p1 == _p0 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _p0, 0) && types_match (_p1, _p0)))
17483 : : {
17484 : 188 : {
17485 : 188 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
17486 : 188 : if (gimple_simplify_118 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
17487 : 188 : return true;
17488 : : }
17489 : : }
17490 : 7803518 : switch (TREE_CODE (_p0))
17491 : : {
17492 : 7713758 : case SSA_NAME:
17493 : 7713758 : if (gimple *_d1 = get_def (valueize, _p0))
17494 : : {
17495 : 5378696 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
17496 : 5716590 : switch (gimple_assign_rhs_code (_a1))
17497 : : {
17498 : 150267 : case BIT_IOR_EXPR:
17499 : 150267 : {
17500 : 150267 : tree _q20 = gimple_assign_rhs1 (_a1);
17501 : 150267 : _q20 = do_valueize (valueize, _q20);
17502 : 150267 : tree _q21 = gimple_assign_rhs2 (_a1);
17503 : 150267 : _q21 = do_valueize (valueize, _q21);
17504 : 150267 : if (tree_swap_operands_p (_q20, _q21))
17505 : 8180 : std::swap (_q20, _q21);
17506 : 150267 : switch (TREE_CODE (_q21))
17507 : : {
17508 : 23065 : case INTEGER_CST:
17509 : 23065 : {
17510 : 23065 : switch (TREE_CODE (_p1))
17511 : : {
17512 : 8764 : case SSA_NAME:
17513 : 8764 : {
17514 : 8764 : {
17515 : 8764 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _q20, _q21 };
17516 : 8764 : if (gimple_simplify_428 (res_op, seq, valueize, type, captures))
17517 : 1 : return true;
17518 : : }
17519 : 8763 : break;
17520 : : }
17521 : : default:;
17522 : : }
17523 : : break;
17524 : : }
17525 : : default:;
17526 : : }
17527 : 7713757 : break;
17528 : : }
17529 : : default:;
17530 : : }
17531 : : }
17532 : 7713757 : {
17533 : 7713757 : switch (TREE_CODE (_p1))
17534 : : {
17535 : 2706549 : case SSA_NAME:
17536 : 2706549 : if (gimple *_d1 = get_def (valueize, _p1))
17537 : : {
17538 : 2137148 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
17539 : 2073778 : switch (gimple_assign_rhs_code (_a1))
17540 : : {
17541 : 6398 : case BIT_IOR_EXPR:
17542 : 6398 : {
17543 : 6398 : tree _q30 = gimple_assign_rhs1 (_a1);
17544 : 6398 : _q30 = do_valueize (valueize, _q30);
17545 : 6398 : tree _q31 = gimple_assign_rhs2 (_a1);
17546 : 6398 : _q31 = do_valueize (valueize, _q31);
17547 : 6398 : if (tree_swap_operands_p (_q30, _q31))
17548 : 369 : std::swap (_q30, _q31);
17549 : 6398 : switch (TREE_CODE (_q31))
17550 : : {
17551 : 773 : case INTEGER_CST:
17552 : 773 : {
17553 : 773 : {
17554 : 773 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q30, _q31 };
17555 : 773 : if (gimple_simplify_428 (res_op, seq, valueize, type, captures))
17556 : 1 : return true;
17557 : : }
17558 : 772 : break;
17559 : : }
17560 : : default:;
17561 : : }
17562 : 7791021 : break;
17563 : : }
17564 : : default:;
17565 : : }
17566 : : }
17567 : : break;
17568 : 4981071 : case INTEGER_CST:
17569 : 4981071 : {
17570 : 4981071 : {
17571 : 4981071 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
17572 : 9540840 : if (INTEGRAL_TYPE_P (TREE_TYPE (captures[0]))
17573 : 19496154 : && wi::bit_and_not (get_nonzero_bits (captures[0]), wi::to_wide (captures[1])) == 0
17574 : : )
17575 : : {
17576 : 12495 : gimple_seq *lseq = seq;
17577 : 12495 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2084;
17578 : 12495 : {
17579 : 12495 : tree tem;
17580 : 12495 : tem = captures[0];
17581 : 12495 : res_op->set_value (tem);
17582 : 12495 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1063, __FILE__, __LINE__, true);
17583 : 12495 : return true;
17584 : : }
17585 : 0 : next_after_fail2084:;
17586 : : }
17587 : : }
17588 : 4968576 : break;
17589 : : }
17590 : : default:;
17591 : : }
17592 : : }
17593 : : break;
17594 : 7791021 : default:;
17595 : : }
17596 : 7791021 : switch (TREE_CODE (_p1))
17597 : : {
17598 : 2723730 : case SSA_NAME:
17599 : 2723730 : if (gimple *_d1 = get_def (valueize, _p1))
17600 : : {
17601 : 2137147 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
17602 : 2073777 : switch (gimple_assign_rhs_code (_a1))
17603 : : {
17604 : 164433 : case BIT_NOT_EXPR:
17605 : 164433 : {
17606 : 164433 : tree _q30 = gimple_assign_rhs1 (_a1);
17607 : 164433 : _q30 = do_valueize (valueize, _q30);
17608 : 164433 : switch (TREE_CODE (_q30))
17609 : : {
17610 : 164433 : case SSA_NAME:
17611 : 164433 : if (gimple *_d2 = get_def (valueize, _q30))
17612 : : {
17613 : 140654 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
17614 : 137285 : switch (gimple_assign_rhs_code (_a2))
17615 : : {
17616 : 509 : case BIT_AND_EXPR:
17617 : 509 : {
17618 : 509 : tree _q40 = gimple_assign_rhs1 (_a2);
17619 : 509 : _q40 = do_valueize (valueize, _q40);
17620 : 509 : tree _q41 = gimple_assign_rhs2 (_a2);
17621 : 509 : _q41 = do_valueize (valueize, _q41);
17622 : 509 : if (tree_swap_operands_p (_q40, _q41))
17623 : 28 : std::swap (_q40, _q41);
17624 : 509 : if ((_q40 == _p0 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _p0, 0) && types_match (_q40, _p0)))
17625 : : {
17626 : 44 : {
17627 : 44 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q30, _q41 };
17628 : 44 : if (gimple_simplify_116 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
17629 : 44 : return true;
17630 : : }
17631 : : }
17632 : 465 : if ((_q41 == _p0 && ! TREE_SIDE_EFFECTS (_q41)) || (operand_equal_p (_q41, _p0, 0) && types_match (_q41, _p0)))
17633 : : {
17634 : 176 : {
17635 : 176 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q30, _q40 };
17636 : 176 : if (gimple_simplify_116 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
17637 : 0 : return true;
17638 : : }
17639 : : }
17640 : 7790977 : break;
17641 : : }
17642 : : default:;
17643 : : }
17644 : : }
17645 : : break;
17646 : : default:;
17647 : : }
17648 : : break;
17649 : : }
17650 : : default:;
17651 : : }
17652 : : }
17653 : : break;
17654 : 7790977 : default:;
17655 : : }
17656 : 7790977 : switch (TREE_CODE (_p0))
17657 : : {
17658 : 7701217 : case SSA_NAME:
17659 : 7701217 : if (gimple *_d1 = get_def (valueize, _p0))
17660 : : {
17661 : 5368036 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
17662 : 5707243 : switch (gimple_assign_rhs_code (_a1))
17663 : : {
17664 : 150252 : case BIT_IOR_EXPR:
17665 : 150252 : {
17666 : 150252 : tree _q20 = gimple_assign_rhs1 (_a1);
17667 : 150252 : _q20 = do_valueize (valueize, _q20);
17668 : 150252 : tree _q21 = gimple_assign_rhs2 (_a1);
17669 : 150252 : _q21 = do_valueize (valueize, _q21);
17670 : 150252 : if (tree_swap_operands_p (_q20, _q21))
17671 : 8180 : std::swap (_q20, _q21);
17672 : 150252 : switch (TREE_CODE (_p1))
17673 : : {
17674 : 117766 : case SSA_NAME:
17675 : 117766 : if (gimple *_d2 = get_def (valueize, _p1))
17676 : : {
17677 : 113561 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
17678 : 110052 : switch (gimple_assign_rhs_code (_a2))
17679 : : {
17680 : 101830 : case BIT_NOT_EXPR:
17681 : 101830 : {
17682 : 101830 : tree _q50 = gimple_assign_rhs1 (_a2);
17683 : 101830 : _q50 = do_valueize (valueize, _q50);
17684 : 101830 : switch (TREE_CODE (_q50))
17685 : : {
17686 : 101830 : case SSA_NAME:
17687 : 101830 : if (gimple *_d3 = get_def (valueize, _q50))
17688 : : {
17689 : 85856 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
17690 : 85877 : switch (gimple_assign_rhs_code (_a3))
17691 : : {
17692 : 8 : case BIT_AND_EXPR:
17693 : 8 : {
17694 : 8 : tree _q60 = gimple_assign_rhs1 (_a3);
17695 : 8 : _q60 = do_valueize (valueize, _q60);
17696 : 8 : tree _q61 = gimple_assign_rhs2 (_a3);
17697 : 8 : _q61 = do_valueize (valueize, _q61);
17698 : 8 : if (tree_swap_operands_p (_q60, _q61))
17699 : 2 : std::swap (_q60, _q61);
17700 : 8 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
17701 : : {
17702 : 8 : if ((_q61 == _q21 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q21, 0) && types_match (_q61, _q21)))
17703 : : {
17704 : 8 : {
17705 : 8 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
17706 : 8 : if (gimple_simplify_429 (res_op, seq, valueize, type, captures))
17707 : 8 : return true;
17708 : : }
17709 : : }
17710 : : }
17711 : 150236 : break;
17712 : : }
17713 : : default:;
17714 : : }
17715 : : }
17716 : : break;
17717 : : default:;
17718 : : }
17719 : : break;
17720 : : }
17721 : 138 : case BIT_XOR_EXPR:
17722 : 138 : {
17723 : 138 : tree _q50 = gimple_assign_rhs1 (_a2);
17724 : 138 : _q50 = do_valueize (valueize, _q50);
17725 : 138 : tree _q51 = gimple_assign_rhs2 (_a2);
17726 : 138 : _q51 = do_valueize (valueize, _q51);
17727 : 138 : if (tree_swap_operands_p (_q50, _q51))
17728 : 0 : std::swap (_q50, _q51);
17729 : 138 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
17730 : : {
17731 : 0 : {
17732 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _q51 };
17733 : 0 : if (gimple_simplify_430 (res_op, seq, valueize, type, captures))
17734 : 0 : return true;
17735 : : }
17736 : : }
17737 : 138 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
17738 : : {
17739 : 10 : {
17740 : 10 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _q50 };
17741 : 10 : if (gimple_simplify_430 (res_op, seq, valueize, type, captures))
17742 : 8 : return true;
17743 : : }
17744 : : }
17745 : 130 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
17746 : : {
17747 : 0 : {
17748 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q21, _q20, _q51 };
17749 : 0 : if (gimple_simplify_430 (res_op, seq, valueize, type, captures))
17750 : 0 : return true;
17751 : : }
17752 : : }
17753 : 130 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
17754 : : {
17755 : 0 : {
17756 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q21, _q20, _q50 };
17757 : 0 : if (gimple_simplify_430 (res_op, seq, valueize, type, captures))
17758 : 0 : return true;
17759 : : }
17760 : : }
17761 : 150236 : break;
17762 : : }
17763 : : default:;
17764 : : }
17765 : : }
17766 : : break;
17767 : 150236 : default:;
17768 : : }
17769 : 150236 : switch (TREE_CODE (_q20))
17770 : : {
17771 : 150236 : case SSA_NAME:
17772 : 150236 : if (gimple *_d2 = get_def (valueize, _q20))
17773 : : {
17774 : 131462 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
17775 : 146681 : switch (gimple_assign_rhs_code (_a2))
17776 : : {
17777 : 206 : case BIT_NOT_EXPR:
17778 : 206 : {
17779 : 206 : tree _q30 = gimple_assign_rhs1 (_a2);
17780 : 206 : _q30 = do_valueize (valueize, _q30);
17781 : 206 : switch (TREE_CODE (_p1))
17782 : : {
17783 : 205 : case SSA_NAME:
17784 : 205 : if (gimple *_d3 = get_def (valueize, _p1))
17785 : : {
17786 : 202 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
17787 : 71 : switch (gimple_assign_rhs_code (_a3))
17788 : : {
17789 : 0 : case BIT_IOR_EXPR:
17790 : 0 : {
17791 : 0 : tree _q60 = gimple_assign_rhs1 (_a3);
17792 : 0 : _q60 = do_valueize (valueize, _q60);
17793 : 0 : tree _q61 = gimple_assign_rhs2 (_a3);
17794 : 0 : _q61 = do_valueize (valueize, _q61);
17795 : 0 : if (tree_swap_operands_p (_q60, _q61))
17796 : 0 : std::swap (_q60, _q61);
17797 : 0 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
17798 : : {
17799 : 0 : switch (TREE_CODE (_q61))
17800 : : {
17801 : 0 : case SSA_NAME:
17802 : 0 : if (gimple *_d4 = get_def (valueize, _q61))
17803 : : {
17804 : 0 : if (gassign *_a4 = dyn_cast <gassign *> (_d4))
17805 : 0 : switch (gimple_assign_rhs_code (_a4))
17806 : : {
17807 : 0 : case BIT_NOT_EXPR:
17808 : 0 : {
17809 : 0 : tree _q80 = gimple_assign_rhs1 (_a4);
17810 : 0 : _q80 = do_valueize (valueize, _q80);
17811 : 0 : if ((_q80 == _q21 && ! TREE_SIDE_EFFECTS (_q80)) || (operand_equal_p (_q80, _q21, 0) && types_match (_q80, _q21)))
17812 : : {
17813 : 0 : {
17814 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q30, _q21, _p1 };
17815 : 0 : if (gimple_simplify_431 (res_op, seq, valueize, type, captures))
17816 : 0 : return true;
17817 : : }
17818 : : }
17819 : : break;
17820 : : }
17821 : : default:;
17822 : : }
17823 : : }
17824 : : break;
17825 : : default:;
17826 : : }
17827 : : }
17828 : 0 : switch (TREE_CODE (_q60))
17829 : : {
17830 : 0 : case SSA_NAME:
17831 : 0 : if (gimple *_d4 = get_def (valueize, _q60))
17832 : : {
17833 : 0 : if (gassign *_a4 = dyn_cast <gassign *> (_d4))
17834 : 0 : switch (gimple_assign_rhs_code (_a4))
17835 : : {
17836 : 0 : case BIT_NOT_EXPR:
17837 : 0 : {
17838 : 0 : tree _q70 = gimple_assign_rhs1 (_a4);
17839 : 0 : _q70 = do_valueize (valueize, _q70);
17840 : 0 : if ((_q70 == _q21 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q21, 0) && types_match (_q70, _q21)))
17841 : : {
17842 : 0 : if ((_q61 == _q30 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q30, 0) && types_match (_q61, _q30)))
17843 : : {
17844 : 0 : {
17845 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q30, _q21, _p1 };
17846 : 0 : if (gimple_simplify_431 (res_op, seq, valueize, type, captures))
17847 : 0 : return true;
17848 : : }
17849 : : }
17850 : : }
17851 : : break;
17852 : : }
17853 : : default:;
17854 : : }
17855 : : }
17856 : : break;
17857 : : default:;
17858 : : }
17859 : 150236 : break;
17860 : : }
17861 : : default:;
17862 : : }
17863 : : }
17864 : : break;
17865 : : default:;
17866 : : }
17867 : : break;
17868 : : }
17869 : : default:;
17870 : : }
17871 : : }
17872 : : break;
17873 : 150236 : default:;
17874 : : }
17875 : 150236 : switch (TREE_CODE (_q21))
17876 : : {
17877 : 127142 : case SSA_NAME:
17878 : 127142 : if (gimple *_d2 = get_def (valueize, _q21))
17879 : : {
17880 : 109364 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
17881 : 132363 : switch (gimple_assign_rhs_code (_a2))
17882 : : {
17883 : 1 : case BIT_NOT_EXPR:
17884 : 1 : {
17885 : 1 : tree _q40 = gimple_assign_rhs1 (_a2);
17886 : 1 : _q40 = do_valueize (valueize, _q40);
17887 : 1 : switch (TREE_CODE (_p1))
17888 : : {
17889 : 1 : case SSA_NAME:
17890 : 1 : if (gimple *_d3 = get_def (valueize, _p1))
17891 : : {
17892 : 1 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
17893 : 1 : switch (gimple_assign_rhs_code (_a3))
17894 : : {
17895 : 1 : case BIT_IOR_EXPR:
17896 : 1 : {
17897 : 1 : tree _q60 = gimple_assign_rhs1 (_a3);
17898 : 1 : _q60 = do_valueize (valueize, _q60);
17899 : 1 : tree _q61 = gimple_assign_rhs2 (_a3);
17900 : 1 : _q61 = do_valueize (valueize, _q61);
17901 : 1 : if (tree_swap_operands_p (_q60, _q61))
17902 : 0 : std::swap (_q60, _q61);
17903 : 1 : if ((_q60 == _q40 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q40, 0) && types_match (_q60, _q40)))
17904 : : {
17905 : 0 : switch (TREE_CODE (_q61))
17906 : : {
17907 : 0 : case SSA_NAME:
17908 : 0 : if (gimple *_d4 = get_def (valueize, _q61))
17909 : : {
17910 : 0 : if (gassign *_a4 = dyn_cast <gassign *> (_d4))
17911 : 0 : switch (gimple_assign_rhs_code (_a4))
17912 : : {
17913 : 0 : case BIT_NOT_EXPR:
17914 : 0 : {
17915 : 0 : tree _q80 = gimple_assign_rhs1 (_a4);
17916 : 0 : _q80 = do_valueize (valueize, _q80);
17917 : 0 : if ((_q80 == _q20 && ! TREE_SIDE_EFFECTS (_q80)) || (operand_equal_p (_q80, _q20, 0) && types_match (_q80, _q20)))
17918 : : {
17919 : 0 : {
17920 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q40, _q20, _p1 };
17921 : 0 : if (gimple_simplify_431 (res_op, seq, valueize, type, captures))
17922 : 0 : return true;
17923 : : }
17924 : : }
17925 : : break;
17926 : : }
17927 : : default:;
17928 : : }
17929 : : }
17930 : : break;
17931 : : default:;
17932 : : }
17933 : : }
17934 : 1 : switch (TREE_CODE (_q60))
17935 : : {
17936 : 1 : case SSA_NAME:
17937 : 1 : if (gimple *_d4 = get_def (valueize, _q60))
17938 : : {
17939 : 1 : if (gassign *_a4 = dyn_cast <gassign *> (_d4))
17940 : 1 : switch (gimple_assign_rhs_code (_a4))
17941 : : {
17942 : 1 : case BIT_NOT_EXPR:
17943 : 1 : {
17944 : 1 : tree _q70 = gimple_assign_rhs1 (_a4);
17945 : 1 : _q70 = do_valueize (valueize, _q70);
17946 : 1 : if ((_q70 == _q20 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q20, 0) && types_match (_q70, _q20)))
17947 : : {
17948 : 1 : if ((_q61 == _q40 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q40, 0) && types_match (_q61, _q40)))
17949 : : {
17950 : 1 : {
17951 : 1 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q40, _q20, _p1 };
17952 : 1 : if (gimple_simplify_431 (res_op, seq, valueize, type, captures))
17953 : 1 : return true;
17954 : : }
17955 : : }
17956 : : }
17957 : : break;
17958 : : }
17959 : : default:;
17960 : : }
17961 : : }
17962 : : break;
17963 : : default:;
17964 : : }
17965 : 7790273 : break;
17966 : : }
17967 : : default:;
17968 : : }
17969 : : }
17970 : : break;
17971 : : default:;
17972 : : }
17973 : : break;
17974 : : }
17975 : : default:;
17976 : : }
17977 : : }
17978 : : break;
17979 : : default:;
17980 : : }
17981 : 7790273 : break;
17982 : : }
17983 : 53094 : case BIT_NOT_EXPR:
17984 : 53094 : {
17985 : 53094 : tree _q20 = gimple_assign_rhs1 (_a1);
17986 : 53094 : _q20 = do_valueize (valueize, _q20);
17987 : 53094 : switch (TREE_CODE (_q20))
17988 : : {
17989 : 53094 : case SSA_NAME:
17990 : 53094 : if (gimple *_d2 = get_def (valueize, _q20))
17991 : : {
17992 : 50062 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
17993 : 45822 : switch (gimple_assign_rhs_code (_a2))
17994 : : {
17995 : 537 : case BIT_AND_EXPR:
17996 : 537 : {
17997 : 537 : tree _q30 = gimple_assign_rhs1 (_a2);
17998 : 537 : _q30 = do_valueize (valueize, _q30);
17999 : 537 : tree _q31 = gimple_assign_rhs2 (_a2);
18000 : 537 : _q31 = do_valueize (valueize, _q31);
18001 : 537 : if (tree_swap_operands_p (_q30, _q31))
18002 : 24 : std::swap (_q30, _q31);
18003 : 537 : switch (TREE_CODE (_p1))
18004 : : {
18005 : 532 : case SSA_NAME:
18006 : 532 : if (gimple *_d3 = get_def (valueize, _p1))
18007 : : {
18008 : 520 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
18009 : 504 : switch (gimple_assign_rhs_code (_a3))
18010 : : {
18011 : 8 : case BIT_IOR_EXPR:
18012 : 8 : {
18013 : 8 : tree _q60 = gimple_assign_rhs1 (_a3);
18014 : 8 : _q60 = do_valueize (valueize, _q60);
18015 : 8 : tree _q61 = gimple_assign_rhs2 (_a3);
18016 : 8 : _q61 = do_valueize (valueize, _q61);
18017 : 8 : if (tree_swap_operands_p (_q60, _q61))
18018 : 2 : std::swap (_q60, _q61);
18019 : 8 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
18020 : : {
18021 : 8 : if ((_q61 == _q31 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q31, 0) && types_match (_q61, _q31)))
18022 : : {
18023 : 8 : {
18024 : 8 : tree captures[2] ATTRIBUTE_UNUSED = { _q30, _q31 };
18025 : 8 : if (gimple_simplify_429 (res_op, seq, valueize, type, captures))
18026 : 8 : return true;
18027 : : }
18028 : : }
18029 : : }
18030 : 53086 : break;
18031 : : }
18032 : : default:;
18033 : : }
18034 : : }
18035 : : break;
18036 : : default:;
18037 : : }
18038 : 53086 : break;
18039 : : }
18040 : : default:;
18041 : : }
18042 : : }
18043 : : break;
18044 : 53086 : default:;
18045 : : }
18046 : 53086 : switch (TREE_CODE (_p1))
18047 : : {
18048 : 41742 : case SSA_NAME:
18049 : 41742 : if (gimple *_d2 = get_def (valueize, _p1))
18050 : : {
18051 : 38226 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
18052 : 39322 : switch (gimple_assign_rhs_code (_a2))
18053 : : {
18054 : 1830 : CASE_CONVERT:
18055 : 1830 : {
18056 : 1830 : tree _q40 = gimple_assign_rhs1 (_a2);
18057 : 1830 : _q40 = do_valueize (valueize, _q40);
18058 : 1830 : switch (TREE_CODE (_q40))
18059 : : {
18060 : 1830 : case SSA_NAME:
18061 : 1830 : if (gimple *_d3 = get_def (valueize, _q40))
18062 : : {
18063 : 1768 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
18064 : 1810 : switch (gimple_assign_rhs_code (_a3))
18065 : : {
18066 : 27 : case BIT_NOT_EXPR:
18067 : 27 : {
18068 : 27 : tree _q50 = gimple_assign_rhs1 (_a3);
18069 : 27 : _q50 = do_valueize (valueize, _q50);
18070 : 27 : {
18071 : 27 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q50 };
18072 : 27 : if (gimple_simplify_123 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
18073 : 7 : return true;
18074 : : }
18075 : 20 : break;
18076 : : }
18077 : : default:;
18078 : : }
18079 : : }
18080 : : break;
18081 : : default:;
18082 : : }
18083 : : break;
18084 : : }
18085 : 1900 : case BIT_NOT_EXPR:
18086 : 1900 : {
18087 : 1900 : tree _q40 = gimple_assign_rhs1 (_a2);
18088 : 1900 : _q40 = do_valueize (valueize, _q40);
18089 : 1900 : {
18090 : 1900 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q40 };
18091 : 1900 : if (gimple_simplify_123 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
18092 : 610 : return true;
18093 : : }
18094 : 1290 : break;
18095 : : }
18096 : : default:;
18097 : : }
18098 : : }
18099 : : break;
18100 : : default:;
18101 : : }
18102 : : break;
18103 : : }
18104 : 67299 : case BIT_XOR_EXPR:
18105 : 67299 : {
18106 : 67299 : tree _q20 = gimple_assign_rhs1 (_a1);
18107 : 67299 : _q20 = do_valueize (valueize, _q20);
18108 : 67299 : tree _q21 = gimple_assign_rhs2 (_a1);
18109 : 67299 : _q21 = do_valueize (valueize, _q21);
18110 : 67299 : if (tree_swap_operands_p (_q20, _q21))
18111 : 3662 : std::swap (_q20, _q21);
18112 : 67299 : switch (TREE_CODE (_p1))
18113 : : {
18114 : 19440 : case SSA_NAME:
18115 : 19440 : if (gimple *_d2 = get_def (valueize, _p1))
18116 : : {
18117 : 11270 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
18118 : 11923 : switch (gimple_assign_rhs_code (_a2))
18119 : : {
18120 : 168 : case BIT_IOR_EXPR:
18121 : 168 : {
18122 : 168 : tree _q50 = gimple_assign_rhs1 (_a2);
18123 : 168 : _q50 = do_valueize (valueize, _q50);
18124 : 168 : tree _q51 = gimple_assign_rhs2 (_a2);
18125 : 168 : _q51 = do_valueize (valueize, _q51);
18126 : 168 : if (tree_swap_operands_p (_q50, _q51))
18127 : 8 : std::swap (_q50, _q51);
18128 : 168 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
18129 : : {
18130 : 0 : {
18131 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q50, _q20, _q21 };
18132 : 0 : if (gimple_simplify_430 (res_op, seq, valueize, type, captures))
18133 : 0 : return true;
18134 : : }
18135 : : }
18136 : 168 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
18137 : : {
18138 : 0 : {
18139 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q50, _q21, _q20 };
18140 : 0 : if (gimple_simplify_430 (res_op, seq, valueize, type, captures))
18141 : 0 : return true;
18142 : : }
18143 : : }
18144 : 168 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
18145 : : {
18146 : 0 : {
18147 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q51, _q20, _q21 };
18148 : 0 : if (gimple_simplify_430 (res_op, seq, valueize, type, captures))
18149 : 0 : return true;
18150 : : }
18151 : : }
18152 : 168 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
18153 : : {
18154 : 0 : {
18155 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q51, _q21, _q20 };
18156 : 0 : if (gimple_simplify_430 (res_op, seq, valueize, type, captures))
18157 : 0 : return true;
18158 : : }
18159 : : }
18160 : 67299 : break;
18161 : : }
18162 : : default:;
18163 : : }
18164 : : }
18165 : : break;
18166 : 67299 : default:;
18167 : : }
18168 : 67299 : if ((_p1 == _q21 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q21, 0) && types_match (_p1, _q21)))
18169 : : {
18170 : 94 : {
18171 : 94 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q21 };
18172 : 94 : if (gimple_simplify_24 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_XOR_EXPR))
18173 : 62 : return true;
18174 : : }
18175 : : }
18176 : 67237 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
18177 : : {
18178 : 0 : {
18179 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q21, _q20 };
18180 : 0 : if (gimple_simplify_24 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_XOR_EXPR))
18181 : 0 : return true;
18182 : : }
18183 : : }
18184 : 7790273 : break;
18185 : : }
18186 : 408792 : CASE_CONVERT:
18187 : 408792 : {
18188 : 408792 : tree _q20 = gimple_assign_rhs1 (_a1);
18189 : 408792 : _q20 = do_valueize (valueize, _q20);
18190 : 408792 : switch (TREE_CODE (_q20))
18191 : : {
18192 : 407851 : case SSA_NAME:
18193 : 407851 : if (gimple *_d2 = get_def (valueize, _q20))
18194 : : {
18195 : 381406 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
18196 : 368782 : switch (gimple_assign_rhs_code (_a2))
18197 : : {
18198 : 1463 : case BIT_NOT_EXPR:
18199 : 1463 : {
18200 : 1463 : tree _q30 = gimple_assign_rhs1 (_a2);
18201 : 1463 : _q30 = do_valueize (valueize, _q30);
18202 : 1463 : switch (TREE_CODE (_p1))
18203 : : {
18204 : 1317 : case SSA_NAME:
18205 : 1317 : if (gimple *_d3 = get_def (valueize, _p1))
18206 : : {
18207 : 1269 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
18208 : 1119 : switch (gimple_assign_rhs_code (_a3))
18209 : : {
18210 : 132 : CASE_CONVERT:
18211 : 132 : {
18212 : 132 : tree _q50 = gimple_assign_rhs1 (_a3);
18213 : 132 : _q50 = do_valueize (valueize, _q50);
18214 : 132 : switch (TREE_CODE (_q50))
18215 : : {
18216 : 132 : case SSA_NAME:
18217 : 132 : if (gimple *_d4 = get_def (valueize, _q50))
18218 : : {
18219 : 132 : if (gassign *_a4 = dyn_cast <gassign *> (_d4))
18220 : 181 : switch (gimple_assign_rhs_code (_a4))
18221 : : {
18222 : 5 : case BIT_NOT_EXPR:
18223 : 5 : {
18224 : 5 : tree _q60 = gimple_assign_rhs1 (_a4);
18225 : 5 : _q60 = do_valueize (valueize, _q60);
18226 : 5 : {
18227 : 5 : tree captures[2] ATTRIBUTE_UNUSED = { _q30, _q60 };
18228 : 5 : if (gimple_simplify_123 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
18229 : 0 : return true;
18230 : : }
18231 : 5 : break;
18232 : : }
18233 : : default:;
18234 : : }
18235 : : }
18236 : : break;
18237 : : default:;
18238 : : }
18239 : : break;
18240 : : }
18241 : 11 : case BIT_NOT_EXPR:
18242 : 11 : {
18243 : 11 : tree _q50 = gimple_assign_rhs1 (_a3);
18244 : 11 : _q50 = do_valueize (valueize, _q50);
18245 : 11 : {
18246 : 11 : tree captures[2] ATTRIBUTE_UNUSED = { _q30, _q50 };
18247 : 11 : if (gimple_simplify_123 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
18248 : 0 : return true;
18249 : : }
18250 : 11 : break;
18251 : : }
18252 : : default:;
18253 : : }
18254 : : }
18255 : : break;
18256 : : default:;
18257 : : }
18258 : : break;
18259 : : }
18260 : : default:;
18261 : : }
18262 : : }
18263 : : break;
18264 : : default:;
18265 : : }
18266 : : break;
18267 : : }
18268 : : default:;
18269 : : }
18270 : : }
18271 : : break;
18272 : 7790273 : default:;
18273 : : }
18274 : 7790273 : switch (TREE_CODE (_p1))
18275 : : {
18276 : 2723044 : case SSA_NAME:
18277 : 2723044 : if (gimple *_d1 = get_def (valueize, _p1))
18278 : : {
18279 : 2136461 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
18280 : 2073091 : switch (gimple_assign_rhs_code (_a1))
18281 : : {
18282 : 14671 : case BIT_XOR_EXPR:
18283 : 14671 : {
18284 : 14671 : tree _q30 = gimple_assign_rhs1 (_a1);
18285 : 14671 : _q30 = do_valueize (valueize, _q30);
18286 : 14671 : tree _q31 = gimple_assign_rhs2 (_a1);
18287 : 14671 : _q31 = do_valueize (valueize, _q31);
18288 : 14671 : if (tree_swap_operands_p (_q30, _q31))
18289 : 476 : std::swap (_q30, _q31);
18290 : 14671 : if ((_q31 == _p0 && ! TREE_SIDE_EFFECTS (_q31)) || (operand_equal_p (_q31, _p0, 0) && types_match (_q31, _p0)))
18291 : : {
18292 : 0 : {
18293 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _q30, _p0 };
18294 : 0 : if (gimple_simplify_24 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_XOR_EXPR))
18295 : 0 : return true;
18296 : : }
18297 : : }
18298 : 14671 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || (operand_equal_p (_q30, _p0, 0) && types_match (_q30, _p0)))
18299 : : {
18300 : 16 : {
18301 : 16 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _q31, _p0 };
18302 : 16 : if (gimple_simplify_24 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_XOR_EXPR))
18303 : 9 : return true;
18304 : : }
18305 : : }
18306 : 7790264 : break;
18307 : : }
18308 : : default:;
18309 : : }
18310 : : }
18311 : : break;
18312 : 7790264 : default:;
18313 : : }
18314 : 7790264 : switch (TREE_CODE (_p0))
18315 : : {
18316 : 7700504 : case SSA_NAME:
18317 : 7700504 : if (gimple *_d1 = get_def (valueize, _p0))
18318 : : {
18319 : 5367324 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
18320 : 5706531 : switch (gimple_assign_rhs_code (_a1))
18321 : : {
18322 : 408784 : CASE_CONVERT:
18323 : 408784 : {
18324 : 408784 : tree _q20 = gimple_assign_rhs1 (_a1);
18325 : 408784 : _q20 = do_valueize (valueize, _q20);
18326 : 408784 : switch (TREE_CODE (_q20))
18327 : : {
18328 : 407843 : case SSA_NAME:
18329 : 407843 : if (gimple *_d2 = get_def (valueize, _q20))
18330 : : {
18331 : 381398 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
18332 : 368766 : switch (gimple_assign_rhs_code (_a2))
18333 : : {
18334 : 726 : case BIT_IOR_EXPR:
18335 : 726 : {
18336 : 726 : tree _q30 = gimple_assign_rhs1 (_a2);
18337 : 726 : _q30 = do_valueize (valueize, _q30);
18338 : 726 : tree _q31 = gimple_assign_rhs2 (_a2);
18339 : 726 : _q31 = do_valueize (valueize, _q31);
18340 : 726 : if (tree_swap_operands_p (_q30, _q31))
18341 : 12 : std::swap (_q30, _q31);
18342 : 726 : switch (TREE_CODE (_p1))
18343 : : {
18344 : 336 : case SSA_NAME:
18345 : 336 : if (gimple *_d3 = get_def (valueize, _p1))
18346 : : {
18347 : 336 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
18348 : 343 : switch (gimple_assign_rhs_code (_a3))
18349 : : {
18350 : 216 : CASE_CONVERT:
18351 : 216 : {
18352 : 216 : tree _q60 = gimple_assign_rhs1 (_a3);
18353 : 216 : _q60 = do_valueize (valueize, _q60);
18354 : 216 : switch (TREE_CODE (_q60))
18355 : : {
18356 : 216 : case SSA_NAME:
18357 : 216 : if (gimple *_d4 = get_def (valueize, _q60))
18358 : : {
18359 : 216 : if (gassign *_a4 = dyn_cast <gassign *> (_d4))
18360 : 413 : switch (gimple_assign_rhs_code (_a4))
18361 : : {
18362 : 0 : case BIT_IOR_EXPR:
18363 : 0 : {
18364 : 0 : tree _q70 = gimple_assign_rhs1 (_a4);
18365 : 0 : _q70 = do_valueize (valueize, _q70);
18366 : 0 : tree _q71 = gimple_assign_rhs2 (_a4);
18367 : 0 : _q71 = do_valueize (valueize, _q71);
18368 : 0 : if (tree_swap_operands_p (_q70, _q71))
18369 : 0 : std::swap (_q70, _q71);
18370 : 0 : if ((_q70 == _q30 && ! TREE_SIDE_EFFECTS (_q70)) || operand_equal_p (_q70, _q30, 0))
18371 : : {
18372 : 0 : {
18373 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q30, _q31, _q71, _q30 };
18374 : 0 : if (gimple_simplify_25 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
18375 : 0 : return true;
18376 : : }
18377 : : }
18378 : 0 : if ((_q71 == _q30 && ! TREE_SIDE_EFFECTS (_q71)) || operand_equal_p (_q71, _q30, 0))
18379 : : {
18380 : 0 : {
18381 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q30, _q31, _q70, _q30 };
18382 : 0 : if (gimple_simplify_25 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
18383 : 0 : return true;
18384 : : }
18385 : : }
18386 : 0 : if ((_q70 == _q31 && ! TREE_SIDE_EFFECTS (_q70)) || operand_equal_p (_q70, _q31, 0))
18387 : : {
18388 : 0 : {
18389 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q31, _q30, _q71, _q31 };
18390 : 0 : if (gimple_simplify_25 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
18391 : 0 : return true;
18392 : : }
18393 : : }
18394 : 0 : if ((_q71 == _q31 && ! TREE_SIDE_EFFECTS (_q71)) || operand_equal_p (_q71, _q31, 0))
18395 : : {
18396 : 0 : {
18397 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q31, _q30, _q70, _q31 };
18398 : 0 : if (gimple_simplify_25 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
18399 : 0 : return true;
18400 : : }
18401 : : }
18402 : 408783 : break;
18403 : : }
18404 : : default:;
18405 : : }
18406 : : }
18407 : : break;
18408 : : default:;
18409 : : }
18410 : : break;
18411 : : }
18412 : : default:;
18413 : : }
18414 : : }
18415 : : break;
18416 : : default:;
18417 : : }
18418 : 408783 : break;
18419 : : }
18420 : 2034 : case BIT_AND_EXPR:
18421 : 2034 : {
18422 : 2034 : tree _q30 = gimple_assign_rhs1 (_a2);
18423 : 2034 : _q30 = do_valueize (valueize, _q30);
18424 : 2034 : tree _q31 = gimple_assign_rhs2 (_a2);
18425 : 2034 : _q31 = do_valueize (valueize, _q31);
18426 : 2034 : if (tree_swap_operands_p (_q30, _q31))
18427 : 22 : std::swap (_q30, _q31);
18428 : 2034 : switch (TREE_CODE (_p1))
18429 : : {
18430 : 981 : case SSA_NAME:
18431 : 981 : if (gimple *_d3 = get_def (valueize, _p1))
18432 : : {
18433 : 956 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
18434 : 976 : switch (gimple_assign_rhs_code (_a3))
18435 : : {
18436 : 487 : CASE_CONVERT:
18437 : 487 : {
18438 : 487 : tree _q60 = gimple_assign_rhs1 (_a3);
18439 : 487 : _q60 = do_valueize (valueize, _q60);
18440 : 487 : if ((_q60 == _q31 && ! TREE_SIDE_EFFECTS (_q60)) || operand_equal_p (_q60, _q31, 0))
18441 : : {
18442 : 0 : {
18443 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q30, _q31, _q31 };
18444 : 0 : if (gimple_simplify_109 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18445 : 0 : return true;
18446 : : }
18447 : : }
18448 : 487 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || operand_equal_p (_q60, _q30, 0))
18449 : : {
18450 : 0 : {
18451 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q31, _q30, _q30 };
18452 : 0 : if (gimple_simplify_109 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18453 : 0 : return true;
18454 : : }
18455 : : }
18456 : : break;
18457 : : }
18458 : : default:;
18459 : : }
18460 : : }
18461 : : break;
18462 : 2034 : default:;
18463 : : }
18464 : 2034 : if ((_p1 == _q31 && ! TREE_SIDE_EFFECTS (_p1)) || operand_equal_p (_p1, _q31, 0))
18465 : : {
18466 : 1 : {
18467 : 1 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q30, _q31, _q31 };
18468 : 1 : if (gimple_simplify_109 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18469 : 1 : return true;
18470 : : }
18471 : : }
18472 : 2033 : if ((_p1 == _q30 && ! TREE_SIDE_EFFECTS (_p1)) || operand_equal_p (_p1, _q30, 0))
18473 : : {
18474 : 0 : {
18475 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q31, _q30, _q30 };
18476 : 0 : if (gimple_simplify_109 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18477 : 0 : return true;
18478 : : }
18479 : : }
18480 : 408783 : break;
18481 : : }
18482 : : default:;
18483 : : }
18484 : : }
18485 : : break;
18486 : 408783 : default:;
18487 : : }
18488 : 408783 : switch (TREE_CODE (_p1))
18489 : : {
18490 : 78506 : case SSA_NAME:
18491 : 78506 : if (gimple *_d2 = get_def (valueize, _p1))
18492 : : {
18493 : 75674 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
18494 : 57466 : switch (gimple_assign_rhs_code (_a2))
18495 : : {
18496 : 25335 : CASE_CONVERT:
18497 : 25335 : {
18498 : 25335 : tree _q40 = gimple_assign_rhs1 (_a2);
18499 : 25335 : _q40 = do_valueize (valueize, _q40);
18500 : 25335 : switch (TREE_CODE (_q40))
18501 : : {
18502 : 25335 : case SSA_NAME:
18503 : 25335 : if (gimple *_d3 = get_def (valueize, _q40))
18504 : : {
18505 : 23364 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
18506 : 8874 : switch (gimple_assign_rhs_code (_a3))
18507 : : {
18508 : 401 : case BIT_AND_EXPR:
18509 : 401 : {
18510 : 401 : tree _q50 = gimple_assign_rhs1 (_a3);
18511 : 401 : _q50 = do_valueize (valueize, _q50);
18512 : 401 : tree _q51 = gimple_assign_rhs2 (_a3);
18513 : 401 : _q51 = do_valueize (valueize, _q51);
18514 : 401 : if (tree_swap_operands_p (_q50, _q51))
18515 : 7 : std::swap (_q50, _q51);
18516 : 401 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || operand_equal_p (_q51, _q20, 0))
18517 : : {
18518 : 0 : {
18519 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p1, _q50, _q51, _q20 };
18520 : 0 : if (gimple_simplify_124 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18521 : 0 : return true;
18522 : : }
18523 : : }
18524 : 401 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || operand_equal_p (_q50, _q20, 0))
18525 : : {
18526 : 0 : {
18527 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p1, _q51, _q50, _q20 };
18528 : 0 : if (gimple_simplify_124 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18529 : 0 : return true;
18530 : : }
18531 : : }
18532 : 7790263 : break;
18533 : : }
18534 : : default:;
18535 : : }
18536 : : }
18537 : : break;
18538 : : default:;
18539 : : }
18540 : : break;
18541 : : }
18542 : 1051 : case BIT_AND_EXPR:
18543 : 1051 : {
18544 : 1051 : tree _q40 = gimple_assign_rhs1 (_a2);
18545 : 1051 : _q40 = do_valueize (valueize, _q40);
18546 : 1051 : tree _q41 = gimple_assign_rhs2 (_a2);
18547 : 1051 : _q41 = do_valueize (valueize, _q41);
18548 : 1051 : if (tree_swap_operands_p (_q40, _q41))
18549 : 63 : std::swap (_q40, _q41);
18550 : 1051 : if ((_q41 == _q20 && ! TREE_SIDE_EFFECTS (_q41)) || operand_equal_p (_q41, _q20, 0))
18551 : : {
18552 : 0 : {
18553 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p1, _q40, _q41, _q20 };
18554 : 0 : if (gimple_simplify_124 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18555 : 0 : return true;
18556 : : }
18557 : : }
18558 : 1051 : if ((_q40 == _q20 && ! TREE_SIDE_EFFECTS (_q40)) || operand_equal_p (_q40, _q20, 0))
18559 : : {
18560 : 0 : {
18561 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p1, _q41, _q40, _q20 };
18562 : 0 : if (gimple_simplify_124 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18563 : 0 : return true;
18564 : : }
18565 : : }
18566 : 7790263 : break;
18567 : : }
18568 : : default:;
18569 : : }
18570 : : }
18571 : : break;
18572 : : default:;
18573 : : }
18574 : : break;
18575 : : }
18576 : 150235 : case BIT_IOR_EXPR:
18577 : 150235 : {
18578 : 150235 : tree _q20 = gimple_assign_rhs1 (_a1);
18579 : 150235 : _q20 = do_valueize (valueize, _q20);
18580 : 150235 : tree _q21 = gimple_assign_rhs2 (_a1);
18581 : 150235 : _q21 = do_valueize (valueize, _q21);
18582 : 150235 : if (tree_swap_operands_p (_q20, _q21))
18583 : 8180 : std::swap (_q20, _q21);
18584 : 150235 : switch (TREE_CODE (_p1))
18585 : : {
18586 : 117749 : case SSA_NAME:
18587 : 117749 : if (gimple *_d2 = get_def (valueize, _p1))
18588 : : {
18589 : 113544 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
18590 : 110035 : switch (gimple_assign_rhs_code (_a2))
18591 : : {
18592 : 410 : case BIT_IOR_EXPR:
18593 : 410 : {
18594 : 410 : tree _q50 = gimple_assign_rhs1 (_a2);
18595 : 410 : _q50 = do_valueize (valueize, _q50);
18596 : 410 : tree _q51 = gimple_assign_rhs2 (_a2);
18597 : 410 : _q51 = do_valueize (valueize, _q51);
18598 : 410 : if (tree_swap_operands_p (_q50, _q51))
18599 : 34 : std::swap (_q50, _q51);
18600 : 410 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || operand_equal_p (_q50, _q20, 0))
18601 : : {
18602 : 0 : {
18603 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q20, _q21, _q51, _q20 };
18604 : 0 : if (gimple_simplify_25 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
18605 : 0 : return true;
18606 : : }
18607 : : }
18608 : 410 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || operand_equal_p (_q51, _q20, 0))
18609 : : {
18610 : 0 : {
18611 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q20, _q21, _q50, _q20 };
18612 : 0 : if (gimple_simplify_25 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
18613 : 0 : return true;
18614 : : }
18615 : : }
18616 : 410 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || operand_equal_p (_q50, _q21, 0))
18617 : : {
18618 : 0 : {
18619 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q21, _q20, _q51, _q21 };
18620 : 0 : if (gimple_simplify_25 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
18621 : 0 : return true;
18622 : : }
18623 : : }
18624 : 410 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || operand_equal_p (_q51, _q21, 0))
18625 : : {
18626 : 0 : {
18627 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q21, _q20, _q50, _q21 };
18628 : 0 : if (gimple_simplify_25 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
18629 : 0 : return true;
18630 : : }
18631 : : }
18632 : 7790263 : break;
18633 : : }
18634 : : default:;
18635 : : }
18636 : : }
18637 : : break;
18638 : : default:;
18639 : : }
18640 : 7790263 : break;
18641 : : }
18642 : : default:;
18643 : : }
18644 : : }
18645 : : break;
18646 : 7790263 : default:;
18647 : : }
18648 : 7790263 : switch (TREE_CODE (_p1))
18649 : : {
18650 : 2723035 : case SSA_NAME:
18651 : 2723035 : if (gimple *_d1 = get_def (valueize, _p1))
18652 : : {
18653 : 2136452 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
18654 : 2073082 : switch (gimple_assign_rhs_code (_a1))
18655 : : {
18656 : 101863 : CASE_CONVERT:
18657 : 101863 : {
18658 : 101863 : tree _q30 = gimple_assign_rhs1 (_a1);
18659 : 101863 : _q30 = do_valueize (valueize, _q30);
18660 : 101863 : switch (TREE_CODE (_q30))
18661 : : {
18662 : 101863 : case SSA_NAME:
18663 : 101863 : if (gimple *_d2 = get_def (valueize, _q30))
18664 : : {
18665 : 98704 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
18666 : 89947 : switch (gimple_assign_rhs_code (_a2))
18667 : : {
18668 : 1510 : case BIT_AND_EXPR:
18669 : 1510 : {
18670 : 1510 : tree _q40 = gimple_assign_rhs1 (_a2);
18671 : 1510 : _q40 = do_valueize (valueize, _q40);
18672 : 1510 : tree _q41 = gimple_assign_rhs2 (_a2);
18673 : 1510 : _q41 = do_valueize (valueize, _q41);
18674 : 1510 : if (tree_swap_operands_p (_q40, _q41))
18675 : 66 : std::swap (_q40, _q41);
18676 : 1510 : if ((_q41 == _p0 && ! TREE_SIDE_EFFECTS (_q41)) || operand_equal_p (_q41, _p0, 0))
18677 : : {
18678 : 0 : {
18679 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p1, _q40, _q41, _p0 };
18680 : 0 : if (gimple_simplify_124 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18681 : 0 : return true;
18682 : : }
18683 : : }
18684 : 1510 : if ((_q40 == _p0 && ! TREE_SIDE_EFFECTS (_q40)) || operand_equal_p (_q40, _p0, 0))
18685 : : {
18686 : 0 : {
18687 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p1, _q41, _q40, _p0 };
18688 : 0 : if (gimple_simplify_124 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18689 : 0 : return true;
18690 : : }
18691 : : }
18692 : 7790263 : break;
18693 : : }
18694 : : default:;
18695 : : }
18696 : : }
18697 : : break;
18698 : : default:;
18699 : : }
18700 : : break;
18701 : : }
18702 : : default:;
18703 : : }
18704 : : }
18705 : : break;
18706 : 7790263 : default:;
18707 : : }
18708 : 7790263 : switch (TREE_CODE (_p0))
18709 : : {
18710 : 7700503 : case SSA_NAME:
18711 : 7700503 : if (gimple *_d1 = get_def (valueize, _p0))
18712 : : {
18713 : 5367323 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
18714 : 5706530 : switch (gimple_assign_rhs_code (_a1))
18715 : : {
18716 : 44415 : case BIT_AND_EXPR:
18717 : 44415 : {
18718 : 44415 : tree _q20 = gimple_assign_rhs1 (_a1);
18719 : 44415 : _q20 = do_valueize (valueize, _q20);
18720 : 44415 : tree _q21 = gimple_assign_rhs2 (_a1);
18721 : 44415 : _q21 = do_valueize (valueize, _q21);
18722 : 44415 : if (tree_swap_operands_p (_q20, _q21))
18723 : 2789 : std::swap (_q20, _q21);
18724 : 44415 : switch (TREE_CODE (_p1))
18725 : : {
18726 : 33371 : case SSA_NAME:
18727 : 33371 : if (gimple *_d2 = get_def (valueize, _p1))
18728 : : {
18729 : 33070 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
18730 : 33192 : switch (gimple_assign_rhs_code (_a2))
18731 : : {
18732 : 1402 : CASE_CONVERT:
18733 : 1402 : {
18734 : 1402 : tree _q50 = gimple_assign_rhs1 (_a2);
18735 : 1402 : _q50 = do_valueize (valueize, _q50);
18736 : 1402 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || operand_equal_p (_q50, _q21, 0))
18737 : : {
18738 : 0 : {
18739 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q21 };
18740 : 0 : if (gimple_simplify_109 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18741 : 0 : return true;
18742 : : }
18743 : : }
18744 : 1402 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || operand_equal_p (_q50, _q20, 0))
18745 : : {
18746 : 0 : {
18747 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _q20 };
18748 : 0 : if (gimple_simplify_109 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18749 : 0 : return true;
18750 : : }
18751 : : }
18752 : : break;
18753 : : }
18754 : : default:;
18755 : : }
18756 : : }
18757 : : break;
18758 : 44415 : default:;
18759 : : }
18760 : 44415 : if ((_p1 == _q21 && ! TREE_SIDE_EFFECTS (_p1)) || operand_equal_p (_p1, _q21, 0))
18761 : : {
18762 : 33 : {
18763 : 33 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q21 };
18764 : 33 : if (gimple_simplify_109 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18765 : 33 : return true;
18766 : : }
18767 : : }
18768 : 44382 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || operand_equal_p (_p1, _q20, 0))
18769 : : {
18770 : 40 : {
18771 : 40 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _q20 };
18772 : 40 : if (gimple_simplify_109 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18773 : 40 : return true;
18774 : : }
18775 : : }
18776 : 44342 : {
18777 : 44342 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
18778 : 44342 : if (gimple_simplify_432 (res_op, seq, valueize, type, captures))
18779 : 117 : return true;
18780 : : }
18781 : 44225 : switch (TREE_CODE (_p1))
18782 : : {
18783 : 33318 : case SSA_NAME:
18784 : 33318 : if (gimple *_d2 = get_def (valueize, _p1))
18785 : : {
18786 : 33019 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
18787 : 33135 : switch (gimple_assign_rhs_code (_a2))
18788 : : {
18789 : 1370 : CASE_CONVERT:
18790 : 1370 : {
18791 : 1370 : tree _q50 = gimple_assign_rhs1 (_a2);
18792 : 1370 : _q50 = do_valueize (valueize, _q50);
18793 : 1370 : switch (TREE_CODE (_q50))
18794 : : {
18795 : 1370 : case SSA_NAME:
18796 : 1370 : if (gimple *_d3 = get_def (valueize, _q50))
18797 : : {
18798 : 1370 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
18799 : 1718 : switch (gimple_assign_rhs_code (_a3))
18800 : : {
18801 : 173 : case BIT_AND_EXPR:
18802 : 173 : {
18803 : 173 : tree _q60 = gimple_assign_rhs1 (_a3);
18804 : 173 : _q60 = do_valueize (valueize, _q60);
18805 : 173 : tree _q61 = gimple_assign_rhs2 (_a3);
18806 : 173 : _q61 = do_valueize (valueize, _q61);
18807 : 173 : if (tree_swap_operands_p (_q60, _q61))
18808 : 25 : std::swap (_q60, _q61);
18809 : 173 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
18810 : : {
18811 : 0 : {
18812 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _p0, _q20, _q21, _p1, _q50, _q61 };
18813 : 0 : if (gimple_simplify_126 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18814 : 0 : return true;
18815 : : }
18816 : : }
18817 : 173 : if ((_q61 == _q20 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q20, 0) && types_match (_q61, _q20)))
18818 : : {
18819 : 0 : {
18820 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _p0, _q20, _q21, _p1, _q50, _q60 };
18821 : 0 : if (gimple_simplify_126 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18822 : 0 : return true;
18823 : : }
18824 : : }
18825 : 173 : if ((_q60 == _q21 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q21, 0) && types_match (_q60, _q21)))
18826 : : {
18827 : 0 : {
18828 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _p0, _q21, _q20, _p1, _q50, _q61 };
18829 : 0 : if (gimple_simplify_126 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18830 : 0 : return true;
18831 : : }
18832 : : }
18833 : 173 : if ((_q61 == _q21 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q21, 0) && types_match (_q61, _q21)))
18834 : : {
18835 : 0 : {
18836 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _p0, _q21, _q20, _p1, _q50, _q60 };
18837 : 0 : if (gimple_simplify_126 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18838 : 0 : return true;
18839 : : }
18840 : : }
18841 : 7790065 : break;
18842 : : }
18843 : : default:;
18844 : : }
18845 : : }
18846 : : break;
18847 : : default:;
18848 : : }
18849 : : break;
18850 : : }
18851 : 2059 : case BIT_AND_EXPR:
18852 : 2059 : {
18853 : 2059 : tree _q50 = gimple_assign_rhs1 (_a2);
18854 : 2059 : _q50 = do_valueize (valueize, _q50);
18855 : 2059 : tree _q51 = gimple_assign_rhs2 (_a2);
18856 : 2059 : _q51 = do_valueize (valueize, _q51);
18857 : 2059 : if (tree_swap_operands_p (_q50, _q51))
18858 : 304 : std::swap (_q50, _q51);
18859 : 2059 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
18860 : : {
18861 : 0 : {
18862 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _p0, _q20, _q21, _p1, _p1, _q51 };
18863 : 0 : if (gimple_simplify_127 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18864 : 0 : return true;
18865 : : }
18866 : : }
18867 : 2059 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
18868 : : {
18869 : 0 : {
18870 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _p0, _q20, _q21, _p1, _p1, _q50 };
18871 : 0 : if (gimple_simplify_127 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18872 : 0 : return true;
18873 : : }
18874 : : }
18875 : 2059 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
18876 : : {
18877 : 2 : {
18878 : 2 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _p0, _q21, _q20, _p1, _p1, _q51 };
18879 : 2 : if (gimple_simplify_127 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18880 : 2 : return true;
18881 : : }
18882 : : }
18883 : 2057 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
18884 : : {
18885 : 6 : {
18886 : 6 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _p0, _q21, _q20, _p1, _p1, _q50 };
18887 : 6 : if (gimple_simplify_127 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18888 : 6 : return true;
18889 : : }
18890 : : }
18891 : 7790065 : break;
18892 : : }
18893 : : default:;
18894 : : }
18895 : : }
18896 : : break;
18897 : : default:;
18898 : : }
18899 : 7790065 : break;
18900 : : }
18901 : : default:;
18902 : : }
18903 : : }
18904 : : break;
18905 : 7790065 : default:;
18906 : : }
18907 : 7790065 : switch (TREE_CODE (_p1))
18908 : : {
18909 : 2722974 : case SSA_NAME:
18910 : 2722974 : if (gimple *_d1 = get_def (valueize, _p1))
18911 : : {
18912 : 2136393 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
18913 : 2073017 : switch (gimple_assign_rhs_code (_a1))
18914 : : {
18915 : 31786 : case BIT_AND_EXPR:
18916 : 31786 : {
18917 : 31786 : tree _q30 = gimple_assign_rhs1 (_a1);
18918 : 31786 : _q30 = do_valueize (valueize, _q30);
18919 : 31786 : tree _q31 = gimple_assign_rhs2 (_a1);
18920 : 31786 : _q31 = do_valueize (valueize, _q31);
18921 : 31786 : if (tree_swap_operands_p (_q30, _q31))
18922 : 2864 : std::swap (_q30, _q31);
18923 : 31786 : if ((_q31 == _p0 && ! TREE_SIDE_EFFECTS (_q31)) || operand_equal_p (_q31, _p0, 0))
18924 : : {
18925 : 93 : {
18926 : 93 : tree captures[4] ATTRIBUTE_UNUSED = { _p1, _q30, _q31, _p0 };
18927 : 93 : if (gimple_simplify_124 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18928 : 93 : return true;
18929 : : }
18930 : : }
18931 : 31693 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || operand_equal_p (_q30, _p0, 0))
18932 : : {
18933 : 152 : {
18934 : 152 : tree captures[4] ATTRIBUTE_UNUSED = { _p1, _q31, _q30, _p0 };
18935 : 152 : if (gimple_simplify_124 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
18936 : 152 : return true;
18937 : : }
18938 : : }
18939 : 31541 : {
18940 : 31541 : tree captures[3] ATTRIBUTE_UNUSED = { _q30, _q31, _p0 };
18941 : 31541 : if (gimple_simplify_432 (res_op, seq, valueize, type, captures))
18942 : 2 : return true;
18943 : : }
18944 : 31539 : break;
18945 : : }
18946 : : default:;
18947 : : }
18948 : : }
18949 : : break;
18950 : 7789818 : default:;
18951 : : }
18952 : 7789818 : switch (TREE_CODE (_p0))
18953 : : {
18954 : 7700058 : case SSA_NAME:
18955 : 7700058 : if (gimple *_d1 = get_def (valueize, _p0))
18956 : : {
18957 : 5366880 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
18958 : 5705969 : switch (gimple_assign_rhs_code (_a1))
18959 : : {
18960 : 408712 : CASE_CONVERT:
18961 : 408712 : {
18962 : 408712 : tree _q20 = gimple_assign_rhs1 (_a1);
18963 : 408712 : _q20 = do_valueize (valueize, _q20);
18964 : 408712 : switch (TREE_CODE (_q20))
18965 : : {
18966 : 407771 : case SSA_NAME:
18967 : 407771 : if (gimple *_d2 = get_def (valueize, _q20))
18968 : : {
18969 : 381326 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
18970 : 368672 : switch (gimple_assign_rhs_code (_a2))
18971 : : {
18972 : 2028 : case BIT_AND_EXPR:
18973 : 2028 : {
18974 : 2028 : tree _q30 = gimple_assign_rhs1 (_a2);
18975 : 2028 : _q30 = do_valueize (valueize, _q30);
18976 : 2028 : tree _q31 = gimple_assign_rhs2 (_a2);
18977 : 2028 : _q31 = do_valueize (valueize, _q31);
18978 : 2028 : if (tree_swap_operands_p (_q30, _q31))
18979 : 22 : std::swap (_q30, _q31);
18980 : 2028 : switch (TREE_CODE (_p1))
18981 : : {
18982 : 976 : case SSA_NAME:
18983 : 976 : if (gimple *_d3 = get_def (valueize, _p1))
18984 : : {
18985 : 951 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
18986 : 971 : switch (gimple_assign_rhs_code (_a3))
18987 : : {
18988 : 487 : CASE_CONVERT:
18989 : 487 : {
18990 : 487 : tree _q60 = gimple_assign_rhs1 (_a3);
18991 : 487 : _q60 = do_valueize (valueize, _q60);
18992 : 487 : switch (TREE_CODE (_q60))
18993 : : {
18994 : 487 : case SSA_NAME:
18995 : 487 : if (gimple *_d4 = get_def (valueize, _q60))
18996 : : {
18997 : 487 : if (gassign *_a4 = dyn_cast <gassign *> (_d4))
18998 : 395 : switch (gimple_assign_rhs_code (_a4))
18999 : : {
19000 : 190 : case BIT_AND_EXPR:
19001 : 190 : {
19002 : 190 : tree _q70 = gimple_assign_rhs1 (_a4);
19003 : 190 : _q70 = do_valueize (valueize, _q70);
19004 : 190 : tree _q71 = gimple_assign_rhs2 (_a4);
19005 : 190 : _q71 = do_valueize (valueize, _q71);
19006 : 190 : if (tree_swap_operands_p (_q70, _q71))
19007 : 0 : std::swap (_q70, _q71);
19008 : 190 : if ((_q70 == _q30 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q30, 0) && types_match (_q70, _q30)))
19009 : : {
19010 : 0 : {
19011 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q31, _p1, _q60, _q71 };
19012 : 0 : if (gimple_simplify_128 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
19013 : 0 : return true;
19014 : : }
19015 : : }
19016 : 190 : if ((_q71 == _q30 && ! TREE_SIDE_EFFECTS (_q71)) || (operand_equal_p (_q71, _q30, 0) && types_match (_q71, _q30)))
19017 : : {
19018 : 0 : {
19019 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q31, _p1, _q60, _q70 };
19020 : 0 : if (gimple_simplify_128 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
19021 : 0 : return true;
19022 : : }
19023 : : }
19024 : 190 : if ((_q70 == _q31 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q31, 0) && types_match (_q70, _q31)))
19025 : : {
19026 : 0 : {
19027 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _q20, _q31, _q30, _p1, _q60, _q71 };
19028 : 0 : if (gimple_simplify_128 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
19029 : 0 : return true;
19030 : : }
19031 : : }
19032 : 190 : if ((_q71 == _q31 && ! TREE_SIDE_EFFECTS (_q71)) || (operand_equal_p (_q71, _q31, 0) && types_match (_q71, _q31)))
19033 : : {
19034 : 136 : {
19035 : 136 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _q20, _q31, _q30, _p1, _q60, _q70 };
19036 : 136 : if (gimple_simplify_128 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
19037 : 0 : return true;
19038 : : }
19039 : : }
19040 : 408712 : break;
19041 : : }
19042 : : default:;
19043 : : }
19044 : : }
19045 : : break;
19046 : : default:;
19047 : : }
19048 : : break;
19049 : : }
19050 : 18 : case BIT_AND_EXPR:
19051 : 18 : {
19052 : 18 : tree _q60 = gimple_assign_rhs1 (_a3);
19053 : 18 : _q60 = do_valueize (valueize, _q60);
19054 : 18 : tree _q61 = gimple_assign_rhs2 (_a3);
19055 : 18 : _q61 = do_valueize (valueize, _q61);
19056 : 18 : if (tree_swap_operands_p (_q60, _q61))
19057 : 3 : std::swap (_q60, _q61);
19058 : 18 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
19059 : : {
19060 : 0 : {
19061 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q31, _p1, _p1, _q61 };
19062 : 0 : if (gimple_simplify_129 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
19063 : 0 : return true;
19064 : : }
19065 : : }
19066 : 18 : if ((_q61 == _q30 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q30, 0) && types_match (_q61, _q30)))
19067 : : {
19068 : 0 : {
19069 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q31, _p1, _p1, _q60 };
19070 : 0 : if (gimple_simplify_129 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
19071 : 0 : return true;
19072 : : }
19073 : : }
19074 : 18 : if ((_q60 == _q31 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q31, 0) && types_match (_q60, _q31)))
19075 : : {
19076 : 0 : {
19077 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _q20, _q31, _q30, _p1, _p1, _q61 };
19078 : 0 : if (gimple_simplify_129 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
19079 : 0 : return true;
19080 : : }
19081 : : }
19082 : 18 : if ((_q61 == _q31 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q31, 0) && types_match (_q61, _q31)))
19083 : : {
19084 : 0 : {
19085 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _q20, _q31, _q30, _p1, _p1, _q60 };
19086 : 0 : if (gimple_simplify_129 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
19087 : 0 : return true;
19088 : : }
19089 : : }
19090 : 408712 : break;
19091 : : }
19092 : : default:;
19093 : : }
19094 : : }
19095 : : break;
19096 : : default:;
19097 : : }
19098 : 408712 : break;
19099 : : }
19100 : : default:;
19101 : : }
19102 : : }
19103 : : break;
19104 : 408712 : default:;
19105 : : }
19106 : 408712 : switch (TREE_CODE (_p1))
19107 : : {
19108 : 78435 : case SSA_NAME:
19109 : 78435 : if (gimple *_d2 = get_def (valueize, _p1))
19110 : : {
19111 : 75603 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
19112 : 57395 : switch (gimple_assign_rhs_code (_a2))
19113 : : {
19114 : 25335 : CASE_CONVERT:
19115 : 25335 : {
19116 : 25335 : tree _q40 = gimple_assign_rhs1 (_a2);
19117 : 25335 : _q40 = do_valueize (valueize, _q40);
19118 : 25335 : {
19119 : 25335 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _p1, _q40 };
19120 : 25335 : if (gimple_simplify_27 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
19121 : 1455 : return true;
19122 : : }
19123 : 23880 : break;
19124 : : }
19125 : : default:;
19126 : : }
19127 : : }
19128 : : break;
19129 : 407257 : default:;
19130 : : }
19131 : 407257 : {
19132 : 407257 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _p1, _p1 };
19133 : 407257 : if (gimple_simplify_28 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
19134 : 26432 : return true;
19135 : : }
19136 : 380825 : break;
19137 : : }
19138 : 150231 : case BIT_IOR_EXPR:
19139 : 150231 : {
19140 : 150231 : tree _q20 = gimple_assign_rhs1 (_a1);
19141 : 150231 : _q20 = do_valueize (valueize, _q20);
19142 : 150231 : tree _q21 = gimple_assign_rhs2 (_a1);
19143 : 150231 : _q21 = do_valueize (valueize, _q21);
19144 : 150231 : if (tree_swap_operands_p (_q20, _q21))
19145 : 8180 : std::swap (_q20, _q21);
19146 : 150231 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
19147 : : {
19148 : 0 : {
19149 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
19150 : 0 : if (gimple_simplify_130 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19151 : 0 : return true;
19152 : : }
19153 : : }
19154 : 150231 : if ((_p1 == _q21 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q21, 0) && types_match (_p1, _q21)))
19155 : : {
19156 : 2689 : {
19157 : 2689 : tree captures[2] ATTRIBUTE_UNUSED = { _q21, _q20 };
19158 : 2689 : if (gimple_simplify_130 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19159 : 2689 : return true;
19160 : : }
19161 : : }
19162 : 147542 : {
19163 : 147542 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
19164 : 147542 : if (gimple_simplify_131 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19165 : 59 : return true;
19166 : : }
19167 : 147483 : {
19168 : 147483 : tree captures[3] ATTRIBUTE_UNUSED = { _q21, _q20, _p1 };
19169 : 147483 : if (gimple_simplify_131 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19170 : 114 : return true;
19171 : : }
19172 : 147369 : switch (TREE_CODE (_p1))
19173 : : {
19174 : 117660 : case SSA_NAME:
19175 : 117660 : if (gimple *_d2 = get_def (valueize, _p1))
19176 : : {
19177 : 113455 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
19178 : 109946 : switch (gimple_assign_rhs_code (_a2))
19179 : : {
19180 : 130 : case BIT_AND_EXPR:
19181 : 130 : {
19182 : 130 : tree _q50 = gimple_assign_rhs1 (_a2);
19183 : 130 : _q50 = do_valueize (valueize, _q50);
19184 : 130 : tree _q51 = gimple_assign_rhs2 (_a2);
19185 : 130 : _q51 = do_valueize (valueize, _q51);
19186 : 130 : if (tree_swap_operands_p (_q50, _q51))
19187 : 13 : std::swap (_q50, _q51);
19188 : 130 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
19189 : : {
19190 : 1 : {
19191 : 1 : tree captures[4] ATTRIBUTE_UNUSED = { _q20, _q21, _p1, _q51 };
19192 : 1 : if (gimple_simplify_132 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19193 : 1 : return true;
19194 : : }
19195 : : }
19196 : 129 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
19197 : : {
19198 : 0 : {
19199 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q20, _q21, _p1, _q50 };
19200 : 0 : if (gimple_simplify_132 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19201 : 0 : return true;
19202 : : }
19203 : : }
19204 : 129 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
19205 : : {
19206 : 0 : {
19207 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q21, _q20, _p1, _q51 };
19208 : 0 : if (gimple_simplify_132 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19209 : 0 : return true;
19210 : : }
19211 : : }
19212 : 129 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
19213 : : {
19214 : 0 : {
19215 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q21, _q20, _p1, _q50 };
19216 : 0 : if (gimple_simplify_132 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19217 : 0 : return true;
19218 : : }
19219 : : }
19220 : 7759068 : break;
19221 : : }
19222 : 101738 : case BIT_NOT_EXPR:
19223 : 101738 : {
19224 : 101738 : tree _q50 = gimple_assign_rhs1 (_a2);
19225 : 101738 : _q50 = do_valueize (valueize, _q50);
19226 : 101738 : switch (TREE_CODE (_q50))
19227 : : {
19228 : 101738 : case SSA_NAME:
19229 : 101738 : if (gimple *_d3 = get_def (valueize, _q50))
19230 : : {
19231 : 85764 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
19232 : 85785 : switch (gimple_assign_rhs_code (_a3))
19233 : : {
19234 : 101 : case BIT_IOR_EXPR:
19235 : 101 : {
19236 : 101 : tree _q60 = gimple_assign_rhs1 (_a3);
19237 : 101 : _q60 = do_valueize (valueize, _q60);
19238 : 101 : tree _q61 = gimple_assign_rhs2 (_a3);
19239 : 101 : _q61 = do_valueize (valueize, _q61);
19240 : 101 : if (tree_swap_operands_p (_q60, _q61))
19241 : 7 : std::swap (_q60, _q61);
19242 : 101 : if ((_q60 == _q21 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q21, 0) && types_match (_q60, _q21)))
19243 : : {
19244 : 0 : {
19245 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q20, _q21, _p1, _q61 };
19246 : 0 : if (gimple_simplify_133 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19247 : 0 : return true;
19248 : : }
19249 : : }
19250 : 101 : if ((_q61 == _q21 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q21, 0) && types_match (_q61, _q21)))
19251 : : {
19252 : 0 : {
19253 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q20, _q21, _p1, _q60 };
19254 : 0 : if (gimple_simplify_133 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19255 : 0 : return true;
19256 : : }
19257 : : }
19258 : 101 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
19259 : : {
19260 : 0 : {
19261 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q21, _q20, _p1, _q61 };
19262 : 0 : if (gimple_simplify_133 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19263 : 0 : return true;
19264 : : }
19265 : : }
19266 : 101 : if ((_q61 == _q20 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q20, 0) && types_match (_q61, _q20)))
19267 : : {
19268 : 0 : {
19269 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q21, _q20, _p1, _q60 };
19270 : 0 : if (gimple_simplify_133 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19271 : 0 : return true;
19272 : : }
19273 : : }
19274 : 7759068 : break;
19275 : : }
19276 : : default:;
19277 : : }
19278 : : }
19279 : : break;
19280 : : default:;
19281 : : }
19282 : : break;
19283 : : }
19284 : : default:;
19285 : : }
19286 : : }
19287 : : break;
19288 : : default:;
19289 : : }
19290 : 7759068 : break;
19291 : : }
19292 : : default:;
19293 : : }
19294 : : }
19295 : : break;
19296 : 7759068 : default:;
19297 : : }
19298 : 7759068 : switch (TREE_CODE (_p1))
19299 : : {
19300 : 2721186 : case SSA_NAME:
19301 : 2721186 : if (gimple *_d1 = get_def (valueize, _p1))
19302 : : {
19303 : 2134605 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
19304 : 2071229 : switch (gimple_assign_rhs_code (_a1))
19305 : : {
19306 : 6388 : case BIT_IOR_EXPR:
19307 : 6388 : {
19308 : 6388 : tree _q30 = gimple_assign_rhs1 (_a1);
19309 : 6388 : _q30 = do_valueize (valueize, _q30);
19310 : 6388 : tree _q31 = gimple_assign_rhs2 (_a1);
19311 : 6388 : _q31 = do_valueize (valueize, _q31);
19312 : 6388 : if (tree_swap_operands_p (_q30, _q31))
19313 : 367 : std::swap (_q30, _q31);
19314 : 6388 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || (operand_equal_p (_q30, _p0, 0) && types_match (_q30, _p0)))
19315 : : {
19316 : 5 : {
19317 : 5 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q31 };
19318 : 5 : if (gimple_simplify_130 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19319 : 5 : return true;
19320 : : }
19321 : : }
19322 : 6383 : if ((_q31 == _p0 && ! TREE_SIDE_EFFECTS (_q31)) || (operand_equal_p (_q31, _p0, 0) && types_match (_q31, _p0)))
19323 : : {
19324 : 1 : {
19325 : 1 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q30 };
19326 : 1 : if (gimple_simplify_130 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19327 : 1 : return true;
19328 : : }
19329 : : }
19330 : 6382 : {
19331 : 6382 : tree captures[3] ATTRIBUTE_UNUSED = { _q30, _q31, _p0 };
19332 : 6382 : if (gimple_simplify_131 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19333 : 7 : return true;
19334 : : }
19335 : 6375 : {
19336 : 6375 : tree captures[3] ATTRIBUTE_UNUSED = { _q31, _q30, _p0 };
19337 : 6375 : if (gimple_simplify_131 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19338 : 14 : return true;
19339 : : }
19340 : 6361 : break;
19341 : : }
19342 : : default:;
19343 : : }
19344 : : }
19345 : : break;
19346 : 7759041 : default:;
19347 : : }
19348 : 7759041 : switch (TREE_CODE (_p0))
19349 : : {
19350 : 7669281 : case SSA_NAME:
19351 : 7669281 : if (gimple *_d1 = get_def (valueize, _p0))
19352 : : {
19353 : 5336103 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
19354 : 5675196 : switch (gimple_assign_rhs_code (_a1))
19355 : : {
19356 : 44217 : case BIT_AND_EXPR:
19357 : 44217 : {
19358 : 44217 : tree _q20 = gimple_assign_rhs1 (_a1);
19359 : 44217 : _q20 = do_valueize (valueize, _q20);
19360 : 44217 : tree _q21 = gimple_assign_rhs2 (_a1);
19361 : 44217 : _q21 = do_valueize (valueize, _q21);
19362 : 44217 : if (tree_swap_operands_p (_q20, _q21))
19363 : 2787 : std::swap (_q20, _q21);
19364 : 44217 : switch (TREE_CODE (_p1))
19365 : : {
19366 : 33310 : case SSA_NAME:
19367 : 33310 : if (gimple *_d2 = get_def (valueize, _p1))
19368 : : {
19369 : 33011 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
19370 : 33127 : switch (gimple_assign_rhs_code (_a2))
19371 : : {
19372 : 755 : case BIT_IOR_EXPR:
19373 : 755 : {
19374 : 755 : tree _q50 = gimple_assign_rhs1 (_a2);
19375 : 755 : _q50 = do_valueize (valueize, _q50);
19376 : 755 : tree _q51 = gimple_assign_rhs2 (_a2);
19377 : 755 : _q51 = do_valueize (valueize, _q51);
19378 : 755 : if (tree_swap_operands_p (_q50, _q51))
19379 : 127 : std::swap (_q50, _q51);
19380 : 755 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
19381 : : {
19382 : 0 : {
19383 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q20, _q51, _p0, _q21 };
19384 : 0 : if (gimple_simplify_136 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19385 : 0 : return true;
19386 : : }
19387 : : }
19388 : 755 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
19389 : : {
19390 : 0 : {
19391 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q21, _q51, _p0, _q20 };
19392 : 0 : if (gimple_simplify_136 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19393 : 0 : return true;
19394 : : }
19395 : : }
19396 : 755 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
19397 : : {
19398 : 0 : {
19399 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q20, _q50, _p0, _q21 };
19400 : 0 : if (gimple_simplify_136 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19401 : 0 : return true;
19402 : : }
19403 : : }
19404 : 755 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
19405 : : {
19406 : 0 : {
19407 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q21, _q50, _p0, _q20 };
19408 : 0 : if (gimple_simplify_136 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19409 : 0 : return true;
19410 : : }
19411 : : }
19412 : 7759041 : break;
19413 : : }
19414 : : default:;
19415 : : }
19416 : : }
19417 : : break;
19418 : : default:;
19419 : : }
19420 : 7759041 : break;
19421 : : }
19422 : 52467 : case BIT_NOT_EXPR:
19423 : 52467 : {
19424 : 52467 : tree _q20 = gimple_assign_rhs1 (_a1);
19425 : 52467 : _q20 = do_valueize (valueize, _q20);
19426 : 52467 : switch (TREE_CODE (_q20))
19427 : : {
19428 : 52467 : case SSA_NAME:
19429 : 52467 : if (gimple *_d2 = get_def (valueize, _q20))
19430 : : {
19431 : 49435 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
19432 : 45359 : switch (gimple_assign_rhs_code (_a2))
19433 : : {
19434 : 1400 : case BIT_IOR_EXPR:
19435 : 1400 : {
19436 : 1400 : tree _q30 = gimple_assign_rhs1 (_a2);
19437 : 1400 : _q30 = do_valueize (valueize, _q30);
19438 : 1400 : tree _q31 = gimple_assign_rhs2 (_a2);
19439 : 1400 : _q31 = do_valueize (valueize, _q31);
19440 : 1400 : if (tree_swap_operands_p (_q30, _q31))
19441 : 79 : std::swap (_q30, _q31);
19442 : 1400 : switch (TREE_CODE (_p1))
19443 : : {
19444 : 1334 : case SSA_NAME:
19445 : 1334 : if (gimple *_d3 = get_def (valueize, _p1))
19446 : : {
19447 : 1320 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
19448 : 1211 : switch (gimple_assign_rhs_code (_a3))
19449 : : {
19450 : 0 : case BIT_IOR_EXPR:
19451 : 0 : {
19452 : 0 : tree _q60 = gimple_assign_rhs1 (_a3);
19453 : 0 : _q60 = do_valueize (valueize, _q60);
19454 : 0 : tree _q61 = gimple_assign_rhs2 (_a3);
19455 : 0 : _q61 = do_valueize (valueize, _q61);
19456 : 0 : if (tree_swap_operands_p (_q60, _q61))
19457 : 0 : std::swap (_q60, _q61);
19458 : 0 : if ((_q61 == _q30 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q30, 0) && types_match (_q61, _q30)))
19459 : : {
19460 : 0 : {
19461 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q60, _q30, _p0, _q31 };
19462 : 0 : if (gimple_simplify_137 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19463 : 0 : return true;
19464 : : }
19465 : : }
19466 : 0 : if ((_q61 == _q31 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q31, 0) && types_match (_q61, _q31)))
19467 : : {
19468 : 0 : {
19469 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q60, _q31, _p0, _q30 };
19470 : 0 : if (gimple_simplify_137 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19471 : 0 : return true;
19472 : : }
19473 : : }
19474 : 0 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
19475 : : {
19476 : 0 : {
19477 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q61, _q30, _p0, _q31 };
19478 : 0 : if (gimple_simplify_137 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19479 : 0 : return true;
19480 : : }
19481 : : }
19482 : 0 : if ((_q60 == _q31 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q31, 0) && types_match (_q60, _q31)))
19483 : : {
19484 : 0 : {
19485 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q61, _q31, _p0, _q30 };
19486 : 0 : if (gimple_simplify_137 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19487 : 0 : return true;
19488 : : }
19489 : : }
19490 : 1400 : break;
19491 : : }
19492 : : default:;
19493 : : }
19494 : : }
19495 : : break;
19496 : 1400 : default:;
19497 : : }
19498 : 1400 : if ((_p1 == _q30 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q30, 0) && types_match (_p1, _q30)))
19499 : : {
19500 : 0 : {
19501 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q30, _q31 };
19502 : 0 : if (gimple_simplify_138 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19503 : 0 : return true;
19504 : : }
19505 : : }
19506 : 1400 : if ((_p1 == _q31 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q31, 0) && types_match (_p1, _q31)))
19507 : : {
19508 : 0 : {
19509 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _q31, _q30 };
19510 : 0 : if (gimple_simplify_138 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19511 : 0 : return true;
19512 : : }
19513 : : }
19514 : 7759041 : break;
19515 : : }
19516 : : default:;
19517 : : }
19518 : : }
19519 : : break;
19520 : : default:;
19521 : : }
19522 : : break;
19523 : : }
19524 : : default:;
19525 : : }
19526 : : }
19527 : : break;
19528 : 7759041 : default:;
19529 : : }
19530 : 7759041 : switch (TREE_CODE (_p1))
19531 : : {
19532 : 2721159 : case SSA_NAME:
19533 : 2721159 : if (gimple *_d1 = get_def (valueize, _p1))
19534 : : {
19535 : 2134578 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
19536 : 2071202 : switch (gimple_assign_rhs_code (_a1))
19537 : : {
19538 : 163687 : case BIT_NOT_EXPR:
19539 : 163687 : {
19540 : 163687 : tree _q30 = gimple_assign_rhs1 (_a1);
19541 : 163687 : _q30 = do_valueize (valueize, _q30);
19542 : 163687 : switch (TREE_CODE (_q30))
19543 : : {
19544 : 163687 : case SSA_NAME:
19545 : 163687 : if (gimple *_d2 = get_def (valueize, _q30))
19546 : : {
19547 : 139908 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
19548 : 136704 : switch (gimple_assign_rhs_code (_a2))
19549 : : {
19550 : 1978 : case BIT_IOR_EXPR:
19551 : 1978 : {
19552 : 1978 : tree _q40 = gimple_assign_rhs1 (_a2);
19553 : 1978 : _q40 = do_valueize (valueize, _q40);
19554 : 1978 : tree _q41 = gimple_assign_rhs2 (_a2);
19555 : 1978 : _q41 = do_valueize (valueize, _q41);
19556 : 1978 : if (tree_swap_operands_p (_q40, _q41))
19557 : 98 : std::swap (_q40, _q41);
19558 : 1978 : if ((_q40 == _p0 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _p0, 0) && types_match (_q40, _p0)))
19559 : : {
19560 : 1 : {
19561 : 1 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q41 };
19562 : 1 : if (gimple_simplify_138 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19563 : 1 : return true;
19564 : : }
19565 : : }
19566 : 1977 : if ((_q41 == _p0 && ! TREE_SIDE_EFFECTS (_q41)) || (operand_equal_p (_q41, _p0, 0) && types_match (_q41, _p0)))
19567 : : {
19568 : 0 : {
19569 : 0 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _q40 };
19570 : 0 : if (gimple_simplify_138 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, BIT_IOR_EXPR))
19571 : 0 : return true;
19572 : : }
19573 : : }
19574 : 7759040 : break;
19575 : : }
19576 : : default:;
19577 : : }
19578 : : }
19579 : : break;
19580 : : default:;
19581 : : }
19582 : : break;
19583 : : }
19584 : : default:;
19585 : : }
19586 : : }
19587 : : break;
19588 : 7759040 : default:;
19589 : : }
19590 : 7759040 : switch (TREE_CODE (_p0))
19591 : : {
19592 : 7669280 : case SSA_NAME:
19593 : 7669280 : if (gimple *_d1 = get_def (valueize, _p0))
19594 : : {
19595 : 5336102 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
19596 : 5675195 : switch (gimple_assign_rhs_code (_a1))
19597 : : {
19598 : 147364 : case BIT_IOR_EXPR:
19599 : 147364 : {
19600 : 147364 : tree _q20 = gimple_assign_rhs1 (_a1);
19601 : 147364 : _q20 = do_valueize (valueize, _q20);
19602 : 147364 : tree _q21 = gimple_assign_rhs2 (_a1);
19603 : 147364 : _q21 = do_valueize (valueize, _q21);
19604 : 147364 : if (tree_swap_operands_p (_q20, _q21))
19605 : 8180 : std::swap (_q20, _q21);
19606 : 147364 : if (CONSTANT_CLASS_P (_q21))
19607 : : {
19608 : 20317 : if (CONSTANT_CLASS_P (_p1))
19609 : : {
19610 : 11554 : {
19611 : 11554 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
19612 : 11554 : gimple_seq *lseq = seq;
19613 : 11554 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2085;
19614 : 11554 : {
19615 : 11554 : res_op->set_op (BIT_IOR_EXPR, type, 2);
19616 : 11554 : {
19617 : 11554 : tree _o1[2], _r1;
19618 : 11554 : _o1[0] = captures[0];
19619 : 11554 : _o1[1] = captures[2];
19620 : 11554 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_AND_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
19621 : 11554 : tem_op.resimplify (lseq, valueize);
19622 : 11554 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
19623 : 11554 : if (!_r1) goto next_after_fail2085;
19624 : 5421 : res_op->ops[0] = _r1;
19625 : : }
19626 : 5421 : {
19627 : 5421 : tree _o1[2], _r1;
19628 : 5421 : _o1[0] = captures[1];
19629 : 5421 : _o1[1] = captures[2];
19630 : 5421 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_AND_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
19631 : 5421 : tem_op.resimplify (NULL, valueize);
19632 : 5421 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
19633 : 5421 : if (!_r1) goto next_after_fail2085;
19634 : 5421 : res_op->ops[1] = _r1;
19635 : : }
19636 : 5421 : res_op->resimplify (lseq, valueize);
19637 : 5421 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1064, __FILE__, __LINE__, true);
19638 : 5421 : return true;
19639 : : }
19640 : 6133 : next_after_fail2085:;
19641 : : }
19642 : : }
19643 : : }
19644 : 7749157 : break;
19645 : : }
19646 : 44217 : case BIT_AND_EXPR:
19647 : 44217 : {
19648 : 44217 : tree _q20 = gimple_assign_rhs1 (_a1);
19649 : 44217 : _q20 = do_valueize (valueize, _q20);
19650 : 44217 : tree _q21 = gimple_assign_rhs2 (_a1);
19651 : 44217 : _q21 = do_valueize (valueize, _q21);
19652 : 44217 : if (tree_swap_operands_p (_q20, _q21))
19653 : 2787 : std::swap (_q20, _q21);
19654 : 44217 : if (CONSTANT_CLASS_P (_q21))
19655 : : {
19656 : 5480 : if (CONSTANT_CLASS_P (_p1))
19657 : : {
19658 : 4462 : {
19659 : 4462 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
19660 : 4462 : if (gimple_simplify_29 (res_op, seq, valueize, type, captures, BIT_AND_EXPR))
19661 : 4462 : return true;
19662 : : }
19663 : : }
19664 : : }
19665 : 7749157 : break;
19666 : : }
19667 : : default:;
19668 : : }
19669 : : }
19670 : : break;
19671 : 7749157 : default:;
19672 : : }
19673 : 7749157 : {
19674 : 7749157 : tree _p1_pops[1];
19675 : 7749157 : if (gimple_logical_inverted_value (_p1, _p1_pops, valueize))
19676 : : {
19677 : 93679 : tree _q30 = _p1_pops[0];
19678 : 93679 : if ((_q30 == _p0 && ! TREE_SIDE_EFFECTS (_q30)) || (operand_equal_p (_q30, _p0, 0) && types_match (_q30, _p0)))
19679 : : {
19680 : 0 : {
19681 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _p0 };
19682 : 0 : if (gimple_simplify_433 (res_op, seq, valueize, type, captures))
19683 : 0 : return true;
19684 : : }
19685 : : }
19686 : : }
19687 : : }
19688 : 7749157 : switch (TREE_CODE (_p0))
19689 : : {
19690 : 7659397 : case SSA_NAME:
19691 : 7659397 : if (gimple *_d1 = get_def (valueize, _p0))
19692 : : {
19693 : 5326219 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
19694 : 5665312 : switch (gimple_assign_rhs_code (_a1))
19695 : : {
19696 : 380825 : CASE_CONVERT:
19697 : 380825 : {
19698 : 380825 : tree _q20 = gimple_assign_rhs1 (_a1);
19699 : 380825 : _q20 = do_valueize (valueize, _q20);
19700 : 380825 : switch (TREE_CODE (_q20))
19701 : : {
19702 : 379884 : case SSA_NAME:
19703 : 379884 : if (gimple *_d2 = get_def (valueize, _q20))
19704 : : {
19705 : 354464 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
19706 : 338833 : switch (gimple_assign_rhs_code (_a2))
19707 : : {
19708 : 974 : case NEGATE_EXPR:
19709 : 974 : {
19710 : 974 : tree _q30 = gimple_assign_rhs1 (_a2);
19711 : 974 : _q30 = do_valueize (valueize, _q30);
19712 : 974 : if (gimple_zero_one_valued_p (_q30, valueize))
19713 : : {
19714 : 6 : {
19715 : 6 : tree captures[2] ATTRIBUTE_UNUSED = { _q30, _p1 };
19716 : 6 : if (gimple_simplify_427 (res_op, seq, valueize, type, captures))
19717 : 2 : return true;
19718 : : }
19719 : : }
19720 : : break;
19721 : : }
19722 : : default:;
19723 : : }
19724 : : }
19725 : : break;
19726 : : default:;
19727 : : }
19728 : : break;
19729 : : }
19730 : : default:;
19731 : : }
19732 : : }
19733 : : break;
19734 : 7749155 : default:;
19735 : : }
19736 : 7749155 : {
19737 : 7749155 : tree _p0_pops[1];
19738 : 7749155 : if (gimple_logical_inverted_value (_p0, _p0_pops, valueize))
19739 : : {
19740 : 106834 : tree _q20 = _p0_pops[0];
19741 : 106834 : if ((_p1 == _q20 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q20, 0) && types_match (_p1, _q20)))
19742 : : {
19743 : 0 : {
19744 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
19745 : 0 : if (gimple_simplify_433 (res_op, seq, valueize, type, captures))
19746 : 0 : return true;
19747 : : }
19748 : : }
19749 : : }
19750 : : }
19751 : 7749155 : switch (TREE_CODE (_p1))
19752 : : {
19753 : 2721156 : case SSA_NAME:
19754 : 2721156 : if (gimple *_d1 = get_def (valueize, _p1))
19755 : : {
19756 : 2134575 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
19757 : 2071197 : switch (gimple_assign_rhs_code (_a1))
19758 : : {
19759 : 100376 : CASE_CONVERT:
19760 : 100376 : {
19761 : 100376 : tree _q30 = gimple_assign_rhs1 (_a1);
19762 : 100376 : _q30 = do_valueize (valueize, _q30);
19763 : 100376 : switch (TREE_CODE (_q30))
19764 : : {
19765 : 100376 : case SSA_NAME:
19766 : 100376 : if (gimple *_d2 = get_def (valueize, _q30))
19767 : : {
19768 : 97351 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
19769 : 88959 : switch (gimple_assign_rhs_code (_a2))
19770 : : {
19771 : 671 : case NEGATE_EXPR:
19772 : 671 : {
19773 : 671 : tree _q40 = gimple_assign_rhs1 (_a2);
19774 : 671 : _q40 = do_valueize (valueize, _q40);
19775 : 671 : if (gimple_zero_one_valued_p (_q40, valueize))
19776 : : {
19777 : 4 : {
19778 : 4 : tree captures[2] ATTRIBUTE_UNUSED = { _q40, _p0 };
19779 : 4 : if (gimple_simplify_427 (res_op, seq, valueize, type, captures))
19780 : 0 : return true;
19781 : : }
19782 : : }
19783 : : break;
19784 : : }
19785 : : default:;
19786 : : }
19787 : : }
19788 : : break;
19789 : : default:;
19790 : : }
19791 : : break;
19792 : : }
19793 : 25676 : case NEGATE_EXPR:
19794 : 25676 : {
19795 : 25676 : tree _q30 = gimple_assign_rhs1 (_a1);
19796 : 25676 : _q30 = do_valueize (valueize, _q30);
19797 : 25676 : if (gimple_zero_one_valued_p (_q30, valueize))
19798 : : {
19799 : 473 : {
19800 : 473 : tree captures[2] ATTRIBUTE_UNUSED = { _q30, _p0 };
19801 : 473 : if (gimple_simplify_427 (res_op, seq, valueize, type, captures))
19802 : 473 : return true;
19803 : : }
19804 : : }
19805 : : break;
19806 : : }
19807 : : default:;
19808 : : }
19809 : : }
19810 : : break;
19811 : 7748682 : default:;
19812 : : }
19813 : 7748682 : switch (TREE_CODE (_p0))
19814 : : {
19815 : 7658922 : case SSA_NAME:
19816 : 7658922 : if (gimple *_d1 = get_def (valueize, _p0))
19817 : : {
19818 : 5325744 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
19819 : 5664833 : switch (gimple_assign_rhs_code (_a1))
19820 : : {
19821 : 52704 : case NEGATE_EXPR:
19822 : 52704 : {
19823 : 52704 : tree _q20 = gimple_assign_rhs1 (_a1);
19824 : 52704 : _q20 = do_valueize (valueize, _q20);
19825 : 52704 : switch (TREE_CODE (_q20))
19826 : : {
19827 : 52704 : case SSA_NAME:
19828 : 52704 : if (gimple *_d2 = get_def (valueize, _q20))
19829 : : {
19830 : 43431 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
19831 : 23901 : switch (gimple_assign_rhs_code (_a2))
19832 : : {
19833 : 19382 : CASE_CONVERT:
19834 : 19382 : {
19835 : 19382 : tree _q30 = gimple_assign_rhs1 (_a2);
19836 : 19382 : _q30 = do_valueize (valueize, _q30);
19837 : 19382 : switch (TREE_CODE (_q30))
19838 : : {
19839 : 19262 : case SSA_NAME:
19840 : 19262 : if (gimple *_d3 = get_def (valueize, _q30))
19841 : : {
19842 : 19158 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
19843 : 3901 : switch (gimple_assign_rhs_code (_a3))
19844 : : {
19845 : 0 : case LT_EXPR:
19846 : 0 : {
19847 : 0 : tree _q40 = gimple_assign_rhs1 (_a3);
19848 : 0 : _q40 = do_valueize (valueize, _q40);
19849 : 0 : tree _q41 = gimple_assign_rhs2 (_a3);
19850 : 0 : _q41 = do_valueize (valueize, _q41);
19851 : 0 : {
19852 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q30, _q40, _q41, _p1 };
19853 : 0 : if (gimple_simplify_434 (res_op, seq, valueize, type, captures, LT_EXPR))
19854 : 0 : return true;
19855 : : }
19856 : 0 : break;
19857 : : }
19858 : 0 : case LE_EXPR:
19859 : 0 : {
19860 : 0 : tree _q40 = gimple_assign_rhs1 (_a3);
19861 : 0 : _q40 = do_valueize (valueize, _q40);
19862 : 0 : tree _q41 = gimple_assign_rhs2 (_a3);
19863 : 0 : _q41 = do_valueize (valueize, _q41);
19864 : 0 : {
19865 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q30, _q40, _q41, _p1 };
19866 : 0 : if (gimple_simplify_434 (res_op, seq, valueize, type, captures, LE_EXPR))
19867 : 0 : return true;
19868 : : }
19869 : 0 : break;
19870 : : }
19871 : 0 : case EQ_EXPR:
19872 : 0 : {
19873 : 0 : tree _q40 = gimple_assign_rhs1 (_a3);
19874 : 0 : _q40 = do_valueize (valueize, _q40);
19875 : 0 : tree _q41 = gimple_assign_rhs2 (_a3);
19876 : 0 : _q41 = do_valueize (valueize, _q41);
19877 : 0 : if (tree_swap_operands_p (_q40, _q41))
19878 : 0 : std::swap (_q40, _q41);
19879 : 0 : {
19880 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q30, _q40, _q41, _p1 };
19881 : 0 : if (gimple_simplify_434 (res_op, seq, valueize, type, captures, EQ_EXPR))
19882 : 0 : return true;
19883 : : }
19884 : 0 : break;
19885 : : }
19886 : 0 : case NE_EXPR:
19887 : 0 : {
19888 : 0 : tree _q40 = gimple_assign_rhs1 (_a3);
19889 : 0 : _q40 = do_valueize (valueize, _q40);
19890 : 0 : tree _q41 = gimple_assign_rhs2 (_a3);
19891 : 0 : _q41 = do_valueize (valueize, _q41);
19892 : 0 : if (tree_swap_operands_p (_q40, _q41))
19893 : 0 : std::swap (_q40, _q41);
19894 : 0 : {
19895 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q30, _q40, _q41, _p1 };
19896 : 0 : if (gimple_simplify_434 (res_op, seq, valueize, type, captures, NE_EXPR))
19897 : 0 : return true;
19898 : : }
19899 : 0 : break;
19900 : : }
19901 : 0 : case GE_EXPR:
19902 : 0 : {
19903 : 0 : tree _q40 = gimple_assign_rhs1 (_a3);
19904 : 0 : _q40 = do_valueize (valueize, _q40);
19905 : 0 : tree _q41 = gimple_assign_rhs2 (_a3);
19906 : 0 : _q41 = do_valueize (valueize, _q41);
19907 : 0 : {
19908 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q30, _q40, _q41, _p1 };
19909 : 0 : if (gimple_simplify_434 (res_op, seq, valueize, type, captures, GE_EXPR))
19910 : 0 : return true;
19911 : : }
19912 : 0 : break;
19913 : : }
19914 : 0 : case GT_EXPR:
19915 : 0 : {
19916 : 0 : tree _q40 = gimple_assign_rhs1 (_a3);
19917 : 0 : _q40 = do_valueize (valueize, _q40);
19918 : 0 : tree _q41 = gimple_assign_rhs2 (_a3);
19919 : 0 : _q41 = do_valueize (valueize, _q41);
19920 : 0 : {
19921 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q30, _q40, _q41, _p1 };
19922 : 0 : if (gimple_simplify_434 (res_op, seq, valueize, type, captures, GT_EXPR))
19923 : 0 : return true;
19924 : : }
19925 : 0 : break;
19926 : : }
19927 : 0 : case UNORDERED_EXPR:
19928 : 0 : {
19929 : 0 : tree _q40 = gimple_assign_rhs1 (_a3);
19930 : 0 : _q40 = do_valueize (valueize, _q40);
19931 : 0 : tree _q41 = gimple_assign_rhs2 (_a3);
19932 : 0 : _q41 = do_valueize (valueize, _q41);
19933 : 0 : if (tree_swap_operands_p (_q40, _q41))
19934 : 0 : std::swap (_q40, _q41);
19935 : 0 : {
19936 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q30, _q40, _q41, _p1 };
19937 : 0 : if (gimple_simplify_434 (res_op, seq, valueize, type, captures, UNORDERED_EXPR))
19938 : 0 : return true;
19939 : : }
19940 : 0 : break;
19941 : : }
19942 : 0 : case ORDERED_EXPR:
19943 : 0 : {
19944 : 0 : tree _q40 = gimple_assign_rhs1 (_a3);
19945 : 0 : _q40 = do_valueize (valueize, _q40);
19946 : 0 : tree _q41 = gimple_assign_rhs2 (_a3);
19947 : 0 : _q41 = do_valueize (valueize, _q41);
19948 : 0 : if (tree_swap_operands_p (_q40, _q41))
19949 : 0 : std::swap (_q40, _q41);
19950 : 0 : {
19951 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q30, _q40, _q41, _p1 };
19952 : 0 : if (gimple_simplify_434 (res_op, seq, valueize, type, captures, ORDERED_EXPR))
19953 : 0 : return true;
19954 : : }
19955 : 0 : break;
19956 : : }
19957 : 0 : case UNLT_EXPR:
19958 : 0 : {
19959 : 0 : tree _q40 = gimple_assign_rhs1 (_a3);
19960 : 0 : _q40 = do_valueize (valueize, _q40);
19961 : 0 : tree _q41 = gimple_assign_rhs2 (_a3);
19962 : 0 : _q41 = do_valueize (valueize, _q41);
19963 : 0 : {
19964 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q30, _q40, _q41, _p1 };
19965 : 0 : if (gimple_simplify_434 (res_op, seq, valueize, type, captures, UNLT_EXPR))
19966 : 0 : return true;
19967 : : }
19968 : 0 : break;
19969 : : }
19970 : 0 : case UNLE_EXPR:
19971 : 0 : {
19972 : 0 : tree _q40 = gimple_assign_rhs1 (_a3);
19973 : 0 : _q40 = do_valueize (valueize, _q40);
19974 : 0 : tree _q41 = gimple_assign_rhs2 (_a3);
19975 : 0 : _q41 = do_valueize (valueize, _q41);
19976 : 0 : {
19977 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q30, _q40, _q41, _p1 };
19978 : 0 : if (gimple_simplify_434 (res_op, seq, valueize, type, captures, UNLE_EXPR))
19979 : 0 : return true;
19980 : : }
19981 : 0 : break;
19982 : : }
19983 : 0 : case UNGT_EXPR:
19984 : 0 : {
19985 : 0 : tree _q40 = gimple_assign_rhs1 (_a3);
19986 : 0 : _q40 = do_valueize (valueize, _q40);
19987 : 0 : tree _q41 = gimple_assign_rhs2 (_a3);
19988 : 0 : _q41 = do_valueize (valueize, _q41);
19989 : 0 : {
19990 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q30, _q40, _q41, _p1 };
19991 : 0 : if (gimple_simplify_434 (res_op, seq, valueize, type, captures, UNGT_EXPR))
19992 : 0 : return true;
19993 : : }
19994 : 0 : break;
19995 : : }
19996 : 0 : case UNGE_EXPR:
19997 : 0 : {
19998 : 0 : tree _q40 = gimple_assign_rhs1 (_a3);
19999 : 0 : _q40 = do_valueize (valueize, _q40);
20000 : 0 : tree _q41 = gimple_assign_rhs2 (_a3);
20001 : 0 : _q41 = do_valueize (valueize, _q41);
20002 : 0 : {
20003 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q30, _q40, _q41, _p1 };
20004 : 0 : if (gimple_simplify_434 (res_op, seq, valueize, type, captures, UNGE_EXPR))
20005 : 0 : return true;
20006 : : }
20007 : 0 : break;
20008 : : }
20009 : 0 : case UNEQ_EXPR:
20010 : 0 : {
20011 : 0 : tree _q40 = gimple_assign_rhs1 (_a3);
20012 : 0 : _q40 = do_valueize (valueize, _q40);
20013 : 0 : tree _q41 = gimple_assign_rhs2 (_a3);
20014 : 0 : _q41 = do_valueize (valueize, _q41);
20015 : 0 : if (tree_swap_operands_p (_q40, _q41))
20016 : 0 : std::swap (_q40, _q41);
20017 : 0 : {
20018 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q30, _q40, _q41, _p1 };
20019 : 0 : if (gimple_simplify_434 (res_op, seq, valueize, type, captures, UNEQ_EXPR))
20020 : 0 : return true;
20021 : : }
20022 : 0 : break;
20023 : : }
20024 : 0 : case LTGT_EXPR:
20025 : 0 : {
20026 : 0 : tree _q40 = gimple_assign_rhs1 (_a3);
20027 : 0 : _q40 = do_valueize (valueize, _q40);
20028 : 0 : tree _q41 = gimple_assign_rhs2 (_a3);
20029 : 0 : _q41 = do_valueize (valueize, _q41);
20030 : 0 : if (tree_swap_operands_p (_q40, _q41))
20031 : 0 : std::swap (_q40, _q41);
20032 : 0 : {
20033 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q30, _q40, _q41, _p1 };
20034 : 0 : if (gimple_simplify_434 (res_op, seq, valueize, type, captures, LTGT_EXPR))
20035 : 0 : return true;
20036 : : }
20037 : 0 : break;
20038 : : }
20039 : : default:;
20040 : : }
20041 : : }
20042 : : break;
20043 : : default:;
20044 : : }
20045 : : break;
20046 : : }
20047 : : default:;
20048 : : }
20049 : : }
20050 : : break;
20051 : : default:;
20052 : : }
20053 : : break;
20054 : : }
20055 : : default:;
20056 : : }
20057 : : }
20058 : : break;
20059 : 7748682 : default:;
20060 : : }
20061 : 7748682 : switch (TREE_CODE (_p1))
20062 : : {
20063 : 2720683 : case SSA_NAME:
20064 : 2720683 : if (gimple *_d1 = get_def (valueize, _p1))
20065 : : {
20066 : 2134102 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
20067 : 2070724 : switch (gimple_assign_rhs_code (_a1))
20068 : : {
20069 : 25203 : case NEGATE_EXPR:
20070 : 25203 : {
20071 : 25203 : tree _q30 = gimple_assign_rhs1 (_a1);
20072 : 25203 : _q30 = do_valueize (valueize, _q30);
20073 : 25203 : switch (TREE_CODE (_q30))
20074 : : {
20075 : 25203 : case SSA_NAME:
20076 : 25203 : if (gimple *_d2 = get_def (valueize, _q30))
20077 : : {
20078 : 21209 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
20079 : 22487 : switch (gimple_assign_rhs_code (_a2))
20080 : : {
20081 : 2616 : CASE_CONVERT:
20082 : 2616 : {
20083 : 2616 : tree _q40 = gimple_assign_rhs1 (_a2);
20084 : 2616 : _q40 = do_valueize (valueize, _q40);
20085 : 2616 : switch (TREE_CODE (_q40))
20086 : : {
20087 : 2616 : case SSA_NAME:
20088 : 2616 : if (gimple *_d3 = get_def (valueize, _q40))
20089 : : {
20090 : 2600 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
20091 : 1318 : switch (gimple_assign_rhs_code (_a3))
20092 : : {
20093 : 0 : case LT_EXPR:
20094 : 0 : {
20095 : 0 : tree _q50 = gimple_assign_rhs1 (_a3);
20096 : 0 : _q50 = do_valueize (valueize, _q50);
20097 : 0 : tree _q51 = gimple_assign_rhs2 (_a3);
20098 : 0 : _q51 = do_valueize (valueize, _q51);
20099 : 0 : {
20100 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q40, _q50, _q51, _p0 };
20101 : 0 : if (gimple_simplify_435 (res_op, seq, valueize, type, captures, LT_EXPR))
20102 : 0 : return true;
20103 : : }
20104 : 0 : break;
20105 : : }
20106 : 0 : case LE_EXPR:
20107 : 0 : {
20108 : 0 : tree _q50 = gimple_assign_rhs1 (_a3);
20109 : 0 : _q50 = do_valueize (valueize, _q50);
20110 : 0 : tree _q51 = gimple_assign_rhs2 (_a3);
20111 : 0 : _q51 = do_valueize (valueize, _q51);
20112 : 0 : {
20113 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q40, _q50, _q51, _p0 };
20114 : 0 : if (gimple_simplify_435 (res_op, seq, valueize, type, captures, LE_EXPR))
20115 : 0 : return true;
20116 : : }
20117 : 0 : break;
20118 : : }
20119 : 0 : case EQ_EXPR:
20120 : 0 : {
20121 : 0 : tree _q50 = gimple_assign_rhs1 (_a3);
20122 : 0 : _q50 = do_valueize (valueize, _q50);
20123 : 0 : tree _q51 = gimple_assign_rhs2 (_a3);
20124 : 0 : _q51 = do_valueize (valueize, _q51);
20125 : 0 : if (tree_swap_operands_p (_q50, _q51))
20126 : 0 : std::swap (_q50, _q51);
20127 : 0 : {
20128 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q40, _q50, _q51, _p0 };
20129 : 0 : if (gimple_simplify_435 (res_op, seq, valueize, type, captures, EQ_EXPR))
20130 : 0 : return true;
20131 : : }
20132 : 0 : break;
20133 : : }
20134 : 0 : case NE_EXPR:
20135 : 0 : {
20136 : 0 : tree _q50 = gimple_assign_rhs1 (_a3);
20137 : 0 : _q50 = do_valueize (valueize, _q50);
20138 : 0 : tree _q51 = gimple_assign_rhs2 (_a3);
20139 : 0 : _q51 = do_valueize (valueize, _q51);
20140 : 0 : if (tree_swap_operands_p (_q50, _q51))
20141 : 0 : std::swap (_q50, _q51);
20142 : 0 : {
20143 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q40, _q50, _q51, _p0 };
20144 : 0 : if (gimple_simplify_435 (res_op, seq, valueize, type, captures, NE_EXPR))
20145 : 0 : return true;
20146 : : }
20147 : 0 : break;
20148 : : }
20149 : 0 : case GE_EXPR:
20150 : 0 : {
20151 : 0 : tree _q50 = gimple_assign_rhs1 (_a3);
20152 : 0 : _q50 = do_valueize (valueize, _q50);
20153 : 0 : tree _q51 = gimple_assign_rhs2 (_a3);
20154 : 0 : _q51 = do_valueize (valueize, _q51);
20155 : 0 : {
20156 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q40, _q50, _q51, _p0 };
20157 : 0 : if (gimple_simplify_435 (res_op, seq, valueize, type, captures, GE_EXPR))
20158 : 0 : return true;
20159 : : }
20160 : 0 : break;
20161 : : }
20162 : 0 : case GT_EXPR:
20163 : 0 : {
20164 : 0 : tree _q50 = gimple_assign_rhs1 (_a3);
20165 : 0 : _q50 = do_valueize (valueize, _q50);
20166 : 0 : tree _q51 = gimple_assign_rhs2 (_a3);
20167 : 0 : _q51 = do_valueize (valueize, _q51);
20168 : 0 : {
20169 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q40, _q50, _q51, _p0 };
20170 : 0 : if (gimple_simplify_435 (res_op, seq, valueize, type, captures, GT_EXPR))
20171 : 0 : return true;
20172 : : }
20173 : 0 : break;
20174 : : }
20175 : 0 : case UNORDERED_EXPR:
20176 : 0 : {
20177 : 0 : tree _q50 = gimple_assign_rhs1 (_a3);
20178 : 0 : _q50 = do_valueize (valueize, _q50);
20179 : 0 : tree _q51 = gimple_assign_rhs2 (_a3);
20180 : 0 : _q51 = do_valueize (valueize, _q51);
20181 : 0 : if (tree_swap_operands_p (_q50, _q51))
20182 : 0 : std::swap (_q50, _q51);
20183 : 0 : {
20184 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q40, _q50, _q51, _p0 };
20185 : 0 : if (gimple_simplify_435 (res_op, seq, valueize, type, captures, UNORDERED_EXPR))
20186 : 0 : return true;
20187 : : }
20188 : 0 : break;
20189 : : }
20190 : 0 : case ORDERED_EXPR:
20191 : 0 : {
20192 : 0 : tree _q50 = gimple_assign_rhs1 (_a3);
20193 : 0 : _q50 = do_valueize (valueize, _q50);
20194 : 0 : tree _q51 = gimple_assign_rhs2 (_a3);
20195 : 0 : _q51 = do_valueize (valueize, _q51);
20196 : 0 : if (tree_swap_operands_p (_q50, _q51))
20197 : 0 : std::swap (_q50, _q51);
20198 : 0 : {
20199 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q40, _q50, _q51, _p0 };
20200 : 0 : if (gimple_simplify_435 (res_op, seq, valueize, type, captures, ORDERED_EXPR))
20201 : 0 : return true;
20202 : : }
20203 : 0 : break;
20204 : : }
20205 : 0 : case UNLT_EXPR:
20206 : 0 : {
20207 : 0 : tree _q50 = gimple_assign_rhs1 (_a3);
20208 : 0 : _q50 = do_valueize (valueize, _q50);
20209 : 0 : tree _q51 = gimple_assign_rhs2 (_a3);
20210 : 0 : _q51 = do_valueize (valueize, _q51);
20211 : 0 : {
20212 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q40, _q50, _q51, _p0 };
20213 : 0 : if (gimple_simplify_435 (res_op, seq, valueize, type, captures, UNLT_EXPR))
20214 : 0 : return true;
20215 : : }
20216 : 0 : break;
20217 : : }
20218 : 0 : case UNLE_EXPR:
20219 : 0 : {
20220 : 0 : tree _q50 = gimple_assign_rhs1 (_a3);
20221 : 0 : _q50 = do_valueize (valueize, _q50);
20222 : 0 : tree _q51 = gimple_assign_rhs2 (_a3);
20223 : 0 : _q51 = do_valueize (valueize, _q51);
20224 : 0 : {
20225 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q40, _q50, _q51, _p0 };
20226 : 0 : if (gimple_simplify_435 (res_op, seq, valueize, type, captures, UNLE_EXPR))
20227 : 0 : return true;
20228 : : }
20229 : 0 : break;
20230 : : }
20231 : 0 : case UNGT_EXPR:
20232 : 0 : {
20233 : 0 : tree _q50 = gimple_assign_rhs1 (_a3);
20234 : 0 : _q50 = do_valueize (valueize, _q50);
20235 : 0 : tree _q51 = gimple_assign_rhs2 (_a3);
20236 : 0 : _q51 = do_valueize (valueize, _q51);
20237 : 0 : {
20238 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q40, _q50, _q51, _p0 };
20239 : 0 : if (gimple_simplify_435 (res_op, seq, valueize, type, captures, UNGT_EXPR))
20240 : 0 : return true;
20241 : : }
20242 : 0 : break;
20243 : : }
20244 : 0 : case UNGE_EXPR:
20245 : 0 : {
20246 : 0 : tree _q50 = gimple_assign_rhs1 (_a3);
20247 : 0 : _q50 = do_valueize (valueize, _q50);
20248 : 0 : tree _q51 = gimple_assign_rhs2 (_a3);
20249 : 0 : _q51 = do_valueize (valueize, _q51);
20250 : 0 : {
20251 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q40, _q50, _q51, _p0 };
20252 : 0 : if (gimple_simplify_435 (res_op, seq, valueize, type, captures, UNGE_EXPR))
20253 : 0 : return true;
20254 : : }
20255 : 0 : break;
20256 : : }
20257 : 0 : case UNEQ_EXPR:
20258 : 0 : {
20259 : 0 : tree _q50 = gimple_assign_rhs1 (_a3);
20260 : 0 : _q50 = do_valueize (valueize, _q50);
20261 : 0 : tree _q51 = gimple_assign_rhs2 (_a3);
20262 : 0 : _q51 = do_valueize (valueize, _q51);
20263 : 0 : if (tree_swap_operands_p (_q50, _q51))
20264 : 0 : std::swap (_q50, _q51);
20265 : 0 : {
20266 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q40, _q50, _q51, _p0 };
20267 : 0 : if (gimple_simplify_435 (res_op, seq, valueize, type, captures, UNEQ_EXPR))
20268 : 0 : return true;
20269 : : }
20270 : 0 : break;
20271 : : }
20272 : 0 : case LTGT_EXPR:
20273 : 0 : {
20274 : 0 : tree _q50 = gimple_assign_rhs1 (_a3);
20275 : 0 : _q50 = do_valueize (valueize, _q50);
20276 : 0 : tree _q51 = gimple_assign_rhs2 (_a3);
20277 : 0 : _q51 = do_valueize (valueize, _q51);
20278 : 0 : if (tree_swap_operands_p (_q50, _q51))
20279 : 0 : std::swap (_q50, _q51);
20280 : 0 : {
20281 : 0 : tree captures[4] ATTRIBUTE_UNUSED = { _q40, _q50, _q51, _p0 };
20282 : 0 : if (gimple_simplify_435 (res_op, seq, valueize, type, captures, LTGT_EXPR))
20283 : 0 : return true;
20284 : : }
20285 : 0 : break;
20286 : : }
20287 : : default:;
20288 : : }
20289 : : }
20290 : : break;
20291 : : default:;
20292 : : }
20293 : : break;
20294 : : }
20295 : : default:;
20296 : : }
20297 : : }
20298 : : break;
20299 : : default:;
20300 : : }
20301 : : break;
20302 : : }
20303 : : default:;
20304 : : }
20305 : : }
20306 : : break;
20307 : 7748682 : default:;
20308 : : }
20309 : 7748682 : switch (TREE_CODE (_p0))
20310 : : {
20311 : 7658922 : case SSA_NAME:
20312 : 7658922 : if (gimple *_d1 = get_def (valueize, _p0))
20313 : : {
20314 : 5325744 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
20315 : 5664833 : switch (gimple_assign_rhs_code (_a1))
20316 : : {
20317 : 380823 : CASE_CONVERT:
20318 : 380823 : {
20319 : 380823 : tree _q20 = gimple_assign_rhs1 (_a1);
20320 : 380823 : _q20 = do_valueize (valueize, _q20);
20321 : 380823 : switch (TREE_CODE (_p1))
20322 : : {
20323 : 303845 : case INTEGER_CST:
20324 : 303845 : {
20325 : 303845 : {
20326 : 303845 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _p1 };
20327 : 303845 : if (gimple_simplify_436 (res_op, seq, valueize, type, captures))
20328 : 837 : return true;
20329 : : }
20330 : 303008 : break;
20331 : : }
20332 : 379986 : default:;
20333 : : }
20334 : 379986 : switch (TREE_CODE (_q20))
20335 : : {
20336 : 379878 : case SSA_NAME:
20337 : 379878 : if (gimple *_d2 = get_def (valueize, _q20))
20338 : : {
20339 : 354458 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
20340 : 338831 : switch (gimple_assign_rhs_code (_a2))
20341 : : {
20342 : 15676 : case LSHIFT_EXPR:
20343 : 15676 : {
20344 : 15676 : tree _q30 = gimple_assign_rhs1 (_a2);
20345 : 15676 : _q30 = do_valueize (valueize, _q30);
20346 : 15676 : tree _q31 = gimple_assign_rhs2 (_a2);
20347 : 15676 : _q31 = do_valueize (valueize, _q31);
20348 : 15676 : switch (TREE_CODE (_q30))
20349 : : {
20350 : 969 : case SSA_NAME:
20351 : 969 : if (gimple *_d3 = get_def (valueize, _q30))
20352 : : {
20353 : 898 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
20354 : 1236 : switch (gimple_assign_rhs_code (_a3))
20355 : : {
20356 : 10 : CASE_CONVERT:
20357 : 10 : {
20358 : 10 : tree _q40 = gimple_assign_rhs1 (_a3);
20359 : 10 : _q40 = do_valueize (valueize, _q40);
20360 : 10 : switch (TREE_CODE (_q31))
20361 : : {
20362 : 10 : case INTEGER_CST:
20363 : 10 : {
20364 : 10 : switch (TREE_CODE (_p1))
20365 : : {
20366 : 10 : case INTEGER_CST:
20367 : 10 : {
20368 : 10 : {
20369 : 10 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q40, _q31, _p1 };
20370 : 10 : if (gimple_simplify_437 (res_op, seq, valueize, type, captures, LSHIFT_EXPR))
20371 : 0 : return true;
20372 : : }
20373 : 10 : break;
20374 : : }
20375 : : default:;
20376 : : }
20377 : : break;
20378 : : }
20379 : : default:;
20380 : : }
20381 : : break;
20382 : : }
20383 : : default:;
20384 : : }
20385 : : }
20386 : : break;
20387 : 15676 : default:;
20388 : : }
20389 : 15676 : switch (TREE_CODE (_q31))
20390 : : {
20391 : 26 : case INTEGER_CST:
20392 : 26 : {
20393 : 26 : switch (TREE_CODE (_p1))
20394 : : {
20395 : 26 : case INTEGER_CST:
20396 : 26 : {
20397 : 26 : {
20398 : 26 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q30, _q31, _p1 };
20399 : 26 : if (gimple_simplify_438 (res_op, seq, valueize, type, captures, LSHIFT_EXPR))
20400 : 0 : return true;
20401 : : }
20402 : 26 : break;
20403 : : }
20404 : : default:;
20405 : : }
20406 : : break;
20407 : : }
20408 : : default:;
20409 : : }
20410 : : break;
20411 : : }
20412 : 68812 : case RSHIFT_EXPR:
20413 : 68812 : {
20414 : 68812 : tree _q30 = gimple_assign_rhs1 (_a2);
20415 : 68812 : _q30 = do_valueize (valueize, _q30);
20416 : 68812 : tree _q31 = gimple_assign_rhs2 (_a2);
20417 : 68812 : _q31 = do_valueize (valueize, _q31);
20418 : 68812 : switch (TREE_CODE (_q30))
20419 : : {
20420 : 68571 : case SSA_NAME:
20421 : 68571 : if (gimple *_d3 = get_def (valueize, _q30))
20422 : : {
20423 : 61197 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
20424 : 62861 : switch (gimple_assign_rhs_code (_a3))
20425 : : {
20426 : 12179 : CASE_CONVERT:
20427 : 12179 : {
20428 : 12179 : tree _q40 = gimple_assign_rhs1 (_a3);
20429 : 12179 : _q40 = do_valueize (valueize, _q40);
20430 : 12179 : switch (TREE_CODE (_q31))
20431 : : {
20432 : 5785 : case INTEGER_CST:
20433 : 5785 : {
20434 : 5785 : switch (TREE_CODE (_p1))
20435 : : {
20436 : 5184 : case INTEGER_CST:
20437 : 5184 : {
20438 : 5184 : {
20439 : 5184 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q40, _q31, _p1 };
20440 : 5184 : if (gimple_simplify_437 (res_op, seq, valueize, type, captures, RSHIFT_EXPR))
20441 : 0 : return true;
20442 : : }
20443 : 5184 : break;
20444 : : }
20445 : : default:;
20446 : : }
20447 : : break;
20448 : : }
20449 : 12179 : default:;
20450 : : }
20451 : 12179 : switch (TREE_CODE (_q40))
20452 : : {
20453 : 12179 : case SSA_NAME:
20454 : 12179 : if (gimple *_d4 = get_def (valueize, _q40))
20455 : : {
20456 : 12117 : if (gcall *_c4 = dyn_cast <gcall *> (_d4))
20457 : 12 : switch (gimple_call_combined_fn (_c4))
20458 : : {
20459 : 0 : case CFN_BUILT_IN_BSWAP128:
20460 : 0 : if (gimple_call_num_args (_c4) == 1)
20461 : : {
20462 : 0 : tree _q50 = gimple_call_arg (_c4, 0);
20463 : 0 : _q50 = do_valueize (valueize, _q50);
20464 : 0 : switch (TREE_CODE (_q31))
20465 : : {
20466 : 0 : case INTEGER_CST:
20467 : 0 : {
20468 : 0 : switch (TREE_CODE (_p1))
20469 : : {
20470 : 0 : case INTEGER_CST:
20471 : 0 : {
20472 : 0 : {
20473 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _q20, _q40, _q50, _q31, _p1 };
20474 : 0 : if (gimple_simplify_439 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP128))
20475 : 0 : return true;
20476 : : }
20477 : 0 : break;
20478 : : }
20479 : : default:;
20480 : : }
20481 : : break;
20482 : : }
20483 : : default:;
20484 : : }
20485 : : }
20486 : : break;
20487 : 0 : case CFN_BUILT_IN_BSWAP16:
20488 : 0 : if (gimple_call_num_args (_c4) == 1)
20489 : : {
20490 : 0 : tree _q50 = gimple_call_arg (_c4, 0);
20491 : 0 : _q50 = do_valueize (valueize, _q50);
20492 : 0 : switch (TREE_CODE (_q31))
20493 : : {
20494 : 0 : case INTEGER_CST:
20495 : 0 : {
20496 : 0 : switch (TREE_CODE (_p1))
20497 : : {
20498 : 0 : case INTEGER_CST:
20499 : 0 : {
20500 : 0 : {
20501 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _q20, _q40, _q50, _q31, _p1 };
20502 : 0 : if (gimple_simplify_439 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP16))
20503 : 0 : return true;
20504 : : }
20505 : 0 : break;
20506 : : }
20507 : : default:;
20508 : : }
20509 : : break;
20510 : : }
20511 : : default:;
20512 : : }
20513 : : }
20514 : : break;
20515 : 0 : case CFN_BUILT_IN_BSWAP32:
20516 : 0 : if (gimple_call_num_args (_c4) == 1)
20517 : : {
20518 : 0 : tree _q50 = gimple_call_arg (_c4, 0);
20519 : 0 : _q50 = do_valueize (valueize, _q50);
20520 : 0 : switch (TREE_CODE (_q31))
20521 : : {
20522 : 0 : case INTEGER_CST:
20523 : 0 : {
20524 : 0 : switch (TREE_CODE (_p1))
20525 : : {
20526 : 0 : case INTEGER_CST:
20527 : 0 : {
20528 : 0 : {
20529 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _q20, _q40, _q50, _q31, _p1 };
20530 : 0 : if (gimple_simplify_439 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP32))
20531 : 0 : return true;
20532 : : }
20533 : 0 : break;
20534 : : }
20535 : : default:;
20536 : : }
20537 : : break;
20538 : : }
20539 : : default:;
20540 : : }
20541 : : }
20542 : : break;
20543 : 0 : case CFN_BUILT_IN_BSWAP64:
20544 : 0 : if (gimple_call_num_args (_c4) == 1)
20545 : : {
20546 : 0 : tree _q50 = gimple_call_arg (_c4, 0);
20547 : 0 : _q50 = do_valueize (valueize, _q50);
20548 : 0 : switch (TREE_CODE (_q31))
20549 : : {
20550 : 0 : case INTEGER_CST:
20551 : 0 : {
20552 : 0 : switch (TREE_CODE (_p1))
20553 : : {
20554 : 0 : case INTEGER_CST:
20555 : 0 : {
20556 : 0 : {
20557 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _q20, _q40, _q50, _q31, _p1 };
20558 : 0 : if (gimple_simplify_439 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP64))
20559 : 0 : return true;
20560 : : }
20561 : 0 : break;
20562 : : }
20563 : : default:;
20564 : : }
20565 : : break;
20566 : : }
20567 : : default:;
20568 : : }
20569 : : }
20570 : : break;
20571 : : default:;
20572 : : }
20573 : : }
20574 : : break;
20575 : : default:;
20576 : : }
20577 : : break;
20578 : : }
20579 : : default:;
20580 : : }
20581 : : }
20582 : : break;
20583 : 68812 : default:;
20584 : : }
20585 : 68812 : switch (TREE_CODE (_q31))
20586 : : {
20587 : 55319 : case INTEGER_CST:
20588 : 55319 : {
20589 : 55319 : switch (TREE_CODE (_p1))
20590 : : {
20591 : 53159 : case INTEGER_CST:
20592 : 53159 : {
20593 : 53159 : {
20594 : 53159 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q30, _q31, _p1 };
20595 : 53159 : if (gimple_simplify_438 (res_op, seq, valueize, type, captures, RSHIFT_EXPR))
20596 : 0 : return true;
20597 : : }
20598 : 53159 : break;
20599 : : }
20600 : : default:;
20601 : : }
20602 : : break;
20603 : : }
20604 : 68812 : default:;
20605 : : }
20606 : 68812 : switch (TREE_CODE (_q30))
20607 : : {
20608 : 68571 : case SSA_NAME:
20609 : 68571 : if (gimple *_d3 = get_def (valueize, _q30))
20610 : : {
20611 : 61197 : if (gcall *_c3 = dyn_cast <gcall *> (_d3))
20612 : 374 : switch (gimple_call_combined_fn (_c3))
20613 : : {
20614 : 0 : case CFN_BUILT_IN_BSWAP128:
20615 : 0 : if (gimple_call_num_args (_c3) == 1)
20616 : : {
20617 : 0 : tree _q40 = gimple_call_arg (_c3, 0);
20618 : 0 : _q40 = do_valueize (valueize, _q40);
20619 : 0 : switch (TREE_CODE (_q31))
20620 : : {
20621 : 0 : case INTEGER_CST:
20622 : 0 : {
20623 : 0 : switch (TREE_CODE (_p1))
20624 : : {
20625 : 0 : case INTEGER_CST:
20626 : 0 : {
20627 : 0 : {
20628 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _q20, _q30, _q40, _q31, _p1 };
20629 : 0 : if (gimple_simplify_439 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP128))
20630 : 0 : return true;
20631 : : }
20632 : 0 : break;
20633 : : }
20634 : : default:;
20635 : : }
20636 : : break;
20637 : : }
20638 : : default:;
20639 : : }
20640 : : }
20641 : : break;
20642 : 0 : case CFN_BUILT_IN_BSWAP16:
20643 : 0 : if (gimple_call_num_args (_c3) == 1)
20644 : : {
20645 : 0 : tree _q40 = gimple_call_arg (_c3, 0);
20646 : 0 : _q40 = do_valueize (valueize, _q40);
20647 : 0 : switch (TREE_CODE (_q31))
20648 : : {
20649 : 0 : case INTEGER_CST:
20650 : 0 : {
20651 : 0 : switch (TREE_CODE (_p1))
20652 : : {
20653 : 0 : case INTEGER_CST:
20654 : 0 : {
20655 : 0 : {
20656 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _q20, _q30, _q40, _q31, _p1 };
20657 : 0 : if (gimple_simplify_439 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP16))
20658 : 0 : return true;
20659 : : }
20660 : 0 : break;
20661 : : }
20662 : : default:;
20663 : : }
20664 : : break;
20665 : : }
20666 : : default:;
20667 : : }
20668 : : }
20669 : : break;
20670 : 0 : case CFN_BUILT_IN_BSWAP32:
20671 : 0 : if (gimple_call_num_args (_c3) == 1)
20672 : : {
20673 : 0 : tree _q40 = gimple_call_arg (_c3, 0);
20674 : 0 : _q40 = do_valueize (valueize, _q40);
20675 : 0 : switch (TREE_CODE (_q31))
20676 : : {
20677 : 0 : case INTEGER_CST:
20678 : 0 : {
20679 : 0 : switch (TREE_CODE (_p1))
20680 : : {
20681 : 0 : case INTEGER_CST:
20682 : 0 : {
20683 : 0 : {
20684 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _q20, _q30, _q40, _q31, _p1 };
20685 : 0 : if (gimple_simplify_439 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP32))
20686 : 0 : return true;
20687 : : }
20688 : 0 : break;
20689 : : }
20690 : : default:;
20691 : : }
20692 : : break;
20693 : : }
20694 : : default:;
20695 : : }
20696 : : }
20697 : : break;
20698 : 0 : case CFN_BUILT_IN_BSWAP64:
20699 : 0 : if (gimple_call_num_args (_c3) == 1)
20700 : : {
20701 : 0 : tree _q40 = gimple_call_arg (_c3, 0);
20702 : 0 : _q40 = do_valueize (valueize, _q40);
20703 : 0 : switch (TREE_CODE (_q31))
20704 : : {
20705 : 0 : case INTEGER_CST:
20706 : 0 : {
20707 : 0 : switch (TREE_CODE (_p1))
20708 : : {
20709 : 0 : case INTEGER_CST:
20710 : 0 : {
20711 : 0 : {
20712 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _q20, _q30, _q40, _q31, _p1 };
20713 : 0 : if (gimple_simplify_439 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP64))
20714 : 0 : return true;
20715 : : }
20716 : 0 : break;
20717 : : }
20718 : : default:;
20719 : : }
20720 : : break;
20721 : : }
20722 : : default:;
20723 : : }
20724 : : }
20725 : : break;
20726 : : default:;
20727 : : }
20728 : : }
20729 : : break;
20730 : : default:;
20731 : : }
20732 : : break;
20733 : : }
20734 : : default:;
20735 : : }
20736 : 86132 : else if (gcall *_c2 = dyn_cast <gcall *> (_d2))
20737 : 6704 : switch (gimple_call_combined_fn (_c2))
20738 : : {
20739 : 0 : case CFN_BUILT_IN_BSWAP128:
20740 : 0 : if (gimple_call_num_args (_c2) == 1)
20741 : : {
20742 : 0 : tree _q30 = gimple_call_arg (_c2, 0);
20743 : 0 : _q30 = do_valueize (valueize, _q30);
20744 : 0 : switch (TREE_CODE (_p1))
20745 : : {
20746 : 0 : case INTEGER_CST:
20747 : 0 : {
20748 : 0 : {
20749 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q30, _p1 };
20750 : 0 : if (gimple_simplify_440 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP128))
20751 : 0 : return true;
20752 : : }
20753 : 0 : break;
20754 : : }
20755 : : default:;
20756 : : }
20757 : : }
20758 : : break;
20759 : 2 : case CFN_BUILT_IN_BSWAP16:
20760 : 2 : if (gimple_call_num_args (_c2) == 1)
20761 : : {
20762 : 2 : tree _q30 = gimple_call_arg (_c2, 0);
20763 : 2 : _q30 = do_valueize (valueize, _q30);
20764 : 2 : switch (TREE_CODE (_p1))
20765 : : {
20766 : 2 : case INTEGER_CST:
20767 : 2 : {
20768 : 2 : {
20769 : 2 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q30, _p1 };
20770 : 2 : if (gimple_simplify_440 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP16))
20771 : 0 : return true;
20772 : : }
20773 : 2 : break;
20774 : : }
20775 : : default:;
20776 : : }
20777 : : }
20778 : : break;
20779 : 13 : case CFN_BUILT_IN_BSWAP32:
20780 : 13 : if (gimple_call_num_args (_c2) == 1)
20781 : : {
20782 : 13 : tree _q30 = gimple_call_arg (_c2, 0);
20783 : 13 : _q30 = do_valueize (valueize, _q30);
20784 : 13 : switch (TREE_CODE (_p1))
20785 : : {
20786 : 13 : case INTEGER_CST:
20787 : 13 : {
20788 : 13 : {
20789 : 13 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q30, _p1 };
20790 : 13 : if (gimple_simplify_440 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP32))
20791 : 0 : return true;
20792 : : }
20793 : 13 : break;
20794 : : }
20795 : : default:;
20796 : : }
20797 : : }
20798 : : break;
20799 : 16 : case CFN_BUILT_IN_BSWAP64:
20800 : 16 : if (gimple_call_num_args (_c2) == 1)
20801 : : {
20802 : 16 : tree _q30 = gimple_call_arg (_c2, 0);
20803 : 16 : _q30 = do_valueize (valueize, _q30);
20804 : 16 : switch (TREE_CODE (_p1))
20805 : : {
20806 : 16 : case INTEGER_CST:
20807 : 16 : {
20808 : 16 : {
20809 : 16 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q30, _p1 };
20810 : 16 : if (gimple_simplify_440 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP64))
20811 : 4 : return true;
20812 : : }
20813 : 12 : break;
20814 : : }
20815 : : default:;
20816 : : }
20817 : : }
20818 : : break;
20819 : : default:;
20820 : : }
20821 : : }
20822 : : break;
20823 : : default:;
20824 : : }
20825 : : break;
20826 : : }
20827 : : default:;
20828 : : }
20829 : : }
20830 : : break;
20831 : 7747841 : default:;
20832 : : }
20833 : 7747841 : switch (TREE_CODE (_p1))
20834 : : {
20835 : 4991589 : case INTEGER_CST:
20836 : 4991589 : {
20837 : 4991589 : {
20838 : 4991589 : tree captures[2] ATTRIBUTE_UNUSED = { _p0, _p1 };
20839 : 4991589 : if (gimple_simplify_436 (res_op, seq, valueize, type, captures))
20840 : 0 : return true;
20841 : : }
20842 : 4991589 : break;
20843 : : }
20844 : 7747841 : default:;
20845 : : }
20846 : 7747841 : switch (TREE_CODE (_p0))
20847 : : {
20848 : 7658081 : case SSA_NAME:
20849 : 7658081 : if (gimple *_d1 = get_def (valueize, _p0))
20850 : : {
20851 : 5324903 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
20852 : 5663992 : switch (gimple_assign_rhs_code (_a1))
20853 : : {
20854 : 107660 : case GT_EXPR:
20855 : 107660 : {
20856 : 107660 : tree _q20 = gimple_assign_rhs1 (_a1);
20857 : 107660 : _q20 = do_valueize (valueize, _q20);
20858 : 107660 : tree _q21 = gimple_assign_rhs2 (_a1);
20859 : 107660 : _q21 = do_valueize (valueize, _q21);
20860 : 107660 : switch (TREE_CODE (_p1))
20861 : : {
20862 : 107660 : case SSA_NAME:
20863 : 107660 : if (gimple *_d2 = get_def (valueize, _p1))
20864 : : {
20865 : 107071 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
20866 : 105447 : switch (gimple_assign_rhs_code (_a2))
20867 : : {
20868 : 4729 : case EQ_EXPR:
20869 : 4729 : {
20870 : 4729 : tree _q50 = gimple_assign_rhs1 (_a2);
20871 : 4729 : _q50 = do_valueize (valueize, _q50);
20872 : 4729 : tree _q51 = gimple_assign_rhs2 (_a2);
20873 : 4729 : _q51 = do_valueize (valueize, _q51);
20874 : 4729 : if (tree_swap_operands_p (_q50, _q51))
20875 : 16 : std::swap (_q50, _q51);
20876 : 4729 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
20877 : : {
20878 : 50 : if (gimple_min_value (_q51, valueize))
20879 : : {
20880 : 10 : {
20881 : 10 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q21 };
20882 : 10 : if (gimple_simplify_441 (res_op, seq, valueize, type, captures, EQ_EXPR))
20883 : 10 : return true;
20884 : : }
20885 : : }
20886 : : }
20887 : 4719 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
20888 : : {
20889 : 0 : if (gimple_max_value (_q51, valueize))
20890 : : {
20891 : 0 : {
20892 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q21, _q20 };
20893 : 0 : if (gimple_simplify_442 (res_op, seq, valueize, type, captures, EQ_EXPR))
20894 : 0 : return true;
20895 : : }
20896 : : }
20897 : : }
20898 : 105859 : break;
20899 : : }
20900 : 20172 : case NE_EXPR:
20901 : 20172 : {
20902 : 20172 : tree _q50 = gimple_assign_rhs1 (_a2);
20903 : 20172 : _q50 = do_valueize (valueize, _q50);
20904 : 20172 : tree _q51 = gimple_assign_rhs2 (_a2);
20905 : 20172 : _q51 = do_valueize (valueize, _q51);
20906 : 20172 : if (tree_swap_operands_p (_q50, _q51))
20907 : 4 : std::swap (_q50, _q51);
20908 : 20172 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
20909 : : {
20910 : 3141 : if (gimple_min_value (_q51, valueize))
20911 : : {
20912 : 1791 : {
20913 : 1791 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q21 };
20914 : 1791 : if (gimple_simplify_441 (res_op, seq, valueize, type, captures, NE_EXPR))
20915 : 1791 : return true;
20916 : : }
20917 : : }
20918 : : }
20919 : 18381 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
20920 : : {
20921 : 1214 : if (gimple_max_value (_q51, valueize))
20922 : : {
20923 : 0 : {
20924 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q21, _q20 };
20925 : 0 : if (gimple_simplify_442 (res_op, seq, valueize, type, captures, NE_EXPR))
20926 : 0 : return true;
20927 : : }
20928 : : }
20929 : : }
20930 : 105859 : break;
20931 : : }
20932 : : default:;
20933 : : }
20934 : : }
20935 : : break;
20936 : 105859 : default:;
20937 : : }
20938 : 105859 : switch (TREE_CODE (_q20))
20939 : : {
20940 : 105801 : case SSA_NAME:
20941 : 105801 : if (gimple *_d2 = get_def (valueize, _q20))
20942 : : {
20943 : 95810 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
20944 : 68869 : switch (gimple_assign_rhs_code (_a2))
20945 : : {
20946 : 17180 : CASE_CONVERT:
20947 : 17180 : {
20948 : 17180 : tree _q30 = gimple_assign_rhs1 (_a2);
20949 : 17180 : _q30 = do_valueize (valueize, _q30);
20950 : 17180 : switch (TREE_CODE (_p1))
20951 : : {
20952 : 17180 : case SSA_NAME:
20953 : 17180 : if (gimple *_d3 = get_def (valueize, _p1))
20954 : : {
20955 : 17180 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
20956 : 16809 : switch (gimple_assign_rhs_code (_a3))
20957 : : {
20958 : 395 : case EQ_EXPR:
20959 : 395 : {
20960 : 395 : tree _q60 = gimple_assign_rhs1 (_a3);
20961 : 395 : _q60 = do_valueize (valueize, _q60);
20962 : 395 : tree _q61 = gimple_assign_rhs2 (_a3);
20963 : 395 : _q61 = do_valueize (valueize, _q61);
20964 : 395 : if (tree_swap_operands_p (_q60, _q61))
20965 : 0 : std::swap (_q60, _q61);
20966 : 395 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
20967 : : {
20968 : 0 : {
20969 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q61, _p0, _q20, _q21 };
20970 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, GT_EXPR, EQ_EXPR))
20971 : 0 : return true;
20972 : : }
20973 : : }
20974 : 395 : if ((_q61 == _q30 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q30, 0) && types_match (_q61, _q30)))
20975 : : {
20976 : 0 : {
20977 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q60, _p0, _q20, _q21 };
20978 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, GT_EXPR, EQ_EXPR))
20979 : 0 : return true;
20980 : : }
20981 : : }
20982 : 105848 : break;
20983 : : }
20984 : 1843 : case NE_EXPR:
20985 : 1843 : {
20986 : 1843 : tree _q60 = gimple_assign_rhs1 (_a3);
20987 : 1843 : _q60 = do_valueize (valueize, _q60);
20988 : 1843 : tree _q61 = gimple_assign_rhs2 (_a3);
20989 : 1843 : _q61 = do_valueize (valueize, _q61);
20990 : 1843 : if (tree_swap_operands_p (_q60, _q61))
20991 : 0 : std::swap (_q60, _q61);
20992 : 1843 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
20993 : : {
20994 : 25 : {
20995 : 25 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q61, _p0, _q20, _q21 };
20996 : 25 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, GT_EXPR, NE_EXPR))
20997 : 11 : return true;
20998 : : }
20999 : : }
21000 : 1832 : if ((_q61 == _q30 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q30, 0) && types_match (_q61, _q30)))
21001 : : {
21002 : 0 : {
21003 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q60, _p0, _q20, _q21 };
21004 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, GT_EXPR, NE_EXPR))
21005 : 0 : return true;
21006 : : }
21007 : : }
21008 : 105848 : break;
21009 : : }
21010 : : default:;
21011 : : }
21012 : : }
21013 : : break;
21014 : : default:;
21015 : : }
21016 : : break;
21017 : : }
21018 : : default:;
21019 : : }
21020 : : }
21021 : : break;
21022 : 105848 : default:;
21023 : : }
21024 : 105848 : switch (TREE_CODE (_q21))
21025 : : {
21026 : 19603 : case SSA_NAME:
21027 : 19603 : if (gimple *_d2 = get_def (valueize, _q21))
21028 : : {
21029 : 17851 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
21030 : 12942 : switch (gimple_assign_rhs_code (_a2))
21031 : : {
21032 : 3078 : CASE_CONVERT:
21033 : 3078 : {
21034 : 3078 : tree _q40 = gimple_assign_rhs1 (_a2);
21035 : 3078 : _q40 = do_valueize (valueize, _q40);
21036 : 3078 : switch (TREE_CODE (_p1))
21037 : : {
21038 : 3078 : case SSA_NAME:
21039 : 3078 : if (gimple *_d3 = get_def (valueize, _p1))
21040 : : {
21041 : 3078 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
21042 : 3078 : switch (gimple_assign_rhs_code (_a3))
21043 : : {
21044 : 0 : case EQ_EXPR:
21045 : 0 : {
21046 : 0 : tree _q60 = gimple_assign_rhs1 (_a3);
21047 : 0 : _q60 = do_valueize (valueize, _q60);
21048 : 0 : tree _q61 = gimple_assign_rhs2 (_a3);
21049 : 0 : _q61 = do_valueize (valueize, _q61);
21050 : 0 : if (tree_swap_operands_p (_q60, _q61))
21051 : 0 : std::swap (_q60, _q61);
21052 : 0 : if ((_q60 == _q40 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q40, 0) && types_match (_q60, _q40)))
21053 : : {
21054 : 0 : {
21055 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q61, _p0, _q21, _q20 };
21056 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, LT_EXPR, EQ_EXPR))
21057 : 0 : return true;
21058 : : }
21059 : : }
21060 : 0 : if ((_q61 == _q40 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q40, 0) && types_match (_q61, _q40)))
21061 : : {
21062 : 0 : {
21063 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q60, _p0, _q21, _q20 };
21064 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, LT_EXPR, EQ_EXPR))
21065 : 0 : return true;
21066 : : }
21067 : : }
21068 : 105848 : break;
21069 : : }
21070 : 617 : case NE_EXPR:
21071 : 617 : {
21072 : 617 : tree _q60 = gimple_assign_rhs1 (_a3);
21073 : 617 : _q60 = do_valueize (valueize, _q60);
21074 : 617 : tree _q61 = gimple_assign_rhs2 (_a3);
21075 : 617 : _q61 = do_valueize (valueize, _q61);
21076 : 617 : if (tree_swap_operands_p (_q60, _q61))
21077 : 0 : std::swap (_q60, _q61);
21078 : 617 : if ((_q60 == _q40 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q40, 0) && types_match (_q60, _q40)))
21079 : : {
21080 : 474 : {
21081 : 474 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q61, _p0, _q21, _q20 };
21082 : 474 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, LT_EXPR, NE_EXPR))
21083 : 0 : return true;
21084 : : }
21085 : : }
21086 : 617 : if ((_q61 == _q40 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q40, 0) && types_match (_q61, _q40)))
21087 : : {
21088 : 0 : {
21089 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q60, _p0, _q21, _q20 };
21090 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, LT_EXPR, NE_EXPR))
21091 : 0 : return true;
21092 : : }
21093 : : }
21094 : 105848 : break;
21095 : : }
21096 : : default:;
21097 : : }
21098 : : }
21099 : : break;
21100 : : default:;
21101 : : }
21102 : : break;
21103 : : }
21104 : : default:;
21105 : : }
21106 : : }
21107 : : break;
21108 : 105848 : default:;
21109 : : }
21110 : 105848 : switch (TREE_CODE (_p1))
21111 : : {
21112 : 105848 : case SSA_NAME:
21113 : 105848 : if (gimple *_d2 = get_def (valueize, _p1))
21114 : : {
21115 : 105259 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
21116 : 103635 : switch (gimple_assign_rhs_code (_a2))
21117 : : {
21118 : 4719 : case EQ_EXPR:
21119 : 4719 : {
21120 : 4719 : tree _q50 = gimple_assign_rhs1 (_a2);
21121 : 4719 : _q50 = do_valueize (valueize, _q50);
21122 : 4719 : tree _q51 = gimple_assign_rhs2 (_a2);
21123 : 4719 : _q51 = do_valueize (valueize, _q51);
21124 : 4719 : if (tree_swap_operands_p (_q50, _q51))
21125 : 16 : std::swap (_q50, _q51);
21126 : 4719 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
21127 : : {
21128 : 40 : {
21129 : 40 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q51, _p0, _q20, _q21 };
21130 : 40 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, GT_EXPR, EQ_EXPR))
21131 : 13 : return true;
21132 : : }
21133 : : }
21134 : 4706 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
21135 : : {
21136 : 0 : {
21137 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q51, _p0, _q21, _q20 };
21138 : 0 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, LT_EXPR, EQ_EXPR))
21139 : 0 : return true;
21140 : : }
21141 : : }
21142 : 4706 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
21143 : : {
21144 : 0 : {
21145 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q50, _p0, _q20, _q21 };
21146 : 0 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, GT_EXPR, EQ_EXPR))
21147 : 0 : return true;
21148 : : }
21149 : : }
21150 : 4706 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
21151 : : {
21152 : 563 : {
21153 : 563 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q50, _p0, _q21, _q20 };
21154 : 563 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, LT_EXPR, EQ_EXPR))
21155 : 0 : return true;
21156 : : }
21157 : : }
21158 : 7738466 : break;
21159 : : }
21160 : 18370 : case NE_EXPR:
21161 : 18370 : {
21162 : 18370 : tree _q50 = gimple_assign_rhs1 (_a2);
21163 : 18370 : _q50 = do_valueize (valueize, _q50);
21164 : 18370 : tree _q51 = gimple_assign_rhs2 (_a2);
21165 : 18370 : _q51 = do_valueize (valueize, _q51);
21166 : 18370 : if (tree_swap_operands_p (_q50, _q51))
21167 : 4 : std::swap (_q50, _q51);
21168 : 18370 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
21169 : : {
21170 : 1350 : {
21171 : 1350 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q51, _p0, _q20, _q21 };
21172 : 1350 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, GT_EXPR, NE_EXPR))
21173 : 55 : return true;
21174 : : }
21175 : : }
21176 : 18315 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
21177 : : {
21178 : 1214 : {
21179 : 1214 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q51, _p0, _q21, _q20 };
21180 : 1214 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, LT_EXPR, NE_EXPR))
21181 : 16 : return true;
21182 : : }
21183 : : }
21184 : 18299 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
21185 : : {
21186 : 0 : {
21187 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q50, _p0, _q20, _q21 };
21188 : 0 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, GT_EXPR, NE_EXPR))
21189 : 0 : return true;
21190 : : }
21191 : : }
21192 : 18299 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
21193 : : {
21194 : 564 : {
21195 : 564 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q50, _p0, _q21, _q20 };
21196 : 564 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, LT_EXPR, NE_EXPR))
21197 : 0 : return true;
21198 : : }
21199 : : }
21200 : 7738466 : break;
21201 : : }
21202 : 2349 : case LT_EXPR:
21203 : 2349 : {
21204 : 2349 : tree _q50 = gimple_assign_rhs1 (_a2);
21205 : 2349 : _q50 = do_valueize (valueize, _q50);
21206 : 2349 : tree _q51 = gimple_assign_rhs2 (_a2);
21207 : 2349 : _q51 = do_valueize (valueize, _q51);
21208 : 2349 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
21209 : : {
21210 : 558 : {
21211 : 558 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
21212 : 558 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LT_EXPR, GT_EXPR))
21213 : 0 : return true;
21214 : : }
21215 : : }
21216 : 2349 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
21217 : : {
21218 : 244 : {
21219 : 244 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
21220 : 244 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GT_EXPR, GT_EXPR))
21221 : 0 : return true;
21222 : : }
21223 : : }
21224 : 2349 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
21225 : : {
21226 : 8 : {
21227 : 8 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
21228 : 8 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LT_EXPR, LT_EXPR))
21229 : 0 : return true;
21230 : : }
21231 : : }
21232 : 2349 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
21233 : : {
21234 : 131 : {
21235 : 131 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
21236 : 131 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GT_EXPR, LT_EXPR))
21237 : 0 : return true;
21238 : : }
21239 : : }
21240 : : break;
21241 : : }
21242 : 30140 : case LE_EXPR:
21243 : 30140 : {
21244 : 30140 : tree _q50 = gimple_assign_rhs1 (_a2);
21245 : 30140 : _q50 = do_valueize (valueize, _q50);
21246 : 30140 : tree _q51 = gimple_assign_rhs2 (_a2);
21247 : 30140 : _q51 = do_valueize (valueize, _q51);
21248 : 30140 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
21249 : : {
21250 : 4130 : {
21251 : 4130 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
21252 : 4130 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LE_EXPR, GT_EXPR))
21253 : 0 : return true;
21254 : : }
21255 : : }
21256 : 30140 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
21257 : : {
21258 : 17 : {
21259 : 17 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
21260 : 17 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GE_EXPR, GT_EXPR))
21261 : 0 : return true;
21262 : : }
21263 : : }
21264 : 30140 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
21265 : : {
21266 : 568 : {
21267 : 568 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
21268 : 568 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LE_EXPR, LT_EXPR))
21269 : 0 : return true;
21270 : : }
21271 : : }
21272 : 30140 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
21273 : : {
21274 : 20146 : {
21275 : 20146 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
21276 : 20146 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GE_EXPR, LT_EXPR))
21277 : 0 : return true;
21278 : : }
21279 : : }
21280 : : break;
21281 : : }
21282 : 34514 : case GT_EXPR:
21283 : 34514 : {
21284 : 34514 : tree _q50 = gimple_assign_rhs1 (_a2);
21285 : 34514 : _q50 = do_valueize (valueize, _q50);
21286 : 34514 : tree _q51 = gimple_assign_rhs2 (_a2);
21287 : 34514 : _q51 = do_valueize (valueize, _q51);
21288 : 34514 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
21289 : : {
21290 : 359 : {
21291 : 359 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
21292 : 359 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GT_EXPR, GT_EXPR))
21293 : 78 : return true;
21294 : : }
21295 : : }
21296 : 34436 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
21297 : : {
21298 : 729 : {
21299 : 729 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
21300 : 729 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LT_EXPR, GT_EXPR))
21301 : 0 : return true;
21302 : : }
21303 : : }
21304 : 34436 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
21305 : : {
21306 : 230 : {
21307 : 230 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
21308 : 230 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GT_EXPR, LT_EXPR))
21309 : 0 : return true;
21310 : : }
21311 : : }
21312 : 34436 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
21313 : : {
21314 : 17300 : {
21315 : 17300 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
21316 : 17300 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LT_EXPR, LT_EXPR))
21317 : 0 : return true;
21318 : : }
21319 : : }
21320 : : break;
21321 : : }
21322 : 8594 : case GE_EXPR:
21323 : 8594 : {
21324 : 8594 : tree _q50 = gimple_assign_rhs1 (_a2);
21325 : 8594 : _q50 = do_valueize (valueize, _q50);
21326 : 8594 : tree _q51 = gimple_assign_rhs2 (_a2);
21327 : 8594 : _q51 = do_valueize (valueize, _q51);
21328 : 8594 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
21329 : : {
21330 : 101 : {
21331 : 101 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
21332 : 101 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GE_EXPR, GT_EXPR))
21333 : 27 : return true;
21334 : : }
21335 : : }
21336 : 8567 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
21337 : : {
21338 : 317 : {
21339 : 317 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
21340 : 317 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LE_EXPR, GT_EXPR))
21341 : 0 : return true;
21342 : : }
21343 : : }
21344 : 8567 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
21345 : : {
21346 : 6460 : {
21347 : 6460 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
21348 : 6460 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GE_EXPR, LT_EXPR))
21349 : 0 : return true;
21350 : : }
21351 : : }
21352 : 8567 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
21353 : : {
21354 : 231 : {
21355 : 231 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
21356 : 231 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LE_EXPR, LT_EXPR))
21357 : 0 : return true;
21358 : : }
21359 : : }
21360 : : break;
21361 : : }
21362 : : default:;
21363 : : }
21364 : : }
21365 : : break;
21366 : : default:;
21367 : : }
21368 : : break;
21369 : : }
21370 : 43346 : case LT_EXPR:
21371 : 43346 : {
21372 : 43346 : tree _q20 = gimple_assign_rhs1 (_a1);
21373 : 43346 : _q20 = do_valueize (valueize, _q20);
21374 : 43346 : tree _q21 = gimple_assign_rhs2 (_a1);
21375 : 43346 : _q21 = do_valueize (valueize, _q21);
21376 : 43346 : switch (TREE_CODE (_p1))
21377 : : {
21378 : 43346 : case SSA_NAME:
21379 : 43346 : if (gimple *_d2 = get_def (valueize, _p1))
21380 : : {
21381 : 43106 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
21382 : 43084 : switch (gimple_assign_rhs_code (_a2))
21383 : : {
21384 : 1076 : case EQ_EXPR:
21385 : 1076 : {
21386 : 1076 : tree _q50 = gimple_assign_rhs1 (_a2);
21387 : 1076 : _q50 = do_valueize (valueize, _q50);
21388 : 1076 : tree _q51 = gimple_assign_rhs2 (_a2);
21389 : 1076 : _q51 = do_valueize (valueize, _q51);
21390 : 1076 : if (tree_swap_operands_p (_q50, _q51))
21391 : 0 : std::swap (_q50, _q51);
21392 : 1076 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
21393 : : {
21394 : 8 : if (gimple_min_value (_q51, valueize))
21395 : : {
21396 : 0 : {
21397 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q21, _q20 };
21398 : 0 : if (gimple_simplify_441 (res_op, seq, valueize, type, captures, EQ_EXPR))
21399 : 0 : return true;
21400 : : }
21401 : : }
21402 : : }
21403 : 1076 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
21404 : : {
21405 : 17 : if (gimple_max_value (_q51, valueize))
21406 : : {
21407 : 10 : {
21408 : 10 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q21 };
21409 : 10 : if (gimple_simplify_442 (res_op, seq, valueize, type, captures, EQ_EXPR))
21410 : 10 : return true;
21411 : : }
21412 : : }
21413 : : }
21414 : 43322 : break;
21415 : : }
21416 : 6348 : case NE_EXPR:
21417 : 6348 : {
21418 : 6348 : tree _q50 = gimple_assign_rhs1 (_a2);
21419 : 6348 : _q50 = do_valueize (valueize, _q50);
21420 : 6348 : tree _q51 = gimple_assign_rhs2 (_a2);
21421 : 6348 : _q51 = do_valueize (valueize, _q51);
21422 : 6348 : if (tree_swap_operands_p (_q50, _q51))
21423 : 6 : std::swap (_q50, _q51);
21424 : 6348 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
21425 : : {
21426 : 13 : if (gimple_min_value (_q51, valueize))
21427 : : {
21428 : 0 : {
21429 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q21, _q20 };
21430 : 0 : if (gimple_simplify_441 (res_op, seq, valueize, type, captures, NE_EXPR))
21431 : 0 : return true;
21432 : : }
21433 : : }
21434 : : }
21435 : 6348 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
21436 : : {
21437 : 1104 : if (gimple_max_value (_q51, valueize))
21438 : : {
21439 : 14 : {
21440 : 14 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _q21 };
21441 : 14 : if (gimple_simplify_442 (res_op, seq, valueize, type, captures, NE_EXPR))
21442 : 14 : return true;
21443 : : }
21444 : : }
21445 : : }
21446 : 43322 : break;
21447 : : }
21448 : : default:;
21449 : : }
21450 : : }
21451 : : break;
21452 : 43322 : default:;
21453 : : }
21454 : 43322 : switch (TREE_CODE (_q20))
21455 : : {
21456 : 43161 : case SSA_NAME:
21457 : 43161 : if (gimple *_d2 = get_def (valueize, _q20))
21458 : : {
21459 : 38784 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
21460 : 15983 : switch (gimple_assign_rhs_code (_a2))
21461 : : {
21462 : 2040 : CASE_CONVERT:
21463 : 2040 : {
21464 : 2040 : tree _q30 = gimple_assign_rhs1 (_a2);
21465 : 2040 : _q30 = do_valueize (valueize, _q30);
21466 : 2040 : switch (TREE_CODE (_p1))
21467 : : {
21468 : 2040 : case SSA_NAME:
21469 : 2040 : if (gimple *_d3 = get_def (valueize, _p1))
21470 : : {
21471 : 2040 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
21472 : 2040 : switch (gimple_assign_rhs_code (_a3))
21473 : : {
21474 : 22 : case EQ_EXPR:
21475 : 22 : {
21476 : 22 : tree _q60 = gimple_assign_rhs1 (_a3);
21477 : 22 : _q60 = do_valueize (valueize, _q60);
21478 : 22 : tree _q61 = gimple_assign_rhs2 (_a3);
21479 : 22 : _q61 = do_valueize (valueize, _q61);
21480 : 22 : if (tree_swap_operands_p (_q60, _q61))
21481 : 0 : std::swap (_q60, _q61);
21482 : 22 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
21483 : : {
21484 : 0 : {
21485 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q61, _p0, _q20, _q21 };
21486 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, LT_EXPR, EQ_EXPR))
21487 : 0 : return true;
21488 : : }
21489 : : }
21490 : 22 : if ((_q61 == _q30 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q30, 0) && types_match (_q61, _q30)))
21491 : : {
21492 : 0 : {
21493 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q60, _p0, _q20, _q21 };
21494 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, LT_EXPR, EQ_EXPR))
21495 : 0 : return true;
21496 : : }
21497 : : }
21498 : 43322 : break;
21499 : : }
21500 : 374 : case NE_EXPR:
21501 : 374 : {
21502 : 374 : tree _q60 = gimple_assign_rhs1 (_a3);
21503 : 374 : _q60 = do_valueize (valueize, _q60);
21504 : 374 : tree _q61 = gimple_assign_rhs2 (_a3);
21505 : 374 : _q61 = do_valueize (valueize, _q61);
21506 : 374 : if (tree_swap_operands_p (_q60, _q61))
21507 : 0 : std::swap (_q60, _q61);
21508 : 374 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
21509 : : {
21510 : 7 : {
21511 : 7 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q61, _p0, _q20, _q21 };
21512 : 7 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, LT_EXPR, NE_EXPR))
21513 : 0 : return true;
21514 : : }
21515 : : }
21516 : 374 : if ((_q61 == _q30 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q30, 0) && types_match (_q61, _q30)))
21517 : : {
21518 : 0 : {
21519 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q60, _p0, _q20, _q21 };
21520 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, LT_EXPR, NE_EXPR))
21521 : 0 : return true;
21522 : : }
21523 : : }
21524 : 43322 : break;
21525 : : }
21526 : : default:;
21527 : : }
21528 : : }
21529 : : break;
21530 : : default:;
21531 : : }
21532 : : break;
21533 : : }
21534 : : default:;
21535 : : }
21536 : : }
21537 : : break;
21538 : 43322 : default:;
21539 : : }
21540 : 43322 : switch (TREE_CODE (_q21))
21541 : : {
21542 : 22895 : case SSA_NAME:
21543 : 22895 : if (gimple *_d2 = get_def (valueize, _q21))
21544 : : {
21545 : 21342 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
21546 : 26357 : switch (gimple_assign_rhs_code (_a2))
21547 : : {
21548 : 684 : CASE_CONVERT:
21549 : 684 : {
21550 : 684 : tree _q40 = gimple_assign_rhs1 (_a2);
21551 : 684 : _q40 = do_valueize (valueize, _q40);
21552 : 684 : switch (TREE_CODE (_p1))
21553 : : {
21554 : 684 : case SSA_NAME:
21555 : 684 : if (gimple *_d3 = get_def (valueize, _p1))
21556 : : {
21557 : 684 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
21558 : 685 : switch (gimple_assign_rhs_code (_a3))
21559 : : {
21560 : 62 : case EQ_EXPR:
21561 : 62 : {
21562 : 62 : tree _q60 = gimple_assign_rhs1 (_a3);
21563 : 62 : _q60 = do_valueize (valueize, _q60);
21564 : 62 : tree _q61 = gimple_assign_rhs2 (_a3);
21565 : 62 : _q61 = do_valueize (valueize, _q61);
21566 : 62 : if (tree_swap_operands_p (_q60, _q61))
21567 : 0 : std::swap (_q60, _q61);
21568 : 62 : if ((_q60 == _q40 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q40, 0) && types_match (_q60, _q40)))
21569 : : {
21570 : 0 : {
21571 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q61, _p0, _q21, _q20 };
21572 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, GT_EXPR, EQ_EXPR))
21573 : 0 : return true;
21574 : : }
21575 : : }
21576 : 62 : if ((_q61 == _q40 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q40, 0) && types_match (_q61, _q40)))
21577 : : {
21578 : 0 : {
21579 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q60, _p0, _q21, _q20 };
21580 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, GT_EXPR, EQ_EXPR))
21581 : 0 : return true;
21582 : : }
21583 : : }
21584 : 43322 : break;
21585 : : }
21586 : 95 : case NE_EXPR:
21587 : 95 : {
21588 : 95 : tree _q60 = gimple_assign_rhs1 (_a3);
21589 : 95 : _q60 = do_valueize (valueize, _q60);
21590 : 95 : tree _q61 = gimple_assign_rhs2 (_a3);
21591 : 95 : _q61 = do_valueize (valueize, _q61);
21592 : 95 : if (tree_swap_operands_p (_q60, _q61))
21593 : 0 : std::swap (_q60, _q61);
21594 : 95 : if ((_q60 == _q40 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q40, 0) && types_match (_q60, _q40)))
21595 : : {
21596 : 0 : {
21597 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q61, _p0, _q21, _q20 };
21598 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, GT_EXPR, NE_EXPR))
21599 : 0 : return true;
21600 : : }
21601 : : }
21602 : 95 : if ((_q61 == _q40 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q40, 0) && types_match (_q61, _q40)))
21603 : : {
21604 : 0 : {
21605 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q60, _p0, _q21, _q20 };
21606 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, GT_EXPR, NE_EXPR))
21607 : 0 : return true;
21608 : : }
21609 : : }
21610 : 43322 : break;
21611 : : }
21612 : : default:;
21613 : : }
21614 : : }
21615 : : break;
21616 : : default:;
21617 : : }
21618 : : break;
21619 : : }
21620 : : default:;
21621 : : }
21622 : : }
21623 : : break;
21624 : 43322 : default:;
21625 : : }
21626 : 43322 : switch (TREE_CODE (_p1))
21627 : : {
21628 : 43322 : case SSA_NAME:
21629 : 43322 : if (gimple *_d2 = get_def (valueize, _p1))
21630 : : {
21631 : 43082 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
21632 : 43060 : switch (gimple_assign_rhs_code (_a2))
21633 : : {
21634 : 1066 : case EQ_EXPR:
21635 : 1066 : {
21636 : 1066 : tree _q50 = gimple_assign_rhs1 (_a2);
21637 : 1066 : _q50 = do_valueize (valueize, _q50);
21638 : 1066 : tree _q51 = gimple_assign_rhs2 (_a2);
21639 : 1066 : _q51 = do_valueize (valueize, _q51);
21640 : 1066 : if (tree_swap_operands_p (_q50, _q51))
21641 : 0 : std::swap (_q50, _q51);
21642 : 1066 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
21643 : : {
21644 : 7 : {
21645 : 7 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q51, _p0, _q20, _q21 };
21646 : 7 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, LT_EXPR, EQ_EXPR))
21647 : 1 : return true;
21648 : : }
21649 : : }
21650 : 1065 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
21651 : : {
21652 : 8 : {
21653 : 8 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q51, _p0, _q21, _q20 };
21654 : 8 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, GT_EXPR, EQ_EXPR))
21655 : 0 : return true;
21656 : : }
21657 : : }
21658 : 1065 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
21659 : : {
21660 : 0 : {
21661 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q50, _p0, _q20, _q21 };
21662 : 0 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, LT_EXPR, EQ_EXPR))
21663 : 0 : return true;
21664 : : }
21665 : : }
21666 : 1065 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
21667 : : {
21668 : 8 : {
21669 : 8 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q50, _p0, _q21, _q20 };
21670 : 8 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, GT_EXPR, EQ_EXPR))
21671 : 0 : return true;
21672 : : }
21673 : : }
21674 : 7738466 : break;
21675 : : }
21676 : 6334 : case NE_EXPR:
21677 : 6334 : {
21678 : 6334 : tree _q50 = gimple_assign_rhs1 (_a2);
21679 : 6334 : _q50 = do_valueize (valueize, _q50);
21680 : 6334 : tree _q51 = gimple_assign_rhs2 (_a2);
21681 : 6334 : _q51 = do_valueize (valueize, _q51);
21682 : 6334 : if (tree_swap_operands_p (_q50, _q51))
21683 : 6 : std::swap (_q50, _q51);
21684 : 6334 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
21685 : : {
21686 : 1090 : {
21687 : 1090 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q51, _p0, _q20, _q21 };
21688 : 1090 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, LT_EXPR, NE_EXPR))
21689 : 17 : return true;
21690 : : }
21691 : : }
21692 : 6317 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
21693 : : {
21694 : 13 : {
21695 : 13 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q51, _p0, _q21, _q20 };
21696 : 13 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, GT_EXPR, NE_EXPR))
21697 : 0 : return true;
21698 : : }
21699 : : }
21700 : 6317 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
21701 : : {
21702 : 50 : {
21703 : 50 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q50, _p0, _q20, _q21 };
21704 : 50 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, LT_EXPR, NE_EXPR))
21705 : 0 : return true;
21706 : : }
21707 : : }
21708 : 6317 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
21709 : : {
21710 : 79 : {
21711 : 79 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q50, _p0, _q21, _q20 };
21712 : 79 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, GT_EXPR, NE_EXPR))
21713 : 0 : return true;
21714 : : }
21715 : : }
21716 : 7738466 : break;
21717 : : }
21718 : 4021 : case LT_EXPR:
21719 : 4021 : {
21720 : 4021 : tree _q50 = gimple_assign_rhs1 (_a2);
21721 : 4021 : _q50 = do_valueize (valueize, _q50);
21722 : 4021 : tree _q51 = gimple_assign_rhs2 (_a2);
21723 : 4021 : _q51 = do_valueize (valueize, _q51);
21724 : 4021 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
21725 : : {
21726 : 167 : {
21727 : 167 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
21728 : 167 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LT_EXPR, LT_EXPR))
21729 : 0 : return true;
21730 : : }
21731 : : }
21732 : 4021 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
21733 : : {
21734 : 12 : {
21735 : 12 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
21736 : 12 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GT_EXPR, LT_EXPR))
21737 : 0 : return true;
21738 : : }
21739 : : }
21740 : 4021 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
21741 : : {
21742 : 38 : {
21743 : 38 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
21744 : 38 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LT_EXPR, GT_EXPR))
21745 : 0 : return true;
21746 : : }
21747 : : }
21748 : 4021 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
21749 : : {
21750 : 560 : {
21751 : 560 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
21752 : 560 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GT_EXPR, GT_EXPR))
21753 : 0 : return true;
21754 : : }
21755 : : }
21756 : : break;
21757 : : }
21758 : 1686 : case LE_EXPR:
21759 : 1686 : {
21760 : 1686 : tree _q50 = gimple_assign_rhs1 (_a2);
21761 : 1686 : _q50 = do_valueize (valueize, _q50);
21762 : 1686 : tree _q51 = gimple_assign_rhs2 (_a2);
21763 : 1686 : _q51 = do_valueize (valueize, _q51);
21764 : 1686 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
21765 : : {
21766 : 38 : {
21767 : 38 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
21768 : 38 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LE_EXPR, LT_EXPR))
21769 : 18 : return true;
21770 : : }
21771 : : }
21772 : 1668 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
21773 : : {
21774 : 102 : {
21775 : 102 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
21776 : 102 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GE_EXPR, LT_EXPR))
21777 : 0 : return true;
21778 : : }
21779 : : }
21780 : 1668 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
21781 : : {
21782 : 226 : {
21783 : 226 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
21784 : 226 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LE_EXPR, GT_EXPR))
21785 : 0 : return true;
21786 : : }
21787 : : }
21788 : 1668 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
21789 : : {
21790 : 41 : {
21791 : 41 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
21792 : 41 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GE_EXPR, GT_EXPR))
21793 : 0 : return true;
21794 : : }
21795 : : }
21796 : : break;
21797 : : }
21798 : 1426 : case GT_EXPR:
21799 : 1426 : {
21800 : 1426 : tree _q50 = gimple_assign_rhs1 (_a2);
21801 : 1426 : _q50 = do_valueize (valueize, _q50);
21802 : 1426 : tree _q51 = gimple_assign_rhs2 (_a2);
21803 : 1426 : _q51 = do_valueize (valueize, _q51);
21804 : 1426 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
21805 : : {
21806 : 789 : {
21807 : 789 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
21808 : 789 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GT_EXPR, LT_EXPR))
21809 : 2 : return true;
21810 : : }
21811 : : }
21812 : 1424 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
21813 : : {
21814 : 1 : {
21815 : 1 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
21816 : 1 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LT_EXPR, LT_EXPR))
21817 : 0 : return true;
21818 : : }
21819 : : }
21820 : 1424 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
21821 : : {
21822 : 30 : {
21823 : 30 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
21824 : 30 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GT_EXPR, GT_EXPR))
21825 : 0 : return true;
21826 : : }
21827 : : }
21828 : 1424 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
21829 : : {
21830 : 228 : {
21831 : 228 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
21832 : 228 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LT_EXPR, GT_EXPR))
21833 : 0 : return true;
21834 : : }
21835 : : }
21836 : : break;
21837 : : }
21838 : 27107 : case GE_EXPR:
21839 : 27107 : {
21840 : 27107 : tree _q50 = gimple_assign_rhs1 (_a2);
21841 : 27107 : _q50 = do_valueize (valueize, _q50);
21842 : 27107 : tree _q51 = gimple_assign_rhs2 (_a2);
21843 : 27107 : _q51 = do_valueize (valueize, _q51);
21844 : 27107 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
21845 : : {
21846 : 10330 : {
21847 : 10330 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
21848 : 10330 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GE_EXPR, LT_EXPR))
21849 : 0 : return true;
21850 : : }
21851 : : }
21852 : 27107 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
21853 : : {
21854 : 1 : {
21855 : 1 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
21856 : 1 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LE_EXPR, LT_EXPR))
21857 : 0 : return true;
21858 : : }
21859 : : }
21860 : 27107 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
21861 : : {
21862 : 10 : {
21863 : 10 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
21864 : 10 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GE_EXPR, GT_EXPR))
21865 : 0 : return true;
21866 : : }
21867 : : }
21868 : 27107 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
21869 : : {
21870 : 15712 : {
21871 : 15712 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
21872 : 15712 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LE_EXPR, GT_EXPR))
21873 : 0 : return true;
21874 : : }
21875 : : }
21876 : : break;
21877 : : }
21878 : : default:;
21879 : : }
21880 : : }
21881 : : break;
21882 : : default:;
21883 : : }
21884 : : break;
21885 : : }
21886 : 281619 : case EQ_EXPR:
21887 : 281619 : {
21888 : 281619 : tree _q20 = gimple_assign_rhs1 (_a1);
21889 : 281619 : _q20 = do_valueize (valueize, _q20);
21890 : 281619 : tree _q21 = gimple_assign_rhs2 (_a1);
21891 : 281619 : _q21 = do_valueize (valueize, _q21);
21892 : 281619 : if (tree_swap_operands_p (_q20, _q21))
21893 : 5796 : std::swap (_q20, _q21);
21894 : 281619 : if (gimple_min_value (_q21, valueize))
21895 : : {
21896 : 51165 : switch (TREE_CODE (_p1))
21897 : : {
21898 : 51085 : case SSA_NAME:
21899 : 51085 : if (gimple *_d2 = get_def (valueize, _p1))
21900 : : {
21901 : 50857 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
21902 : 50229 : switch (gimple_assign_rhs_code (_a2))
21903 : : {
21904 : 641 : case GT_EXPR:
21905 : 641 : {
21906 : 641 : tree _q50 = gimple_assign_rhs1 (_a2);
21907 : 641 : _q50 = do_valueize (valueize, _q50);
21908 : 641 : tree _q51 = gimple_assign_rhs2 (_a2);
21909 : 641 : _q51 = do_valueize (valueize, _q51);
21910 : 641 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
21911 : : {
21912 : 0 : {
21913 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _q20, _q51 };
21914 : 0 : if (gimple_simplify_446 (res_op, seq, valueize, type, captures, EQ_EXPR))
21915 : 0 : return true;
21916 : : }
21917 : : }
21918 : : break;
21919 : : }
21920 : 296 : case LT_EXPR:
21921 : 296 : {
21922 : 296 : tree _q50 = gimple_assign_rhs1 (_a2);
21923 : 296 : _q50 = do_valueize (valueize, _q50);
21924 : 296 : tree _q51 = gimple_assign_rhs2 (_a2);
21925 : 296 : _q51 = do_valueize (valueize, _q51);
21926 : 296 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
21927 : : {
21928 : 0 : {
21929 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _q20, _q50 };
21930 : 0 : if (gimple_simplify_446 (res_op, seq, valueize, type, captures, EQ_EXPR))
21931 : 0 : return true;
21932 : : }
21933 : : }
21934 : : break;
21935 : : }
21936 : 738 : case LE_EXPR:
21937 : 738 : {
21938 : 738 : tree _q50 = gimple_assign_rhs1 (_a2);
21939 : 738 : _q50 = do_valueize (valueize, _q50);
21940 : 738 : tree _q51 = gimple_assign_rhs2 (_a2);
21941 : 738 : _q51 = do_valueize (valueize, _q51);
21942 : 738 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
21943 : : {
21944 : 15 : {
21945 : 15 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q51, _p0 };
21946 : 15 : if (gimple_simplify_447 (res_op, seq, valueize, type, captures))
21947 : 15 : return true;
21948 : : }
21949 : : }
21950 : : break;
21951 : : }
21952 : 230 : case GE_EXPR:
21953 : 230 : {
21954 : 230 : tree _q50 = gimple_assign_rhs1 (_a2);
21955 : 230 : _q50 = do_valueize (valueize, _q50);
21956 : 230 : tree _q51 = gimple_assign_rhs2 (_a2);
21957 : 230 : _q51 = do_valueize (valueize, _q51);
21958 : 230 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
21959 : : {
21960 : 34 : {
21961 : 34 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q50, _p0 };
21962 : 34 : if (gimple_simplify_447 (res_op, seq, valueize, type, captures))
21963 : 34 : return true;
21964 : : }
21965 : : }
21966 : : break;
21967 : : }
21968 : : default:;
21969 : : }
21970 : : }
21971 : : break;
21972 : : default:;
21973 : : }
21974 : : }
21975 : 281570 : if (gimple_max_value (_q21, valueize))
21976 : : {
21977 : 12896 : switch (TREE_CODE (_p1))
21978 : : {
21979 : 12896 : case SSA_NAME:
21980 : 12896 : if (gimple *_d2 = get_def (valueize, _p1))
21981 : : {
21982 : 12896 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
21983 : 12390 : switch (gimple_assign_rhs_code (_a2))
21984 : : {
21985 : 26 : case LT_EXPR:
21986 : 26 : {
21987 : 26 : tree _q50 = gimple_assign_rhs1 (_a2);
21988 : 26 : _q50 = do_valueize (valueize, _q50);
21989 : 26 : tree _q51 = gimple_assign_rhs2 (_a2);
21990 : 26 : _q51 = do_valueize (valueize, _q51);
21991 : 26 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
21992 : : {
21993 : 0 : {
21994 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _q20, _q51 };
21995 : 0 : if (gimple_simplify_448 (res_op, seq, valueize, type, captures, EQ_EXPR))
21996 : 0 : return true;
21997 : : }
21998 : : }
21999 : : break;
22000 : : }
22001 : 18 : case GT_EXPR:
22002 : 18 : {
22003 : 18 : tree _q50 = gimple_assign_rhs1 (_a2);
22004 : 18 : _q50 = do_valueize (valueize, _q50);
22005 : 18 : tree _q51 = gimple_assign_rhs2 (_a2);
22006 : 18 : _q51 = do_valueize (valueize, _q51);
22007 : 18 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
22008 : : {
22009 : 0 : {
22010 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _q20, _q50 };
22011 : 0 : if (gimple_simplify_448 (res_op, seq, valueize, type, captures, EQ_EXPR))
22012 : 0 : return true;
22013 : : }
22014 : : }
22015 : : break;
22016 : : }
22017 : 6 : case GE_EXPR:
22018 : 6 : {
22019 : 6 : tree _q50 = gimple_assign_rhs1 (_a2);
22020 : 6 : _q50 = do_valueize (valueize, _q50);
22021 : 6 : tree _q51 = gimple_assign_rhs2 (_a2);
22022 : 6 : _q51 = do_valueize (valueize, _q51);
22023 : 6 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
22024 : : {
22025 : 6 : {
22026 : 6 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q51, _p0 };
22027 : 6 : if (gimple_simplify_449 (res_op, seq, valueize, type, captures))
22028 : 6 : return true;
22029 : : }
22030 : : }
22031 : : break;
22032 : : }
22033 : 11 : case LE_EXPR:
22034 : 11 : {
22035 : 11 : tree _q50 = gimple_assign_rhs1 (_a2);
22036 : 11 : _q50 = do_valueize (valueize, _q50);
22037 : 11 : tree _q51 = gimple_assign_rhs2 (_a2);
22038 : 11 : _q51 = do_valueize (valueize, _q51);
22039 : 11 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
22040 : : {
22041 : 0 : {
22042 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q50, _p0 };
22043 : 0 : if (gimple_simplify_449 (res_op, seq, valueize, type, captures))
22044 : 0 : return true;
22045 : : }
22046 : : }
22047 : : break;
22048 : : }
22049 : : default:;
22050 : : }
22051 : : }
22052 : : break;
22053 : : default:;
22054 : : }
22055 : : }
22056 : 281564 : switch (TREE_CODE (_p1))
22057 : : {
22058 : 281484 : case SSA_NAME:
22059 : 281484 : if (gimple *_d2 = get_def (valueize, _p1))
22060 : : {
22061 : 279850 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
22062 : 277036 : switch (gimple_assign_rhs_code (_a2))
22063 : : {
22064 : 153297 : case EQ_EXPR:
22065 : 153297 : {
22066 : 153297 : tree _q50 = gimple_assign_rhs1 (_a2);
22067 : 153297 : _q50 = do_valueize (valueize, _q50);
22068 : 153297 : tree _q51 = gimple_assign_rhs2 (_a2);
22069 : 153297 : _q51 = do_valueize (valueize, _q51);
22070 : 153297 : if (tree_swap_operands_p (_q50, _q51))
22071 : 1346 : std::swap (_q50, _q51);
22072 : 153297 : switch (TREE_CODE (_q50))
22073 : : {
22074 : 150702 : case SSA_NAME:
22075 : 150702 : if (gimple *_d3 = get_def (valueize, _q50))
22076 : : {
22077 : 141906 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
22078 : 191696 : switch (gimple_assign_rhs_code (_a3))
22079 : : {
22080 : 4890 : CASE_CONVERT:
22081 : 4890 : {
22082 : 4890 : tree _q60 = gimple_assign_rhs1 (_a3);
22083 : 4890 : _q60 = do_valueize (valueize, _q60);
22084 : 4890 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
22085 : : {
22086 : 16 : {
22087 : 16 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
22088 : 16 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, EQ_EXPR, EQ_EXPR))
22089 : 7 : return true;
22090 : : }
22091 : : }
22092 : 4883 : if ((_q60 == _q21 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q21, 0) && types_match (_q60, _q21)))
22093 : : {
22094 : 0 : {
22095 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
22096 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, EQ_EXPR, EQ_EXPR))
22097 : 0 : return true;
22098 : : }
22099 : : }
22100 : : break;
22101 : : }
22102 : : default:;
22103 : : }
22104 : : }
22105 : : break;
22106 : 153290 : default:;
22107 : : }
22108 : 153290 : switch (TREE_CODE (_q51))
22109 : : {
22110 : 52609 : case SSA_NAME:
22111 : 52609 : if (gimple *_d3 = get_def (valueize, _q51))
22112 : : {
22113 : 50714 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
22114 : 81839 : switch (gimple_assign_rhs_code (_a3))
22115 : : {
22116 : 2162 : CASE_CONVERT:
22117 : 2162 : {
22118 : 2162 : tree _q70 = gimple_assign_rhs1 (_a3);
22119 : 2162 : _q70 = do_valueize (valueize, _q70);
22120 : 2162 : if ((_q70 == _q20 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q20, 0) && types_match (_q70, _q20)))
22121 : : {
22122 : 0 : {
22123 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
22124 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, EQ_EXPR, EQ_EXPR))
22125 : 0 : return true;
22126 : : }
22127 : : }
22128 : 2162 : if ((_q70 == _q21 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q21, 0) && types_match (_q70, _q21)))
22129 : : {
22130 : 0 : {
22131 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
22132 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, EQ_EXPR, EQ_EXPR))
22133 : 0 : return true;
22134 : : }
22135 : : }
22136 : : break;
22137 : : }
22138 : : default:;
22139 : : }
22140 : : }
22141 : : break;
22142 : : default:;
22143 : : }
22144 : 281552 : break;
22145 : : }
22146 : 87268 : case NE_EXPR:
22147 : 87268 : {
22148 : 87268 : tree _q50 = gimple_assign_rhs1 (_a2);
22149 : 87268 : _q50 = do_valueize (valueize, _q50);
22150 : 87268 : tree _q51 = gimple_assign_rhs2 (_a2);
22151 : 87268 : _q51 = do_valueize (valueize, _q51);
22152 : 87268 : if (tree_swap_operands_p (_q50, _q51))
22153 : 49 : std::swap (_q50, _q51);
22154 : 87268 : switch (TREE_CODE (_q50))
22155 : : {
22156 : 87104 : case SSA_NAME:
22157 : 87104 : if (gimple *_d3 = get_def (valueize, _q50))
22158 : : {
22159 : 77675 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
22160 : 63320 : switch (gimple_assign_rhs_code (_a3))
22161 : : {
22162 : 2738 : CASE_CONVERT:
22163 : 2738 : {
22164 : 2738 : tree _q60 = gimple_assign_rhs1 (_a3);
22165 : 2738 : _q60 = do_valueize (valueize, _q60);
22166 : 2738 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
22167 : : {
22168 : 0 : {
22169 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
22170 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, NE_EXPR, EQ_EXPR))
22171 : 0 : return true;
22172 : : }
22173 : : }
22174 : 2738 : if ((_q60 == _q21 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q21, 0) && types_match (_q60, _q21)))
22175 : : {
22176 : 0 : {
22177 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
22178 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, NE_EXPR, EQ_EXPR))
22179 : 0 : return true;
22180 : : }
22181 : : }
22182 : : break;
22183 : : }
22184 : : default:;
22185 : : }
22186 : : }
22187 : : break;
22188 : 87268 : default:;
22189 : : }
22190 : 87268 : switch (TREE_CODE (_q51))
22191 : : {
22192 : 2147 : case SSA_NAME:
22193 : 2147 : if (gimple *_d3 = get_def (valueize, _q51))
22194 : : {
22195 : 1890 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
22196 : 1632 : switch (gimple_assign_rhs_code (_a3))
22197 : : {
22198 : 32 : CASE_CONVERT:
22199 : 32 : {
22200 : 32 : tree _q70 = gimple_assign_rhs1 (_a3);
22201 : 32 : _q70 = do_valueize (valueize, _q70);
22202 : 32 : if ((_q70 == _q20 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q20, 0) && types_match (_q70, _q20)))
22203 : : {
22204 : 0 : {
22205 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
22206 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, NE_EXPR, EQ_EXPR))
22207 : 0 : return true;
22208 : : }
22209 : : }
22210 : 32 : if ((_q70 == _q21 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q21, 0) && types_match (_q70, _q21)))
22211 : : {
22212 : 0 : {
22213 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
22214 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, NE_EXPR, EQ_EXPR))
22215 : 0 : return true;
22216 : : }
22217 : : }
22218 : : break;
22219 : : }
22220 : : default:;
22221 : : }
22222 : : }
22223 : : break;
22224 : : default:;
22225 : : }
22226 : 281552 : break;
22227 : : }
22228 : 2594 : case LT_EXPR:
22229 : 2594 : {
22230 : 2594 : tree _q50 = gimple_assign_rhs1 (_a2);
22231 : 2594 : _q50 = do_valueize (valueize, _q50);
22232 : 2594 : tree _q51 = gimple_assign_rhs2 (_a2);
22233 : 2594 : _q51 = do_valueize (valueize, _q51);
22234 : 2594 : switch (TREE_CODE (_q50))
22235 : : {
22236 : 2588 : case SSA_NAME:
22237 : 2588 : if (gimple *_d3 = get_def (valueize, _q50))
22238 : : {
22239 : 2317 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
22240 : 2470 : switch (gimple_assign_rhs_code (_a3))
22241 : : {
22242 : 491 : CASE_CONVERT:
22243 : 491 : {
22244 : 491 : tree _q60 = gimple_assign_rhs1 (_a3);
22245 : 491 : _q60 = do_valueize (valueize, _q60);
22246 : 491 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
22247 : : {
22248 : 0 : {
22249 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
22250 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, LT_EXPR, EQ_EXPR))
22251 : 0 : return true;
22252 : : }
22253 : : }
22254 : 491 : if ((_q60 == _q21 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q21, 0) && types_match (_q60, _q21)))
22255 : : {
22256 : 0 : {
22257 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
22258 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, LT_EXPR, EQ_EXPR))
22259 : 0 : return true;
22260 : : }
22261 : : }
22262 : : break;
22263 : : }
22264 : : default:;
22265 : : }
22266 : : }
22267 : : break;
22268 : 2594 : default:;
22269 : : }
22270 : 2594 : switch (TREE_CODE (_q51))
22271 : : {
22272 : 1930 : case SSA_NAME:
22273 : 1930 : if (gimple *_d3 = get_def (valueize, _q51))
22274 : : {
22275 : 1660 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
22276 : 1076 : switch (gimple_assign_rhs_code (_a3))
22277 : : {
22278 : 374 : CASE_CONVERT:
22279 : 374 : {
22280 : 374 : tree _q70 = gimple_assign_rhs1 (_a3);
22281 : 374 : _q70 = do_valueize (valueize, _q70);
22282 : 374 : if ((_q70 == _q20 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q20, 0) && types_match (_q70, _q20)))
22283 : : {
22284 : 0 : {
22285 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
22286 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, GT_EXPR, EQ_EXPR))
22287 : 0 : return true;
22288 : : }
22289 : : }
22290 : 374 : if ((_q70 == _q21 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q21, 0) && types_match (_q70, _q21)))
22291 : : {
22292 : 0 : {
22293 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
22294 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, GT_EXPR, EQ_EXPR))
22295 : 0 : return true;
22296 : : }
22297 : : }
22298 : : break;
22299 : : }
22300 : : default:;
22301 : : }
22302 : : }
22303 : : break;
22304 : : default:;
22305 : : }
22306 : : break;
22307 : : }
22308 : 6732 : case GT_EXPR:
22309 : 6732 : {
22310 : 6732 : tree _q50 = gimple_assign_rhs1 (_a2);
22311 : 6732 : _q50 = do_valueize (valueize, _q50);
22312 : 6732 : tree _q51 = gimple_assign_rhs2 (_a2);
22313 : 6732 : _q51 = do_valueize (valueize, _q51);
22314 : 6732 : switch (TREE_CODE (_q50))
22315 : : {
22316 : 6732 : case SSA_NAME:
22317 : 6732 : if (gimple *_d3 = get_def (valueize, _q50))
22318 : : {
22319 : 6019 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
22320 : 7017 : switch (gimple_assign_rhs_code (_a3))
22321 : : {
22322 : 417 : CASE_CONVERT:
22323 : 417 : {
22324 : 417 : tree _q60 = gimple_assign_rhs1 (_a3);
22325 : 417 : _q60 = do_valueize (valueize, _q60);
22326 : 417 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
22327 : : {
22328 : 3 : {
22329 : 3 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
22330 : 3 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, GT_EXPR, EQ_EXPR))
22331 : 3 : return true;
22332 : : }
22333 : : }
22334 : 414 : if ((_q60 == _q21 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q21, 0) && types_match (_q60, _q21)))
22335 : : {
22336 : 0 : {
22337 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
22338 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, GT_EXPR, EQ_EXPR))
22339 : 0 : return true;
22340 : : }
22341 : : }
22342 : : break;
22343 : : }
22344 : : default:;
22345 : : }
22346 : : }
22347 : : break;
22348 : 6729 : default:;
22349 : : }
22350 : 6729 : switch (TREE_CODE (_q51))
22351 : : {
22352 : 1957 : case SSA_NAME:
22353 : 1957 : if (gimple *_d3 = get_def (valueize, _q51))
22354 : : {
22355 : 1694 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
22356 : 1674 : switch (gimple_assign_rhs_code (_a3))
22357 : : {
22358 : 0 : CASE_CONVERT:
22359 : 0 : {
22360 : 0 : tree _q70 = gimple_assign_rhs1 (_a3);
22361 : 0 : _q70 = do_valueize (valueize, _q70);
22362 : 0 : if ((_q70 == _q20 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q20, 0) && types_match (_q70, _q20)))
22363 : : {
22364 : 0 : {
22365 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
22366 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, LT_EXPR, EQ_EXPR))
22367 : 0 : return true;
22368 : : }
22369 : : }
22370 : 0 : if ((_q70 == _q21 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q21, 0) && types_match (_q70, _q21)))
22371 : : {
22372 : 0 : {
22373 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
22374 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, LT_EXPR, EQ_EXPR))
22375 : 0 : return true;
22376 : : }
22377 : : }
22378 : : break;
22379 : : }
22380 : : default:;
22381 : : }
22382 : : }
22383 : : break;
22384 : : default:;
22385 : : }
22386 : : break;
22387 : : }
22388 : 5822 : case LE_EXPR:
22389 : 5822 : {
22390 : 5822 : tree _q50 = gimple_assign_rhs1 (_a2);
22391 : 5822 : _q50 = do_valueize (valueize, _q50);
22392 : 5822 : tree _q51 = gimple_assign_rhs2 (_a2);
22393 : 5822 : _q51 = do_valueize (valueize, _q51);
22394 : 5822 : switch (TREE_CODE (_q50))
22395 : : {
22396 : 5820 : case SSA_NAME:
22397 : 5820 : if (gimple *_d3 = get_def (valueize, _q50))
22398 : : {
22399 : 5262 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
22400 : 6841 : switch (gimple_assign_rhs_code (_a3))
22401 : : {
22402 : 520 : CASE_CONVERT:
22403 : 520 : {
22404 : 520 : tree _q60 = gimple_assign_rhs1 (_a3);
22405 : 520 : _q60 = do_valueize (valueize, _q60);
22406 : 520 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
22407 : : {
22408 : 1 : {
22409 : 1 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
22410 : 1 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, LE_EXPR, EQ_EXPR))
22411 : 1 : return true;
22412 : : }
22413 : : }
22414 : 519 : if ((_q60 == _q21 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q21, 0) && types_match (_q60, _q21)))
22415 : : {
22416 : 1 : {
22417 : 1 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
22418 : 1 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, LE_EXPR, EQ_EXPR))
22419 : 1 : return true;
22420 : : }
22421 : : }
22422 : : break;
22423 : : }
22424 : : default:;
22425 : : }
22426 : : }
22427 : : break;
22428 : 5820 : default:;
22429 : : }
22430 : 5820 : switch (TREE_CODE (_q51))
22431 : : {
22432 : 1292 : case SSA_NAME:
22433 : 1292 : if (gimple *_d3 = get_def (valueize, _q51))
22434 : : {
22435 : 1168 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
22436 : 1578 : switch (gimple_assign_rhs_code (_a3))
22437 : : {
22438 : 12 : CASE_CONVERT:
22439 : 12 : {
22440 : 12 : tree _q70 = gimple_assign_rhs1 (_a3);
22441 : 12 : _q70 = do_valueize (valueize, _q70);
22442 : 12 : if ((_q70 == _q20 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q20, 0) && types_match (_q70, _q20)))
22443 : : {
22444 : 0 : {
22445 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
22446 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
22447 : 0 : return true;
22448 : : }
22449 : : }
22450 : 12 : if ((_q70 == _q21 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q21, 0) && types_match (_q70, _q21)))
22451 : : {
22452 : 0 : {
22453 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
22454 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
22455 : 0 : return true;
22456 : : }
22457 : : }
22458 : : break;
22459 : : }
22460 : : default:;
22461 : : }
22462 : : }
22463 : : break;
22464 : : default:;
22465 : : }
22466 : : break;
22467 : : }
22468 : 2463 : case GE_EXPR:
22469 : 2463 : {
22470 : 2463 : tree _q50 = gimple_assign_rhs1 (_a2);
22471 : 2463 : _q50 = do_valueize (valueize, _q50);
22472 : 2463 : tree _q51 = gimple_assign_rhs2 (_a2);
22473 : 2463 : _q51 = do_valueize (valueize, _q51);
22474 : 2463 : switch (TREE_CODE (_q50))
22475 : : {
22476 : 2463 : case SSA_NAME:
22477 : 2463 : if (gimple *_d3 = get_def (valueize, _q50))
22478 : : {
22479 : 2311 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
22480 : 2854 : switch (gimple_assign_rhs_code (_a3))
22481 : : {
22482 : 195 : CASE_CONVERT:
22483 : 195 : {
22484 : 195 : tree _q60 = gimple_assign_rhs1 (_a3);
22485 : 195 : _q60 = do_valueize (valueize, _q60);
22486 : 195 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
22487 : : {
22488 : 2 : {
22489 : 2 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
22490 : 2 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
22491 : 0 : return true;
22492 : : }
22493 : : }
22494 : 195 : if ((_q60 == _q21 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q21, 0) && types_match (_q60, _q21)))
22495 : : {
22496 : 7 : {
22497 : 7 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
22498 : 7 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
22499 : 0 : return true;
22500 : : }
22501 : : }
22502 : : break;
22503 : : }
22504 : : default:;
22505 : : }
22506 : : }
22507 : : break;
22508 : 2463 : default:;
22509 : : }
22510 : 2463 : switch (TREE_CODE (_q51))
22511 : : {
22512 : 620 : case SSA_NAME:
22513 : 620 : if (gimple *_d3 = get_def (valueize, _q51))
22514 : : {
22515 : 589 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
22516 : 435 : switch (gimple_assign_rhs_code (_a3))
22517 : : {
22518 : 6 : CASE_CONVERT:
22519 : 6 : {
22520 : 6 : tree _q70 = gimple_assign_rhs1 (_a3);
22521 : 6 : _q70 = do_valueize (valueize, _q70);
22522 : 6 : if ((_q70 == _q20 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q20, 0) && types_match (_q70, _q20)))
22523 : : {
22524 : 0 : {
22525 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
22526 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, LE_EXPR, EQ_EXPR))
22527 : 0 : return true;
22528 : : }
22529 : : }
22530 : 6 : if ((_q70 == _q21 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q21, 0) && types_match (_q70, _q21)))
22531 : : {
22532 : 0 : {
22533 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
22534 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, LE_EXPR, EQ_EXPR))
22535 : 0 : return true;
22536 : : }
22537 : : }
22538 : : break;
22539 : : }
22540 : : default:;
22541 : : }
22542 : : }
22543 : : break;
22544 : : default:;
22545 : : }
22546 : : break;
22547 : : }
22548 : : default:;
22549 : : }
22550 : : }
22551 : : break;
22552 : 281552 : default:;
22553 : : }
22554 : 281552 : switch (TREE_CODE (_q20))
22555 : : {
22556 : 276759 : case SSA_NAME:
22557 : 276759 : if (gimple *_d2 = get_def (valueize, _q20))
22558 : : {
22559 : 248647 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
22560 : 256916 : switch (gimple_assign_rhs_code (_a2))
22561 : : {
22562 : 16774 : CASE_CONVERT:
22563 : 16774 : {
22564 : 16774 : tree _q30 = gimple_assign_rhs1 (_a2);
22565 : 16774 : _q30 = do_valueize (valueize, _q30);
22566 : 16774 : switch (TREE_CODE (_p1))
22567 : : {
22568 : 16774 : case SSA_NAME:
22569 : 16774 : if (gimple *_d3 = get_def (valueize, _p1))
22570 : : {
22571 : 16765 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
22572 : 16616 : switch (gimple_assign_rhs_code (_a3))
22573 : : {
22574 : 14450 : case EQ_EXPR:
22575 : 14450 : {
22576 : 14450 : tree _q60 = gimple_assign_rhs1 (_a3);
22577 : 14450 : _q60 = do_valueize (valueize, _q60);
22578 : 14450 : tree _q61 = gimple_assign_rhs2 (_a3);
22579 : 14450 : _q61 = do_valueize (valueize, _q61);
22580 : 14450 : if (tree_swap_operands_p (_q60, _q61))
22581 : 42 : std::swap (_q60, _q61);
22582 : 14450 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
22583 : : {
22584 : 0 : {
22585 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q61, _p0, _q20, _q21 };
22586 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, EQ_EXPR, EQ_EXPR))
22587 : 0 : return true;
22588 : : }
22589 : : }
22590 : 14450 : if ((_q61 == _q30 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q30, 0) && types_match (_q61, _q30)))
22591 : : {
22592 : 0 : {
22593 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q60, _p0, _q20, _q21 };
22594 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, EQ_EXPR, EQ_EXPR))
22595 : 0 : return true;
22596 : : }
22597 : : }
22598 : 281552 : break;
22599 : : }
22600 : 926 : case NE_EXPR:
22601 : 926 : {
22602 : 926 : tree _q60 = gimple_assign_rhs1 (_a3);
22603 : 926 : _q60 = do_valueize (valueize, _q60);
22604 : 926 : tree _q61 = gimple_assign_rhs2 (_a3);
22605 : 926 : _q61 = do_valueize (valueize, _q61);
22606 : 926 : if (tree_swap_operands_p (_q60, _q61))
22607 : 0 : std::swap (_q60, _q61);
22608 : 926 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
22609 : : {
22610 : 67 : {
22611 : 67 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q61, _p0, _q20, _q21 };
22612 : 67 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, EQ_EXPR, NE_EXPR))
22613 : 0 : return true;
22614 : : }
22615 : : }
22616 : 926 : if ((_q61 == _q30 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q30, 0) && types_match (_q61, _q30)))
22617 : : {
22618 : 0 : {
22619 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q60, _p0, _q20, _q21 };
22620 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, EQ_EXPR, NE_EXPR))
22621 : 0 : return true;
22622 : : }
22623 : : }
22624 : 281552 : break;
22625 : : }
22626 : : default:;
22627 : : }
22628 : : }
22629 : : break;
22630 : : default:;
22631 : : }
22632 : : break;
22633 : : }
22634 : : default:;
22635 : : }
22636 : : }
22637 : : break;
22638 : 281552 : default:;
22639 : : }
22640 : 281552 : switch (TREE_CODE (_q21))
22641 : : {
22642 : 90672 : case SSA_NAME:
22643 : 90672 : if (gimple *_d2 = get_def (valueize, _q21))
22644 : : {
22645 : 84803 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
22646 : 120717 : switch (gimple_assign_rhs_code (_a2))
22647 : : {
22648 : 5880 : CASE_CONVERT:
22649 : 5880 : {
22650 : 5880 : tree _q40 = gimple_assign_rhs1 (_a2);
22651 : 5880 : _q40 = do_valueize (valueize, _q40);
22652 : 5880 : switch (TREE_CODE (_p1))
22653 : : {
22654 : 5880 : case SSA_NAME:
22655 : 5880 : if (gimple *_d3 = get_def (valueize, _p1))
22656 : : {
22657 : 5870 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
22658 : 5850 : switch (gimple_assign_rhs_code (_a3))
22659 : : {
22660 : 5209 : case EQ_EXPR:
22661 : 5209 : {
22662 : 5209 : tree _q60 = gimple_assign_rhs1 (_a3);
22663 : 5209 : _q60 = do_valueize (valueize, _q60);
22664 : 5209 : tree _q61 = gimple_assign_rhs2 (_a3);
22665 : 5209 : _q61 = do_valueize (valueize, _q61);
22666 : 5209 : if (tree_swap_operands_p (_q60, _q61))
22667 : 5 : std::swap (_q60, _q61);
22668 : 5209 : if ((_q60 == _q40 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q40, 0) && types_match (_q60, _q40)))
22669 : : {
22670 : 0 : {
22671 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q61, _p0, _q21, _q20 };
22672 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, EQ_EXPR, EQ_EXPR))
22673 : 0 : return true;
22674 : : }
22675 : : }
22676 : 5209 : if ((_q61 == _q40 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q40, 0) && types_match (_q61, _q40)))
22677 : : {
22678 : 0 : {
22679 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q60, _p0, _q21, _q20 };
22680 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, EQ_EXPR, EQ_EXPR))
22681 : 0 : return true;
22682 : : }
22683 : : }
22684 : 281552 : break;
22685 : : }
22686 : 86 : case NE_EXPR:
22687 : 86 : {
22688 : 86 : tree _q60 = gimple_assign_rhs1 (_a3);
22689 : 86 : _q60 = do_valueize (valueize, _q60);
22690 : 86 : tree _q61 = gimple_assign_rhs2 (_a3);
22691 : 86 : _q61 = do_valueize (valueize, _q61);
22692 : 86 : if (tree_swap_operands_p (_q60, _q61))
22693 : 0 : std::swap (_q60, _q61);
22694 : 86 : if ((_q60 == _q40 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q40, 0) && types_match (_q60, _q40)))
22695 : : {
22696 : 16 : {
22697 : 16 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q61, _p0, _q21, _q20 };
22698 : 16 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, EQ_EXPR, NE_EXPR))
22699 : 0 : return true;
22700 : : }
22701 : : }
22702 : 86 : if ((_q61 == _q40 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q40, 0) && types_match (_q61, _q40)))
22703 : : {
22704 : 0 : {
22705 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q60, _p0, _q21, _q20 };
22706 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, EQ_EXPR, NE_EXPR))
22707 : 0 : return true;
22708 : : }
22709 : : }
22710 : 281552 : break;
22711 : : }
22712 : : default:;
22713 : : }
22714 : : }
22715 : : break;
22716 : : default:;
22717 : : }
22718 : : break;
22719 : : }
22720 : : default:;
22721 : : }
22722 : : }
22723 : : break;
22724 : 281552 : default:;
22725 : : }
22726 : 281552 : switch (TREE_CODE (_p1))
22727 : : {
22728 : 281472 : case SSA_NAME:
22729 : 281472 : if (gimple *_d2 = get_def (valueize, _p1))
22730 : : {
22731 : 279838 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
22732 : 277024 : switch (gimple_assign_rhs_code (_a2))
22733 : : {
22734 : 153290 : case EQ_EXPR:
22735 : 153290 : {
22736 : 153290 : tree _q50 = gimple_assign_rhs1 (_a2);
22737 : 153290 : _q50 = do_valueize (valueize, _q50);
22738 : 153290 : tree _q51 = gimple_assign_rhs2 (_a2);
22739 : 153290 : _q51 = do_valueize (valueize, _q51);
22740 : 153290 : if (tree_swap_operands_p (_q50, _q51))
22741 : 1346 : std::swap (_q50, _q51);
22742 : 153290 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
22743 : : {
22744 : 2158 : {
22745 : 2158 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
22746 : 2158 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, EQ_EXPR, EQ_EXPR))
22747 : 2 : return true;
22748 : : }
22749 : 2156 : {
22750 : 2156 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q51, _p0, _q20, _q21 };
22751 : 2156 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, EQ_EXPR, EQ_EXPR))
22752 : 0 : return true;
22753 : : }
22754 : : }
22755 : 153288 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
22756 : : {
22757 : 50 : {
22758 : 50 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
22759 : 50 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, EQ_EXPR, EQ_EXPR))
22760 : 0 : return true;
22761 : : }
22762 : : }
22763 : 153288 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
22764 : : {
22765 : 78 : {
22766 : 78 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
22767 : 78 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, EQ_EXPR, EQ_EXPR))
22768 : 0 : return true;
22769 : : }
22770 : 78 : {
22771 : 78 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q51, _p0, _q21, _q20 };
22772 : 78 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, EQ_EXPR, EQ_EXPR))
22773 : 0 : return true;
22774 : : }
22775 : : }
22776 : 153288 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
22777 : : {
22778 : 25893 : {
22779 : 25893 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
22780 : 25893 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, EQ_EXPR, EQ_EXPR))
22781 : 0 : return true;
22782 : : }
22783 : 25893 : {
22784 : 25893 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q50, _p0, _q21, _q20 };
22785 : 25893 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, EQ_EXPR, EQ_EXPR))
22786 : 0 : return true;
22787 : : }
22788 : : }
22789 : 153288 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
22790 : : {
22791 : 50 : {
22792 : 50 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q50, _p0, _q20, _q21 };
22793 : 50 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, EQ_EXPR, EQ_EXPR))
22794 : 0 : return true;
22795 : : }
22796 : : }
22797 : 7738466 : break;
22798 : : }
22799 : 87268 : case NE_EXPR:
22800 : 87268 : {
22801 : 87268 : tree _q50 = gimple_assign_rhs1 (_a2);
22802 : 87268 : _q50 = do_valueize (valueize, _q50);
22803 : 87268 : tree _q51 = gimple_assign_rhs2 (_a2);
22804 : 87268 : _q51 = do_valueize (valueize, _q51);
22805 : 87268 : if (tree_swap_operands_p (_q50, _q51))
22806 : 49 : std::swap (_q50, _q51);
22807 : 87268 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
22808 : : {
22809 : 865 : {
22810 : 865 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
22811 : 865 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, NE_EXPR, EQ_EXPR))
22812 : 184 : return true;
22813 : : }
22814 : 681 : {
22815 : 681 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q51, _p0, _q20, _q21 };
22816 : 681 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, EQ_EXPR, NE_EXPR))
22817 : 0 : return true;
22818 : : }
22819 : : }
22820 : 87084 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
22821 : : {
22822 : 22 : {
22823 : 22 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
22824 : 22 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, NE_EXPR, EQ_EXPR))
22825 : 0 : return true;
22826 : : }
22827 : : }
22828 : 87084 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
22829 : : {
22830 : 847 : {
22831 : 847 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
22832 : 847 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, NE_EXPR, EQ_EXPR))
22833 : 0 : return true;
22834 : : }
22835 : 847 : {
22836 : 847 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q51, _p0, _q21, _q20 };
22837 : 847 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, EQ_EXPR, NE_EXPR))
22838 : 0 : return true;
22839 : : }
22840 : : }
22841 : 87084 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
22842 : : {
22843 : 25139 : {
22844 : 25139 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
22845 : 25139 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, NE_EXPR, EQ_EXPR))
22846 : 0 : return true;
22847 : : }
22848 : 25139 : {
22849 : 25139 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q50, _p0, _q21, _q20 };
22850 : 25139 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, EQ_EXPR, NE_EXPR))
22851 : 0 : return true;
22852 : : }
22853 : : }
22854 : 87084 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
22855 : : {
22856 : 22 : {
22857 : 22 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q50, _p0, _q20, _q21 };
22858 : 22 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, EQ_EXPR, NE_EXPR))
22859 : 0 : return true;
22860 : : }
22861 : : }
22862 : 7738466 : break;
22863 : : }
22864 : 2594 : case LT_EXPR:
22865 : 2594 : {
22866 : 2594 : tree _q50 = gimple_assign_rhs1 (_a2);
22867 : 2594 : _q50 = do_valueize (valueize, _q50);
22868 : 2594 : tree _q51 = gimple_assign_rhs2 (_a2);
22869 : 2594 : _q51 = do_valueize (valueize, _q51);
22870 : 2594 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
22871 : : {
22872 : 5 : {
22873 : 5 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
22874 : 5 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, LT_EXPR, EQ_EXPR))
22875 : 5 : return true;
22876 : : }
22877 : : }
22878 : 2589 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
22879 : : {
22880 : 92 : {
22881 : 92 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
22882 : 92 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, GT_EXPR, EQ_EXPR))
22883 : 0 : return true;
22884 : : }
22885 : : }
22886 : 2589 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
22887 : : {
22888 : 26 : {
22889 : 26 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
22890 : 26 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, LT_EXPR, EQ_EXPR))
22891 : 0 : return true;
22892 : : }
22893 : : }
22894 : 2589 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
22895 : : {
22896 : 1 : {
22897 : 1 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
22898 : 1 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, GT_EXPR, EQ_EXPR))
22899 : 0 : return true;
22900 : : }
22901 : : }
22902 : : break;
22903 : : }
22904 : 6729 : case GT_EXPR:
22905 : 6729 : {
22906 : 6729 : tree _q50 = gimple_assign_rhs1 (_a2);
22907 : 6729 : _q50 = do_valueize (valueize, _q50);
22908 : 6729 : tree _q51 = gimple_assign_rhs2 (_a2);
22909 : 6729 : _q51 = do_valueize (valueize, _q51);
22910 : 6729 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
22911 : : {
22912 : 133 : {
22913 : 133 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
22914 : 133 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, GT_EXPR, EQ_EXPR))
22915 : 34 : return true;
22916 : : }
22917 : : }
22918 : 6695 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
22919 : : {
22920 : 0 : {
22921 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
22922 : 0 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, LT_EXPR, EQ_EXPR))
22923 : 0 : return true;
22924 : : }
22925 : : }
22926 : 6695 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
22927 : : {
22928 : 24 : {
22929 : 24 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
22930 : 24 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, GT_EXPR, EQ_EXPR))
22931 : 0 : return true;
22932 : : }
22933 : : }
22934 : 6695 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
22935 : : {
22936 : 451 : {
22937 : 451 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
22938 : 451 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, LT_EXPR, EQ_EXPR))
22939 : 0 : return true;
22940 : : }
22941 : : }
22942 : : break;
22943 : : }
22944 : 5820 : case LE_EXPR:
22945 : 5820 : {
22946 : 5820 : tree _q50 = gimple_assign_rhs1 (_a2);
22947 : 5820 : _q50 = do_valueize (valueize, _q50);
22948 : 5820 : tree _q51 = gimple_assign_rhs2 (_a2);
22949 : 5820 : _q51 = do_valueize (valueize, _q51);
22950 : 5820 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
22951 : : {
22952 : 21 : {
22953 : 21 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
22954 : 21 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, LE_EXPR, EQ_EXPR))
22955 : 15 : return true;
22956 : : }
22957 : : }
22958 : 5805 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
22959 : : {
22960 : 5 : {
22961 : 5 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
22962 : 5 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
22963 : 0 : return true;
22964 : : }
22965 : : }
22966 : 5805 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
22967 : : {
22968 : 14 : {
22969 : 14 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
22970 : 14 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, LE_EXPR, EQ_EXPR))
22971 : 0 : return true;
22972 : : }
22973 : : }
22974 : 5805 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
22975 : : {
22976 : 124 : {
22977 : 124 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
22978 : 124 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
22979 : 0 : return true;
22980 : : }
22981 : : }
22982 : : break;
22983 : : }
22984 : 2463 : case GE_EXPR:
22985 : 2463 : {
22986 : 2463 : tree _q50 = gimple_assign_rhs1 (_a2);
22987 : 2463 : _q50 = do_valueize (valueize, _q50);
22988 : 2463 : tree _q51 = gimple_assign_rhs2 (_a2);
22989 : 2463 : _q51 = do_valueize (valueize, _q51);
22990 : 2463 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
22991 : : {
22992 : 19 : {
22993 : 19 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
22994 : 19 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
22995 : 11 : return true;
22996 : : }
22997 : : }
22998 : 2452 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
22999 : : {
23000 : 33 : {
23001 : 33 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
23002 : 33 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, LE_EXPR, EQ_EXPR))
23003 : 0 : return true;
23004 : : }
23005 : : }
23006 : 2452 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
23007 : : {
23008 : 31 : {
23009 : 31 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
23010 : 31 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
23011 : 0 : return true;
23012 : : }
23013 : : }
23014 : 2452 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
23015 : : {
23016 : 115 : {
23017 : 115 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
23018 : 115 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, LE_EXPR, EQ_EXPR))
23019 : 0 : return true;
23020 : : }
23021 : : }
23022 : : break;
23023 : : }
23024 : : default:;
23025 : : }
23026 : : }
23027 : : break;
23028 : : default:;
23029 : : }
23030 : 7738466 : break;
23031 : : }
23032 : 250164 : case NE_EXPR:
23033 : 250164 : {
23034 : 250164 : tree _q20 = gimple_assign_rhs1 (_a1);
23035 : 250164 : _q20 = do_valueize (valueize, _q20);
23036 : 250164 : tree _q21 = gimple_assign_rhs2 (_a1);
23037 : 250164 : _q21 = do_valueize (valueize, _q21);
23038 : 250164 : if (tree_swap_operands_p (_q20, _q21))
23039 : 1085 : std::swap (_q20, _q21);
23040 : 250164 : if (gimple_min_value (_q21, valueize))
23041 : : {
23042 : 107829 : switch (TREE_CODE (_p1))
23043 : : {
23044 : 107821 : case SSA_NAME:
23045 : 107821 : if (gimple *_d2 = get_def (valueize, _p1))
23046 : : {
23047 : 106633 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
23048 : 103821 : switch (gimple_assign_rhs_code (_a2))
23049 : : {
23050 : 3164 : case GT_EXPR:
23051 : 3164 : {
23052 : 3164 : tree _q50 = gimple_assign_rhs1 (_a2);
23053 : 3164 : _q50 = do_valueize (valueize, _q50);
23054 : 3164 : tree _q51 = gimple_assign_rhs2 (_a2);
23055 : 3164 : _q51 = do_valueize (valueize, _q51);
23056 : 3164 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
23057 : : {
23058 : 4 : {
23059 : 4 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _q20, _q51 };
23060 : 4 : if (gimple_simplify_446 (res_op, seq, valueize, type, captures, NE_EXPR))
23061 : 4 : return true;
23062 : : }
23063 : : }
23064 : : break;
23065 : : }
23066 : 2687 : case LT_EXPR:
23067 : 2687 : {
23068 : 2687 : tree _q50 = gimple_assign_rhs1 (_a2);
23069 : 2687 : _q50 = do_valueize (valueize, _q50);
23070 : 2687 : tree _q51 = gimple_assign_rhs2 (_a2);
23071 : 2687 : _q51 = do_valueize (valueize, _q51);
23072 : 2687 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
23073 : : {
23074 : 8 : {
23075 : 8 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _q20, _q50 };
23076 : 8 : if (gimple_simplify_446 (res_op, seq, valueize, type, captures, NE_EXPR))
23077 : 8 : return true;
23078 : : }
23079 : : }
23080 : : break;
23081 : : }
23082 : 5034 : case GE_EXPR:
23083 : 5034 : {
23084 : 5034 : tree _q50 = gimple_assign_rhs1 (_a2);
23085 : 5034 : _q50 = do_valueize (valueize, _q50);
23086 : 5034 : tree _q51 = gimple_assign_rhs2 (_a2);
23087 : 5034 : _q51 = do_valueize (valueize, _q51);
23088 : 5034 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
23089 : : {
23090 : 1409 : {
23091 : 1409 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _p1, _q50 };
23092 : 1409 : if (gimple_simplify_452 (res_op, seq, valueize, type, captures))
23093 : 209 : return true;
23094 : : }
23095 : : }
23096 : : break;
23097 : : }
23098 : 1623 : case LE_EXPR:
23099 : 1623 : {
23100 : 1623 : tree _q50 = gimple_assign_rhs1 (_a2);
23101 : 1623 : _q50 = do_valueize (valueize, _q50);
23102 : 1623 : tree _q51 = gimple_assign_rhs2 (_a2);
23103 : 1623 : _q51 = do_valueize (valueize, _q51);
23104 : 1623 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
23105 : : {
23106 : 410 : {
23107 : 410 : tree captures[4] ATTRIBUTE_UNUSED = { _p0, _q20, _p1, _q51 };
23108 : 410 : if (gimple_simplify_452 (res_op, seq, valueize, type, captures))
23109 : 198 : return true;
23110 : : }
23111 : : }
23112 : : break;
23113 : : }
23114 : : default:;
23115 : : }
23116 : : }
23117 : : break;
23118 : : default:;
23119 : : }
23120 : : }
23121 : 249745 : if (gimple_max_value (_q21, valueize))
23122 : : {
23123 : 2636 : switch (TREE_CODE (_p1))
23124 : : {
23125 : 2636 : case SSA_NAME:
23126 : 2636 : if (gimple *_d2 = get_def (valueize, _p1))
23127 : : {
23128 : 2634 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
23129 : 2614 : switch (gimple_assign_rhs_code (_a2))
23130 : : {
23131 : 4 : case LT_EXPR:
23132 : 4 : {
23133 : 4 : tree _q50 = gimple_assign_rhs1 (_a2);
23134 : 4 : _q50 = do_valueize (valueize, _q50);
23135 : 4 : tree _q51 = gimple_assign_rhs2 (_a2);
23136 : 4 : _q51 = do_valueize (valueize, _q51);
23137 : 4 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
23138 : : {
23139 : 0 : {
23140 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _q20, _q51 };
23141 : 0 : if (gimple_simplify_448 (res_op, seq, valueize, type, captures, NE_EXPR))
23142 : 0 : return true;
23143 : : }
23144 : : }
23145 : : break;
23146 : : }
23147 : 407 : case GT_EXPR:
23148 : 407 : {
23149 : 407 : tree _q50 = gimple_assign_rhs1 (_a2);
23150 : 407 : _q50 = do_valueize (valueize, _q50);
23151 : 407 : tree _q51 = gimple_assign_rhs2 (_a2);
23152 : 407 : _q51 = do_valueize (valueize, _q51);
23153 : 407 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
23154 : : {
23155 : 0 : {
23156 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _q20, _q50 };
23157 : 0 : if (gimple_simplify_448 (res_op, seq, valueize, type, captures, NE_EXPR))
23158 : 0 : return true;
23159 : : }
23160 : : }
23161 : : break;
23162 : : }
23163 : : default:;
23164 : : }
23165 : : }
23166 : : break;
23167 : : default:;
23168 : : }
23169 : : }
23170 : 249745 : switch (TREE_CODE (_p1))
23171 : : {
23172 : 249617 : case SSA_NAME:
23173 : 249617 : if (gimple *_d2 = get_def (valueize, _p1))
23174 : : {
23175 : 246633 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
23176 : 240439 : switch (gimple_assign_rhs_code (_a2))
23177 : : {
23178 : 51392 : case EQ_EXPR:
23179 : 51392 : {
23180 : 51392 : tree _q50 = gimple_assign_rhs1 (_a2);
23181 : 51392 : _q50 = do_valueize (valueize, _q50);
23182 : 51392 : tree _q51 = gimple_assign_rhs2 (_a2);
23183 : 51392 : _q51 = do_valueize (valueize, _q51);
23184 : 51392 : if (tree_swap_operands_p (_q50, _q51))
23185 : 248 : std::swap (_q50, _q51);
23186 : 51392 : switch (TREE_CODE (_q50))
23187 : : {
23188 : 50772 : case SSA_NAME:
23189 : 50772 : if (gimple *_d3 = get_def (valueize, _q50))
23190 : : {
23191 : 48497 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
23192 : 44751 : switch (gimple_assign_rhs_code (_a3))
23193 : : {
23194 : 824 : CASE_CONVERT:
23195 : 824 : {
23196 : 824 : tree _q60 = gimple_assign_rhs1 (_a3);
23197 : 824 : _q60 = do_valueize (valueize, _q60);
23198 : 824 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
23199 : : {
23200 : 54 : {
23201 : 54 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
23202 : 54 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, EQ_EXPR, NE_EXPR))
23203 : 0 : return true;
23204 : : }
23205 : : }
23206 : 824 : if ((_q60 == _q21 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q21, 0) && types_match (_q60, _q21)))
23207 : : {
23208 : 0 : {
23209 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
23210 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, EQ_EXPR, NE_EXPR))
23211 : 0 : return true;
23212 : : }
23213 : : }
23214 : : break;
23215 : : }
23216 : : default:;
23217 : : }
23218 : : }
23219 : : break;
23220 : 51392 : default:;
23221 : : }
23222 : 51392 : switch (TREE_CODE (_q51))
23223 : : {
23224 : 9590 : case SSA_NAME:
23225 : 9590 : if (gimple *_d3 = get_def (valueize, _q51))
23226 : : {
23227 : 8627 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
23228 : 3228 : switch (gimple_assign_rhs_code (_a3))
23229 : : {
23230 : 239 : CASE_CONVERT:
23231 : 239 : {
23232 : 239 : tree _q70 = gimple_assign_rhs1 (_a3);
23233 : 239 : _q70 = do_valueize (valueize, _q70);
23234 : 239 : if ((_q70 == _q20 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q20, 0) && types_match (_q70, _q20)))
23235 : : {
23236 : 0 : {
23237 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
23238 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, EQ_EXPR, NE_EXPR))
23239 : 0 : return true;
23240 : : }
23241 : : }
23242 : 239 : if ((_q70 == _q21 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q21, 0) && types_match (_q70, _q21)))
23243 : : {
23244 : 0 : {
23245 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
23246 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, EQ_EXPR, NE_EXPR))
23247 : 0 : return true;
23248 : : }
23249 : : }
23250 : : break;
23251 : : }
23252 : : default:;
23253 : : }
23254 : : }
23255 : : break;
23256 : : default:;
23257 : : }
23258 : 249683 : break;
23259 : : }
23260 : 150866 : case NE_EXPR:
23261 : 150866 : {
23262 : 150866 : tree _q50 = gimple_assign_rhs1 (_a2);
23263 : 150866 : _q50 = do_valueize (valueize, _q50);
23264 : 150866 : tree _q51 = gimple_assign_rhs2 (_a2);
23265 : 150866 : _q51 = do_valueize (valueize, _q51);
23266 : 150866 : if (tree_swap_operands_p (_q50, _q51))
23267 : 1103 : std::swap (_q50, _q51);
23268 : 150866 : switch (TREE_CODE (_q50))
23269 : : {
23270 : 146686 : case SSA_NAME:
23271 : 146686 : if (gimple *_d3 = get_def (valueize, _q50))
23272 : : {
23273 : 131897 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
23274 : 117848 : switch (gimple_assign_rhs_code (_a3))
23275 : : {
23276 : 2129 : CASE_CONVERT:
23277 : 2129 : {
23278 : 2129 : tree _q60 = gimple_assign_rhs1 (_a3);
23279 : 2129 : _q60 = do_valueize (valueize, _q60);
23280 : 2129 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
23281 : : {
23282 : 6 : {
23283 : 6 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
23284 : 6 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, NE_EXPR, NE_EXPR))
23285 : 0 : return true;
23286 : : }
23287 : : }
23288 : 2129 : if ((_q60 == _q21 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q21, 0) && types_match (_q60, _q21)))
23289 : : {
23290 : 0 : {
23291 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
23292 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, NE_EXPR, NE_EXPR))
23293 : 0 : return true;
23294 : : }
23295 : : }
23296 : : break;
23297 : : }
23298 : : default:;
23299 : : }
23300 : : }
23301 : : break;
23302 : 150866 : default:;
23303 : : }
23304 : 150866 : switch (TREE_CODE (_q51))
23305 : : {
23306 : 27673 : case SSA_NAME:
23307 : 27673 : if (gimple *_d3 = get_def (valueize, _q51))
23308 : : {
23309 : 23610 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
23310 : 12612 : switch (gimple_assign_rhs_code (_a3))
23311 : : {
23312 : 112 : CASE_CONVERT:
23313 : 112 : {
23314 : 112 : tree _q70 = gimple_assign_rhs1 (_a3);
23315 : 112 : _q70 = do_valueize (valueize, _q70);
23316 : 112 : if ((_q70 == _q20 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q20, 0) && types_match (_q70, _q20)))
23317 : : {
23318 : 0 : {
23319 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
23320 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, NE_EXPR, NE_EXPR))
23321 : 0 : return true;
23322 : : }
23323 : : }
23324 : 112 : if ((_q70 == _q21 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q21, 0) && types_match (_q70, _q21)))
23325 : : {
23326 : 0 : {
23327 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
23328 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, NE_EXPR, NE_EXPR))
23329 : 0 : return true;
23330 : : }
23331 : : }
23332 : : break;
23333 : : }
23334 : : default:;
23335 : : }
23336 : : }
23337 : : break;
23338 : : default:;
23339 : : }
23340 : 249683 : break;
23341 : : }
23342 : 8557 : case LT_EXPR:
23343 : 8557 : {
23344 : 8557 : tree _q50 = gimple_assign_rhs1 (_a2);
23345 : 8557 : _q50 = do_valueize (valueize, _q50);
23346 : 8557 : tree _q51 = gimple_assign_rhs2 (_a2);
23347 : 8557 : _q51 = do_valueize (valueize, _q51);
23348 : 8557 : switch (TREE_CODE (_q50))
23349 : : {
23350 : 8433 : case SSA_NAME:
23351 : 8433 : if (gimple *_d3 = get_def (valueize, _q50))
23352 : : {
23353 : 6772 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
23354 : 8484 : switch (gimple_assign_rhs_code (_a3))
23355 : : {
23356 : 906 : CASE_CONVERT:
23357 : 906 : {
23358 : 906 : tree _q60 = gimple_assign_rhs1 (_a3);
23359 : 906 : _q60 = do_valueize (valueize, _q60);
23360 : 906 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
23361 : : {
23362 : 0 : {
23363 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
23364 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, LT_EXPR, NE_EXPR))
23365 : 0 : return true;
23366 : : }
23367 : : }
23368 : 906 : if ((_q60 == _q21 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q21, 0) && types_match (_q60, _q21)))
23369 : : {
23370 : 0 : {
23371 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
23372 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, LT_EXPR, NE_EXPR))
23373 : 0 : return true;
23374 : : }
23375 : : }
23376 : : break;
23377 : : }
23378 : : default:;
23379 : : }
23380 : : }
23381 : : break;
23382 : 8557 : default:;
23383 : : }
23384 : 8557 : switch (TREE_CODE (_q51))
23385 : : {
23386 : 7809 : case SSA_NAME:
23387 : 7809 : if (gimple *_d3 = get_def (valueize, _q51))
23388 : : {
23389 : 6885 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
23390 : 8803 : switch (gimple_assign_rhs_code (_a3))
23391 : : {
23392 : 117 : CASE_CONVERT:
23393 : 117 : {
23394 : 117 : tree _q70 = gimple_assign_rhs1 (_a3);
23395 : 117 : _q70 = do_valueize (valueize, _q70);
23396 : 117 : if ((_q70 == _q20 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q20, 0) && types_match (_q70, _q20)))
23397 : : {
23398 : 10 : {
23399 : 10 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
23400 : 10 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, GT_EXPR, NE_EXPR))
23401 : 0 : return true;
23402 : : }
23403 : : }
23404 : 117 : if ((_q70 == _q21 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q21, 0) && types_match (_q70, _q21)))
23405 : : {
23406 : 0 : {
23407 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
23408 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, GT_EXPR, NE_EXPR))
23409 : 0 : return true;
23410 : : }
23411 : : }
23412 : : break;
23413 : : }
23414 : : default:;
23415 : : }
23416 : : }
23417 : : break;
23418 : : default:;
23419 : : }
23420 : : break;
23421 : : }
23422 : 10336 : case GT_EXPR:
23423 : 10336 : {
23424 : 10336 : tree _q50 = gimple_assign_rhs1 (_a2);
23425 : 10336 : _q50 = do_valueize (valueize, _q50);
23426 : 10336 : tree _q51 = gimple_assign_rhs2 (_a2);
23427 : 10336 : _q51 = do_valueize (valueize, _q51);
23428 : 10336 : switch (TREE_CODE (_q50))
23429 : : {
23430 : 10328 : case SSA_NAME:
23431 : 10328 : if (gimple *_d3 = get_def (valueize, _q50))
23432 : : {
23433 : 9251 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
23434 : 7629 : switch (gimple_assign_rhs_code (_a3))
23435 : : {
23436 : 746 : CASE_CONVERT:
23437 : 746 : {
23438 : 746 : tree _q60 = gimple_assign_rhs1 (_a3);
23439 : 746 : _q60 = do_valueize (valueize, _q60);
23440 : 746 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
23441 : : {
23442 : 55 : {
23443 : 55 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
23444 : 55 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, GT_EXPR, NE_EXPR))
23445 : 46 : return true;
23446 : : }
23447 : : }
23448 : 700 : if ((_q60 == _q21 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q21, 0) && types_match (_q60, _q21)))
23449 : : {
23450 : 0 : {
23451 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
23452 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, GT_EXPR, NE_EXPR))
23453 : 0 : return true;
23454 : : }
23455 : : }
23456 : : break;
23457 : : }
23458 : : default:;
23459 : : }
23460 : : }
23461 : : break;
23462 : 10290 : default:;
23463 : : }
23464 : 10290 : switch (TREE_CODE (_q51))
23465 : : {
23466 : 3906 : case SSA_NAME:
23467 : 3906 : if (gimple *_d3 = get_def (valueize, _q51))
23468 : : {
23469 : 3187 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
23470 : 3110 : switch (gimple_assign_rhs_code (_a3))
23471 : : {
23472 : 251 : CASE_CONVERT:
23473 : 251 : {
23474 : 251 : tree _q70 = gimple_assign_rhs1 (_a3);
23475 : 251 : _q70 = do_valueize (valueize, _q70);
23476 : 251 : if ((_q70 == _q20 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q20, 0) && types_match (_q70, _q20)))
23477 : : {
23478 : 0 : {
23479 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
23480 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, LT_EXPR, NE_EXPR))
23481 : 0 : return true;
23482 : : }
23483 : : }
23484 : 251 : if ((_q70 == _q21 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q21, 0) && types_match (_q70, _q21)))
23485 : : {
23486 : 0 : {
23487 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
23488 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, LT_EXPR, NE_EXPR))
23489 : 0 : return true;
23490 : : }
23491 : : }
23492 : : break;
23493 : : }
23494 : : default:;
23495 : : }
23496 : : }
23497 : : break;
23498 : : default:;
23499 : : }
23500 : : break;
23501 : : }
23502 : 4517 : case LE_EXPR:
23503 : 4517 : {
23504 : 4517 : tree _q50 = gimple_assign_rhs1 (_a2);
23505 : 4517 : _q50 = do_valueize (valueize, _q50);
23506 : 4517 : tree _q51 = gimple_assign_rhs2 (_a2);
23507 : 4517 : _q51 = do_valueize (valueize, _q51);
23508 : 4517 : switch (TREE_CODE (_q50))
23509 : : {
23510 : 4517 : case SSA_NAME:
23511 : 4517 : if (gimple *_d3 = get_def (valueize, _q50))
23512 : : {
23513 : 4120 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
23514 : 4185 : switch (gimple_assign_rhs_code (_a3))
23515 : : {
23516 : 169 : CASE_CONVERT:
23517 : 169 : {
23518 : 169 : tree _q60 = gimple_assign_rhs1 (_a3);
23519 : 169 : _q60 = do_valueize (valueize, _q60);
23520 : 169 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
23521 : : {
23522 : 6 : {
23523 : 6 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
23524 : 6 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, LE_EXPR, NE_EXPR))
23525 : 0 : return true;
23526 : : }
23527 : : }
23528 : 169 : if ((_q60 == _q21 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q21, 0) && types_match (_q60, _q21)))
23529 : : {
23530 : 0 : {
23531 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
23532 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, LE_EXPR, NE_EXPR))
23533 : 0 : return true;
23534 : : }
23535 : : }
23536 : : break;
23537 : : }
23538 : : default:;
23539 : : }
23540 : : }
23541 : : break;
23542 : 4517 : default:;
23543 : : }
23544 : 4517 : switch (TREE_CODE (_q51))
23545 : : {
23546 : 1098 : case SSA_NAME:
23547 : 1098 : if (gimple *_d3 = get_def (valueize, _q51))
23548 : : {
23549 : 941 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
23550 : 934 : switch (gimple_assign_rhs_code (_a3))
23551 : : {
23552 : 4 : CASE_CONVERT:
23553 : 4 : {
23554 : 4 : tree _q70 = gimple_assign_rhs1 (_a3);
23555 : 4 : _q70 = do_valueize (valueize, _q70);
23556 : 4 : if ((_q70 == _q20 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q20, 0) && types_match (_q70, _q20)))
23557 : : {
23558 : 0 : {
23559 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
23560 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, GE_EXPR, NE_EXPR))
23561 : 0 : return true;
23562 : : }
23563 : : }
23564 : 4 : if ((_q70 == _q21 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q21, 0) && types_match (_q70, _q21)))
23565 : : {
23566 : 0 : {
23567 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
23568 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, GE_EXPR, NE_EXPR))
23569 : 0 : return true;
23570 : : }
23571 : : }
23572 : : break;
23573 : : }
23574 : : default:;
23575 : : }
23576 : : }
23577 : : break;
23578 : : default:;
23579 : : }
23580 : : break;
23581 : : }
23582 : 5977 : case GE_EXPR:
23583 : 5977 : {
23584 : 5977 : tree _q50 = gimple_assign_rhs1 (_a2);
23585 : 5977 : _q50 = do_valueize (valueize, _q50);
23586 : 5977 : tree _q51 = gimple_assign_rhs2 (_a2);
23587 : 5977 : _q51 = do_valueize (valueize, _q51);
23588 : 5977 : switch (TREE_CODE (_q50))
23589 : : {
23590 : 5977 : case SSA_NAME:
23591 : 5977 : if (gimple *_d3 = get_def (valueize, _q50))
23592 : : {
23593 : 5448 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
23594 : 2179 : switch (gimple_assign_rhs_code (_a3))
23595 : : {
23596 : 705 : CASE_CONVERT:
23597 : 705 : {
23598 : 705 : tree _q60 = gimple_assign_rhs1 (_a3);
23599 : 705 : _q60 = do_valueize (valueize, _q60);
23600 : 705 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
23601 : : {
23602 : 16 : {
23603 : 16 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
23604 : 16 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, GE_EXPR, NE_EXPR))
23605 : 16 : return true;
23606 : : }
23607 : : }
23608 : 689 : if ((_q60 == _q21 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q21, 0) && types_match (_q60, _q21)))
23609 : : {
23610 : 0 : {
23611 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
23612 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, GE_EXPR, NE_EXPR))
23613 : 0 : return true;
23614 : : }
23615 : : }
23616 : : break;
23617 : : }
23618 : : default:;
23619 : : }
23620 : : }
23621 : : break;
23622 : 5961 : default:;
23623 : : }
23624 : 5961 : switch (TREE_CODE (_q51))
23625 : : {
23626 : 2394 : case SSA_NAME:
23627 : 2394 : if (gimple *_d3 = get_def (valueize, _q51))
23628 : : {
23629 : 2314 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
23630 : 2752 : switch (gimple_assign_rhs_code (_a3))
23631 : : {
23632 : 5 : CASE_CONVERT:
23633 : 5 : {
23634 : 5 : tree _q70 = gimple_assign_rhs1 (_a3);
23635 : 5 : _q70 = do_valueize (valueize, _q70);
23636 : 5 : if ((_q70 == _q20 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q20, 0) && types_match (_q70, _q20)))
23637 : : {
23638 : 5 : {
23639 : 5 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
23640 : 5 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, LE_EXPR, NE_EXPR))
23641 : 0 : return true;
23642 : : }
23643 : : }
23644 : 5 : if ((_q70 == _q21 && ! TREE_SIDE_EFFECTS (_q70)) || (operand_equal_p (_q70, _q21, 0) && types_match (_q70, _q21)))
23645 : : {
23646 : 0 : {
23647 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
23648 : 0 : if (gimple_simplify_450 (res_op, seq, valueize, type, captures, LE_EXPR, NE_EXPR))
23649 : 0 : return true;
23650 : : }
23651 : : }
23652 : : break;
23653 : : }
23654 : : default:;
23655 : : }
23656 : : }
23657 : : break;
23658 : : default:;
23659 : : }
23660 : : break;
23661 : : }
23662 : : default:;
23663 : : }
23664 : : }
23665 : : break;
23666 : 249683 : default:;
23667 : : }
23668 : 249683 : switch (TREE_CODE (_q20))
23669 : : {
23670 : 244699 : case SSA_NAME:
23671 : 244699 : if (gimple *_d2 = get_def (valueize, _q20))
23672 : : {
23673 : 218571 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
23674 : 203574 : switch (gimple_assign_rhs_code (_a2))
23675 : : {
23676 : 4084 : CASE_CONVERT:
23677 : 4084 : {
23678 : 4084 : tree _q30 = gimple_assign_rhs1 (_a2);
23679 : 4084 : _q30 = do_valueize (valueize, _q30);
23680 : 4084 : switch (TREE_CODE (_p1))
23681 : : {
23682 : 4084 : case SSA_NAME:
23683 : 4084 : if (gimple *_d3 = get_def (valueize, _p1))
23684 : : {
23685 : 4069 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
23686 : 4047 : switch (gimple_assign_rhs_code (_a3))
23687 : : {
23688 : 627 : case EQ_EXPR:
23689 : 627 : {
23690 : 627 : tree _q60 = gimple_assign_rhs1 (_a3);
23691 : 627 : _q60 = do_valueize (valueize, _q60);
23692 : 627 : tree _q61 = gimple_assign_rhs2 (_a3);
23693 : 627 : _q61 = do_valueize (valueize, _q61);
23694 : 627 : if (tree_swap_operands_p (_q60, _q61))
23695 : 0 : std::swap (_q60, _q61);
23696 : 627 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
23697 : : {
23698 : 0 : {
23699 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q61, _p0, _q20, _q21 };
23700 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, NE_EXPR, EQ_EXPR))
23701 : 0 : return true;
23702 : : }
23703 : : }
23704 : 627 : if ((_q61 == _q30 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q30, 0) && types_match (_q61, _q30)))
23705 : : {
23706 : 0 : {
23707 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q60, _p0, _q20, _q21 };
23708 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, NE_EXPR, EQ_EXPR))
23709 : 0 : return true;
23710 : : }
23711 : : }
23712 : 249683 : break;
23713 : : }
23714 : 2265 : case NE_EXPR:
23715 : 2265 : {
23716 : 2265 : tree _q60 = gimple_assign_rhs1 (_a3);
23717 : 2265 : _q60 = do_valueize (valueize, _q60);
23718 : 2265 : tree _q61 = gimple_assign_rhs2 (_a3);
23719 : 2265 : _q61 = do_valueize (valueize, _q61);
23720 : 2265 : if (tree_swap_operands_p (_q60, _q61))
23721 : 4 : std::swap (_q60, _q61);
23722 : 2265 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
23723 : : {
23724 : 11 : {
23725 : 11 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q61, _p0, _q20, _q21 };
23726 : 11 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, NE_EXPR, NE_EXPR))
23727 : 0 : return true;
23728 : : }
23729 : : }
23730 : 2265 : if ((_q61 == _q30 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q30, 0) && types_match (_q61, _q30)))
23731 : : {
23732 : 0 : {
23733 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q60, _p0, _q20, _q21 };
23734 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, NE_EXPR, NE_EXPR))
23735 : 0 : return true;
23736 : : }
23737 : : }
23738 : 249683 : break;
23739 : : }
23740 : : default:;
23741 : : }
23742 : : }
23743 : : break;
23744 : : default:;
23745 : : }
23746 : : break;
23747 : : }
23748 : : default:;
23749 : : }
23750 : : }
23751 : : break;
23752 : 249683 : default:;
23753 : : }
23754 : 249683 : switch (TREE_CODE (_q21))
23755 : : {
23756 : 26988 : case SSA_NAME:
23757 : 26988 : if (gimple *_d2 = get_def (valueize, _q21))
23758 : : {
23759 : 23019 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
23760 : 16903 : switch (gimple_assign_rhs_code (_a2))
23761 : : {
23762 : 307 : CASE_CONVERT:
23763 : 307 : {
23764 : 307 : tree _q40 = gimple_assign_rhs1 (_a2);
23765 : 307 : _q40 = do_valueize (valueize, _q40);
23766 : 307 : switch (TREE_CODE (_p1))
23767 : : {
23768 : 307 : case SSA_NAME:
23769 : 307 : if (gimple *_d3 = get_def (valueize, _p1))
23770 : : {
23771 : 289 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
23772 : 245 : switch (gimple_assign_rhs_code (_a3))
23773 : : {
23774 : 69 : case EQ_EXPR:
23775 : 69 : {
23776 : 69 : tree _q60 = gimple_assign_rhs1 (_a3);
23777 : 69 : _q60 = do_valueize (valueize, _q60);
23778 : 69 : tree _q61 = gimple_assign_rhs2 (_a3);
23779 : 69 : _q61 = do_valueize (valueize, _q61);
23780 : 69 : if (tree_swap_operands_p (_q60, _q61))
23781 : 0 : std::swap (_q60, _q61);
23782 : 69 : if ((_q60 == _q40 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q40, 0) && types_match (_q60, _q40)))
23783 : : {
23784 : 0 : {
23785 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q61, _p0, _q21, _q20 };
23786 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, NE_EXPR, EQ_EXPR))
23787 : 0 : return true;
23788 : : }
23789 : : }
23790 : 69 : if ((_q61 == _q40 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q40, 0) && types_match (_q61, _q40)))
23791 : : {
23792 : 0 : {
23793 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q60, _p0, _q21, _q20 };
23794 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, NE_EXPR, EQ_EXPR))
23795 : 0 : return true;
23796 : : }
23797 : : }
23798 : 249683 : break;
23799 : : }
23800 : 106 : case NE_EXPR:
23801 : 106 : {
23802 : 106 : tree _q60 = gimple_assign_rhs1 (_a3);
23803 : 106 : _q60 = do_valueize (valueize, _q60);
23804 : 106 : tree _q61 = gimple_assign_rhs2 (_a3);
23805 : 106 : _q61 = do_valueize (valueize, _q61);
23806 : 106 : if (tree_swap_operands_p (_q60, _q61))
23807 : 13 : std::swap (_q60, _q61);
23808 : 106 : if ((_q60 == _q40 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q40, 0) && types_match (_q60, _q40)))
23809 : : {
23810 : 5 : {
23811 : 5 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q61, _p0, _q21, _q20 };
23812 : 5 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, NE_EXPR, NE_EXPR))
23813 : 0 : return true;
23814 : : }
23815 : : }
23816 : 106 : if ((_q61 == _q40 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q40, 0) && types_match (_q61, _q40)))
23817 : : {
23818 : 0 : {
23819 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q60, _p0, _q21, _q20 };
23820 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, NE_EXPR, NE_EXPR))
23821 : 0 : return true;
23822 : : }
23823 : : }
23824 : 249683 : break;
23825 : : }
23826 : : default:;
23827 : : }
23828 : : }
23829 : : break;
23830 : : default:;
23831 : : }
23832 : : break;
23833 : : }
23834 : : default:;
23835 : : }
23836 : : }
23837 : : break;
23838 : 249683 : default:;
23839 : : }
23840 : 249683 : switch (TREE_CODE (_p1))
23841 : : {
23842 : 249555 : case SSA_NAME:
23843 : 249555 : if (gimple *_d2 = get_def (valueize, _p1))
23844 : : {
23845 : 246571 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
23846 : 240377 : switch (gimple_assign_rhs_code (_a2))
23847 : : {
23848 : 51392 : case EQ_EXPR:
23849 : 51392 : {
23850 : 51392 : tree _q50 = gimple_assign_rhs1 (_a2);
23851 : 51392 : _q50 = do_valueize (valueize, _q50);
23852 : 51392 : tree _q51 = gimple_assign_rhs2 (_a2);
23853 : 51392 : _q51 = do_valueize (valueize, _q51);
23854 : 51392 : if (tree_swap_operands_p (_q50, _q51))
23855 : 248 : std::swap (_q50, _q51);
23856 : 51392 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
23857 : : {
23858 : 889 : {
23859 : 889 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
23860 : 889 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, EQ_EXPR, NE_EXPR))
23861 : 186 : return true;
23862 : : }
23863 : 703 : {
23864 : 703 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q51, _p0, _q20, _q21 };
23865 : 703 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, NE_EXPR, EQ_EXPR))
23866 : 0 : return true;
23867 : : }
23868 : : }
23869 : 51206 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
23870 : : {
23871 : 355 : {
23872 : 355 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
23873 : 355 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, EQ_EXPR, NE_EXPR))
23874 : 0 : return true;
23875 : : }
23876 : : }
23877 : 51206 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
23878 : : {
23879 : 64 : {
23880 : 64 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
23881 : 64 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, EQ_EXPR, NE_EXPR))
23882 : 0 : return true;
23883 : : }
23884 : 64 : {
23885 : 64 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q51, _p0, _q21, _q20 };
23886 : 64 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, NE_EXPR, EQ_EXPR))
23887 : 0 : return true;
23888 : : }
23889 : : }
23890 : 51206 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
23891 : : {
23892 : 10779 : {
23893 : 10779 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
23894 : 10779 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, EQ_EXPR, NE_EXPR))
23895 : 0 : return true;
23896 : : }
23897 : 10779 : {
23898 : 10779 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q50, _p0, _q21, _q20 };
23899 : 10779 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, NE_EXPR, EQ_EXPR))
23900 : 0 : return true;
23901 : : }
23902 : : }
23903 : 51206 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
23904 : : {
23905 : 355 : {
23906 : 355 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q50, _p0, _q20, _q21 };
23907 : 355 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, NE_EXPR, EQ_EXPR))
23908 : 0 : return true;
23909 : : }
23910 : : }
23911 : 7738466 : break;
23912 : : }
23913 : 150866 : case NE_EXPR:
23914 : 150866 : {
23915 : 150866 : tree _q50 = gimple_assign_rhs1 (_a2);
23916 : 150866 : _q50 = do_valueize (valueize, _q50);
23917 : 150866 : tree _q51 = gimple_assign_rhs2 (_a2);
23918 : 150866 : _q51 = do_valueize (valueize, _q51);
23919 : 150866 : if (tree_swap_operands_p (_q50, _q51))
23920 : 1103 : std::swap (_q50, _q51);
23921 : 150866 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
23922 : : {
23923 : 48614 : {
23924 : 48614 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
23925 : 48614 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, NE_EXPR, NE_EXPR))
23926 : 10 : return true;
23927 : : }
23928 : 48604 : {
23929 : 48604 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q51, _p0, _q20, _q21 };
23930 : 48604 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, NE_EXPR, NE_EXPR))
23931 : 0 : return true;
23932 : : }
23933 : : }
23934 : 150856 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
23935 : : {
23936 : 1107 : {
23937 : 1107 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
23938 : 1107 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, NE_EXPR, NE_EXPR))
23939 : 0 : return true;
23940 : : }
23941 : : }
23942 : 150856 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
23943 : : {
23944 : 909 : {
23945 : 909 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
23946 : 909 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, NE_EXPR, NE_EXPR))
23947 : 0 : return true;
23948 : : }
23949 : 909 : {
23950 : 909 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q51, _p0, _q21, _q20 };
23951 : 909 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, NE_EXPR, NE_EXPR))
23952 : 0 : return true;
23953 : : }
23954 : : }
23955 : 150856 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
23956 : : {
23957 : 34823 : {
23958 : 34823 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
23959 : 34823 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, NE_EXPR, NE_EXPR))
23960 : 0 : return true;
23961 : : }
23962 : 34823 : {
23963 : 34823 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q50, _p0, _q21, _q20 };
23964 : 34823 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, NE_EXPR, NE_EXPR))
23965 : 0 : return true;
23966 : : }
23967 : : }
23968 : 150856 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
23969 : : {
23970 : 1107 : {
23971 : 1107 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q50, _p0, _q20, _q21 };
23972 : 1107 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, NE_EXPR, NE_EXPR))
23973 : 0 : return true;
23974 : : }
23975 : : }
23976 : 7738466 : break;
23977 : : }
23978 : 8557 : case LT_EXPR:
23979 : 8557 : {
23980 : 8557 : tree _q50 = gimple_assign_rhs1 (_a2);
23981 : 8557 : _q50 = do_valueize (valueize, _q50);
23982 : 8557 : tree _q51 = gimple_assign_rhs2 (_a2);
23983 : 8557 : _q51 = do_valueize (valueize, _q51);
23984 : 8557 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
23985 : : {
23986 : 5888 : {
23987 : 5888 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
23988 : 5888 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, LT_EXPR, NE_EXPR))
23989 : 4 : return true;
23990 : : }
23991 : : }
23992 : 8553 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
23993 : : {
23994 : 10 : {
23995 : 10 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
23996 : 10 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, GT_EXPR, NE_EXPR))
23997 : 0 : return true;
23998 : : }
23999 : : }
24000 : 8553 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
24001 : : {
24002 : 21 : {
24003 : 21 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
24004 : 21 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, LT_EXPR, NE_EXPR))
24005 : 0 : return true;
24006 : : }
24007 : : }
24008 : 8553 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
24009 : : {
24010 : 154 : {
24011 : 154 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
24012 : 154 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, GT_EXPR, NE_EXPR))
24013 : 0 : return true;
24014 : : }
24015 : : }
24016 : : break;
24017 : : }
24018 : 10290 : case GT_EXPR:
24019 : 10290 : {
24020 : 10290 : tree _q50 = gimple_assign_rhs1 (_a2);
24021 : 10290 : _q50 = do_valueize (valueize, _q50);
24022 : 10290 : tree _q51 = gimple_assign_rhs2 (_a2);
24023 : 10290 : _q51 = do_valueize (valueize, _q51);
24024 : 10290 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
24025 : : {
24026 : 1615 : {
24027 : 1615 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
24028 : 1615 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, GT_EXPR, NE_EXPR))
24029 : 107 : return true;
24030 : : }
24031 : : }
24032 : 10183 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
24033 : : {
24034 : 2327 : {
24035 : 2327 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
24036 : 2327 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, LT_EXPR, NE_EXPR))
24037 : 0 : return true;
24038 : : }
24039 : : }
24040 : 10183 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
24041 : : {
24042 : 7 : {
24043 : 7 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
24044 : 7 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, GT_EXPR, NE_EXPR))
24045 : 0 : return true;
24046 : : }
24047 : : }
24048 : 10183 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
24049 : : {
24050 : 397 : {
24051 : 397 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
24052 : 397 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, LT_EXPR, NE_EXPR))
24053 : 0 : return true;
24054 : : }
24055 : : }
24056 : : break;
24057 : : }
24058 : 4517 : case LE_EXPR:
24059 : 4517 : {
24060 : 4517 : tree _q50 = gimple_assign_rhs1 (_a2);
24061 : 4517 : _q50 = do_valueize (valueize, _q50);
24062 : 4517 : tree _q51 = gimple_assign_rhs2 (_a2);
24063 : 4517 : _q51 = do_valueize (valueize, _q51);
24064 : 4517 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
24065 : : {
24066 : 1712 : {
24067 : 1712 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
24068 : 1712 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, LE_EXPR, NE_EXPR))
24069 : 8 : return true;
24070 : : }
24071 : : }
24072 : 4509 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
24073 : : {
24074 : 11 : {
24075 : 11 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
24076 : 11 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, GE_EXPR, NE_EXPR))
24077 : 0 : return true;
24078 : : }
24079 : : }
24080 : 4509 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
24081 : : {
24082 : 14 : {
24083 : 14 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
24084 : 14 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, LE_EXPR, NE_EXPR))
24085 : 0 : return true;
24086 : : }
24087 : : }
24088 : 4509 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
24089 : : {
24090 : 28 : {
24091 : 28 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
24092 : 28 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, GE_EXPR, NE_EXPR))
24093 : 0 : return true;
24094 : : }
24095 : : }
24096 : : break;
24097 : : }
24098 : 5961 : case GE_EXPR:
24099 : 5961 : {
24100 : 5961 : tree _q50 = gimple_assign_rhs1 (_a2);
24101 : 5961 : _q50 = do_valueize (valueize, _q50);
24102 : 5961 : tree _q51 = gimple_assign_rhs2 (_a2);
24103 : 5961 : _q51 = do_valueize (valueize, _q51);
24104 : 5961 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
24105 : : {
24106 : 148 : {
24107 : 148 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50, _q51 };
24108 : 148 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, GE_EXPR, NE_EXPR))
24109 : 4 : return true;
24110 : : }
24111 : : }
24112 : 5957 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
24113 : : {
24114 : 1539 : {
24115 : 1539 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51, _q50 };
24116 : 1539 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, LE_EXPR, NE_EXPR))
24117 : 0 : return true;
24118 : : }
24119 : : }
24120 : 5957 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
24121 : : {
24122 : 84 : {
24123 : 84 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50, _q51 };
24124 : 84 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, GE_EXPR, NE_EXPR))
24125 : 0 : return true;
24126 : : }
24127 : : }
24128 : 5957 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
24129 : : {
24130 : 50 : {
24131 : 50 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51, _q50 };
24132 : 50 : if (gimple_simplify_451 (res_op, seq, valueize, type, captures, LE_EXPR, NE_EXPR))
24133 : 0 : return true;
24134 : : }
24135 : : }
24136 : : break;
24137 : : }
24138 : : default:;
24139 : : }
24140 : : }
24141 : : break;
24142 : : default:;
24143 : : }
24144 : 7738466 : break;
24145 : : }
24146 : 81648 : case LE_EXPR:
24147 : 81648 : {
24148 : 81648 : tree _q20 = gimple_assign_rhs1 (_a1);
24149 : 81648 : _q20 = do_valueize (valueize, _q20);
24150 : 81648 : tree _q21 = gimple_assign_rhs2 (_a1);
24151 : 81648 : _q21 = do_valueize (valueize, _q21);
24152 : 81648 : switch (TREE_CODE (_p1))
24153 : : {
24154 : 81648 : case SSA_NAME:
24155 : 81648 : if (gimple *_d2 = get_def (valueize, _p1))
24156 : : {
24157 : 81429 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
24158 : 80665 : switch (gimple_assign_rhs_code (_a2))
24159 : : {
24160 : 6832 : case EQ_EXPR:
24161 : 6832 : {
24162 : 6832 : tree _q50 = gimple_assign_rhs1 (_a2);
24163 : 6832 : _q50 = do_valueize (valueize, _q50);
24164 : 6832 : tree _q51 = gimple_assign_rhs2 (_a2);
24165 : 6832 : _q51 = do_valueize (valueize, _q51);
24166 : 6832 : if (tree_swap_operands_p (_q50, _q51))
24167 : 0 : std::swap (_q50, _q51);
24168 : 6832 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
24169 : : {
24170 : 24 : if (gimple_min_value (_q51, valueize))
24171 : : {
24172 : 17 : {
24173 : 17 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
24174 : 17 : if (gimple_simplify_453 (res_op, seq, valueize, type, captures))
24175 : 17 : return true;
24176 : : }
24177 : : }
24178 : : }
24179 : 6815 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
24180 : : {
24181 : 0 : if (gimple_max_value (_q51, valueize))
24182 : : {
24183 : 0 : {
24184 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q21, _q20, _p1 };
24185 : 0 : if (gimple_simplify_454 (res_op, seq, valueize, type, captures))
24186 : 0 : return true;
24187 : : }
24188 : : }
24189 : : }
24190 : 81562 : break;
24191 : : }
24192 : 5091 : case NE_EXPR:
24193 : 5091 : {
24194 : 5091 : tree _q50 = gimple_assign_rhs1 (_a2);
24195 : 5091 : _q50 = do_valueize (valueize, _q50);
24196 : 5091 : tree _q51 = gimple_assign_rhs2 (_a2);
24197 : 5091 : _q51 = do_valueize (valueize, _q51);
24198 : 5091 : if (tree_swap_operands_p (_q50, _q51))
24199 : 23 : std::swap (_q50, _q51);
24200 : 5091 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
24201 : : {
24202 : 771 : if (gimple_min_value (_q51, valueize))
24203 : : {
24204 : 280 : {
24205 : 280 : tree captures[4] ATTRIBUTE_UNUSED = { _p1, _q20, _p0, _q21 };
24206 : 280 : if (gimple_simplify_455 (res_op, seq, valueize, type, captures))
24207 : 69 : return true;
24208 : : }
24209 : : }
24210 : : }
24211 : 81562 : break;
24212 : : }
24213 : : default:;
24214 : : }
24215 : : }
24216 : : break;
24217 : 81562 : default:;
24218 : : }
24219 : 81562 : switch (TREE_CODE (_q20))
24220 : : {
24221 : 81387 : case SSA_NAME:
24222 : 81387 : if (gimple *_d2 = get_def (valueize, _q20))
24223 : : {
24224 : 75810 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
24225 : 88475 : switch (gimple_assign_rhs_code (_a2))
24226 : : {
24227 : 6269 : CASE_CONVERT:
24228 : 6269 : {
24229 : 6269 : tree _q30 = gimple_assign_rhs1 (_a2);
24230 : 6269 : _q30 = do_valueize (valueize, _q30);
24231 : 6269 : switch (TREE_CODE (_p1))
24232 : : {
24233 : 6269 : case SSA_NAME:
24234 : 6269 : if (gimple *_d3 = get_def (valueize, _p1))
24235 : : {
24236 : 6269 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
24237 : 6269 : switch (gimple_assign_rhs_code (_a3))
24238 : : {
24239 : 236 : case EQ_EXPR:
24240 : 236 : {
24241 : 236 : tree _q60 = gimple_assign_rhs1 (_a3);
24242 : 236 : _q60 = do_valueize (valueize, _q60);
24243 : 236 : tree _q61 = gimple_assign_rhs2 (_a3);
24244 : 236 : _q61 = do_valueize (valueize, _q61);
24245 : 236 : if (tree_swap_operands_p (_q60, _q61))
24246 : 0 : std::swap (_q60, _q61);
24247 : 236 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
24248 : : {
24249 : 16 : {
24250 : 16 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q61, _p0, _q20, _q21 };
24251 : 16 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, LE_EXPR, EQ_EXPR))
24252 : 0 : return true;
24253 : : }
24254 : : }
24255 : 236 : if ((_q61 == _q30 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q30, 0) && types_match (_q61, _q30)))
24256 : : {
24257 : 0 : {
24258 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q60, _p0, _q20, _q21 };
24259 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, LE_EXPR, EQ_EXPR))
24260 : 0 : return true;
24261 : : }
24262 : : }
24263 : 81562 : break;
24264 : : }
24265 : 311 : case NE_EXPR:
24266 : 311 : {
24267 : 311 : tree _q60 = gimple_assign_rhs1 (_a3);
24268 : 311 : _q60 = do_valueize (valueize, _q60);
24269 : 311 : tree _q61 = gimple_assign_rhs2 (_a3);
24270 : 311 : _q61 = do_valueize (valueize, _q61);
24271 : 311 : if (tree_swap_operands_p (_q60, _q61))
24272 : 0 : std::swap (_q60, _q61);
24273 : 311 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
24274 : : {
24275 : 58 : {
24276 : 58 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q61, _p0, _q20, _q21 };
24277 : 58 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, LE_EXPR, NE_EXPR))
24278 : 0 : return true;
24279 : : }
24280 : : }
24281 : 311 : if ((_q61 == _q30 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q30, 0) && types_match (_q61, _q30)))
24282 : : {
24283 : 54 : {
24284 : 54 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q60, _p0, _q20, _q21 };
24285 : 54 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, LE_EXPR, NE_EXPR))
24286 : 0 : return true;
24287 : : }
24288 : : }
24289 : 81562 : break;
24290 : : }
24291 : : default:;
24292 : : }
24293 : : }
24294 : : break;
24295 : : default:;
24296 : : }
24297 : : break;
24298 : : }
24299 : : default:;
24300 : : }
24301 : : }
24302 : : break;
24303 : 81562 : default:;
24304 : : }
24305 : 81562 : switch (TREE_CODE (_q21))
24306 : : {
24307 : 51555 : case SSA_NAME:
24308 : 51555 : if (gimple *_d2 = get_def (valueize, _q21))
24309 : : {
24310 : 47765 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
24311 : 63141 : switch (gimple_assign_rhs_code (_a2))
24312 : : {
24313 : 2723 : CASE_CONVERT:
24314 : 2723 : {
24315 : 2723 : tree _q40 = gimple_assign_rhs1 (_a2);
24316 : 2723 : _q40 = do_valueize (valueize, _q40);
24317 : 2723 : switch (TREE_CODE (_p1))
24318 : : {
24319 : 2723 : case SSA_NAME:
24320 : 2723 : if (gimple *_d3 = get_def (valueize, _p1))
24321 : : {
24322 : 2723 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
24323 : 2723 : switch (gimple_assign_rhs_code (_a3))
24324 : : {
24325 : 72 : case EQ_EXPR:
24326 : 72 : {
24327 : 72 : tree _q60 = gimple_assign_rhs1 (_a3);
24328 : 72 : _q60 = do_valueize (valueize, _q60);
24329 : 72 : tree _q61 = gimple_assign_rhs2 (_a3);
24330 : 72 : _q61 = do_valueize (valueize, _q61);
24331 : 72 : if (tree_swap_operands_p (_q60, _q61))
24332 : 0 : std::swap (_q60, _q61);
24333 : 72 : if ((_q60 == _q40 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q40, 0) && types_match (_q60, _q40)))
24334 : : {
24335 : 0 : {
24336 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q61, _p0, _q21, _q20 };
24337 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
24338 : 0 : return true;
24339 : : }
24340 : : }
24341 : 72 : if ((_q61 == _q40 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q40, 0) && types_match (_q61, _q40)))
24342 : : {
24343 : 0 : {
24344 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q60, _p0, _q21, _q20 };
24345 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
24346 : 0 : return true;
24347 : : }
24348 : : }
24349 : 81562 : break;
24350 : : }
24351 : 136 : case NE_EXPR:
24352 : 136 : {
24353 : 136 : tree _q60 = gimple_assign_rhs1 (_a3);
24354 : 136 : _q60 = do_valueize (valueize, _q60);
24355 : 136 : tree _q61 = gimple_assign_rhs2 (_a3);
24356 : 136 : _q61 = do_valueize (valueize, _q61);
24357 : 136 : if (tree_swap_operands_p (_q60, _q61))
24358 : 0 : std::swap (_q60, _q61);
24359 : 136 : if ((_q60 == _q40 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q40, 0) && types_match (_q60, _q40)))
24360 : : {
24361 : 0 : {
24362 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q61, _p0, _q21, _q20 };
24363 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, GE_EXPR, NE_EXPR))
24364 : 0 : return true;
24365 : : }
24366 : : }
24367 : 136 : if ((_q61 == _q40 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q40, 0) && types_match (_q61, _q40)))
24368 : : {
24369 : 0 : {
24370 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q60, _p0, _q21, _q20 };
24371 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, GE_EXPR, NE_EXPR))
24372 : 0 : return true;
24373 : : }
24374 : : }
24375 : 81562 : break;
24376 : : }
24377 : : default:;
24378 : : }
24379 : : }
24380 : : break;
24381 : : default:;
24382 : : }
24383 : : break;
24384 : : }
24385 : : default:;
24386 : : }
24387 : : }
24388 : : break;
24389 : 81562 : default:;
24390 : : }
24391 : 81562 : switch (TREE_CODE (_p1))
24392 : : {
24393 : 81562 : case SSA_NAME:
24394 : 81562 : if (gimple *_d2 = get_def (valueize, _p1))
24395 : : {
24396 : 81343 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
24397 : 80579 : switch (gimple_assign_rhs_code (_a2))
24398 : : {
24399 : 6815 : case EQ_EXPR:
24400 : 6815 : {
24401 : 6815 : tree _q50 = gimple_assign_rhs1 (_a2);
24402 : 6815 : _q50 = do_valueize (valueize, _q50);
24403 : 6815 : tree _q51 = gimple_assign_rhs2 (_a2);
24404 : 6815 : _q51 = do_valueize (valueize, _q51);
24405 : 6815 : if (tree_swap_operands_p (_q50, _q51))
24406 : 0 : std::swap (_q50, _q51);
24407 : 6815 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
24408 : : {
24409 : 7 : {
24410 : 7 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q51, _p0, _q20, _q21 };
24411 : 7 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, LE_EXPR, EQ_EXPR))
24412 : 6 : return true;
24413 : : }
24414 : : }
24415 : 6809 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
24416 : : {
24417 : 0 : {
24418 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q51, _p0, _q21, _q20 };
24419 : 0 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
24420 : 0 : return true;
24421 : : }
24422 : : }
24423 : 6809 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
24424 : : {
24425 : 3 : {
24426 : 3 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q50, _p0, _q20, _q21 };
24427 : 3 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, LE_EXPR, EQ_EXPR))
24428 : 0 : return true;
24429 : : }
24430 : : }
24431 : 6809 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
24432 : : {
24433 : 26 : {
24434 : 26 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q50, _p0, _q21, _q20 };
24435 : 26 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
24436 : 0 : return true;
24437 : : }
24438 : : }
24439 : 81295 : break;
24440 : : }
24441 : 5022 : case NE_EXPR:
24442 : 5022 : {
24443 : 5022 : tree _q50 = gimple_assign_rhs1 (_a2);
24444 : 5022 : _q50 = do_valueize (valueize, _q50);
24445 : 5022 : tree _q51 = gimple_assign_rhs2 (_a2);
24446 : 5022 : _q51 = do_valueize (valueize, _q51);
24447 : 5022 : if (tree_swap_operands_p (_q50, _q51))
24448 : 23 : std::swap (_q50, _q51);
24449 : 5022 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
24450 : : {
24451 : 702 : {
24452 : 702 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q51, _p0, _q20, _q21 };
24453 : 702 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, LE_EXPR, NE_EXPR))
24454 : 25 : return true;
24455 : : }
24456 : : }
24457 : 4997 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
24458 : : {
24459 : 138 : {
24460 : 138 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q51, _p0, _q21, _q20 };
24461 : 138 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, GE_EXPR, NE_EXPR))
24462 : 0 : return true;
24463 : : }
24464 : : }
24465 : 4997 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
24466 : : {
24467 : 60 : {
24468 : 60 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q50, _p0, _q20, _q21 };
24469 : 60 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, LE_EXPR, NE_EXPR))
24470 : 0 : return true;
24471 : : }
24472 : : }
24473 : 4997 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
24474 : : {
24475 : 139 : {
24476 : 139 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q50, _p0, _q21, _q20 };
24477 : 139 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, GE_EXPR, NE_EXPR))
24478 : 0 : return true;
24479 : : }
24480 : : }
24481 : 81295 : break;
24482 : : }
24483 : 4949 : case LT_EXPR:
24484 : 4949 : {
24485 : 4949 : tree _q50 = gimple_assign_rhs1 (_a2);
24486 : 4949 : _q50 = do_valueize (valueize, _q50);
24487 : 4949 : tree _q51 = gimple_assign_rhs2 (_a2);
24488 : 4949 : _q51 = do_valueize (valueize, _q51);
24489 : 4949 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
24490 : : {
24491 : 833 : {
24492 : 833 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
24493 : 833 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LT_EXPR, LE_EXPR))
24494 : 25 : return true;
24495 : : }
24496 : : }
24497 : 4924 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
24498 : : {
24499 : 896 : {
24500 : 896 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
24501 : 896 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GT_EXPR, LE_EXPR))
24502 : 149 : return true;
24503 : : }
24504 : : }
24505 : 4775 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
24506 : : {
24507 : 764 : {
24508 : 764 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
24509 : 764 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LT_EXPR, GE_EXPR))
24510 : 0 : return true;
24511 : : }
24512 : : }
24513 : 4775 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
24514 : : {
24515 : 992 : {
24516 : 992 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
24517 : 992 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GT_EXPR, GE_EXPR))
24518 : 0 : return true;
24519 : : }
24520 : : }
24521 : : break;
24522 : : }
24523 : 7041 : case LE_EXPR:
24524 : 7041 : {
24525 : 7041 : tree _q50 = gimple_assign_rhs1 (_a2);
24526 : 7041 : _q50 = do_valueize (valueize, _q50);
24527 : 7041 : tree _q51 = gimple_assign_rhs2 (_a2);
24528 : 7041 : _q51 = do_valueize (valueize, _q51);
24529 : 7041 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
24530 : : {
24531 : 571 : {
24532 : 571 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
24533 : 571 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LE_EXPR, LE_EXPR))
24534 : 8 : return true;
24535 : : }
24536 : : }
24537 : 7033 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
24538 : : {
24539 : 72 : {
24540 : 72 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
24541 : 72 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GE_EXPR, LE_EXPR))
24542 : 0 : return true;
24543 : : }
24544 : : }
24545 : 7033 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
24546 : : {
24547 : 1939 : {
24548 : 1939 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
24549 : 1939 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LE_EXPR, GE_EXPR))
24550 : 0 : return true;
24551 : : }
24552 : : }
24553 : 7033 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
24554 : : {
24555 : 1917 : {
24556 : 1917 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
24557 : 1917 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GE_EXPR, GE_EXPR))
24558 : 0 : return true;
24559 : : }
24560 : : }
24561 : : break;
24562 : : }
24563 : 13539 : case GT_EXPR:
24564 : 13539 : {
24565 : 13539 : tree _q50 = gimple_assign_rhs1 (_a2);
24566 : 13539 : _q50 = do_valueize (valueize, _q50);
24567 : 13539 : tree _q51 = gimple_assign_rhs2 (_a2);
24568 : 13539 : _q51 = do_valueize (valueize, _q51);
24569 : 13539 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
24570 : : {
24571 : 6015 : {
24572 : 6015 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
24573 : 6015 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GT_EXPR, LE_EXPR))
24574 : 0 : return true;
24575 : : }
24576 : : }
24577 : 13539 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
24578 : : {
24579 : 707 : {
24580 : 707 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
24581 : 707 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LT_EXPR, LE_EXPR))
24582 : 0 : return true;
24583 : : }
24584 : : }
24585 : 13539 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
24586 : : {
24587 : 1322 : {
24588 : 1322 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
24589 : 1322 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GT_EXPR, GE_EXPR))
24590 : 0 : return true;
24591 : : }
24592 : : }
24593 : 13539 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
24594 : : {
24595 : 1232 : {
24596 : 1232 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
24597 : 1232 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LT_EXPR, GE_EXPR))
24598 : 0 : return true;
24599 : : }
24600 : : }
24601 : : break;
24602 : : }
24603 : 41116 : case GE_EXPR:
24604 : 41116 : {
24605 : 41116 : tree _q50 = gimple_assign_rhs1 (_a2);
24606 : 41116 : _q50 = do_valueize (valueize, _q50);
24607 : 41116 : tree _q51 = gimple_assign_rhs2 (_a2);
24608 : 41116 : _q51 = do_valueize (valueize, _q51);
24609 : 41116 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
24610 : : {
24611 : 26899 : {
24612 : 26899 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
24613 : 26899 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GE_EXPR, LE_EXPR))
24614 : 54 : return true;
24615 : : }
24616 : : }
24617 : 41062 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
24618 : : {
24619 : 89 : {
24620 : 89 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
24621 : 89 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LE_EXPR, LE_EXPR))
24622 : 0 : return true;
24623 : : }
24624 : : }
24625 : 41062 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
24626 : : {
24627 : 9 : {
24628 : 9 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
24629 : 9 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GE_EXPR, GE_EXPR))
24630 : 0 : return true;
24631 : : }
24632 : : }
24633 : 41062 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
24634 : : {
24635 : 16798 : {
24636 : 16798 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
24637 : 16798 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LE_EXPR, GE_EXPR))
24638 : 0 : return true;
24639 : : }
24640 : : }
24641 : : break;
24642 : : }
24643 : : default:;
24644 : : }
24645 : : }
24646 : : break;
24647 : 81295 : default:;
24648 : : }
24649 : 81295 : if (integer_onep (_q21))
24650 : : {
24651 : 1023 : switch (TREE_CODE (_p1))
24652 : : {
24653 : 1023 : case SSA_NAME:
24654 : 1023 : if (gimple *_d2 = get_def (valueize, _p1))
24655 : : {
24656 : 1023 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
24657 : 1066 : switch (gimple_assign_rhs_code (_a2))
24658 : : {
24659 : 0 : CASE_CONVERT:
24660 : 0 : {
24661 : 0 : tree _q50 = gimple_assign_rhs1 (_a2);
24662 : 0 : _q50 = do_valueize (valueize, _q50);
24663 : 0 : {
24664 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _q50 };
24665 : 0 : if (gimple_simplify_456 (res_op, seq, valueize, type, captures))
24666 : 0 : return true;
24667 : : }
24668 : 0 : break;
24669 : : }
24670 : : default:;
24671 : : }
24672 : : }
24673 : : break;
24674 : 1023 : default:;
24675 : : }
24676 : 1023 : {
24677 : 1023 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
24678 : 1023 : if (gimple_simplify_456 (res_op, seq, valueize, type, captures))
24679 : 0 : return true;
24680 : : }
24681 : : }
24682 : : break;
24683 : : }
24684 : 557279 : case GE_EXPR:
24685 : 557279 : {
24686 : 557279 : tree _q20 = gimple_assign_rhs1 (_a1);
24687 : 557279 : _q20 = do_valueize (valueize, _q20);
24688 : 557279 : tree _q21 = gimple_assign_rhs2 (_a1);
24689 : 557279 : _q21 = do_valueize (valueize, _q21);
24690 : 557279 : switch (TREE_CODE (_p1))
24691 : : {
24692 : 557279 : case SSA_NAME:
24693 : 557279 : if (gimple *_d2 = get_def (valueize, _p1))
24694 : : {
24695 : 555443 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
24696 : 553779 : switch (gimple_assign_rhs_code (_a2))
24697 : : {
24698 : 12912 : case EQ_EXPR:
24699 : 12912 : {
24700 : 12912 : tree _q50 = gimple_assign_rhs1 (_a2);
24701 : 12912 : _q50 = do_valueize (valueize, _q50);
24702 : 12912 : tree _q51 = gimple_assign_rhs2 (_a2);
24703 : 12912 : _q51 = do_valueize (valueize, _q51);
24704 : 12912 : if (tree_swap_operands_p (_q50, _q51))
24705 : 8 : std::swap (_q50, _q51);
24706 : 12912 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
24707 : : {
24708 : 3 : if (gimple_min_value (_q51, valueize))
24709 : : {
24710 : 0 : {
24711 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q21, _q20, _p1 };
24712 : 0 : if (gimple_simplify_453 (res_op, seq, valueize, type, captures))
24713 : 0 : return true;
24714 : : }
24715 : : }
24716 : : }
24717 : 12912 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
24718 : : {
24719 : 19 : if (gimple_max_value (_q51, valueize))
24720 : : {
24721 : 14 : {
24722 : 14 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _q21, _p1 };
24723 : 14 : if (gimple_simplify_454 (res_op, seq, valueize, type, captures))
24724 : 14 : return true;
24725 : : }
24726 : : }
24727 : : }
24728 : 557260 : break;
24729 : : }
24730 : 3475 : case NE_EXPR:
24731 : 3475 : {
24732 : 3475 : tree _q50 = gimple_assign_rhs1 (_a2);
24733 : 3475 : _q50 = do_valueize (valueize, _q50);
24734 : 3475 : tree _q51 = gimple_assign_rhs2 (_a2);
24735 : 3475 : _q51 = do_valueize (valueize, _q51);
24736 : 3475 : if (tree_swap_operands_p (_q50, _q51))
24737 : 46 : std::swap (_q50, _q51);
24738 : 3475 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
24739 : : {
24740 : 1075 : if (gimple_min_value (_q51, valueize))
24741 : : {
24742 : 973 : {
24743 : 973 : tree captures[4] ATTRIBUTE_UNUSED = { _p1, _q21, _p0, _q20 };
24744 : 973 : if (gimple_simplify_455 (res_op, seq, valueize, type, captures))
24745 : 5 : return true;
24746 : : }
24747 : : }
24748 : : }
24749 : 557260 : break;
24750 : : }
24751 : : default:;
24752 : : }
24753 : : }
24754 : : break;
24755 : 557260 : default:;
24756 : : }
24757 : 557260 : switch (TREE_CODE (_q20))
24758 : : {
24759 : 556596 : case SSA_NAME:
24760 : 556596 : if (gimple *_d2 = get_def (valueize, _q20))
24761 : : {
24762 : 483421 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
24763 : 380214 : switch (gimple_assign_rhs_code (_a2))
24764 : : {
24765 : 16446 : CASE_CONVERT:
24766 : 16446 : {
24767 : 16446 : tree _q30 = gimple_assign_rhs1 (_a2);
24768 : 16446 : _q30 = do_valueize (valueize, _q30);
24769 : 16446 : switch (TREE_CODE (_p1))
24770 : : {
24771 : 16446 : case SSA_NAME:
24772 : 16446 : if (gimple *_d3 = get_def (valueize, _p1))
24773 : : {
24774 : 16446 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
24775 : 16442 : switch (gimple_assign_rhs_code (_a3))
24776 : : {
24777 : 669 : case EQ_EXPR:
24778 : 669 : {
24779 : 669 : tree _q60 = gimple_assign_rhs1 (_a3);
24780 : 669 : _q60 = do_valueize (valueize, _q60);
24781 : 669 : tree _q61 = gimple_assign_rhs2 (_a3);
24782 : 669 : _q61 = do_valueize (valueize, _q61);
24783 : 669 : if (tree_swap_operands_p (_q60, _q61))
24784 : 0 : std::swap (_q60, _q61);
24785 : 669 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
24786 : : {
24787 : 1 : {
24788 : 1 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q61, _p0, _q20, _q21 };
24789 : 1 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
24790 : 1 : return true;
24791 : : }
24792 : : }
24793 : 668 : if ((_q61 == _q30 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q30, 0) && types_match (_q61, _q30)))
24794 : : {
24795 : 0 : {
24796 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q60, _p0, _q20, _q21 };
24797 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
24798 : 0 : return true;
24799 : : }
24800 : : }
24801 : 557205 : break;
24802 : : }
24803 : 497 : case NE_EXPR:
24804 : 497 : {
24805 : 497 : tree _q60 = gimple_assign_rhs1 (_a3);
24806 : 497 : _q60 = do_valueize (valueize, _q60);
24807 : 497 : tree _q61 = gimple_assign_rhs2 (_a3);
24808 : 497 : _q61 = do_valueize (valueize, _q61);
24809 : 497 : if (tree_swap_operands_p (_q60, _q61))
24810 : 0 : std::swap (_q60, _q61);
24811 : 497 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
24812 : : {
24813 : 54 : {
24814 : 54 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q61, _p0, _q20, _q21 };
24815 : 54 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, GE_EXPR, NE_EXPR))
24816 : 54 : return true;
24817 : : }
24818 : : }
24819 : 443 : if ((_q61 == _q30 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q30, 0) && types_match (_q61, _q30)))
24820 : : {
24821 : 0 : {
24822 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q30, _q60, _p0, _q20, _q21 };
24823 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, GE_EXPR, NE_EXPR))
24824 : 0 : return true;
24825 : : }
24826 : : }
24827 : 557205 : break;
24828 : : }
24829 : : default:;
24830 : : }
24831 : : }
24832 : : break;
24833 : : default:;
24834 : : }
24835 : : break;
24836 : : }
24837 : : default:;
24838 : : }
24839 : : }
24840 : : break;
24841 : 557205 : default:;
24842 : : }
24843 : 557205 : switch (TREE_CODE (_q21))
24844 : : {
24845 : 47141 : case SSA_NAME:
24846 : 47141 : if (gimple *_d2 = get_def (valueize, _q21))
24847 : : {
24848 : 45507 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
24849 : 68566 : switch (gimple_assign_rhs_code (_a2))
24850 : : {
24851 : 1979 : CASE_CONVERT:
24852 : 1979 : {
24853 : 1979 : tree _q40 = gimple_assign_rhs1 (_a2);
24854 : 1979 : _q40 = do_valueize (valueize, _q40);
24855 : 1979 : switch (TREE_CODE (_p1))
24856 : : {
24857 : 1979 : case SSA_NAME:
24858 : 1979 : if (gimple *_d3 = get_def (valueize, _p1))
24859 : : {
24860 : 1979 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
24861 : 1979 : switch (gimple_assign_rhs_code (_a3))
24862 : : {
24863 : 14 : case EQ_EXPR:
24864 : 14 : {
24865 : 14 : tree _q60 = gimple_assign_rhs1 (_a3);
24866 : 14 : _q60 = do_valueize (valueize, _q60);
24867 : 14 : tree _q61 = gimple_assign_rhs2 (_a3);
24868 : 14 : _q61 = do_valueize (valueize, _q61);
24869 : 14 : if (tree_swap_operands_p (_q60, _q61))
24870 : 0 : std::swap (_q60, _q61);
24871 : 14 : if ((_q60 == _q40 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q40, 0) && types_match (_q60, _q40)))
24872 : : {
24873 : 0 : {
24874 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q61, _p0, _q21, _q20 };
24875 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, LE_EXPR, EQ_EXPR))
24876 : 0 : return true;
24877 : : }
24878 : : }
24879 : 14 : if ((_q61 == _q40 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q40, 0) && types_match (_q61, _q40)))
24880 : : {
24881 : 0 : {
24882 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q60, _p0, _q21, _q20 };
24883 : 0 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, LE_EXPR, EQ_EXPR))
24884 : 0 : return true;
24885 : : }
24886 : : }
24887 : 557205 : break;
24888 : : }
24889 : 28 : case NE_EXPR:
24890 : 28 : {
24891 : 28 : tree _q60 = gimple_assign_rhs1 (_a3);
24892 : 28 : _q60 = do_valueize (valueize, _q60);
24893 : 28 : tree _q61 = gimple_assign_rhs2 (_a3);
24894 : 28 : _q61 = do_valueize (valueize, _q61);
24895 : 28 : if (tree_swap_operands_p (_q60, _q61))
24896 : 0 : std::swap (_q60, _q61);
24897 : 28 : if ((_q60 == _q40 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q40, 0) && types_match (_q60, _q40)))
24898 : : {
24899 : 6 : {
24900 : 6 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q61, _p0, _q21, _q20 };
24901 : 6 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, LE_EXPR, NE_EXPR))
24902 : 0 : return true;
24903 : : }
24904 : : }
24905 : 28 : if ((_q61 == _q40 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q40, 0) && types_match (_q61, _q40)))
24906 : : {
24907 : 2 : {
24908 : 2 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q40, _q60, _p0, _q21, _q20 };
24909 : 2 : if (gimple_simplify_443 (res_op, seq, valueize, type, captures, LE_EXPR, NE_EXPR))
24910 : 0 : return true;
24911 : : }
24912 : : }
24913 : 557205 : break;
24914 : : }
24915 : : default:;
24916 : : }
24917 : : }
24918 : : break;
24919 : : default:;
24920 : : }
24921 : : break;
24922 : : }
24923 : : default:;
24924 : : }
24925 : : }
24926 : : break;
24927 : 557205 : default:;
24928 : : }
24929 : 557205 : switch (TREE_CODE (_p1))
24930 : : {
24931 : 557205 : case SSA_NAME:
24932 : 557205 : if (gimple *_d2 = get_def (valueize, _p1))
24933 : : {
24934 : 555369 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
24935 : 553705 : switch (gimple_assign_rhs_code (_a2))
24936 : : {
24937 : 12897 : case EQ_EXPR:
24938 : 12897 : {
24939 : 12897 : tree _q50 = gimple_assign_rhs1 (_a2);
24940 : 12897 : _q50 = do_valueize (valueize, _q50);
24941 : 12897 : tree _q51 = gimple_assign_rhs2 (_a2);
24942 : 12897 : _q51 = do_valueize (valueize, _q51);
24943 : 12897 : if (tree_swap_operands_p (_q50, _q51))
24944 : 8 : std::swap (_q50, _q51);
24945 : 12897 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
24946 : : {
24947 : 5 : {
24948 : 5 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q51, _p0, _q20, _q21 };
24949 : 5 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
24950 : 1 : return true;
24951 : : }
24952 : : }
24953 : 12896 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
24954 : : {
24955 : 3 : {
24956 : 3 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q51, _p0, _q21, _q20 };
24957 : 3 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, LE_EXPR, EQ_EXPR))
24958 : 0 : return true;
24959 : : }
24960 : : }
24961 : 12896 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
24962 : : {
24963 : 0 : {
24964 : 0 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q50, _p0, _q20, _q21 };
24965 : 0 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, GE_EXPR, EQ_EXPR))
24966 : 0 : return true;
24967 : : }
24968 : : }
24969 : 12896 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
24970 : : {
24971 : 31 : {
24972 : 31 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q50, _p0, _q21, _q20 };
24973 : 31 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, LE_EXPR, EQ_EXPR))
24974 : 0 : return true;
24975 : : }
24976 : : }
24977 : 7738466 : break;
24978 : : }
24979 : 3416 : case NE_EXPR:
24980 : 3416 : {
24981 : 3416 : tree _q50 = gimple_assign_rhs1 (_a2);
24982 : 3416 : _q50 = do_valueize (valueize, _q50);
24983 : 3416 : tree _q51 = gimple_assign_rhs2 (_a2);
24984 : 3416 : _q51 = do_valueize (valueize, _q51);
24985 : 3416 : if (tree_swap_operands_p (_q50, _q51))
24986 : 46 : std::swap (_q50, _q51);
24987 : 3416 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
24988 : : {
24989 : 365 : {
24990 : 365 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q51, _p0, _q20, _q21 };
24991 : 365 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, GE_EXPR, NE_EXPR))
24992 : 5 : return true;
24993 : : }
24994 : : }
24995 : 3411 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
24996 : : {
24997 : 1070 : {
24998 : 1070 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q51, _p0, _q21, _q20 };
24999 : 1070 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, LE_EXPR, NE_EXPR))
25000 : 0 : return true;
25001 : : }
25002 : : }
25003 : 3411 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
25004 : : {
25005 : 226 : {
25006 : 226 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q20, _q50, _p0, _q20, _q21 };
25007 : 226 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, GE_EXPR, NE_EXPR))
25008 : 0 : return true;
25009 : : }
25010 : : }
25011 : 3411 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
25012 : : {
25013 : 88 : {
25014 : 88 : tree captures[6] ATTRIBUTE_UNUSED = { _p1, _q21, _q50, _p0, _q21, _q20 };
25015 : 88 : if (gimple_simplify_444 (res_op, seq, valueize, type, captures, LE_EXPR, NE_EXPR))
25016 : 0 : return true;
25017 : : }
25018 : : }
25019 : 7738466 : break;
25020 : : }
25021 : 193592 : case LT_EXPR:
25022 : 193592 : {
25023 : 193592 : tree _q50 = gimple_assign_rhs1 (_a2);
25024 : 193592 : _q50 = do_valueize (valueize, _q50);
25025 : 193592 : tree _q51 = gimple_assign_rhs2 (_a2);
25026 : 193592 : _q51 = do_valueize (valueize, _q51);
25027 : 193592 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
25028 : : {
25029 : 191204 : {
25030 : 191204 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
25031 : 191204 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LT_EXPR, GE_EXPR))
25032 : 3 : return true;
25033 : : }
25034 : : }
25035 : 193589 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
25036 : : {
25037 : 45 : {
25038 : 45 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
25039 : 45 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GT_EXPR, GE_EXPR))
25040 : 0 : return true;
25041 : : }
25042 : : }
25043 : 193589 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
25044 : : {
25045 : 21 : {
25046 : 21 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
25047 : 21 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LT_EXPR, LE_EXPR))
25048 : 0 : return true;
25049 : : }
25050 : : }
25051 : 193589 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
25052 : : {
25053 : 401 : {
25054 : 401 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
25055 : 401 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GT_EXPR, LE_EXPR))
25056 : 0 : return true;
25057 : : }
25058 : : }
25059 : : break;
25060 : : }
25061 : 183902 : case LE_EXPR:
25062 : 183902 : {
25063 : 183902 : tree _q50 = gimple_assign_rhs1 (_a2);
25064 : 183902 : _q50 = do_valueize (valueize, _q50);
25065 : 183902 : tree _q51 = gimple_assign_rhs2 (_a2);
25066 : 183902 : _q51 = do_valueize (valueize, _q51);
25067 : 183902 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
25068 : : {
25069 : 179882 : {
25070 : 179882 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
25071 : 179882 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LE_EXPR, GE_EXPR))
25072 : 32 : return true;
25073 : : }
25074 : : }
25075 : 183870 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
25076 : : {
25077 : 194 : {
25078 : 194 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
25079 : 194 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GE_EXPR, GE_EXPR))
25080 : 0 : return true;
25081 : : }
25082 : : }
25083 : 183870 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
25084 : : {
25085 : 41 : {
25086 : 41 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
25087 : 41 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LE_EXPR, LE_EXPR))
25088 : 0 : return true;
25089 : : }
25090 : : }
25091 : 183870 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
25092 : : {
25093 : 6151 : {
25094 : 6151 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
25095 : 6151 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GE_EXPR, LE_EXPR))
25096 : 0 : return true;
25097 : : }
25098 : : }
25099 : : break;
25100 : : }
25101 : 50389 : case GT_EXPR:
25102 : 50389 : {
25103 : 50389 : tree _q50 = gimple_assign_rhs1 (_a2);
25104 : 50389 : _q50 = do_valueize (valueize, _q50);
25105 : 50389 : tree _q51 = gimple_assign_rhs2 (_a2);
25106 : 50389 : _q51 = do_valueize (valueize, _q51);
25107 : 50389 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
25108 : : {
25109 : 88 : {
25110 : 88 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
25111 : 88 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GT_EXPR, GE_EXPR))
25112 : 40 : return true;
25113 : : }
25114 : : }
25115 : 50349 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
25116 : : {
25117 : 47667 : {
25118 : 47667 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
25119 : 47667 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LT_EXPR, GE_EXPR))
25120 : 57 : return true;
25121 : : }
25122 : : }
25123 : 50292 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
25124 : : {
25125 : 88 : {
25126 : 88 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
25127 : 88 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GT_EXPR, LE_EXPR))
25128 : 0 : return true;
25129 : : }
25130 : : }
25131 : 50292 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
25132 : : {
25133 : 111 : {
25134 : 111 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
25135 : 111 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LT_EXPR, LE_EXPR))
25136 : 0 : return true;
25137 : : }
25138 : : }
25139 : : break;
25140 : : }
25141 : 108921 : case GE_EXPR:
25142 : 108921 : {
25143 : 108921 : tree _q50 = gimple_assign_rhs1 (_a2);
25144 : 108921 : _q50 = do_valueize (valueize, _q50);
25145 : 108921 : tree _q51 = gimple_assign_rhs2 (_a2);
25146 : 108921 : _q51 = do_valueize (valueize, _q51);
25147 : 108921 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
25148 : : {
25149 : 40 : {
25150 : 40 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
25151 : 40 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GE_EXPR, GE_EXPR))
25152 : 0 : return true;
25153 : : }
25154 : : }
25155 : 108921 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
25156 : : {
25157 : 82210 : {
25158 : 82210 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
25159 : 82210 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LE_EXPR, GE_EXPR))
25160 : 18 : return true;
25161 : : }
25162 : : }
25163 : 108903 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
25164 : : {
25165 : 16981 : {
25166 : 16981 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
25167 : 16981 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, GE_EXPR, LE_EXPR))
25168 : 0 : return true;
25169 : : }
25170 : : }
25171 : 108903 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
25172 : : {
25173 : 7016 : {
25174 : 7016 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
25175 : 7016 : if (gimple_simplify_445 (res_op, seq, valueize, type, captures, LE_EXPR, LE_EXPR))
25176 : 0 : return true;
25177 : : }
25178 : : }
25179 : : break;
25180 : : }
25181 : : default:;
25182 : : }
25183 : : }
25184 : : break;
25185 : : default:;
25186 : : }
25187 : : break;
25188 : : }
25189 : 61447 : case LSHIFT_EXPR:
25190 : 61447 : {
25191 : 61447 : tree _q20 = gimple_assign_rhs1 (_a1);
25192 : 61447 : _q20 = do_valueize (valueize, _q20);
25193 : 61447 : tree _q21 = gimple_assign_rhs2 (_a1);
25194 : 61447 : _q21 = do_valueize (valueize, _q21);
25195 : 61447 : switch (TREE_CODE (_q20))
25196 : : {
25197 : 29353 : case SSA_NAME:
25198 : 29353 : if (gimple *_d2 = get_def (valueize, _q20))
25199 : : {
25200 : 26650 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
25201 : 24645 : switch (gimple_assign_rhs_code (_a2))
25202 : : {
25203 : 8825 : CASE_CONVERT:
25204 : 8825 : {
25205 : 8825 : tree _q30 = gimple_assign_rhs1 (_a2);
25206 : 8825 : _q30 = do_valueize (valueize, _q30);
25207 : 8825 : switch (TREE_CODE (_q21))
25208 : : {
25209 : 8773 : case INTEGER_CST:
25210 : 8773 : {
25211 : 8773 : switch (TREE_CODE (_p1))
25212 : : {
25213 : 8765 : case INTEGER_CST:
25214 : 8765 : {
25215 : 8765 : {
25216 : 8765 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _p0, _q20, _q30, _q21, _p1 };
25217 : 8765 : if (gimple_simplify_457 (res_op, seq, valueize, type, captures, LSHIFT_EXPR))
25218 : 259 : return true;
25219 : : }
25220 : 8506 : break;
25221 : : }
25222 : : default:;
25223 : : }
25224 : : break;
25225 : : }
25226 : : default:;
25227 : : }
25228 : : break;
25229 : : }
25230 : : default:;
25231 : : }
25232 : : }
25233 : : break;
25234 : 31924 : case INTEGER_CST:
25235 : 31924 : {
25236 : 31924 : if (integer_onep (_p1))
25237 : : {
25238 : 310 : {
25239 : 310 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q21 };
25240 : 310 : if ((wi::to_wide (captures[0]) & 1) != 0
25241 : : )
25242 : : {
25243 : 310 : gimple_seq *lseq = seq;
25244 : 310 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2086;
25245 : 310 : {
25246 : 310 : res_op->set_op (NOP_EXPR, type, 1);
25247 : 310 : {
25248 : 310 : tree _o1[2], _r1;
25249 : 310 : _o1[0] = captures[1];
25250 : 310 : _o1[1] = build_zero_cst (TREE_TYPE (captures[1]));
25251 : 310 : gimple_match_op tem_op (res_op->cond.any_else (), EQ_EXPR, boolean_type_node, _o1[0], _o1[1]);
25252 : 310 : tem_op.resimplify (lseq, valueize);
25253 : 310 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
25254 : 310 : if (!_r1) goto next_after_fail2086;
25255 : 4 : res_op->ops[0] = _r1;
25256 : : }
25257 : 4 : res_op->resimplify (lseq, valueize);
25258 : 4 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1065, __FILE__, __LINE__, true);
25259 : 4 : return true;
25260 : : }
25261 : 306 : next_after_fail2086:;
25262 : : }
25263 : : else
25264 : : {
25265 : 0 : gimple_seq *lseq = seq;
25266 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2087;
25267 : 0 : {
25268 : 0 : tree tem;
25269 : 0 : tem = build_zero_cst (type);
25270 : 0 : res_op->set_value (tem);
25271 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1066, __FILE__, __LINE__, true);
25272 : 0 : return true;
25273 : : }
25274 : 306 : next_after_fail2087:;
25275 : : }
25276 : : }
25277 : : }
25278 : : break;
25279 : : }
25280 : 61184 : default:;
25281 : : }
25282 : 61184 : switch (TREE_CODE (_q21))
25283 : : {
25284 : 25659 : case INTEGER_CST:
25285 : 25659 : {
25286 : 25659 : switch (TREE_CODE (_p1))
25287 : : {
25288 : 24724 : case INTEGER_CST:
25289 : 24724 : {
25290 : 24724 : {
25291 : 24724 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _p0, _q20, _q20, _q21, _p1 };
25292 : 24724 : if (gimple_simplify_458 (res_op, seq, valueize, type, captures, LSHIFT_EXPR))
25293 : 258 : return true;
25294 : : }
25295 : 24466 : break;
25296 : : }
25297 : : default:;
25298 : : }
25299 : : break;
25300 : : }
25301 : : default:;
25302 : : }
25303 : : break;
25304 : : }
25305 : 210794 : case RSHIFT_EXPR:
25306 : 210794 : {
25307 : 210794 : tree _q20 = gimple_assign_rhs1 (_a1);
25308 : 210794 : _q20 = do_valueize (valueize, _q20);
25309 : 210794 : tree _q21 = gimple_assign_rhs2 (_a1);
25310 : 210794 : _q21 = do_valueize (valueize, _q21);
25311 : 210794 : switch (TREE_CODE (_q20))
25312 : : {
25313 : 190273 : case SSA_NAME:
25314 : 190273 : if (gimple *_d2 = get_def (valueize, _q20))
25315 : : {
25316 : 165902 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
25317 : 158350 : switch (gimple_assign_rhs_code (_a2))
25318 : : {
25319 : 23077 : CASE_CONVERT:
25320 : 23077 : {
25321 : 23077 : tree _q30 = gimple_assign_rhs1 (_a2);
25322 : 23077 : _q30 = do_valueize (valueize, _q30);
25323 : 23077 : switch (TREE_CODE (_q21))
25324 : : {
25325 : 16154 : case INTEGER_CST:
25326 : 16154 : {
25327 : 16154 : switch (TREE_CODE (_p1))
25328 : : {
25329 : 16084 : case INTEGER_CST:
25330 : 16084 : {
25331 : 16084 : {
25332 : 16084 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _p0, _q20, _q30, _q21, _p1 };
25333 : 16084 : if (gimple_simplify_457 (res_op, seq, valueize, type, captures, RSHIFT_EXPR))
25334 : 33 : return true;
25335 : : }
25336 : 16051 : break;
25337 : : }
25338 : : default:;
25339 : : }
25340 : : break;
25341 : : }
25342 : 23044 : default:;
25343 : : }
25344 : 23044 : switch (TREE_CODE (_q30))
25345 : : {
25346 : 23018 : case SSA_NAME:
25347 : 23018 : if (gimple *_d3 = get_def (valueize, _q30))
25348 : : {
25349 : 22029 : if (gcall *_c3 = dyn_cast <gcall *> (_d3))
25350 : 425 : switch (gimple_call_combined_fn (_c3))
25351 : : {
25352 : 0 : case CFN_BUILT_IN_BSWAP128:
25353 : 0 : if (gimple_call_num_args (_c3) == 1)
25354 : : {
25355 : 0 : tree _q40 = gimple_call_arg (_c3, 0);
25356 : 0 : _q40 = do_valueize (valueize, _q40);
25357 : 0 : switch (TREE_CODE (_q21))
25358 : : {
25359 : 0 : case INTEGER_CST:
25360 : 0 : {
25361 : 0 : switch (TREE_CODE (_p1))
25362 : : {
25363 : 0 : case INTEGER_CST:
25364 : 0 : {
25365 : 0 : {
25366 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q30, _q40, _q21, _p1 };
25367 : 0 : if (gimple_simplify_439 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP128))
25368 : 0 : return true;
25369 : : }
25370 : 0 : break;
25371 : : }
25372 : : default:;
25373 : : }
25374 : : break;
25375 : : }
25376 : : default:;
25377 : : }
25378 : : }
25379 : : break;
25380 : 16 : case CFN_BUILT_IN_BSWAP16:
25381 : 16 : if (gimple_call_num_args (_c3) == 1)
25382 : : {
25383 : 16 : tree _q40 = gimple_call_arg (_c3, 0);
25384 : 16 : _q40 = do_valueize (valueize, _q40);
25385 : 16 : switch (TREE_CODE (_q21))
25386 : : {
25387 : 0 : case INTEGER_CST:
25388 : 0 : {
25389 : 0 : switch (TREE_CODE (_p1))
25390 : : {
25391 : 0 : case INTEGER_CST:
25392 : 0 : {
25393 : 0 : {
25394 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q30, _q40, _q21, _p1 };
25395 : 0 : if (gimple_simplify_439 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP16))
25396 : 0 : return true;
25397 : : }
25398 : 0 : break;
25399 : : }
25400 : : default:;
25401 : : }
25402 : : break;
25403 : : }
25404 : : default:;
25405 : : }
25406 : : }
25407 : : break;
25408 : 0 : case CFN_BUILT_IN_BSWAP32:
25409 : 0 : if (gimple_call_num_args (_c3) == 1)
25410 : : {
25411 : 0 : tree _q40 = gimple_call_arg (_c3, 0);
25412 : 0 : _q40 = do_valueize (valueize, _q40);
25413 : 0 : switch (TREE_CODE (_q21))
25414 : : {
25415 : 0 : case INTEGER_CST:
25416 : 0 : {
25417 : 0 : switch (TREE_CODE (_p1))
25418 : : {
25419 : 0 : case INTEGER_CST:
25420 : 0 : {
25421 : 0 : {
25422 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q30, _q40, _q21, _p1 };
25423 : 0 : if (gimple_simplify_439 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP32))
25424 : 0 : return true;
25425 : : }
25426 : 0 : break;
25427 : : }
25428 : : default:;
25429 : : }
25430 : : break;
25431 : : }
25432 : : default:;
25433 : : }
25434 : : }
25435 : : break;
25436 : 0 : case CFN_BUILT_IN_BSWAP64:
25437 : 0 : if (gimple_call_num_args (_c3) == 1)
25438 : : {
25439 : 0 : tree _q40 = gimple_call_arg (_c3, 0);
25440 : 0 : _q40 = do_valueize (valueize, _q40);
25441 : 0 : switch (TREE_CODE (_q21))
25442 : : {
25443 : 0 : case INTEGER_CST:
25444 : 0 : {
25445 : 0 : switch (TREE_CODE (_p1))
25446 : : {
25447 : 0 : case INTEGER_CST:
25448 : 0 : {
25449 : 0 : {
25450 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q30, _q40, _q21, _p1 };
25451 : 0 : if (gimple_simplify_439 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP64))
25452 : 0 : return true;
25453 : : }
25454 : 0 : break;
25455 : : }
25456 : : default:;
25457 : : }
25458 : : break;
25459 : : }
25460 : : default:;
25461 : : }
25462 : : }
25463 : : break;
25464 : : default:;
25465 : : }
25466 : : }
25467 : : break;
25468 : : default:;
25469 : : }
25470 : : break;
25471 : : }
25472 : : default:;
25473 : : }
25474 : : }
25475 : : break;
25476 : 210761 : default:;
25477 : : }
25478 : 210761 : switch (TREE_CODE (_q21))
25479 : : {
25480 : 152618 : case INTEGER_CST:
25481 : 152618 : {
25482 : 152618 : switch (TREE_CODE (_p1))
25483 : : {
25484 : 149922 : case INTEGER_CST:
25485 : 149922 : {
25486 : 149922 : {
25487 : 149922 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _p0, _q20, _q20, _q21, _p1 };
25488 : 149922 : if (gimple_simplify_458 (res_op, seq, valueize, type, captures, RSHIFT_EXPR))
25489 : 747 : return true;
25490 : : }
25491 : 149175 : break;
25492 : : }
25493 : : default:;
25494 : : }
25495 : : break;
25496 : : }
25497 : 210014 : default:;
25498 : : }
25499 : 210014 : switch (TREE_CODE (_q20))
25500 : : {
25501 : 189493 : case SSA_NAME:
25502 : 189493 : if (gimple *_d2 = get_def (valueize, _q20))
25503 : : {
25504 : 165134 : if (gcall *_c2 = dyn_cast <gcall *> (_d2))
25505 : 3052 : switch (gimple_call_combined_fn (_c2))
25506 : : {
25507 : 0 : case CFN_BUILT_IN_BSWAP128:
25508 : 0 : if (gimple_call_num_args (_c2) == 1)
25509 : : {
25510 : 0 : tree _q30 = gimple_call_arg (_c2, 0);
25511 : 0 : _q30 = do_valueize (valueize, _q30);
25512 : 0 : switch (TREE_CODE (_q21))
25513 : : {
25514 : 0 : case INTEGER_CST:
25515 : 0 : {
25516 : 0 : switch (TREE_CODE (_p1))
25517 : : {
25518 : 0 : case INTEGER_CST:
25519 : 0 : {
25520 : 0 : {
25521 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q21, _p1 };
25522 : 0 : if (gimple_simplify_439 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP128))
25523 : 0 : return true;
25524 : : }
25525 : 0 : break;
25526 : : }
25527 : : default:;
25528 : : }
25529 : : break;
25530 : : }
25531 : : default:;
25532 : : }
25533 : : }
25534 : : break;
25535 : 0 : case CFN_BUILT_IN_BSWAP16:
25536 : 0 : if (gimple_call_num_args (_c2) == 1)
25537 : : {
25538 : 0 : tree _q30 = gimple_call_arg (_c2, 0);
25539 : 0 : _q30 = do_valueize (valueize, _q30);
25540 : 0 : switch (TREE_CODE (_q21))
25541 : : {
25542 : 0 : case INTEGER_CST:
25543 : 0 : {
25544 : 0 : switch (TREE_CODE (_p1))
25545 : : {
25546 : 0 : case INTEGER_CST:
25547 : 0 : {
25548 : 0 : {
25549 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q21, _p1 };
25550 : 0 : if (gimple_simplify_439 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP16))
25551 : 0 : return true;
25552 : : }
25553 : 0 : break;
25554 : : }
25555 : : default:;
25556 : : }
25557 : : break;
25558 : : }
25559 : : default:;
25560 : : }
25561 : : }
25562 : : break;
25563 : 22 : case CFN_BUILT_IN_BSWAP32:
25564 : 22 : if (gimple_call_num_args (_c2) == 1)
25565 : : {
25566 : 22 : tree _q30 = gimple_call_arg (_c2, 0);
25567 : 22 : _q30 = do_valueize (valueize, _q30);
25568 : 22 : switch (TREE_CODE (_q21))
25569 : : {
25570 : 20 : case INTEGER_CST:
25571 : 20 : {
25572 : 20 : switch (TREE_CODE (_p1))
25573 : : {
25574 : 20 : case INTEGER_CST:
25575 : 20 : {
25576 : 20 : {
25577 : 20 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q21, _p1 };
25578 : 20 : if (gimple_simplify_439 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP32))
25579 : 1 : return true;
25580 : : }
25581 : 19 : break;
25582 : : }
25583 : : default:;
25584 : : }
25585 : : break;
25586 : : }
25587 : : default:;
25588 : : }
25589 : : }
25590 : : break;
25591 : 2 : case CFN_BUILT_IN_BSWAP64:
25592 : 2 : if (gimple_call_num_args (_c2) == 1)
25593 : : {
25594 : 2 : tree _q30 = gimple_call_arg (_c2, 0);
25595 : 2 : _q30 = do_valueize (valueize, _q30);
25596 : 2 : switch (TREE_CODE (_q21))
25597 : : {
25598 : 0 : case INTEGER_CST:
25599 : 0 : {
25600 : 0 : switch (TREE_CODE (_p1))
25601 : : {
25602 : 0 : case INTEGER_CST:
25603 : 0 : {
25604 : 0 : {
25605 : 0 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q21, _p1 };
25606 : 0 : if (gimple_simplify_439 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP64))
25607 : 0 : return true;
25608 : : }
25609 : 0 : break;
25610 : : }
25611 : : default:;
25612 : : }
25613 : : break;
25614 : : }
25615 : : default:;
25616 : : }
25617 : : }
25618 : : break;
25619 : : default:;
25620 : : }
25621 : : }
25622 : : break;
25623 : : default:;
25624 : : }
25625 : : break;
25626 : : }
25627 : 6234 : case VEC_COND_EXPR:
25628 : 6234 : {
25629 : 6234 : tree _q20 = gimple_assign_rhs1 (_a1);
25630 : 6234 : _q20 = do_valueize (valueize, _q20);
25631 : 6234 : tree _q21 = gimple_assign_rhs2 (_a1);
25632 : 6234 : _q21 = do_valueize (valueize, _q21);
25633 : 6234 : tree _q22 = gimple_assign_rhs3 (_a1);
25634 : 6234 : _q22 = do_valueize (valueize, _q22);
25635 : 6234 : switch (TREE_CODE (_p1))
25636 : : {
25637 : 2660 : case SSA_NAME:
25638 : 2660 : if (gimple *_d2 = get_def (valueize, _p1))
25639 : : {
25640 : 2658 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
25641 : 2464 : switch (gimple_assign_rhs_code (_a2))
25642 : : {
25643 : 2174 : case VEC_COND_EXPR:
25644 : 2174 : {
25645 : 2174 : tree _q60 = gimple_assign_rhs1 (_a2);
25646 : 2174 : _q60 = do_valueize (valueize, _q60);
25647 : 2174 : tree _q61 = gimple_assign_rhs2 (_a2);
25648 : 2174 : _q61 = do_valueize (valueize, _q61);
25649 : 2174 : tree _q62 = gimple_assign_rhs3 (_a2);
25650 : 2174 : _q62 = do_valueize (valueize, _q62);
25651 : 2174 : if ((_q60 == _q20 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q20, 0) && types_match (_q60, _q20)))
25652 : : {
25653 : 0 : {
25654 : 0 : tree captures[7] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q22, _p1, _q61, _q62 };
25655 : 0 : if (TREE_CODE_CLASS (BIT_AND_EXPR) != tcc_comparison
25656 : : || types_match (type, TREE_TYPE (captures[2]))
25657 : : || expand_vec_cond_expr_p (type, TREE_TYPE (captures[1]), ERROR_MARK)
25658 : : || (optimize_vectors_before_lowering_p ()
25659 : : && !expand_vec_cond_expr_p (TREE_TYPE (captures[2]),
25660 : : TREE_TYPE (captures[1]), ERROR_MARK))
25661 : : )
25662 : : {
25663 : 0 : gimple_seq *lseq = seq;
25664 : 0 : if (lseq
25665 : 0 : && (!single_use (captures[0])
25666 : 0 : || !single_use (captures[4])))
25667 : 0 : lseq = NULL;
25668 : 0 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2088;
25669 : 0 : {
25670 : 0 : res_op->set_op (VEC_COND_EXPR, type, 3);
25671 : 0 : res_op->ops[0] = captures[1];
25672 : 0 : {
25673 : 0 : tree _o1[2], _r1;
25674 : 0 : _o1[0] = captures[2];
25675 : 0 : _o1[1] = captures[5];
25676 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_AND_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
25677 : 0 : tem_op.resimplify (NULL, valueize);
25678 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
25679 : 0 : if (!_r1) goto next_after_fail2088;
25680 : 0 : res_op->ops[1] = _r1;
25681 : : }
25682 : 0 : {
25683 : 0 : tree _o1[2], _r1;
25684 : 0 : _o1[0] = captures[3];
25685 : 0 : _o1[1] = captures[6];
25686 : 0 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_AND_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
25687 : 0 : tem_op.resimplify (NULL, valueize);
25688 : 0 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
25689 : 0 : if (!_r1) goto next_after_fail2088;
25690 : 0 : res_op->ops[2] = _r1;
25691 : : }
25692 : 0 : res_op->resimplify (lseq, valueize);
25693 : 0 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 925, __FILE__, __LINE__, true);
25694 : 0 : return true;
25695 : : }
25696 : 0 : next_after_fail2088:;
25697 : : }
25698 : : }
25699 : : }
25700 : : break;
25701 : : }
25702 : : default:;
25703 : : }
25704 : : }
25705 : : break;
25706 : 6234 : default:;
25707 : : }
25708 : 6234 : {
25709 : 6234 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _q22, _p1 };
25710 : 6234 : if (TREE_CODE_CLASS (BIT_AND_EXPR) != tcc_comparison
25711 : : || types_match (type, TREE_TYPE (captures[2]))
25712 : : || expand_vec_cond_expr_p (type, TREE_TYPE (captures[1]), ERROR_MARK)
25713 : : || (optimize_vectors_before_lowering_p ()
25714 : : && !expand_vec_cond_expr_p (TREE_TYPE (captures[2]),
25715 : : TREE_TYPE (captures[1]), ERROR_MARK))
25716 : : )
25717 : : {
25718 : 6234 : gimple_seq *lseq = seq;
25719 : 6234 : if (lseq
25720 : 1122 : && (!single_use (captures[0])))
25721 : 5291 : lseq = NULL;
25722 : 6234 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2089;
25723 : 6234 : {
25724 : 6234 : res_op->set_op (VEC_COND_EXPR, type, 3);
25725 : 6234 : res_op->ops[0] = captures[1];
25726 : 6234 : {
25727 : 6234 : tree _o1[2], _r1;
25728 : 6234 : _o1[0] = captures[2];
25729 : 6234 : _o1[1] = captures[4];
25730 : 6234 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_AND_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
25731 : 6234 : tem_op.resimplify (NULL, valueize);
25732 : 6234 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
25733 : 6234 : if (!_r1) goto next_after_fail2089;
25734 : 4300 : res_op->ops[1] = _r1;
25735 : : }
25736 : 4300 : {
25737 : 4300 : tree _o1[2], _r1;
25738 : 4300 : _o1[0] = captures[3];
25739 : 4300 : _o1[1] = captures[4];
25740 : 4300 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_AND_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
25741 : 4300 : tem_op.resimplify (NULL, valueize);
25742 : 4300 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
25743 : 4300 : if (!_r1) goto next_after_fail2089;
25744 : 4300 : res_op->ops[2] = _r1;
25745 : : }
25746 : 4300 : res_op->resimplify (lseq, valueize);
25747 : 4300 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 926, __FILE__, __LINE__, true);
25748 : 4300 : return true;
25749 : : }
25750 : 1934 : next_after_fail2089:;
25751 : : }
25752 : : }
25753 : 1934 : break;
25754 : : }
25755 : : default:;
25756 : : }
25757 : 1042190 : else if (gcall *_c1 = dyn_cast <gcall *> (_d1))
25758 : 126055 : switch (gimple_call_combined_fn (_c1))
25759 : : {
25760 : 0 : case CFN_BUILT_IN_BSWAP128:
25761 : 0 : if (gimple_call_num_args (_c1) == 1)
25762 : : {
25763 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
25764 : 0 : _q20 = do_valueize (valueize, _q20);
25765 : 0 : switch (TREE_CODE (_p1))
25766 : : {
25767 : 0 : case INTEGER_CST:
25768 : 0 : {
25769 : 0 : {
25770 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
25771 : 0 : if (gimple_simplify_440 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP128))
25772 : 0 : return true;
25773 : : }
25774 : 0 : break;
25775 : : }
25776 : : default:;
25777 : : }
25778 : : }
25779 : : break;
25780 : 2 : case CFN_BUILT_IN_BSWAP16:
25781 : 2 : if (gimple_call_num_args (_c1) == 1)
25782 : : {
25783 : 2 : tree _q20 = gimple_call_arg (_c1, 0);
25784 : 2 : _q20 = do_valueize (valueize, _q20);
25785 : 2 : switch (TREE_CODE (_p1))
25786 : : {
25787 : 2 : case INTEGER_CST:
25788 : 2 : {
25789 : 2 : {
25790 : 2 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
25791 : 2 : if (gimple_simplify_440 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP16))
25792 : 0 : return true;
25793 : : }
25794 : 2 : break;
25795 : : }
25796 : : default:;
25797 : : }
25798 : : }
25799 : : break;
25800 : 602 : case CFN_BUILT_IN_BSWAP32:
25801 : 602 : if (gimple_call_num_args (_c1) == 1)
25802 : : {
25803 : 602 : tree _q20 = gimple_call_arg (_c1, 0);
25804 : 602 : _q20 = do_valueize (valueize, _q20);
25805 : 602 : switch (TREE_CODE (_p1))
25806 : : {
25807 : 598 : case INTEGER_CST:
25808 : 598 : {
25809 : 598 : {
25810 : 598 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
25811 : 598 : if (gimple_simplify_440 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP32))
25812 : 5 : return true;
25813 : : }
25814 : 593 : break;
25815 : : }
25816 : : default:;
25817 : : }
25818 : : }
25819 : : break;
25820 : 438 : case CFN_BUILT_IN_BSWAP64:
25821 : 438 : if (gimple_call_num_args (_c1) == 1)
25822 : : {
25823 : 438 : tree _q20 = gimple_call_arg (_c1, 0);
25824 : 438 : _q20 = do_valueize (valueize, _q20);
25825 : 438 : switch (TREE_CODE (_p1))
25826 : : {
25827 : 436 : case INTEGER_CST:
25828 : 436 : {
25829 : 436 : {
25830 : 436 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q20, _p1 };
25831 : 436 : if (gimple_simplify_440 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_BSWAP64))
25832 : 4 : return true;
25833 : : }
25834 : 432 : break;
25835 : : }
25836 : : default:;
25837 : : }
25838 : : }
25839 : : break;
25840 : : default:;
25841 : : }
25842 : : }
25843 : : break;
25844 : 7738466 : default:;
25845 : : }
25846 : 7738466 : switch (TREE_CODE (_p1))
25847 : : {
25848 : 2716193 : case SSA_NAME:
25849 : 2716193 : if (gimple *_d1 = get_def (valueize, _p1))
25850 : : {
25851 : 2129612 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
25852 : 2066264 : switch (gimple_assign_rhs_code (_a1))
25853 : : {
25854 : 1927 : case VEC_COND_EXPR:
25855 : 1927 : {
25856 : 1927 : tree _q30 = gimple_assign_rhs1 (_a1);
25857 : 1927 : _q30 = do_valueize (valueize, _q30);
25858 : 1927 : tree _q31 = gimple_assign_rhs2 (_a1);
25859 : 1927 : _q31 = do_valueize (valueize, _q31);
25860 : 1927 : tree _q32 = gimple_assign_rhs3 (_a1);
25861 : 1927 : _q32 = do_valueize (valueize, _q32);
25862 : 1927 : {
25863 : 1927 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _p1, _q30, _q31, _q32 };
25864 : 1927 : if (TREE_CODE_CLASS (BIT_AND_EXPR) != tcc_comparison
25865 : : || types_match (type, TREE_TYPE (captures[3]))
25866 : : || expand_vec_cond_expr_p (type, TREE_TYPE (captures[2]), ERROR_MARK)
25867 : : || (optimize_vectors_before_lowering_p ()
25868 : : && !expand_vec_cond_expr_p (TREE_TYPE (captures[3]),
25869 : : TREE_TYPE (captures[2]), ERROR_MARK))
25870 : : )
25871 : : {
25872 : 1927 : gimple_seq *lseq = seq;
25873 : 1927 : if (lseq
25874 : 1132 : && (!single_use (captures[1])))
25875 : 834 : lseq = NULL;
25876 : 1927 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2090;
25877 : 1927 : {
25878 : 1927 : res_op->set_op (VEC_COND_EXPR, type, 3);
25879 : 1927 : res_op->ops[0] = captures[2];
25880 : 1927 : {
25881 : 1927 : tree _o1[2], _r1;
25882 : 1927 : _o1[0] = captures[0];
25883 : 1927 : _o1[1] = captures[3];
25884 : 1927 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_AND_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
25885 : 1927 : tem_op.resimplify (NULL, valueize);
25886 : 1927 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
25887 : 1927 : if (!_r1) goto next_after_fail2090;
25888 : 7 : res_op->ops[1] = _r1;
25889 : : }
25890 : 7 : {
25891 : 7 : tree _o1[2], _r1;
25892 : 7 : _o1[0] = captures[0];
25893 : 7 : _o1[1] = captures[4];
25894 : 7 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_AND_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
25895 : 7 : tem_op.resimplify (NULL, valueize);
25896 : 7 : _r1 = maybe_push_res_to_seq (&tem_op, NULL);
25897 : 7 : if (!_r1) goto next_after_fail2090;
25898 : 7 : res_op->ops[2] = _r1;
25899 : : }
25900 : 7 : res_op->resimplify (lseq, valueize);
25901 : 7 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 927, __FILE__, __LINE__, true);
25902 : 7 : return true;
25903 : : }
25904 : 1920 : next_after_fail2090:;
25905 : : }
25906 : : }
25907 : 1920 : break;
25908 : : }
25909 : : default:;
25910 : : }
25911 : : }
25912 : : break;
25913 : 7738459 : default:;
25914 : : }
25915 : 7738459 : switch (TREE_CODE (_p0))
25916 : : {
25917 : 7648699 : case SSA_NAME:
25918 : 7648699 : if (gimple *_d1 = get_def (valueize, _p0))
25919 : : {
25920 : 5315521 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
25921 : 5654620 : switch (gimple_assign_rhs_code (_a1))
25922 : : {
25923 : 379982 : CASE_CONVERT:
25924 : 379982 : {
25925 : 379982 : tree _q20 = gimple_assign_rhs1 (_a1);
25926 : 379982 : _q20 = do_valueize (valueize, _q20);
25927 : 379982 : switch (TREE_CODE (_q20))
25928 : : {
25929 : 379874 : case SSA_NAME:
25930 : 379874 : if (gimple *_d2 = get_def (valueize, _q20))
25931 : : {
25932 : 354454 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
25933 : 338831 : switch (gimple_assign_rhs_code (_a2))
25934 : : {
25935 : 500 : case LE_EXPR:
25936 : 500 : {
25937 : 500 : tree _q30 = gimple_assign_rhs1 (_a2);
25938 : 500 : _q30 = do_valueize (valueize, _q30);
25939 : 500 : tree _q31 = gimple_assign_rhs2 (_a2);
25940 : 500 : _q31 = do_valueize (valueize, _q31);
25941 : 500 : if (integer_onep (_q31))
25942 : : {
25943 : 28 : switch (TREE_CODE (_p1))
25944 : : {
25945 : 28 : case SSA_NAME:
25946 : 28 : if (gimple *_d3 = get_def (valueize, _p1))
25947 : : {
25948 : 28 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
25949 : 3 : switch (gimple_assign_rhs_code (_a3))
25950 : : {
25951 : 3 : CASE_CONVERT:
25952 : 3 : {
25953 : 3 : tree _q60 = gimple_assign_rhs1 (_a3);
25954 : 3 : _q60 = do_valueize (valueize, _q60);
25955 : 3 : {
25956 : 3 : tree captures[3] ATTRIBUTE_UNUSED = { _q30, _q31, _q60 };
25957 : 3 : if (gimple_simplify_456 (res_op, seq, valueize, type, captures))
25958 : 1 : return true;
25959 : : }
25960 : 2 : break;
25961 : : }
25962 : : default:;
25963 : : }
25964 : : }
25965 : : break;
25966 : 27 : default:;
25967 : : }
25968 : 27 : {
25969 : 27 : tree captures[3] ATTRIBUTE_UNUSED = { _q30, _q31, _p1 };
25970 : 27 : if (gimple_simplify_456 (res_op, seq, valueize, type, captures))
25971 : 2 : return true;
25972 : : }
25973 : : }
25974 : : break;
25975 : : }
25976 : : default:;
25977 : : }
25978 : : }
25979 : : break;
25980 : 379979 : default:;
25981 : : }
25982 : 379979 : switch (TREE_CODE (_p1))
25983 : : {
25984 : 76975 : case SSA_NAME:
25985 : 76975 : if (gimple *_d2 = get_def (valueize, _p1))
25986 : : {
25987 : 74143 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
25988 : 55935 : switch (gimple_assign_rhs_code (_a2))
25989 : : {
25990 : 23879 : CASE_CONVERT:
25991 : 23879 : {
25992 : 23879 : tree _q40 = gimple_assign_rhs1 (_a2);
25993 : 23879 : _q40 = do_valueize (valueize, _q40);
25994 : 23879 : switch (TREE_CODE (_q40))
25995 : : {
25996 : 23879 : case SSA_NAME:
25997 : 23879 : if (gimple *_d3 = get_def (valueize, _q40))
25998 : : {
25999 : 22042 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
26000 : 7930 : switch (gimple_assign_rhs_code (_a3))
26001 : : {
26002 : 13 : case LE_EXPR:
26003 : 13 : {
26004 : 13 : tree _q50 = gimple_assign_rhs1 (_a3);
26005 : 13 : _q50 = do_valueize (valueize, _q50);
26006 : 13 : tree _q51 = gimple_assign_rhs2 (_a3);
26007 : 13 : _q51 = do_valueize (valueize, _q51);
26008 : 13 : if (integer_onep (_q51))
26009 : : {
26010 : 0 : {
26011 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q50, _q51, _q20 };
26012 : 0 : if (gimple_simplify_456 (res_op, seq, valueize, type, captures))
26013 : 0 : return true;
26014 : : }
26015 : : }
26016 : : break;
26017 : : }
26018 : : default:;
26019 : : }
26020 : : }
26021 : : break;
26022 : : default:;
26023 : : }
26024 : : break;
26025 : : }
26026 : 114 : case LE_EXPR:
26027 : 114 : {
26028 : 114 : tree _q40 = gimple_assign_rhs1 (_a2);
26029 : 114 : _q40 = do_valueize (valueize, _q40);
26030 : 114 : tree _q41 = gimple_assign_rhs2 (_a2);
26031 : 114 : _q41 = do_valueize (valueize, _q41);
26032 : 114 : if (integer_onep (_q41))
26033 : : {
26034 : 0 : {
26035 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q40, _q41, _q20 };
26036 : 0 : if (gimple_simplify_456 (res_op, seq, valueize, type, captures))
26037 : 0 : return true;
26038 : : }
26039 : : }
26040 : : break;
26041 : : }
26042 : : default:;
26043 : : }
26044 : : }
26045 : : break;
26046 : 379979 : default:;
26047 : : }
26048 : 379979 : switch (TREE_CODE (_q20))
26049 : : {
26050 : 379871 : case SSA_NAME:
26051 : 379871 : if (gimple *_d2 = get_def (valueize, _q20))
26052 : : {
26053 : 354451 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
26054 : 338828 : switch (gimple_assign_rhs_code (_a2))
26055 : : {
26056 : 2572 : case EQ_EXPR:
26057 : 2572 : {
26058 : 2572 : tree _q30 = gimple_assign_rhs1 (_a2);
26059 : 2572 : _q30 = do_valueize (valueize, _q30);
26060 : 2572 : tree _q31 = gimple_assign_rhs2 (_a2);
26061 : 2572 : _q31 = do_valueize (valueize, _q31);
26062 : 2572 : if (tree_swap_operands_p (_q30, _q31))
26063 : 0 : std::swap (_q30, _q31);
26064 : 2572 : switch (TREE_CODE (_q31))
26065 : : {
26066 : 356 : case INTEGER_CST:
26067 : 356 : {
26068 : 356 : switch (TREE_CODE (_p1))
26069 : : {
26070 : 354 : case SSA_NAME:
26071 : 354 : if (gimple *_d3 = get_def (valueize, _p1))
26072 : : {
26073 : 338 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
26074 : 455 : switch (gimple_assign_rhs_code (_a3))
26075 : : {
26076 : 24 : CASE_CONVERT:
26077 : 24 : {
26078 : 24 : tree _q60 = gimple_assign_rhs1 (_a3);
26079 : 24 : _q60 = do_valueize (valueize, _q60);
26080 : 24 : if ((_q60 == _q30 && ! TREE_SIDE_EFFECTS (_q60)) || (operand_equal_p (_q60, _q30, 0) && types_match (_q60, _q30)))
26081 : : {
26082 : 1 : {
26083 : 1 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q30, _q31 };
26084 : 1 : if (gimple_simplify_459 (res_op, seq, valueize, type, captures))
26085 : 1 : return true;
26086 : : }
26087 : : }
26088 : : break;
26089 : : }
26090 : : default:;
26091 : : }
26092 : : }
26093 : : break;
26094 : 355 : default:;
26095 : : }
26096 : 355 : if ((_p1 == _q30 && ! TREE_SIDE_EFFECTS (_p1)) || (operand_equal_p (_p1, _q30, 0) && types_match (_p1, _q30)))
26097 : : {
26098 : 0 : {
26099 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _p0, _q30, _q31 };
26100 : 0 : if (gimple_simplify_459 (res_op, seq, valueize, type, captures))
26101 : 0 : return true;
26102 : : }
26103 : : }
26104 : : break;
26105 : : }
26106 : : default:;
26107 : : }
26108 : 379978 : break;
26109 : : }
26110 : : default:;
26111 : : }
26112 : : }
26113 : : break;
26114 : 379978 : default:;
26115 : : }
26116 : 379978 : switch (TREE_CODE (_p1))
26117 : : {
26118 : 76974 : case SSA_NAME:
26119 : 76974 : if (gimple *_d2 = get_def (valueize, _p1))
26120 : : {
26121 : 74142 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
26122 : 55934 : switch (gimple_assign_rhs_code (_a2))
26123 : : {
26124 : 23878 : CASE_CONVERT:
26125 : 23878 : {
26126 : 23878 : tree _q40 = gimple_assign_rhs1 (_a2);
26127 : 23878 : _q40 = do_valueize (valueize, _q40);
26128 : 23878 : switch (TREE_CODE (_q40))
26129 : : {
26130 : 23878 : case SSA_NAME:
26131 : 23878 : if (gimple *_d3 = get_def (valueize, _q40))
26132 : : {
26133 : 22041 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
26134 : 7930 : switch (gimple_assign_rhs_code (_a3))
26135 : : {
26136 : 290 : case EQ_EXPR:
26137 : 290 : {
26138 : 290 : tree _q50 = gimple_assign_rhs1 (_a3);
26139 : 290 : _q50 = do_valueize (valueize, _q50);
26140 : 290 : tree _q51 = gimple_assign_rhs2 (_a3);
26141 : 290 : _q51 = do_valueize (valueize, _q51);
26142 : 290 : if (tree_swap_operands_p (_q50, _q51))
26143 : 24 : std::swap (_q50, _q51);
26144 : 290 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
26145 : : {
26146 : 2 : switch (TREE_CODE (_q51))
26147 : : {
26148 : 2 : case INTEGER_CST:
26149 : 2 : {
26150 : 2 : {
26151 : 2 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _q20, _q51 };
26152 : 2 : if (gimple_simplify_460 (res_op, seq, valueize, type, captures))
26153 : 2 : return true;
26154 : : }
26155 : 0 : break;
26156 : : }
26157 : : default:;
26158 : : }
26159 : : }
26160 : 7738453 : break;
26161 : : }
26162 : : default:;
26163 : : }
26164 : : }
26165 : : break;
26166 : : default:;
26167 : : }
26168 : : break;
26169 : : }
26170 : : default:;
26171 : : }
26172 : : }
26173 : : break;
26174 : : default:;
26175 : : }
26176 : : break;
26177 : : }
26178 : : default:;
26179 : : }
26180 : : }
26181 : : break;
26182 : 7738453 : default:;
26183 : : }
26184 : 7738453 : switch (TREE_CODE (_p1))
26185 : : {
26186 : 2716180 : case SSA_NAME:
26187 : 2716180 : if (gimple *_d1 = get_def (valueize, _p1))
26188 : : {
26189 : 2129599 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
26190 : 2066253 : switch (gimple_assign_rhs_code (_a1))
26191 : : {
26192 : 100372 : CASE_CONVERT:
26193 : 100372 : {
26194 : 100372 : tree _q30 = gimple_assign_rhs1 (_a1);
26195 : 100372 : _q30 = do_valueize (valueize, _q30);
26196 : 100372 : switch (TREE_CODE (_q30))
26197 : : {
26198 : 100372 : case SSA_NAME:
26199 : 100372 : if (gimple *_d2 = get_def (valueize, _q30))
26200 : : {
26201 : 97347 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
26202 : 88957 : switch (gimple_assign_rhs_code (_a2))
26203 : : {
26204 : 101 : case LE_EXPR:
26205 : 101 : {
26206 : 101 : tree _q40 = gimple_assign_rhs1 (_a2);
26207 : 101 : _q40 = do_valueize (valueize, _q40);
26208 : 101 : tree _q41 = gimple_assign_rhs2 (_a2);
26209 : 101 : _q41 = do_valueize (valueize, _q41);
26210 : 101 : if (integer_onep (_q41))
26211 : : {
26212 : 0 : {
26213 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q40, _q41, _p0 };
26214 : 0 : if (gimple_simplify_456 (res_op, seq, valueize, type, captures))
26215 : 0 : return true;
26216 : : }
26217 : : }
26218 : : break;
26219 : : }
26220 : 2384 : case EQ_EXPR:
26221 : 2384 : {
26222 : 2384 : tree _q40 = gimple_assign_rhs1 (_a2);
26223 : 2384 : _q40 = do_valueize (valueize, _q40);
26224 : 2384 : tree _q41 = gimple_assign_rhs2 (_a2);
26225 : 2384 : _q41 = do_valueize (valueize, _q41);
26226 : 2384 : if (tree_swap_operands_p (_q40, _q41))
26227 : 24 : std::swap (_q40, _q41);
26228 : 2384 : if ((_q40 == _p0 && ! TREE_SIDE_EFFECTS (_q40)) || (operand_equal_p (_q40, _p0, 0) && types_match (_q40, _p0)))
26229 : : {
26230 : 47 : switch (TREE_CODE (_q41))
26231 : : {
26232 : 47 : case INTEGER_CST:
26233 : 47 : {
26234 : 47 : {
26235 : 47 : tree captures[3] ATTRIBUTE_UNUSED = { _p1, _p0, _q41 };
26236 : 47 : if (gimple_simplify_460 (res_op, seq, valueize, type, captures))
26237 : 47 : return true;
26238 : : }
26239 : 0 : break;
26240 : : }
26241 : : default:;
26242 : : }
26243 : : }
26244 : 7738406 : break;
26245 : : }
26246 : : default:;
26247 : : }
26248 : : }
26249 : : break;
26250 : : default:;
26251 : : }
26252 : : break;
26253 : : }
26254 : 235508 : case LE_EXPR:
26255 : 235508 : {
26256 : 235508 : tree _q30 = gimple_assign_rhs1 (_a1);
26257 : 235508 : _q30 = do_valueize (valueize, _q30);
26258 : 235508 : tree _q31 = gimple_assign_rhs2 (_a1);
26259 : 235508 : _q31 = do_valueize (valueize, _q31);
26260 : 235508 : if (integer_onep (_q31))
26261 : : {
26262 : 863 : {
26263 : 863 : tree captures[3] ATTRIBUTE_UNUSED = { _q30, _q31, _p0 };
26264 : 863 : if (gimple_simplify_456 (res_op, seq, valueize, type, captures))
26265 : 0 : return true;
26266 : : }
26267 : : }
26268 : : break;
26269 : : }
26270 : : default:;
26271 : : }
26272 : : }
26273 : : break;
26274 : 7738406 : default:;
26275 : : }
26276 : 7738406 : switch (TREE_CODE (_p0))
26277 : : {
26278 : 7648646 : case SSA_NAME:
26279 : 7648646 : if (gimple *_d1 = get_def (valueize, _p0))
26280 : : {
26281 : 5315468 : if (gassign *_a1 = dyn_cast <gassign *> (_d1))
26282 : 5654614 : switch (gimple_assign_rhs_code (_a1))
26283 : : {
26284 : 1172 : case ORDERED_EXPR:
26285 : 1172 : {
26286 : 1172 : tree _q20 = gimple_assign_rhs1 (_a1);
26287 : 1172 : _q20 = do_valueize (valueize, _q20);
26288 : 1172 : tree _q21 = gimple_assign_rhs2 (_a1);
26289 : 1172 : _q21 = do_valueize (valueize, _q21);
26290 : 1172 : if (tree_swap_operands_p (_q20, _q21))
26291 : 4 : std::swap (_q20, _q21);
26292 : 1172 : if ((_q21 == _q20 && ! TREE_SIDE_EFFECTS (_q21)) || (operand_equal_p (_q21, _q20, 0) && types_match (_q21, _q20)))
26293 : : {
26294 : 386 : switch (TREE_CODE (_p1))
26295 : : {
26296 : 386 : case SSA_NAME:
26297 : 386 : if (gimple *_d2 = get_def (valueize, _p1))
26298 : : {
26299 : 386 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
26300 : 386 : switch (gimple_assign_rhs_code (_a2))
26301 : : {
26302 : 191 : case ORDERED_EXPR:
26303 : 191 : {
26304 : 191 : tree _q50 = gimple_assign_rhs1 (_a2);
26305 : 191 : _q50 = do_valueize (valueize, _q50);
26306 : 191 : tree _q51 = gimple_assign_rhs2 (_a2);
26307 : 191 : _q51 = do_valueize (valueize, _q51);
26308 : 191 : if (tree_swap_operands_p (_q50, _q51))
26309 : 0 : std::swap (_q50, _q51);
26310 : 191 : if ((_q51 == _q50 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q50, 0) && types_match (_q51, _q50)))
26311 : : {
26312 : 165 : {
26313 : 165 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _q50 };
26314 : 165 : if (types_match (captures[0], captures[1])
26315 : : )
26316 : : {
26317 : 152 : gimple_seq *lseq = seq;
26318 : 152 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2091;
26319 : 152 : {
26320 : 152 : res_op->set_op (ORDERED_EXPR, type, 2);
26321 : 152 : res_op->ops[0] = captures[0];
26322 : 152 : res_op->ops[1] = captures[1];
26323 : 152 : res_op->resimplify (lseq, valueize);
26324 : 152 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1067, __FILE__, __LINE__, true);
26325 : 152 : return true;
26326 : : }
26327 : 0 : next_after_fail2091:;
26328 : : }
26329 : : }
26330 : : }
26331 : 39 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
26332 : : {
26333 : 0 : {
26334 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _p1, _q51 };
26335 : 0 : if (gimple_simplify_461 (res_op, seq, valueize, type, captures))
26336 : 0 : return true;
26337 : : }
26338 : : }
26339 : 39 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
26340 : : {
26341 : 0 : {
26342 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _p1, _q50 };
26343 : 0 : if (gimple_simplify_461 (res_op, seq, valueize, type, captures))
26344 : 0 : return true;
26345 : : }
26346 : : }
26347 : 1020 : break;
26348 : : }
26349 : : default:;
26350 : : }
26351 : : }
26352 : : break;
26353 : : default:;
26354 : : }
26355 : : }
26356 : 1020 : switch (TREE_CODE (_p1))
26357 : : {
26358 : 1020 : case SSA_NAME:
26359 : 1020 : if (gimple *_d2 = get_def (valueize, _p1))
26360 : : {
26361 : 1020 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
26362 : 1020 : switch (gimple_assign_rhs_code (_a2))
26363 : : {
26364 : 41 : case ORDERED_EXPR:
26365 : 41 : {
26366 : 41 : tree _q50 = gimple_assign_rhs1 (_a2);
26367 : 41 : _q50 = do_valueize (valueize, _q50);
26368 : 41 : tree _q51 = gimple_assign_rhs2 (_a2);
26369 : 41 : _q51 = do_valueize (valueize, _q51);
26370 : 41 : if (tree_swap_operands_p (_q50, _q51))
26371 : 0 : std::swap (_q50, _q51);
26372 : 41 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
26373 : : {
26374 : 0 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
26375 : : {
26376 : 0 : {
26377 : 0 : tree captures[3] ATTRIBUTE_UNUSED = { _q20, _p0, _q21 };
26378 : 0 : if (gimple_simplify_462 (res_op, seq, valueize, type, captures))
26379 : 0 : return true;
26380 : : }
26381 : : }
26382 : : }
26383 : 41 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
26384 : : {
26385 : 2 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
26386 : : {
26387 : 2 : {
26388 : 2 : tree captures[3] ATTRIBUTE_UNUSED = { _q21, _p0, _q20 };
26389 : 2 : if (gimple_simplify_462 (res_op, seq, valueize, type, captures))
26390 : 2 : return true;
26391 : : }
26392 : : }
26393 : : }
26394 : 8205480 : break;
26395 : : }
26396 : : default:;
26397 : : }
26398 : : }
26399 : : break;
26400 : : default:;
26401 : : }
26402 : 8205480 : break;
26403 : : }
26404 : 45600 : case MINUS_EXPR:
26405 : 45600 : {
26406 : 45600 : tree _q20 = gimple_assign_rhs1 (_a1);
26407 : 45600 : _q20 = do_valueize (valueize, _q20);
26408 : 45600 : tree _q21 = gimple_assign_rhs2 (_a1);
26409 : 45600 : _q21 = do_valueize (valueize, _q21);
26410 : 45600 : switch (TREE_CODE (_q20))
26411 : : {
26412 : 42918 : case SSA_NAME:
26413 : 42918 : if (gimple *_d2 = get_def (valueize, _q20))
26414 : : {
26415 : 40854 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
26416 : 38233 : switch (gimple_assign_rhs_code (_a2))
26417 : : {
26418 : 15534 : CASE_CONVERT:
26419 : 15534 : {
26420 : 15534 : tree _q30 = gimple_assign_rhs1 (_a2);
26421 : 15534 : _q30 = do_valueize (valueize, _q30);
26422 : 15534 : switch (TREE_CODE (_q21))
26423 : : {
26424 : 15529 : case SSA_NAME:
26425 : 15529 : if (gimple *_d3 = get_def (valueize, _q21))
26426 : : {
26427 : 15503 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
26428 : 6957 : switch (gimple_assign_rhs_code (_a3))
26429 : : {
26430 : 5590 : CASE_CONVERT:
26431 : 5590 : {
26432 : 5590 : tree _q50 = gimple_assign_rhs1 (_a3);
26433 : 5590 : _q50 = do_valueize (valueize, _q50);
26434 : 5590 : switch (TREE_CODE (_p1))
26435 : : {
26436 : 5376 : case INTEGER_CST:
26437 : 5376 : {
26438 : 5376 : {
26439 : 5376 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q21, _q50, _p1 };
26440 : 5376 : if (gimple_simplify_463 (res_op, seq, valueize, type, captures, MINUS_EXPR))
26441 : 182 : return true;
26442 : : }
26443 : 5194 : break;
26444 : : }
26445 : : default:;
26446 : : }
26447 : : break;
26448 : : }
26449 : : default:;
26450 : : }
26451 : : }
26452 : : break;
26453 : : default:;
26454 : : }
26455 : : break;
26456 : : }
26457 : : default:;
26458 : : }
26459 : : }
26460 : : break;
26461 : : default:;
26462 : : }
26463 : : break;
26464 : : }
26465 : 369489 : case PLUS_EXPR:
26466 : 369489 : {
26467 : 369489 : tree _q20 = gimple_assign_rhs1 (_a1);
26468 : 369489 : _q20 = do_valueize (valueize, _q20);
26469 : 369489 : tree _q21 = gimple_assign_rhs2 (_a1);
26470 : 369489 : _q21 = do_valueize (valueize, _q21);
26471 : 369489 : if (tree_swap_operands_p (_q20, _q21))
26472 : 10784 : std::swap (_q20, _q21);
26473 : 369489 : switch (TREE_CODE (_q20))
26474 : : {
26475 : 369489 : case SSA_NAME:
26476 : 369489 : if (gimple *_d2 = get_def (valueize, _q20))
26477 : : {
26478 : 351255 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
26479 : 319190 : switch (gimple_assign_rhs_code (_a2))
26480 : : {
26481 : 39097 : CASE_CONVERT:
26482 : 39097 : {
26483 : 39097 : tree _q30 = gimple_assign_rhs1 (_a2);
26484 : 39097 : _q30 = do_valueize (valueize, _q30);
26485 : 39097 : switch (TREE_CODE (_q21))
26486 : : {
26487 : 9562 : case SSA_NAME:
26488 : 9562 : if (gimple *_d3 = get_def (valueize, _q21))
26489 : : {
26490 : 9445 : if (gassign *_a3 = dyn_cast <gassign *> (_d3))
26491 : 5973 : switch (gimple_assign_rhs_code (_a3))
26492 : : {
26493 : 3429 : CASE_CONVERT:
26494 : 3429 : {
26495 : 3429 : tree _q50 = gimple_assign_rhs1 (_a3);
26496 : 3429 : _q50 = do_valueize (valueize, _q50);
26497 : 3429 : switch (TREE_CODE (_p1))
26498 : : {
26499 : 2971 : case INTEGER_CST:
26500 : 2971 : {
26501 : 2971 : {
26502 : 2971 : tree captures[6] ATTRIBUTE_UNUSED = { _p0, _q20, _q30, _q21, _q50, _p1 };
26503 : 2971 : if (gimple_simplify_463 (res_op, seq, valueize, type, captures, PLUS_EXPR))
26504 : 183 : return true;
26505 : : }
26506 : 2788 : break;
26507 : : }
26508 : : default:;
26509 : : }
26510 : : break;
26511 : : }
26512 : : default:;
26513 : : }
26514 : : }
26515 : : break;
26516 : : default:;
26517 : : }
26518 : : break;
26519 : : }
26520 : : default:;
26521 : : }
26522 : : }
26523 : : break;
26524 : : default:;
26525 : : }
26526 : 8205480 : break;
26527 : : }
26528 : 43284 : case LT_EXPR:
26529 : 43284 : {
26530 : 43284 : tree _q20 = gimple_assign_rhs1 (_a1);
26531 : 43284 : _q20 = do_valueize (valueize, _q20);
26532 : 43284 : tree _q21 = gimple_assign_rhs2 (_a1);
26533 : 43284 : _q21 = do_valueize (valueize, _q21);
26534 : 43284 : switch (TREE_CODE (_p1))
26535 : : {
26536 : 43284 : case SSA_NAME:
26537 : 43284 : if (gimple *_d2 = get_def (valueize, _p1))
26538 : : {
26539 : 43044 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
26540 : 43022 : switch (gimple_assign_rhs_code (_a2))
26541 : : {
26542 : 4021 : case LT_EXPR:
26543 : 4021 : {
26544 : 4021 : tree _q50 = gimple_assign_rhs1 (_a2);
26545 : 4021 : _q50 = do_valueize (valueize, _q50);
26546 : 4021 : tree _q51 = gimple_assign_rhs2 (_a2);
26547 : 4021 : _q51 = do_valueize (valueize, _q51);
26548 : 4021 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
26549 : : {
26550 : 167 : {
26551 : 167 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
26552 : 167 : if (gimple_simplify_164 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, LT_EXPR, MIN_EXPR))
26553 : 14 : return true;
26554 : : }
26555 : : }
26556 : 4007 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
26557 : : {
26558 : 560 : {
26559 : 560 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
26560 : 560 : if (gimple_simplify_164 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, GT_EXPR, MAX_EXPR))
26561 : 0 : return true;
26562 : : }
26563 : : }
26564 : : break;
26565 : : }
26566 : 1424 : case GT_EXPR:
26567 : 1424 : {
26568 : 1424 : tree _q50 = gimple_assign_rhs1 (_a2);
26569 : 1424 : _q50 = do_valueize (valueize, _q50);
26570 : 1424 : tree _q51 = gimple_assign_rhs2 (_a2);
26571 : 1424 : _q51 = do_valueize (valueize, _q51);
26572 : 1424 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
26573 : : {
26574 : 1 : {
26575 : 1 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
26576 : 1 : if (gimple_simplify_164 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, LT_EXPR, MIN_EXPR))
26577 : 0 : return true;
26578 : : }
26579 : : }
26580 : 1424 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
26581 : : {
26582 : 30 : {
26583 : 30 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
26584 : 30 : if (gimple_simplify_164 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, GT_EXPR, MAX_EXPR))
26585 : 9 : return true;
26586 : : }
26587 : : }
26588 : : break;
26589 : : }
26590 : : default:;
26591 : : }
26592 : : }
26593 : : break;
26594 : : default:;
26595 : : }
26596 : : break;
26597 : : }
26598 : 81295 : case LE_EXPR:
26599 : 81295 : {
26600 : 81295 : tree _q20 = gimple_assign_rhs1 (_a1);
26601 : 81295 : _q20 = do_valueize (valueize, _q20);
26602 : 81295 : tree _q21 = gimple_assign_rhs2 (_a1);
26603 : 81295 : _q21 = do_valueize (valueize, _q21);
26604 : 81295 : switch (TREE_CODE (_p1))
26605 : : {
26606 : 81295 : case SSA_NAME:
26607 : 81295 : if (gimple *_d2 = get_def (valueize, _p1))
26608 : : {
26609 : 81076 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
26610 : 80312 : switch (gimple_assign_rhs_code (_a2))
26611 : : {
26612 : 7033 : case LE_EXPR:
26613 : 7033 : {
26614 : 7033 : tree _q50 = gimple_assign_rhs1 (_a2);
26615 : 7033 : _q50 = do_valueize (valueize, _q50);
26616 : 7033 : tree _q51 = gimple_assign_rhs2 (_a2);
26617 : 7033 : _q51 = do_valueize (valueize, _q51);
26618 : 7033 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
26619 : : {
26620 : 563 : {
26621 : 563 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
26622 : 563 : if (gimple_simplify_164 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, LE_EXPR, MIN_EXPR))
26623 : 107 : return true;
26624 : : }
26625 : : }
26626 : 6926 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
26627 : : {
26628 : 1917 : {
26629 : 1917 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
26630 : 1917 : if (gimple_simplify_164 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, GE_EXPR, MAX_EXPR))
26631 : 0 : return true;
26632 : : }
26633 : : }
26634 : : break;
26635 : : }
26636 : 41062 : case GE_EXPR:
26637 : 41062 : {
26638 : 41062 : tree _q50 = gimple_assign_rhs1 (_a2);
26639 : 41062 : _q50 = do_valueize (valueize, _q50);
26640 : 41062 : tree _q51 = gimple_assign_rhs2 (_a2);
26641 : 41062 : _q51 = do_valueize (valueize, _q51);
26642 : 41062 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
26643 : : {
26644 : 89 : {
26645 : 89 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
26646 : 89 : if (gimple_simplify_164 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, LE_EXPR, MIN_EXPR))
26647 : 0 : return true;
26648 : : }
26649 : : }
26650 : 41062 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
26651 : : {
26652 : 9 : {
26653 : 9 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
26654 : 9 : if (gimple_simplify_164 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, GE_EXPR, MAX_EXPR))
26655 : 0 : return true;
26656 : : }
26657 : : }
26658 : : break;
26659 : : }
26660 : : default:;
26661 : : }
26662 : : }
26663 : : break;
26664 : : default:;
26665 : : }
26666 : : break;
26667 : : }
26668 : 105659 : case GT_EXPR:
26669 : 105659 : {
26670 : 105659 : tree _q20 = gimple_assign_rhs1 (_a1);
26671 : 105659 : _q20 = do_valueize (valueize, _q20);
26672 : 105659 : tree _q21 = gimple_assign_rhs2 (_a1);
26673 : 105659 : _q21 = do_valueize (valueize, _q21);
26674 : 105659 : switch (TREE_CODE (_p1))
26675 : : {
26676 : 105659 : case SSA_NAME:
26677 : 105659 : if (gimple *_d2 = get_def (valueize, _p1))
26678 : : {
26679 : 105070 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
26680 : 103446 : switch (gimple_assign_rhs_code (_a2))
26681 : : {
26682 : 34436 : case GT_EXPR:
26683 : 34436 : {
26684 : 34436 : tree _q50 = gimple_assign_rhs1 (_a2);
26685 : 34436 : _q50 = do_valueize (valueize, _q50);
26686 : 34436 : tree _q51 = gimple_assign_rhs2 (_a2);
26687 : 34436 : _q51 = do_valueize (valueize, _q51);
26688 : 34436 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
26689 : : {
26690 : 281 : {
26691 : 281 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
26692 : 281 : if (gimple_simplify_164 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, GT_EXPR, MAX_EXPR))
26693 : 12 : return true;
26694 : : }
26695 : : }
26696 : 34424 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
26697 : : {
26698 : 17300 : {
26699 : 17300 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
26700 : 17300 : if (gimple_simplify_164 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, LT_EXPR, MIN_EXPR))
26701 : 0 : return true;
26702 : : }
26703 : : }
26704 : : break;
26705 : : }
26706 : 2349 : case LT_EXPR:
26707 : 2349 : {
26708 : 2349 : tree _q50 = gimple_assign_rhs1 (_a2);
26709 : 2349 : _q50 = do_valueize (valueize, _q50);
26710 : 2349 : tree _q51 = gimple_assign_rhs2 (_a2);
26711 : 2349 : _q51 = do_valueize (valueize, _q51);
26712 : 2349 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
26713 : : {
26714 : 244 : {
26715 : 244 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
26716 : 244 : if (gimple_simplify_164 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, GT_EXPR, MAX_EXPR))
26717 : 220 : return true;
26718 : : }
26719 : : }
26720 : 2129 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
26721 : : {
26722 : 8 : {
26723 : 8 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
26724 : 8 : if (gimple_simplify_164 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, LT_EXPR, MIN_EXPR))
26725 : 4 : return true;
26726 : : }
26727 : : }
26728 : : break;
26729 : : }
26730 : : default:;
26731 : : }
26732 : : }
26733 : : break;
26734 : : default:;
26735 : : }
26736 : : break;
26737 : : }
26738 : 557049 : case GE_EXPR:
26739 : 557049 : {
26740 : 557049 : tree _q20 = gimple_assign_rhs1 (_a1);
26741 : 557049 : _q20 = do_valueize (valueize, _q20);
26742 : 557049 : tree _q21 = gimple_assign_rhs2 (_a1);
26743 : 557049 : _q21 = do_valueize (valueize, _q21);
26744 : 557049 : switch (TREE_CODE (_p1))
26745 : : {
26746 : 557049 : case SSA_NAME:
26747 : 557049 : if (gimple *_d2 = get_def (valueize, _p1))
26748 : : {
26749 : 555213 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
26750 : 553549 : switch (gimple_assign_rhs_code (_a2))
26751 : : {
26752 : 108903 : case GE_EXPR:
26753 : 108903 : {
26754 : 108903 : tree _q50 = gimple_assign_rhs1 (_a2);
26755 : 108903 : _q50 = do_valueize (valueize, _q50);
26756 : 108903 : tree _q51 = gimple_assign_rhs2 (_a2);
26757 : 108903 : _q51 = do_valueize (valueize, _q51);
26758 : 108903 : if ((_q50 == _q20 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q20, 0) && types_match (_q50, _q20)))
26759 : : {
26760 : 40 : {
26761 : 40 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q51 };
26762 : 40 : if (gimple_simplify_164 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, GE_EXPR, MAX_EXPR))
26763 : 20 : return true;
26764 : : }
26765 : : }
26766 : 108883 : if ((_q51 == _q21 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q21, 0) && types_match (_q51, _q21)))
26767 : : {
26768 : 7016 : {
26769 : 7016 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q50 };
26770 : 7016 : if (gimple_simplify_164 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, LE_EXPR, MIN_EXPR))
26771 : 0 : return true;
26772 : : }
26773 : : }
26774 : : break;
26775 : : }
26776 : 183870 : case LE_EXPR:
26777 : 183870 : {
26778 : 183870 : tree _q50 = gimple_assign_rhs1 (_a2);
26779 : 183870 : _q50 = do_valueize (valueize, _q50);
26780 : 183870 : tree _q51 = gimple_assign_rhs2 (_a2);
26781 : 183870 : _q51 = do_valueize (valueize, _q51);
26782 : 183870 : if ((_q51 == _q20 && ! TREE_SIDE_EFFECTS (_q51)) || (operand_equal_p (_q51, _q20, 0) && types_match (_q51, _q20)))
26783 : : {
26784 : 194 : {
26785 : 194 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q20, _q21, _p1, _q50 };
26786 : 194 : if (gimple_simplify_164 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, GE_EXPR, MAX_EXPR))
26787 : 26 : return true;
26788 : : }
26789 : : }
26790 : 183844 : if ((_q50 == _q21 && ! TREE_SIDE_EFFECTS (_q50)) || (operand_equal_p (_q50, _q21, 0) && types_match (_q50, _q21)))
26791 : : {
26792 : 41 : {
26793 : 41 : tree captures[5] ATTRIBUTE_UNUSED = { _p0, _q21, _q20, _p1, _q51 };
26794 : 41 : if (gimple_simplify_164 (res_op, seq, valueize, type, captures, BIT_AND_EXPR, LE_EXPR, MIN_EXPR))
26795 : 0 : return true;
26796 : : }
26797 : : }
26798 : : break;
26799 : : }
26800 : : default:;
26801 : : }
26802 : : }
26803 : : break;
26804 : : default:;
26805 : : }
26806 : : break;
26807 : : }
26808 : 52704 : case NEGATE_EXPR:
26809 : 52704 : {
26810 : 52704 : tree _q20 = gimple_assign_rhs1 (_a1);
26811 : 52704 : _q20 = do_valueize (valueize, _q20);
26812 : 52704 : if (integer_onep (_p1))
26813 : : {
26814 : 204 : {
26815 : 204 : tree captures[2] ATTRIBUTE_UNUSED = { _q20, _p1 };
26816 : 204 : if (!TYPE_OVERFLOW_SANITIZED (type)
26817 : : )
26818 : : {
26819 : 204 : gimple_seq *lseq = seq;
26820 : 204 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2092;
26821 : 204 : {
26822 : 204 : res_op->set_op (BIT_AND_EXPR, type, 2);
26823 : 204 : res_op->ops[0] = captures[0];
26824 : 204 : res_op->ops[1] = captures[1];
26825 : 204 : res_op->resimplify (lseq, valueize);
26826 : 204 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 1068, __FILE__, __LINE__, true);
26827 : 204 : return true;
26828 : : }
26829 : 0 : next_after_fail2092:;
26830 : : }
26831 : : }
26832 : : }
26833 : : break;
26834 : : }
26835 : 492 : case VEC_PERM_EXPR:
26836 : 492 : {
26837 : 492 : tree _q20 = gimple_assign_rhs1 (_a1);
26838 : 492 : _q20 = do_valueize (valueize, _q20);
26839 : 492 : tree _q21 = gimple_assign_rhs2 (_a1);
26840 : 492 : _q21 = do_valueize (valueize, _q21);
26841 : 492 : tree _q22 = gimple_assign_rhs3 (_a1);
26842 : 492 : _q22 = do_valueize (valueize, _q22);
26843 : 492 : if ((_q21 == _q20 && ! TREE_SIDE_EFFECTS (_q21)) || (operand_equal_p (_q21, _q20, 0) && types_match (_q21, _q20)))
26844 : : {
26845 : 342 : switch (TREE_CODE (_p1))
26846 : : {
26847 : 342 : case SSA_NAME:
26848 : 342 : if (gimple *_d2 = get_def (valueize, _p1))
26849 : : {
26850 : 271 : if (gassign *_a2 = dyn_cast <gassign *> (_d2))
26851 : 93 : switch (gimple_assign_rhs_code (_a2))
26852 : : {
26853 : 2 : case VEC_PERM_EXPR:
26854 : 2 : {
26855 : 2 : tree _q60 = gimple_assign_rhs1 (_a2);
26856 : 2 : _q60 = do_valueize (valueize, _q60);
26857 : 2 : tree _q61 = gimple_assign_rhs2 (_a2);
26858 : 2 : _q61 = do_valueize (valueize, _q61);
26859 : 2 : tree _q62 = gimple_assign_rhs3 (_a2);
26860 : 2 : _q62 = do_valueize (valueize, _q62);
26861 : 2 : if ((_q61 == _q60 && ! TREE_SIDE_EFFECTS (_q61)) || (operand_equal_p (_q61, _q60, 0) && types_match (_q61, _q60)))
26862 : : {
26863 : 2 : if ((_q62 == _q22 && ! TREE_SIDE_EFFECTS (_q62)) || (operand_equal_p (_q62, _q22, 0) && types_match (_q62, _q22)))
26864 : : {
26865 : 2 : {
26866 : 2 : tree captures[4] ATTRIBUTE_UNUSED = { _q20, _q22, _q60 };
26867 : 2 : if (VECTOR_INTEGER_TYPE_P (type)
26868 : : )
26869 : : {
26870 : 2 : gimple_seq *lseq = seq;
26871 : 2 : if (UNLIKELY (!dbg_cnt (match))) goto next_after_fail2093;
26872 : 2 : {
26873 : 2 : res_op->set_op (VEC_PERM_EXPR, type, 3);
26874 : 2 : {
26875 : 2 : tree _o1[2], _r1;
26876 : 2 : _o1[0] = captures[0];
26877 : 2 : _o1[1] = captures[2];
26878 : 2 : gimple_match_op tem_op (res_op->cond.any_else (), BIT_AND_EXPR, TREE_TYPE (_o1[0]), _o1[0], _o1[1]);
26879 : 2 : tem_op.resimplify (lseq, valueize);
26880 : 2 : _r1 = maybe_push_res_to_seq (&tem_op, lseq);
26881 : 2 : if (!_r1) goto next_after_fail2093;
26882 : 1 : captures[3] = _r1;
26883 : : }
26884 : 1 : res_op->ops[0] = captures[3];
26885 : 1 : res_op->ops[1] = captures[3];
26886 : 1 : res_op->ops[2] = captures[1];
26887 : 1 : res_op->resimplify (lseq, valueize);
26888 : 1 : if (UNLIKELY (debug_dump)) gimple_dump_logs ("match.pd", 928, __FILE__, __LINE__, true);
26889 : 1 : return true;
26890 : : }
26891 : : next_after_fail2093:;
26892 : : }
26893 : : }
26894 : : }
26895 : : }
26896 : : break;
26897 : : }
26898 : : default:;
26899 : : }
26900 : : }
26901 : : break;
26902 : : default:;
26903 : : }
26904 : : }
26905 : : break;
26906 : : }
26907 : : default:;
26908 : : }
26909 : 1042132 : else if (gcall *_c1 = dyn_cast <gcall *> (_d1))
26910 : 126046 : switch (gimple_call_combined_fn (_c1))
26911 : : {
26912 : 16 : case CFN_BUILT_IN_POPCOUNT:
26913 : 16 : if (gimple_call_num_args (_c1) == 1)
26914 : : {
26915 : 16 : tree _q20 = gimple_call_arg (_c1, 0);
26916 : 16 : _q20 = do_valueize (valueize, _q20);
26917 : 16 : if (integer_onep (_p1))
26918 : : {
26919 : 0 : {
26920 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
26921 : 0 : if (gimple_simplify_464 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_POPCOUNT, CFN_BUILT_IN_PARITY))
26922 : 0 : return true;
26923 : : }
26924 : : }
26925 : : }
26926 : : break;
26927 : 0 : case CFN_BUILT_IN_POPCOUNTLL:
26928 : 0 : if (gimple_call_num_args (_c1) == 1)
26929 : : {
26930 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
26931 : 0 : _q20 = do_valueize (valueize, _q20);
26932 : 0 : if (integer_onep (_p1))
26933 : : {
26934 : 0 : {
26935 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
26936 : 0 : if (gimple_simplify_464 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_POPCOUNTLL, CFN_BUILT_IN_PARITYLL))
26937 : 0 : return true;
26938 : : }
26939 : : }
26940 : : }
26941 : : break;
26942 : 0 : case CFN_POPCOUNT:
26943 : 0 : if (gimple_call_num_args (_c1) == 1)
26944 : : {
26945 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
26946 : 0 : _q20 = do_valueize (valueize, _q20);
26947 : 0 : if (integer_onep (_p1))
26948 : : {
26949 : 0 : {
26950 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
26951 : 0 : if (gimple_simplify_464 (res_op, seq, valueize, type, captures, CFN_POPCOUNT, CFN_PARITY))
26952 : 0 : return true;
26953 : : }
26954 : : }
26955 : : }
26956 : : break;
26957 : 0 : case CFN_BUILT_IN_POPCOUNTIMAX:
26958 : 0 : if (gimple_call_num_args (_c1) == 1)
26959 : : {
26960 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
26961 : 0 : _q20 = do_valueize (valueize, _q20);
26962 : 0 : if (integer_onep (_p1))
26963 : : {
26964 : 0 : {
26965 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
26966 : 0 : if (gimple_simplify_464 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_POPCOUNTIMAX, CFN_BUILT_IN_PARITYIMAX))
26967 : 0 : return true;
26968 : : }
26969 : : }
26970 : : }
26971 : : break;
26972 : 0 : case CFN_BUILT_IN_POPCOUNTL:
26973 : 0 : if (gimple_call_num_args (_c1) == 1)
26974 : : {
26975 : 0 : tree _q20 = gimple_call_arg (_c1, 0);
26976 : 0 : _q20 = do_valueize (valueize, _q20);
26977 : 0 : if (integer_onep (_p1))
26978 : : {
26979 : 0 : {
26980 : 0 : tree captures[1] ATTRIBUTE_UNUSED = { _q20 };
26981 : 0 : if (gimple_simplify_464 (res_op, seq, valueize, type, captures, CFN_BUILT_IN_POPCOUNTL, CFN_BUILT_IN_PARITYL))
26982 : 0 : return true;
26983 : : }
26984 : : }
26985 : : }
26986 : : break;
26987 : : default:;
26988 : : }
26989 : : }
26990 : : break;
26991 : : default:;
26992 : : }
26993 : : return false;
26994 : : }
26995 : : #pragma GCC diagnostic pop
|