Lines Matching defs:Num

714   uint32_t Num = valueNumbering.lookup(V);
718 NumberingPhi.erase(Num);
2268 bool GVNPass::ValueTable::areAllValsInBB(uint32_t Num, const BasicBlock *BB,
2271 Gvn.LeaderTable.getLeaders(Num),
2278 uint32_t Num, GVNPass &Gvn) {
2279 auto FindRes = PhiTranslateTable.find({Num, Pred});
2282 uint32_t NewNum = phiTranslateImpl(Pred, PhiBlock, Num, Gvn);
2283 PhiTranslateTable.insert({{Num, Pred}, NewNum});
2287 // Return true if the value number \p Num and NewNum have equal value.
2289 bool GVNPass::ValueTable::areCallValsEqual(uint32_t Num, uint32_t NewNum,
2294 auto Leaders = Gvn.LeaderTable.getLeaders(Num);
2322 /// Translate value number \p Num using phis, so that it has the values of
2326 uint32_t Num, GVNPass &Gvn) {
2327 if (PHINode *PN = NumberingPhi[Num]) {
2333 return Num;
2336 // If there is any value related with Num is defined in a BB other than
2339 if (!areAllValsInBB(Num, PhiBlock, Gvn))
2340 return Num;
2342 if (Num >= ExprIdx.size() || ExprIdx[Num] == 0)
2343 return Num;
2344 Expression Exp = Expressions[ExprIdx[Num]];
2370 if (Exp.opcode == Instruction::Call && NewNum != Num)
2371 return areCallValsEqual(Num, NewNum, Pred, PhiBlock, Gvn) ? NewNum : Num;
2374 return Num;
2380 uint32_t Num, const BasicBlock &CurrBlock) {
2382 PhiTranslateTable.erase({Num, Pred});
2581 uint32_t Num = VN.lookupOrAddCmp(Cmp->getOpcode(), NotPred, Op0, Op1);
2584 if (Num < NextNum) {
2585 Value *NotCmp = findLeader(Root.getEnd(), Num);
2604 LeaderTable.insert(Num, NotVal, Root.getEnd());
2653 unsigned Num = VN.lookupOrAdd(Load);
2654 LeaderTable.insert(Num, Load, Load->getParent());
2717 unsigned Num = VN.lookupOrAdd(I);
2722 LeaderTable.insert(Num, I, I->getParent());
2729 if (Num >= NextNum) {
2730 LeaderTable.insert(Num, I, I->getParent());
2736 Value *Repl = findLeader(I->getParent(), Num);
2739 LeaderTable.insert(Num, I, I->getParent());
2930 unsigned Num = VN.lookupOrAdd(Instr);
2931 VN.add(Instr, Num);
2934 LeaderTable.insert(Num, Instr, Pred);