• Home
  • Raw
  • Download

Lines Matching refs:child_index

10874       int child_index = 2 * parent_index + 1;  in Sort()  local
10875 uint32_t child_hash = GetSortedKey(child_index)->Hash(); in Sort()
10876 if (child_index + 1 < len) { in Sort()
10877 uint32_t right_child_hash = GetSortedKey(child_index + 1)->Hash(); in Sort()
10879 child_index++; in Sort()
10884 SwapSortedKeys(parent_index, child_index); in Sort()
10886 parent_index = child_index; // parent_hash remains correct. in Sort()
10899 int child_index = parent_index * 2 + 1; in Sort() local
10900 uint32_t child_hash = GetSortedKey(child_index)->Hash(); in Sort()
10901 if (child_index + 1 < i) { in Sort()
10902 uint32_t right_child_hash = GetSortedKey(child_index + 1)->Hash(); in Sort()
10904 child_index++; in Sort()
10909 SwapSortedKeys(parent_index, child_index); in Sort()
10910 parent_index = child_index; in Sort()
16328 int child_index = i; in HeapSortPairs() local
16329 while (child_index > 0) { in HeapSortPairs()
16330 int parent_index = ((child_index + 1) >> 1) - 1; in HeapSortPairs()
16332 uint32_t child_value = NumberToUint32(numbers->get(child_index)); in HeapSortPairs()
16334 content->SwapPairs(numbers, parent_index, child_index); in HeapSortPairs()
16338 child_index = parent_index; in HeapSortPairs()
16349 int child_index = ((parent_index + 1) << 1) - 1; in HeapSortPairs() local
16350 if (child_index >= i) break; in HeapSortPairs()
16351 uint32_t child1_value = NumberToUint32(numbers->get(child_index)); in HeapSortPairs()
16352 uint32_t child2_value = NumberToUint32(numbers->get(child_index + 1)); in HeapSortPairs()
16354 if (child_index + 1 >= i || child1_value > child2_value) { in HeapSortPairs()
16356 content->SwapPairs(numbers, parent_index, child_index); in HeapSortPairs()
16357 parent_index = child_index; in HeapSortPairs()
16360 content->SwapPairs(numbers, parent_index, child_index + 1); in HeapSortPairs()
16361 parent_index = child_index + 1; in HeapSortPairs()