> The pulse loggers assumed that a pulse rendering finishes before the next 
> pulse rendering starts. That isn't true anymore when multithreaded is enabled 
> (the default now), and causes a NullPointerException in the print logger and 
> breaks the application completely.
> 
> Problems
> - Both loggers kept a single pulse currently rendering field. When the next 
> pulse started rendering early, it overwrote that field
> - The end notification relied on counting completed scenes. When a scene was 
> skipped, the notification never came
> - The print logger measured each pulse duration up to when it was printed. A 
> pulse that had to wait behind a previous pulse render showed a wrong time
> 
> Changes
> - PaintCollector: sends the end notification as an extra render job after 
> each render pass. Render jobs run in order on one thread, so every render 
> start now has exactly one matching end
> - PrintLogger: tracks pulses being rendered in a queue instead of one field. 
> And each pulse duration is measured up to when it completed.
> - JFRPulseLogger: uses the same queue now, so events get the correct pulse ID 
> instead of the next pulse ID orĀ 0.
> 
> A note about reviewing: Even though those are some larger changes, there 
> isn't a need to be very rigorous when reviewing.
> Any code that is changed is not running in normal apps, only when the pulse 
> logger is enabled. And since that feature is broken right now (and has been 
> for many years), it can only get better.
> 
> ---------
> - [x] I confirm that I make this contribution in accordance with the [OpenJDK 
> Interim AI Policy](https://openjdk.org/legal/ai).

Christopher Schnick has updated the pull request incrementally with one 
additional commit since the last revision:

  Trigger Build

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

Changes:
  - all: https://git.openjdk.org/jfx/pull/2368/files
  - new: https://git.openjdk.org/jfx/pull/2368/files/4ce54520..122b8bb6

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jfx&pr=2368&range=01
 - incr: https://webrevs.openjdk.org/?repo=jfx&pr=2368&range=00-01

  Stats: 0 lines in 0 files changed: 0 ins; 0 del; 0 mod
  Patch: https://git.openjdk.org/jfx/pull/2368.diff
  Fetch: git fetch https://git.openjdk.org/jfx.git pull/2368/head:pull/2368

PR: https://git.openjdk.org/jfx/pull/2368

Reply via email to