JDK-6616323 : consider benefits of replacing a componen array with other collection from the awt.Container class
The Version table provides details related to the release that this issue/RFE will be addressed.
Unresolved : Release in which this issue/RFE will be addressed. Resolved: Release in which this issue/RFE has been resolved. Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.
java.awt.Container class stores all children in an array of Components:
1) its initial size is 0;
2) on changing the hierarchy of components (add/remove) it addresses the Arrays.copy(args) method;
There is no visible improvements with startup2 and startup3 but it does observed with swingmark if Container use ArrayList instead of plaing array.
esults\swingmark Benchmark Samples Mean Stdev Ge
swingmark 30 907.52 3.77
esults\swingmark Benchmark Samples Mean Stdev %Diff P
swingmark 30 881.36 4.33 -2.88 0.000 Yes
* - Not Significant: The %Diff for the mean could be noise. If there is
an actual difference, more samples would be needed to detect it.