Re: [PATCH] Endianness-aware mkcramfs

H. Peter Anvin (hpa@zytor.com)
Tue, 04 Dec 2001 17:12:40 -0800


Jeremy Puhlman wrote:

> On Tue, Dec 04, 2001 at 04:49:41PM -0800, Matthew Dharm wrote:
>
>>There is another argument for supporting both endiannesses....
>>
>>Consider an embedded system which can be run in either endianness. Sounds
>>silly? MIPS processors can run big or little endian, and many people
>>routinely switch between them.
>>
> Yes but typically this also includes a step of reflashing firmware or
> swaping of firmware...So it would not be unrealistic to swap out the
> filesystem as well...
>
> Since in a deployment situation you will always be sticking with one endianness
> it makes sense that you would want the most speed for your buck...Since flash
> filesystems are slow to begin with also adding in the decompression
> hit you get from cramfs...it would seem to me that adding in le<->be
> would just add to its speed reduction....That would seem to be a good
> place to trim the fat so to speak...
>

Actually, you've got it completely backwards. Because the compression
system used (deflate) is endian-independent, the only thing in cramfs that
is endian-sensitive is the metadata. Byteswapping the metadata is
probably not a measurable performance effect.

-hpa

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/