From: Tyler Cipriani Date: Sun, 25 Oct 2026 06:35:04 GMT Subject: [PATCH 0/4] t: run greplint checks inside chainlint Message-ID: <20261025063508.3026136-1-tyler@tylercipriani.com> In-Reply-To: As Junio said[0], make test-lint is "uncomfortably slow". make test-lint runs both t/chainlint.pl and t/greplint.pl which do mostly the same thing on mostly the same files, both: - Open about 1100 files - Parse/lex/tokenize the files - Run checks - which is the only place chainlint and greplint vary Plus, greplint processes files serially. So we're doing the same work twice and half the work happens in serial. Following Peff's suggestion, this series teaches chainlint.pl to run the greplint checks while running checks on its own tokens. So "make test-lint" parses each file once, in parallel. Keep greplint.pl as a standalone for GIT_TEST_CHAIN_LINT=0. Peff's early return (patch 2) speeds up standalone greplint.pl (when greplint does its own parsing). Peff: Can I add your Signed-off-by to your patch in the series? It does, indeed, cut time in half when greplint does its own parsing. Before this series: $ time sh -c 'for c in 1 2 3 4 5; do make test-lint; done' real 0m25.158s user 0m51.557s sys 0m0.899s After this series: $ time sh -c 'for c in 1 2 3 4 5; do make test-lint; done' real 0m5.972s user 0m41.536s sys 0m0.943s (nproc == 16 for both) [0]. https://lore.kernel.org/git/xmqqjynueq81.fsf@gitster.g/ Jeff King (1): t/greplint: skip test bodies without the word grep Tyler Cipriani (3): t/interop: replace bare grep with test_grep t/greplint: move parsing and token check to library t/chainlint: add --greplint to run greplint t/Makefile | 30 +++- t/chainlint.pl | 24 ++- t/greplint.pl | 240 +------------------------ t/interop/i5700-protocol-transition.sh | 10 +- t/{greplint.pl => lib-greplint.pl} | 78 ++++---- 5 files changed, 93 insertions(+), 289 deletions(-) copy t/{greplint.pl => lib-greplint.pl} (85%) base-commit: 7e34d8174dcda3435d1404c9a30bef46afe6c13e -- 2.47.3