Open In App

General Purpose Registers

A register serves as a quick memory for accepting, storing, and sending data and instructions that the CPU will need right away. A register is a collection of flip-flops, Single bit digital data is stored using flip-flops. By combining many flip-flops, the storage capacity can be extended to accommodate a huge number of bits. We must utilize an n-bit register with n flip flops if we wish to store an n-bit word.

The gates govern the flow of information, i.e., when and how the information is sent into a register, whereas the flip-flops store the binary information.



 

Working of Registers:

When we provide the system with input, that input is stored in registers, and when the system returns results after processing, those results are also drawn from the registers. so that the CPU can use them to process the data that the user provides.

Registers are performed based on three operations:



Types of Registers:

Status and Control Register:

Status and Control registers report and allow modification of the state of the processor and of the program being executed.

 

General-Purpose Data Registers: 

General purpose registers are extra registers that are present in the CPU and are utilized anytime data or a memory location is required. These registers are used for storing operands and pointers. These are mainly used for holding the following:

There are 3 types of General-purpose data registers they are:

Data registers: Data registers consists of four 32-bit data registers, which are used for arithmetic, logical and other operations. Data registers are again classified into 4 types they are:

Pointer registers: The pointer registers consist of 16-bit left sections (SP, and BP) and 32-bit ESP and EBP registers.

Index registers: The 16-bit rightmost bits of the 32-bit ESI and EDI index registers. SI and DI are sometimes employed in addition and sometimes in subtraction as well as for indexed addressing.

Special Purpose Registers:

To store machine state data and change state configuration, special purpose registers are employed. In other words, it is also defined as the CPU has a number of registers that are used to carry out instruction execution these registers are called special purpose registers. Special purpose registers are of 8 types they are cs, ds, ss, es, fs, and gs registers come under segment registers. These registers hold up to six segment selectors. 


Article Tags :