]> git.lizzy.rs Git - rust.git/commit
Implement LazyBTreeMap and use it in a few places.
authorNicholas Nethercote <nnethercote@mozilla.com>
Tue, 24 Apr 2018 03:22:41 +0000 (13:22 +1000)
committerNicholas Nethercote <nnethercote@mozilla.com>
Thu, 26 Apr 2018 01:55:06 +0000 (11:55 +1000)
commit259ae181391933040389e7e4206e792ad66b1487
treefb844c9df2e467c6ce042e0ac8385a2b017eb95a
parentcc794209681d6b11a63282bcd1513caa50127816
Implement LazyBTreeMap and use it in a few places.

This is a thin wrapper around BTreeMap that avoids allocating upon
creation. It speeds up some rustc-perf benchmarks by up to 3.6%.
src/librustc/infer/higher_ranked/mod.rs
src/librustc/infer/mod.rs
src/librustc/ty/fold.rs
src/librustc_data_structures/lazy_btree_map.rs [new file with mode: 0644]
src/librustc_data_structures/lib.rs