home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #1 / NN_1993_1.iso / spool / comp / arch / 12160 < prev    next >
Encoding:
Text File  |  1993-01-08  |  2.3 KB  |  47 lines

  1. Newsgroups: comp.arch
  2. Path: sparky!uunet!usc!sdd.hp.com!ux1.cso.uiuc.edu!news.iastate.edu!help.cc.iastate.edu!willmore
  3. From: willmore@iastate.edu (David Willmore)
  4. Subject: Re: A theory for Big & Little Endian's origin
  5. Message-ID: <willmore.726511292@help.cc.iastate.edu>
  6. Sender: news@news.iastate.edu (USENET News System)
  7. Organization: Iowa State University, Ames IA
  8. References: <1iig7aINNtc@spim.mti.sgi.com> <1993Jan8.120225.8330@infodev.cam.ac.uk>
  9. Date: Fri, 8 Jan 1993 16:41:32 GMT
  10. Lines: 35
  11.  
  12. From the understanding that I have, (nice open statment) here is
  13. how I see the two alignments having come about.
  14.  
  15. To store a byte, there are no choices, 8 bits arranged any way
  16. at one location is a byte.  With 16 bits there are two choices.
  17. You can store the most signifigant byte first or the least.
  18. The intuitive way would be to put the biggest byte at the labeled
  19. address, for example, 0 and the least signifigant byte at address
  20. 1.  This would be read from address 0 as high byte low byte--just
  21. as it should sound.
  22.  
  23. The other way fixes the load problem.  Say you want to read an 8
  24. bit value starting at address 0.  The first byte read goes in the
  25. low order part of the register, the rest is cleared.  To load a
  26. 16 bit value, address 0 is placed in the low byte of the register
  27. and the next byte at address 1 is placed in the next higher byte
  28. of the register.  That way, a 32 bit or more number can be at a
  29. fixed location and you can optionally load 8 bits, 16 bits, or the
  30. full 32 bits without having to adjust your address register.
  31.  
  32. The only reason to have used one over the other, as I see it, is
  33. by how far you were looking ahead.  The x86 family came about
  34. bit by bit (sorry about that pun) and get backed into a corner
  35. because they didn't think ahead.  The 68k family was designed 
  36. from scratch and these load issues were solved before they 
  37. committed themselves to a particular format.
  38.  
  39. This is a very common theme in computer archetecture.  If you don't 
  40. look ahead and plan for it, you can get backed into some nasty
  41. corners.
  42.  
  43. ---------------------------------------------------------------------------
  44. willmore@iastate.edu | "Death before dishonor" | "Better dead than greek" | 
  45. David Willmore  | "Ever noticed how much they look like orchids? Lovely!" | 
  46. ---------------------------------------------------------------------------
  47.