summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: b81d9af)
raw | patch | inline | side by side (parent: b81d9af)
author | Nicolas Pitre <nico@cam.org> | |
Mon, 10 Sep 2007 15:51:34 +0000 (11:51 -0400) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Mon, 10 Sep 2007 17:50:21 +0000 (10:50 -0700) |
Signed-off-by: Nicolas Pitre <nico@cam.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Documentation/config.txt | patch | blob | history | |
builtin-pack-objects.c | patch | blob | history |
index 866e0534b8843af3c1789becd06b244162632d01..015910f27a450cdaec80f3bfc2679243126736c0 100644 (file)
--- a/Documentation/config.txt
+++ b/Documentation/config.txt
A value of 0 means no limit. Defaults to 0.
pack.deltaCacheLimit::
- The maxium size of a delta, that is cached in
+ The maximum size of a delta, that is cached in
gitlink:git-pack-objects[1]. Defaults to 1000.
+pack.threads::
+ Specifies the number of threads to spawn when searching for best
+ delta matches. This requires that gitlink:git-pack-objects[1]
+ be compiled with pthreads otherwise this option is ignored with a
+ warning. This is meant to reduce packing time on multiprocessor
+ machines. The required amount of memory for the delta search window
+ is however multiplied by the number of threads.
+
pull.octopus::
The default merge strategy to use when pulling multiple branches
at once.
diff --git a/builtin-pack-objects.c b/builtin-pack-objects.c
index af12e454e183d69eb34c369e2c789a7c0a921b80..e091bcbda9233f8b1bfe25f6aa4d702614d42435 100644 (file)
--- a/builtin-pack-objects.c
+++ b/builtin-pack-objects.c
cache_max_small_delta_size = git_config_int(k, v);
return 0;
}
+ if (!strcmp(k, "pack.threads")) {
+ delta_search_threads = git_config_int(k, v);
+ if (delta_search_threads < 1)
+ die("invalid number of threads specified (%d)",
+ delta_search_threads);
+#ifndef THREADED_DELTA_SEARCH
+ if (delta_search_threads > 1)
+ warning("no threads support, ignoring %s", k);
+#endif
+ return 0;
+ }
return git_default_config(k, v);
}