1
0
Fork 0
mirror of https://github.com/git/git.git synced 2024-11-05 16:52:59 +01:00
git/lib
Clemens Buchacher 88520cadf9 git-gui: search 4 directories to improve statistic of gc hint
On Windows, git-gui suggests running the garbage collector if it finds
1 or more files in .git/objects/42 (as opposed to 8 files on other
platforms). The probability of that happening if the repo contains
about 100 loose objects is 32%. The probability for the same to happen
when searching 4 directories is only 8%, which is bit more reasonable.

Also remove $objects_limit from the message, because we already know
that we are above (or close to) that limit. Telling the user about
that number does not really give him any useful information.

The following octave script shows the probability for at least m*q
objects to be found in q subdirectories of .git/objects if n is the
total number of objects.

q = 4;
m = [1 2 8];
n = 0:10:2000;

P = zeros(length(n), length(m));
for k = 1:length(n)
        P(k, :) = 1-binocdf(q*m-1, n(k), q/(256-q));
end
plot(n, P);

n \ q   1       4
50      18%     1%
100     32%     8%
200     54%     39%
500     86%     96%

Signed-off-by: Clemens Buchacher <drizzd@aon.at>
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
2009-12-05 13:48:03 -08:00
..
about.tcl git-gui: Ensure all spellchecker 'class' variables are initialized 2008-02-21 00:22:06 -05:00
blame.tcl git-gui: Fix commit encoding handling. 2008-12-08 08:33:05 -08:00
branch.tcl git-gui: Always use absolute path to all git executables 2007-07-09 01:17:09 -04:00
branch_checkout.tcl Mark strings for translation. 2007-09-02 16:54:48 +01:00
branch_create.tcl git-gui: Setup branch.remote,merge for shorthand git-pull 2008-05-08 20:20:27 -04:00
branch_delete.tcl git-gui: minor spelling fix and string factorisation. 2009-03-24 16:17:30 -07:00
branch_rename.tcl git-gui: Paper bag fix missing translated strings 2007-09-14 01:51:18 -04:00
browser.tcl git-gui: Allow specifying an initial line for git gui blame. 2008-08-24 22:00:01 -07:00
checkout_op.tcl git-gui: run post-checkout hook on checkout 2009-04-05 12:58:26 -07:00
choose_font.tcl git-gui: if a background colour is set, set foreground colour as well 2008-03-05 23:47:11 -05:00
choose_repository.tcl git-gui: run post-checkout hook after clone 2009-04-08 07:42:54 -07:00
choose_rev.tcl git-gui: Work around random missing scrollbar in revision list 2008-01-22 23:37:15 -05:00
class.tcl git-gui: Fix window manager problems on ion3 2007-08-20 00:38:13 -04:00
commit.tcl git-gui: When calling post-commit hook wrong variable was cleared. 2009-04-05 12:45:40 -07:00
console.tcl git-gui: if a background colour is set, set foreground colour as well 2008-03-05 23:47:11 -05:00
database.tcl git-gui: search 4 directories to improve statistic of gc hint 2009-12-05 13:48:03 -08:00
date.tcl git-gui: Localize commit/author dates when displaying them 2007-09-10 01:54:16 -04:00
diff.tcl git-gui: Ensure submodule path is quoted properly 2009-08-26 17:42:50 -07:00
encoding.tcl git-gui: Optimize encoding name resolution using a lookup table. 2008-09-24 12:48:32 -07:00
error.tcl git-gui: if a background colour is set, set foreground colour as well 2008-03-05 23:47:11 -05:00
git-gui.ico git-gui: Improve the application icon on Windows. 2007-12-02 23:05:10 -05:00
index.tcl git-gui: Make Ctrl-T safe to use for conflicting files. 2008-09-30 11:47:33 -07:00
logo.tcl git-gui: Refactor Henrik Nyh's logo into its own procedure 2007-10-10 01:12:15 -04:00
merge.tcl git-gui: Fix switch statement in lib/merge.tcl 2008-10-10 09:31:58 -07:00
mergetool.tcl git-gui: Ensure consistent usage of mergetool.keepBackup 2009-04-08 07:40:58 -07:00
option.tcl git-gui: Implement system-wide configuration handling. 2008-11-16 13:33:09 -08:00
remote.tcl git-gui: Fix removing non-pushable remotes 2008-09-30 12:59:37 -07:00
remote_add.tcl git-gui: Fix fetching from remotes when adding them 2008-09-30 12:59:37 -07:00
remote_branch_delete.tcl git gui: make current branch default in "remote delete branch" merge check 2009-12-05 13:17:51 -08:00
search.tcl git-gui: Fix the search bar destruction handler. 2008-11-16 14:02:13 -08:00
shortcut.tcl Append ampersand to "Target" of lnk files created by do_cygwin_shortcut 2009-03-09 16:21:17 -07:00
spellcheck.tcl git-gui: Remove space from the end of aspell's reply before processing 2008-09-30 12:59:18 -07:00
sshkey.tcl git-gui: Add a dialog that shows the OpenSSH public key. 2008-11-01 16:01:23 -07:00
status_bar.tcl Merge branch 'maint' 2007-10-20 20:43:36 -04:00
tools.tcl git-gui: minor spelling fix and string factorisation. 2009-03-24 16:17:30 -07:00
tools_dlg.tcl git-gui: Allow Tools request arguments from the user. 2008-11-16 13:33:09 -08:00
transport.tcl git-gui: Teach start_push_anywhere_action{} to notice when remote is a mirror. 2008-12-02 07:20:19 -08:00
win32.tcl git-gui: Use proper Windows shortcuts instead of bat files 2007-10-12 23:07:58 -04:00
win32_shortcut.js git-gui: Use proper Windows shortcuts instead of bat files 2007-10-12 23:07:58 -04:00