# ISA2 - Computer Science 230H Instruction Set...

This preview shows pages 1–9. Sign up to view the full content.

1 ISA Computer Science 230H Instruction Set Architecture (ISA) Prepared by Michael Jack Fall 2007 Slides set 2

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
2 ISA References The information and figures for the following slides were prepared from the following sources: Patterson, D., and Hennessy J., Computer Organization and Design, 3rd edition, 2005 Stallings, W., Computer Organization and Architecture: Designing for Performance 7 th edition, 2006 Hircock B., Computer Science 230 Course Notes
3 ISA Endianness Byte ordering, or endianness , is another major architectural consideration (an annoying phenomenon.) How the bytes within a word and the bits within a byte are both referenced and represented? E.g. if we have a two-byte integer, the integer may be stored so that the least significant byte is followed by the most significant byte or vice versa.

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
4 ISA Endianness (cont) Big endian Stores the most significant byte of a multibyte numerical value first (in the lowest numerical address.) Little endian Stores the least significant byte of a multibyte numerical value first (in the highest numerical address.) Bi-endian Can handle both styles.
5 ISA Suppose we have the 32-bit hexadecimal value 0h12345678 that is stored in a 32-bit word in byte-addressable memory. The value consists of four bytes, with the least significant byte containing the value 78 and the most significant byte containing the value 12. The big endian and small endian arrangements of the bytes are shown below. Endianness (cont)

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
6 ISA The big endian stores the most significant byte in the lowest numerical byte address. The little endian stores the most significant byte in the highest numerical address. For a given multibyte scalar value, bug endian and little endian are byte-reversed mappings of each other. Endianness (cont)
7 ISA The concept of endianness presents a problem when: It is necessary to treat a multibyte value as a single data item with single address, even though it is composed of smaller addressable units. A programmer attempts to manipulate individual bytes or bits within a multibyte scalar. Data are transferred from a machine of one endian type to the other The property of endianness does not extend beyond an individual data unit. It does not affect the ordering of data items within a structure. Endianness (cont)

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
8 ISA Bi-endian architecture Enables programmers to choose either mode when migrating OSs and applications from other machines. The OS establishes the endian mode in which processes execute. Once a mode is selected, all subsequent memory loads and stores are determined by the memory-addressing model of that mode. Thus mode can be changed on a per-process basis. To support this hardware feature, 2 bits are maintained in the machine state register (MSR) maintained by the OS as part of the process state.
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

### What students are saying

• As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

Kiran Temple University Fox School of Business ‘17, Course Hero Intern

• I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

Dana University of Pennsylvania ‘17, Course Hero Intern

• The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

Jill Tulane University ‘16, Course Hero Intern