Lines Matching refs:hi

68 #define TwoWayPartition1(X, pivot, t1, lo, hi, l, r) \  argument
71 r = hi; \
101 #define TwoWayPartitionReverse1(X, pivot, t1, lo, hi, l, r) \ argument
104 r = hi; \
118 #define TwoWayPartition2(X, Y, pivot, t1, t2, lo, hi, l, r) \ argument
121 r = hi; \
135 #define TwoWayPartition3(X, Y, Z, pivot, t1, t2, t3, lo, hi, l, r) \ argument
138 r = hi; \
155 PetscCount i, j, p, l, r, hi = n - 1; \
167 p = MEDIAN(X, hi); \
169 TwoWayPartition1(X, pivot, t1, 0, hi, l, r); \
171 PetscCall(FuncName(hi - r + 1, X + r)); \
178 PetscCount i, j, p, l, r, hi = n - 1; \
190 p = MEDIAN(X, hi); \
192 TwoWayPartitionReverse1(X, pivot, t1, 0, hi, l, r); \
194 PetscCall(FuncName(hi - r + 1, X + r)); \
200 PetscCount i, j, p, l, r, hi = n - 1; \
212 p = MEDIAN(X, hi); \
214 TwoWayPartition2(X, Y, pivot, t1, t2, 0, hi, l, r); \
216 PetscCall(FuncName(hi - r + 1, X + r, Y + r)); \
222 PetscCount i, j, p, l, r, hi = n - 1; \
234 p = MEDIAN(X, hi); \
236 TwoWayPartition3(X, Y, Z, pivot, t1, t2, t3, 0, hi, l, r); \
238 PetscCall(FuncName(hi - r + 1, X + r, Y + r, Z + r)); \
537 PetscInt lo = 0, hi; in PetscFindInt() local
546 PetscCall(PetscIntCast(n, &hi)); in PetscFindInt()
547 while (hi - lo > 1) { in PetscFindInt()
548 PetscInt mid = lo + (hi - lo) / 2; in PetscFindInt()
549hi - 1], PETSC_COMM_SELF, PETSC_ERR_ARG_WRONG, "Input array was not sorted: (%" PetscInt_FMT ", %"… in PetscFindInt()
550 if (key < X[mid]) hi = mid; in PetscFindInt()
576 PetscCount lo = 0, hi; in PetscFindCount() local
585 hi = n; in PetscFindCount()
586 while (hi - lo > 1) { in PetscFindCount()
587 PetscCount mid = lo + (hi - lo) / 2; in PetscFindCount()
588hi - 1], PETSC_COMM_SELF, PETSC_ERR_ARG_WRONG, "Input array was not sorted: (%" PetscCount_FMT ", … in PetscFindCount()
589 if (key < X[mid]) hi = mid; in PetscFindCount()
656 PetscCount lo = 0, hi = n; in PetscFindMPIInt() local
665 while (hi - lo > 1) { in PetscFindMPIInt()
666 PetscCount mid = lo + (hi - lo) / 2; in PetscFindMPIInt()
667 …[mid] && X[mid] <= X[hi - 1], PETSC_COMM_SELF, PETSC_ERR_ARG_WRONG, "Input array was not sorted: (… in PetscFindMPIInt()
668 if (key < X[mid]) hi = mid; in PetscFindMPIInt()
983 PetscCount hi = n - 1; in PetscSortIntWithDataArray() local
999 PetscCount l = 0, r = hi; in PetscSortIntWithDataArray()
1001 pivot = X[MEDIAN(X, hi)]; in PetscSortIntWithDataArray()
1014 PetscCall(PetscSortIntWithDataArray(hi - r + 1, X + r, YY + size * r, size, t2)); in PetscSortIntWithDataArray()