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

Re: [GSoC] Applying for conversion scripts to builtins

From
Junio C Hamano <gitster@pobox.com>
Date
Mar 17, 2015, 18:38 UTC
Message-ID
<xmqqpp87o4eo.fsf@gitster.dls.corp.google.com>
In-Reply-To
<4355599932558291b22313f244eda9bd@www.dscho.org>
Johannes Schindelin <johannes.schindelin@gmx.de> writes:
> Therefore, I would wager a bet that just the mere conversion of a
> shell script into even a primitive `run_command()`-based builtin would
> help performance on Windows in a noticeable manner.

As you correctly allege, if a patch rewrote a shell-scripted porcelain by using series of run_command() and doing nothing else, I would have asked "is that an improvement?", without knowing that.

> Of course, it would be *even nicer* to avoid the spawning altogether.
Yeah, that, too ;-)
Show 12 quoted lines
> The biggest benefit of avoiding needless parsing, however, is not
> performance. It is avoiding quoting issues. This is particularly so on
> Windows, where Git is sometimes called from outside a shell
> environment, where we have to deal with inconsistent quoting because
> it is every Windows program's own job to parse the command-line,
> including the quoting.
>
> Concrete example: on Windows, we have file locking issues because
> files that are in use cannot be deleted. For that reason, we have
> Windows-specific code that is "nice" by trying harder to delete files,
> giving programs a little time to let their locks go. This locking
> issue happens also when a virus scanner "uses"...
These are definitely good advices from the area expert.
Thanks for a bunch of good input.
Previous: Johannes Schindelin
Message 6 of 6 in “[GSoC] Applying for conversion scripts to builtins”
  1. Yurii ShevtsovMar 16, 2015
  2. Matthieu MoyMar 16, 2015
  3. Paul TanMar 17, 2015
  4. Duy NguyenMar 17, 2015
  5. Johannes SchindelinMar 17, 2015
  6. Junio C HamanoMar 17, 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.