Liking cljdoc? Tell your friends :D

dissoc-in* performance

dissoc-in* version 5 handles nested hashmaps and some nested vectors notably faster than version_4, while maintaining the performance of sequences and lists.

See the overall summary for benchmarking details. The benchmarks displayed in this document are defined here.

Hashmaps

Version 5 handles hashmaps twice as fast a version 4.

(fn [n] (dissoc-in* (nested-map n) (path-map n)))

Benchmark measurements for expression `(fn [n] (dissoc-in* (nested-map n) (path-map n)))`, time versus 'n' arguments, comparing different versions. Show details

Lists

Version 5 handles lists somewhat faster than version 4.

(fn [n] (dissoc-in* (nested-list n) (path-list n)))

Benchmark measurements for expression `(fn [n] (dissoc-in* (nested-list n) (path-list n)))`, time versus 'n' arguments, comparing different versions. Show details

Sequences

Version 5 performs about the same as version 4 when handling sequences.

(fn [n] (dissoc-in* (nested-seq n) (path-seq n)))

Benchmark measurements for expression `(fn [n] (dissoc-in* (nested-seq n) (path-seq n)))`, time versus 'n' arguments, comparing different versions. Show details

Vectors

Version 5 handles some nested vectors with 24 to 40% speedup compared to version 4, while other patterns of nested vectors are handled similarly.

(fn [n] (dissoc-in* (narrow-deep-vec n) (path-narrow-deep-vec n)))

Benchmark measurements for expression `(fn [n] (dissoc-in* (narrow-deep-vec n) (path-narrow-deep-vec n)))`, time versus 'n' arguments, comparing different versions. Show details

(fn [n] (dissoc-in* (nested-vec n) (path-nested-vec n)))

Benchmark measurements for expression `(fn [n] (dissoc-in* (nested-vec n) (path-nested-vec n)))`, time versus 'n' arguments, comparing different versions. Show details

Can you improve this documentation?Edit on GitHub

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
Move to previous article
Move to next article
Ctrl+/Jump to the search field
× close