Professional Documents
Culture Documents
Topics:
1. Instruction Codes
2. Computer Registers
3. Computer Instructions
4. Timing and Control
5. Instruction Cycle
6. Memory Reference Instructions
7. Input-Output and Interrupt
8. Complete Computer Description
1. Instruction Codes
Program: A set of instructions that specify the operations, operands, and the
sequence by which processing has to occur.
Instruction Code: A group of bits that tell the computer to perform a specific
operation (a sequence of micro-operation known as macro-operation.
It is usually divided into operation code, operand address, addressing mode, etc.
The basic addressing modes are Immediate, Direct and Indirect addressing modes.
1
Demonstration of Direct address and Indirect address:
Effective Address: The address that can be directly used without modification to
access an operand for a computation-type instruction or the target address for a
branch-type instruction is known as effective address.
2
2. Computer Registers
Registers in the Basic Computer
3
Common Bus system:
4
5
3. Computer Instructions
Basic Computer Instruction Formats:
15 12 0
14I 11
Opcode Address
ee
15 12 0
0 1 1 11 Register operation
1
15 12 0
1 1 1 11 I/O operation
1
6
Basic Computer Instructions:
7
2. Transfer Instructions - Data transfers between the main memory and the
processor registers - LDA, STA
3.Control Instructions - Program sequencing and control - BUN, BSA, ISZ
4. Input/Output Instructions- Input and output - INP, OUT
8
T0 T1 T2 T3 T4 T0
Clo ck
T0
T1
T2
T3
T4
D3
CL R
SC
9
5. Instruction cycle
10
Determine the type of instruction:
11
Register Reference Instructions:
Register reference instructions are identified when D7 = 1 and I = 0.
Register Ref. Instr. is specified in b0 ~ b11 of IR
Execution starts with timing signal T3.
12
6. Memory Reference Instructions
There are seven memory reference instructions listed in the table below.
The effective address of the instruction is in AR and was placed there during
timing signal T2 when I = 0, or during timing signal T3 when I = 1.
13
BSA: Branch and Save Return Address
M[AR] PC, PC AR + 1
14
Control Flowchart for Memory Reference Instructions:
15
7. Input-Output and Interrupt
Input-Output Configuration:
The terminal sends and receives serial information. The serial information
from the keyboard is shifted into INPR. The serial information for the printer is
stored in the OUTR. INPR and OUTR communicate with the terminal serially and
with the AC in parallel. The flags are needed to synchronize the timing difference
between I/O device and the computer.
16
Input-Output Instructions:
Input-Output Instructions are identified when D7 = 1 and I = 1.
Input-Output Instr. is specified in b6 ~ b11 of IR
Execution starts with timing signal T3.
17
Program Controlled Input/Output:
1. Continuous CPU involvement and I/O takes valuable CPU time.
2. CPU slowed down to I/O speed
3. Simple
4. Least hardware
18
Demonstration of Interrupt cycle:
19
Interrupt Cycle:
The condition for setting flip-flop R to 1 is given by the register transfer statement
The fetch and decode phases of the instruction cycle must be modified by replacing
T0, T1, T2 with R'T0, R'T1, R'T2.
20
21