git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 1/2] Introduce grep threads param

From
Eric Sunshine <sunshine@sunshineco.com>
Date
Dec 16, 2015, 00:26 UTC
Message-ID
<CAPig+cRTz=DMd6XyJ=co26d2c=PgVqhhsWQpgy53930MdC_=Rw@mail.gmail.com>
In-Reply-To
<xmqq60zzfpdz.fsf@gitster.mtv.corp.google.com>
On Tue, Dec 15, 2015 at 3:06 PM, Junio C Hamano <gitster@pobox.com> wrote:
Show 14 quoted lines
> Victor Leschuk <vleschuk@gmail.com> writes:
>> Subject: Re: [PATCH 1/2] Introduce grep threads param
>
> I'll retitle this to something like
>
>     grep: add --threads=<num> option and grep.threads configuration
>
> while queuing (which I did for v7 earlier).
>
> I think [2/2] and also moving the code to disable threading when
> show-in-pager mode should be separate "preparatory clean-up" patches
> before this main patch.  I'll push out what I think this topic
> should be on 'pu' later today (with fixups suggested above squashed
> in); please check them and see what you think.
I read over what was pushed to 'pu' and noticed a couple problems.

First, the 'online_cpus() == 1' check, which was removed in patch 1/3, accidentally creeps back in with patch 3/3.

Show 13 quoted lines
>> +grep.threads::
>> +     Number of grep worker threads, use it to tune up performance on
>> +     your machines. Leave it unset (or set to 0) for default behavior,
>> +     which is using 8 threads for all systems.
>> +     Default behavior may change in future versions
>> +     to better suit hardware and circumstances.
>
> The last sentence is too noisy.  Perhaps drop it and phrase it like
> this instead?
>
>     grep.threads::
>             Number of grep worker threads to use.  If unset (or set to 0),
>             to 0), 8 threads are used by default (for now).
Second, the stray "to 0)," on the second line needs to be dropped.
Other than that, the series looks reasonable.
Previous: Victor LeschukNext: Victor Leschuk
Message 5 of 6 in “Add git-grep threads param”
  1. 0/2 Add git-grep threads paramVictor Leschuk, Dec 15, 2015
  2. 1/2 Introduce grep threads paramVictor Leschuk, Dec 15, 2015
  3. Junio C HamanoDec 15, 2015
  4. Victor LeschukDec 15, 2015
  5. Eric SunshineDec 16, 2015
  6. 2/2 Get rid of online_cpus() when determining grep threads numVictor Leschuk, Dec 15, 2015

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.