??? 06/04/04 16:06 Read: times |
#71780 - RE: Compiler-dependence Responding to: ???'s previous message |
Dennis Welbourn said:
I second Wolfgang's note that endianess is compiler dependent. What he actually said was, "The byte order for 8052 processors depends on the used compiler." (my emphasis) Because the 8051 is an 8-bit processor, it knows nothing about multi-byte data at all[1] - therefore the compiler is completely at liberty to do whatever it likes. This is not the case, however, with >8-bit processors: in this case, the processor hardware defines the order in which it expects the individual bytes of its 16-bit, 32-bit, or whatever-size words - and the compiler must abide by this. [1] Apart from the odd 16-bit SFR, like the DPTR... |