RFR: 8349211: Add support for intrusive trees to the utilities red-black tree

Casper Norrbin cnorrbin at openjdk.org
Wed Feb 5 14:35:12 UTC 2025


On Tue, 4 Feb 2025 07:24:06 GMT, Thomas Stuefe <stuefe at openjdk.org> wrote:

> Why not skip the useless insert_node creation? Let insert_at_cursor just accept uninitialized Node* memory, since it will initialize all Node members anyway?
> 

As of now, the cursor doesn't track to what key its pointing to.  All `Node` members _but_ the key are initialized, so the key still needs to be specified. Thats what the `0` in `Node(0)` is. I could change this to have that also stored inside the cursor, so we can avoid creating the node first.

> could you massage this patch a bit to reduce the delta to the last version? That is a good idea in general (I usually do a manual minimize-delta sweep before I undraft a PR for review). A lot seems to be code movement at first glance.
> 

A lot is new or rewritten so git diff had a hard time picking up related changes. I tried my best to order and group the changes so functionality overlaps.

-------------

PR Comment: https://git.openjdk.org/jdk/pull/23416#issuecomment-2637014828


More information about the hotspot-dev mailing list