Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1NDnq5-0001f5-W9 for mharc-grub-devel@gnu.org; Thu, 26 Nov 2009 18:33:30 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NDnq4-0001dl-4f for grub-devel@gnu.org; Thu, 26 Nov 2009 18:33:28 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NDnpz-0001Yb-9U for grub-devel@gnu.org; Thu, 26 Nov 2009 18:33:27 -0500 Received: from [199.232.76.173] (port=46784 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NDnpz-0001YG-4P for grub-devel@gnu.org; Thu, 26 Nov 2009 18:33:23 -0500 Received: from 197.red-80-32-81.staticip.rima-tde.net ([80.32.81.197]:35916 helo=mail.pina.cat) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NDnpy-0002aB-Ma for grub-devel@gnu.org; Thu, 26 Nov 2009 18:33:22 -0500 Received: from pinux (82-45-164-87.cable.ubr06.hari.blueyonder.co.uk [82.45.164.87]) by mail.pina.cat (Postfix) with ESMTP id 4DC6E288F3009 for ; Fri, 27 Nov 2009 00:33:20 +0100 (CET) Received: by pinux (Postfix, from userid 1000) id D0AED8045; Thu, 26 Nov 2009 23:33:26 +0000 (GMT) Date: Thu, 26 Nov 2009 23:33:26 +0000 From: Carles Pina i Estany To: The development of GNU GRUB Message-ID: <20091126233326.GB3242@pina.cat> References: <20091125223104.GA1032@pina.cat> <20091126015335.GB32241@thorin> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20091126015335.GB32241@thorin> User-Agent: Mutt/1.5.20 (2009-06-14) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) Subject: Re: gettext: --no-hash in msgmft X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 26 Nov 2009 23:33:28 -0000 Hi, On Nov/26/2009, Robert Millan wrote: > On Wed, Nov 25, 2009 at 10:31:04PM +0000, Carles Pina i Estany wrote: > > > > Hello, > > > > I'm thinking to disable the hash table in the .mo files. It's not used > > in Grub Kernel and it makes the size 10% bigger: > > > > In a 473 sentences po file with hash it's 30633 bytes and without 28109, > > so it 's not a big difference. > > > > Do we want to disable or it's just some KB in /boot/grub and we don't > > really mind? > > > > Explanation: the .mo files has a hash table (by default) but gettext > > grub module is not using the hash table (it does search by bisection). > > > > Why? > > a) code simpler and smaller > > b) for the number of strings the speed is not a big difference* > > c) less space used in /boot/grub/locale > > Makes sense for .mo files that we use in GRUB, but what about the > system-wide .mo file, which is used by GRUB utilities? I assume > gettext takes advantage of this hash table. Jordi already answered with some ideas and others as well. Just one note: I haven't measured but I'm very sure that the speed for the user is mainly the same with and without hash. It's Grub, not OpenOffice or a big project with more strings (even thought we have more strings that I guessed) > Is it possible to strip the hash table when installing .mo files to > /boot/grub ? (Btw, our scripts don't install .mo files to /boot yet, > currently user has to do this manually) As has been said: msguunfmt, I don't see any option to strip the hash. -- Carles Pina i Estany http://pinux.info