On Thu, 22 Jan 2026 17:04:26 GMT, Christopher Schnick <[email protected]> wrote:
>> This should improve the code quality of the class while preserving its
>> original workings
>
> Christopher Schnick has updated the pull request incrementally with one
> additional commit since the last revision:
>
> Remove unused imports
modules/javafx.graphics/src/main/java/com/sun/javafx/sg/prism/NGGroup.java line
218:
> 216: for (int i = (startPos == -1 ? 0 : startPos); i <
> orderedChildren.size(); i++) {
> 217: NGNode child = orderedChildren.get(i);
> 218: child.render(g);
more on the concurrency here: if one would instrument the get(int) method in
`children` like so
private final List<NGNode> children = new ArrayList<>(1) {
public NGNode get(int ix) {
System.out.println(Thread.currentThread());
return super.get(ix);
}
};
the log will show accesses from two threads:
Thread[#33,JavaFX Application Thread,5,main]
...
Thread[#28,QuantumRenderer-0,5,main]
...
Thread[#33,JavaFX Application Thread,5,main]
The access pattern for `viewOrderChildren` seem to show only QuantumRenderer
thread, though I did not test extensively.
Does anyone know if these two threads are allowed to run in parallel, or is
there a mechanism in place that ensures mutual exclusion?
-------------
PR Review Comment: https://git.openjdk.org/jfx/pull/2043#discussion_r2728325064