optimise catfile interface with ByteString and Attoparsec
Around 3% total speedup. Profiling git annex find --not --in web, it's now bytestring end-to-end, and there is only a little added overhead in eg accessing the Annex state MVar (3%). The rest of the runtime is spent reading symlinks, and in attoparsec. This feels like the end of the optimisation road, without a major change like caching information for faster queries.
This commit is contained in:
parent
2caf579718
commit
86426036a0
3 changed files with 31 additions and 23 deletions
|
@ -101,6 +101,7 @@ newtype RefDate = RefDate String
|
|||
|
||||
{- Types of objects that can be stored in git. -}
|
||||
data ObjectType = BlobObject | CommitObject | TreeObject
|
||||
deriving (Show)
|
||||
|
||||
readObjectType :: S.ByteString -> Maybe ObjectType
|
||||
readObjectType "blob" = Just BlobObject
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue