|
#define | LDA(a) *(a) |
|
#define | STA(a, v) *(a) = (v) |
|
#define | LDV(a) (a) |
|
#define | STV(a, v) (a) = (v) |
|
#define | LDF(o, f) ((o)->f) |
|
#define | STF(o, f, v) ((o)->f) = (v) |
|
#define | LDNODE(o, f) ((node_t*)(LDF((o),f))) |
|
#define | TX_LDA(a) TM_SHARED_READ_L(*(a)) |
|
#define | TX_STA(a, v) TM_SHARED_WRITE_L(*(a), v) |
|
#define | TX_LDV(a) TM_SHARED_READ_L(a) |
|
#define | TX_STV(a, v) TM_SHARED_WRITE_P(a, v) |
|
#define | TX_LDF(o, f) ((long)TM_SHARED_READ_L((o)->f)) |
|
#define | TX_LDF_P(o, f) ((void*)TM_SHARED_READ_P((o)->f)) |
|
#define | TX_STF(o, f, v) TM_SHARED_WRITE_L((o)->f, v) |
|
#define | TX_STF_P(o, f, v) TM_SHARED_WRITE_P((o)->f, v) |
|
#define | TX_LDNODE(o, f) ((node_t*)(TX_LDF_P((o),f))) |
|
#define | LOOKUP(set, key) lookup(set, key) |
|
#define | TX_LOOKUP(set, key) TMlookup(TM_ARG set, key) |
|
#define | ROTATE_LEFT(set, node) rotateLeft(set, node) |
|
#define | TX_ROTATE_LEFT(set, node) TMrotateLeft(TM_ARG set, node) |
|
#define | ROTATE_RIGHT(set, node) rotateRight(set, node) |
|
#define | TX_ROTATE_RIGHT(set, node) TMrotateRight(TM_ARG set, node) |
|
#define | PARENT_OF(n) parentOf(n) |
|
#define | TX_PARENT_OF(n) TMparentOf(TM_ARG n) |
|
#define | LEFT_OF(n) leftOf(n) |
|
#define | TX_LEFT_OF(n) TMleftOf(TM_ARG n) |
|
#define | RIGHT_OF(n) rightOf(n) |
|
#define | TX_RIGHT_OF(n) TMrightOf(TM_ARG n) |
|
#define | COLOR_OF(n) colorOf(n) |
|
#define | TX_COLOR_OF(n) TMcolorOf(TM_ARG n) |
|
#define | SET_COLOR(n, c) setColor(n, c) |
|
#define | TX_SET_COLOR(n, c) TMsetColor(TM_ARG n, c) |
|
#define | FIX_AFTER_INSERTION(s, x) fixAfterInsertion(s, x) |
|
#define | TX_FIX_AFTER_INSERTION(s, x) TMfixAfterInsertion(TM_ARG s, x) |
|
#define | INSERT(s, k, v, n) insert(s, k, v, n) |
|
#define | TX_INSERT(s, k, v, n) TMinsert(TM_ARG s, k, v, n) |
|
#define | SUCCESSOR(n) successor(n) |
|
#define | TX_SUCCESSOR(n) TMsuccessor(TM_ARG n) |
|
#define | FIX_AFTER_DELETION(s, n) fixAfterDeletion(s, n) |
|
#define | TX_FIX_AFTER_DELETION(s, n) TMfixAfterDeletion(TM_ARG s, n ) |
|
#define | DELETE(s, n) delete_node(s, n) |
|
#define | TX_DELETE(s, n) TMdelete(TM_ARG s, n) |
|
|
static TM_CALLABLE node_t * | TMlookup (TM_ARGDECL rbtree_t *s, void *k) |
|
static TM_CALLABLE void | TMrotateLeft (TM_ARGDECL rbtree_t *s, node_t *x) |
|
static TM_CALLABLE void | TMrotateRight (TM_ARGDECL rbtree_t *s, node_t *x) |
|
static TM_CALLABLE node_t * | TMparentOf (TM_ARGDECL node_t *n) |
|
static TM_CALLABLE node_t * | TMleftOf (TM_ARGDECL node_t *n) |
|
static TM_CALLABLE node_t * | TMrightOf (TM_ARGDECL node_t *n) |
|
static TM_CALLABLE long | TMcolorOf (TM_ARGDECL node_t *n) |
|
static TM_CALLABLE void | TMsetColor (TM_ARGDECL node_t *n, long c) |
|
static TM_CALLABLE void | TMfixAfterInsertion (TM_ARGDECL rbtree_t *s, node_t *x) |
|
static TM_CALLABLE node_t * | TMsuccessor (TM_ARGDECL node_t *t) |
|
static TM_CALLABLE void | TMfixAfterDeletion (TM_ARGDECL rbtree_t *s, node_t *x) |
|
static TM_CALLABLE node_t * | TMinsert (TM_ARGDECL rbtree_t *s, void *k, void *v, node_t *n) |
|
static TM_CALLABLE node_t * | TMgetNode (TM_ARGDECL_ALONE) |
|
static TM_CALLABLE node_t * | TMdelete (TM_ARGDECL rbtree_t *s, node_t *p) |
|
static node_t * | lookup (rbtree_t *s, void *k) |
|
static void | rotateLeft (rbtree_t *s, node_t *x) |
|
static void | rotateRight (rbtree_t *s, node_t *x) |
|
static node_t * | parentOf (node_t *n) |
|
static node_t * | leftOf (node_t *n) |
|
static node_t * | rightOf (node_t *n) |
|
static long | colorOf (node_t *n) |
|
static void | setColor (node_t *n, long c) |
|
static void | fixAfterInsertion (rbtree_t *s, node_t *x) |
|
static node_t * | insert (rbtree_t *s, void *k, void *v, node_t *n) |
|
static node_t * | successor (node_t *t) |
|
static void | fixAfterDeletion (rbtree_t *s, node_t *x) |
|
static node_t * | delete_node (rbtree_t *s, node_t *p) |
|
static node_t * | firstEntry (rbtree_t *s) |
|
static long | verifyRedBlack (node_t *root, long depth) |
|
long | rbtree_verify (rbtree_t *s, long verbose) |
|
static long | compareKeysDefault (const void *a, const void *b) |
|
static TM_CALLABLE long | TMcompareKeysDefault (TM_ARGDECL const void *a, const void *b) |
|
rbtree_t * | rbtree_alloc (comparator_t *compare) |
|
rbtree_t * | TMrbtree_alloc (TM_ARGDECL comparator_t *compare) |
|
static void | releaseNode (node_t *n) |
|
static TM_CALLABLE void | TMreleaseNode (TM_ARGDECL node_t *n) |
|
static void | freeNode (node_t *n) |
|
static void | TMfreeNode (TM_ARGDECL node_t *n) |
|
void | rbtree_free (rbtree_t *r) |
|
void | TMrbtree_free (TM_ARGDECL rbtree_t *r) |
|
static node_t * | getNode () |
|
bool_t | rbtree_insert (rbtree_t *r, void *key, void *val) |
|
bool_t | TMrbtree_insert (TM_ARGDECL rbtree_t *r, void *key, void *val) |
|
bool_t | rbtree_delete (rbtree_t *r, void *key) |
|
bool_t | TMrbtree_delete (TM_ARGDECL rbtree_t *r, void *key) |
|
bool_t | rbtree_update (rbtree_t *r, void *key, void *val) |
|
bool_t | TMrbtree_update (TM_ARGDECL rbtree_t *r, void *key, void *val) |
|
void * | rbtree_get (rbtree_t *r, void *key) |
|
void * | TMrbtree_get (TM_ARGDECL rbtree_t *r, void *key) |
|
long | rbtree_contains (rbtree_t *r, void *key) |
|
long | TMrbtree_contains (TM_ARGDECL rbtree_t *r, void *key) |
|