All of lore.kernel.org
 help / color / mirror / Atom feed
From: Taylor Blau <me@ttaylorr.com>
To: blanet via GitGitGadget <gitgitgadget@gmail.com>
Cc: git@vger.kernel.org, blanet <bupt_xingxin@163.com>,
	Xing Xin <xingxin.xx@bytedance.com>
Subject: Re: [PATCH] midx: disable replace objects
Date: Sun, 7 Apr 2024 14:04:30 -0400	[thread overview]
Message-ID: <ZhLgLhv4LRcYrm7X@nand.local> (raw)
In-Reply-To: <ZhLfqU9VNUW+2mmV@nand.local>

On Sun, Apr 07, 2024 at 02:02:17PM -0400, Taylor Blau wrote:
> It is tempting to instead do something like:
>
> --- 8< ---
> diff --git a/pack-bitmap-write.c b/pack-bitmap-write.c
> index c6c8f94cc5..cbc543caad 100644
> --- a/pack-bitmap-write.c
> +++ b/pack-bitmap-write.c
> @@ -17,6 +17,7 @@
>  #include "trace2.h"
>  #include "tree.h"
>  #include "tree-walk.h"
> +#include "replace-object.h"
>
>  struct bitmapped_commit {
>  	struct commit *commit;
> @@ -223,6 +224,8 @@ static void bitmap_builder_init(struct bitmap_builder *bb,
>  	memset(bb, 0, sizeof(*bb));
>  	init_bb_data(&bb->data);
>
> +	parsed_object_pool_clear(the_repository->parsed_objects);
> +
>  	reset_revision_walk();
>  	repo_init_revisions(writer->to_pack->repo, &revs, NULL);
>  	revs.topo_order = 1;
> --- >8 ---

Oops. I meant to attach a diff here that calls disable_replace_refs(),
not parsed_object_pool_clear().

> But by then it is too late, because the replace refs have already been
> taken into account for parsed objects.

Thanks,
Taylor

  reply	other threads:[~2024-04-07 18:04 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-07 13:11 [PATCH] midx: disable replace objects blanet via GitGitGadget
2024-04-07 14:16 ` Taylor Blau
2024-04-07 18:02   ` Taylor Blau
2024-04-07 18:04     ` Taylor Blau [this message]
2024-04-08  5:45     ` [External] " 鑫邢
2024-04-08  5:26 ` [PATCH v2] " blanet via GitGitGadget
2024-04-17 19:34   ` Junio C Hamano
2024-04-18 13:22     ` Taylor Blau
2024-04-18 16:06       ` 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=ZhLgLhv4LRcYrm7X@nand.local \
    --to=me@ttaylorr.com \
    --cc=bupt_xingxin@163.com \
    --cc=git@vger.kernel.org \
    --cc=gitgitgadget@gmail.com \
    --cc=xingxin.xx@bytedance.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 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.