Index: lib/CodeGen/GlobalISel/CSEMIRBuilder.cpp =================================================================== --- lib/CodeGen/GlobalISel/CSEMIRBuilder.cpp +++ lib/CodeGen/GlobalISel/CSEMIRBuilder.cpp @@ -39,6 +39,7 @@ MachineInstr *MI = CSEInfo->getMachineInstrIfExists(ID, CurMBB, NodeInsertPos); if (MI) { + CSEInfo->countOpcodeHit(MI->getOpcode()); auto CurrPos = getInsertPt(); if (!dominates(MI, CurrPos)) CurMBB->splice(CurrPos, CurMBB, MI);