File: optimize_by_converting_String_to_ByteString.mdwn

package info (click to toggle)
git-annex 8.20210223-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 68,764 kB
  • sloc: haskell: 70,359; javascript: 9,103; sh: 1,304; makefile: 212; perl: 136; ansic: 44
file content (17 lines) | stat: -rw-r--r-- 655 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
git-annex uses FilePath (String) extensively. That's a slow data type.
Converting to ByteString, and RawFilePath, should speed it up
significantly, according to [[/profiling]].

I've made a test branch, `bs`, to see what kind of performance improvement
to expect. 

Benchmarking `git-annex find`, speedups range from 28-66%. The files fly by
much more snappily. Other commands likely also speed up, but do more work
than find so the improvement is not as large.

The `bs` branch is in a mergeable state now. [[done]]

Stuff not entirely finished:

* Profile various commands and look for hot spots involving conversion
  between RawFilePath and FilePath.