From: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Andrew Morton <akpm@linux-foundation.org>,
Linux Media Mailing List <linux-media@vger.kernel.org>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [GIT PULL for v5.8-rc1] media updates
Date: Thu, 4 Jun 2020 08:13:02 +0200 [thread overview]
Message-ID: <20200604081302.1a36f358@coco.lan> (raw)
In-Reply-To: <CAHk-=wg=CTtNrxPeFzkDw053dY3urchiyxevHnUXHhTGbK=9OQ@mail.gmail.com>
Em Wed, 3 Jun 2020 21:13:21 -0700
Linus Torvalds <torvalds@linux-foundation.org> escreveu:
> On Wed, Jun 3, 2020 at 1:06 AM Mauro Carvalho Chehab
> <mchehab+huawei@kernel.org> wrote:
> >
> > PS.: The diffstat is so big that I almost dropped it, as it is almost
> > useless for humans to read. I ended by not doing it just because perhaps
> > you could be using some sort of script to check diffstat.
>
> No, but I do compare the basics, and you don't have to more than scan
> it to see that "ok, it only touches area xyz".
Ok.
> And it turns out that it is huge for you partly because you have the
> default (fairly low) git rename detection limits, in order to avoid
> using a lot of CPU or memory for rename detection.
>
> So you get:
>
> > 2181 files changed, 260633 insertions(+), 106012 deletions(-)
>
> while I get
>
> 1698 files changed, 161922 insertions(+), 7301 deletions(-)
>
> which is a noticeable difference. Still a big diffstat, but quite a
> bit smaller than yours.
>
> You also get a _lot_ more noise in the form of "create mode xyz" and
> "delete mode abc" notices, while for me a lot of them are just "rename
> abc => xyz". So there's a double whammy for you.
>
> The reason is that your diff only has renames for the 100% matches like this:
>
> > rename Documentation/{media/v4l-drivers => admin-guide/media}/au0828-cardlist.rst (100%)
>
> which git can detect purely by seeing "oh, same exact SHA1".
>
> But you don't have any non-100% renames.
>
> In contrast, the diffstat I see also has the inexact renames like
>
> rename Documentation/{media/v4l-drivers =>
> admin-guide/media}/bttv-cardlist.rst (99%)
> rename Documentation/{media/v4l-drivers => admin-guide/media}/bttv.rst (79%)
>
> because I have done
>
> git config diff.renamelimit 0
>
> to make the rename detection limit be infinite (alternatively, just
> edit your ~/.gitconfig file manually - it's often easier than
> remembering what the "git config" syntax is).
>
> You want to see
>
> [diff]
> renamelimit = 0
>
> in your ~/.gitconfig file (or, alternatively, if you want the setting
> to be per-repo, in your .git/config file in your repository).
>
> The default git limits for "should I spend CPU time and memory on
> detecting inexact renames" are fairly low, because people use git on
> fairly low-end machines.
I'm using renamelimit = 0 on one of my trees (the one I'm using for
the ReST conversion), and I even use -M1 there when sending patches
to docs (as some of the conversions require lots of indentation
changes, for example, on files with lots of ascii artwork), but on
my merge tree, I was using some limit, as it is not common to have
this huge amount of changes.
> I bet your development machine isn't some kind of low-end toy, and
> rename detection is not _that_ expensive.
Probably not as nice as yours, but it is a comfortable machine,
with 32 GB RAM, an i7-8705G CPU and a fast SSD disk.
Changing it to unlimited limit costed almost nothing here:
real 0m1,210s
user 0m1,009s
sys 0m0,190s
I'll use this from now on. Thanks for the tip!
Thanks,
Mauro
next prev parent reply other threads:[~2020-06-04 6:13 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-03 8:05 [GIT PULL for v5.8-rc1] media updates Mauro Carvalho Chehab
2020-06-04 4:13 ` Linus Torvalds
2020-06-04 6:13 ` Mauro Carvalho Chehab [this message]
2020-06-04 4:21 ` Linus Torvalds
2020-06-04 6:20 ` Mauro Carvalho Chehab
2020-06-04 4:35 ` pr-tracker-bot
-- strict thread matches above, loose matches on Subject: below --
2020-06-12 23:26 Mauro Carvalho Chehab
2020-06-13 20:25 ` pr-tracker-bot
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=20200604081302.1a36f358@coco.lan \
--to=mchehab+huawei@kernel.org \
--cc=akpm@linux-foundation.org \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=torvalds@linux-foundation.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.