Wednesday, 14 March 2012

Registered based


Registered  Based Machine
Processor registers are normally at the top of the memory hierarchy, and provide the fastest way to access data. The term normally refers only to the group of registers that are directly encoded as part of an instruction, as defined by the instruction set. However, modern high performance CPUs often have duplicates of these "architectural registers" in order to improve performance via register renaming, allowing parallel and speculative execution. Modern x86 is perhaps the most well known example of this technique.[1]
Allocating frequently used variables to registers can be critical to a program's performance. This register allocation is either performed by a compiler, in the code generation phase, or manually, by an assembly language programmer.
Categories of register
Registers are normally measured by the number of bits they can hold, for example, an "8-bit register" or a "32-bit register". A processor often contains several kinds of registers, that can be classified accordingly to their content or instructions that operate on them:
1.     User-accessible Registers – The most common division of user-accessible registers is into data registers and address registers.
2.     Data registers can hold numeric values such as integer and floating-point values, as well as characters, small bit arrays and other data. In some older and low end CPUs, a special data register, known as the accumulator, is used implicitly for many operations.
3.     Address registers hold addresses and are used by instructions that indirectly access primary memory.
a.     Some processors contain registers that may only be used to hold an address or only to hold numeric values (in some cases used as an index register whose value is added as an offset from some address); others allow registers to hold either kind of quantity. A wide variety of possible addressing modes, used to specify the effective address of an operand, exist.
b.    The stack pointer is used to manage the run-time stack. Rarely, other data stacks are addressed by dedicated address registers, seestack machine.
4.     Conditional registers hold truth values often used to determine whether some instruction should or should not be executed.
5.     General purpose registers (GPRs) can store both data and addresses, i.e., they are combined Data/Address registers.
6.     Floating point registers (FPRs) store floating point numbers in many architectures.
7.     Constant registers hold read-only values such as zero, one, or pi.
8.     Vector registers hold data for vector processing done by SIMD instructions (Single Instruction, Multiple Data).
9.     Special purpose registers ( SPR ) hold program state; they usually include the program counter (aka instruction pointer) and status register (aka processor status word). The aforementioned stack pointer is sometimes also included in this group. Embedded microprocessors can also have registers corresponding to specialized hardware elements.
Instruction register store the instruction currently being executed.
10.  In some architectures, model-specific registers (also called machine-specific registers) store data and settings related to the processor itself. Because their meanings are attached to the design of a specific processor, they cannot be expected to remain standard between processor generations.
11.  Control and status registers – It has three types: program counter, instruction registers and program status word (PSW).
12.  Registers related to fetching information from RAM, a collection of storage registers located on separate chips from the CPU (unlike most of the above, these are generally not architectural registers):
  1. Memory data register
  2. Memory address register
  3. Memory Type Range Registers (MTRR)



No comments:

Post a Comment