Cache Memory and Register Memory
M1-R5.1 & CCC · Chapter 1: Introduction to Computer · 3 min read
Cache Memory
- Cache memory is a very small and very fast memory placed b/w CPU and main memory (RAM).
- Cache is faster than main memory, so it improves the overall speed of the computer.
- It works as a high-speed buffer b/w C.P.U. and main memory (RAM).
- It is used to temporarily store very active data and instructions during processing.
- It stores frequently used data and instructions temporarily so the CPU can access them faster.
- Access time of a cache memory is 15-25 nanosecond, while main memory takes about 25 nanoseconds.
- Many Computer Systems are designed to have two Separate Cache memories-
1. Instruction Cache
2. Data cache
- The instruction cache is used for storing program instructions and the data cache is used for Storing data.
- Many computer systems are also designed to have multiple levels of caches such as- L1,L2,L3I
Register Memory
- "Register memory" usually refers to a type of computer memory used in processors (CPUs).
- Register memory is a small, fastest type of memory used inside the CPU.
- These registers are used to hold information on a temporary basis during instruction execution.
- All the instructions are read and run by the CPU using these registers.
- The size of registers is very small (measured in bits),but they work very quikly.
Common Types of Registers:
1)Memory Address Register (MAR):
- It holds the address of active memory location.
2)Memory Buffer Register(MBR)/ MDR( Memory Data Register):
- Temporarily holds data being transferred to or from memory.
3)Program Counter Register(PCR):
- Holds the address of the next instruction to be executed.
4)Accumulator Register(ACC):
- Used in arithmetic and logic operations.
5)Instruction Register (IR):
- Holds the current instruction that is being executed by the CPU.
6)Input/Output Register( I/O Register):
- Temporarily holds data going to or coming from an I/O device.
7)Decoder:
- It has a necessary circuit way to decode and interpret the meaning of each and every instruction supported by the CPU.
8)General Purpose Registers:
- Temporarily hold data during execution.