Advertisement.

EnchantedLearning.com is a user-supported site.
As a bonus, site members have access to a banner-ad-free version of the site, with print-friendly pages.
Click here to learn more.

ad
(Already a member? Click here.)


Memory in SPARC Machines

For more, see: SPARC at Enchanted Learning

SPARC, like all modern computers, is based on the von Neumann architecture, which has an addressable memory in which both instructions and data are stored.

It is rare for a program to need access to an individual bit in memory all by itself; instead, programs usually require access to some number of bits stored consecutively in memory. So there are significant cost and speed advantages to designing an architecture which:

The SPARC architecture groups data bits in the following ways:

Each location in memory holds one byte (8 bits) of data; each location is identified by its own unique address (a 32-bit unsigned integer).

You can also use an address to refer to one of the larger units of memory (halfword, word, or double word). In this case, the address refers to the first byte of the 2, 4, or 8 consecutive bytes involved. For the sake of efficiency, the SPARC architecture requires that you make sure that all memory references are aligned; in other words, a halfword must start at an even memory address, a word must start at an address which is a multiple of 4, and a double word must start at an address which is a multiple of 8.

SPARC is a big-endian architecture. This means that multi-byte quantities (halfword, word, or double word) are stored with their most significant byte first (in the lowest address) and their least significant byte last (in the highest address). For example, if you stored the number 256 (binary 100000000) as a word at location 500, you would find the byte 1 stored at location 500, and the byte 0 stored at location 501.

Little-endian architectures store multi-byte quantities in the opposite order, with the least significant byte first. It doesn't really matter which method is used, but you do need to be aware of the order in a few situations (whether programming in assembly language or in a high-level language):

Of the common microprocessors, the Motorola 680x0 series has a big-endian architecture, like SPARC. Intel microprocessors are little-endian. PowerPC processors can be configured either way; the most common machines using them are big-endian.

The terms big-endian and little-endian come from Jonathan Swift's Gulliver's Travels, in which politicians argued and nations made war over which side of an egg should be cracked open.


Copyright 1998-1999 Enchanted Learning Software.



Enchanted Learning Search

Search the Enchanted Learning website for:



Advertisement.



Advertisement.



Advertisement.