Carry uninteresting flags back through already processed parents
commit155808178ee80aaadfeb3d982d931e5b2e3ed307
authorShawn O. Pearce <spearce@spearce.org>
Tue, 25 Mar 2008 07:28:50 +0000 (25 03:28 -0400)
committerShawn O. Pearce <spearce@spearce.org>
Mon, 7 Apr 2008 05:06:16 +0000 (7 01:06 -0400)
tree3ad2c8d5a814ccae4e6d9b89f1b2b3bbe6506743
parent8b867434356b1805cd080eed104b488aed4a67fb
Carry uninteresting flags back through already processed parents

If an interesting branch has had a chance to visit through the
parent commits that are behind the merge base of the interesting
branch and the uninteresting branch we won't get UNINTERESTING
carried into those commits, but they have already been produced
as output from the pending generator.

We carry the flags back through the parents for any branch we have
already SEEN (pushed into the pending queue), thus making sure the
UNINTERESTING flag goes back as far as we can get with our current
parsed parent lists.  Since single commit chains are very common
(the so called strand-of-pearls) we try to perform a tail recursion
on the first parent and only use stack recusion when we need to
walk down the other side branches of a merge.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
org.spearce.jgit/src/org/spearce/jgit/revwalk/AbstractPendingGenerator.java