228 vm_abort(
"avl_insert_intern: node already in the tree");
236 if (tmpnode->
childs[direction]) {
248 tmpnode->
childs[direction] = newnode;
261 if ((balance != 0) && (tmpnode->
balance != 0)) {
279 else if (tmpnode->
balance > 1) {
326 if (tree->
root == NULL)
362 for (node = tree->
root; node != NULL; ) {
static void avl_rotate_left(avl_node_t **node)
Dummy implementation of a mutex.
bool avl_insert(avl_tree_t *tree, void *data)
void vm_abort(const char *text,...)
avl_comparator * comparator
void log_print(const char *text,...)
void * avl_find(avl_tree_t *tree, void *data)
Instruction::InstID tmp[]
s4 avl_comparator(const void *treenode, const void *node)
void unlock()
Unlocks the given mutex object and checks for errors.
static void avl_adjust_balance(avl_node_t *node)
static s4 avl_insert_intern(avl_tree_t *tree, avl_node_t **node, void *data)
Mutex * mutex
Mutex to lock the tree.
static avl_node_t * avl_newnode(void *data)
void lock()
Locks the given mutex object and checks for errors.
void avl_dump(avl_node_t *node, s4 indent)
avl_tree_t * avl_create(avl_comparator *comparator)
static void avl_rotate_right(avl_node_t **node)