grub-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Creating grub/grub2/grldr.mbr bootrom with makerom


From: Bean
Subject: Re: Creating grub/grub2/grldr.mbr bootrom with makerom
Date: Sat, 22 Dec 2007 17:03:48 +0800

On Dec 22, 2007 4:06 PM, Yoshinori K. Okuji <address@hidden> wrote:
> On Friday 21 December 2007 20:04, Robert Millan wrote:
> > How well does compression work for GRUB 2 ?  core.img is already compressed
> > (with lzo); if LZMA makes better results perhaps it'd be a good idea to
> > switch.
>
> It's not that simple. LZO was chosen instead of gzip, because of the size
> requirement on PC. To preserve safety, we need to keep the core part less
> than 31.5KB (63 sectors).
>
> The size is the sum of non-compressable bootstrap code, decompression code and
> compressed code + data. When I made an experiment in PUPA, although gzip had
> a better compression ratio, due to the decompression code size, LZO won.
>
> I don't know precisely, but I suspect that decompression code for LZMA would
> be slightly larger than gzip's (IIRC, a range coder is likely to require more
> code and data). So I don't expect that LZMA can replace the current usage of
> LZO in normal PC so easily.

The decompression code for LZMA is very small, i use -Os option to
compile LzmaDecode.c, the result is about 2.8K.

-- 
Bean




reply via email to

[Prev in Thread] Current Thread [Next in Thread]