Re: bswap is slow on SPARC
Mouse <[email protected]> Mon, 24 Nov 2025 10:01:26 -0500 (EST)
| Newsgroups | gmane.os.netbsd.ports.sparc |
|---|---|
| Message-ID | <[email protected]> |
> For most NetBSD architectures, GCC's __builtin_bswapX inserts fast > inline MD code. For SPARC, SPARC64, and VAX, it falls back to a > function call. > When encryption algorithms expect to be able to encode little-endian > integers in a tight loop, that adds up to being *slow*. Um, maybe I'm just revealing my ignorance, but wouldn't a reasonable response to this be "don't use encryption that insists on using little-endian for integers when you're on a SPARC"? (For that matter, why would encryption care about integer endianness to begin with?) Not that speeding up byte-swapping would be a bad thing, but it seems to me it isn't the only approach here. /~\ The ASCII Mouse \ / Ribbon Campaign X Against HTML [email protected] / \ Email! 7D C8 61 52 5D E7 2D 39 4E F1 31 3E E8 B3 27 4B