Assembly Language (Cambridge (CIE) O Level Computer Science): Revision Note
Exam code: 2210
Assembly Language
What is assembly language?
Assembly language is a second-generation, low-level language designed to simplify the writing of machine code instructions for programmers
Programmers use assembly language for the following reasons:
Need to make use of specific hardware or parts of the hardware
To complete specific machine-dependent instructions
To ensure that too much space is not taken up in RAM
To ensure code can be completed much faster
Assembly languages allow programmers to program with mnemonics, e.g.
LDA Load - this will ensure a value is added to the accumulator
ADD Addition - this will add the value input or loaded from memory to the value in the accumulator
STO Store - stores the value in the accumulator in RAM
Assembly language allowed continuation of working directly with the hardware but removed an element of complexity
A mnemonic is received by the computer and it is looked up within a specific table
An assembler is needed to check the word so that it can be converted into machine code
If a match from the word is found (e.g. STO), the word is replaced with the relevant binary code to match that sequence
Worked Example
Complete the table to identify whether each example of computer code is High-level, Assembly language or Machine code
Computer code | High-level | Assembly | Machine code |
|---|---|---|---|
| |||
| |||
|
[3]
Answer
Computer code | High-level | Assembly | Machine code |
|---|---|---|---|
| X [1 mark] | ||
| X [1 mark] | ||
| X [1 mark] |
Unlock more, it's free!
Was this revision note helpful?