Post #3788833
2026-07-13 15:44 UTC
Replies (1)
-
@david_chisnall@infosec.exchange 2026-07-13 16:21
@zwol@masto.hackers.town That's more or less what Arm and PowerPC did (PowerPC made it a mode switch, since it needed to run x86 and M68k code cheaply), but it turns out that most programs don't care: unless you're serialising data (to disk or over a network), almost nothing cares what the in-memory representation of an integer is beyond its width. What they do care about is that two components (compilation units, shared libraries, whatever) in the same program agree. Pick one or the other and it's fine. So even if the ISA makes it explicit, most software won't care and will just pick whatever the default is. Things that do serialisation should provide a layer that ensures that the loaded or stored data is in the correct layout. Erlang does this well. I think Pandas lets you specify that a lazily loaded table needs byte swapping on import, but I could be wrong (the machinery is there, but maybe no one has wired it up?).