Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1KANmA-00009a-BW for mharc-grub-devel@gnu.org; Sun, 22 Jun 2008 07:30:30 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KANm7-00008Y-Dx for grub-devel@gnu.org; Sun, 22 Jun 2008 07:30:27 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KANm5-00008G-O3 for grub-devel@gnu.org; Sun, 22 Jun 2008 07:30:26 -0400 Received: from [199.232.76.173] (port=48649 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KANm5-00008C-Kc for grub-devel@gnu.org; Sun, 22 Jun 2008 07:30:25 -0400 Received: from mta21.charter.net ([216.33.127.81]:45794) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1KANm5-0004yS-4P for grub-devel@gnu.org; Sun, 22 Jun 2008 07:30:25 -0400 Received: from aarprv04.charter.net ([10.20.200.74]) by mta21.charter.net (InterMail vM.7.08.03.00 201-2186-126-20070710) with ESMTP id <20080622113021.SBBM23078.mta21.charter.net@aarprv04.charter.net> for ; Sun, 22 Jun 2008 07:30:21 -0400 Received: from [192.168.0.102] (really [71.10.234.12]) by aarprv04.charter.net with ESMTP id <20080622113021.LID4495.aarprv04.charter.net@[192.168.0.102]> for ; Sun, 22 Jun 2008 07:30:21 -0400 Message-ID: <485E37BF.9040401@isaac.cedarswampstudios.org> Date: Sun, 22 Jun 2008 07:30:07 -0400 From: Isaac Dupree User-Agent: Thunderbird 2.0.0.14 (X11/20080505) MIME-Version: 1.0 To: The development of GRUB 2 References: <20080619133147.GA5018@thorin> <485AA89A.5030404@isaac.cedarswampstudios.org> <20080621141907.GC24465@thorin> <1214058907.10018.39.camel@localhost> In-Reply-To: <1214058907.10018.39.camel@localhost> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Chzlrs: 0 X-detected-kernel: by monty-python.gnu.org: Solaris 10 (1203?) Subject: Re: [PATCH] add a counter in grub_dprintf X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GRUB 2 List-Id: The development of GRUB 2 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 22 Jun 2008 11:30:28 -0000 Javier Martín wrote: > El sáb, 21-06-2008 a las 16:19 +0200, Robert Millan escribió: >> But space in post-mbr area is precious, and if we can save a bit, it means >> less users who will run into trouble in first place. >> > > Disclaimer: the following is just the product of brainstorming from a > mind tortured by hours of studying projective geometry. Use with care ^^ > > Why not modify the build system to create _two_ instances of kernel.img, > one with and another without debugging? grub_mkimage would create the > normal, smaller core.img (without dprintf) for installing and embedding; > and store a core_dbg.img in the /boot/grub folder, so that if > instrumentation is required the only thing the users needs to do is > chain that debug version of GRUB: > > grub> multiboot /boot/grub/core_dbg.img > grub> boot or even to install it if necessary (if it fits! But multiboot, if it works, could help *some* of the time too). I think that prebuilt debug image is important, otherwise when users rebuild a debug version it's much more likely to be built differently somehow from the corresponding non-debug version (especially if it originally came through a packaging system such as Debian). Robert Millan wrote: > OTOH, it could add maintainance burden for us when we have to explain > everyone that they have to rebuild and reinstall GRUB to get the debug > output _and_ it opens the door for heisenbugs. > > But space in post-mbr area is precious, and if we can save a bit, it means > less users who will run into trouble in first place. the possibility for heisenbugs does seem very real given the diversity of hardware out there. Would it mitigate this to only disable the dprintfs (by default) in space-critical images such as x86 pc? (or would it make things worse...) -Isaac