Next: Implementation
Up: CS1011 lecture: Instruction Execution
Previous: CS1011 lecture: Instruction Execution
The part of the design visible to the user.
The architecture of MU0 consists of:
- Memory: locations 0, 1, 2, etc., each of 16 bits, so each can contain
216 different values, which we normally take to mean numbers in the range
-215 to 215-1
- Registers: ACC and PC. As the ACC contains values from memory, it
is also 16-bit.
- Instruction set:
- LDA
- copy contents of operand-location to ACC
- STO
- copy contents of ACC to operand-location
- ADD
- add contents of operand-location to ACC
- SUB
- subtract contents of operand-location from ACC
- JMP
- copy operand-location (not contents) to PC
- JGE
- JMP if the ACC is
0
- JNE
- JMP if the ACC is
0
- STP
- stop program
Each memory location can contain an instruction, so they are also 16-bit.
Instructions consist of a 4-bit action (allowing 24=16 different actions,
of which 8 are currently unused) and a 12-bit operand-location (allowing
212 different memory locations i.e. 0 to 4095).
As the PC holds locations of instructions in memory, it is also 12-bit.
See figure 1.
Figure 1:
The basic MU0 architecture, with the visible registers ACC & PC
|
Next: Implementation
Up: CS1011 lecture: Instruction Execution
Previous: CS1011 lecture: Instruction Execution
Pete Jinks
1998-10-30