RFR: 8339341: SurfaceManager cacheMap retains strong references [v4]

Phil Race prr at openjdk.org
Thu Oct 17 18:46:52 UTC 2024


On Tue, 24 Sep 2024 19:38:46 GMT, Phil Race <prr at openjdk.org> wrote:

>> Nikita Gubarkov has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Revert wildcard import in X11GraphicsDevice
>
> src/java.desktop/share/classes/sun/awt/image/SurfaceManager.java line 102:
> 
>> 100:      * and this map is just a weak mapping for the bookkeeping purposes.
>> 101:      */
>> 102:     private final Map<ProxyCache, WeakReference<SurfaceDataProxy>> weakCache = new WeakHashMap<>(2);
> 
> why does this one not need to be a synchronized map ?

Ping ! on this .

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

PR Review Comment: https://git.openjdk.org/jdk/pull/20825#discussion_r1805261713


More information about the client-libs-dev mailing list