Lines Matching defs:best
111 // find the best span (closest to n in size).
112 // The following loops implements address-ordered best-fit.
113 Span *best = NULL;
120 if ((best == NULL)
121 || (span->length < best->length)
122 || ((span->length == best->length) && (span->start < best->start))) {
123 best = span;
124 ASSERT(best->location == Span::ON_NORMAL_FREELIST);
134 if ((best == NULL)
135 || (span->length < best->length)
136 || ((span->length == best->length) && (span->start < best->start))) {
137 best = span;
138 ASSERT(best->location == Span::ON_RETURNED_FREELIST);
143 return best == NULL ? NULL : Carve(best, n);