CPU Register Types and Functions

Classified in Computers

Written on in English with a size of 3.48 KB

CPU Internal Registers

Internal registers are a set of temporary storage units available to the Central Processing Unit (CPU) for its operation. They serve as high-speed storage locations within the CPU itself.

The size of these registers depends on the function to be performed and the type of CPU. They generally match the size of the Data Bus or the Address Bus.

Classification of CPU Registers

CPU registers are broadly classified into two main types:

  • Inaccessible Registers: Not directly controllable by the user.
  • Accessible Registers: Controllable by the user.

Inaccessible Registers

Inaccessible registers are those whose operation or content the user cannot directly control. They are for the exclusive and restricted use of the CPU. From the user's point of view, these registers are transparent and do not apparently affect the CPU's operation.

Instruction Register (IR)

The Instruction Register (IR) is used to store the operational code of an instruction until its execution has finished. Its size is suitable for the codes used in most common CPUs, typically matching the size of the Data Bus.

Memory Address Register (MAR)

The Memory Address Register (MAR) consists of the outputs of the CPU's internal register, often referred to as the Bus Address Register. It is used to hold, for as long as necessary, a specific address for information on the address bus.

Various sources deliver addresses to the MAR. The Program Counter (PC) is the most frequently used source for the MAR. The Stack Pointer (SP) register also accesses the MAR when its content is used to provide an address. The MAR can also be loaded directly from a particular instruction if it contains the address of a data item.

Data Buffer Register (DBR)

The Data Buffer Register (DBR), also known as the Memory Data Register (MDR), is the pathway through which all codes and data requested and delivered by the CPU pass.

Accessible Registers

Accessible registers are those CPU registers whose operation and/or content the user can control from outside the CPU. Within accessible registers, there are two different types:

  • Specific-Purpose Registers: Their function is determined by the CPU manufacturer.
  • General-Purpose Registers: They do not have a predefined function.
Specific-Purpose Registers

Specific-purpose registers are allocated a specific function within the CPU, though they may perform other functions. These include:

  • Program Counter (PC): Holds the address of the next instruction to be executed.
  • Stack Pointer (SP): Points to the top of the stack in memory.
  • Index Register (IR): Used for address modification in indexed addressing modes.
  • Accumulator Register (AC): Stores the results of arithmetic and logic operations.
General-Purpose Registers

General-purpose registers are internal CPU registers that have no predefined function. They can be used as the source or destination of data within the CPU.

These registers are used as memory elements within the CPU with a very short access time. The size of these registers is often the same as the CPU's data bus.

Related entries: