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 Mailing List <git@vger.kernel.org>
Subject: Re: Start handling references internally as a sorted in-memory list
Date: Mon, 11 Sep 2006 16:50:14 -0700 (PDT)	[thread overview]
Message-ID: <Pine.LNX.4.64.0609111647000.27779@g5.osdl.org> (raw)
In-Reply-To: <Pine.LNX.4.64.0609111632050.27779@g5.osdl.org>



On Mon, 11 Sep 2006, Linus Torvalds wrote:
> 
> And yeah, I know that the "sorting" code is O(n**2) thanks to doing an 
> insertion sort into a simple linked list. Tough. I didn't care enough to 
> do it well. With "n" usually being a few hundred at most, we really don't 
> care, and if we ever do, we _can_ fix it later on to use a heap or 
> something.

Btw, to expand on that - one of the nice things from this whole re-org of 
how we handle refs is that when you do

	git-rev-parse --all

it now sorts them in a reliable order - by name. Before, they came out in 
some random order that totally depended on the filesystem that the 
references were on.

Use the "--symbolic --all" to see this in a more obvious way, before and 
after.

		Linus

  reply	other threads:[~2006-09-11 23:50 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 [this message]
2006-09-11 23:57   ` Junio C Hamano
2006-09-12  1:05     ` Linus Torvalds
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.0609111647000.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).