From 8b4ac80545db00743f298eba0958dfee550da89a Mon Sep 17 00:00:00 2001 From: Avery Pennarun Date: Wed, 25 Aug 2010 21:06:46 -0700 Subject: [PATCH] cmd/midx: fix SHA_PER_PAGE calculation. 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 --- cmd/midx-cmd.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/midx-cmd.py b/cmd/midx-cmd.py index e43e312..bbfd2ac 100755 --- a/cmd/midx-cmd.py +++ b/cmd/midx-cmd.py @@ -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): -- 2.39.2