Git development
 help / color / mirror / Atom feed
From: Derrick Stolee <stolee@gmail.com>
To: Junio C Hamano <gitster@pobox.com>,
	Jayesh Daga via GitGitGadget <gitgitgadget@gmail.com>
Cc: git@vger.kernel.org, Jayesh Daga <jayeshdaga99@gmail.com>
Subject: Re: [PATCH v4] read-cache: use istate->repo for trace2 logging
Date: Thu, 2 Apr 2026 10:26:14 -0400	[thread overview]
Message-ID: <fbf03f6a-c746-4b6b-81fb-f3eb4b2e2f0e@gmail.com> (raw)
In-Reply-To: <xmqqpl4ldqyi.fsf@gitster.g>

On 3/30/26 4:04 PM, Junio C Hamano wrote:
> "Jayesh Daga via GitGitGadget" <gitgitgadget@gmail.com> writes:
> 
>> From: Jayesh Daga <jayeshdaga99@gmail.com>
>>
>> trace2 calls in read-cache.c use the global 'the_repository',
>> even though the relevant index_state provides an explicit
>> repository pointer via 'istate->repo'.
>>
>> Using the global repository can result in incorrect trace2
>> output when multiple repository instances are in use, as
>> events may be attributed to the wrong repository.
>>
>> Use 'istate->repo' instead to ensure correct repository
>> attribution.
>>
>> Signed-off-by: Jayesh Daga <jayeshdaga99@gmail.com>
>> ---
>> Range-diff vs v3:
>>
>>   1:  5a8165b05d < -:  ---------- repo: add paths.git_dir repo info key
>>   2:  9bb6d0fa01 = 1:  c99d731efa read-cache: use istate->repo for trace2 logging
> 
> A range-diff with v2 would have been much more relevant, but the
> patch below looks super boring compared to v2 which is very good.
> Just replacing the_repository with istate->repo and nothing else,
> which is exactly we expect to see from the patch title above ;-)
> 
> Will queue.  Thanks.

Thanks for putting in the work to create this complete
commit. LGTM.

-Stolee

  reply	other threads:[~2026-04-02 14:26 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-27 10:08 [PATCH] read-cache: use index state repository for trace2 logging Jayesh Daga via GitGitGadget
2026-03-27 13:48 ` Derrick Stolee
2026-03-27 16:28   ` Junio C Hamano
2026-03-28  5:25     ` jayesh0104
2026-03-28  7:14 ` [PATCH v2] read-cache: use istate->repo " Jayesh Daga via GitGitGadget
2026-03-28 18:36   ` Junio C Hamano
2026-03-29 14:57     ` Derrick Stolee
2026-03-30 17:27   ` [PATCH v3 0/2] [GSoC] read-cache: use index state repository " Jayesh Daga via GitGitGadget
2026-03-30 17:27     ` [PATCH v3 1/2] repo: add paths.git_dir repo info key jayesh0104 via GitGitGadget
2026-03-30 17:27     ` [PATCH v3 2/2] read-cache: use istate->repo for trace2 logging Jayesh Daga via GitGitGadget
2026-03-30 18:38     ` [PATCH v4] " Jayesh Daga via GitGitGadget
2026-03-30 20:04       ` Junio C Hamano
2026-04-02 14:26         ` Derrick Stolee [this message]
2026-04-02 15:25           ` [PATCH] " Jayesh Daga

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=fbf03f6a-c746-4b6b-81fb-f3eb4b2e2f0e@gmail.com \
    --to=stolee@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitgitgadget@gmail.com \
    --cc=gitster@pobox.com \
    --cc=jayeshdaga99@gmail.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox