git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: David Brownell <david-b@pacbell.net>
To: Daniel Barkalow <barkalow@iabervon.org>
Cc: git@vger.kernel.org
Subject: Re: warning: no common commits - slow pull
Date: Mon, 10 Mar 2008 09:18:09 -0800	[thread overview]
Message-ID: <200803101018.09282.david-b@pacbell.net> (raw)
In-Reply-To: <alpine.LNX.1.00.0803091443440.19665@iabervon.org>

On Sunday 09 March 2008, Daniel Barkalow wrote:
> Try this. I'm not at all sure that it's doing what I want, but it passes 
> all the current tests, and it should only affect your test case if it's 
> actually right.

Seems to resolve that problem for me ... well timed, in terms of RC5!

But some stuff still looks a bit fishy.  See this RC4 --> RC5 pull:

  remote: Counting objects: 1329, done.
  remote: Compressing objects: 100% (276/276), done.
  remote: Total 908 (delta 749), reused 760 (delta 631)
  Receiving objects: 100% (908/908), 146.35 KiB | 40 KiB/s, done.
  Resolving deltas: 100% (749/749), completed with 287 local objects.
  remote: Counting objects: 1330, done.
  remote: Compressing objects: 100% (277/277), done.
  remote: Total 909 (delta 749), reused 760 (delta 631)
  Receiving objects: 100% (909/909), 146.63 KiB | 38 KiB/s, done.
  Resolving deltas: 100% (749/749), completed with 287 local objects.
  From git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
   * [new tag]         v2.6.25-rc5 -> v2.6.25-rc5
  Updating 29e8c3c..cdeeeae
  Fast forward
  Auto packing your repository for optimum performance. You may also
  run "git gc" manually. See "git help gc" for more information.
  ...

That's pretty typical:  two count/compress/receive/resolve passes,
with almost an identical shape and size.  Every time I see that, I
suspect that most of the second one should not be needed...

However, the grace of not re-fetching the entire GIT database (at
several hundred MBytes) the second time is much appreciated!

- Dave


> --- a/builtin-fetch-pack.c
> +++ b/builtin-fetch-pack.c
> @@ -26,6 +26,8 @@ static const char fetch_pack_usage[] =
>  #define SEEN		(1U << 3)
>  #define POPPED		(1U << 4)
>  
> +static int marked;
> +
>  /*
>   * After sending this many "have"s if we do not get any new ACK , we
>   * give up traversing our history.
> @@ -61,6 +63,16 @@ static int rev_list_insert_ref(const char *path, const unsigned char *sha1, int
>  	return 0;
>  }
>  
> +static int clear_marks(const char *path, const unsigned char *sha1, int flag, void *cb_data)
> +{
> +	struct object *o = deref_tag(parse_object(sha1), path, 0);
> +
> +	if (o && o->type == OBJ_COMMIT)
> +		clear_commit_marks((struct commit *)o, 
> +				   COMMON | COMMON_REF | SEEN | POPPED);
> +	return 0;
> +}
> +
>  /*
>     This function marks a rev and its ancestors as common.
>     In some cases, it is desirable to mark only the ancestors (for example
> @@ -153,6 +165,10 @@ static int find_common(int fd[2], unsigned char *result_sha1,
>  	unsigned in_vain = 0;
>  	int got_continue = 0;
>  
> +	if (marked)
> +		for_each_ref(clear_marks, NULL);
> +	marked = 1;
> +
>  	for_each_ref(rev_list_insert_ref, NULL);
>  
>  	fetching = 0;
> 

  reply	other threads:[~2008-03-10 17:18 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-07  1:35 warning: no common commits - slow pull David Brownell
2008-03-08  1:22 ` Daniel Barkalow
2008-03-08 22:48   ` David Brownell
2008-03-08 22:58     ` Daniel Barkalow
2008-03-08 23:25       ` David Brownell
2008-03-08 23:27         ` Daniel Barkalow
2008-03-09 18:47           ` Daniel Barkalow
2008-03-10 17:18             ` David Brownell [this message]
2008-03-10 17:40               ` Daniel Barkalow
  -- strict thread matches above, loose matches on Subject: below --
2008-02-11  1:07 Len Brown
2008-02-11  1:44 ` Junio C Hamano
2008-02-17  3:52   ` Daniel Barkalow
2008-02-17 14:57     ` Johannes Schindelin
2008-02-17 17:46       ` Daniel Barkalow
2008-02-17 17:54       ` Junio C Hamano
2008-02-17 19:27         ` Johannes Schindelin
2008-02-17 20:41           ` Daniel Barkalow
2008-02-11  1:53 ` Theodore Tso
2008-02-11  2:39   ` Len Brown
2008-02-11  2:49   ` Junio C Hamano
2008-02-11  3:55     ` Theodore Tso
2008-02-15 21:43       ` Len Brown
2008-02-16 21:22         ` Johannes Schindelin
2008-02-25 21:59         ` Florian Weimer
2008-02-25 23:32           ` Daniel Barkalow
2008-02-26 19:38         ` Len Brown
2008-02-26 20:47           ` Nicolas Pitre
2008-02-26 23:45           ` Daniel Barkalow
2008-02-27  5:12           ` Junio C Hamano
2008-02-27  6:29             ` Junio C Hamano
2008-02-27 19:28               ` Daniel Barkalow
2008-02-27 20:53                 ` Junio C Hamano
2008-02-27 21:26                   ` Daniel Barkalow
2008-02-28  0:43                     ` Shawn O. Pearce
2008-02-28  8:50                       ` Shawn O. Pearce
2008-02-29 14:44                         ` Jon Loeliger
2008-02-29 17:14                           ` Daniel Barkalow
2008-02-28  0:47                     ` Junio C Hamano
2008-02-28 15:53                       ` Daniel Barkalow
2008-02-28 17:52                         ` Junio C Hamano
2008-02-28 18:36                           ` Daniel Barkalow
2008-02-11 15:54 ` Florian Weimer
2008-02-11 21:13   ` Nix

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

  List information: http://vger.kernel.org/majordomo-info.html

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

  git send-email \
    --in-reply-to=200803101018.09282.david-b@pacbell.net \
    --to=david-b@pacbell.net \
    --cc=barkalow@iabervon.org \
    --cc=git@vger.kernel.org \
    /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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).