Lines Matching refs:AvlNode

51 // AvlNode* node -> +---------------+  V
53 // | AvlNode |
70 // an AvlNode.
93 typedef OSetNode AvlNode;
99 AvlNode* left;
100 AvlNode* right;
121 AvlNode* root; // root node
123 AvlNode* nodeStack[STACK_MAX]; // Iterator node stack
132 // Given a pointer to the node's element, return the pointer to the AvlNode
136 AvlNode* node_of_elem(const void *elem)
138 AvlNode* n = (AvlNode*)((Addr)elem - sizeof(AvlNode));
148 // Given an AvlNode, return the pointer to the element.
150 void* elem_of_node(const AvlNode *n)
157 return (void*)((Addr)n + sizeof(AvlNode));
162 void* elem_of_node_no_check(const AvlNode *n)
164 return (void*)((Addr)n + sizeof(AvlNode));
168 void* slow_key_of_node(const AvlTree* t, const AvlNode* n)
174 void* fast_key_of_node(const AvlNode* n)
180 static inline Word fast_cmp(const void* k, const AvlNode* n)
197 inline Word slow_cmp(const AvlTree* t, const void* k, const AvlNode* n)
204 static void avl_swl ( AvlNode** root )
206 AvlNode* a = *root;
207 AvlNode* b = a->right;
214 static void avl_swr ( AvlNode** root )
216 AvlNode* a = *root;
217 AvlNode* b = a->left;
224 static void avl_nasty ( AvlNode* root )
256 static inline void stackPush(AvlTree* t, AvlNode* n, Int i)
266 static inline Bool stackPop(AvlTree* t, AvlNode** n, Int* i)
294 // Check the padding is right and the AvlNode is the expected size.
295 vg_assert(sizeof(AvlNode) == 3*sizeof(void*));
330 t->node_pa = VG_(newPA)(sizeof(AvlNode)
384 AvlNode* n = NULL;
428 AvlNode* n;
429 Int nodeSize = sizeof(AvlNode) + elemSize;
454 static inline Word cmp_key_root(const AvlTree* t, const AvlNode* n)
463 static Bool avl_insert(AvlTree* t, AvlNode* n)
540 AvlNode* n;
575 static AvlNode* avl_lookup(const AvlTree* t, const void* k)
578 AvlNode* curr = t->root;
609 AvlNode* n;
649 static Bool avl_remove(AvlTree* t, const AvlNode* n)
736 AvlNode* n;
773 AvlNode* n = avl_lookup(t, k);
865 AvlNode *t;
926 static void OSet_Print2( const AvlTree* t, const AvlNode* n,