]> git.lizzy.rs Git - rust.git/commit
perf: Reduce snapshot/rollback overhead
authorMarkus Westerlind <markus.westerlind@distilnetworks.com>
Mon, 24 Feb 2020 09:40:36 +0000 (10:40 +0100)
committerMarkus Westerlind <markus.westerlind@distilnetworks.com>
Tue, 5 May 2020 08:03:13 +0000 (10:03 +0200)
commit1506b1fc6a42dda3e56789f43587448cc5bf4a36
treeb469970b042b8c02f779c0010790bdde9db253e5
parent61621e2667869a9c6cc153d10f84b8850fd64494
perf: Reduce snapshot/rollback overhead

By merging the undo_log of all structures part of the snapshot the cost
of creating a snapshot becomes much cheaper. Since snapshots with no or
few changes are so frequent this ends up mattering more than the slight
overhead of dispatching on the variants that map to each field.
15 files changed:
Cargo.lock
Cargo.toml
src/librustc_data_structures/lib.rs
src/librustc_infer/infer/combine.rs
src/librustc_infer/infer/equate.rs
src/librustc_infer/infer/error_reporting/need_type_info.rs
src/librustc_infer/infer/freshen.rs
src/librustc_infer/infer/fudge.rs
src/librustc_infer/infer/lattice.rs
src/librustc_infer/infer/mod.rs
src/librustc_infer/infer/nll_relate/mod.rs
src/librustc_infer/infer/resolve.rs
src/librustc_infer/infer/sub.rs
src/librustc_infer/infer/type_variable.rs
src/librustc_middle/infer/unify_key.rs