summaryrefslogtreecommitdiffstats
path: root/cpukit/score/src/rbtreeextract.c (unfollow)
Commit message (Collapse)AuthorFilesLines
2017-10-21score: Fix warningSebastian Huber1-1/+1
2017-09-27score: Simplify red-black tree debug supportSebastian Huber1-1/+17
Make the RBTree_Node layout independent of RTEMS_DEBUG (and all other build configuration options). This allows the use of this structure in Newlib. Update #3112.
2016-09-06score: Improve red-black tree debug supportSebastian Huber1-3/+2
Ensure that we extract a node only from the right tree.
2016-08-08score: Add debug support to red-black treesSebastian Huber1-0/+3
This helps to detect double insert and extract errors.
2015-09-03rbtree: Replace implementationSebastian Huber1-187/+3
Use the BSD <sys/tree.h> implementation since it is faster, more flexible and uses less storage. See https://github.com/sebhub/rb-bench.
2014-08-07rbtree: Simplify _RBTree_Extract()Sebastian Huber1-8/+10
2014-08-07rbtree: Simplify insert and extractSebastian Huber1-4/+3
Simplify _RBTree_Insert() and _RBTree_Extract(). Remove more superfluous NULL pointer checks. Change _RBTree_Is_root() to use only the node. Add parent parameter to _RBTree_Sibling(). Delete _RBTree_Grandparent() and _RBTree_Parent_sibling().
2014-07-22rbtree: Do not set node off-tree in extractSebastian Huber1-3/+0
2014-07-22rbtree: Remove superfluous NULL pointer checksSebastian Huber1-11/+0
2014-07-22rbtree: FormatSebastian Huber1-68/+86
2014-03-21Change all references of rtems.com to rtems.org.Chris Johns1-1/+1
2013-11-21score/rbtree: Remove "unprotected" from APISebastian Huber1-6/+6
2013-11-21score/rbtree: Delete protected operationsSebastian Huber1-27/+0
The user of the red-black tree container must now ensure that at most one thread at once can access an instance.
2013-07-23score: Create rbtree implementation headerSebastian Huber1-3/+1
Move implementation specific parts of rbtree.h and rbtree.inl into new header file rbtreeimpl.h. The rbtree.h contains now only the application visible API.
2012-05-11Remove All CVS Id Strings Possible Using a ScriptJoel Sherrill1-2/+0
Script does what is expected and tries to do it as smartly as possible. + remove occurrences of two blank comment lines next to each other after Id string line removed. + remove entire comment blocks which only exited to contain CVS Ids + If the processing left a blank line at the top of a file, it was removed.
2012-05-08rbtree: API changes. Remove rbtree control node from RBTree_Next.Gedare Bloom1-2/+2
The implementation of RBTree_Next was using an awkward construction to detect and avoid accessing the false root of the red-black tree. To deal with the false root, RBTree_Next was comparing node parents with the control node. Instead the false root can be detected by checking if the grandparent of a node exists; the grandparent of the tree's true root is NULL by definition so the root of the tree is found while walking up the tree by checking for the non-existence of a grandparent. This change propagates into the predecessor/successor and iterate functions.
2012-05-08PR2060: RBTree: updating min and max on extract pathGedare Bloom1-17/+9
During node extraction from a red-black tree the min and max values are updated incorrectly. We need to use the successor/predecessor functions to find the next/previous node when we remove the min/max from the tree.
2012-03-04score: Add _RBTree_Opposite_direction.Gedare Bloom1-5/+5
Add a red-black tree helper method to ease obtaining the direction opposite to the current direction. Useful for manipulating and traversing an rbtree.
2011-12-022011-12-02 Ralf Corsépius <ralf.corsepius@rtems.org>Ralf Corsepius1-1/+1
* score/src/rbtreeextract.c: Make _RBTree_Extract_validate_unprotected static. * score/src/rbtreeinsert.c: Make _RBTree_Validate_insert_unprotected static.
2011-08-022011-08-02 Petr Benes <benesp16@fel.cvut.cz>Joel Sherrill1-12/+8
PR 1861/cpukit * score/src/rbtreeextract.c: Remove redundant code.
2011-07-272011-07-27 Petr Benes <benesp16@fel.cvut.cz>Joel Sherrill1-2/+4
PR 1856/cpukit * posix/src/pthread.c, posix/src/pthreadjoin.c, score/src/rbtreeextract.c: Do not derefence NULL.
2011-05-24Remove white-spaces.Ralf Corsepius1-23/+23
2011-04-042010-07-28 Gedare Bloom <giddyup44@yahoo.com>Joel Sherrill1-0/+245
PR 1641/cpukit * sapi/Makefile.am, sapi/preinstall.am, score/Makefile.am, score/preinstall.am: Add Red Black Tree data structure to score. * sapi/include/rtems/rbtree.h, sapi/inline/rtems/rbtree.inl, score/include/rtems/score/rbtree.h, score/inline/rtems/score/rbtree.inl, score/src/rbtree.c, score/src/rbtreeextract.c, score/src/rbtreefind.c, score/src/rbtreefindheader.c, score/src/rbtreeget.c, score/src/rbtreeinsert.c, score/src/rbtreepeek.c: New files.