Motorola M68000 User's Guide Page 36

  • Download
  • Add to my manuals
  • Print
  • Page
    / 256
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 35
22 Assembly Language Programming for the 68000 Family
mer from having to worry about the exact representation of instructions
and data in memory. However, a programmer usually finds the occasion
when such knowledge is useful.
Recall that memory consists of an array of individually addressable
bytes. If the data we wish to store in memory is only a single byte, there
is no question as to how it is represented, only where. If, however, the
data is a word or instruction consisting of more than one byte, it is not
clear how this information is stored. Word data (16 bits) are always stored
with the high-order byte stored in the lower memory address. This means
that if we were reading a dump of memory, word data would be read
directly. Many microprocessors have this order reversed, making it much
harder to interpret the contents of memory. Figure 4 shows how byte,
word and longword values are stored.
Instructions consist of one or more words. The first word always con
tains the operation code, or opcode. This specifies what the particular
Integer Data
1 Byte -8 Bits
IS 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
MSB Bvt®0 LSB
Byte 1
Byte 2 Byte 3
1 Word-16 Bits
IS 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
MSB
WordO
LSB
Word 1
Word 2
Even Bytes I Odd Bytes
7 6 5 4 3 2 1 0 | 7 6 5 4 3 2 1 0
1 Long Word*32 Bits
15 14 13 12 11 10 9376543210
MSB
Long Word 0
---------
High Order
Low Order
LSB
Long Word 1
---------------
Long Word 2 —
---------
Figure 4 Bytes, words, and longwords memoiy. (Courtesy of Motorola, Inc.)
Page view 35
1 2 ... 31 32 33 34 35 36 37 38 39 40 41 ... 255 256

Comments to this Manuals

No comments