summaryrefslogtreecommitdiff
path: root/t/perf
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2017-07-05 13:32:56 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2017-07-05 13:32:56 -0700
commit5ab148dda0076a136b4afb385d96bd9cdc4d2590 (patch)
tree6e6876952e2e6a1154258c9a9e11428572d4dcf9 /t/perf
parentMerge branch 'bw/repo-object' (diff)
parentsha1_file: guard against invalid loose subdirectory numbers (diff)
downloadtgif-5ab148dda0076a136b4afb385d96bd9cdc4d2590.tar.xz
Merge branch 'rs/sha1-name-readdir-optim'
Optimize "what are the object names already taken in an alternate object database?" query that is used to derive the length of prefix an object name is uniquely abbreviated to. * rs/sha1-name-readdir-optim: sha1_file: guard against invalid loose subdirectory numbers sha1_file: let for_each_file_in_obj_subdir() handle subdir names p4205: add perf test script for pretty log formats sha1_name: cache readdir(3) results in find_short_object_filename()
Diffstat (limited to 't/perf')
-rwxr-xr-xt/perf/p4205-log-pretty-formats.sh16
1 files changed, 16 insertions, 0 deletions
diff --git a/t/perf/p4205-log-pretty-formats.sh b/t/perf/p4205-log-pretty-formats.sh
new file mode 100755
index 0000000000..7c26f4f337
--- /dev/null
+++ b/t/perf/p4205-log-pretty-formats.sh
@@ -0,0 +1,16 @@
+#!/bin/sh
+
+test_description='Tests the performance of various pretty format placeholders'
+
+. ./perf-lib.sh
+
+test_perf_default_repo
+
+for format in %H %h %T %t %P %p %h-%h-%h
+do
+ test_perf "log with $format" "
+ git log --format=\"$format\" >/dev/null
+ "
+done
+
+test_done