From: Manfred Spraul <manfreds@colorfullife.com>
To: Andrea Arcangeli <andrea@suse.de>
Cc: Oliver Xymoron <oxymoron@waste.org>,
Kevin O'Connor <koconnor@cse.Buffalo.EDU>,
linux-mm@kvack.org, linux-kernel@vger.rutgers.edu,
Marc Lehmann <pcg@opengroup.org>,
Linus Torvalds <torvalds@transmeta.com>
Subject: Re: [patch] rbtrees [was Re: AVL trees vs. Red-Black trees]
Date: Mon, 29 Nov 1999 20:18:17 +0100 [thread overview]
Message-ID: <3842D179.7FBD6A69@colorfullife.com> (raw)
In-Reply-To: <Pine.LNX.4.10.9911291649470.5133-100000@alpha.random>
Andrea Arcangeli wrote:
> + To use rbtrees you'll have to implement your own insert and search cores.
> + This will avoid us to use callbacks and to drop drammatically performances.
> + I know it's not the cleaner way, but in C (not in C++) to get
> + performances and genericity...
> +
> + Some example of insert and search follows here. The search is a plain
> + normal search over an ordered tree. The insert instead must be implemented
> + int two steps: as first thing the code must insert the element in
> + order as a red leaf in the tree, then the support library function
> + rb_insert_color() must be called. Such function will do the
> + not trivial work to rebalance the rbtree if necessary.
What about something similar to the "end_request()" implementation?
ie you #define a name and the (inline) compare function, then you
#include <rbtree.h>. <rbtree.h> creates all functions that you need.
--
Manfred
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://humbolt.geo.uu.nl/Linux-MM/
next prev parent reply other threads:[~1999-11-29 19:18 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
1999-11-27 12:59 AVL trees vs. Red-Black trees Kevin O'Connor
1999-11-28 2:57 ` Andrea Arcangeli
1999-11-28 5:29 ` Oliver Xymoron
1999-11-29 15:54 ` [patch] rbtrees [was Re: AVL trees vs. Red-Black trees] Andrea Arcangeli
1999-11-29 19:18 ` Manfred Spraul [this message]
1999-11-29 19:17 ` Andrea Arcangeli
1999-11-30 5:27 ` Kevin O'Connor
1999-11-30 14:14 ` Andrea Arcangeli
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3842D179.7FBD6A69@colorfullife.com \
--to=manfreds@colorfullife.com \
--cc=andrea@suse.de \
--cc=koconnor@cse.Buffalo.EDU \
--cc=linux-kernel@vger.rutgers.edu \
--cc=linux-mm@kvack.org \
--cc=oxymoron@waste.org \
--cc=pcg@opengroup.org \
--cc=torvalds@transmeta.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox