You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Alexey Varlamov (JIRA)" <ji...@apache.org> on 2008/03/24 13:53:25 UTC

[jira] Commented: (HARMONY-5638) [drlvm][performance] String.intern() should use unsynchronized fast-path

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

Alexey Varlamov commented on HARMONY-5638:
------------------------------------------

Looks like this is exploiting "double checking lock" idiom, which is knonw unsafe for Java [1].
[1] http://www.cs.umd.edu/~pugh/java/memoryModel/DoubleCheckedLocking.html

> [drlvm][performance] String.intern() should use unsynchronized fast-path
> ------------------------------------------------------------------------
>
>                 Key: HARMONY-5638
>                 URL: https://issues.apache.org/jira/browse/HARMONY-5638
>             Project: Harmony
>          Issue Type: Improvement
>            Reporter: Aleksey Shipilev
>         Attachments: 0006-serial-vmInternString.patch
>
>
> Current implementation on String.intern() synchronizes on entire put operation. Given the perspective large fraction of the strings are already interned, we might implement the fast-path lookup as unsynchronized part of put().

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