Byte addressing

Byte addressing refers to hardware architectures which support accessing individual bytes of data rather than only larger units called words, which would be word-addressable. Such computers are sometimes called byte machines[1] (in contrast to word machines).[2]

The basic unit of digital storage is called a bit, storing a single 0 or 1.

Many common architectures can address more than 8 bits of data at a time. For example, the Intel 386SX processor can handle 16-bit (two-byte) data, since data is transferred over a 16-bit bus. However, data in memory may be of various lengths.

A 64-bit architecture machine might still need to access 8-bit data over its 64-bit address line, and have the data returned in the bottom 8 bits of its longer data line.

Byte addressable memory refers to architectures where data can be accessed and addressed in units that are narrower than the bus. An eight-bit processor like the Intel 8008 addresses eight bits, but as this is the full width of the bus, this is regarded as word-addressable. The 386SX, which addresses memory in 8-bit units but can fetch and store it 16 bits at a time, is termed byte-addressable.

Bytes have not always meant 8 bits; in fact, depending on the platform, byte sizes of 1[3] to 48 bits[4] have been used in the past. Therefore, the term octet is used where the context makes byte-length ambiguous.

For example, in the 1980s, Honeywell mainframes had 36-bit words, and were byte-addressable in 9-bit bytes, or "nonets", They used 7- or 8-bit character codes, either of which were stored one to each 9-bit byte, making characters individually addressable.

To illustrate why byte addressing is useful, consider the IBM 7094, which is word-addressable and has no concept of a byte. It has 36-bit words, and stores its six-bit character codes six to a word.

To change the 16th character in a string, the program has to determine that this is the fourth character of the third word in the string, fetch the third word, mask out the old value of the fourth character from the value held in the register, "or" in the new one, and then store back the amended word. At least six machine instructions. Usually these are relegated to a subroutine, so every store or fetch of a single character involves the overhead of calling a subroutine and returning.

With byte addressing, that can be achieved in one instruction: store this character code at that byte address. Text programs are easier to write, smaller, and run faster.

The advantage of word addressing is that more memory can be addressed in the same number of bits. The IBM 7094 has 15-bit addresses, so could address 32,768 words of 36 bits. The machines were often built with a full complement of addressable memory. Addressing 32,768 bytes of 6 bits would have been much less useful for scientific and engineering users.

Or consider the 32-bit Pentium processor. Its 32-bit address bus can address 4 billion different items. Using word addressing, a 32-bit address bus could address 4 Gigawords; or 16 Gigabytes using the modern 8-bit byte. If the 386SX and its successors had used word addressing, scientists, engineers, and gamers could all have enjoyed programs that were 4x larger on 32-bit machines.

Then again, word processing, rendering HTML, and all other text applications would have run more slowly.

When computers were so costly that they were only or mainly used for science and engineering, word addressing was the obvious mode. As it became cost-effective to use computers for handling text, hardware designers moved to byte addressing.

Some systems, such as the PDP-10, use word addressing but facilitate access to individual bytes using special instructions which can access memory using a byte pointer, which contains both a word address and the index of a specific byte within the word.

See also

References

  1. Hansen, H. R. (1986). Wirtschaftsinformatik (in German). I (5 ed.). Stuttgart, Germany: Gustav Fischer. p. 125.
  2. "Wortmaschine" (in German). Archived from the original on 2017-04-09. Retrieved 2017-04-09.
  3. Buchholz, Werner (February 1977). "The Word "Byte" Comes of Age..." Byte Magazine. 2 (2): 144. […] The first reference found in the files was contained in an internal memo written in June 1956 during the early days of developing Stretch. A byte was described as consisting of any number of parallel bits from one to six. Thus a byte was assumed to have a length appropriate for the occasion. Its first use was in the context of the input-output equipment of the 1950s, which handled six bits at a time. The possibility of going to 8 bit bytes was considered in August 1956 and incorporated in the design of Stretch shortly thereafter. The first published reference to the term occurred in 1959 in a paper "Processing Data in Bits and Pieces" by G A Blaauw, F P Brooks Jr and W Buchholz in the IRE Transactions on Electronic Computers, June 1959, page 121. The notions of that paper were elaborated in Chapter 4 of Planning a Computer System (Project Stretch), edited by W Buchholz, McGraw-Hill Book Company (1962). The rationale for coining the term was explained there on page 40 as follows:
    Byte denotes a group of bits used to encode a character, or the number of bits transmitted in parallel to and from input-output units. A term other than character is used here because a given character may be represented in different applications by more than one code, and different codes may use different numbers of bits (ie, different byte sizes). In input-output transmission the grouping of bits may be completely arbitrary and have no relation to actual characters. (The term is coined from bite, but respelled to avoid accidental mutation to bit.)
    System/360 took over many of the Stretch concepts, including the basic byte and word sizes, which are powers of 2. For economy, however, the byte size was fixed at the 8 bit maximum, and addressing at the bit level was replaced by byte addressing. […]
  4. 3600 Computer System - Reference Manual (PDF). K. St. Paul, Minnesota, USA: Control Data Corporation (CDC). 1966-10-11 [1965]. 60021300. Archived from the original (PDF) on 2017-04-05. Retrieved 2017-04-05. Byte - A partition of a computer word. (NB. Discusses 12-bit, 24-bit and 48-bit bytes.)
This article is issued from Wikipedia. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.