Lines Matching refs:cmp
69 med3(char *a, char *b, char *c, int (*cmp)(const void *, const void *)) in med3()
71 return cmp(a, b) < 0 ? in med3()
72 (cmp(b, c) < 0 ? b : (cmp(a, c) < 0 ? c : a )) in med3()
73 :(cmp(b, c) > 0 ? b : (cmp(a, c) < 0 ? a : c )); in med3()
76 qsort(void *aa, size_t n, size_t es, int (*cmp)(const void *, const void *)) in qsort()
85 for (pl = pm; pl > (char *) a && cmp(pl - es, pl) > 0; in qsort()
96 pl = med3(pl, pl + d, pl + 2 * d, cmp); in qsort()
97 pm = med3(pm - d, pm, pm + d, cmp); in qsort()
98 pn = med3(pn - 2 * d, pn - d, pn, cmp); in qsort()
100 pm = med3(pl, pm, pn, cmp); in qsort()
107 while (pb <= pc && (r = cmp(pb, a)) <= 0) { in qsort()
115 while (pb <= pc && (r = cmp(pc, a)) >= 0) { in qsort()
132 for (pl = pm; pl > (char *) a && cmp(pl - es, pl) > 0; in qsort()
143 qsort(a, r / es, es, cmp); in qsort()