@@ -45,11 +45,11 @@ kmem_cache_t *btree_leaf_cache;
45
45
* of each node is poisoned appropriately. Note that poisoning always occurs if
46
46
* ZFS_DEBUG is set, so it is safe to set the intensity to 5 during normal
47
47
* operation.
48
- *
48
+ *
49
49
* Intensity 4 and 5 are particularly expensive to perform; the previous levels
50
50
* are a few memory operations per node, while these levels require multiple
51
51
* operations per element. In addition, when creating large btrees, these
52
- * operations are called at every step, resulting in extremely sloww operation
52
+ * operations are called at every step, resulting in extremely slow operation
53
53
* (while the asymptotic complexity of the other steps is the same, the
54
54
* importance of the constant factors cannot be denied).
55
55
*/
@@ -60,9 +60,9 @@ int btree_verify_intensity = 0;
60
60
#endif
61
61
62
62
#ifdef _ILP32
63
- #define BTREE_POISON 0xabadb10c
63
+ #define BTREE_POISON 0xabadb10c
64
64
#else
65
- #define BTREE_POISON 0xabadb10cdeadbeef
65
+ #define BTREE_POISON 0xabadb10cdeadbeef
66
66
#endif
67
67
68
68
#ifdef ZFS_DEBUG
@@ -406,7 +406,7 @@ bt_shleft_at_leaf(btree_t *tree, btree_leaf_t *leaf, uint64_t idx,
406
406
}
407
407
408
408
static inline void
409
- bt_transfer_core (btree_t * tree , btree_core_t * source , uint64_t sidx ,
409
+ bt_transfer_core (btree_t * tree , btree_core_t * source , uint64_t sidx ,
410
410
uint64_t count , btree_core_t * dest , uint64_t didx , boolean_t trap )
411
411
{
412
412
size_t size = tree -> bt_elem_size ;
@@ -423,7 +423,7 @@ bt_transfer_core(btree_t* tree, btree_core_t *source, uint64_t sidx,
423
423
}
424
424
425
425
static inline void
426
- bt_transfer_leaf (btree_t * tree , btree_leaf_t * source , uint64_t sidx ,
426
+ bt_transfer_leaf (btree_t * tree , btree_leaf_t * source , uint64_t sidx ,
427
427
uint64_t count , btree_leaf_t * dest , uint64_t didx )
428
428
{
429
429
size_t size = tree -> bt_elem_size ;
@@ -572,7 +572,8 @@ btree_insert_into_parent(btree_t *tree, btree_hdr_t *old_node,
572
572
* Copy the back part of the elements and children to the new
573
573
* leaf.
574
574
*/
575
- bt_transfer_core (tree , parent , keep_count , move_count , new_parent , 0 , B_TRUE );
575
+ bt_transfer_core (tree , parent , keep_count , move_count ,
576
+ new_parent , 0 , B_TRUE );
576
577
577
578
/* Store the new separator in a buffer. */
578
579
uint8_t * tmp_buf = kmem_alloc (size , KM_SLEEP );
@@ -583,7 +584,8 @@ btree_insert_into_parent(btree_t *tree, btree_hdr_t *old_node,
583
584
* Shift the remaining elements and children in the front half
584
585
* to handle the new value.
585
586
*/
586
- bt_shright_at_core (tree , parent , offset , keep_count - 1 - offset , B_FALSE );
587
+ bt_shright_at_core (tree , parent , offset , keep_count - 1 -
588
+ offset , B_FALSE );
587
589
588
590
uint8_t * e_start = parent -> btc_elems + offset * size ;
589
591
bcopy (buf , e_start , size );
@@ -930,7 +932,8 @@ btree_bulk_finish(btree_t *tree)
930
932
}
931
933
}
932
934
/* First, shift things in the right node back. */
933
- bt_shift_at_core (tree , cur , 0 , hdr -> bth_count , move_count , B_TRUE , B_FALSE );
935
+ bt_shift_at_core (tree , cur , 0 , hdr -> bth_count , move_count ,
936
+ B_TRUE , B_FALSE );
934
937
935
938
/* Next, move the separator to the right node. */
936
939
uint8_t * separator = parent -> btc_elems + ((parent_idx - 1 ) *
@@ -944,7 +947,8 @@ btree_bulk_finish(btree_t *tree)
944
947
*/
945
948
move_count -- ;
946
949
uint64_t move_idx = l_neighbor -> btc_hdr .bth_count - move_count ;
947
- bt_transfer_core (tree , l_neighbor , move_idx , move_count , cur , 0 , B_TRUE );
950
+ bt_transfer_core (tree , l_neighbor , move_idx , move_count , cur , 0 ,
951
+ B_TRUE );
948
952
949
953
/*
950
954
* Finally, move the last element in the left node to the
@@ -1485,8 +1489,8 @@ btree_remove_from_node(btree_t *tree, btree_core_t *node, btree_hdr_t *rm_hdr)
1485
1489
bcopy (separator , e_out , size );
1486
1490
1487
1491
/* Move all our elements and children into the left node. */
1488
- bt_transfer_core (tree , node , 0 , idx - 1 , left , l_hdr -> bth_count +
1489
- 1 , B_TRUE );
1492
+ bt_transfer_core (tree , node , 0 , idx - 1 , left ,
1493
+ l_hdr -> bth_count + 1 , B_TRUE );
1490
1494
bt_transfer_core (tree , node , idx , hdr -> bth_count - idx + 1 ,
1491
1495
left , l_hdr -> bth_count + idx , B_FALSE );
1492
1496
0 commit comments