Midterm 2 Review
Tom Kelliher, CS 220
Nov. 19, 1997
The project and the remainder of the semester.
For 11/24: The SPIM paper.
Five questions:
- Addressing modes.
- Instruction set design.
- CMOS logic design.
- Arithmetic operations.
- Data structures and SAL.
- Effective address, location of operand.
- Modes: immediate, direct, register, register direct,
base-displacement, PC-relative.
In a nutshell, the RISC design philosophy: KISS, unless there's good reason
to do otherwise.
Bits and pieces:
- Pull-up, pull-down and their relationship.
- N- and p-type transistors and where they're used.
- The geometrical structure of OR and AND.
Examples:
- .
- .
- .
- (two gates).
- Signed add, subtract, multiply, divide.
- Bit-wise logical operations: NOT, OR, AND, XOR, etc.
- Rotates and logic and arithmetic shifts. Speeding up
multiplication for some constant multipliers.
Starting from
.data
stack: .word 0:128
tosPtr: .word
arg: .word
value: .word
rtnAddr: .word
.text
__start: la tosPtr, stack
mul temp, 4, 128
add tosPtr, tosPtr, temp
implement push and pop for a stack.
Thomas P. Kelliher
Tue Nov 18 11:28:33 EST 1997
Tom Kelliher