Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8102469

Changing a single child of FlowLayout is slower than changing all children

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Cannot Reproduce
    • Icon: P4 P4
    • 8
    • 8
    • javafx

      While looking into possible optimizations for FlowLayout, I discovered some weird behavior. I added a new mode to the performance test LayoutTest, which changes only the size of a single child. Surprisingly this case is significantly slower than changing the size of all children.

      In the layout-code there is no optimization in place yet, which would take advantage of the fact that almost all children stay the same. I.e. changing a single child should be as fast as changing all children (at least).

      I profiled the application and it looks like most of the time in the JavaFX application thread is spent waiting for the rendering thread. The rendering thread spends most of its time in GLContext.nDrawIndexedQuads(). But somebody else should double check this, because I find the profiler results sometimes flawed when native method calls are involved.

            jandrese Joe Andresen (Inactive)
            mheinrichs Michael Heinrichs (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported: