[llvm] [AMDGPU] Enable CSE in the GlobalISel post-legalizer combiner (PR #217258)

Vikram Hegde via llvm-commits llvm-commits at lists.llvm.org
Wed Aug 19 03:26:29 PDT 2026


================
@@ -496,23 +501,29 @@ bool AMDGPUPostLegalizerCombiner::runOnMachineFunction(MachineFunction &MF) {
       IsOptNone ? nullptr
                 : &getAnalysis<MachineDominatorTreeWrapperPass>().getDomTree();
 
+  GISelCSEAnalysisWrapper &Wrapper =
+      getAnalysis<GISelCSEAnalysisWrapperPass>().getCSEWrapper();
+  GISelCSEInfo *CSEInfo = &Wrapper.get(TPC.getCSEConfig());
----------------
vikramRH wrote:

we should probably avoid using TargetPassConfig and use "getStandardCSEConfigForOpt" directly instead.

https://github.com/llvm/llvm-project/pull/217258


More information about the llvm-commits mailing list