From f6798c006df0ccf5427238ffbdf541f4590fcb86 Mon Sep 17 00:00:00 2001 From: Claude Date: Tue, 27 Oct 2026 09:08:15 +0000 Subject: [PATCH] script: use the smallest dictionary grid at q10/q11 for big inputs Like the regular grid, qualities 10 and 11 use the smallest dictionary configuration set for inputs longer than 64 KiB. --- script/manual-test-brotli-encoder-parity.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/script/manual-test-brotli-encoder-parity.c b/script/manual-test-brotli-encoder-parity.c index edddc495..5257f741 100644 --- a/script/manual-test-brotli-encoder-parity.c +++ b/script/manual-test-brotli-encoder-parity.c @@ -1388,7 +1388,10 @@ run_input_dict(const char* name, const uint8_t* data, size_t len) { continue; } for (uint32_t q = g_qmin; q <= g_qmax; q++) { - run_dict_configs(name, data, len, q, level); + // Qualities 10 and 11 (which are much slower) use the smallest grid + // for inputs longer than 64 KiB. + run_dict_configs(name, data, len, q, + ((q >= 10) && (len > (64 << 10))) ? 2 : level); if ((set == 1) && (len >= 1000) && (q >= 5)) { check_smaller(name, data, len, q); }