SlideShare ist ein Scribd-Unternehmen logo
1 von 15
DULDULAO, JULIANA MEI A.
Cache Memory
(L1, L2, L3 & caching techniques)
What is
Cache Memory?
A cache memory is a very high
speed, expensive piece of memory,
which is used to speed up the retrieval
process.
Without cache memory, every
time the CPU requests for data, it would
send the request to main memory
which would then be sent back across
the system bus to the CPU.
The idea of introducing cache is
that this extremely fast memory would
store data that is frequently accessed
and if possible, the data that is around
it.
Programs and apps on your computer are designed as a set of
instructions that the CPU interprets and runs.
How does Cache memory work?
This is where the memory hierarchy comes into play.
The data first gets loaded up into the RAM and is then sent to the CPU.
CPUs these days are capable of carrying out a gigantic number of
instructions per second. To make full use of its power, the CPU needs
access to super-fast memory, which is where the Cache memory
comes in.
The memory controller takes the data from the RAM and sends it to
the CPU cache. Depending on your CPU, the controller is found on the
CPU, or the Northbridge chipset found on your motherboard.
The memory cache then carries out the back and forth of data within
the CPU.
The Levels of CPU Cache Memory: L1, L2, and L3
L1
L2
L3
The Levels of CPU Cache Memory: L1, L2, and L3
L1 Cache
L1 (Level 1) cache is the fastest memory that is present
in a computer system.
The size of the L1 cache depends on the CPU. Some top-
end consumer CPUs now feature a 1MB L1 cache, like the Intel
i9-9980XE, but these cost a huge amount of money and are still
few and far between. Some server chipsets, like Intel's Xeon
range, also feature a 1-2MB L1 memory cache.
The Levels of CPU Cache Memory: L1, L2, and L3
L1 Cache
The Levels of CPU Cache Memory: L1, L2, and L3
L2 Cache
L2 (Level 2) cache is slower than the L1 cache but bigger
in size. Where an L1 cache may measure in kilobytes, modern L2
memory caches measure in megabytes.
The L2 cache size varies depending on the CPU, but its
size is typically between 256KB to 8MB. Most modern CPUs will
pack more than a 256KB L2 cache, and this size is now
considered small.
When it comes to speed, the L2 cache lags behind the
L1 cache but is still much faster than your system RAM. The L1
memory cache is typically 100 times faster than your RAM, while
the L2 cache is around 25 times faster.
The Levels of CPU Cache Memory: L1, L2, and L3
L3 Cache
Onto the L3 (Level 3) cache. In the early days, the L3
memory cache was actually found on the motherboard. This was
a very long time ago, back when most CPUs were just single-core
processors.
The L3 cache is the largest but also the slowest cache
memory unit. Modern CPUs include the L3 cache on the CPU
itself. But while the L1 and L2 cache exist for each core on the
chip itself, the L3 cache is more akin to a general memory pool
that the entire chip can make use of.
The Levels of CPU Cache Memory: L1, L2, and L3
Caching techniques
What is Caching?
Caching is a mechanism to improve the performance of any type of
application. Technically, caching is the process of storing and accessing data from a
cache.
The main reason why caching was born is that accessing data from persistent
memories takes a considerable amount of time. Thus, whenever data is retrieved or
processed, it should be stored in a more efficient memory.
Caching is a fairly simple way to achieve performance improvements. This is
especially true when compared to algorithm optimization, which is usually a much
complex and time-consuming task.
Different types of Caching
1 SpatialCache
2 TemporalCache
Spatial Locality means that all those instructions
which are stored nearby to the recently executed
instruction have high chances of execution. It refers to the
use of data elements(instructions) which are relatively
close in storage locations.
Temporal Locality means that a instruction which
is recently executed have high chances of execution again.
So the instruction is kept in cache memory such that it can
be fetched easily and takes no time in searching for the
same instruction.
3 Write-Through Cache
4 Write-BackCache
Write-through data is simultaneously updated to cache and
memory. This process is simpler and more reliable. This is used when
there are no frequent writes to the cache.
It helps in data recovery. A data write will experience
latency as we have to write to two locations. It Solves the
inconsistency problem. But it questions the advantage of having a
cache in write operation.
The data is updated only in the cache and updated
into the memory at a later time. Data is updated in the
memory only when the cache line is ready to be replaced.
Write Back is also known as Write Deferred.
REFERENCES
https://www.makeuseof.com/tag/what-is-cpu-cache/
https://techaudhary.com/what-is-cache-memory/
https://www.geeksforgeeks.org/difference-between-
spatial-locality-and-temporal-locality/
https://www.geeksforgeeks.org/write-through-and-
write-back-in-cache/

