RFR: 8309463: IGV: Dynamic graph layout algorithm [v7]
emmyyin
duke at openjdk.org
Fri Aug 25 08:49:16 UTC 2023
On Thu, 24 Aug 2023 10:49:16 GMT, Christian Hagedorn <chagedorn at openjdk.org> wrote:
>> Yes since `relativeTo` and `relativeFrom` refers to the ports on the node, which is irrelevant for the dummy nodes. Could definitely be done differently, but this is how it is in `HierarchicalLayoutManager` and I thought it would be better to be consistent across the layout managers
>
> Okay, thanks for the explanation. The code in `HierarchicalLayoutManager` looks very similar. So, you could also change `relativeTo` and `relativeFrom` to zero there. Or even better share the code somehow (if I see that correctly, the only difference is how to insert the node - `nodes.add(n)` vs. `insertNode(n, layer)`).
@robcasloz has created a suggestion list of how to improve `HierarchicalLayoutManager`. Could we perhaps add this to that list instead? I think there must have been some reason to set `n.width/2` (maybe just in case you want to make the dummy nodes visible with a larger width) so it could be worth to work it through some more
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/14349#discussion_r1305379806
More information about the hotspot-compiler-dev
mailing list