Lines Matching refs:InitReg
1271 // Map from <LoopReg, InitReg> to phi register for all created phis. Note that
1272 // this map is only used when InitReg is non-undef.
1274 // Map from LoopReg to phi register where the InitReg is undef.
1280 // Insert a phi that carries LoopReg from the loop body and InitReg otherwise.
1281 // If InitReg is not given it is chosen arbitrarily. It will either be undef
1283 Register phi(Register LoopReg, std::optional<Register> InitReg = {},
1468 Register KernelRewriter::phi(Register LoopReg, std::optional<Register> InitReg,
1471 if (InitReg) {
1472 auto I = Phis.find({LoopReg, *InitReg});
1482 // InitReg is either undef or no existing phi takes InitReg as input. Try and
1487 if (!InitReg)
1491 // Found a phi taking undef as input, so rewrite it to take InitReg.
1493 MI->getOperand(1).setReg(*InitReg);
1494 Phis.insert({{LoopReg, *InitReg}, R});
1496 MRI.constrainRegClass(R, MRI.getRegClass(*InitReg));
1507 if (InitReg) {
1509 MRI.constrainRegClass(R, MRI.getRegClass(*InitReg));
1514 .addReg(InitReg ? *InitReg : undef(RC))
1518 if (!InitReg)
1521 Phis[{LoopReg, *InitReg}] = R;