Weitere ähnliche Inhalte

Was ist angesagt?

Was ist angesagt? (20)

raid technology
raid technologyraid technology
raid technology
 
Storage Managment
Storage ManagmentStorage Managment
Storage Managment
 
Cache memory
Cache memoryCache memory
Cache memory
 
Cache memory
Cache memoryCache memory
Cache memory
 
Cache memory
Cache memoryCache memory
Cache memory
 
Cache memory ppt
Cache memory ppt  Cache memory ppt
Cache memory ppt
 
CACHE MEMORY
CACHE MEMORYCACHE MEMORY
CACHE MEMORY
 
Cache Memory
Cache MemoryCache Memory
Cache Memory
 
OS Memory Management
OS Memory ManagementOS Memory Management
OS Memory Management
 
Direct memory access
Direct memory accessDirect memory access
Direct memory access
 
SSD - Solid State Drive PPT by Atishay Jain
SSD - Solid State Drive PPT by Atishay JainSSD - Solid State Drive PPT by Atishay Jain
SSD - Solid State Drive PPT by Atishay Jain
 
Memory fragmentation by ofor williams daniel
Memory fragmentation by ofor williams danielMemory fragmentation by ofor williams daniel
Memory fragmentation by ofor williams daniel
 
Cache memory and virtual memory
Cache memory and virtual memoryCache memory and virtual memory
Cache memory and virtual memory
 
Storage devices ppt by abhishek srivastava
Storage devices ppt by abhishek srivastavaStorage devices ppt by abhishek srivastava
Storage devices ppt by abhishek srivastava
 
ROM
ROMROM
ROM
 
Memory Organization
Memory OrganizationMemory Organization
Memory Organization
 
Cache memory principles
Cache memory principlesCache memory principles
Cache memory principles
 
Raid Technology
Raid TechnologyRaid Technology
Raid Technology
 
SCSI(small computer system interface)
SCSI(small computer system interface)SCSI(small computer system interface)
SCSI(small computer system interface)
 
Virtual memory
Virtual memoryVirtual memory
Virtual memory
 

Ähnlich wie Cache Memory- JMD.pptx

lecture_11.pptx
lecture_11.pptxlecture_11.pptx
lecture_11.pptxyewid98102
 
ملٹی لیول کے شے۔
ملٹی لیول کے شے۔ملٹی لیول کے شے۔
ملٹی لیول کے شے۔maamir farooq
 
Virtual Memory vs Cache Memory
Virtual Memory vs Cache MemoryVirtual Memory vs Cache Memory
Virtual Memory vs Cache MemoryAshik Iqbal
 
2. the memory systems (module2)
2. the memory systems (module2)2. the memory systems (module2)
2. the memory systems (module2)Ajit Saraf
 
Exploring Of System Hardware
Exploring Of System HardwareExploring Of System Hardware
Exploring Of System HardwareMuhammad Nauman
 
Microprocessor made by gulshan 11th a
Microprocessor made by gulshan 11th  aMicroprocessor made by gulshan 11th  a
Microprocessor made by gulshan 11th aChandrakiran Satdeve
 
Computer memory and types of memory.pptx
Computer memory and types of memory.pptxComputer memory and types of memory.pptx
Computer memory and types of memory.pptxdbmscse61
 
cachememory-210517060741 (1).pdf
cachememory-210517060741 (1).pdfcachememory-210517060741 (1).pdf
cachememory-210517060741 (1).pdfOmGadekar2
 
Understanding And Managing Memory
Understanding And Managing MemoryUnderstanding And Managing Memory
Understanding And Managing Memoryisma ishak
 

Ähnlich wie Cache Memory- JMD.pptx (20)

Cache Memory.ppt
Cache Memory.pptCache Memory.ppt
Cache Memory.ppt
 
Cache memory
Cache memory Cache memory
Cache memory
 
Cache memory presentation
Cache memory presentationCache memory presentation
Cache memory presentation
 
lecture_11.pptx
lecture_11.pptxlecture_11.pptx
lecture_11.pptx
 
ملٹی لیول کے شے۔
ملٹی لیول کے شے۔ملٹی لیول کے شے۔
ملٹی لیول کے شے۔
 
