What breaks?

Doug Gwyn gwyn at smoke.brl.mil
Tue Jan 22 08:27:29 AEST 1991


In article <1991Jan21.130932.2982 at odin.diku.dk> thorinn at diku.dk (Lars Henrik Mathiesen) writes:
>The TCP _protocol_ defines certain fields as exactly 32 bits in a
>specific order on the wire. For any machine the network interface will
>define a mapping between bits-on-the-wire and bits-in-machine-words;
>in a 36-bit-word machine this mapping cannot be as simple as in a
>byte-addressable machine.

It should involve roughly the same amount of effort.  For example, define
the system's internal representation of packet data as an array of words
with the data contained in the low-order 32 bits of each word (also define
whether big- or little-endian).  At some point the network hardware
interface is going to have to be spoon-fed the 32 bits in some form that
it can cope with; it is easy enough to take care of the unpacking at that
point.

I've had a fair amount of experience in dealing with communication between
36-bit and 8-bit addressable architectures (DEC mainframes vs. minis);
these issues have been solved long ago, and it wasn't very difficult.



More information about the Comp.lang.c mailing list