Instruction Types and Addressing Modes
Instruction Types and Addressing Modes
Next
Opcod Operand Operand Result
Instructio
e Address1 Address2 Address1
n
Instruction Set Types
C=A+B
How is this high-level language command
implemented in the computer?
Calculation of Memory
Accesses To Execute an
To fetch Instruction
itself Opcode= Instruction
Op1Addr=1
1 Op1=1
Op2Addr=1 Op2=1
ResAddr=1 Res=1
NextiAddr=1 Total=3
Total=5
PC 24
Calculation of Memory
Accesses To Execute an
To fetch Instruction
itself Opcode= Instruction
Op1Addr=1
1 Op1=1
Op2Addr=1 Op2=1
ResAddr=1 Res=1
Total=4 Total=3
PC 24
Calculation of Memory
Accesses To Execute an
To fetch Instruction
itself Opcode= Instruction
Op1Addr=1
1 Op1=1
Op2Addr=1 Op2=1
Res=1
Total=3
Total=3
PC 24
Calculation of Memory
Accesses To Execute an
To fetch Instruction
itself Opcode= Instruction
Op1Addr=1
1 Op1=1
Total=2 Total=1
Ans.
3-ADDRESSMACHINE 2-ADDRESSMACHINE 1-ADDRESSMACHINE 0-ADDRESSMACHINE
Immediate
Direct
Indirect
Register
Register Indirect
Displacement (Indexed)
Stack
Immediate Addressing
Instruction
Opcode Operand
Direct Addressing
Instruction
Opcode Address A
Memory
Operand
Indirect Addressing (1)
Opcode Address A
Memory
Pointer to operand
Operand
Indirect Addressing (2)
Instruction
Operand
Register Indirect Addressing
EA = (R)
Operand is in memory cell pointed to by
contents of register R
Large address space
One fewer memory access than indirect
addressing
Register Indirect Addressing Diagram
Instruction
Registers