From a8229cd0e1683a8b028768c97c2fce141c7edd20 Mon Sep 17 00:00:00 2001 From: Uwe Hermann Date: Tue, 17 Apr 2018 00:23:19 +0200 Subject: [PATCH] input: Increase chunk size from 16KB to 4MB. This not only slightly speeds up loading files, but more importantly leads to larger chunks being passed to input modules (and later potentially output modules), some of which can have a large performance penalty for small chunks. In the specific case of e.g. binary input and an .sr output file this change can lead to a speedup of 220x or more (due to larger chunks for srzip). --- input.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/input.c b/input.c index 21c28cd..9a9545f 100644 --- a/input.c +++ b/input.c @@ -28,7 +28,7 @@ #include #include "sigrok-cli.h" -#define BUFSIZE (16 * 1024) +#define BUFSIZE (4 * 1024 * 1024) static void load_input_file_module(void) { -- 2.30.2