AVL(9F) Kernel Functions for Drivers AVL(9F)

NAME


avl, avl_add, avl_create, avl_destroy, avl_destroy_nodes, avl_find,
avl_first, avl_insert, avl_insert_here, avl_is_empty, avl_last,
avl_nearest, avl_numnodes, avl_remove, avl_swap, avl_update,
avl_update_gt, avl_update_lt, AVL_NEXT, AVL_PREV - AVL tree routines

DESCRIPTION


AVL trees are a general purpose, self-balancing binary tree that can be
used instead of the standard linked list interfaces -- list_create(9F).
AVL trees are particularly useful either when order is important or
better lookup performance is required.

The AVL tree interfaces are identical in both userland and the kernel.
For more general information on AVL trees, see libavl(3LIB). For more
information on any of the functions defined here, please see the
corresponding manual page in section 3AVL. Please note, that while the
descriptions in those manual pages are accurate for writers of Device
Drivers, the examples provided use scaffolding not available in the
kernel, such as the use of malloc(), and need to be adapted.

CONTEXT


All of the AVL routines may be used in user, kernel, and interrupt
context.

EXAMPLES


See EXAMPLES in libavl(3LIB).

INTERFACE STABILITY


Committed

MT-Safety
AVL trees do not inherently have any internal locking, it is up to the
consumer to use locks as appropriate. See mutex(9F) and rwlock(9F) for
more information on synchronization primitives.

SEE ALSO


avl_add(3AVL), avl_create(3AVL), avl_destroy(3AVL),
avl_destroy_nodes(3AVL), avl_find(3AVL), avl_first(3AVL),
avl_insert(3AVL), avl_insert_here(3AVL), avl_is_empty(3AVL),
avl_last(3AVL), avl_nearest(3AVL), AVL_NEXT(3AVL), avl_numnodes(3AVL),
AVL_PREV(3AVL), avl_remove(3AVL), avl_swap(3AVL), avl_update(3AVL),
avl_update_gt(3AVL), avl_update_lt(3AVL), libavl(3LIB)

Writing Device Drivers.

illumos February 27, 2024 illumos

tribblix@gmail.com :: GitHub :: Privacy