@@ -348,18 +348,6 @@ bool GenXTargetMachine::addPassesToEmitFile(PassManagerBase &PM,
348
348
vc::addPass (PM, createGenXReduceIntSizePass ());
349
349
// / .. include:: GenXGlobalValueLowering.cpp
350
350
vc::addPass (PM, createGenXGlobalValueLoweringPass ());
351
- // / InstructionCombining
352
- // / --------------------
353
- // / This is a standard LLVM pass, used at this point in the GenX backend.
354
- // /
355
- vc::addPass (PM, createInstructionCombiningPass ());
356
- // Run integer reduction again to revert some trunc/ext patterns transformed
357
- // by instcombine.
358
- vc::addPass (PM, createGenXReduceIntSizePass ());
359
- // / .. include:: GenXSimdCFConformance.cpp
360
- vc::addPass (PM, createGenXEarlySimdCFConformancePass ());
361
- // / .. include:: GenXPromotePredicate.cpp
362
- vc::addPass (PM, createGenXPromotePredicatePass ());
363
351
364
352
// / .. include:: GenXStackUsage.cpp
365
353
vc::addPass (PM, createGenXStackUsagePass ());
@@ -373,6 +361,20 @@ bool GenXTargetMachine::addPassesToEmitFile(PassManagerBase &PM,
373
361
vc::addPass (PM, createGenXLoadStoreLoweringPass ());
374
362
vc::addPass (PM, createGenXThreadPrivateMemoryPass ());
375
363
364
+ // / InstructionCombining
365
+ // / --------------------
366
+ // / This is a standard LLVM pass, used at this point in the GenX backend.
367
+ // / Run instcombine after some lowering passes (e.g. GenXLoadStoreLowering) to
368
+ // / make a cleanup.
369
+ vc::addPass (PM, createInstructionCombiningPass ());
370
+ // Run integer reduction again to revert some trunc/ext patterns transformed
371
+ // by instcombine.
372
+ vc::addPass (PM, createGenXReduceIntSizePass ());
373
+ // / .. include:: GenXSimdCFConformance.cpp
374
+ vc::addPass (PM, createGenXEarlySimdCFConformancePass ());
375
+ // / .. include:: GenXPromotePredicate.cpp
376
+ vc::addPass (PM, createGenXPromotePredicatePass ());
377
+
376
378
// Run GEP lowering again to remove possible GEPs after instcombine.
377
379
vc::addPass (PM, createGenXGEPLoweringPass ());
378
380
// / .. include:: GenXLowering.cpp
0 commit comments