All of lore.kernel.org
 help / color / mirror / Atom feed
From: Rob Landley <rob@landley.net>
To: Pavel Machek <pavel@ucw.cz>
Cc: Kyle Moffett <mrmacman_g4@mac.com>,
	Roman Zippel <zippel@linux-m68k.org>,
	linux-kernel@vger.kernel.org, Sam Ravnborg <sam@ravnborg.org>
Subject: Re: [PATCH] make miniconfig (take 2)
Date: Sat, 26 Nov 2005 09:51:38 -0600	[thread overview]
Message-ID: <200511260951.39093.rob@landley.net> (raw)
In-Reply-To: <20051126141926.GB17663@elf.ucw.cz>

On Saturday 26 November 2005 08:19, Pavel Machek wrote:
> > Also, zappable lines tend to clump, so if it gets 2 zappable lines in a
> > row it could speculatively try zapping 2 at a time to see if it makes
> > faster progress.  (The down side is the extra allnoconfig runs for
> > backing up and iterating through on failures to see _which_ ones made a
> > difference.  That's not low-hanging fruit, may not be edible at all...)
>
> Can't you just filter out all the comments beforehand?

The problem is that the comments aren't all comments.  The
  # CONFIG_BLAH is not set
comments are actually like negative dentries specifying "CONFIG_BLAH=n", and 
otherwise it's unspecified which means you get the default.  (They look like 
comments, but they have meaning and yanking them can change behavior.)

This is noticeable if you feed a script through oldconfig, where everything 
that isn't specified one way or the other gets the default setting (which 
might as well be from randconfig).  But even allnoconfig has a lot of "y" 
entries in the resulting script, and some of them (like CONFIG_KALLSYMS or 
CONFIG_DEBUG_BUGVERBOSE) we may very well want to switch off.

Try this:

make allnoconfig
grep -v "^#" .config | grep -v "^$" > .config2
mv .config2 .config
make oldconfig

On the other hand, if you instead mv .config2 to allno.config and make 
allnoconfig, you get something that matches the original .config back.  And I 
haven't seen an "# blah is not set" line wind up in a miniconfig yet.

My understanding is that if you set the right symbol to open up the menu that 
a symbol you want to switch off is in, then not specifying a symbol in that 
menu leads allnoconfig to switch it off, since otherwise it would have to be 
specified.  It's only closed menus that get the defaults.  So if you 
originally created your .config through menuconfig, the "# is not set" lines 
should never be essential.  I think.  (By the way: note that the contents of 
a lot of submenus never actually get written out at all if their guard symbol 
is switched off.  Look at firewire or i2o support in 
allnoconfig's .config...)

(I spent a lot of time poking at this to make miniconfig work back under 
2.6.10.  And the busybox CONFIG_ vs ENABLE_ stuff, too...)

Then again I still haven't figured out why running the shrinker script against 
allnoconfig's config insists that CONFIG_PM=y still has to be set or the 
behavior changes.  Something I need to look at one of these days...

In any case, 99% of the time we should be able to ignore the comments and that 
lets us skip large chunks of config and should be a noticeable speedup.  A 
fallback to handle cases where the "is not set" comments change stuff may be 
sheer paranoia, but I can't be sure it's never necessary just yet...

>         Pavel

Rob
-- 
Steve Ballmer: Innovation!  Inigo Montoya: You keep using that word.
I do not think it means what you think it means.

  reply	other threads:[~2005-11-26 15:51 UTC|newest]

Thread overview: 42+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-11-17 12:29 Quick and dirty miniconfig howto, with feature suggestions Rob Landley
2005-11-20  3:08 ` Roman Zippel
2005-11-20  5:54   ` Rob Landley
2005-11-21  6:15   ` [PATCH] make miniconfig Rob Landley
2005-11-21 16:06     ` [PATCH] make miniconfig (take 2) Rob Landley
2005-11-21 17:26       ` Pavel Machek
2005-11-21 17:46         ` Rob Landley
2005-11-21 17:36       ` Pavel Machek
2005-11-21 17:50         ` Rob Landley
2005-11-21 18:28           ` Pavel Machek
2005-11-21 18:53             ` Rob Landley
2005-11-21 19:24               ` Pavel Machek
2005-11-22  5:14                 ` Rob Landley
2005-11-22 22:54                   ` Pavel Machek
2005-11-23  8:58                     ` Rob Landley
2005-11-23 13:21                       ` Pavel Machek
2005-11-24  3:19                         ` Rob Landley
2005-11-25 19:45                           ` Pavel Machek
2005-11-25 21:45                             ` Rob Landley
2005-11-25 22:09                               ` Pavel Machek
2005-11-25 22:20                                 ` Rob Landley
2005-11-26  2:34                                   ` Kyle Moffett
2005-11-26 12:25                                     ` Rob Landley
2005-11-26 14:19                                       ` Pavel Machek
2005-11-26 15:51                                         ` Rob Landley [this message]
2005-11-24  4:02                         ` Rob Landley
2005-11-25 19:46                           ` Pavel Machek
2005-11-26  1:53                             ` Andre Noll
2005-11-22  5:17                 ` Rob Landley
2005-11-24 13:56       ` Roman Zippel
2005-11-24 17:45         ` Rob Landley
2005-11-25  1:48           ` Roman Zippel
2005-11-25  8:18             ` Rob Landley
2005-11-25 15:02               ` Roman Zippel
2005-11-25 16:47                 ` Rob Landley
2005-11-25 21:12             ` Rob Landley
2005-11-27 23:20               ` Roman Zippel
2005-11-28  0:59                 ` Rob Landley
2005-11-29  1:00                   ` Roman Zippel
2005-11-29  2:26                     ` Rob Landley
2005-11-30  2:29                       ` Roman Zippel
2005-11-20  3:25 ` Quick and dirty miniconfig howto, with feature suggestions Rob Landley

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=200511260951.39093.rob@landley.net \
    --to=rob@landley.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mrmacman_g4@mac.com \
    --cc=pavel@ucw.cz \
    --cc=sam@ravnborg.org \
    --cc=zippel@linux-m68k.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.