5.3 - The Processor Instruction Set Flashcards
What is an instruction set?
Describe the commands a processor can perform
What a different toe of instruction types are there?
Data transfer: LDA, STR
Arithmetic operations: ADD, SUB
Comparison operations: CMP
Logical operations: AND, OR, NOT
Branch - conditional/unconditional
Shift operations: left/right bit shifts
What is machine code?
Only language the processor can understand
Combinations of 0’s and 1’s
What is the opcode (operation code)?
First few bits, it includes:
- the actual command the processor needs to carry out (ADD, SUB)
- the addressing mode
What is the addressing mode?
Specifies whether the operand is the actual data, the memory address where the data is held, or a register
What is the operand?
One or more items of data (values, memory addresses or registers) that are to be used in the instruction
What decides the number of bits allocated for the opcode and operand?
Varies depending on the processor
Changes with word length
What is immediate addressing?
When the operand is the actual value to be used in the instruction
What is direct addressing?
The operand in this case is the address of the location in memory of the data to be used