Lines Matching refs:top
270 struct btree_iter_set *top = iter->data, *i = top + 1;
276 if (bkey_cmp(top->k, &START_KEY(i->k)) <= 0)
281 heap_sift(iter, i - top, bch_extent_sort_cmp);
285 if (top->k > i->k) {
286 if (bkey_cmp(top->k, i->k) >= 0)
289 bch_cut_front(top->k, i->k);
291 heap_sift(iter, i - top, bch_extent_sort_cmp);
294 BUG_ON(!bkey_cmp(&START_KEY(top->k), &START_KEY(i->k)));
296 if (bkey_cmp(i->k, top->k) < 0) {
297 bkey_copy(tmp, top->k);
300 bch_cut_front(i->k, top->k);
305 bch_cut_back(&START_KEY(i->k), top->k);
405 struct bkey *top;
412 * We insert a new key to cover the top of the
417 * is the top or the bottom, but it has to match
420 * depends on us inserting a new key for the top
423 top = bch_bset_search(b, bset_tree_last(b),
425 bch_bset_insert(b, top, k);
430 top = bkey_next(k);
433 bch_cut_front(insert, top);