All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Yoshinori K. Okuji" <okuji@enbug.org>
To: The development of GRUB 2 <grub-devel@gnu.org>
Subject: Re: Automagic command loading
Date: Fri, 1 Oct 2004 17:09:03 +0200	[thread overview]
Message-ID: <200410011709.03394.okuji@enbug.org> (raw)
In-Reply-To: <871xgjg5ll.fsf@marco.marco-g.com>

My intuition is that this is not a good solution. So I think of another 
example.

The user does not like the behavior of, say, ls. So he writes his own 
module for an exhanced version of ls. Then, which does GRUB load?

I do not like this undeterministic behavior. You may think that the user 
can simply remove the original module and add his own. This is true, 
but I don't think this is a clean way.

One more example. Suppose that GRUB supports 100 commands and 100 
filesystems. Probably the overhead of loading all modules would be 
negligible on Pentium4, but isn't it significant on 486? We should not 
forget that some people still use very old computers.

I don't see any serious disadvantage in autocmd.lst. Generating this 
file is as easy as embedding command names in modules. Editing this 
file is not difficult at all for users who can write their own modules.

Generally speaking, text-based approaches are better than binary-based 
approaches. For example, if the user wants to know what modules 
contains a given command, he can just grep autocmd.lst instead of 
reading the source code or using readelf.

BTW, I think it would be useful to investigate why loading all modules 
takes 5 seconds on bochs. Even on bochs, I feel this is too much. There 
might be a bug in the disk cache system. Tomas, could you look at the 
cache efficiency when loading all modules? You can get this information 
by the function grub_disk_cache_get_performance. To enable this 
function, you need to change kern/disk.c, because I disable this by #if 
0 ... #endif.

Okuji



  parent reply	other threads:[~2004-10-01 15:15 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-09-28 19:05 Automagic command loading Tomas Ebenlendr
2004-09-29 12:16 ` Marco Gerards
2004-09-29 22:14   ` Tomas Ebenlendr
2004-09-29 15:02 ` Yoshinori K. Okuji
2004-09-29 21:38   ` Tomas Ebenlendr
2004-09-29 22:00     ` Marco Gerards
2004-09-29 22:23       ` Tomas Ebenlendr
2004-09-30 13:33     ` Yoshinori K. Okuji
2004-09-30 15:05       ` Marco Gerards
2004-09-30 17:44         ` Tomas Ebenlendr
2004-10-01 15:09         ` Yoshinori K. Okuji [this message]
2004-10-01 15:36           ` chaac
2004-10-01 21:56           ` Tomas Ebenlendr
2004-10-06  8:43             ` Yoshinori K. Okuji

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=200410011709.03394.okuji@enbug.org \
    --to=okuji@enbug.org \
    --cc=grub-devel@gnu.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.