Difference between Cache Memory and Main Memory

Key Difference: Cache memory is a high speed memory that is used to store frequently accessed data. Whenever it is required, this data is made available to the Central processing unit at a rapid rate.  Main memory is also known as Random Access Memory. It is a memory unit that directly interacts with the central processing unit (CPU).

Cache Memory is a small and high speed access area. It is used to store frequently accessed data. Whenever it is required, this data is made available to the central processing unit at a rapid rate. Cache memory can be accessed at a very fast rate than in comparison to normal main memory. This memory often resides in the CPU. It has been devised to match the speed of the processor; it is Static-RAM, SRAM. These SRAM are faster and expensive than DRAM.

Cache memory is located between main memory and CPU. If a processor needs to write or read a location in the main memory, it checks the availability of the memory location in the cache. It is done by comparing the address of the memory location to all the tags in the cache which have the possibility of containing that particular address. In case the memory location in found in the cache, it is regarded as a Cache hit, and if not, then in that case it is regarded as a Cache miss. Primary cache is closest to the processor. Secondary cache is located at the second closest place of the processor.

Main memory is also known as Random Access Memory (RAM). It is a memory unit that directly interacts with the central processing unit (CPU). It is a volatile source of data. It can be described as a large array comprising of words or bytes. RAM is connected with the processor by its address and data buses. These buses are composed of electrical circuits or bits. Main memory is actually built from DRAM chips or Dynamic RAM. They are known for their compact size and capability for a faster access. It is important to mention that the computer can only manipulate data that is present in the main memory. A typical “module” of desktop memory is long and thin in appearance. It is installed in the memory module slots present on the motherboard. Modern memory modules come in various capacities like 256MB, 512MB, 1GB, 2GB, 4GB, and 8GB sizes; main memory has a limited capacity.

Comparison between Cache Memory and Main Memory:

 

Main Memory (RAM)

Cache Memory

Definition

Main memory is also known as Random Access Memory. It is a memory unit that directly interacts with the central processing unit (CPU)

Cache memory is used to store frequently accessed data in order to quickly access the data whenever it is required.

Proximity with CPU

Comparatively far

 

Comparatively closer

 

Speed

Comparatively slow

Comparatively fast

Capacity

Larger

Comparatively less

Component

It is a part of the hard drive (secondary storage)

Located on the processor itself

Image Courtesy: engineersgarage.com, transtutors.com

Most Searched in Education and References Most Searched in Society and Culture
Most Searched in Electronics Most Searched in Computers and Internets
Flash Drives vs External Hard Drives
Nokia Lumia 928 vs Sony Xperia Z
Primer vs Foundation
CT scan vs Ultrasound

Comments

Full table is not been able to see

Thanks.....it was pretty useful :)

Add new comment

Plain text

CAPTCHA
This question is for testing whether or not you are a human visitor and to prevent automated spam submissions.