git-annex/Command
Joey Hess 9eb10caa27
Some optimisations to string splitting code.
Turns out that Data.List.Utils.split is slow and makes a lot of
allocations. Here's a much simpler single character splitter that behaves
the same (even in wacky corner cases) while running in half the time and
75% the allocations.

As well as being an optimisation, this helps move toward eliminating use of
missingh.

(Data.List.Split.splitOn is nearly as slow as Data.List.Utils.split and
allocates even more.)

I have not benchmarked the effect on git-annex, but would not be surprised
to see some parsing of eg, large streams from git commands run twice as
fast, and possibly in less memory.

This commit was sponsored by Boyd Stephen Smith Jr. on Patreon.
2017-01-31 19:06:22 -04:00
..
Add.hs add: Stage modified non-large files when running in indirect mode. 2016-12-05 14:10:21 -04:00
AddUnused.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
AddUrl.hs Some optimisations to string splitting code. 2017-01-31 19:06:22 -04:00
Adjust.hs adjust: Add --fix adjustment, which is useful when the git directory is in a nonstandard place. 2016-05-16 17:18:33 -04:00
Assistant.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Benchmark.hs
CalcKey.hs calckey: New plumbing command, calculates the key that would be used to refer to a file 2016-04-20 13:50:26 -04:00
CheckPresentKey.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Commit.hs
Config.hs config: New command for storing configuration in the git-annex branch. 2017-01-30 16:46:38 -04:00
ConfigList.hs
ContentLocation.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Copy.hs copy, move, mirror: Support --json and --json-progress. 2016-09-09 16:24:26 -04:00
Dead.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Describe.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
DiffDriver.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Direct.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Drop.hs get, move, copy, mirror: Added --failed switch which retries failed copies/moves 2016-08-03 12:37:12 -04:00
DropKey.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
DropUnused.hs
EnableRemote.hs implement p2p command 2016-11-30 14:35:24 -04:00
EnableTor.hs refactor 2016-12-30 12:31:17 -04:00
ExamineKey.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Expire.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Find.hs Removed dependency on json library; all JSON is now handled by aeson. 2016-07-26 19:15:34 -04:00
FindRef.hs
Fix.hs fix build warning on windows and android 2016-05-05 15:49:56 -04:00
Forget.hs
FromKey.hs Make all --batch input, as well as fromkey and registerurl stdin be processed without requiring it to be in the current encoding. 2016-12-13 15:35:04 -04:00
Fsck.hs fsck --all --from was checking the content of files in the local repository, rather than on the special remote. 2016-11-16 15:33:57 -04:00
FuzzTest.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
GCryptSetup.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Get.hs enable forwardRetry for command-line transfers 2016-10-26 15:38:27 -04:00
Group.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
GroupWanted.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Help.hs
Import.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
ImportFeed.hs Always use filesystem encoding for all file and handle reads and writes. 2016-12-24 14:46:31 -04:00
InAnnex.hs
Indirect.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Info.hs info: Support being passed a treeish, and show info about the annexed files in it similar to how a directory is handled. 2016-09-15 12:51:00 -04:00
Init.hs
InitRemote.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
List.hs list: Do not include dead repositories. 2016-06-04 14:33:31 -04:00
Lock.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
LockContent.hs git-annex-shell, remotedaemon, git remote: Fix some memory DOS attacks. 2016-12-09 13:34:32 -04:00
Log.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
LookupKey.hs
Map.hs Some optimisations to string splitting code. 2017-01-31 19:06:22 -04:00
MatchExpression.hs
Merge.hs refactor 2016-04-22 14:35:48 -04:00
MetaData.hs metadata --batch: Fix bug when conflicting metadata changes were made in the same batch run. 2016-12-13 11:07:49 -04:00
Migrate.hs
Mirror.hs copy, move, mirror: Support --json and --json-progress. 2016-09-09 16:24:26 -04:00
Move.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
NotifyChanges.hs make tor hidden service work when directory watching is not available 2016-12-09 16:40:47 -04:00
NumCopies.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
P2P.hs webapp: full wormhole pairing UI (untested) 2016-12-27 16:41:35 -04:00
PreCommit.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Proxy.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
ReadPresentKey.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
RecvKey.hs get, move, copy, mirror: Added --failed switch which retries failed copies/moves 2016-08-03 12:37:12 -04:00
RegisterUrl.hs Make all --batch input, as well as fromkey and registerurl stdin be processed without requiring it to be in the current encoding. 2016-12-13 15:35:04 -04:00
Reinit.hs
Reinject.hs avoid too-long command synopsis 2016-11-30 14:16:57 -04:00
ReKey.hs rekey --force: Incorrectly marked the new key's content as being present in the local repo even when it was not. 2016-12-19 18:18:57 -04:00
RemoteDaemon.hs remotedaemon: serve tor hidden service 2016-11-20 15:48:12 -04:00
Repair.hs
Required.hs
ResolveMerge.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
RmUrl.hs rekey: Added --batch mode. 2016-12-05 12:55:50 -04:00
Schedule.hs Fixed typo in Schedule.hs. 2016-11-24 07:37:33 -04:00
Semitrust.hs
SendKey.hs enable forwardRetry for command-line transfers 2016-10-26 15:38:27 -04:00
SetKey.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
SetPresentKey.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Smudge.hs Make git clean filter preserve the backend that was used for a file. 2016-06-09 15:17:08 -04:00
Status.hs Removed dependency on json library; all JSON is now handled by aeson. 2016-07-26 19:15:34 -04:00
Sync.hs improve comment 2016-11-16 16:03:23 -04:00
Test.hs
TestRemote.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
TransferInfo.hs git-annex-shell, remotedaemon, git remote: Fix some memory DOS attacks. 2016-12-09 13:34:32 -04:00
TransferKey.hs remove TransferObserver 2016-08-03 13:46:20 -04:00
TransferKeys.hs Always use filesystem encoding for all file and handle reads and writes. 2016-12-24 14:46:31 -04:00
Trust.hs
Unannex.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Undo.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Ungroup.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Uninit.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Unlock.hs upgrade: Handle upgrade to v6 when the repository already contains v6 unlocked files whose content is already present. 2016-10-17 15:19:47 -04:00
Untrust.hs
Unused.hs Some optimisations to string splitting code. 2017-01-31 19:06:22 -04:00
Upgrade.hs When auto-upgrading a v3 remote, avoid upgrading to version 6, instead keep it at version 5. 2016-10-05 16:23:09 -04:00
VAdd.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
VCycle.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Version.hs version: Display OS version and architecture too. 2016-05-05 16:06:01 -04:00
VFilter.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Vicfg.hs make git annex config settings editable in vicfg 2017-01-30 17:08:05 -04:00
View.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
VPop.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Wanted.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Watch.hs
WebApp.hs Avoid backtraces on expected failures when built with ghc 8; only use backtraces for unexpected errors. 2016-11-15 21:29:54 -04:00
Whereis.hs better locking for json with -J 2016-09-09 15:51:34 -04:00