Home | History | Annotate | Download | only in Scalar

Lines Matching full:rank

15 // In the implementation of this algorithm, constants are assigned rank = 0,
16 // function arguments are rank = 1, and other values are assigned ranks
18 // (starting at 2), which effectively gives values in deep loops higher rank
52 unsigned Rank;
54 ValueEntry(unsigned R, Value *O) : Rank(R), Op(O) {}
57 return LHS.Rank > RHS.Rank; // Sort so that highest rank goes to start.
71 dbgs() << ", #" << Ops[i].Rank << "] ";
211 return 0; // Otherwise it's a global or constant, rank 0.
214 if (unsigned Rank = ValueRankMap[I])
215 return Rank; // Rank already known?
217 // If this is an expression, return the 1+MAX(rank(LHS), rank(RHS)) so that
221 unsigned Rank = 0, MaxRank = RankMap[I->getParent()];
223 i != e && Rank != MaxRank; ++i)
224 Rank = std::max(Rank, getRank(I->getOperand(i)));
226 // If this is a not or neg instruction, do not count it for rank. This
227 // assures us that X and ~X will have the same rank.
230 ++Rank;
232 //DEBUG(dbgs() << "Calculated Rank[" << V->getName() << "] = "
233 // << Rank << "\n");
235 return ValueRankMap[I] = Rank;
930 /// rank as element i to see if X exists. If X does not exist, return i. This
932 /// same rank.
935 unsigned XRank = Ops[i].Rank;
937 for (unsigned j = i+1; j != e && Ops[j].Rank == XRank; ++j)
941 for (unsigned j = i-1; j != ~0U && Ops[j].Rank == XRank; --j)
1540 // Sort the operands by rank.
1616 // the operands and their ranks, sort the operands by their rank. Use a
1674 // Calculate the rank map for F
1699 // We are done with the rank map.