]> code.delx.au - gnu-emacs/commit
Consistently use the mark bit of the root interval's parent field
authorJim Blandy <jimb@redhat.com>
Sun, 18 Jul 1993 06:26:10 +0000 (06:26 +0000)
committerJim Blandy <jimb@redhat.com>
Sun, 18 Jul 1993 06:26:10 +0000 (06:26 +0000)
commite87206440141f2cad44d913dd558edc7f60a17cb
treee91a70156e9f3e46a220747321d78beff160ab10
parent718ca51e403c565c8cb35fbf7f4eb6bb00fee0b8
Consistently use the mark bit of the root interval's parent field
to say whether or not the interval tree has been visited (and skip
it when revisited), and the mark bit of the plist field to say
whether or not that interval has been visited (and abort if
revisited); don't try to use the plist mark bit for both
meanings.
* alloc.c (mark_interval_tree): Don't test if the interval tree
has already been visited here; let the MARK_INTERVAL_TREE macro do
that; avoid function call overhead.  Mark the interval tree as
having been visited by setting TREE->parent's mark bit.
(MARK_INTERVAL_TREE): If the tree has been visited (according to
I->parent's mark bit), don't call mark_interval_tree.
(gc_sweep): Rebalance the interval trees of those large strings
which are still alive.  This also clears the mark bits of those
trees' root intervals' parent fields.
(compact_strings): Rebalance the interval tree of each small
strings which is still alive.  This also clears the mark bits of
that tree's root interval's parent field.  Since the string has
moved, update the root interval's parent pointer to contain the
new address.
* lisp.h (struct interval): Doc fix; explain the roles of the mark
bits of the parent and plist members.
src/alloc.c
src/lisp.h