Port-sparc archive

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

Re: bswap is slow on SPARC



On Mon, 24 Nov 2025 21:08:31 +0000
nia <nia%NetBSD.org@localhost> wrote:

> The applications for fast byte-swaps extend way beyond this too.
> Most multimedia file formats aren't big-endian.

You are right, it is a useful optimisation to have. I was just trying
to understand why little-endian meta-data was used for encrypted swap.

Some time ago I implemented custom hashing functions and simple
xor symmetric encryption algorithms. And depending on the use case, I
omitted byte swapping, in order to keep it small and efficient.

For example, hash tables codes or disk block checksums that don't need
to be shared across different architectures, storing those in host byte
order is acceptable.


Home | Main Index | Thread Index | Old Index