From: Nguyen Thai Ngoc Duy <pclouds@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: git@vger.kernel.org
Subject: Re: [PATCH 1/2] rm: only refresh entries that we may touch
Date: Sat, 16 Jan 2010 17:58:41 +0700 [thread overview]
Message-ID: <fcaeb9bf1001160258w476be063s595568afef088f42@mail.gmail.com> (raw)
In-Reply-To: <7v8wbyiry4.fsf@alter.siamese.dyndns.org>
On 1/16/10, Junio C Hamano <gitster@pobox.com> wrote:
> Nguyễn Thái Ngọc Duy <pclouds@gmail.com> writes:
>
> > diff --git a/builtin-rm.c b/builtin-rm.c
> > index 57975db..4cac3d1 100644
> > --- a/builtin-rm.c
> > +++ b/builtin-rm.c
> > @@ -169,7 +169,6 @@ int cmd_rm(int argc, const char **argv, const char *prefix)
> >
> > if (read_cache() < 0)
> > die("index file corrupt");
> > - refresh_cache(REFRESH_QUIET);
> >
> > pathspec = get_pathspec(prefix, argv);
> > seen = NULL;
> > @@ -181,6 +180,7 @@ int cmd_rm(int argc, const char **argv, const char *prefix)
> > struct cache_entry *ce = active_cache[i];
> > if (!match_pathspec(pathspec, ce->name, ce_namelen(ce), 0, seen))
> > continue;
> > + refresh_cache_entry(ce, 1);
>
>
> Why does this pass "1" instead of "0"? The existing code does not give
> refresh_cache() REFRESH_REALLY bit, and a patch that is marked as a pure
> optimization should pass 0. If you really mean it, please spell it as
> CE_MATCH_IGNORE_VALID and justify why it is a good change in a separate
> patch.
"refresh_cache(REFRESH_QUIET);" does pass "0" indeed. Can you please
change it to "0"? Thanks.
--
Duy
next prev parent reply other threads:[~2010-01-16 10:58 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-14 15:02 [PATCH 0/2] Improve Git performance on big trees Nguyễn Thái Ngọc Duy
2010-01-14 15:02 ` [PATCH 1/2] rm: only refresh entries that we may touch Nguyễn Thái Ngọc Duy
2010-01-16 4:39 ` Junio C Hamano
2010-01-16 10:58 ` Nguyen Thai Ngoc Duy [this message]
2010-01-14 15:02 ` [PATCH 2/2] status: only touch path we may need to check Nguyễn Thái Ngọc Duy
2010-01-14 16:02 ` Sverre Rabbelier
2010-01-16 4:41 ` Junio C Hamano
2010-01-14 15:21 ` [PATCH 0/2] Improve Git performance on big trees Martin Langhoff
2010-01-15 13:36 ` Nguyen Thai Ngoc Duy
2010-01-17 8:43 ` [PATCH] rm: only refresh entries that we may touch Nguyễn Thái Ngọc Duy
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=fcaeb9bf1001160258w476be063s595568afef088f42@mail.gmail.com \
--to=pclouds@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.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;
as well as URLs for NNTP newsgroup(s).