shithub: gefs

Download patch

ref: 19d4db9fddeaecaa7017c2557013c776183bcad5
parent: e211e19a42770000cf97c3dad712a79b9201aeb8
author: Ori Bernstein <ori@eigenstate.org>
date: Thu Nov 2 12:19:44 EDT 2023

blk: shrink max log size

--- a/fs.c
+++ b/fs.c
@@ -2314,7 +2314,7 @@
 		 * don't want to spend a ton of time compressing, though,
 		 * so we only do the compression when our log gets big.
 		 *
-		 * 1/4 of our reserved emergency space seems like a good
+		 * 10% of our reserved emergency space seems like a good
 		 * heuristic for big, but it was picked arbitrarily.
 		 */
 		qlock(&fs->synclk);
@@ -2321,7 +2321,7 @@
 		for(i = 0; i < fs->narena; i++){
 			epochstart(id);
 			qlock(&fs->arenas[i]);
-			c = fs->arenas[i].nlog > fs->arenas[i].reserve/(4*Blksz);
+			c = fs->arenas[i].nlog > fs->arenas[i].reserve/(10*Blksz);
 			if(c){
 				if(compresslog(&fs->arenas[i]) == -1)
 					fprint(2, "compress log: %r");