Path: utzoo!attcan!uunet!husc6!bloom-beacon!apple!amdahl!amdcad!crackle!tim From: tim@crackle.amd.com (Tim Olson) Newsgroups: comp.arch Subject: Re: Rx000 byteorder Message-ID: <24152@amdcad.AMD.COM> Date: 22 Jan 89 23:38:43 GMT References: <76@melba.oz> Sender: news@amdcad.AMD.COM Reply-To: tim@amd.com (Tim Olson) Organization: Advanced Micro Devices, Inc. Sunnyvale CA Lines: 21 Summary: Expires: Sender: Followup-To: In article <76@melba.oz> gnb@melba.bby.oz.au writes: | With regard to DEC using the MIPS chip in little-endian mode: | | Is it reasonably simple to provide a binary translator to change | a big-endian binary to a little-endian binary? Could you then | easily recognise system calls and convert them? This is difficult unless you know the "natural sizes" of all of the data items. For example, if you want to convert data from big-endian to little-endian, you must swap bytes within half-words, and swap half-words within words, but you don't do anything to byte-sized data (strings, as well). If you have an unstripped binary with debug information, then you can derive the data sizes from it, but it is probably not possible with stripped binaries. -- Tim Olson Advanced Micro Devices (tim@crackle.amd.com)