Home | History | Annotate | Download | only in llvm-diff

Lines Matching refs:Index

52     unsigned Index = Storage.size();
54 if (Index == 0) return;
58 unsigned Target = (Index + 1) / 2 - 1;
59 if (!Precedes(data[Index], data[Target])) return;
60 std::swap(data[Index], data[Target]);
62 Index = Target;
80 unsigned Index = 0;
82 // With a 1-based index, the children would be Index*2 and Index*2+1.
83 unsigned R = (Index + 1) * 2;
91 // Otherwise, test whether we should swap L and Index.
92 if (Precedes(Storage[L], Storage[Index]))
93 std::swap(Storage[L], Storage[Index]);
101 // If Index is >= the min of L and R, then heap ordering is restored.
102 if (!Precedes(Storage[IndexToTest], Storage[Index]))
106 std::swap(Storage[IndexToTest], Storage[Index]);
107 Index = IndexToTest;
519 unsigned Index = 1;
520 for (BasicBlock::iterator LI = LStart; LI != LE; ++LI, ++Index) {
522 Next[Index] = Cur[Index-1];
523 Next[Index].Cost += MatchCost;
524 Next[Index].Path.push_back(DC_match);
526 } else if (Next[Index-1].Cost <= Cur[Index].Cost) {
527 Next[Index] = Next[Index-1];
528 Next[Index].Cost += LeftCost;
529 Next[Index].Path.push_back(DC_left);
531 Next[Index] = Cur[Index];
532 Next[Index].Cost += RightCost;
533 Next[Index].Path.push_back(DC_right);