Cache memory
Cache memoryCache memory
Cache memory
 
Virtual Memory vs Cache Memory
Virtual Memory vs Cache MemoryVirtual Memory vs Cache Memory
Virtual Memory vs Cache Memory
 
CPU & RAM
CPU & RAMCPU & RAM
CPU & RAM
 
cache.pptx
cache.pptxcache.pptx
cache.pptx
 
2. the memory systems (module2)
2. the memory systems (module2)2. the memory systems (module2)
2. the memory systems (module2)
 
Memory hierarchy
Memory hierarchyMemory hierarchy
Memory hierarchy
 
Exploring Of System Hardware
Exploring Of System HardwareExploring Of System Hardware
Exploring Of System Hardware
 
Microprocessor made by gulshan 11th a
Microprocessor made by gulshan 11th  aMicroprocessor made by gulshan 11th  a
Microprocessor made by gulshan 11th a
 
Cache memory
Cache memoryCache memory
Cache memory
 
Cache memory ...
Cache memory ...Cache memory ...
Cache memory ...
 
Computer memory and types of memory.pptx
Computer memory and types of memory.pptxComputer memory and types of memory.pptx
Computer memory and types of memory.pptx
 
cachememory-210517060741 (1).pdf
cachememory-210517060741 (1).pdfcachememory-210517060741 (1).pdf
cachememory-210517060741 (1).pdf
 
M E M O R Y
M E M O R YM E M O R Y
M E M O R Y
 
Understanding And Managing Memory
Understanding And Managing MemoryUnderstanding And Managing Memory
Understanding And Managing Memory
 
Lesson 8 Memory Storage And Management
Lesson 8 Memory Storage And ManagementLesson 8 Memory Storage And Management
Lesson 8 Memory Storage And Management
 

Kürzlich hochgeladen

