aboutsummaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit/resources/org/eclipse/jgit/internal
diff options
context:
space:
mode:
authorAnna Papitto <annapapitto@google.com>2023-07-14 12:19:27 -0700
committerAnna Papitto <annapapitto@google.com>2023-07-18 15:19:26 -0700
commit000e7caf5e35ac0fb357aa10f13329f03b4dbee0 (patch)
treeb3da61c538b6742f48dc54b4c8ee12ea7d263c27 /org.eclipse.jgit/resources/org/eclipse/jgit/internal
parent7d2669587f475f3fba1acce9df257aed3c0714cd (diff)
downloadjgit-000e7caf5e35ac0fb357aa10f13329f03b4dbee0.tar.gz
jgit-000e7caf5e35ac0fb357aa10f13329f03b4dbee0.zip
PackReverseIndexV1: reverse index parsed from version 1 file
The reverse index for a pack is used to quickly find an object's position in the pack's forward index based on that object's pack offset. It is currently computed from the forward index by sorting the index entries by the corresponding pack offset. This computation uses insertion sort, which has an average runtime of O(n^2). Cgit persists a pack reverse index file to avoid recomputing the reverse index ordering. Instead they write a file with format https://git-scm.com/docs/pack-format#_pack_rev_files_have_the_format which can later be read and parsed into the in-memory reverse index each time it is needed. PackReverseIndexV1 parses a reverse index file with the official version 1 format into an in-memory representation of the reverse index which implements methods to find an object's forward index position from its offset in logorithmic time. Change-Id: I60a92463fbd6a8cc9c1c7451df1c14d0a21a0f64 Signed-off-by: Anna Papitto <annapapitto@google.com>
Diffstat (limited to 'org.eclipse.jgit/resources/org/eclipse/jgit/internal')
-rw-r--r--org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties1
1 files changed, 1 insertions, 0 deletions
diff --git a/org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties b/org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties
index bc8144f1c9..bf8a1ef5db 100644
--- a/org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties
+++ b/org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties
@@ -689,6 +689,7 @@ searchForReachableBranches=Finding reachable branches
saveFileStoreAttributesFailed=Saving measured FileStore attributes to user config failed
searchForReuse=Finding sources
searchForReuseTimeout=Search for reuse timed out after {0} seconds
+unsupportedObjectIdVersion=Object id version {0} is not supported
searchForSizes=Getting sizes
secondsAgo={0} seconds ago
selectingCommits=Selecting commits