From: Junio C Hamano <gitster@pobox.com>
To: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
Cc: git@vger.kernel.org
Subject: Re: [PATCH] git-rev-list.txt: rev stands for revision, not reverse.
Date: Fri, 02 Nov 2007 13:46:01 -0700 [thread overview]
Message-ID: <7v8x5g1ily.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <7vprys1k5m.fsf@gitster.siamese.dyndns.org> (Junio C. Hamano's message of "Fri, 02 Nov 2007 13:12:37 -0700")
Junio C Hamano <gitster@pobox.com> writes:
> Ralf Wildenhues <Ralf.Wildenhues@gmx.de> writes:
>
>> Is the reverse chronological order the primary sorting key at all?
>
> It is mostly chrono but there is a topo element as well. You
> would never see a parent none of whose child is shown.
To be precise...
Internally, it mainly works on topology with an additional logic
to tiebreak with commit timestamps.
- We always have one or more "output candidates".
- Initially, the set of output candidates are primed from the
positive refs (e.g. "foo", foo in "bar..foo", foo and bar in
"bar...foo") you give to rev-list and/or log family of
commands, after reachability analysis with negative refs
(e.g. "^foo", bar in "bar..foo", merge-base of foo and bar in
"bar...foo") if present.
- We output the latest one among output candidates. The
parents of the commit we output go through the reachability
analysis and the ones that are reachable from any of the
negative refs are removed. The ones that survive this
reachability analysis are added to the output candidates.
And the process starts over. The algorithm terminates when
there is none.
In practice, because child commits tend to get later commit
timestamps than all of their parent commits, the output looks
mostly reverse chronological.
prev parent reply other threads:[~2007-11-02 20:46 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-11-01 8:45 [PATCH] git-rev-list.txt: rev stands for revision, not reverse Ralf Wildenhues
2007-11-01 19:51 ` Junio C Hamano
2007-11-02 18:55 ` Ralf Wildenhues
2007-11-02 20:12 ` Junio C Hamano
2007-11-02 20:46 ` Junio C Hamano [this message]
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=7v8x5g1ily.fsf@gitster.siamese.dyndns.org \
--to=gitster@pobox.com \
--cc=Ralf.Wildenhues@gmx.de \
--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.
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).