L06 - CMU 18-447 S'08 L6-1 2008 J. C. Hoe 18-447 Lecture 6:...

Info iconThis preview shows pages 1–4. Sign up to view the full content.

View Full Document Right Arrow Icon
CMU 18-447 S’08 L6-1 © 2008 J. C. Hoe 18-447 Lecture 6: MIPS ISA James C. Hoe Dept of ECE, CMU February 4, 2008 HW#1 due now Handouts: Handout04 Lab 2 Handout05 HW2 R4000 Microprocessor User’s Manual (on Blackboard) CMU 18-447 S’08 L6-2 © 2008 J. C. Hoe Instruction Set Architecture ± A stable platform, typically 15~20 years ­ guarantees binary compatibility for SW investments ­ permits adoption of foreseeable technology advances ± User-level ISA ­ program visible state and instructions available to user processes ­ single-user abstraction on top of HW/SW virtualization ± “Virtual Environment” Architecture ­ state and instructions to control virtualization (e.g., caches, sharing) ­ user-level, but not used by your average user programs ± “Operating Environment” Architecture ­ state and instructions to implement virtualization ­ privileged/protected access reserved for OS
Background image of page 1

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

View Full DocumentRight Arrow Icon
CMU 18-447 S’08 L6-3 © 2008 J. C. Hoe What are specified/decided in an ISA? ± Data format and size ­ character, binary, decimal, floating point, negatives ± “Programmer Visible State” ­ memory, registers, program counters, etc. ± Instructions: how to transform the programmer visible state? ­ what to perform and what to perform next ­ where are the operands ± Instruction-to-binary encoding ± How to interface with the outside world? ± Protection and privileged operations ± Software conventions Very often you compromise immediate optimality for future scalability and compatibility CMU 18-447 S’08 L6-4 © 2008 J. C. Hoe MIPS R2000 Program Visible State **Note** r0=0 r1 r2 General Purpose Register File 32 32-bit words named r0. ..r31 M[0] M[1] M[2] M[3] M[4] M[N-1] Memory 2 32 by 8-bit locations (4 Giga Bytes) 32-bit address (there is some magic going on) Program Counter 32-bit memory address of the current instruction
Background image of page 2
CMU 18-447 S’08 L6-5 © 2008 J. C. Hoe Data Format ± Most things are 32 bits ­ instruction and data addresses ­ signed and unsigned integers ­ just bits ± Also 16-bit word and 8-bit word (aka byte) ± Floating-point numbers ­ IEEE standard 754 ­ float: 8-bit exponent, 23-bit significand ­ double: 11-bit exponent, 52-bit significand CMU 18-447 S’08 L6-6 © 2008 J. C. Hoe Big Endian vs. Little Endian (Part I, Chapter 4, Gulliver’s Travels) ± 32-bit signed or unsigned integer comprises 4 bytes ± On a byte-addressable machine . . . . . . . Big Endian Little Endian ± What difference does it make? 8-bit 8-bit 8-bit 8-bit LSB (least significant) MSB (most significant) byte 0 byte 1 byte 2 byte 3 MSB LSB byte 4 byte 5 byte 6 byte 7 byte 8 byte 9 byte 10 byte 11 byte 12 byte 13 byte 14 byte 15 byte 16 byte 17 byte 18 byte 19 MSB LSB byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7 byte 8 byte 9 byte 10 byte 11 byte 12 byte 13 byte 14 byte 15 byte 16 byte 17 byte 18 byte 19 check out htonl(), ntohl() in in.h pointer points to the big end pointer points to the little end
Background image of page 3

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

View Full DocumentRight Arrow Icon
Image of page 4
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 15

L06 - CMU 18-447 S'08 L6-1 2008 J. C. Hoe 18-447 Lecture 6:...

This preview shows document pages 1 - 4. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online