harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nathan Beyer (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HARMONY-5636) [classlib][luni][performance] java.lang.reflect.Proxy cache should be unsynchronized
Date Sun, 23 Mar 2008 21:17:24 GMT

    [ https://issues.apache.org/jira/browse/HARMONY-5636?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12581428#action_12581428
] 

Nathan Beyer commented on HARMONY-5636:
---------------------------------------

This patch isn't safe. If applied, it would expose the possibility of the 'containsKey' being
invoked while a 'put' is being invoked and there's no guarantee that the internal state of
the Map would be safe for execution (spurious NPEs, etc).

The patch also removes the WeakHashMap, but that's not mentioned at all.

Additionally, the synchronized blocks in this bit of code are already very small, so I'm skeptical
of real value of such a change. 

> [classlib][luni][performance] java.lang.reflect.Proxy cache should be unsynchronized
> ------------------------------------------------------------------------------------
>
>                 Key: HARMONY-5636
>                 URL: https://issues.apache.org/jira/browse/HARMONY-5636
>             Project: Harmony
>          Issue Type: Improvement
>            Reporter: Aleksey Shipilev
>            Priority: Minor
>         Attachments: 0004-serial-isProxyClass.patch
>
>
> For now, the proxyCache in Proxy is synchronized, which lead to performance problems
with accessing Proxy.isProxyClass() from multiple threads at once.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message