Skip to content
This repository was archived by the owner on Sep 11, 2020. It is now read-only.

plumbing: format/packfile, performance optimizations for reading large commit histories #963

Merged
merged 12 commits into from
Nov 28, 2018
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Improve performace for reading many small objects from packfile by le…
…tting the I/O buffers be used better.

Signed-off-by: Filip Navara <[email protected]>
  • Loading branch information
filipnavara committed Nov 26, 2018
commit 4a21431163cb42f605d35884f674304245e99370
2 changes: 1 addition & 1 deletion plumbing/format/packfile/packfile.go
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ func (p *Packfile) objectAtOffset(offset int64) (plumbing.EncodedObject, error)

// If we have no filesystem, we will return a MemoryObject instead
// of an FSObject.
if p.fs == nil {
if p.fs == nil || h.Length <= 16 * 1024 {
return p.getNextObject(h)
}

Expand Down