]> arthur.barton.de Git - bup.git/commitdiff
cmd/midx: fix SHA_PER_PAGE calculation.
authorAvery Pennarun <apenwarr@gmail.com>
Thu, 26 Aug 2010 04:06:46 +0000 (21:06 -0700)
committerAvery Pennarun <apenwarr@gmail.com>
Thu, 26 Aug 2010 04:23:41 +0000 (21:23 -0700)
For some reason we were dividing by 200 instead of by 20, which was way off.
Switch to 20 instead.  Suspiciously, this makes memory usage slightly worse
in my current (smallish) set of test data, so we might need to revert it
later...?  But if we're going to have an adjustment, we should at least make
it clear what for, rather than hiding it in something that looks
suspiciously like a typo.

Signed-off-by: Avery Pennarun <apenwarr@gmail.com>
cmd/midx-cmd.py

index e43e3126c3c44197c6b455e74f34a3a12c6fd6ed..bbfd2acc0d2a562b26c755f64636f8debdd0467d 100755 (executable)
@@ -4,7 +4,7 @@ from bup import options, git
 from bup.helpers import *
 
 PAGE_SIZE=4096
-SHA_PER_PAGE=PAGE_SIZE/200.
+SHA_PER_PAGE=PAGE_SIZE/20.
 
 
 def merge(idxlist, bits, table):