-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
dumpfile: minor performance improvements
Printing out the dumpfile seems to take ~50% of the total time of running the `create-dumpfile` command, which is surprising. Let's pick off some low-hanging fruit by doing fewer allocations: - preallocate the string buffer we use for each line - use the push/pop API of PathBuf instead of creating a new PathBuf every time with .join(). This also solves the question of how we can consume the new PathBuf into the hardlinks table: we now definitely can't, so making a copy is now obviously correct.
- Loading branch information
1 parent
9c1b0dc
commit 2074f3a
Showing
1 changed file
with
11 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters