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

FlyingLetters sample 'leaks' memory

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Not an Issue
    • Icon: P4 P4
    • fx1.3
    • fx1.3
    • javafx
    • windows xp desktop

      I say 'leaks' because the leak isn't permanent. Amount of heap used will increase up the max allowed, but when it gets there, gc's will free up enough memory to allow the sample to continue running.

      To reproduce, do this:
      - start FlyingLetters
      - start jconsole and connect to FlyingLetters
      - click on the memory tab in jconsole
      - observe the used and committed values
      - click on a flying letter. Note the used value goes up
      - click again, etc. Note that the used value goes up with each run
      - now click the Perform GC button. The used value goes down
      - click the Perform GC button a 2nd time. The used value goes down more
      - sometimes, the used value will go down even more with a 3rd click
      I commented out the body of the onlayout function and the bug still occurred.

      VisualVM can be used to see which classes are involved in this. It appears to me that java.awt.geom.AffineTransform has the most instances.

      I'm not sure that this is actually a bug in the JavaFX runtime - it could be a bug in the sample code itself.


            kcr Kevin Rushforth
            jholmlundjfx Jim Holmlund (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported: