1/*===- TableGen'erated file -------------------------------------*- C++ -*-===*\
2|* *|
3|* X86PreLegalizerCombinerImpl Combiner Match Table *|
4|* *|
5|* Automatically generated file, do not edit! *|
6|* *|
7\*===----------------------------------------------------------------------===*/
8
9#ifdef GET_GICOMBINER_DEPS
10
11#include "llvm/ADT/SparseBitVector.h"
12namespace llvm {
13
14extern cl::OptionCategory GICombinerOptionCategory;
15
16} // namespace llvm
17
18#endif // GET_GICOMBINER_DEPS
19
20#ifdef GET_GICOMBINER_TYPES
21
22struct X86PreLegalizerCombinerImplRuleConfig {
23 SparseBitVector<> DisabledRules;
24
25 bool isRuleEnabled(unsigned RuleID) const;
26 bool parseCommandLineOption();
27 bool setRuleEnabled(StringRef RuleIdentifier);
28 bool setRuleDisabled(StringRef RuleIdentifier);
29};
30
31static std::optional<uint64_t> getRuleIdxForIdentifier(StringRef RuleIdentifier) {
32 uint64_t I;
33 // getAtInteger(...) returns false on success
34 bool Parsed = !RuleIdentifier.getAsInteger(0, I);
35 if (Parsed)
36 return I;
37
38#ifndef NDEBUG
39 switch (RuleIdentifier.size()) {
40 default: break;
41 case 9: // 3 strings to match.
42 switch (RuleIdentifier[0]) {
43 default: break;
44 case 'c': // 1 string to match.
45 if (memcmp(RuleIdentifier.data()+1, "opy_prop", 8) != 0)
46 break;
47 return 57; // "copy_prop"
48 case 'm': // 2 strings to match.
49 if (memcmp(RuleIdentifier.data()+1, "ulo_by_", 7) != 0)
50 break;
51 switch (RuleIdentifier[8]) {
52 default: break;
53 case '0': // 1 string to match.
54 return 41; // "mulo_by_0"
55 case '2': // 1 string to match.
56 return 40; // "mulo_by_2"
57 }
58 break;
59 }
60 break;
61 case 10: // 4 strings to match.
62 switch (RuleIdentifier[0]) {
63 default: break;
64 case 'i': // 1 string to match.
65 if (memcmp(RuleIdentifier.data()+1, "2p_to_p2i", 9) != 0)
66 break;
67 return 7; // "i2p_to_p2i"
68 case 'm': // 1 string to match.
69 if (memcmp(RuleIdentifier.data()+1, "ul_to_shl", 9) != 0)
70 break;
71 return 58; // "mul_to_shl"
72 case 'p': // 1 string to match.
73 if (memcmp(RuleIdentifier.data()+1, "2i_to_i2p", 9) != 0)
74 break;
75 return 6; // "p2i_to_i2p"
76 case 's': // 1 string to match.
77 if (memcmp(RuleIdentifier.data()+1, "ub_to_add", 9) != 0)
78 break;
79 return 59; // "sub_to_add"
80 }
81 break;
82 case 11: // 1 string to match.
83 if (memcmp(RuleIdentifier.data()+0, "add_sub_reg", 11) != 0)
84 break;
85 return 12; // "add_sub_reg"
86 case 12: // 1 string to match.
87 if (memcmp(RuleIdentifier.data()+0, "adde_to_addo", 12) != 0)
88 break;
89 return 42; // "adde_to_addo"
90 case 13: // 1 string to match.
91 if (memcmp(RuleIdentifier.data()+0, "same_val_zero", 13) != 0)
92 break;
93 return 3; // "same_val_zero"
94 case 14: // 4 strings to match.
95 switch (RuleIdentifier[0]) {
96 default: break;
97 case 'b': // 1 string to match.
98 if (memcmp(RuleIdentifier.data()+1, "inop_same_val", 13) != 0)
99 break;
100 return 2; // "binop_same_val"
101 case 'f': // 1 string to match.
102 if (memcmp(RuleIdentifier.data()+1, "neg_fneg_fold", 13) != 0)
103 break;
104 return 9; // "fneg_fneg_fold"
105 case 'm': // 1 string to match.
106 if (memcmp(RuleIdentifier.data()+1, "ul_by_neg_one", 13) != 0)
107 break;
108 return 61; // "mul_by_neg_one"
109 case 'r': // 1 string to match.
110 if (memcmp(RuleIdentifier.data()+1, "eassoc_ptradd", 13) != 0)
111 break;
112 return 21; // "reassoc_ptradd"
113 }
114 break;
115 case 15: // 3 strings to match.
116 switch (RuleIdentifier[0]) {
117 default: break;
118 case 'i': // 1 string to match.
119 if (memcmp(RuleIdentifier.data()+1, "dempotent_prop", 14) != 0)
120 break;
121 return 62; // "idempotent_prop"
122 case 'o': // 1 string to match.
123 if (memcmp(RuleIdentifier.data()+1, "verlapping_and", 14) != 0)
124 break;
125 return 39; // "overlapping_and"
126 case 's': // 1 string to match.
127 if (memcmp(RuleIdentifier.data()+1, "elect_same_val", 14) != 0)
128 break;
129 return 0; // "select_same_val"
130 }
131 break;
132 case 16: // 1 string to match.
133 if (memcmp(RuleIdentifier.data()+0, "undef_to_fp_zero", 16) != 0)
134 break;
135 return 45; // "undef_to_fp_zero"
136 case 17: // 4 strings to match.
137 switch (RuleIdentifier[0]) {
138 default: break;
139 case 'a': // 2 strings to match.
140 switch (RuleIdentifier[1]) {
141 default: break;
142 case 'd': // 1 string to match.
143 if (memcmp(RuleIdentifier.data()+2, "d_p2i_to_ptradd", 15) != 0)
144 break;
145 return 60; // "add_p2i_to_ptradd"
146 case 'n': // 1 string to match.
147 if (memcmp(RuleIdentifier.data()+2, "yext_trunc_fold", 15) != 0)
148 break;
149 return 8; // "anyext_trunc_fold"
150 }
151 break;
152 case 'e': // 1 string to match.
153 if (memcmp(RuleIdentifier.data()+1, "rase_undef_store", 16) != 0)
154 break;
155 return 55; // "erase_undef_store"
156 case 'u': // 1 string to match.
157 if (memcmp(RuleIdentifier.data()+1, "ndef_to_int_zero", 16) != 0)
158 break;
159 return 46; // "undef_to_int_zero"
160 }
161 break;
162 case 18: // 6 strings to match.
163 switch (RuleIdentifier[0]) {
164 default: break;
165 case 'b': // 1 string to match.
166 if (memcmp(RuleIdentifier.data()+1, "inop_left_to_zero", 17) != 0)
167 break;
168 return 4; // "binop_left_to_zero"
169 case 'c': // 3 strings to match.
170 if (RuleIdentifier[1] != 'o')
171 break;
172 switch (RuleIdentifier[2]) {
173 default: break;
174 case 'm': // 1 string to match.
175 if (memcmp(RuleIdentifier.data()+3, "bine_minmax_nan", 15) != 0)
176 break;
177 return 43; // "combine_minmax_nan"
178 case 'n': // 2 strings to match.
179 if (memcmp(RuleIdentifier.data()+3, "stant_fold_f", 12) != 0)
180 break;
181 switch (RuleIdentifier[15]) {
182 default: break;
183 case 'a': // 1 string to match.
184 if (memcmp(RuleIdentifier.data()+16, "bs", 2) != 0)
185 break;
186 return 24; // "constant_fold_fabs"
187 case 'n': // 1 string to match.
188 if (memcmp(RuleIdentifier.data()+16, "eg", 2) != 0)
189 break;
190 return 23; // "constant_fold_fneg"
191 }
192 break;
193 }
194 break;
195 case 'e': // 1 string to match.
196 if (memcmp(RuleIdentifier.data()+1, "xpand_const_fpowi", 17) != 0)
197 break;
198 return 44; // "expand_const_fpowi"
199 case 'f': // 1 string to match.
200 if (memcmp(RuleIdentifier.data()+1, "ptrunc_fpext_fold", 17) != 0)
201 break;
202 return 17; // "fptrunc_fpext_fold"
203 }
204 break;
205 case 19: // 11 strings to match.
206 switch (RuleIdentifier[0]) {
207 default: break;
208 case 'b': // 1 string to match.
209 if (memcmp(RuleIdentifier.data()+1, "inop_right_to_zero", 18) != 0)
210 break;
211 return 5; // "binop_right_to_zero"
212 case 'c': // 6 strings to match.
213 if (memcmp(RuleIdentifier.data()+1, "onst", 4) != 0)
214 break;
215 switch (RuleIdentifier[5]) {
216 default: break;
217 case '_': // 1 string to match.
218 if (memcmp(RuleIdentifier.data()+6, "ptradd_to_i2p", 13) != 0)
219 break;
220 return 38; // "const_ptradd_to_i2p"
221 case 'a': // 5 strings to match.
222 if (memcmp(RuleIdentifier.data()+6, "nt_fold_f", 9) != 0)
223 break;
224 switch (RuleIdentifier[15]) {
225 default: break;
226 case 'c': // 1 string to match.
227 if (memcmp(RuleIdentifier.data()+16, "eil", 3) != 0)
228 break;
229 return 29; // "constant_fold_fceil"
230 case 'l': // 1 string to match.
231 if (memcmp(RuleIdentifier.data()+16, "og2", 3) != 0)
232 break;
233 return 26; // "constant_fold_flog2"
234 case 'p': // 1 string to match.
235 if (memcmp(RuleIdentifier.data()+16, "ext", 3) != 0)
236 break;
237 return 28; // "constant_fold_fpext"
238 case 'r': // 1 string to match.
239 if (memcmp(RuleIdentifier.data()+16, "int", 3) != 0)
240 break;
241 return 34; // "constant_fold_frint"
242 case 's': // 1 string to match.
243 if (memcmp(RuleIdentifier.data()+16, "qrt", 3) != 0)
244 break;
245 return 25; // "constant_fold_fsqrt"
246 }
247 break;
248 }
249 break;
250 case 'r': // 2 strings to match.
251 switch (RuleIdentifier[1]) {
252 default: break;
253 case 'e': // 1 string to match.
254 if (memcmp(RuleIdentifier.data()+2, "assoc_comm_binops", 17) != 0)
255 break;
256 return 22; // "reassoc_comm_binops"
257 case 'i': // 1 string to match.
258 if (memcmp(RuleIdentifier.data()+2, "ght_identity_zero", 17) != 0)
259 break;
260 return 1; // "right_identity_zero"
261 }
262 break;
263 case 's': // 1 string to match.
264 if (memcmp(RuleIdentifier.data()+1, "implify_add_to_sub", 18) != 0)
265 break;
266 return 63; // "simplify_add_to_sub"
267 case 'u': // 1 string to match.
268 if (memcmp(RuleIdentifier.data()+1, "nary_undef_to_zero", 18) != 0)
269 break;
270 return 50; // "unary_undef_to_zero"
271 }
272 break;
273 case 20: // 3 strings to match.
274 switch (RuleIdentifier[0]) {
275 default: break;
276 case 'b': // 1 string to match.
277 if (memcmp(RuleIdentifier.data()+1, "itcast_bitcast_fold", 19) != 0)
278 break;
279 return 16; // "bitcast_bitcast_fold"
280 case 'c': // 1 string to match.
281 if (memcmp(RuleIdentifier.data()+1, "onstant_fold_ffloor", 19) != 0)
282 break;
283 return 30; // "constant_fold_ffloor"
284 case 'u': // 1 string to match.
285 if (memcmp(RuleIdentifier.data()+1, "nary_undef_to_undef", 19) != 0)
286 break;
287 return 51; // "unary_undef_to_undef"
288 }
289 break;
290 case 21: // 3 strings to match.
291 switch (RuleIdentifier[0]) {
292 default: break;
293 case 'c': // 1 string to match.
294 if (memcmp(RuleIdentifier.data()+1, "onstant_fold_fptrunc", 20) != 0)
295 break;
296 return 27; // "constant_fold_fptrunc"
297 case 'r': // 1 string to match.
298 if (memcmp(RuleIdentifier.data()+1, "ight_identity_one_fp", 20) != 0)
299 break;
300 return 11; // "right_identity_one_fp"
301 case 'u': // 1 string to match.
302 if (memcmp(RuleIdentifier.data()+1, "ndef_to_negative_one", 20) != 0)
303 break;
304 return 47; // "undef_to_negative_one"
305 }
306 break;
307 case 22: // 3 strings to match.
308 switch (RuleIdentifier[0]) {
309 default: break;
310 case 'p': // 1 string to match.
311 if (memcmp(RuleIdentifier.data()+1, "ropagate_undef_any_op", 21) != 0)
312 break;
313 return 52; // "propagate_undef_any_op"
314 case 'r': // 1 string to match.
315 if (memcmp(RuleIdentifier.data()+1, "ight_identity_one_int", 21) != 0)
316 break;
317 return 10; // "right_identity_one_int"
318 case 't': // 1 string to match.
319 if (memcmp(RuleIdentifier.data()+1, "runc_buildvector_fold", 21) != 0)
320 break;
321 return 14; // "trunc_buildvector_fold"
322 }
323 break;
324 case 23: // 3 strings to match.
325 switch (RuleIdentifier[0]) {
326 default: break;
327 case 'i': // 2 strings to match.
328 if (memcmp(RuleIdentifier.data()+1, "tof_const_zero_fold_", 20) != 0)
329 break;
330 switch (RuleIdentifier[21]) {
331 default: break;
332 case 's': // 1 string to match.
333 if (RuleIdentifier[22] != 'i')
334 break;
335 return 36; // "itof_const_zero_fold_si"
336 case 'u': // 1 string to match.
337 if (RuleIdentifier[22] != 'i')
338 break;
339 return 37; // "itof_const_zero_fold_ui"
340 }
341 break;
342 case 'p': // 1 string to match.
343 if (memcmp(RuleIdentifier.data()+1, "ropagate_undef_all_ops", 22) != 0)
344 break;
345 return 53; // "propagate_undef_all_ops"
346 }
347 break;
348 case 24: // 2 strings to match.
349 switch (RuleIdentifier[0]) {
350 default: break;
351 case 'b': // 1 string to match.
352 if (memcmp(RuleIdentifier.data()+1, "inop_left_undef_to_zero", 23) != 0)
353 break;
354 return 48; // "binop_left_undef_to_zero"
355 case 'c': // 1 string to match.
356 if (memcmp(RuleIdentifier.data()+1, "onstant_fold_fnearbyint", 23) != 0)
357 break;
358 return 35; // "constant_fold_fnearbyint"
359 }
360 break;
361 case 25: // 2 strings to match.
362 switch (RuleIdentifier[0]) {
363 default: break;
364 case 'b': // 1 string to match.
365 if (memcmp(RuleIdentifier.data()+1, "uildvector_identity_fold", 24) != 0)
366 break;
367 return 13; // "buildvector_identity_fold"
368 case 'r': // 1 string to match.
369 if (memcmp(RuleIdentifier.data()+1, "ight_identity_neg_one_fp", 24) != 0)
370 break;
371 return 20; // "right_identity_neg_one_fp"
372 }
373 break;
374 case 26: // 2 strings to match.
375 switch (RuleIdentifier[0]) {
376 default: break;
377 case 'b': // 1 string to match.
378 if (memcmp(RuleIdentifier.data()+1, "inop_right_undef_to_undef", 25) != 0)
379 break;
380 return 49; // "binop_right_undef_to_undef"
381 case 'r': // 1 string to match.
382 if (memcmp(RuleIdentifier.data()+1, "ight_identity_neg_zero_fp", 25) != 0)
383 break;
384 return 18; // "right_identity_neg_zero_fp"
385 }
386 break;
387 case 27: // 1 string to match.
388 if (memcmp(RuleIdentifier.data()+0, "trunc_lshr_buildvector_fold", 27) != 0)
389 break;
390 return 15; // "trunc_lshr_buildvector_fold"
391 case 28: // 1 string to match.
392 if (memcmp(RuleIdentifier.data()+0, "propagate_undef_shuffle_mask", 28) != 0)
393 break;
394 return 54; // "propagate_undef_shuffle_mask"
395 case 29: // 2 strings to match.
396 if (memcmp(RuleIdentifier.data()+0, "constant_fold_intrinsic_", 24) != 0)
397 break;
398 switch (RuleIdentifier[24]) {
399 default: break;
400 case 'r': // 1 string to match.
401 if (memcmp(RuleIdentifier.data()+25, "ound", 4) != 0)
402 break;
403 return 32; // "constant_fold_intrinsic_round"
404 case 't': // 1 string to match.
405 if (memcmp(RuleIdentifier.data()+25, "runc", 4) != 0)
406 break;
407 return 31; // "constant_fold_intrinsic_trunc"
408 }
409 break;
410 case 30: // 1 string to match.
411 if (memcmp(RuleIdentifier.data()+0, "right_identity_neg_zero_fp_nsz", 30) != 0)
412 break;
413 return 19; // "right_identity_neg_zero_fp_nsz"
414 case 33: // 1 string to match.
415 if (memcmp(RuleIdentifier.data()+0, "constant_fold_intrinsic_roundeven", 33) != 0)
416 break;
417 return 33; // "constant_fold_intrinsic_roundeven"
418 case 36: // 1 string to match.
419 if (memcmp(RuleIdentifier.data()+0, "insert_extract_vec_elt_out_of_bounds", 36) != 0)
420 break;
421 return 56; // "insert_extract_vec_elt_out_of_bounds"
422 }
423#endif // ifndef NDEBUG
424
425 return std::nullopt;
426}
427static std::optional<std::pair<uint64_t, uint64_t>> getRuleRangeForIdentifier(StringRef RuleIdentifier) {
428 std::pair<StringRef, StringRef> RangePair = RuleIdentifier.split('-');
429 if (!RangePair.second.empty()) {
430 const auto First = getRuleIdxForIdentifier(RangePair.first);
431 const auto Last = getRuleIdxForIdentifier(RangePair.second);
432 if (!First || !Last)
433 return std::nullopt;
434 if (First >= Last)
435 report_fatal_error("Beginning of range should be before end of range");
436 return {{*First, *Last + 1}};
437 }
438 if (RangePair.first == "*") {
439 return {{0, 64}};
440 }
441 const auto I = getRuleIdxForIdentifier(RangePair.first);
442 if (!I)
443 return std::nullopt;
444 return {{*I, *I + 1}};
445}
446
447bool X86PreLegalizerCombinerImplRuleConfig::setRuleEnabled(StringRef RuleIdentifier) {
448 auto MaybeRange = getRuleRangeForIdentifier(RuleIdentifier);
449 if (!MaybeRange)
450 return false;
451 for (auto I = MaybeRange->first; I < MaybeRange->second; ++I)
452 DisabledRules.reset(I);
453 return true;
454}
455
456bool X86PreLegalizerCombinerImplRuleConfig::setRuleDisabled(StringRef RuleIdentifier) {
457 auto MaybeRange = getRuleRangeForIdentifier(RuleIdentifier);
458 if (!MaybeRange)
459 return false;
460 for (auto I = MaybeRange->first; I < MaybeRange->second; ++I)
461 DisabledRules.set(I);
462 return true;
463}
464
465static std::vector<std::string> X86PreLegalizerCombinerOption;
466static cl::list<std::string> X86PreLegalizerCombinerDisableOption(
467 "x86prelegalizercombiner-disable-rule",
468 cl::desc("Disable one or more combiner rules temporarily in the X86PreLegalizerCombiner pass"),
469 cl::CommaSeparated,
470 cl::Hidden,
471 cl::cat(GICombinerOptionCategory),
472 cl::callback([](const std::string &Str) {
473 X86PreLegalizerCombinerOption.push_back(Str);
474 }));
475static cl::list<std::string> X86PreLegalizerCombinerOnlyEnableOption(
476 "x86prelegalizercombiner-only-enable-rule",
477 cl::desc("Disable all rules in the X86PreLegalizerCombiner pass then re-enable the specified ones"),
478 cl::Hidden,
479 cl::cat(GICombinerOptionCategory),
480 cl::callback([](const std::string &CommaSeparatedArg) {
481 StringRef Str = CommaSeparatedArg;
482 X86PreLegalizerCombinerOption.push_back("*");
483 do {
484 auto X = Str.split(",");
485 X86PreLegalizerCombinerOption.push_back(("!" + X.first).str());
486 Str = X.second;
487 } while (!Str.empty());
488 }));
489
490
491bool X86PreLegalizerCombinerImplRuleConfig::isRuleEnabled(unsigned RuleID) const {
492 return !DisabledRules.test(RuleID);
493}
494bool X86PreLegalizerCombinerImplRuleConfig::parseCommandLineOption() {
495 for (StringRef Identifier : X86PreLegalizerCombinerOption) {
496 bool Enabled = Identifier.consume_front("!");
497 if (Enabled && !setRuleEnabled(Identifier))
498 return false;
499 if (!Enabled && !setRuleDisabled(Identifier))
500 return false;
501 }
502 return true;
503}
504
505
506#endif // GET_GICOMBINER_TYPES
507
508#ifdef GET_GICOMBINER_TYPES
509
510const unsigned MAX_SUBTARGET_PREDICATES = 0;
511using PredicateBitset = llvm::Bitset<MAX_SUBTARGET_PREDICATES>;
512
513#endif // GET_GICOMBINER_TYPES
514
515#ifdef GET_GICOMBINER_CLASS_MEMBERS
516
517PredicateBitset AvailableModuleFeatures;
518mutable PredicateBitset AvailableFunctionFeatures;
519PredicateBitset getAvailableFeatures() const {
520 return AvailableModuleFeatures | AvailableFunctionFeatures;
521}
522PredicateBitset
523computeAvailableModuleFeatures(const X86Subtarget *Subtarget) const;
524PredicateBitset
525computeAvailableFunctionFeatures(const X86Subtarget *Subtarget,
526 const MachineFunction *MF) const;
527void setupGeneratedPerFunctionState(MachineFunction &MF) override;
528
529#endif // GET_GICOMBINER_CLASS_MEMBERS
530
531#ifdef GET_GICOMBINER_CLASS_MEMBERS
532
533 mutable MatcherState State;
534 typedef ComplexRendererFns(X86PreLegalizerCombinerImpl::*ComplexMatcherMemFn)(MachineOperand &) const;
535 typedef void(X86PreLegalizerCombinerImpl::*CustomRendererFn)(MachineInstrBuilder &, const MachineInstr &, int) const;
536 const ExecInfoTy<PredicateBitset, ComplexMatcherMemFn, CustomRendererFn> ExecInfo;
537 static X86PreLegalizerCombinerImpl::ComplexMatcherMemFn ComplexPredicateFns[];
538 static X86PreLegalizerCombinerImpl::CustomRendererFn CustomRenderers[];
539 bool testImmPredicate_I64(unsigned PredicateID, int64_t Imm) const override;
540 bool testImmPredicate_APInt(unsigned PredicateID, const APInt &Imm) const override;
541 bool testImmPredicate_APFloat(unsigned PredicateID, const APFloat &Imm) const override;
542 const uint8_t *getMatchTable() const override;
543 bool testMIPredicate_MI(unsigned PredicateID, const MachineInstr &MI, const MatcherState &State) const override;
544 bool testMOPredicate_MO(unsigned PredicateID, const MachineOperand &MO, const MatcherState &State) const override;
545 bool testSimplePredicate(unsigned PredicateID) const override;
546 bool runCustomAction(unsigned FnID, const MatcherState &State, NewMIVector &OutMIs) const override;
547
548#endif // GET_GICOMBINER_CLASS_MEMBERS
549
550#ifdef GET_GICOMBINER_IMPL
551
552// LLT Objects.
553enum {
554 GILLT_s1,
555};
556const static size_t NumTypeObjects = 1;
557const static LLT TypeObjects[] = {
558 LLT::scalar(1),
559};
560
561// Bits for subtarget features that participate in instruction matching.
562enum SubtargetFeatureBits : uint8_t {
563};
564
565PredicateBitset X86PreLegalizerCombinerImpl::
566computeAvailableModuleFeatures(const X86Subtarget *Subtarget) const {
567 PredicateBitset Features{};
568 return Features;
569}
570
571void X86PreLegalizerCombinerImpl::setupGeneratedPerFunctionState(MachineFunction &MF) {
572 AvailableFunctionFeatures = computeAvailableFunctionFeatures((const X86Subtarget *)&MF.getSubtarget(), &MF);
573}
574PredicateBitset X86PreLegalizerCombinerImpl::
575computeAvailableFunctionFeatures(const X86Subtarget *Subtarget, const MachineFunction *MF) const {
576 PredicateBitset Features{};
577 return Features;
578}
579
580// Feature bitsets.
581enum {
582 GIFBS_Invalid,
583};
584constexpr static PredicateBitset FeatureBitsets[] {
585 {}, // GIFBS_Invalid
586};
587
588// ComplexPattern predicates.
589enum {
590 GICP_Invalid,
591};
592// See constructor for table contents
593
594X86PreLegalizerCombinerImpl::ComplexMatcherMemFn
595X86PreLegalizerCombinerImpl::ComplexPredicateFns[] = {
596 nullptr, // GICP_Invalid
597};
598
599enum {
600 GICXXPred_MI_Predicate_GICombiner0 = GICXXPred_Invalid + 1,
601 GICXXPred_MI_Predicate_GICombiner1,
602 GICXXPred_MI_Predicate_GICombiner2,
603 GICXXPred_MI_Predicate_GICombiner3,
604};
605bool X86PreLegalizerCombinerImpl::testMIPredicate_MI(unsigned PredicateID, const MachineInstr & MI, const MatcherState &State) const {
606 switch (PredicateID) {
607 case GICXXPred_MI_Predicate_GICombiner0: {
608 return Helper.matchConstantFPOp(State.MIs[0]->getOperand(2), 1.0);
609 }
610 case GICXXPred_MI_Predicate_GICombiner1: {
611 return Helper.matchConstantFPOp(State.MIs[0]->getOperand(2), -0.0);
612 }
613 case GICXXPred_MI_Predicate_GICombiner2: {
614 return Helper.matchConstantFPOp(State.MIs[0]->getOperand(2), 0.0);
615 }
616 case GICXXPred_MI_Predicate_GICombiner3: {
617 return Helper.matchConstantFPOp(State.MIs[0]->getOperand(2), -1.0);
618 }
619 }
620 llvm_unreachable("Unknown predicate");
621 return false;
622}
623bool X86PreLegalizerCombinerImpl::testMOPredicate_MO(unsigned PredicateID, const MachineOperand & MO, const MatcherState &State) const {
624 llvm_unreachable("Unknown predicate");
625 return false;
626}
627bool X86PreLegalizerCombinerImpl::testImmPredicate_I64(unsigned PredicateID, int64_t Imm) const {
628 llvm_unreachable("Unknown predicate");
629 return false;
630}
631bool X86PreLegalizerCombinerImpl::testImmPredicate_APFloat(unsigned PredicateID, const APFloat & Imm) const {
632 llvm_unreachable("Unknown predicate");
633 return false;
634}
635bool X86PreLegalizerCombinerImpl::testImmPredicate_APInt(unsigned PredicateID, const APInt & Imm) const {
636 llvm_unreachable("Unknown predicate");
637 return false;
638}
639enum {
640 GICXXPred_Simple_IsRule0Enabled = GICXXPred_Invalid + 1,
641 GICXXPred_Simple_IsRule1Enabled,
642 GICXXPred_Simple_IsRule2Enabled,
643 GICXXPred_Simple_IsRule3Enabled,
644 GICXXPred_Simple_IsRule4Enabled,
645 GICXXPred_Simple_IsRule5Enabled,
646 GICXXPred_Simple_IsRule6Enabled,
647 GICXXPred_Simple_IsRule7Enabled,
648 GICXXPred_Simple_IsRule8Enabled,
649 GICXXPred_Simple_IsRule9Enabled,
650 GICXXPred_Simple_IsRule10Enabled,
651 GICXXPred_Simple_IsRule11Enabled,
652 GICXXPred_Simple_IsRule12Enabled,
653 GICXXPred_Simple_IsRule13Enabled,
654 GICXXPred_Simple_IsRule14Enabled,
655 GICXXPred_Simple_IsRule15Enabled,
656 GICXXPred_Simple_IsRule16Enabled,
657 GICXXPred_Simple_IsRule17Enabled,
658 GICXXPred_Simple_IsRule18Enabled,
659 GICXXPred_Simple_IsRule19Enabled,
660 GICXXPred_Simple_IsRule20Enabled,
661 GICXXPred_Simple_IsRule21Enabled,
662 GICXXPred_Simple_IsRule22Enabled,
663 GICXXPred_Simple_IsRule23Enabled,
664 GICXXPred_Simple_IsRule24Enabled,
665 GICXXPred_Simple_IsRule25Enabled,
666 GICXXPred_Simple_IsRule26Enabled,
667 GICXXPred_Simple_IsRule27Enabled,
668 GICXXPred_Simple_IsRule28Enabled,
669 GICXXPred_Simple_IsRule29Enabled,
670 GICXXPred_Simple_IsRule30Enabled,
671 GICXXPred_Simple_IsRule31Enabled,
672 GICXXPred_Simple_IsRule32Enabled,
673 GICXXPred_Simple_IsRule33Enabled,
674 GICXXPred_Simple_IsRule34Enabled,
675 GICXXPred_Simple_IsRule35Enabled,
676 GICXXPred_Simple_IsRule36Enabled,
677 GICXXPred_Simple_IsRule37Enabled,
678 GICXXPred_Simple_IsRule38Enabled,
679 GICXXPred_Simple_IsRule39Enabled,
680 GICXXPred_Simple_IsRule40Enabled,
681 GICXXPred_Simple_IsRule41Enabled,
682 GICXXPred_Simple_IsRule42Enabled,
683 GICXXPred_Simple_IsRule43Enabled,
684 GICXXPred_Simple_IsRule44Enabled,
685 GICXXPred_Simple_IsRule45Enabled,
686 GICXXPred_Simple_IsRule46Enabled,
687 GICXXPred_Simple_IsRule47Enabled,
688 GICXXPred_Simple_IsRule48Enabled,
689 GICXXPred_Simple_IsRule49Enabled,
690 GICXXPred_Simple_IsRule50Enabled,
691 GICXXPred_Simple_IsRule51Enabled,
692 GICXXPred_Simple_IsRule52Enabled,
693 GICXXPred_Simple_IsRule53Enabled,
694 GICXXPred_Simple_IsRule54Enabled,
695 GICXXPred_Simple_IsRule55Enabled,
696 GICXXPred_Simple_IsRule56Enabled,
697 GICXXPred_Simple_IsRule57Enabled,
698 GICXXPred_Simple_IsRule58Enabled,
699 GICXXPred_Simple_IsRule59Enabled,
700 GICXXPred_Simple_IsRule60Enabled,
701 GICXXPred_Simple_IsRule61Enabled,
702 GICXXPred_Simple_IsRule62Enabled,
703 GICXXPred_Simple_IsRule63Enabled,
704};
705
706bool X86PreLegalizerCombinerImpl::testSimplePredicate(unsigned Predicate) const {
707 return RuleConfig.isRuleEnabled(Predicate - GICXXPred_Invalid - 1);
708}
709// Custom renderers.
710enum {
711 GICR_Invalid,
712};
713X86PreLegalizerCombinerImpl::CustomRendererFn
714X86PreLegalizerCombinerImpl::CustomRenderers[] = {
715 nullptr, // GICR_Invalid
716};
717
718bool X86PreLegalizerCombinerImpl::tryCombineAllImpl(MachineInstr &I) const {
719 const TargetSubtargetInfo &ST = MF.getSubtarget();
720 const PredicateBitset AvailableFeatures = getAvailableFeatures();
721 B.setInstrAndDebugLoc(I);
722 State.MIs.clear();
723 State.MIs.push_back(&I);
724 if (executeMatchTable(*this, State, ExecInfo, B, getMatchTable(), *ST.getInstrInfo(), MRI, *MRI.getTargetRegisterInfo(), *ST.getRegBankInfo(), AvailableFeatures, /*CoverageInfo*/ nullptr)) {
725 return true;
726 }
727
728 return false;
729}
730
731enum {
732 GICXXCustomAction_GICombiner0 = GICXXCustomAction_Invalid + 1,
733 GICXXCustomAction_GICombiner1,
734 GICXXCustomAction_GICombiner2,
735 GICXXCustomAction_GICombiner3,
736 GICXXCustomAction_GICombiner4,
737 GICXXCustomAction_GICombiner5,
738 GICXXCustomAction_GICombiner6,
739 GICXXCustomAction_GICombiner7,
740 GICXXCustomAction_GICombiner8,
741 GICXXCustomAction_GICombiner9,
742 GICXXCustomAction_GICombiner10,
743 GICXXCustomAction_GICombiner11,
744 GICXXCustomAction_GICombiner12,
745 GICXXCustomAction_GICombiner13,
746 GICXXCustomAction_GICombiner14,
747 GICXXCustomAction_GICombiner15,
748 GICXXCustomAction_GICombiner16,
749 GICXXCustomAction_GICombiner17,
750 GICXXCustomAction_GICombiner18,
751 GICXXCustomAction_GICombiner19,
752 GICXXCustomAction_GICombiner20,
753 GICXXCustomAction_GICombiner21,
754 GICXXCustomAction_GICombiner22,
755 GICXXCustomAction_GICombiner23,
756 GICXXCustomAction_GICombiner24,
757 GICXXCustomAction_GICombiner25,
758 GICXXCustomAction_GICombiner26,
759 GICXXCustomAction_GICombiner27,
760 GICXXCustomAction_GICombiner28,
761 GICXXCustomAction_GICombiner29,
762 GICXXCustomAction_GICombiner30,
763 GICXXCustomAction_GICombiner31,
764 GICXXCustomAction_GICombiner32,
765 GICXXCustomAction_GICombiner33,
766 GICXXCustomAction_GICombiner34,
767};
768bool X86PreLegalizerCombinerImpl::runCustomAction(unsigned ApplyID, const MatcherState &State, NewMIVector &OutMIs) const {
769 Helper.getBuilder().setInstrAndDebugLoc(*State.MIs[0]);
770 switch(ApplyID) {
771 case GICXXCustomAction_GICombiner0:{
772 // Match Patterns
773 if(![&](){return Helper.matchSelectSameVal(*State.MIs[0]);}()) {
774 return false;
775 }
776 // Apply Patterns
777 Helper.replaceSingleDefInstWithOperand(*State.MIs[0], 2);
778 return true;
779 }
780 case GICXXCustomAction_GICombiner1:{
781 Register GIMatchData_info;
782 // Match Patterns
783 if(![&](){return Helper.matchCombineI2PToP2I(*State.MIs[0], GIMatchData_info);}()) {
784 return false;
785 }
786 // Apply Patterns
787 Helper.applyCombineI2PToP2I(*State.MIs[0], GIMatchData_info);
788 return true;
789 }
790 case GICXXCustomAction_GICombiner2:{
791 Register GIMatchData_info;
792 // Match Patterns
793 if(![&](){GIMatchData_info = State.MIs[1]->getOperand(1).getReg(); return true;}()) {
794 return false;
795 }
796 // Apply Patterns
797 Helper.applyCombineP2IToI2P(*State.MIs[0], GIMatchData_info);
798 return true;
799 }
800 case GICXXCustomAction_GICombiner3:{
801 Register GIMatchData_matchinfo;
802 // Match Patterns
803 if(![&](){return Helper.matchCombineAnyExtTrunc(*State.MIs[0], GIMatchData_matchinfo);}()) {
804 return false;
805 }
806 // Apply Patterns
807 Helper.replaceSingleDefInstWithReg(*State.MIs[0], GIMatchData_matchinfo);
808 return true;
809 }
810 case GICXXCustomAction_GICombiner4:{
811 Register GIMatchData_matchinfo;
812 // Match Patterns
813 if(![&](){return Helper.matchBuildVectorIdentityFold(*State.MIs[0], GIMatchData_matchinfo);}()) {
814 return false;
815 }
816 // Apply Patterns
817 Helper.replaceSingleDefInstWithReg(*State.MIs[0], GIMatchData_matchinfo);
818 return true;
819 }
820 case GICXXCustomAction_GICombiner5:{
821 Register GIMatchData_matchinfo;
822 // Match Patterns
823 if(![&](){return Helper.matchTruncBuildVectorFold(*State.MIs[0], GIMatchData_matchinfo);}()) {
824 return false;
825 }
826 // Apply Patterns
827 Helper.replaceSingleDefInstWithReg(*State.MIs[0], GIMatchData_matchinfo);
828 return true;
829 }
830 case GICXXCustomAction_GICombiner6:{
831 Register GIMatchData_matchinfo;
832 // Match Patterns
833 if(![&](){return Helper.matchTruncLshrBuildVectorFold(*State.MIs[0], GIMatchData_matchinfo);}()) {
834 return false;
835 }
836 // Apply Patterns
837 Helper.replaceSingleDefInstWithReg(*State.MIs[0], GIMatchData_matchinfo);
838 return true;
839 }
840 case GICXXCustomAction_GICombiner7:{
841 // Match Patterns
842 if(![&](){return MRI.getType(State.MIs[1]->getOperand(1).getReg()) == MRI.getType(State.MIs[0]->getOperand(0).getReg());}()) {
843 return false;
844 }
845 // Apply Patterns
846 Helper.replaceSingleDefInstWithReg(*State.MIs[0], State.MIs[1]->getOperand(1).getReg());
847 return true;
848 }
849 case GICXXCustomAction_GICombiner8:{
850 std::function<void(MachineIRBuilder &)> GIMatchData_matchinfo;
851 // Match Patterns
852 if(![&](){return Helper.matchReassocPtrAdd(*State.MIs[0], GIMatchData_matchinfo);}()) {
853 return false;
854 }
855 // Apply Patterns
856 Helper.applyBuildFnNoErase(*State.MIs[0], GIMatchData_matchinfo);
857 return true;
858 }
859 case GICXXCustomAction_GICombiner9:{
860 std::function<void(MachineIRBuilder &)> GIMatchData_matchinfo;
861 // Match Patterns
862 if(![&](){return Helper.matchReassocCommBinOp(*State.MIs[0], GIMatchData_matchinfo);}()) {
863 return false;
864 }
865 // Apply Patterns
866 Helper.applyBuildFn(*State.MIs[0], GIMatchData_matchinfo);
867 return true;
868 }
869 case GICXXCustomAction_GICombiner10:{
870 // Apply Patterns
871 Helper.applyCombineConstantFoldFpUnary(*State.MIs[0], State.MIs[1]->getOperand(1).getFPImm());
872 return true;
873 }
874 case GICXXCustomAction_GICombiner11:{
875 // Apply Patterns
876 Helper.replaceInstWithFConstant(*State.MIs[0]->getOperand(0).getParent(), 0.0);
877 return true;
878 }
879 case GICXXCustomAction_GICombiner12:{
880 APInt GIMatchData_info;
881 // Match Patterns
882 if(![&](){return Helper.matchCombineConstPtrAddToI2P(*State.MIs[0], GIMatchData_info);}()) {
883 return false;
884 }
885 // Apply Patterns
886 Helper.applyCombineConstPtrAddToI2P(*State.MIs[0], GIMatchData_info);
887 return true;
888 }
889 case GICXXCustomAction_GICombiner13:{
890 std::function<void(MachineIRBuilder &)> GIMatchData_info;
891 // Match Patterns
892 if(![&](){return Helper.matchOverlappingAnd(*State.MIs[0], GIMatchData_info);}()) {
893 return false;
894 }
895 // Apply Patterns
896 Helper.applyBuildFn(*State.MIs[0], GIMatchData_info);
897 return true;
898 }
899 case GICXXCustomAction_GICombiner14:{
900 std::function<void(MachineIRBuilder &)> GIMatchData_matchinfo;
901 // Match Patterns
902 if(![&](){return Helper.matchMulOBy2(*State.MIs[0], GIMatchData_matchinfo);}()) {
903 return false;
904 }
905 // Apply Patterns
906 Helper.applyBuildFnNoErase(*State.MIs[0], GIMatchData_matchinfo);
907 return true;
908 }
909 case GICXXCustomAction_GICombiner15:{
910 std::function<void(MachineIRBuilder &)> GIMatchData_matchinfo;
911 // Match Patterns
912 if(![&](){return Helper.matchMulOBy0(*State.MIs[0], GIMatchData_matchinfo);}()) {
913 return false;
914 }
915 // Apply Patterns
916 Helper.applyBuildFn(*State.MIs[0], GIMatchData_matchinfo);
917 return true;
918 }
919 case GICXXCustomAction_GICombiner16:{
920 std::function<void(MachineIRBuilder &)> GIMatchData_matchinfo;
921 // Match Patterns
922 if(![&](){return Helper.matchAddEToAddO(*State.MIs[0], GIMatchData_matchinfo);}()) {
923 return false;
924 }
925 // Apply Patterns
926 Helper.applyBuildFnNoErase(*State.MIs[0], GIMatchData_matchinfo);
927 return true;
928 }
929 case GICXXCustomAction_GICombiner17:{
930 unsigned GIMatchData_info;
931 // Match Patterns
932 if(![&](){return Helper.matchCombineFMinMaxNaN(*State.MIs[0], GIMatchData_info);}()) {
933 return false;
934 }
935 // Apply Patterns
936 Helper.replaceSingleDefInstWithOperand(*State.MIs[0], GIMatchData_info);
937 return true;
938 }
939 case GICXXCustomAction_GICombiner18:{
940 // Match Patterns
941 if(![&](){return Helper.matchFPowIExpansion(*State.MIs[0], State.MIs[1]->getOperand(1).getCImm()->getSExtValue());}()) {
942 return false;
943 }
944 // Apply Patterns
945 Helper.applyExpandFPowI(*State.MIs[0], State.MIs[1]->getOperand(1).getCImm()->getSExtValue());
946 return true;
947 }
948 case GICXXCustomAction_GICombiner19:{
949 // Match Patterns
950 if(![&](){return Helper.matchAnyExplicitUseIsUndef(*State.MIs[0]);}()) {
951 return false;
952 }
953 // Apply Patterns
954 Helper.replaceInstWithFConstant(*State.MIs[0], 0.0);
955 return true;
956 }
957 case GICXXCustomAction_GICombiner20:{
958 // Match Patterns
959 if(![&](){return Helper.matchAnyExplicitUseIsUndef(*State.MIs[0]);}()) {
960 return false;
961 }
962 // Apply Patterns
963 Helper.replaceInstWithConstant(*State.MIs[0], 0);
964 return true;
965 }
966 case GICXXCustomAction_GICombiner21:{
967 // Match Patterns
968 if(![&](){return Helper.matchAnyExplicitUseIsUndef(*State.MIs[0]);}()) {
969 return false;
970 }
971 // Apply Patterns
972 Helper.replaceInstWithConstant(*State.MIs[0], -1);
973 return true;
974 }
975 case GICXXCustomAction_GICombiner22:{
976 // Match Patterns
977 if(![&](){return Helper.matchOperandIsUndef(*State.MIs[0], 1);}()) {
978 return false;
979 }
980 // Apply Patterns
981 Helper.replaceInstWithConstant(*State.MIs[0], 0);
982 return true;
983 }
984 case GICXXCustomAction_GICombiner23:{
985 // Match Patterns
986 if(![&](){return Helper.matchOperandIsUndef(*State.MIs[0], 2);}()) {
987 return false;
988 }
989 // Apply Patterns
990 Helper.replaceInstWithUndef(*State.MIs[0]);
991 return true;
992 }
993 case GICXXCustomAction_GICombiner24:{
994 // Apply Patterns
995 Helper.replaceInstWithUndef(*State.MIs[0]->getOperand(0).getParent());
996 return true;
997 }
998 case GICXXCustomAction_GICombiner25:{
999 // Match Patterns
1000 if(![&](){return Helper.matchAnyExplicitUseIsUndef(*State.MIs[0]);}()) {
1001 return false;
1002 }
1003 // Apply Patterns
1004 Helper.replaceInstWithUndef(*State.MIs[0]);
1005 return true;
1006 }
1007 case GICXXCustomAction_GICombiner26:{
1008 // Match Patterns
1009 if(![&](){return Helper.matchAllExplicitUsesAreUndef(*State.MIs[0]);}()) {
1010 return false;
1011 }
1012 // Apply Patterns
1013 Helper.replaceInstWithUndef(*State.MIs[0]);
1014 return true;
1015 }
1016 case GICXXCustomAction_GICombiner27:{
1017 // Match Patterns
1018 if(![&](){return Helper.matchUndefShuffleVectorMask(*State.MIs[0]);}()) {
1019 return false;
1020 }
1021 // Apply Patterns
1022 Helper.replaceInstWithUndef(*State.MIs[0]);
1023 return true;
1024 }
1025 case GICXXCustomAction_GICombiner28:{
1026 // Match Patterns
1027 if(![&](){return Helper.matchUndefStore(*State.MIs[0]);}()) {
1028 return false;
1029 }
1030 // Apply Patterns
1031 Helper.eraseInst(*State.MIs[0]);
1032 return true;
1033 }
1034 case GICXXCustomAction_GICombiner29:{
1035 // Match Patterns
1036 if(![&](){return Helper.matchInsertExtractVecEltOutOfBounds(*State.MIs[0]);}()) {
1037 return false;
1038 }
1039 // Apply Patterns
1040 Helper.replaceInstWithUndef(*State.MIs[0]);
1041 return true;
1042 }
1043 case GICXXCustomAction_GICombiner30:{
1044 // Match Patterns
1045 if(![&](){return Helper.matchCombineCopy(*State.MIs[0]);}()) {
1046 return false;
1047 }
1048 // Apply Patterns
1049 Helper.applyCombineCopy(*State.MIs[0]);
1050 return true;
1051 }
1052 case GICXXCustomAction_GICombiner31:{
1053 unsigned GIMatchData_matchinfo;
1054 // Match Patterns
1055 if(![&](){return Helper.matchCombineMulToShl(*State.MIs[0], GIMatchData_matchinfo);}()) {
1056 return false;
1057 }
1058 // Apply Patterns
1059 Helper.applyCombineMulToShl(*State.MIs[0], GIMatchData_matchinfo);
1060 return true;
1061 }
1062 case GICXXCustomAction_GICombiner32:{
1063 std::function<void(MachineIRBuilder &)> GIMatchData_matchinfo;
1064 // Match Patterns
1065 if(![&](){return Helper.matchCombineSubToAdd(*State.MIs[0], GIMatchData_matchinfo);}()) {
1066 return false;
1067 }
1068 // Apply Patterns
1069 Helper.applyBuildFnNoErase(*State.MIs[0], GIMatchData_matchinfo);
1070 return true;
1071 }
1072 case GICXXCustomAction_GICombiner33:{
1073 std::pair<Register, bool> GIMatchData_info;
1074 // Match Patterns
1075 if(![&](){return Helper.matchCombineAddP2IToPtrAdd(*State.MIs[0], GIMatchData_info);}()) {
1076 return false;
1077 }
1078 // Apply Patterns
1079 Helper.applyCombineAddP2IToPtrAdd(*State.MIs[0], GIMatchData_info);
1080 return true;
1081 }
1082 case GICXXCustomAction_GICombiner34:{
1083 std::tuple<Register, Register> GIMatchData_info;
1084 // Match Patterns
1085 if(![&](){return Helper.matchSimplifyAddToSub(*State.MIs[0], GIMatchData_info);}()) {
1086 return false;
1087 }
1088 // Apply Patterns
1089 Helper.applySimplifyAddToSub(*State.MIs[0], GIMatchData_info);
1090 return true;
1091 }
1092 }
1093 llvm_unreachable("Unknown Apply Action");
1094}
1095#if __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
1096#define GIMT_Encode2(Val) uint8_t(Val), uint8_t((Val) >> 8)
1097#define GIMT_Encode4(Val) uint8_t(Val), uint8_t((Val) >> 8), uint8_t((Val) >> 16), uint8_t((Val) >> 24)
1098#define GIMT_Encode8(Val) uint8_t(Val), uint8_t((Val) >> 8), uint8_t((Val) >> 16), uint8_t((Val) >> 24), uint8_t(uint64_t(Val) >> 32), uint8_t(uint64_t(Val) >> 40), uint8_t(uint64_t(Val) >> 48), uint8_t(uint64_t(Val) >> 56)
1099#else
1100#define GIMT_Encode2(Val) uint8_t((Val) >> 8), uint8_t(Val)
1101#define GIMT_Encode4(Val) uint8_t((Val) >> 24), uint8_t((Val) >> 16), uint8_t((Val) >> 8), uint8_t(Val)
1102#define GIMT_Encode8(Val) uint8_t(uint64_t(Val) >> 56), uint8_t(uint64_t(Val) >> 48), uint8_t(uint64_t(Val) >> 40), uint8_t(uint64_t(Val) >> 32), uint8_t((Val) >> 24), uint8_t((Val) >> 16), uint8_t((Val) >> 8), uint8_t(Val)
1103#endif
1104const uint8_t *X86PreLegalizerCombinerImpl::getMatchTable() const {
1105 constexpr static uint8_t MatchTable0[] = {
1106 /* 0 */ GIM_SwitchOpcode, /*MI*/0, /*[*/GIMT_Encode2(20), GIMT_Encode2(280), /*)*//*default:*//*Label 62*/ GIMT_Encode4(3236),
1107 /* 10 */ /*TargetOpcode::COPY*//*Label 0*/ GIMT_Encode4(1050), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0),
1108 /* 150 */ /*TargetOpcode::G_ADD*//*Label 1*/ GIMT_Encode4(1062),
1109 /* 154 */ /*TargetOpcode::G_SUB*//*Label 2*/ GIMT_Encode4(1198),
1110 /* 158 */ /*TargetOpcode::G_MUL*//*Label 3*/ GIMT_Encode4(1293),
1111 /* 162 */ /*TargetOpcode::G_SDIV*//*Label 4*/ GIMT_Encode4(1442),
1112 /* 166 */ /*TargetOpcode::G_UDIV*//*Label 5*/ GIMT_Encode4(1483),
1113 /* 170 */ /*TargetOpcode::G_SREM*//*Label 6*/ GIMT_Encode4(1535),
1114 /* 174 */ /*TargetOpcode::G_UREM*//*Label 7*/ GIMT_Encode4(1576), GIMT_Encode4(0), GIMT_Encode4(0),
1115 /* 186 */ /*TargetOpcode::G_AND*//*Label 8*/ GIMT_Encode4(1628),
1116 /* 190 */ /*TargetOpcode::G_OR*//*Label 9*/ GIMT_Encode4(1675),
1117 /* 194 */ /*TargetOpcode::G_XOR*//*Label 10*/ GIMT_Encode4(1734), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0),
1118 /* 262 */ /*TargetOpcode::G_BUILD_VECTOR*//*Label 11*/ GIMT_Encode4(1808),
1119 /* 266 */ /*TargetOpcode::G_BUILD_VECTOR_TRUNC*//*Label 12*/ GIMT_Encode4(1831), GIMT_Encode4(0),
1120 /* 274 */ /*TargetOpcode::G_PTRTOINT*//*Label 13*/ GIMT_Encode4(1843),
1121 /* 278 */ /*TargetOpcode::G_INTTOPTR*//*Label 14*/ GIMT_Encode4(1886),
1122 /* 282 */ /*TargetOpcode::G_BITCAST*//*Label 15*/ GIMT_Encode4(1919),
1123 /* 286 */ /*TargetOpcode::G_FREEZE*//*Label 16*/ GIMT_Encode4(1962), GIMT_Encode4(0), GIMT_Encode4(0),
1124 /* 298 */ /*TargetOpcode::G_INTRINSIC_TRUNC*//*Label 17*/ GIMT_Encode4(1992),
1125 /* 302 */ /*TargetOpcode::G_INTRINSIC_ROUND*//*Label 18*/ GIMT_Encode4(2014), GIMT_Encode4(0), GIMT_Encode4(0),
1126 /* 314 */ /*TargetOpcode::G_INTRINSIC_ROUNDEVEN*//*Label 19*/ GIMT_Encode4(2036), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0),
1127 /* 350 */ /*TargetOpcode::G_STORE*//*Label 20*/ GIMT_Encode4(2058), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0),
1128 /* 486 */ /*TargetOpcode::G_ANYEXT*//*Label 21*/ GIMT_Encode4(2070),
1129 /* 490 */ /*TargetOpcode::G_TRUNC*//*Label 22*/ GIMT_Encode4(2103), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0),
1130 /* 534 */ /*TargetOpcode::G_SHL*//*Label 23*/ GIMT_Encode4(2147),
1131 /* 538 */ /*TargetOpcode::G_LSHR*//*Label 24*/ GIMT_Encode4(2233),
1132 /* 542 */ /*TargetOpcode::G_ASHR*//*Label 25*/ GIMT_Encode4(2308), GIMT_Encode4(0), GIMT_Encode4(0),
1133 /* 554 */ /*TargetOpcode::G_ROTR*//*Label 26*/ GIMT_Encode4(2383),
1134 /* 558 */ /*TargetOpcode::G_ROTL*//*Label 27*/ GIMT_Encode4(2407), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0),
1135 /* 578 */ /*TargetOpcode::G_SELECT*//*Label 28*/ GIMT_Encode4(2431), GIMT_Encode4(0),
1136 /* 586 */ /*TargetOpcode::G_UADDE*//*Label 29*/ GIMT_Encode4(2443), GIMT_Encode4(0),
1137 /* 594 */ /*TargetOpcode::G_USUBE*//*Label 30*/ GIMT_Encode4(2455), GIMT_Encode4(0),
1138 /* 602 */ /*TargetOpcode::G_SADDE*//*Label 31*/ GIMT_Encode4(2467), GIMT_Encode4(0),
1139 /* 610 */ /*TargetOpcode::G_SSUBE*//*Label 32*/ GIMT_Encode4(2479),
1140 /* 614 */ /*TargetOpcode::G_UMULO*//*Label 33*/ GIMT_Encode4(2491),
1141 /* 618 */ /*TargetOpcode::G_SMULO*//*Label 34*/ GIMT_Encode4(2514), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0),
1142 /* 686 */ /*TargetOpcode::G_FADD*//*Label 35*/ GIMT_Encode4(2537), GIMT_Encode4(0),
1143 /* 694 */ /*TargetOpcode::G_FMUL*//*Label 36*/ GIMT_Encode4(2590), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0),
1144 /* 722 */ /*TargetOpcode::G_FPOWI*//*Label 37*/ GIMT_Encode4(2634), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0),
1145 /* 742 */ /*TargetOpcode::G_FLOG2*//*Label 38*/ GIMT_Encode4(2656), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0),
1146 /* 758 */ /*TargetOpcode::G_FNEG*//*Label 39*/ GIMT_Encode4(2678),
1147 /* 762 */ /*TargetOpcode::G_FPEXT*//*Label 40*/ GIMT_Encode4(2729),
1148 /* 766 */ /*TargetOpcode::G_FPTRUNC*//*Label 41*/ GIMT_Encode4(2751),
1149 /* 770 */ /*TargetOpcode::G_FPTOSI*//*Label 42*/ GIMT_Encode4(2794),
1150 /* 774 */ /*TargetOpcode::G_FPTOUI*//*Label 43*/ GIMT_Encode4(2816),
1151 /* 778 */ /*TargetOpcode::G_SITOFP*//*Label 44*/ GIMT_Encode4(2838),
1152 /* 782 */ /*TargetOpcode::G_UITOFP*//*Label 45*/ GIMT_Encode4(2865), GIMT_Encode4(0), GIMT_Encode4(0),
1153 /* 794 */ /*TargetOpcode::G_FABS*//*Label 46*/ GIMT_Encode4(2892), GIMT_Encode4(0), GIMT_Encode4(0),
1154 /* 806 */ /*TargetOpcode::G_FCANONICALIZE*//*Label 47*/ GIMT_Encode4(2943),
1155 /* 810 */ /*TargetOpcode::G_FMINNUM*//*Label 48*/ GIMT_Encode4(2973),
1156 /* 814 */ /*TargetOpcode::G_FMAXNUM*//*Label 49*/ GIMT_Encode4(2985), GIMT_Encode4(0), GIMT_Encode4(0),
1157 /* 826 */ /*TargetOpcode::G_FMINIMUM*//*Label 50*/ GIMT_Encode4(2997),
1158 /* 830 */ /*TargetOpcode::G_FMAXIMUM*//*Label 51*/ GIMT_Encode4(3009), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0),
1159 /* 874 */ /*TargetOpcode::G_PTR_ADD*//*Label 52*/ GIMT_Encode4(3021), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0),
1160 /* 898 */ /*TargetOpcode::G_ABS*//*Label 53*/ GIMT_Encode4(3067), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0),
1161 /* 930 */ /*TargetOpcode::G_INSERT_VECTOR_ELT*//*Label 54*/ GIMT_Encode4(3079),
1162 /* 934 */ /*TargetOpcode::G_EXTRACT_VECTOR_ELT*//*Label 55*/ GIMT_Encode4(3091),
1163 /* 938 */ /*TargetOpcode::G_SHUFFLE_VECTOR*//*Label 56*/ GIMT_Encode4(3103), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0),
1164 /* 986 */ /*TargetOpcode::G_FCEIL*//*Label 57*/ GIMT_Encode4(3126), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0), GIMT_Encode4(0),
1165 /* 1034 */ /*TargetOpcode::G_FSQRT*//*Label 58*/ GIMT_Encode4(3148),
1166 /* 1038 */ /*TargetOpcode::G_FFLOOR*//*Label 59*/ GIMT_Encode4(3170),
1167 /* 1042 */ /*TargetOpcode::G_FRINT*//*Label 60*/ GIMT_Encode4(3192),
1168 /* 1046 */ /*TargetOpcode::G_FNEARBYINT*//*Label 61*/ GIMT_Encode4(3214),
1169 /* 1050 */ // Label 0: @1050
1170 /* 1050 */ GIM_Try, /*On fail goto*//*Label 63*/ GIMT_Encode4(1061), // Rule ID 101 //
1171 /* 1055 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule57Enabled),
1172 /* 1058 */ // MIs[0] d
1173 /* 1058 */ // No operand predicates
1174 /* 1058 */ // MIs[0] s
1175 /* 1058 */ // No operand predicates
1176 /* 1058 */ // Combiner Rule #57: copy_prop
1177 /* 1058 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner30),
1178 /* 1061 */ // Label 63: @1061
1179 /* 1061 */ GIM_Reject,
1180 /* 1062 */ // Label 1: @1062
1181 /* 1062 */ GIM_Try, /*On fail goto*//*Label 64*/ GIMT_Encode4(1073), // Rule ID 92 //
1182 /* 1067 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule52Enabled),
1183 /* 1070 */ // Combiner Rule #52: propagate_undef_any_op; wip_match_opcode 'G_ADD'
1184 /* 1070 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner25),
1185 /* 1073 */ // Label 64: @1073
1186 /* 1073 */ GIM_Try, /*On fail goto*//*Label 65*/ GIMT_Encode4(1084), // Rule ID 104 //
1187 /* 1078 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule60Enabled),
1188 /* 1081 */ // Combiner Rule #60: add_p2i_to_ptradd; wip_match_opcode 'G_ADD'
1189 /* 1081 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner33),
1190 /* 1084 */ // Label 65: @1084
1191 /* 1084 */ GIM_Try, /*On fail goto*//*Label 66*/ GIMT_Encode4(1095), // Rule ID 109 //
1192 /* 1089 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule63Enabled),
1193 /* 1092 */ // Combiner Rule #63: simplify_add_to_sub; wip_match_opcode 'G_ADD'
1194 /* 1092 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner34),
1195 /* 1095 */ // Label 66: @1095
1196 /* 1095 */ GIM_Try, /*On fail goto*//*Label 67*/ GIMT_Encode4(1129), // Rule ID 31 //
1197 /* 1100 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule12Enabled),
1198 /* 1103 */ // MIs[0] dst
1199 /* 1103 */ // No operand predicates
1200 /* 1103 */ // MIs[0] __add_sub_reg_match_0.tmp
1201 /* 1103 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1202 /* 1107 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_SUB),
1203 /* 1111 */ // MIs[1] src
1204 /* 1111 */ // No operand predicates
1205 /* 1111 */ // MIs[1] __add_sub_reg_match_0.x
1206 /* 1111 */ // No operand predicates
1207 /* 1111 */ // MIs[0] __add_sub_reg_match_0.x
1208 /* 1111 */ GIM_CheckIsSameOperandIgnoreCopies, /*MI*/0, /*OpIdx*/2, /*OtherMI*/1, /*OtherOpIdx*/2,
1209 /* 1116 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/1, /*NewOpIdx*/1,
1210 /* 1121 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1211 /* 1123 */ // Combiner Rule #12: add_sub_reg @ [__add_sub_reg_match_0[1]]
1212 /* 1123 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/1, /*NewOpIdx*/1,
1213 /* 1128 */ GIR_EraseRootFromParent_Done,
1214 /* 1129 */ // Label 67: @1129
1215 /* 1129 */ GIM_Try, /*On fail goto*//*Label 68*/ GIMT_Encode4(1163), // Rule ID 30 //
1216 /* 1134 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule12Enabled),
1217 /* 1137 */ // MIs[0] dst
1218 /* 1137 */ // No operand predicates
1219 /* 1137 */ // MIs[0] __add_sub_reg_match_0.x
1220 /* 1137 */ // No operand predicates
1221 /* 1137 */ // MIs[0] __add_sub_reg_match_0.tmp
1222 /* 1137 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/2, // MIs[1]
1223 /* 1141 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_SUB),
1224 /* 1145 */ // MIs[1] src
1225 /* 1145 */ // No operand predicates
1226 /* 1145 */ // MIs[1] __add_sub_reg_match_0.x
1227 /* 1145 */ GIM_CheckIsSameOperandIgnoreCopies, /*MI*/1, /*OpIdx*/2, /*OtherMI*/0, /*OtherOpIdx*/1,
1228 /* 1150 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/1, /*NewOpIdx*/1,
1229 /* 1155 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1230 /* 1157 */ // Combiner Rule #12: add_sub_reg @ [__add_sub_reg_match_0[0]]
1231 /* 1157 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/1, /*NewOpIdx*/1,
1232 /* 1162 */ GIR_EraseRootFromParent_Done,
1233 /* 1163 */ // Label 68: @1163
1234 /* 1163 */ GIM_Try, /*On fail goto*//*Label 69*/ GIMT_Encode4(1186), // Rule ID 2 //
1235 /* 1168 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule1Enabled),
1236 /* 1171 */ // MIs[0] dst
1237 /* 1171 */ // No operand predicates
1238 /* 1171 */ // MIs[0] lhs
1239 /* 1171 */ // No operand predicates
1240 /* 1171 */ // MIs[0] Operand 2
1241 /* 1171 */ GIM_CheckConstantInt8, /*MI*/0, /*Op*/2, 0,
1242 /* 1175 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1243 /* 1180 */ // Combiner Rule #1: right_identity_zero @ [__right_identity_zero_match_0[1]]
1244 /* 1180 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1245 /* 1185 */ GIR_EraseRootFromParent_Done,
1246 /* 1186 */ // Label 69: @1186
1247 /* 1186 */ GIM_Try, /*On fail goto*//*Label 70*/ GIMT_Encode4(1197), // Rule ID 42 //
1248 /* 1191 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule22Enabled),
1249 /* 1194 */ // MIs[0] root
1250 /* 1194 */ // No operand predicates
1251 /* 1194 */ // MIs[0] src1
1252 /* 1194 */ // No operand predicates
1253 /* 1194 */ // MIs[0] src2
1254 /* 1194 */ // No operand predicates
1255 /* 1194 */ // Combiner Rule #22: reassoc_comm_binops
1256 /* 1194 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner9),
1257 /* 1197 */ // Label 70: @1197
1258 /* 1197 */ GIM_Reject,
1259 /* 1198 */ // Label 2: @1198
1260 /* 1198 */ GIM_Try, /*On fail goto*//*Label 71*/ GIMT_Encode4(1209), // Rule ID 93 //
1261 /* 1203 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule52Enabled),
1262 /* 1206 */ // Combiner Rule #52: propagate_undef_any_op; wip_match_opcode 'G_SUB'
1263 /* 1206 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner25),
1264 /* 1209 */ // Label 71: @1209
1265 /* 1209 */ GIM_Try, /*On fail goto*//*Label 72*/ GIMT_Encode4(1248), // Rule ID 13 //
1266 /* 1214 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule3Enabled),
1267 /* 1217 */ // MIs[0] dst
1268 /* 1217 */ // No operand predicates
1269 /* 1217 */ // MIs[0] x
1270 /* 1217 */ GIM_RecordRegType, /*MI*/0, /*Op*/1, /*TempTypeIdx*/255,
1271 /* 1221 */ // MIs[0] x
1272 /* 1221 */ GIM_CheckIsSameOperandIgnoreCopies, /*MI*/0, /*OpIdx*/2, /*OtherMI*/0, /*OtherOpIdx*/1,
1273 /* 1226 */ GIR_MakeTempReg, /*TempRegID*/0, /*TypeID*/255,
1274 /* 1229 */ GIR_BuildConstant, /*TempRegID*/0, /*Val*/GIMT_Encode8(0),
1275 /* 1239 */ // Combiner Rule #3: same_val_zero @ [__same_val_zero_match_0[0]]
1276 /* 1239 */ GIR_BuildRootMI, /*Opcode*/GIMT_Encode2(TargetOpcode::COPY),
1277 /* 1242 */ GIR_RootToRootCopy, /*OpIdx*/0, // dst
1278 /* 1244 */ GIR_AddSimpleTempRegister, /*InsnID*/0, /*TempRegID*/0,
1279 /* 1247 */ GIR_EraseRootFromParent_Done,
1280 /* 1248 */ // Label 72: @1248
1281 /* 1248 */ GIM_Try, /*On fail goto*//*Label 73*/ GIMT_Encode4(1271), // Rule ID 1 //
1282 /* 1253 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule1Enabled),
1283 /* 1256 */ // MIs[0] dst
1284 /* 1256 */ // No operand predicates
1285 /* 1256 */ // MIs[0] lhs
1286 /* 1256 */ // No operand predicates
1287 /* 1256 */ // MIs[0] Operand 2
1288 /* 1256 */ GIM_CheckConstantInt8, /*MI*/0, /*Op*/2, 0,
1289 /* 1260 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1290 /* 1265 */ // Combiner Rule #1: right_identity_zero @ [__right_identity_zero_match_0[0]]
1291 /* 1265 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1292 /* 1270 */ GIR_EraseRootFromParent_Done,
1293 /* 1271 */ // Label 73: @1271
1294 /* 1271 */ GIM_Try, /*On fail goto*//*Label 74*/ GIMT_Encode4(1292), // Rule ID 103 //
1295 /* 1276 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule59Enabled),
1296 /* 1279 */ // MIs[0] d
1297 /* 1279 */ // No operand predicates
1298 /* 1279 */ // MIs[0] op1
1299 /* 1279 */ // No operand predicates
1300 /* 1279 */ // MIs[0] c
1301 /* 1279 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/2, // MIs[1]
1302 /* 1283 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_CONSTANT),
1303 /* 1287 */ // MIs[1] imm
1304 /* 1287 */ // No operand predicates
1305 /* 1287 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1306 /* 1289 */ // Combiner Rule #59: sub_to_add
1307 /* 1289 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner32),
1308 /* 1292 */ // Label 74: @1292
1309 /* 1292 */ GIM_Reject,
1310 /* 1293 */ // Label 3: @1293
1311 /* 1293 */ GIM_Try, /*On fail goto*//*Label 75*/ GIMT_Encode4(1304), // Rule ID 76 //
1312 /* 1298 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule46Enabled),
1313 /* 1301 */ // Combiner Rule #46: undef_to_int_zero; wip_match_opcode 'G_MUL'
1314 /* 1301 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner20),
1315 /* 1304 */ // Label 75: @1304
1316 /* 1304 */ GIM_Try, /*On fail goto*//*Label 76*/ GIMT_Encode4(1344), // Rule ID 105 //
1317 /* 1309 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule61Enabled),
1318 /* 1312 */ // MIs[0] dst
1319 /* 1312 */ GIM_RecordRegType, /*MI*/0, /*Op*/0, /*TempTypeIdx*/255,
1320 /* 1316 */ // MIs[0] x
1321 /* 1316 */ // No operand predicates
1322 /* 1316 */ // MIs[0] Operand 2
1323 /* 1316 */ GIM_CheckConstantInt8, /*MI*/0, /*Op*/2, 255,
1324 /* 1320 */ GIR_MakeTempReg, /*TempRegID*/0, /*TypeID*/255,
1325 /* 1323 */ GIR_BuildConstant, /*TempRegID*/0, /*Val*/GIMT_Encode8(0),
1326 /* 1333 */ // Combiner Rule #61: mul_by_neg_one
1327 /* 1333 */ GIR_BuildRootMI, /*Opcode*/GIMT_Encode2(TargetOpcode::G_SUB),
1328 /* 1336 */ GIR_RootToRootCopy, /*OpIdx*/0, // dst
1329 /* 1338 */ GIR_AddSimpleTempRegister, /*InsnID*/0, /*TempRegID*/0,
1330 /* 1341 */ GIR_RootToRootCopy, /*OpIdx*/1, // x
1331 /* 1343 */ GIR_EraseRootFromParent_Done,
1332 /* 1344 */ // Label 76: @1344
1333 /* 1344 */ GIM_Try, /*On fail goto*//*Label 77*/ GIMT_Encode4(1384), // Rule ID 22 //
1334 /* 1349 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule4Enabled),
1335 /* 1352 */ // MIs[0] dst
1336 /* 1352 */ // No operand predicates
1337 /* 1352 */ // MIs[0] zero
1338 /* 1352 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1339 /* 1356 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_CONSTANT),
1340 /* 1360 */ // MIs[1] Operand 1
1341 /* 1360 */ GIM_CheckLiteralInt, /*MI*/1, /*Op*/1, GIMT_Encode8(0),
1342 /* 1371 */ // MIs[0] rhs
1343 /* 1371 */ // No operand predicates
1344 /* 1371 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1345 /* 1376 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1346 /* 1378 */ // Combiner Rule #4: binop_left_to_zero @ [__binop_left_to_zero_match_0[7]]
1347 /* 1378 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1348 /* 1383 */ GIR_EraseRootFromParent_Done,
1349 /* 1384 */ // Label 77: @1384
1350 /* 1384 */ GIM_Try, /*On fail goto*//*Label 78*/ GIMT_Encode4(1407), // Rule ID 23 //
1351 /* 1389 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule5Enabled),
1352 /* 1392 */ // MIs[0] dst
1353 /* 1392 */ // No operand predicates
1354 /* 1392 */ // MIs[0] lhs
1355 /* 1392 */ // No operand predicates
1356 /* 1392 */ // MIs[0] zero
1357 /* 1392 */ GIM_CheckConstantInt8, /*MI*/0, /*Op*/2, 0,
1358 /* 1396 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/2,
1359 /* 1401 */ // Combiner Rule #5: binop_right_to_zero
1360 /* 1401 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/2,
1361 /* 1406 */ GIR_EraseRootFromParent_Done,
1362 /* 1407 */ // Label 78: @1407
1363 /* 1407 */ GIM_Try, /*On fail goto*//*Label 79*/ GIMT_Encode4(1430), // Rule ID 28 //
1364 /* 1412 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule10Enabled),
1365 /* 1415 */ // MIs[0] dst
1366 /* 1415 */ // No operand predicates
1367 /* 1415 */ // MIs[0] x
1368 /* 1415 */ // No operand predicates
1369 /* 1415 */ // MIs[0] Operand 2
1370 /* 1415 */ GIM_CheckConstantInt8, /*MI*/0, /*Op*/2, 1,
1371 /* 1419 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1372 /* 1424 */ // Combiner Rule #10: right_identity_one_int
1373 /* 1424 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1374 /* 1429 */ GIR_EraseRootFromParent_Done,
1375 /* 1430 */ // Label 79: @1430
1376 /* 1430 */ GIM_Try, /*On fail goto*//*Label 80*/ GIMT_Encode4(1441), // Rule ID 102 //
1377 /* 1435 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule58Enabled),
1378 /* 1438 */ // MIs[0] d
1379 /* 1438 */ // No operand predicates
1380 /* 1438 */ // MIs[0] op1
1381 /* 1438 */ // No operand predicates
1382 /* 1438 */ // MIs[0] op2
1383 /* 1438 */ // No operand predicates
1384 /* 1438 */ // Combiner Rule #58: mul_to_shl
1385 /* 1438 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner31),
1386 /* 1441 */ // Label 80: @1441
1387 /* 1441 */ GIM_Reject,
1388 /* 1442 */ // Label 4: @1442
1389 /* 1442 */ GIM_Try, /*On fail goto*//*Label 81*/ GIMT_Encode4(1482), // Rule ID 18 //
1390 /* 1447 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule4Enabled),
1391 /* 1450 */ // MIs[0] dst
1392 /* 1450 */ // No operand predicates
1393 /* 1450 */ // MIs[0] zero
1394 /* 1450 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1395 /* 1454 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_CONSTANT),
1396 /* 1458 */ // MIs[1] Operand 1
1397 /* 1458 */ GIM_CheckLiteralInt, /*MI*/1, /*Op*/1, GIMT_Encode8(0),
1398 /* 1469 */ // MIs[0] rhs
1399 /* 1469 */ // No operand predicates
1400 /* 1469 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1401 /* 1474 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1402 /* 1476 */ // Combiner Rule #4: binop_left_to_zero @ [__binop_left_to_zero_match_0[3]]
1403 /* 1476 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1404 /* 1481 */ GIR_EraseRootFromParent_Done,
1405 /* 1482 */ // Label 81: @1482
1406 /* 1482 */ GIM_Reject,
1407 /* 1483 */ // Label 5: @1483
1408 /* 1483 */ GIM_Try, /*On fail goto*//*Label 82*/ GIMT_Encode4(1494), // Rule ID 79 //
1409 /* 1488 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule48Enabled),
1410 /* 1491 */ // Combiner Rule #48: binop_left_undef_to_zero; wip_match_opcode 'G_UDIV'
1411 /* 1491 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner22),
1412 /* 1494 */ // Label 82: @1494
1413 /* 1494 */ GIM_Try, /*On fail goto*//*Label 83*/ GIMT_Encode4(1534), // Rule ID 19 //
1414 /* 1499 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule4Enabled),
1415 /* 1502 */ // MIs[0] dst
1416 /* 1502 */ // No operand predicates
1417 /* 1502 */ // MIs[0] zero
1418 /* 1502 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1419 /* 1506 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_CONSTANT),
1420 /* 1510 */ // MIs[1] Operand 1
1421 /* 1510 */ GIM_CheckLiteralInt, /*MI*/1, /*Op*/1, GIMT_Encode8(0),
1422 /* 1521 */ // MIs[0] rhs
1423 /* 1521 */ // No operand predicates
1424 /* 1521 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1425 /* 1526 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1426 /* 1528 */ // Combiner Rule #4: binop_left_to_zero @ [__binop_left_to_zero_match_0[4]]
1427 /* 1528 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1428 /* 1533 */ GIR_EraseRootFromParent_Done,
1429 /* 1534 */ // Label 83: @1534
1430 /* 1534 */ GIM_Reject,
1431 /* 1535 */ // Label 6: @1535
1432 /* 1535 */ GIM_Try, /*On fail goto*//*Label 84*/ GIMT_Encode4(1575), // Rule ID 20 //
1433 /* 1540 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule4Enabled),
1434 /* 1543 */ // MIs[0] dst
1435 /* 1543 */ // No operand predicates
1436 /* 1543 */ // MIs[0] zero
1437 /* 1543 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1438 /* 1547 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_CONSTANT),
1439 /* 1551 */ // MIs[1] Operand 1
1440 /* 1551 */ GIM_CheckLiteralInt, /*MI*/1, /*Op*/1, GIMT_Encode8(0),
1441 /* 1562 */ // MIs[0] rhs
1442 /* 1562 */ // No operand predicates
1443 /* 1562 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1444 /* 1567 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1445 /* 1569 */ // Combiner Rule #4: binop_left_to_zero @ [__binop_left_to_zero_match_0[5]]
1446 /* 1569 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1447 /* 1574 */ GIR_EraseRootFromParent_Done,
1448 /* 1575 */ // Label 84: @1575
1449 /* 1575 */ GIM_Reject,
1450 /* 1576 */ // Label 7: @1576
1451 /* 1576 */ GIM_Try, /*On fail goto*//*Label 85*/ GIMT_Encode4(1587), // Rule ID 80 //
1452 /* 1581 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule48Enabled),
1453 /* 1584 */ // Combiner Rule #48: binop_left_undef_to_zero; wip_match_opcode 'G_UREM'
1454 /* 1584 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner22),
1455 /* 1587 */ // Label 85: @1587
1456 /* 1587 */ GIM_Try, /*On fail goto*//*Label 86*/ GIMT_Encode4(1627), // Rule ID 21 //
1457 /* 1592 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule4Enabled),
1458 /* 1595 */ // MIs[0] dst
1459 /* 1595 */ // No operand predicates
1460 /* 1595 */ // MIs[0] zero
1461 /* 1595 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1462 /* 1599 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_CONSTANT),
1463 /* 1603 */ // MIs[1] Operand 1
1464 /* 1603 */ GIM_CheckLiteralInt, /*MI*/1, /*Op*/1, GIMT_Encode8(0),
1465 /* 1614 */ // MIs[0] rhs
1466 /* 1614 */ // No operand predicates
1467 /* 1614 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1468 /* 1619 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1469 /* 1621 */ // Combiner Rule #4: binop_left_to_zero @ [__binop_left_to_zero_match_0[6]]
1470 /* 1621 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1471 /* 1626 */ GIR_EraseRootFromParent_Done,
1472 /* 1627 */ // Label 86: @1627
1473 /* 1627 */ GIM_Reject,
1474 /* 1628 */ // Label 8: @1628
1475 /* 1628 */ GIM_Try, /*On fail goto*//*Label 87*/ GIMT_Encode4(1639), // Rule ID 59 //
1476 /* 1633 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule39Enabled),
1477 /* 1636 */ // Combiner Rule #39: overlapping_and; wip_match_opcode 'G_AND'
1478 /* 1636 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner13),
1479 /* 1639 */ // Label 87: @1639
1480 /* 1639 */ GIM_Try, /*On fail goto*//*Label 88*/ GIMT_Encode4(1650), // Rule ID 75 //
1481 /* 1644 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule46Enabled),
1482 /* 1647 */ // Combiner Rule #46: undef_to_int_zero; wip_match_opcode 'G_AND'
1483 /* 1647 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner20),
1484 /* 1650 */ // Label 88: @1650
1485 /* 1650 */ GIM_Try, /*On fail goto*//*Label 89*/ GIMT_Encode4(1674), // Rule ID 11 //
1486 /* 1655 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule2Enabled),
1487 /* 1658 */ // MIs[0] dst
1488 /* 1658 */ // No operand predicates
1489 /* 1658 */ // MIs[0] src
1490 /* 1658 */ // No operand predicates
1491 /* 1658 */ // MIs[0] src
1492 /* 1658 */ GIM_CheckIsSameOperandIgnoreCopies, /*MI*/0, /*OpIdx*/2, /*OtherMI*/0, /*OtherOpIdx*/1,
1493 /* 1663 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1494 /* 1668 */ // Combiner Rule #2: binop_same_val @ [__binop_same_val_match_0[0]]
1495 /* 1668 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1496 /* 1673 */ GIR_EraseRootFromParent_Done,
1497 /* 1674 */ // Label 89: @1674
1498 /* 1674 */ GIM_Reject,
1499 /* 1675 */ // Label 9: @1675
1500 /* 1675 */ GIM_Try, /*On fail goto*//*Label 90*/ GIMT_Encode4(1686), // Rule ID 77 //
1501 /* 1680 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule47Enabled),
1502 /* 1683 */ // Combiner Rule #47: undef_to_negative_one; wip_match_opcode 'G_OR'
1503 /* 1683 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner21),
1504 /* 1686 */ // Label 90: @1686
1505 /* 1686 */ GIM_Try, /*On fail goto*//*Label 91*/ GIMT_Encode4(1710), // Rule ID 12 //
1506 /* 1691 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule2Enabled),
1507 /* 1694 */ // MIs[0] dst
1508 /* 1694 */ // No operand predicates
1509 /* 1694 */ // MIs[0] src
1510 /* 1694 */ // No operand predicates
1511 /* 1694 */ // MIs[0] src
1512 /* 1694 */ GIM_CheckIsSameOperandIgnoreCopies, /*MI*/0, /*OpIdx*/2, /*OtherMI*/0, /*OtherOpIdx*/1,
1513 /* 1699 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1514 /* 1704 */ // Combiner Rule #2: binop_same_val @ [__binop_same_val_match_0[1]]
1515 /* 1704 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1516 /* 1709 */ GIR_EraseRootFromParent_Done,
1517 /* 1710 */ // Label 91: @1710
1518 /* 1710 */ GIM_Try, /*On fail goto*//*Label 92*/ GIMT_Encode4(1733), // Rule ID 3 //
1519 /* 1715 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule1Enabled),
1520 /* 1718 */ // MIs[0] dst
1521 /* 1718 */ // No operand predicates
1522 /* 1718 */ // MIs[0] lhs
1523 /* 1718 */ // No operand predicates
1524 /* 1718 */ // MIs[0] Operand 2
1525 /* 1718 */ GIM_CheckConstantInt8, /*MI*/0, /*Op*/2, 0,
1526 /* 1722 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1527 /* 1727 */ // Combiner Rule #1: right_identity_zero @ [__right_identity_zero_match_0[2]]
1528 /* 1727 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1529 /* 1732 */ GIR_EraseRootFromParent_Done,
1530 /* 1733 */ // Label 92: @1733
1531 /* 1733 */ GIM_Reject,
1532 /* 1734 */ // Label 10: @1734
1533 /* 1734 */ GIM_Try, /*On fail goto*//*Label 93*/ GIMT_Encode4(1745), // Rule ID 94 //
1534 /* 1739 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule52Enabled),
1535 /* 1742 */ // Combiner Rule #52: propagate_undef_any_op; wip_match_opcode 'G_XOR'
1536 /* 1742 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner25),
1537 /* 1745 */ // Label 93: @1745
1538 /* 1745 */ GIM_Try, /*On fail goto*//*Label 94*/ GIMT_Encode4(1784), // Rule ID 14 //
1539 /* 1750 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule3Enabled),
1540 /* 1753 */ // MIs[0] dst
1541 /* 1753 */ // No operand predicates
1542 /* 1753 */ // MIs[0] x
1543 /* 1753 */ GIM_RecordRegType, /*MI*/0, /*Op*/1, /*TempTypeIdx*/255,
1544 /* 1757 */ // MIs[0] x
1545 /* 1757 */ GIM_CheckIsSameOperandIgnoreCopies, /*MI*/0, /*OpIdx*/2, /*OtherMI*/0, /*OtherOpIdx*/1,
1546 /* 1762 */ GIR_MakeTempReg, /*TempRegID*/0, /*TypeID*/255,
1547 /* 1765 */ GIR_BuildConstant, /*TempRegID*/0, /*Val*/GIMT_Encode8(0),
1548 /* 1775 */ // Combiner Rule #3: same_val_zero @ [__same_val_zero_match_0[1]]
1549 /* 1775 */ GIR_BuildRootMI, /*Opcode*/GIMT_Encode2(TargetOpcode::COPY),
1550 /* 1778 */ GIR_RootToRootCopy, /*OpIdx*/0, // dst
1551 /* 1780 */ GIR_AddSimpleTempRegister, /*InsnID*/0, /*TempRegID*/0,
1552 /* 1783 */ GIR_EraseRootFromParent_Done,
1553 /* 1784 */ // Label 94: @1784
1554 /* 1784 */ GIM_Try, /*On fail goto*//*Label 95*/ GIMT_Encode4(1807), // Rule ID 4 //
1555 /* 1789 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule1Enabled),
1556 /* 1792 */ // MIs[0] dst
1557 /* 1792 */ // No operand predicates
1558 /* 1792 */ // MIs[0] lhs
1559 /* 1792 */ // No operand predicates
1560 /* 1792 */ // MIs[0] Operand 2
1561 /* 1792 */ GIM_CheckConstantInt8, /*MI*/0, /*Op*/2, 0,
1562 /* 1796 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1563 /* 1801 */ // Combiner Rule #1: right_identity_zero @ [__right_identity_zero_match_0[3]]
1564 /* 1801 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1565 /* 1806 */ GIR_EraseRootFromParent_Done,
1566 /* 1807 */ // Label 95: @1807
1567 /* 1807 */ GIM_Reject,
1568 /* 1808 */ // Label 11: @1808
1569 /* 1808 */ GIM_Try, /*On fail goto*//*Label 96*/ GIMT_Encode4(1819), // Rule ID 33 //
1570 /* 1813 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule13Enabled),
1571 /* 1816 */ // Combiner Rule #13: buildvector_identity_fold; wip_match_opcode 'G_BUILD_VECTOR'
1572 /* 1816 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner4),
1573 /* 1819 */ // Label 96: @1819
1574 /* 1819 */ GIM_Try, /*On fail goto*//*Label 97*/ GIMT_Encode4(1830), // Rule ID 96 //
1575 /* 1824 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule53Enabled),
1576 /* 1827 */ // Combiner Rule #53: propagate_undef_all_ops; wip_match_opcode 'G_BUILD_VECTOR'
1577 /* 1827 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner26),
1578 /* 1830 */ // Label 97: @1830
1579 /* 1830 */ GIM_Reject,
1580 /* 1831 */ // Label 12: @1831
1581 /* 1831 */ GIM_Try, /*On fail goto*//*Label 98*/ GIMT_Encode4(1842), // Rule ID 32 //
1582 /* 1836 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule13Enabled),
1583 /* 1839 */ // Combiner Rule #13: buildvector_identity_fold; wip_match_opcode 'G_BUILD_VECTOR_TRUNC'
1584 /* 1839 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner4),
1585 /* 1842 */ // Label 98: @1842
1586 /* 1842 */ GIM_Reject,
1587 /* 1843 */ // Label 13: @1843
1588 /* 1843 */ GIM_Try, /*On fail goto*//*Label 99*/ GIMT_Encode4(1864), // Rule ID 25 //
1589 /* 1848 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule7Enabled),
1590 /* 1851 */ // MIs[0] dst
1591 /* 1851 */ // No operand predicates
1592 /* 1851 */ // MIs[0] t
1593 /* 1851 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1594 /* 1855 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_INTTOPTR),
1595 /* 1859 */ // MIs[1] ptr
1596 /* 1859 */ // No operand predicates
1597 /* 1859 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1598 /* 1861 */ // Combiner Rule #7: i2p_to_p2i
1599 /* 1861 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner2),
1600 /* 1864 */ // Label 99: @1864
1601 /* 1864 */ GIM_Try, /*On fail goto*//*Label 100*/ GIMT_Encode4(1885), // Rule ID 88 //
1602 /* 1869 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule51Enabled),
1603 /* 1872 */ // MIs[0] dst
1604 /* 1872 */ // No operand predicates
1605 /* 1872 */ // MIs[0] __unary_undef_to_undef_match_0.x
1606 /* 1872 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1607 /* 1876 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_IMPLICIT_DEF),
1608 /* 1880 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1609 /* 1882 */ // Combiner Rule #51: unary_undef_to_undef @ [__unary_undef_to_undef_match_0[3]]
1610 /* 1882 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner24),
1611 /* 1885 */ // Label 100: @1885
1612 /* 1885 */ GIM_Reject,
1613 /* 1886 */ // Label 14: @1886
1614 /* 1886 */ GIM_Try, /*On fail goto*//*Label 101*/ GIMT_Encode4(1897), // Rule ID 24 //
1615 /* 1891 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule6Enabled),
1616 /* 1894 */ // Combiner Rule #6: p2i_to_i2p; wip_match_opcode 'G_INTTOPTR'
1617 /* 1894 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner1),
1618 /* 1897 */ // Label 101: @1897
1619 /* 1897 */ GIM_Try, /*On fail goto*//*Label 102*/ GIMT_Encode4(1918), // Rule ID 89 //
1620 /* 1902 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule51Enabled),
1621 /* 1905 */ // MIs[0] dst
1622 /* 1905 */ // No operand predicates
1623 /* 1905 */ // MIs[0] __unary_undef_to_undef_match_0.x
1624 /* 1905 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1625 /* 1909 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_IMPLICIT_DEF),
1626 /* 1913 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1627 /* 1915 */ // Combiner Rule #51: unary_undef_to_undef @ [__unary_undef_to_undef_match_0[4]]
1628 /* 1915 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner24),
1629 /* 1918 */ // Label 102: @1918
1630 /* 1918 */ GIM_Reject,
1631 /* 1919 */ // Label 15: @1919
1632 /* 1919 */ GIM_Try, /*On fail goto*//*Label 103*/ GIMT_Encode4(1940), // Rule ID 36 //
1633 /* 1924 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule16Enabled),
1634 /* 1927 */ // MIs[0] dst
1635 /* 1927 */ // No operand predicates
1636 /* 1927 */ // MIs[0] src1
1637 /* 1927 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1638 /* 1931 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_BITCAST),
1639 /* 1935 */ // MIs[1] src0
1640 /* 1935 */ // No operand predicates
1641 /* 1935 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1642 /* 1937 */ // Combiner Rule #16: bitcast_bitcast_fold
1643 /* 1937 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner7),
1644 /* 1940 */ // Label 103: @1940
1645 /* 1940 */ GIM_Try, /*On fail goto*//*Label 104*/ GIMT_Encode4(1961), // Rule ID 86 //
1646 /* 1945 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule51Enabled),
1647 /* 1948 */ // MIs[0] dst
1648 /* 1948 */ // No operand predicates
1649 /* 1948 */ // MIs[0] __unary_undef_to_undef_match_0.x
1650 /* 1948 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1651 /* 1952 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_IMPLICIT_DEF),
1652 /* 1956 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1653 /* 1958 */ // Combiner Rule #51: unary_undef_to_undef @ [__unary_undef_to_undef_match_0[1]]
1654 /* 1958 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner24),
1655 /* 1961 */ // Label 104: @1961
1656 /* 1961 */ GIM_Reject,
1657 /* 1962 */ // Label 16: @1962
1658 /* 1962 */ GIM_Try, /*On fail goto*//*Label 105*/ GIMT_Encode4(1991), // Rule ID 106 //
1659 /* 1967 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule62Enabled),
1660 /* 1970 */ // MIs[0] dst
1661 /* 1970 */ // No operand predicates
1662 /* 1970 */ // MIs[0] src
1663 /* 1970 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1664 /* 1974 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FREEZE),
1665 /* 1978 */ // MIs[1] __idempotent_prop_match_0.x
1666 /* 1978 */ // No operand predicates
1667 /* 1978 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1668 /* 1983 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1669 /* 1985 */ // Combiner Rule #62: idempotent_prop @ [__idempotent_prop_match_0[0]]
1670 /* 1985 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1671 /* 1990 */ GIR_EraseRootFromParent_Done,
1672 /* 1991 */ // Label 105: @1991
1673 /* 1991 */ GIM_Reject,
1674 /* 1992 */ // Label 17: @1992
1675 /* 1992 */ GIM_Try, /*On fail goto*//*Label 106*/ GIMT_Encode4(2013), // Rule ID 51 //
1676 /* 1997 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule31Enabled),
1677 /* 2000 */ // MIs[0] dst
1678 /* 2000 */ // No operand predicates
1679 /* 2000 */ // MIs[0] src0
1680 /* 2000 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1681 /* 2004 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FCONSTANT),
1682 /* 2008 */ // MIs[1] cst
1683 /* 2008 */ // No operand predicates
1684 /* 2008 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1685 /* 2010 */ // Combiner Rule #31: constant_fold_intrinsic_trunc
1686 /* 2010 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner10),
1687 /* 2013 */ // Label 106: @2013
1688 /* 2013 */ GIM_Reject,
1689 /* 2014 */ // Label 18: @2014
1690 /* 2014 */ GIM_Try, /*On fail goto*//*Label 107*/ GIMT_Encode4(2035), // Rule ID 52 //
1691 /* 2019 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule32Enabled),
1692 /* 2022 */ // MIs[0] dst
1693 /* 2022 */ // No operand predicates
1694 /* 2022 */ // MIs[0] src0
1695 /* 2022 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1696 /* 2026 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FCONSTANT),
1697 /* 2030 */ // MIs[1] cst
1698 /* 2030 */ // No operand predicates
1699 /* 2030 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1700 /* 2032 */ // Combiner Rule #32: constant_fold_intrinsic_round
1701 /* 2032 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner10),
1702 /* 2035 */ // Label 107: @2035
1703 /* 2035 */ GIM_Reject,
1704 /* 2036 */ // Label 19: @2036
1705 /* 2036 */ GIM_Try, /*On fail goto*//*Label 108*/ GIMT_Encode4(2057), // Rule ID 53 //
1706 /* 2041 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule33Enabled),
1707 /* 2044 */ // MIs[0] dst
1708 /* 2044 */ // No operand predicates
1709 /* 2044 */ // MIs[0] src0
1710 /* 2044 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1711 /* 2048 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FCONSTANT),
1712 /* 2052 */ // MIs[1] cst
1713 /* 2052 */ // No operand predicates
1714 /* 2052 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1715 /* 2054 */ // Combiner Rule #33: constant_fold_intrinsic_roundeven
1716 /* 2054 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner10),
1717 /* 2057 */ // Label 108: @2057
1718 /* 2057 */ GIM_Reject,
1719 /* 2058 */ // Label 20: @2058
1720 /* 2058 */ GIM_Try, /*On fail goto*//*Label 109*/ GIMT_Encode4(2069), // Rule ID 98 //
1721 /* 2063 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule55Enabled),
1722 /* 2066 */ // Combiner Rule #55: erase_undef_store; wip_match_opcode 'G_STORE'
1723 /* 2066 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner28),
1724 /* 2069 */ // Label 109: @2069
1725 /* 2069 */ GIM_Reject,
1726 /* 2070 */ // Label 21: @2070
1727 /* 2070 */ GIM_Try, /*On fail goto*//*Label 110*/ GIMT_Encode4(2081), // Rule ID 26 //
1728 /* 2075 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule8Enabled),
1729 /* 2078 */ // Combiner Rule #8: anyext_trunc_fold; wip_match_opcode 'G_ANYEXT'
1730 /* 2078 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner3),
1731 /* 2081 */ // Label 110: @2081
1732 /* 2081 */ GIM_Try, /*On fail goto*//*Label 111*/ GIMT_Encode4(2102), // Rule ID 87 //
1733 /* 2086 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule51Enabled),
1734 /* 2089 */ // MIs[0] dst
1735 /* 2089 */ // No operand predicates
1736 /* 2089 */ // MIs[0] __unary_undef_to_undef_match_0.x
1737 /* 2089 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1738 /* 2093 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_IMPLICIT_DEF),
1739 /* 2097 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1740 /* 2099 */ // Combiner Rule #51: unary_undef_to_undef @ [__unary_undef_to_undef_match_0[2]]
1741 /* 2099 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner24),
1742 /* 2102 */ // Label 111: @2102
1743 /* 2102 */ GIM_Reject,
1744 /* 2103 */ // Label 22: @2103
1745 /* 2103 */ GIM_Try, /*On fail goto*//*Label 112*/ GIMT_Encode4(2114), // Rule ID 34 //
1746 /* 2108 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule14Enabled),
1747 /* 2111 */ // Combiner Rule #14: trunc_buildvector_fold; wip_match_opcode 'G_TRUNC'
1748 /* 2111 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner5),
1749 /* 2114 */ // Label 112: @2114
1750 /* 2114 */ GIM_Try, /*On fail goto*//*Label 113*/ GIMT_Encode4(2125), // Rule ID 35 //
1751 /* 2119 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule15Enabled),
1752 /* 2122 */ // Combiner Rule #15: trunc_lshr_buildvector_fold; wip_match_opcode 'G_TRUNC'
1753 /* 2122 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner6),
1754 /* 2125 */ // Label 113: @2125
1755 /* 2125 */ GIM_Try, /*On fail goto*//*Label 114*/ GIMT_Encode4(2146), // Rule ID 85 //
1756 /* 2130 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule51Enabled),
1757 /* 2133 */ // MIs[0] dst
1758 /* 2133 */ // No operand predicates
1759 /* 2133 */ // MIs[0] __unary_undef_to_undef_match_0.x
1760 /* 2133 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1761 /* 2137 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_IMPLICIT_DEF),
1762 /* 2141 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1763 /* 2143 */ // Combiner Rule #51: unary_undef_to_undef @ [__unary_undef_to_undef_match_0[0]]
1764 /* 2143 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner24),
1765 /* 2146 */ // Label 114: @2146
1766 /* 2146 */ GIM_Reject,
1767 /* 2147 */ // Label 23: @2147
1768 /* 2147 */ GIM_Try, /*On fail goto*//*Label 115*/ GIMT_Encode4(2158), // Rule ID 78 //
1769 /* 2152 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule48Enabled),
1770 /* 2155 */ // Combiner Rule #48: binop_left_undef_to_zero; wip_match_opcode 'G_SHL'
1771 /* 2155 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner22),
1772 /* 2158 */ // Label 115: @2158
1773 /* 2158 */ GIM_Try, /*On fail goto*//*Label 116*/ GIMT_Encode4(2169), // Rule ID 81 //
1774 /* 2163 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule49Enabled),
1775 /* 2166 */ // Combiner Rule #49: binop_right_undef_to_undef; wip_match_opcode 'G_SHL'
1776 /* 2166 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner23),
1777 /* 2169 */ // Label 116: @2169
1778 /* 2169 */ GIM_Try, /*On fail goto*//*Label 117*/ GIMT_Encode4(2209), // Rule ID 15 //
1779 /* 2174 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule4Enabled),
1780 /* 2177 */ // MIs[0] dst
1781 /* 2177 */ // No operand predicates
1782 /* 2177 */ // MIs[0] zero
1783 /* 2177 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1784 /* 2181 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_CONSTANT),
1785 /* 2185 */ // MIs[1] Operand 1
1786 /* 2185 */ GIM_CheckLiteralInt, /*MI*/1, /*Op*/1, GIMT_Encode8(0),
1787 /* 2196 */ // MIs[0] rhs
1788 /* 2196 */ // No operand predicates
1789 /* 2196 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1790 /* 2201 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1791 /* 2203 */ // Combiner Rule #4: binop_left_to_zero @ [__binop_left_to_zero_match_0[0]]
1792 /* 2203 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1793 /* 2208 */ GIR_EraseRootFromParent_Done,
1794 /* 2209 */ // Label 117: @2209
1795 /* 2209 */ GIM_Try, /*On fail goto*//*Label 118*/ GIMT_Encode4(2232), // Rule ID 5 //
1796 /* 2214 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule1Enabled),
1797 /* 2217 */ // MIs[0] dst
1798 /* 2217 */ // No operand predicates
1799 /* 2217 */ // MIs[0] lhs
1800 /* 2217 */ // No operand predicates
1801 /* 2217 */ // MIs[0] Operand 2
1802 /* 2217 */ GIM_CheckConstantInt8, /*MI*/0, /*Op*/2, 0,
1803 /* 2221 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1804 /* 2226 */ // Combiner Rule #1: right_identity_zero @ [__right_identity_zero_match_0[4]]
1805 /* 2226 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1806 /* 2231 */ GIR_EraseRootFromParent_Done,
1807 /* 2232 */ // Label 118: @2232
1808 /* 2232 */ GIM_Reject,
1809 /* 2233 */ // Label 24: @2233
1810 /* 2233 */ GIM_Try, /*On fail goto*//*Label 119*/ GIMT_Encode4(2244), // Rule ID 83 //
1811 /* 2238 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule49Enabled),
1812 /* 2241 */ // Combiner Rule #49: binop_right_undef_to_undef; wip_match_opcode 'G_LSHR'
1813 /* 2241 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner23),
1814 /* 2244 */ // Label 119: @2244
1815 /* 2244 */ GIM_Try, /*On fail goto*//*Label 120*/ GIMT_Encode4(2284), // Rule ID 16 //
1816 /* 2249 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule4Enabled),
1817 /* 2252 */ // MIs[0] dst
1818 /* 2252 */ // No operand predicates
1819 /* 2252 */ // MIs[0] zero
1820 /* 2252 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1821 /* 2256 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_CONSTANT),
1822 /* 2260 */ // MIs[1] Operand 1
1823 /* 2260 */ GIM_CheckLiteralInt, /*MI*/1, /*Op*/1, GIMT_Encode8(0),
1824 /* 2271 */ // MIs[0] rhs
1825 /* 2271 */ // No operand predicates
1826 /* 2271 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1827 /* 2276 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1828 /* 2278 */ // Combiner Rule #4: binop_left_to_zero @ [__binop_left_to_zero_match_0[1]]
1829 /* 2278 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1830 /* 2283 */ GIR_EraseRootFromParent_Done,
1831 /* 2284 */ // Label 120: @2284
1832 /* 2284 */ GIM_Try, /*On fail goto*//*Label 121*/ GIMT_Encode4(2307), // Rule ID 7 //
1833 /* 2289 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule1Enabled),
1834 /* 2292 */ // MIs[0] dst
1835 /* 2292 */ // No operand predicates
1836 /* 2292 */ // MIs[0] lhs
1837 /* 2292 */ // No operand predicates
1838 /* 2292 */ // MIs[0] Operand 2
1839 /* 2292 */ GIM_CheckConstantInt8, /*MI*/0, /*Op*/2, 0,
1840 /* 2296 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1841 /* 2301 */ // Combiner Rule #1: right_identity_zero @ [__right_identity_zero_match_0[6]]
1842 /* 2301 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1843 /* 2306 */ GIR_EraseRootFromParent_Done,
1844 /* 2307 */ // Label 121: @2307
1845 /* 2307 */ GIM_Reject,
1846 /* 2308 */ // Label 25: @2308
1847 /* 2308 */ GIM_Try, /*On fail goto*//*Label 122*/ GIMT_Encode4(2319), // Rule ID 82 //
1848 /* 2313 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule49Enabled),
1849 /* 2316 */ // Combiner Rule #49: binop_right_undef_to_undef; wip_match_opcode 'G_ASHR'
1850 /* 2316 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner23),
1851 /* 2319 */ // Label 122: @2319
1852 /* 2319 */ GIM_Try, /*On fail goto*//*Label 123*/ GIMT_Encode4(2359), // Rule ID 17 //
1853 /* 2324 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule4Enabled),
1854 /* 2327 */ // MIs[0] dst
1855 /* 2327 */ // No operand predicates
1856 /* 2327 */ // MIs[0] zero
1857 /* 2327 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
1858 /* 2331 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_CONSTANT),
1859 /* 2335 */ // MIs[1] Operand 1
1860 /* 2335 */ GIM_CheckLiteralInt, /*MI*/1, /*Op*/1, GIMT_Encode8(0),
1861 /* 2346 */ // MIs[0] rhs
1862 /* 2346 */ // No operand predicates
1863 /* 2346 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1864 /* 2351 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
1865 /* 2353 */ // Combiner Rule #4: binop_left_to_zero @ [__binop_left_to_zero_match_0[2]]
1866 /* 2353 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1867 /* 2358 */ GIR_EraseRootFromParent_Done,
1868 /* 2359 */ // Label 123: @2359
1869 /* 2359 */ GIM_Try, /*On fail goto*//*Label 124*/ GIMT_Encode4(2382), // Rule ID 6 //
1870 /* 2364 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule1Enabled),
1871 /* 2367 */ // MIs[0] dst
1872 /* 2367 */ // No operand predicates
1873 /* 2367 */ // MIs[0] lhs
1874 /* 2367 */ // No operand predicates
1875 /* 2367 */ // MIs[0] Operand 2
1876 /* 2367 */ GIM_CheckConstantInt8, /*MI*/0, /*Op*/2, 0,
1877 /* 2371 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1878 /* 2376 */ // Combiner Rule #1: right_identity_zero @ [__right_identity_zero_match_0[5]]
1879 /* 2376 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1880 /* 2381 */ GIR_EraseRootFromParent_Done,
1881 /* 2382 */ // Label 124: @2382
1882 /* 2382 */ GIM_Reject,
1883 /* 2383 */ // Label 26: @2383
1884 /* 2383 */ GIM_Try, /*On fail goto*//*Label 125*/ GIMT_Encode4(2406), // Rule ID 10 //
1885 /* 2388 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule1Enabled),
1886 /* 2391 */ // MIs[0] dst
1887 /* 2391 */ // No operand predicates
1888 /* 2391 */ // MIs[0] lhs
1889 /* 2391 */ // No operand predicates
1890 /* 2391 */ // MIs[0] Operand 2
1891 /* 2391 */ GIM_CheckConstantInt8, /*MI*/0, /*Op*/2, 0,
1892 /* 2395 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1893 /* 2400 */ // Combiner Rule #1: right_identity_zero @ [__right_identity_zero_match_0[9]]
1894 /* 2400 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1895 /* 2405 */ GIR_EraseRootFromParent_Done,
1896 /* 2406 */ // Label 125: @2406
1897 /* 2406 */ GIM_Reject,
1898 /* 2407 */ // Label 27: @2407
1899 /* 2407 */ GIM_Try, /*On fail goto*//*Label 126*/ GIMT_Encode4(2430), // Rule ID 9 //
1900 /* 2412 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule1Enabled),
1901 /* 2415 */ // MIs[0] dst
1902 /* 2415 */ // No operand predicates
1903 /* 2415 */ // MIs[0] lhs
1904 /* 2415 */ // No operand predicates
1905 /* 2415 */ // MIs[0] Operand 2
1906 /* 2415 */ GIM_CheckConstantInt8, /*MI*/0, /*Op*/2, 0,
1907 /* 2419 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1908 /* 2424 */ // Combiner Rule #1: right_identity_zero @ [__right_identity_zero_match_0[8]]
1909 /* 2424 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1910 /* 2429 */ GIR_EraseRootFromParent_Done,
1911 /* 2430 */ // Label 126: @2430
1912 /* 2430 */ GIM_Reject,
1913 /* 2431 */ // Label 28: @2431
1914 /* 2431 */ GIM_Try, /*On fail goto*//*Label 127*/ GIMT_Encode4(2442), // Rule ID 0 //
1915 /* 2436 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule0Enabled),
1916 /* 2439 */ // Combiner Rule #0: select_same_val; wip_match_opcode 'G_SELECT'
1917 /* 2439 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner0),
1918 /* 2442 */ // Label 127: @2442
1919 /* 2442 */ GIM_Reject,
1920 /* 2443 */ // Label 29: @2443
1921 /* 2443 */ GIM_Try, /*On fail goto*//*Label 128*/ GIMT_Encode4(2454), // Rule ID 64 //
1922 /* 2448 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule42Enabled),
1923 /* 2451 */ // Combiner Rule #42: adde_to_addo; wip_match_opcode 'G_UADDE'
1924 /* 2451 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner16),
1925 /* 2454 */ // Label 128: @2454
1926 /* 2454 */ GIM_Reject,
1927 /* 2455 */ // Label 30: @2455
1928 /* 2455 */ GIM_Try, /*On fail goto*//*Label 129*/ GIMT_Encode4(2466), // Rule ID 66 //
1929 /* 2460 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule42Enabled),
1930 /* 2463 */ // Combiner Rule #42: adde_to_addo; wip_match_opcode 'G_USUBE'
1931 /* 2463 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner16),
1932 /* 2466 */ // Label 129: @2466
1933 /* 2466 */ GIM_Reject,
1934 /* 2467 */ // Label 31: @2467
1935 /* 2467 */ GIM_Try, /*On fail goto*//*Label 130*/ GIMT_Encode4(2478), // Rule ID 65 //
1936 /* 2472 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule42Enabled),
1937 /* 2475 */ // Combiner Rule #42: adde_to_addo; wip_match_opcode 'G_SADDE'
1938 /* 2475 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner16),
1939 /* 2478 */ // Label 130: @2478
1940 /* 2478 */ GIM_Reject,
1941 /* 2479 */ // Label 32: @2479
1942 /* 2479 */ GIM_Try, /*On fail goto*//*Label 131*/ GIMT_Encode4(2490), // Rule ID 67 //
1943 /* 2484 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule42Enabled),
1944 /* 2487 */ // Combiner Rule #42: adde_to_addo; wip_match_opcode 'G_SSUBE'
1945 /* 2487 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner16),
1946 /* 2490 */ // Label 131: @2490
1947 /* 2490 */ GIM_Reject,
1948 /* 2491 */ // Label 33: @2491
1949 /* 2491 */ GIM_Try, /*On fail goto*//*Label 132*/ GIMT_Encode4(2502), // Rule ID 60 //
1950 /* 2496 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule40Enabled),
1951 /* 2499 */ // Combiner Rule #40: mulo_by_2; wip_match_opcode 'G_UMULO'
1952 /* 2499 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner14),
1953 /* 2502 */ // Label 132: @2502
1954 /* 2502 */ GIM_Try, /*On fail goto*//*Label 133*/ GIMT_Encode4(2513), // Rule ID 62 //
1955 /* 2507 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule41Enabled),
1956 /* 2510 */ // Combiner Rule #41: mulo_by_0; wip_match_opcode 'G_UMULO'
1957 /* 2510 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner15),
1958 /* 2513 */ // Label 133: @2513
1959 /* 2513 */ GIM_Reject,
1960 /* 2514 */ // Label 34: @2514
1961 /* 2514 */ GIM_Try, /*On fail goto*//*Label 134*/ GIMT_Encode4(2525), // Rule ID 61 //
1962 /* 2519 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule40Enabled),
1963 /* 2522 */ // Combiner Rule #40: mulo_by_2; wip_match_opcode 'G_SMULO'
1964 /* 2522 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner14),
1965 /* 2525 */ // Label 134: @2525
1966 /* 2525 */ GIM_Try, /*On fail goto*//*Label 135*/ GIMT_Encode4(2536), // Rule ID 63 //
1967 /* 2530 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule41Enabled),
1968 /* 2533 */ // Combiner Rule #41: mulo_by_0; wip_match_opcode 'G_SMULO'
1969 /* 2533 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner15),
1970 /* 2536 */ // Label 135: @2536
1971 /* 2536 */ GIM_Reject,
1972 /* 2537 */ // Label 35: @2537
1973 /* 2537 */ GIM_Try, /*On fail goto*//*Label 136*/ GIMT_Encode4(2560), // Rule ID 38 //
1974 /* 2542 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule18Enabled),
1975 /* 2545 */ // MIs[0] dst
1976 /* 2545 */ // No operand predicates
1977 /* 2545 */ // MIs[0] x
1978 /* 2545 */ // No operand predicates
1979 /* 2545 */ // MIs[0] y
1980 /* 2545 */ // No operand predicates
1981 /* 2545 */ GIM_CheckCxxInsnPredicate, /*MI*/0, /*FnId*/GIMT_Encode2(GICXXPred_MI_Predicate_GICombiner1),
1982 /* 2549 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1983 /* 2554 */ // Combiner Rule #18: right_identity_neg_zero_fp
1984 /* 2554 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1985 /* 2559 */ GIR_EraseRootFromParent_Done,
1986 /* 2560 */ // Label 136: @2560
1987 /* 2560 */ GIM_Try, /*On fail goto*//*Label 137*/ GIMT_Encode4(2589), // Rule ID 39 //
1988 /* 2565 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule19Enabled),
1989 /* 2568 */ GIM_MIFlags, /*MI*/0, GIMT_Encode4(MachineInstr::FmNsz),
1990 /* 2574 */ // MIs[0] dst
1991 /* 2574 */ // No operand predicates
1992 /* 2574 */ // MIs[0] x
1993 /* 2574 */ // No operand predicates
1994 /* 2574 */ // MIs[0] y
1995 /* 2574 */ // No operand predicates
1996 /* 2574 */ GIM_CheckCxxInsnPredicate, /*MI*/0, /*FnId*/GIMT_Encode2(GICXXPred_MI_Predicate_GICombiner2),
1997 /* 2578 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
1998 /* 2583 */ // Combiner Rule #19: right_identity_neg_zero_fp_nsz
1999 /* 2583 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
2000 /* 2588 */ GIR_EraseRootFromParent_Done,
2001 /* 2589 */ // Label 137: @2589
2002 /* 2589 */ GIM_Reject,
2003 /* 2590 */ // Label 36: @2590
2004 /* 2590 */ GIM_Try, /*On fail goto*//*Label 138*/ GIMT_Encode4(2613), // Rule ID 29 //
2005 /* 2595 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule11Enabled),
2006 /* 2598 */ // MIs[0] dst
2007 /* 2598 */ // No operand predicates
2008 /* 2598 */ // MIs[0] x
2009 /* 2598 */ // No operand predicates
2010 /* 2598 */ // MIs[0] y
2011 /* 2598 */ // No operand predicates
2012 /* 2598 */ GIM_CheckCxxInsnPredicate, /*MI*/0, /*FnId*/GIMT_Encode2(GICXXPred_MI_Predicate_GICombiner0),
2013 /* 2602 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
2014 /* 2607 */ // Combiner Rule #11: right_identity_one_fp
2015 /* 2607 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
2016 /* 2612 */ GIR_EraseRootFromParent_Done,
2017 /* 2613 */ // Label 138: @2613
2018 /* 2613 */ GIM_Try, /*On fail goto*//*Label 139*/ GIMT_Encode4(2633), // Rule ID 40 //
2019 /* 2618 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule20Enabled),
2020 /* 2621 */ // MIs[0] dst
2021 /* 2621 */ // No operand predicates
2022 /* 2621 */ // MIs[0] x
2023 /* 2621 */ // No operand predicates
2024 /* 2621 */ // MIs[0] y
2025 /* 2621 */ // No operand predicates
2026 /* 2621 */ GIM_CheckCxxInsnPredicate, /*MI*/0, /*FnId*/GIMT_Encode2(GICXXPred_MI_Predicate_GICombiner3),
2027 /* 2625 */ // Combiner Rule #20: right_identity_neg_one_fp
2028 /* 2625 */ GIR_BuildRootMI, /*Opcode*/GIMT_Encode2(TargetOpcode::G_FNEG),
2029 /* 2628 */ GIR_RootToRootCopy, /*OpIdx*/0, // dst
2030 /* 2630 */ GIR_RootToRootCopy, /*OpIdx*/1, // x
2031 /* 2632 */ GIR_EraseRootFromParent_Done,
2032 /* 2633 */ // Label 139: @2633
2033 /* 2633 */ GIM_Reject,
2034 /* 2634 */ // Label 37: @2634
2035 /* 2634 */ GIM_Try, /*On fail goto*//*Label 140*/ GIMT_Encode4(2655), // Rule ID 72 //
2036 /* 2639 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule44Enabled),
2037 /* 2642 */ // MIs[0] dst
2038 /* 2642 */ // No operand predicates
2039 /* 2642 */ // MIs[0] float
2040 /* 2642 */ // No operand predicates
2041 /* 2642 */ // MIs[0] int
2042 /* 2642 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/2, // MIs[1]
2043 /* 2646 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_CONSTANT),
2044 /* 2650 */ // MIs[1] imm
2045 /* 2650 */ // No operand predicates
2046 /* 2650 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
2047 /* 2652 */ // Combiner Rule #44: expand_const_fpowi
2048 /* 2652 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner18),
2049 /* 2655 */ // Label 140: @2655
2050 /* 2655 */ GIM_Reject,
2051 /* 2656 */ // Label 38: @2656
2052 /* 2656 */ GIM_Try, /*On fail goto*//*Label 141*/ GIMT_Encode4(2677), // Rule ID 46 //
2053 /* 2661 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule26Enabled),
2054 /* 2664 */ // MIs[0] dst
2055 /* 2664 */ // No operand predicates
2056 /* 2664 */ // MIs[0] src0
2057 /* 2664 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
2058 /* 2668 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FCONSTANT),
2059 /* 2672 */ // MIs[1] cst
2060 /* 2672 */ // No operand predicates
2061 /* 2672 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
2062 /* 2674 */ // Combiner Rule #26: constant_fold_flog2
2063 /* 2674 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner10),
2064 /* 2677 */ // Label 141: @2677
2065 /* 2677 */ GIM_Reject,
2066 /* 2678 */ // Label 39: @2678
2067 /* 2678 */ GIM_Try, /*On fail goto*//*Label 142*/ GIMT_Encode4(2699), // Rule ID 43 //
2068 /* 2683 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule23Enabled),
2069 /* 2686 */ // MIs[0] dst
2070 /* 2686 */ // No operand predicates
2071 /* 2686 */ // MIs[0] src0
2072 /* 2686 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
2073 /* 2690 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FCONSTANT),
2074 /* 2694 */ // MIs[1] cst
2075 /* 2694 */ // No operand predicates
2076 /* 2694 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
2077 /* 2696 */ // Combiner Rule #23: constant_fold_fneg
2078 /* 2696 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner10),
2079 /* 2699 */ // Label 142: @2699
2080 /* 2699 */ GIM_Try, /*On fail goto*//*Label 143*/ GIMT_Encode4(2728), // Rule ID 27 //
2081 /* 2704 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule9Enabled),
2082 /* 2707 */ // MIs[0] dst
2083 /* 2707 */ // No operand predicates
2084 /* 2707 */ // MIs[0] t
2085 /* 2707 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
2086 /* 2711 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FNEG),
2087 /* 2715 */ // MIs[1] src
2088 /* 2715 */ // No operand predicates
2089 /* 2715 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/1, /*NewOpIdx*/1,
2090 /* 2720 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
2091 /* 2722 */ // Combiner Rule #9: fneg_fneg_fold
2092 /* 2722 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/1, /*NewOpIdx*/1,
2093 /* 2727 */ GIR_EraseRootFromParent_Done,
2094 /* 2728 */ // Label 143: @2728
2095 /* 2728 */ GIM_Reject,
2096 /* 2729 */ // Label 40: @2729
2097 /* 2729 */ GIM_Try, /*On fail goto*//*Label 144*/ GIMT_Encode4(2750), // Rule ID 48 //
2098 /* 2734 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule28Enabled),
2099 /* 2737 */ // MIs[0] dst
2100 /* 2737 */ // No operand predicates
2101 /* 2737 */ // MIs[0] src0
2102 /* 2737 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
2103 /* 2741 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FCONSTANT),
2104 /* 2745 */ // MIs[1] cst
2105 /* 2745 */ // No operand predicates
2106 /* 2745 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
2107 /* 2747 */ // Combiner Rule #28: constant_fold_fpext
2108 /* 2747 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner10),
2109 /* 2750 */ // Label 144: @2750
2110 /* 2750 */ GIM_Reject,
2111 /* 2751 */ // Label 41: @2751
2112 /* 2751 */ GIM_Try, /*On fail goto*//*Label 145*/ GIMT_Encode4(2772), // Rule ID 47 //
2113 /* 2756 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule27Enabled),
2114 /* 2759 */ // MIs[0] dst
2115 /* 2759 */ // No operand predicates
2116 /* 2759 */ // MIs[0] src0
2117 /* 2759 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
2118 /* 2763 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FCONSTANT),
2119 /* 2767 */ // MIs[1] cst
2120 /* 2767 */ // No operand predicates
2121 /* 2767 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
2122 /* 2769 */ // Combiner Rule #27: constant_fold_fptrunc
2123 /* 2769 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner10),
2124 /* 2772 */ // Label 145: @2772
2125 /* 2772 */ GIM_Try, /*On fail goto*//*Label 146*/ GIMT_Encode4(2793), // Rule ID 37 //
2126 /* 2777 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule17Enabled),
2127 /* 2780 */ // MIs[0] dst
2128 /* 2780 */ // No operand predicates
2129 /* 2780 */ // MIs[0] src1
2130 /* 2780 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
2131 /* 2784 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FPEXT),
2132 /* 2788 */ // MIs[1] src0
2133 /* 2788 */ // No operand predicates
2134 /* 2788 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
2135 /* 2790 */ // Combiner Rule #17: fptrunc_fpext_fold
2136 /* 2790 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner7),
2137 /* 2793 */ // Label 146: @2793
2138 /* 2793 */ GIM_Reject,
2139 /* 2794 */ // Label 42: @2794
2140 /* 2794 */ GIM_Try, /*On fail goto*//*Label 147*/ GIMT_Encode4(2815), // Rule ID 90 //
2141 /* 2799 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule51Enabled),
2142 /* 2802 */ // MIs[0] dst
2143 /* 2802 */ // No operand predicates
2144 /* 2802 */ // MIs[0] __unary_undef_to_undef_match_0.x
2145 /* 2802 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
2146 /* 2806 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_IMPLICIT_DEF),
2147 /* 2810 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
2148 /* 2812 */ // Combiner Rule #51: unary_undef_to_undef @ [__unary_undef_to_undef_match_0[5]]
2149 /* 2812 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner24),
2150 /* 2815 */ // Label 147: @2815
2151 /* 2815 */ GIM_Reject,
2152 /* 2816 */ // Label 43: @2816
2153 /* 2816 */ GIM_Try, /*On fail goto*//*Label 148*/ GIMT_Encode4(2837), // Rule ID 91 //
2154 /* 2821 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule51Enabled),
2155 /* 2824 */ // MIs[0] dst
2156 /* 2824 */ // No operand predicates
2157 /* 2824 */ // MIs[0] __unary_undef_to_undef_match_0.x
2158 /* 2824 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
2159 /* 2828 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_IMPLICIT_DEF),
2160 /* 2832 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
2161 /* 2834 */ // Combiner Rule #51: unary_undef_to_undef @ [__unary_undef_to_undef_match_0[6]]
2162 /* 2834 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner24),
2163 /* 2837 */ // Label 148: @2837
2164 /* 2837 */ GIM_Reject,
2165 /* 2838 */ // Label 44: @2838
2166 /* 2838 */ GIM_Try, /*On fail goto*//*Label 149*/ GIMT_Encode4(2849), // Rule ID 74 //
2167 /* 2843 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule45Enabled),
2168 /* 2846 */ // Combiner Rule #45: undef_to_fp_zero; wip_match_opcode 'G_SITOFP'
2169 /* 2846 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner19),
2170 /* 2849 */ // Label 149: @2849
2171 /* 2849 */ GIM_Try, /*On fail goto*//*Label 150*/ GIMT_Encode4(2864), // Rule ID 56 //
2172 /* 2854 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule36Enabled),
2173 /* 2857 */ // MIs[0] dst
2174 /* 2857 */ // No operand predicates
2175 /* 2857 */ // MIs[0] Operand 1
2176 /* 2857 */ GIM_CheckConstantInt8, /*MI*/0, /*Op*/1, 0,
2177 /* 2861 */ // Combiner Rule #36: itof_const_zero_fold_si
2178 /* 2861 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner11),
2179 /* 2864 */ // Label 150: @2864
2180 /* 2864 */ GIM_Reject,
2181 /* 2865 */ // Label 45: @2865
2182 /* 2865 */ GIM_Try, /*On fail goto*//*Label 151*/ GIMT_Encode4(2876), // Rule ID 73 //
2183 /* 2870 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule45Enabled),
2184 /* 2873 */ // Combiner Rule #45: undef_to_fp_zero; wip_match_opcode 'G_UITOFP'
2185 /* 2873 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner19),
2186 /* 2876 */ // Label 151: @2876
2187 /* 2876 */ GIM_Try, /*On fail goto*//*Label 152*/ GIMT_Encode4(2891), // Rule ID 57 //
2188 /* 2881 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule37Enabled),
2189 /* 2884 */ // MIs[0] dst
2190 /* 2884 */ // No operand predicates
2191 /* 2884 */ // MIs[0] Operand 1
2192 /* 2884 */ GIM_CheckConstantInt8, /*MI*/0, /*Op*/1, 0,
2193 /* 2888 */ // Combiner Rule #37: itof_const_zero_fold_ui
2194 /* 2888 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner11),
2195 /* 2891 */ // Label 152: @2891
2196 /* 2891 */ GIM_Reject,
2197 /* 2892 */ // Label 46: @2892
2198 /* 2892 */ GIM_Try, /*On fail goto*//*Label 153*/ GIMT_Encode4(2921), // Rule ID 107 //
2199 /* 2897 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule62Enabled),
2200 /* 2900 */ // MIs[0] dst
2201 /* 2900 */ // No operand predicates
2202 /* 2900 */ // MIs[0] src
2203 /* 2900 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
2204 /* 2904 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FABS),
2205 /* 2908 */ // MIs[1] __idempotent_prop_match_0.x
2206 /* 2908 */ // No operand predicates
2207 /* 2908 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
2208 /* 2913 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
2209 /* 2915 */ // Combiner Rule #62: idempotent_prop @ [__idempotent_prop_match_0[1]]
2210 /* 2915 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
2211 /* 2920 */ GIR_EraseRootFromParent_Done,
2212 /* 2921 */ // Label 153: @2921
2213 /* 2921 */ GIM_Try, /*On fail goto*//*Label 154*/ GIMT_Encode4(2942), // Rule ID 44 //
2214 /* 2926 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule24Enabled),
2215 /* 2929 */ // MIs[0] dst
2216 /* 2929 */ // No operand predicates
2217 /* 2929 */ // MIs[0] src0
2218 /* 2929 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
2219 /* 2933 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FCONSTANT),
2220 /* 2937 */ // MIs[1] cst
2221 /* 2937 */ // No operand predicates
2222 /* 2937 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
2223 /* 2939 */ // Combiner Rule #24: constant_fold_fabs
2224 /* 2939 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner10),
2225 /* 2942 */ // Label 154: @2942
2226 /* 2942 */ GIM_Reject,
2227 /* 2943 */ // Label 47: @2943
2228 /* 2943 */ GIM_Try, /*On fail goto*//*Label 155*/ GIMT_Encode4(2972), // Rule ID 108 //
2229 /* 2948 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule62Enabled),
2230 /* 2951 */ // MIs[0] dst
2231 /* 2951 */ // No operand predicates
2232 /* 2951 */ // MIs[0] src
2233 /* 2951 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
2234 /* 2955 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FCANONICALIZE),
2235 /* 2959 */ // MIs[1] __idempotent_prop_match_0.x
2236 /* 2959 */ // No operand predicates
2237 /* 2959 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
2238 /* 2964 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
2239 /* 2966 */ // Combiner Rule #62: idempotent_prop @ [__idempotent_prop_match_0[2]]
2240 /* 2966 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
2241 /* 2971 */ GIR_EraseRootFromParent_Done,
2242 /* 2972 */ // Label 155: @2972
2243 /* 2972 */ GIM_Reject,
2244 /* 2973 */ // Label 48: @2973
2245 /* 2973 */ GIM_Try, /*On fail goto*//*Label 156*/ GIMT_Encode4(2984), // Rule ID 68 //
2246 /* 2978 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule43Enabled),
2247 /* 2981 */ // Combiner Rule #43: combine_minmax_nan; wip_match_opcode 'G_FMINNUM'
2248 /* 2981 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner17),
2249 /* 2984 */ // Label 156: @2984
2250 /* 2984 */ GIM_Reject,
2251 /* 2985 */ // Label 49: @2985
2252 /* 2985 */ GIM_Try, /*On fail goto*//*Label 157*/ GIMT_Encode4(2996), // Rule ID 69 //
2253 /* 2990 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule43Enabled),
2254 /* 2993 */ // Combiner Rule #43: combine_minmax_nan; wip_match_opcode 'G_FMAXNUM'
2255 /* 2993 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner17),
2256 /* 2996 */ // Label 157: @2996
2257 /* 2996 */ GIM_Reject,
2258 /* 2997 */ // Label 50: @2997
2259 /* 2997 */ GIM_Try, /*On fail goto*//*Label 158*/ GIMT_Encode4(3008), // Rule ID 70 //
2260 /* 3002 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule43Enabled),
2261 /* 3005 */ // Combiner Rule #43: combine_minmax_nan; wip_match_opcode 'G_FMINIMUM'
2262 /* 3005 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner17),
2263 /* 3008 */ // Label 158: @3008
2264 /* 3008 */ GIM_Reject,
2265 /* 3009 */ // Label 51: @3009
2266 /* 3009 */ GIM_Try, /*On fail goto*//*Label 159*/ GIMT_Encode4(3020), // Rule ID 71 //
2267 /* 3014 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule43Enabled),
2268 /* 3017 */ // Combiner Rule #43: combine_minmax_nan; wip_match_opcode 'G_FMAXIMUM'
2269 /* 3017 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner17),
2270 /* 3020 */ // Label 159: @3020
2271 /* 3020 */ GIM_Reject,
2272 /* 3021 */ // Label 52: @3021
2273 /* 3021 */ GIM_Try, /*On fail goto*//*Label 160*/ GIMT_Encode4(3032), // Rule ID 41 //
2274 /* 3026 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule21Enabled),
2275 /* 3029 */ // Combiner Rule #21: reassoc_ptradd; wip_match_opcode 'G_PTR_ADD'
2276 /* 3029 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner8),
2277 /* 3032 */ // Label 160: @3032
2278 /* 3032 */ GIM_Try, /*On fail goto*//*Label 161*/ GIMT_Encode4(3043), // Rule ID 58 //
2279 /* 3037 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule38Enabled),
2280 /* 3040 */ // Combiner Rule #38: const_ptradd_to_i2p; wip_match_opcode 'G_PTR_ADD'
2281 /* 3040 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner12),
2282 /* 3043 */ // Label 161: @3043
2283 /* 3043 */ GIM_Try, /*On fail goto*//*Label 162*/ GIMT_Encode4(3066), // Rule ID 8 //
2284 /* 3048 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule1Enabled),
2285 /* 3051 */ // MIs[0] dst
2286 /* 3051 */ // No operand predicates
2287 /* 3051 */ // MIs[0] lhs
2288 /* 3051 */ // No operand predicates
2289 /* 3051 */ // MIs[0] Operand 2
2290 /* 3051 */ GIM_CheckConstantInt8, /*MI*/0, /*Op*/2, 0,
2291 /* 3055 */ GIM_CheckCanReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
2292 /* 3060 */ // Combiner Rule #1: right_identity_zero @ [__right_identity_zero_match_0[7]]
2293 /* 3060 */ GIR_ReplaceReg, /*OldInsnID*/0, /*OldOpIdx*/0, /*NewInsnId*/0, /*NewOpIdx*/1,
2294 /* 3065 */ GIR_EraseRootFromParent_Done,
2295 /* 3066 */ // Label 162: @3066
2296 /* 3066 */ GIM_Reject,
2297 /* 3067 */ // Label 53: @3067
2298 /* 3067 */ GIM_Try, /*On fail goto*//*Label 163*/ GIMT_Encode4(3078), // Rule ID 84 //
2299 /* 3072 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule50Enabled),
2300 /* 3075 */ // Combiner Rule #50: unary_undef_to_zero; wip_match_opcode 'G_ABS'
2301 /* 3075 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner22),
2302 /* 3078 */ // Label 163: @3078
2303 /* 3078 */ GIM_Reject,
2304 /* 3079 */ // Label 54: @3079
2305 /* 3079 */ GIM_Try, /*On fail goto*//*Label 164*/ GIMT_Encode4(3090), // Rule ID 99 //
2306 /* 3084 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule56Enabled),
2307 /* 3087 */ // Combiner Rule #56: insert_extract_vec_elt_out_of_bounds; wip_match_opcode 'G_INSERT_VECTOR_ELT'
2308 /* 3087 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner29),
2309 /* 3090 */ // Label 164: @3090
2310 /* 3090 */ GIM_Reject,
2311 /* 3091 */ // Label 55: @3091
2312 /* 3091 */ GIM_Try, /*On fail goto*//*Label 165*/ GIMT_Encode4(3102), // Rule ID 100 //
2313 /* 3096 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule56Enabled),
2314 /* 3099 */ // Combiner Rule #56: insert_extract_vec_elt_out_of_bounds; wip_match_opcode 'G_EXTRACT_VECTOR_ELT'
2315 /* 3099 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner29),
2316 /* 3102 */ // Label 165: @3102
2317 /* 3102 */ GIM_Reject,
2318 /* 3103 */ // Label 56: @3103
2319 /* 3103 */ GIM_Try, /*On fail goto*//*Label 166*/ GIMT_Encode4(3114), // Rule ID 95 //
2320 /* 3108 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule53Enabled),
2321 /* 3111 */ // Combiner Rule #53: propagate_undef_all_ops; wip_match_opcode 'G_SHUFFLE_VECTOR'
2322 /* 3111 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner26),
2323 /* 3114 */ // Label 166: @3114
2324 /* 3114 */ GIM_Try, /*On fail goto*//*Label 167*/ GIMT_Encode4(3125), // Rule ID 97 //
2325 /* 3119 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule54Enabled),
2326 /* 3122 */ // Combiner Rule #54: propagate_undef_shuffle_mask; wip_match_opcode 'G_SHUFFLE_VECTOR'
2327 /* 3122 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner27),
2328 /* 3125 */ // Label 167: @3125
2329 /* 3125 */ GIM_Reject,
2330 /* 3126 */ // Label 57: @3126
2331 /* 3126 */ GIM_Try, /*On fail goto*//*Label 168*/ GIMT_Encode4(3147), // Rule ID 49 //
2332 /* 3131 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule29Enabled),
2333 /* 3134 */ // MIs[0] dst
2334 /* 3134 */ // No operand predicates
2335 /* 3134 */ // MIs[0] src0
2336 /* 3134 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
2337 /* 3138 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FCONSTANT),
2338 /* 3142 */ // MIs[1] cst
2339 /* 3142 */ // No operand predicates
2340 /* 3142 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
2341 /* 3144 */ // Combiner Rule #29: constant_fold_fceil
2342 /* 3144 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner10),
2343 /* 3147 */ // Label 168: @3147
2344 /* 3147 */ GIM_Reject,
2345 /* 3148 */ // Label 58: @3148
2346 /* 3148 */ GIM_Try, /*On fail goto*//*Label 169*/ GIMT_Encode4(3169), // Rule ID 45 //
2347 /* 3153 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule25Enabled),
2348 /* 3156 */ // MIs[0] dst
2349 /* 3156 */ // No operand predicates
2350 /* 3156 */ // MIs[0] src0
2351 /* 3156 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
2352 /* 3160 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FCONSTANT),
2353 /* 3164 */ // MIs[1] cst
2354 /* 3164 */ // No operand predicates
2355 /* 3164 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
2356 /* 3166 */ // Combiner Rule #25: constant_fold_fsqrt
2357 /* 3166 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner10),
2358 /* 3169 */ // Label 169: @3169
2359 /* 3169 */ GIM_Reject,
2360 /* 3170 */ // Label 59: @3170
2361 /* 3170 */ GIM_Try, /*On fail goto*//*Label 170*/ GIMT_Encode4(3191), // Rule ID 50 //
2362 /* 3175 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule30Enabled),
2363 /* 3178 */ // MIs[0] dst
2364 /* 3178 */ // No operand predicates
2365 /* 3178 */ // MIs[0] src0
2366 /* 3178 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
2367 /* 3182 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FCONSTANT),
2368 /* 3186 */ // MIs[1] cst
2369 /* 3186 */ // No operand predicates
2370 /* 3186 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
2371 /* 3188 */ // Combiner Rule #30: constant_fold_ffloor
2372 /* 3188 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner10),
2373 /* 3191 */ // Label 170: @3191
2374 /* 3191 */ GIM_Reject,
2375 /* 3192 */ // Label 60: @3192
2376 /* 3192 */ GIM_Try, /*On fail goto*//*Label 171*/ GIMT_Encode4(3213), // Rule ID 54 //
2377 /* 3197 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule34Enabled),
2378 /* 3200 */ // MIs[0] dst
2379 /* 3200 */ // No operand predicates
2380 /* 3200 */ // MIs[0] src0
2381 /* 3200 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
2382 /* 3204 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FCONSTANT),
2383 /* 3208 */ // MIs[1] cst
2384 /* 3208 */ // No operand predicates
2385 /* 3208 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
2386 /* 3210 */ // Combiner Rule #34: constant_fold_frint
2387 /* 3210 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner10),
2388 /* 3213 */ // Label 171: @3213
2389 /* 3213 */ GIM_Reject,
2390 /* 3214 */ // Label 61: @3214
2391 /* 3214 */ GIM_Try, /*On fail goto*//*Label 172*/ GIMT_Encode4(3235), // Rule ID 55 //
2392 /* 3219 */ GIM_CheckSimplePredicate, GIMT_Encode2(GICXXPred_Simple_IsRule35Enabled),
2393 /* 3222 */ // MIs[0] dst
2394 /* 3222 */ // No operand predicates
2395 /* 3222 */ // MIs[0] src0
2396 /* 3222 */ GIM_RecordInsnIgnoreCopies, /*DefineMI*/1, /*MI*/0, /*OpIdx*/1, // MIs[1]
2397 /* 3226 */ GIM_CheckOpcode, /*MI*/1, GIMT_Encode2(TargetOpcode::G_FCONSTANT),
2398 /* 3230 */ // MIs[1] cst
2399 /* 3230 */ // No operand predicates
2400 /* 3230 */ GIM_CheckIsSafeToFold, /*NumInsns*/1,
2401 /* 3232 */ // Combiner Rule #35: constant_fold_fnearbyint
2402 /* 3232 */ GIR_DoneWithCustomAction, /*Fn*/GIMT_Encode2(GICXXCustomAction_GICombiner10),
2403 /* 3235 */ // Label 172: @3235
2404 /* 3235 */ GIM_Reject,
2405 /* 3236 */ // Label 62: @3236
2406 /* 3236 */ GIM_Reject,
2407 /* 3237 */ }; // Size: 3237 bytes
2408 return MatchTable0;
2409}
2410#undef GIMT_Encode2
2411#undef GIMT_Encode4
2412#undef GIMT_Encode8
2413
2414
2415#endif // GET_GICOMBINER_IMPL
2416
2417#ifdef GET_GICOMBINER_CONSTRUCTOR_INITS
2418
2419AvailableModuleFeatures(computeAvailableModuleFeatures(&STI)),
2420AvailableFunctionFeatures()
2421
2422#endif // GET_GICOMBINER_CONSTRUCTOR_INITS
2423
2424#ifdef GET_GICOMBINER_CONSTRUCTOR_INITS
2425
2426, State(0),
2427ExecInfo(TypeObjects, NumTypeObjects, FeatureBitsets, ComplexPredicateFns, CustomRenderers)
2428
2429#endif // GET_GICOMBINER_CONSTRUCTOR_INITS
2430
2431