CPU Instruction Sets (Cambridge (CIE) IGCSE Computer Science)

Revision Note

James Woodhouse

Written by: James Woodhouse

Reviewed by: Lucy Kirkham

CPU Instruction Sets

What is an Instruction set?

  • An instruction set is a list of all the commands that can be processed by a CPU

  • Each command has a binary code which is called machine code

  • The binary code is made up of an operation code (opcode) and an operand

    • The opcode is the operation to be performed

    • The operand is the location where the operation is to be performed in 

  • The table below shows an example instruction set

  • Each instruction has a mnemonic that indicates what the instruction does alongside an example binary code

  • After an instruction is decoded into an opcode and an operand, the CPU finds the opcode in the processor’s instruction set

  • It then knows what operation to perform when executing the instruction

Instruction

Mnemonic

Binary code

Command

Add

ADD

10100001

Adds a value to the value currently stored in the accumulator (ACC)

Subtract

SUB

00100010

Subtract a value from the values stored in the accumulator

Load

LDA

10111111

Load the value stored in a memory location into the accumulator

Store

STA

01100000

Store the value in the accumulator in a specific location in memory

Stop

HLT

00000000

Stop the program

  • Instruction lists are machine-specific

    • A program created using one computer’s instruction set would not run on a computer containing a processor made by a different manufacturer

    • For example, a computer program created using Intel’s instruction set would not run on a device containing an ARM processor

Worked Example

Using the instruction set in the table above what would be the operation if the instruction was 00100010 00000010?

[1]

Answer

Either of:

  • The operation would be SUB [1]

  • If the operand was raw data the complete instruction would be to subtract 2 from the value in the accumulator [1]

Last updated:

You've read 0 of your 10 free revision notes

Unlock more, it's free!

Join the 100,000+ Students that ❤️ Save My Exams

the (exam) results speak for themselves:

Did this page help you?

James Woodhouse

Author: James Woodhouse

Expertise: Computer Science

James graduated from the University of Sunderland with a degree in ICT and Computing education. He has over 14 years of experience both teaching and leading in Computer Science, specialising in teaching GCSE and A-level. James has held various leadership roles, including Head of Computer Science and coordinator positions for Key Stage 3 and Key Stage 4. James has a keen interest in networking security and technologies aimed at preventing security breaches.

Lucy Kirkham

Author: Lucy Kirkham

Expertise: Head of STEM

Lucy has been a passionate Maths teacher for over 12 years, teaching maths across the UK and abroad helping to engage, interest and develop confidence in the subject at all levels.Working as a Head of Department and then Director of Maths, Lucy has advised schools and academy trusts in both Scotland and the East Midlands, where her role was to support and coach teachers to improve Maths teaching for all.