linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Linus Torvalds <torvalds@linux-foundation.org>
To: Greg KH <gregkh@linuxfoundation.org>,
	"Joel Fernandes (Google)" <joel@joelfernandes.org>,
	Masahiro Yamada <yamada.masahiro@socionext.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	Linux List Kernel Mailing <linux-kernel@vger.kernel.org>
Subject: Re: [GIT PULL] Driver core patches for 5.2-rc1
Date: Thu, 9 May 2019 13:47:54 -0700	[thread overview]
Message-ID: <CAHk-=wh=Uscp=yO1p===JjH3x9NS-ez+wrk64Z0pw7EGfWvVTA@mail.gmail.com> (raw)
In-Reply-To: <20190507175912.GA11709@kroah.com>

[ Ok, this may look irrelevant to people, but I actually notice this
because I do quick rebuilds *all* the time, so the 30s vs 41s
difference is actually something I reacted to and then tried to figure
out... ]

On Tue, May 7, 2019 at 10:59 AM Greg KH <gregkh@linuxfoundation.org> wrote:
>
> Joel Fernandes (Google) (2):
>       Provide in-kernel headers to make extending kernel easier

Joel and Masahiro,
 this commit does annoying things. It's a small thing, but it ends up
grating on my kernel rebuild times, so I hope somebody can take a look
at it..

Try building a kernel with no changes, and it shouldn't re-link.

HOWEVER.

If you re-make the config in between, the kernel/kheaders_data.tar.xz
is re-generated too. I think it checks timestamps despite having that
"CHK" phase that should verify just contents.

I think the kernel/config_data.gz rules do the same thing, judging by
the output.

I use "make allmodconfig" to re-generate the same kernel config, which
triggers this. The difference between "nothing changed" and "rerun
'make allmodconfig' and nothing _still_ should have changed" is quite
stark:

- nothing changed: rebuild in less than 30s

    [torvalds@i7 linux]$ time make -j32
      DESCEND  objtool
      CALL    scripts/atomic/check-atomics.sh
      CALL    scripts/checksyscalls.sh
      CHK     include/generated/compile.h
      CHK     kernel/kheaders_data.tar.xz
      Building modules, stage 2.
    Kernel: arch/x86/boot/bzImage is ready  (#9)
      MODPOST 7282 modules

    real        0m29.379s
    user        1m50.586s
    sys 0m41.047s

- do (the same) "make allmodconfig" in between, now rebuild time is
just over 41s:

    [torvalds@i7 linux]$ make allmodconfig

    [torvalds@i7 linux]$ time make -j32
    scripts/kconfig/conf  --syncconfig Kconfig
      DESCEND  objtool
      CALL    scripts/atomic/check-atomics.sh
      CALL    scripts/checksyscalls.sh
      CHK     include/generated/compile.h
      GZIP    kernel/config_data.gz
      CHK     kernel/kheaders_data.tar.xz
      CC [M]  kernel/configs.o
      GEN     kernel/kheaders_data.tar.xz
      CC [M]  kernel/kheaders.o
      Building modules, stage 2.
    Kernel: arch/x86/boot/bzImage is ready  (#9)
      MODPOST 7282 modules
      LD [M]  kernel/configs.ko
      LD [M]  kernel/kheaders.ko

    real        0m41.326s
    user        2m17.822s
    sys 0m54.561s

No, this isn't the end of the world, but if somebody sees a simple
solution to avoid that extra ten seconds, I'd appreciate it.

                  Linus

  parent reply	other threads:[~2019-05-09 20:48 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-07 17:59 [GIT PULL] Driver core patches for 5.2-rc1 Greg KH
2019-05-07 20:50 ` pr-tracker-bot
2019-05-09 20:47 ` Linus Torvalds [this message]
2019-05-10  2:36   ` Joel Fernandes
2019-05-10  7:58     ` Masahiro Yamada
2019-05-10 19:04       ` Joel Fernandes
2019-05-10  6:20   ` Masahiro Yamada

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='CAHk-=wh=Uscp=yO1p===JjH3x9NS-ez+wrk64Z0pw7EGfWvVTA@mail.gmail.com' \
    --to=torvalds@linux-foundation.org \
    --cc=akpm@linux-foundation.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=joel@joelfernandes.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=yamada.masahiro@socionext.com \
    /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).