[PATCH STABLE] revset: force immediate revset evaluation for roots() (issue4313)

Matt Mackall mpm at selenic.com
Fri Jul 25 12:13:32 CDT 2014


On Thu, 2014-07-24 at 22:15 -0700, Gregory Szorc wrote:
> On 7/24/14, 8:04 PM, Matt Mackall wrote:
> > On Wed, 2014-07-23 at 19:09 -0700, Gregory Szorc wrote:
> >> This is possibly a regression
> >> from dd716807fd23.
> >
> > You said the magic word to make me actually care about this during a
> > code freeze.. but then didn't take the crucial step of measuring the
> > regression.
> 
> There are some numbers in the v2 patch I sent today. I didn't explicitly 
> mention dd716807fd23's numbers in the commit though. Here are 
> dd716807fd23^, dd716807fd23, and my v2 patch for the hg repo:
> 
> revset #6: roots(0::tip)
> 0) wall 0.078206 comb 0.070000 user 0.070000 sys 0.000000 (best of 100)
> 1) wall 2.841311 comb 2.840000 user 2.840000 sys 0.000000 (best of 4)
> 2) wall 0.078800 comb 0.080000 user 0.080000 sys 0.000000 (best of 100)

Not sure how I missed that when I ran the benchmarks. Sigh.

> revset #23: roots((0:tip)::)
> 0) wall 1.246024 comb 1.250000 user 1.230000 sys 0.020000 (best of 8)
> 1) wall 218.167173 comb 218.170000 user 218.080000 sys 0.090000 (best of 3)
> 2) wall 1.229971 comb 1.230000 user 1.210000 sys 0.020000 (best of 8)

Yowtch. I was working under the assumption that baseset.__contains__
would be a cached set like lazyset, but instead it's list.__contains__.
Something to fix post-3.1.

-- 
Mathematics is the supreme nostalgia of our time.




More information about the Mercurial-devel mailing list