This page is not created by, affiliated with, or supported by Slack Technologies, Inc.


@mfikes I think I’ve applied all the MapEntry related stuff


@dnolen Thanks! This one was recently discovered, and could be a regression for code like (rseq (first {:a 1}))


k, looking at that one


It is great that the map entry changes end up being more than just for "correctness". Here is the perf snippet from the news article: Finally, using a dedicated map entry type can lead to performance improvements in some code that works with map entries. For example, in :advanced mode, this code [source,clojure]

(simple-benchmark [m (zipmap (range 100) (range))]
  (reduce (fn [a [k v]] (if (even? v) (+ a k) a)) 0 m) 100000)
runs 11% faster in JavaScriptCore, 18% faster in V8, and a whopping 105% faster in SpiderMonkey. And if you use the dedicated key and val functions instead of destructuring, the V8 performance goes to 44% faster and SpiderMonkey 112%.


yeah I suspect as much :slightly_smiling_face:


I suppose it is a matter of a dedicated 2-element type being very fast over a generic PersistentVector type that has to delegate to internal arrays and such.