From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS53758 23.128.96.0/24 X-Spam-Status: No, score=-3.8 required=3.0 tests=AWL,BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE, SPF_HELO_PASS,SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by dcvr.yhbt.net (Postfix) with ESMTP id 002791F8C6 for ; Thu, 1 Jul 2021 21:43:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233575AbhGAVp5 (ORCPT ); Thu, 1 Jul 2021 17:45:57 -0400 Received: from cloud.peff.net ([104.130.231.41]:39316 "EHLO cloud.peff.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229934AbhGAVp4 (ORCPT ); Thu, 1 Jul 2021 17:45:56 -0400 Received: (qmail 29050 invoked by uid 109); 1 Jul 2021 21:43:25 -0000 Received: from Unknown (HELO peff.net) (10.0.1.2) by cloud.peff.net (qpsmtpd/0.94) with ESMTP; Thu, 01 Jul 2021 21:43:25 +0000 Authentication-Results: cloud.peff.net; auth=none Received: (qmail 19488 invoked by uid 111); 1 Jul 2021 21:43:24 -0000 Received: from coredump.intra.peff.net (HELO sigill.intra.peff.net) (10.0.0.2) by peff.net (qpsmtpd/0.94) with (TLS_AES_256_GCM_SHA384 encrypted) ESMTPS; Thu, 01 Jul 2021 17:43:24 -0400 Authentication-Results: peff.net; auth=none Date: Thu, 1 Jul 2021 17:43:23 -0400 From: Jeff King To: =?utf-8?B?w4Z2YXIgQXJuZmrDtnLDsA==?= Bjarmason Cc: Martin Langhoff , Git Mailing List , Taylor Blau Subject: Re: git log exclude pathspec from file - supported? plans? Message-ID: References: <87sg0zdx7z.fsf@evledraar.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org On Thu, Jul 01, 2021 at 05:27:05PM -0400, Jeff King wrote: > > One of the PCREv2 experiments I had very early WIP work towards was to > > create a search index for commit messages, contents etc. and stick it in > > something similar to the --changed-paths part of the commit-graph. > > Yeah, to some degree --change-paths may mitigate this, since for a > series of simple pathspecs we'd generate the bloom filter once and then > get O(1) matching per commit. The timings for "git rev-list" I shared earlier were with commit-graphs, but not with changed-path filters. They don't seem to help much, though. I suspect the reason is that they can never give a definite answer. They can only say "probably, yes, this commit is worth looking at". And then we have to do the same slow, linear pathspec match on that commit. And if your pathspec contains virtually every path in the first place, then the answer from the bloom filters will always be "probably, yes". So I guess they are not really a silver bullet here. -Peff