addressing modes Flashcards

1
Q

opcode consists of

A

binary digits representing basic operation eg ADD/LOAD and 2 digit code/bit pattern representing addressing mode

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

immediate addressing

A

operand is the actual value to be operated on (eg LDA #5)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

direct addressing

A

operand holds the memory address of the value to be operated on, data hardcoded into instruction (only addressing mode used in LMC assembly language) (eg LDA 5)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

indirect addressing

A

operand is the location (typically register) which holds address of data we want. (eg LDA (5)) starting address stored in block of memory ie index table

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

uses of indirect addressing

A

Enables a larger range of addressable locations and allows calling routine whose starting point may move eg if x = 1009. store 1009 at 4000 and go via BRA 4000. if routine moves from 1009, only change contents of 4000

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

indexed addressing

A

address of the operand is obtained by adding a constant value/address to the contents of a general register aka INDEX REGISTER. constant val and the number of the index register are in the instruction code

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

index addressing use

A

to access an array whose elements in successive memory locations
useful for a table of routine start addresses

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

immediate addressing adv and uses

A
  • uses no memory, so fastest

- used when using a constant rather than variable

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

direct addressing adv, disadv and uses

A

-fast (not as fast as immediate)
BUT -code depends on correct data always being present
uses: computers only running single program eg engine management computer so good for quick access too

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

indirect addressing uses

A

if loader loads software libraries in different memory location each time when program is loaded

How well did you know this?
1
Not at all
2
3
4
5
Perfectly