OCR A-Level Computer Science H446
Processors: Structure, Performance and Types
Input, Output and Storage
Systems Software
Applications Generation
Software Development
Types of Programming Language
Exchanging Data
Networks
Web Technologies
Data Types and Number Representation
Data Structures
Boolean Algebra
Legal, Moral, Cultural and Ethical Issues
Elements of Computational Thinking
Problem Solving and Programming
Algorithms
Types of Programming Language
Modes of addressing memory
- 3 things to know
- Component 01
Overview
Recall questions on immediate, direct, indirect and indexed addressing, what the operand means in each mode, working out what LDA loads under each mode, using indexed addressing for arrays, and memory accesses per mode.
What you need to know
Answer each one before you reveal it.
In direct addressing, what does the operand actually mean?
Name the four modes of addressing memory.
Questions from this subtopic
Each one with the model answer underneath.
- 1
What is an addressing mode?
Model answer
The rule that says how the operand part of an instruction should be interpreted in order to find the data the instruction is to act on. The same bit pattern in the operand field can mean the value itself, an address, an address of an address, or an offset, depending on which addressing mode the instruction specifies.
- 2
Name the four modes of addressing memory.
Model answer
Immediate, direct, indirect and indexed.
- 3
In immediate addressing, what does the operand actually mean?
Model answer
The operand is the data itself. No memory access is needed to fetch it, because the value to be used is held in the instruction, so the processor simply uses it. If the instruction is LDA with immediate addressing and the operand is 7, the accumulator is set to 7.
- 4
In direct addressing, what does the operand actually mean?
Model answer
The operand is the memory address at which the data is stored. The processor goes to that address and fetches its contents. If the instruction is LDA with direct addressing and the operand is 40, the processor reads whatever is in location 40 and puts that into the accumulator.
- 5
In indirect addressing, what does the operand actually mean?
Model answer
The operand is the address of a location that itself holds the address of the data. The processor makes two memory accesses: first it reads the location the operand names to obtain a second address, then it goes to that second address for the actual data.
- 6
In indexed addressing, what does the operand actually mean?
Model answer
The operand is a base address, to which the current contents of the index register are added to give the effective address of the data. The data is then fetched from that calculated address. Changing the index register changes which location the same instruction reaches.
Other ways to work this
The same content, four other ways.
What is inside Levo
Six ways to work the same material.
Every question in Types of Programming Language, on a schedule.
Attempt a question from memory, write the correct version, then attempt it again. Levo records the jump between your first attempt and your last, and brings each question back on the day you are due to forget it.
Or £46 a year, about £3.83 a month. Cancel anytime.