You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@groovy.apache.org by "Daniel Sun (JIRA)" <ji...@apache.org> on 2019/03/30 17:15:00 UTC

[jira] [Created] (GROOVY-9060) Make the initial capacity of LinkedHashMap be power of 2 for better performance

Daniel Sun created GROOVY-9060:
----------------------------------

             Summary: Make the initial capacity of LinkedHashMap be power of 2 for better performance
                 Key: GROOVY-9060
                 URL: https://issues.apache.org/jira/browse/GROOVY-9060
             Project: Groovy
          Issue Type: Improvement
            Reporter: Daniel Sun
            Assignee: Daniel Sun
             Fix For: 3.0.0-beta-1


{\{LinkedHashMap}} is a subclass of \{{HashMap}}, so its initial capacity should be power of 2 too.

SEE: [https://stackoverflow.com/questions/8352378/why-does-hashmap-require-that-the-initial-capacity-be-a-power-of-two]

 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)