Skip to content

Instantly share code, notes, and snippets.


Reynold Xin rxin

View GitHub Profile
View microbenchmark.markdown

I was curious about the results reported here, which reports that Scala's mutable maps are slower than Java's:

In my tests, Scala's OpenHashMap equals or beats java's HashMap:

Insertion 100k elements (String keys) time in ms:

  • scala HashMap: 92.75
  • scala OpenHashMap: 14.03125
  • java HashMap: 15.78125