Mercurial > hg
comparison rust/Cargo.lock @ 52060:8b7123c8947b
update: add a Rust fast-path when updating from null (and clean)
This case is easy to detect and we have all we need to generate a valid
working copy and dirstate entirely in Rust, which speeds things up
considerably:
On my machine updating a repo of ~300k files goes from 10.00s down to 4.2s,
all while consuming 50% less system time, with all caches hot.
Something to note is that further improvements will probably happen
with the upcoming `InnerRevlog` series that does smarter
mmap hanlding, especially for filelogs.
Here are benchmark numbers on a machine with only 4 cores (and no SMT enabled)
```
### data-env-vars.name = heptapod-public-2024-03-25-ds2-pnm
# benchmark.name = hg.command.update
# bin-env-vars.hg.py-re2-module = default
# bin-env-vars.hg.changeset.node = <this change>
# benchmark.variants.atomic-update = no
# benchmark.variants.scenario = null-to-tip
# benchmark.variants.worker = default
default: 5.328762 ~~~~~
rust: 1.308654 (-75.44%, -4.02)
### data-env-vars.name = mercurial-devel-2024-03-22-ds2-pnm
# benchmark.name = hg.command.update
# bin-env-vars.hg.py-re2-module = default
# bin-env-vars.hg.changeset.node = <this change>
# benchmark.variants.atomic-update = no
# benchmark.variants.scenario = null-to-tip
# benchmark.variants.worker = default
default: 1.693271 ~~~~~
rust: 1.151053 (-32.02%, -0.54)
### data-env-vars.name = mozilla-unified-2024-03-22-ds2-pnm
# benchmark.name = hg.command.update
# bin-env-vars.hg.py-re2-module = default
# bin-env-vars.hg.changeset.node = <this change>
# benchmark.variants.atomic-update = no
# benchmark.variants.scenario = null-to-tip
# benchmark.variants.worker = default
default: 38.901613 ~~~~~
rust: 11.637880 (-70.08%, -27.26)
### data-env-vars.name = netbsd-xsrc-public-2024-09-19-ds2-pnm
# benchmark.name = hg.command.update
# bin-env-vars.hg.py-re2-module = default
# bin-env-vars.hg.changeset.node = <this change>
# benchmark.variants.atomic-update = no
# benchmark.variants.scenario = null-to-tip
# benchmark.variants.worker = default
default: 4.793727 ~~~~~
rust: 1.505905 (-68.59%, -3.29)
```
author | Raphaël Gomès <rgomes@octobus.net> |
---|---|
date | Tue, 01 Oct 2024 13:49:11 +0200 |
parents | 92e23ba257d1 |
children |
comparison
equal
deleted
inserted
replaced
52059:b332ae615714 | 52060:8b7123c8947b |
---|---|
648 "sha-1 0.10.0", | 648 "sha-1 0.10.0", |
649 "tempfile", | 649 "tempfile", |
650 "thread_local", | 650 "thread_local", |
651 "toml", | 651 "toml", |
652 "twox-hash", | 652 "twox-hash", |
653 "uuid", | |
653 "zstd", | 654 "zstd", |
654 ] | 655 ] |
655 | 656 |
656 [[package]] | 657 [[package]] |
657 name = "hg-cpython" | 658 name = "hg-cpython" |
1528 version = "0.1.10" | 1529 version = "0.1.10" |
1529 source = "registry+https://github.com/rust-lang/crates.io-index" | 1530 source = "registry+https://github.com/rust-lang/crates.io-index" |
1530 checksum = "c0edd1e5b14653f783770bce4a4dabb4a5108a5370a5f5d8cfe8710c361f6c8b" | 1531 checksum = "c0edd1e5b14653f783770bce4a4dabb4a5108a5370a5f5d8cfe8710c361f6c8b" |
1531 | 1532 |
1532 [[package]] | 1533 [[package]] |
1534 name = "uuid" | |
1535 version = "1.11.0" | |
1536 source = "registry+https://github.com/rust-lang/crates.io-index" | |
1537 checksum = "f8c5f0a0af699448548ad1a2fbf920fb4bee257eae39953ba95cb84891a0446a" | |
1538 dependencies = [ | |
1539 "getrandom 0.2.8", | |
1540 ] | |
1541 | |
1542 [[package]] | |
1533 name = "vcpkg" | 1543 name = "vcpkg" |
1534 version = "0.2.15" | 1544 version = "0.2.15" |
1535 source = "registry+https://github.com/rust-lang/crates.io-index" | 1545 source = "registry+https://github.com/rust-lang/crates.io-index" |
1536 checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" | 1546 checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" |
1537 | 1547 |