Processor Registers

Introduction

What are registers?

A register is a small, fast and easily accessible area of memory available to the computer’s processor. Some registers are specific purpose, such as the MAR, MDR, or ACC. Other registers are general purpose registers that can hold any data. How data is stored in registers varies from machine to machine and from register to register.

What do I need to know for the exam?

  1. You will need to be able to give a definition of a register
  2. You will need to be able to name the common registers found in Von Neumann Architecture (e.g. MDR,ACC,IR)
  3. You will need to be able to perform simple binary tasks with the contents of a register.(see example)

Example 1

Example 1 – Automatic Plant Watering System

A microcontroller that controls a plant watering system contains two 8-bit registers for storing the current day and month of the year.

  • Register A holds the day
  • Register B holds the month
A
0 0 0 1 1 0 0 1

 

B
0 0 0 0 1 1 0 0
What day of the year is it?

25th of December – Christmas Day!

Example 2

Example 2

A electronic stove stores the current power setting for 4 hob rings in four 4-bit registers. Each hob has power settings 0 to 9.

In order to stop the stove from drawing too much power it checks the registers every time a button is pressed to ensure the total power draw does not exceed 31.

A B C D
1 0 0 1 0 0 1 0 1 0 0 0 0 1 1 1
Has the stove reached the maximum power level?

A – 9, B – 2, C – 8, D-7    Total = 26

So no, the stove hasn’t exceeded the maximum power setting.

 

Resources