Re: [PATCH v8 4/5] Implement line-history search (git log -L)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Junio C Hamano <gitster@xxxxxxxxx> writes:

> Junio C Hamano <gitster@xxxxxxxxx> writes:
>
>> Overall, I like this better than the "log --follow" hack; as the
>> revision traversal is done without any pathspec when being "careful
>> and slow" (aka -M), you do not suffer from the "just use a singleton
>> pathspec globally regardless of what other history paths are being
>> traversed" limitation of "log --follow".
>>
>> The patch series certainly is interesting.
>
> Having said that, I notice that "careful and slow" is just "too slow
> to be usable" even on a small tree like ours.  Try running
>
>     $ git log -M -L:get_name:builtin/describe.c
>
> and see how long you have to wait until you hit the first line of
> output.

I'll dig some more.  It *should* be essentially the following times
taken together:

  $ time git log --raw -M --topo-order >/dev/null

  real    0m5.448s
  user    0m4.599s
  sys     0m0.794s
  $ time git log -L:get_name:builtin/describe.c >/dev/null

  real    0m0.832s
  user    0m0.796s
  sys     0m0.032s

  $ time git log -L:get_name:builtin-describe.c 81b50f3ce40^ >/dev/null

  real    0m0.489s
  user    0m0.465s
  sys     0m0.022s

So I'm losing a factor of about 4 somewhere, which I can't explain right
now.

It could be improved further if --follow was fixed, because then the
first step should be much faster than diffing *all* the trees.

-- 
Thomas Rast
trast@{inf,student}.ethz.ch
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]