On Fri, 5 Feb 2021 14:46:49 GMT, Ambarish Rapte <ara...@openjdk.org> wrote:
>> John Hendrikx has updated the pull request incrementally with four >> additional commits since the last revision: >> >> - Add missing TreeShowingExpressionTest which also tests SubScene >> - Also dispose listeners on Window/Showing in dispose >> - Fix review comments >> - Update copyrights > > Added couple minor comments and a suggestion. > Rest looks good to me, Observed no failures. It would be a great performance > improvement for large scene applications. > This PR also seems to fix another issue > [JDK-8259558](https://bugs.openjdk.java.net/browse/JDK-8259558). Test program > is attached to the bug. > > Time readings, > with this fix, > time to remove 100000 nodes : ~20 ms > time to add those removed 100000 nodes to a different parent: ~80 ms > > without this fix, > time to remove 100000 nodes : ~1720 ms > time to add those removed 100000 nodes to a different parent: ~100 ms This is possible, as for each Node removed two listeners are also removed from the huge listener lists in Scene and Window (O(n) performance). Adding is not affected much as adding a listener to a huge list is not that costly. ------------- PR: https://git.openjdk.java.net/jfx/pull/185