3 ms·
> 250k+ manifests of more than 5MB each on average (most recent ones are larger than 10MB), even with a SHA-1function doing 1GB/s (and I think we barely reach h
by glandium 11y ago
> 250k+ manifests of more than 5MB each on average (most recent ones are larger than 10MB), even with a SHA-1function doing 1GB/s (and I think we barely reach half that), that should take more than 20 minutes
That puzzled me, so I recorded every time addrevision and checkhash are called, and it turns out that Mercurial is not, in fact, checking the SHA-1 of everything. On the current bundle for mozilla-central, it checks:
- All 282460 changesets
- 256 manifests (of 282232)
- 262675 file revisions (of 1615480) for 237574 files, so slightly more than 1 file revision per file but less than 2, on average.
Edit: Reading the code, essentially, it trusts deltas from bundles.
Edit 2: For fairness, it does check SHA-1 when checking out and committing (it even checks the parent changeset 4 times and the new changeset twice), but not when doing hg verify.