Team Transformation Tactics for Holistic Testing and Quality (NewCrafts Paris...
Team Transformation Tactics for Holistic Testing and Quality (NewCrafts Paris...Team Transformation Tactics for Holistic Testing and Quality (NewCrafts Paris...
Team Transformation Tactics for Holistic Testing and Quality (NewCrafts Paris...Lisi Hocke
 
Encryption Recap: A Refresher on Key Concepts
Encryption Recap: A Refresher on Key ConceptsEncryption Recap: A Refresher on Key Concepts
Encryption Recap: A Refresher on Key Conceptsthomashtkim
 
AzureNativeQumulo_HPC_Cloud_Native_Benchmarks.pdf
AzureNativeQumulo_HPC_Cloud_Native_Benchmarks.pdfAzureNativeQumulo_HPC_Cloud_Native_Benchmarks.pdf
AzureNativeQumulo_HPC_Cloud_Native_Benchmarks.pdfryanfarris8
 
Modern binary build systems - PyCon 2024
Modern binary build systems - PyCon 2024Modern binary build systems - PyCon 2024
Modern binary build systems - PyCon 2024Henry Schreiner
 
Alluxio Monthly Webinar | Simplify Data Access for AI in Multi-Cloud
Alluxio Monthly Webinar | Simplify Data Access for AI in Multi-CloudAlluxio Monthly Webinar | Simplify Data Access for AI in Multi-Cloud
Alluxio Monthly Webinar | Simplify Data Access for AI in Multi-CloudAlluxio, Inc.
 
Prompt Engineering - an Art, a Science, or your next Job Title?
Prompt Engineering - an Art, a Science, or your next Job Title?Prompt Engineering - an Art, a Science, or your next Job Title?
Prompt Engineering - an Art, a Science, or your next Job Title?Maxim Salnikov
 
CERVED e Neo4j su una nuvola, migrazione ed evoluzione di un grafo mission cr...
CERVED e Neo4j su una nuvola, migrazione ed evoluzione di un grafo mission cr...CERVED e Neo4j su una nuvola, migrazione ed evoluzione di un grafo mission cr...
CERVED e Neo4j su una nuvola, migrazione ed evoluzione di un grafo mission cr...Neo4j
 
Effective Strategies for Wix's Scaling challenges - GeeCon
Effective Strategies for Wix's Scaling challenges - GeeConEffective Strategies for Wix's Scaling challenges - GeeCon
Effective Strategies for Wix's Scaling challenges - GeeConNatan Silnitsky
 
Novo Nordisk: When Knowledge Graphs meet LLMs
Novo Nordisk: When Knowledge Graphs meet LLMsNovo Nordisk: When Knowledge Graphs meet LLMs
Novo Nordisk: When Knowledge Graphs meet LLMsNeo4j
 
UNI DI NAPOLI FEDERICO II - Il ruolo dei grafi nell'AI Conversazionale Ibrida
UNI DI NAPOLI FEDERICO II - Il ruolo dei grafi nell'AI Conversazionale IbridaUNI DI NAPOLI FEDERICO II - Il ruolo dei grafi nell'AI Conversazionale Ibrida
UNI DI NAPOLI FEDERICO II - Il ruolo dei grafi nell'AI Conversazionale IbridaNeo4j
 
Weeding your micro service landscape.pdf
Weeding your micro service landscape.pdfWeeding your micro service landscape.pdf
Weeding your micro service landscape.pdftimtebeek1
 
[GRCPP] Introduction to concepts (C++20)
[GRCPP] Introduction to concepts (C++20)[GRCPP] Introduction to concepts (C++20)
[GRCPP] Introduction to concepts (C++20)Dimitrios Platis
 
Test Automation Design Patterns_ A Comprehensive Guide.pdf
Test Automation Design Patterns_ A Comprehensive Guide.pdfTest Automation Design Patterns_ A Comprehensive Guide.pdf
Test Automation Design Patterns_ A Comprehensive Guide.pdfkalichargn70th171
 
OpenChain Webinar: AboutCode and Beyond - End-to-End SCA
OpenChain Webinar: AboutCode and Beyond - End-to-End SCAOpenChain Webinar: AboutCode and Beyond - End-to-End SCA
OpenChain Webinar: AboutCode and Beyond - End-to-End SCAShane Coughlan
 
Anypoint Code Builder - Munich MuleSoft Meetup - 16th May 2024
Anypoint Code Builder - Munich MuleSoft Meetup - 16th May 2024Anypoint Code Builder - Munich MuleSoft Meetup - 16th May 2024
Anypoint Code Builder - Munich MuleSoft Meetup - 16th May 2024MulesoftMunichMeetup
 
Your Ultimate Web Studio for Streaming Anywhere | Evmux
Your Ultimate Web Studio for Streaming Anywhere | EvmuxYour Ultimate Web Studio for Streaming Anywhere | Evmux
Your Ultimate Web Studio for Streaming Anywhere | Evmuxevmux96
 

Kürzlich hochgeladen (20)

Team Transformation Tactics for Holistic Testing and Quality (NewCrafts Paris...
Team Transformation Tactics for Holistic Testing and Quality (NewCrafts Paris...Team Transformation Tactics for Holistic Testing and Quality (NewCrafts Paris...
Team Transformation Tactics for Holistic Testing and Quality (NewCrafts Paris...
 
Encryption Recap: A Refresher on Key Concepts
Encryption Recap: A Refresher on Key ConceptsEncryption Recap: A Refresher on Key Concepts
Encryption Recap: A Refresher on Key Concepts
 
Abortion Clinic In Stanger ](+27832195400*)[ 🏥 Safe Abortion Pills In Stanger...
Abortion Clinic In Stanger ](+27832195400*)[ 🏥 Safe Abortion Pills In Stanger...Abortion Clinic In Stanger ](+27832195400*)[ 🏥 Safe Abortion Pills In Stanger...
Abortion Clinic In Stanger ](+27832195400*)[ 🏥 Safe Abortion Pills In Stanger...
 
AzureNativeQumulo_HPC_Cloud_Native_Benchmarks.pdf
AzureNativeQumulo_HPC_Cloud_Native_Benchmarks.pdfAzureNativeQumulo_HPC_Cloud_Native_Benchmarks.pdf
AzureNativeQumulo_HPC_Cloud_Native_Benchmarks.pdf
 
Modern binary build systems - PyCon 2024
Modern binary build systems - PyCon 2024Modern binary build systems - PyCon 2024
Modern binary build systems - PyCon 2024
 
Alluxio Monthly Webinar | Simplify Data Access for AI in Multi-Cloud
Alluxio Monthly Webinar | Simplify Data Access for AI in Multi-CloudAlluxio Monthly Webinar | Simplify Data Access for AI in Multi-Cloud
Alluxio Monthly Webinar | Simplify Data Access for AI in Multi-Cloud
 
Prompt Engineering - an Art, a Science, or your next Job Title?
Prompt Engineering - an Art, a Science, or your next Job Title?Prompt Engineering - an Art, a Science, or your next Job Title?
Prompt Engineering - an Art, a Science, or your next Job Title?
 
CERVED e Neo4j su una nuvola, migrazione ed evoluzione di un grafo mission cr...
CERVED e Neo4j su una nuvola, migrazione ed evoluzione di un grafo mission cr...CERVED e Neo4j su una nuvola, migrazione ed evoluzione di un grafo mission cr...
CERVED e Neo4j su una nuvola, migrazione ed evoluzione di un grafo mission cr...
 
Effective Strategies for Wix's Scaling challenges - GeeCon
Effective Strategies for Wix's Scaling challenges - GeeConEffective Strategies for Wix's Scaling challenges - GeeCon
Effective Strategies for Wix's Scaling challenges - GeeCon
 
Abortion Pill Prices Germiston ](+27832195400*)[ 🏥 Women's Abortion Clinic in...
Abortion Pill Prices Germiston ](+27832195400*)[ 🏥 Women's Abortion Clinic in...Abortion Pill Prices Germiston ](+27832195400*)[ 🏥 Women's Abortion Clinic in...
Abortion Pill Prices Germiston ](+27832195400*)[ 🏥 Women's Abortion Clinic in...
 
Abortion Pill Prices Turfloop ](+27832195400*)[ 🏥 Women's Abortion Clinic in ...
Abortion Pill Prices Turfloop ](+27832195400*)[ 🏥 Women's Abortion Clinic in ...Abortion Pill Prices Turfloop ](+27832195400*)[ 🏥 Women's Abortion Clinic in ...
Abortion Pill Prices Turfloop ](+27832195400*)[ 🏥 Women's Abortion Clinic in ...
 
Novo Nordisk: When Knowledge Graphs meet LLMs
Novo Nordisk: When Knowledge Graphs meet LLMsNovo Nordisk: When Knowledge Graphs meet LLMs
Novo Nordisk: When Knowledge Graphs meet LLMs
 
UNI DI NAPOLI FEDERICO II - Il ruolo dei grafi nell'AI Conversazionale Ibrida
UNI DI NAPOLI FEDERICO II - Il ruolo dei grafi nell'AI Conversazionale IbridaUNI DI NAPOLI FEDERICO II - Il ruolo dei grafi nell'AI Conversazionale Ibrida
UNI DI NAPOLI FEDERICO II - Il ruolo dei grafi nell'AI Conversazionale Ibrida
 
Abortion Pill Prices Mthatha (@](+27832195400*)[ 🏥 Women's Abortion Clinic In...
Abortion Pill Prices Mthatha (@](+27832195400*)[ 🏥 Women's Abortion Clinic In...Abortion Pill Prices Mthatha (@](+27832195400*)[ 🏥 Women's Abortion Clinic In...
Abortion Pill Prices Mthatha (@](+27832195400*)[ 🏥 Women's Abortion Clinic In...
 
Weeding your micro service landscape.pdf
Weeding your micro service landscape.pdfWeeding your micro service landscape.pdf
Weeding your micro service landscape.pdf
 
[GRCPP] Introduction to concepts (C++20)
[GRCPP] Introduction to concepts (C++20)[GRCPP] Introduction to concepts (C++20)
[GRCPP] Introduction to concepts (C++20)
 
Test Automation Design Patterns_ A Comprehensive Guide.pdf
Test Automation Design Patterns_ A Comprehensive Guide.pdfTest Automation Design Patterns_ A Comprehensive Guide.pdf
Test Automation Design Patterns_ A Comprehensive Guide.pdf
 
OpenChain Webinar: AboutCode and Beyond - End-to-End SCA
OpenChain Webinar: AboutCode and Beyond - End-to-End SCAOpenChain Webinar: AboutCode and Beyond - End-to-End SCA
OpenChain Webinar: AboutCode and Beyond - End-to-End SCA
 
Anypoint Code Builder - Munich MuleSoft Meetup - 16th May 2024
Anypoint Code Builder - Munich MuleSoft Meetup - 16th May 2024Anypoint Code Builder - Munich MuleSoft Meetup - 16th May 2024
Anypoint Code Builder - Munich MuleSoft Meetup - 16th May 2024
 
Your Ultimate Web Studio for Streaming Anywhere | Evmux
Your Ultimate Web Studio for Streaming Anywhere | EvmuxYour Ultimate Web Studio for Streaming Anywhere | Evmux
Your Ultimate Web Studio for Streaming Anywhere | Evmux
 

Cache Memory- JMD.pptx

  • 1. DULDULAO, JULIANA MEI A. Cache Memory (L1, L2, L3 & caching techniques)
  • 2. What is Cache Memory? A cache memory is a very high speed, expensive piece of memory, which is used to speed up the retrieval process. Without cache memory, every time the CPU requests for data, it would send the request to main memory which would then be sent back across the system bus to the CPU. The idea of introducing cache is that this extremely fast memory would store data that is frequently accessed and if possible, the data that is around it.
  • 3.
  • 4. Programs and apps on your computer are designed as a set of instructions that the CPU interprets and runs. How does Cache memory work? This is where the memory hierarchy comes into play. The data first gets loaded up into the RAM and is then sent to the CPU. CPUs these days are capable of carrying out a gigantic number of instructions per second. To make full use of its power, the CPU needs access to super-fast memory, which is where the Cache memory comes in. The memory controller takes the data from the RAM and sends it to the CPU cache. Depending on your CPU, the controller is found on the CPU, or the Northbridge chipset found on your motherboard. The memory cache then carries out the back and forth of data within the CPU.
  • 5. The Levels of CPU Cache Memory: L1, L2, and L3 L1 L2 L3
  • 6. The Levels of CPU Cache Memory: L1, L2, and L3 L1 Cache L1 (Level 1) cache is the fastest memory that is present in a computer system. The size of the L1 cache depends on the CPU. Some top- end consumer CPUs now feature a 1MB L1 cache, like the Intel i9-9980XE, but these cost a huge amount of money and are still few and far between. Some server chipsets, like Intel's Xeon range, also feature a 1-2MB L1 memory cache.
  • 7. The Levels of CPU Cache Memory: L1, L2, and L3 L1 Cache
  • 8. The Levels of CPU Cache Memory: L1, L2, and L3 L2 Cache L2 (Level 2) cache is slower than the L1 cache but bigger in size. Where an L1 cache may measure in kilobytes, modern L2 memory caches measure in megabytes. The L2 cache size varies depending on the CPU, but its size is typically between 256KB to 8MB. Most modern CPUs will pack more than a 256KB L2 cache, and this size is now considered small. When it comes to speed, the L2 cache lags behind the L1 cache but is still much faster than your system RAM. The L1 memory cache is typically 100 times faster than your RAM, while the L2 cache is around 25 times faster.
  • 9. The Levels of CPU Cache Memory: L1, L2, and L3 L3 Cache Onto the L3 (Level 3) cache. In the early days, the L3 memory cache was actually found on the motherboard. This was a very long time ago, back when most CPUs were just single-core processors. The L3 cache is the largest but also the slowest cache memory unit. Modern CPUs include the L3 cache on the CPU itself. But while the L1 and L2 cache exist for each core on the chip itself, the L3 cache is more akin to a general memory pool that the entire chip can make use of.
  • 10. The Levels of CPU Cache Memory: L1, L2, and L3
  • 11. Caching techniques What is Caching? Caching is a mechanism to improve the performance of any type of application. Technically, caching is the process of storing and accessing data from a cache. The main reason why caching was born is that accessing data from persistent memories takes a considerable amount of time. Thus, whenever data is retrieved or processed, it should be stored in a more efficient memory. Caching is a fairly simple way to achieve performance improvements. This is especially true when compared to algorithm optimization, which is usually a much complex and time-consuming task.
  • 13. 1 SpatialCache 2 TemporalCache Spatial Locality means that all those instructions which are stored nearby to the recently executed instruction have high chances of execution. It refers to the use of data elements(instructions) which are relatively close in storage locations. Temporal Locality means that a instruction which is recently executed have high chances of execution again. So the instruction is kept in cache memory such that it can be fetched easily and takes no time in searching for the same instruction.
  • 14. 3 Write-Through Cache 4 Write-BackCache Write-through data is simultaneously updated to cache and memory. This process is simpler and more reliable. This is used when there are no frequent writes to the cache. It helps in data recovery. A data write will experience latency as we have to write to two locations. It Solves the inconsistency problem. But it questions the advantage of having a cache in write operation. The data is updated only in the cache and updated into the memory at a later time. Data is updated in the memory only when the cache line is ready to be replaced. Write Back is also known as Write Deferred.