git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Linus Torvalds <torvalds@osdl.org>
To: Junio C Hamano <junkio@cox.net>
Cc: git@vger.kernel.org
Subject: Re: Start handling references internally as a sorted in-memory list
Date: Mon, 11 Sep 2006 18:05:09 -0700 (PDT)	[thread overview]
Message-ID: <Pine.LNX.4.64.0609111800590.27779@g5.osdl.org> (raw)
In-Reply-To: <7vsliyez2m.fsf@assigned-by-dhcp.cox.net>



On Mon, 11 Sep 2006, Junio C Hamano wrote:
> 
> I thought what triggered the restructuring of this part was N
> actually being large enough to cause pain to some people, so I
> suspect later might need to be reasonably soon ;-).

Well, the current problems is actually related to the _IO_ load of O(n) 
(and to some degree the disk usage), and that is indeed fairly high. The 
new O(n**2) is all for a (very) simple CPU loop, so I suspect "n" has to 
be in the millions before it even approaches the IO load problem ;)

> I've been wondering what happens if you pack "refs/heads/foo",
> delete it, and create "refs/heads/foo/bar" with your proposal.
> I'll find the answer (which is _not_ "42") in the updated
> do_for_each_ref(), I guess.

Right now, the code in question only contains some preliminary support for 
refs at all, and it's technically incorrect. If you ever have a 
"packed-refs" file that contains _anything_ outside of the actual loose 
refs, it won't do the right thing.

But I'd rather have this as a base, than send one huge patch that does 
everything.

For example, right now the code doesn't support negative refs (even the 
simple kind) at all, so you don't need to even have the "file turned into 
a directory" case for it to "not work".

So right now it's basically just scaffolding. It's hopefully _good_ 
scaffolding, so that when I send the next few patches, it actually starts 
working.. ;)

		Linus

  reply	other threads:[~2006-09-12  1:05 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-09-11 19:03 Allow multiple "git_path()" uses Linus Torvalds
2006-09-11 23:37 ` Start handling references internally as a sorted in-memory list Linus Torvalds
2006-09-11 23:50   ` Linus Torvalds
2006-09-11 23:57   ` Junio C Hamano
2006-09-12  1:05     ` Linus Torvalds [this message]
2006-09-12  1:09   ` Chris Wedgwood
2006-09-12  3:10   ` Add support for negative refs Linus Torvalds
2006-09-12  3:17     ` Make ref resolution saner Linus Torvalds
2006-09-12  5:36       ` Jeff King
2006-09-12 14:41         ` Linus Torvalds
2006-09-18  7:25   ` [RFC] git-pack-refs --prune Junio C Hamano
2006-09-18 16:47     ` Linus Torvalds
2006-09-18 18:44       ` Junio C Hamano
2006-09-21  7:02       ` Junio C Hamano
2006-09-21  7:06         ` [PATCH 1/5] symbolit-ref: fix resolve_ref conversion Junio C Hamano
2006-09-21  7:06         ` [PATCH 2/5] Add callback data to for_each_ref() family Junio C Hamano
2006-09-21  7:06         ` [PATCH 3/5] Tell between packed, unpacked and symbolic refs Junio C Hamano
2006-09-21  7:06         ` [PATCH 4/5] pack-refs: do not pack " Junio C Hamano
2006-09-21  7:06         ` [PATCH 5/5] git-pack-refs --prune Junio C Hamano
2006-09-21 15:19         ` [RFC] " Linus Torvalds
2006-09-22  4:57           ` 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=Pine.LNX.4.64.0609111800590.27779@g5.osdl.org \
    --to=torvalds@osdl.org \
    --cc=git@vger.kernel.org \
    --cc=junkio@cox.net \
    /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).