All of lore.kernel.org
 help / color / mirror / Atom feed
From: Derrick Stolee <stolee@gmail.com>
To: Johannes Schindelin via GitGitGadget <gitgitgadget@gmail.com>,
	git@vger.kernel.org
Cc: Patrick Steinhardt <ps@pks.im>,
	Johannes Schindelin <johannes.schindelin@gmx.de>
Subject: Re: [PATCH] perf: do allow `GIT_PERF_*` to be overridden again
Date: Fri, 4 Apr 2025 08:13:15 -0400	[thread overview]
Message-ID: <3bc8a906-ead6-4cce-9658-d45feb76cebf@gmail.com> (raw)
In-Reply-To: <pull.1900.git.1743764167548.gitgitgadget@gmail.com>

On 4/4/2025 6:56 AM, Johannes Schindelin via GitGitGadget wrote:
> From: Johannes Schindelin <johannes.schindelin@gmx.de>
> 
> A common way to run Git's performance benchmarks on repositories other
> than Git's own repository (which is not exactly large when compared to
> actually large repositories) is to run them like this:
> 
> 	GIT_PERF_LARGE_REPO=/path/to/my/large/repo \
> 	./p1234-*.sh -ivx
> 

This issue also extends to other necessary variables such as
GIT_PERF_REPEAT_COUNT.  
> +# GIT-BUILD-OPTIONS, sourced by test-lib.sh, overwrites the `GIT_PERF_*`
> +# values that are set by the user (if any). Let's stash them away as
> +# `eval`-able assignments.
> +git_perf_settings="$(env |
> +	sed -n "/^GIT_PERF_/{
> +		# escape all single-quotes in the value
> +		s/'/'\\\\''/g
> +		# turn this into an eval-able assignment
> +		s/^\\([^=]*=\\)\\(.*\\)/\\1'\\2'/p
> +	}")"
> +
>  . ../test-lib.sh
> +eval "$git_perf_settings"
I verified this fix in my local environment. Thanks so much for digging
in and finding the solution here!

-Stolee


  reply	other threads:[~2025-04-04 12:13 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-04 10:56 [PATCH] perf: do allow `GIT_PERF_*` to be overridden again Johannes Schindelin via GitGitGadget
2025-04-04 12:13 ` Derrick Stolee [this message]
2025-04-19  3:54 ` Jeff King
2025-04-20 21:12   ` Junio C Hamano
2025-04-22 10:41     ` Jeff King
2025-04-22 15:37       ` Junio C Hamano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3bc8a906-ead6-4cce-9658-d45feb76cebf@gmail.com \
    --to=stolee@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitgitgadget@gmail.com \
    --cc=johannes.schindelin@gmx.de \
    --cc=ps@pks.im \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.