0% found this document useful (0 votes)
37 views10 pages

Advance MP

The document discusses the translation lookaside buffer (TLB), which is used to reduce the effective memory access time in paged memory systems. The TLB stores recent translations between virtual and physical addresses. When a memory access occurs, the TLB is checked first. If the translation is present (a TLB hit), access is faster. If not present (TLB miss), slower access involves checking the page table first before accessing memory. By caching translations, the TLB reduces average memory access time compared to using just the page table. The TLB is updated each time a new translation is loaded from the page table.

Uploaded by

Khyati
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
37 views10 pages

Advance MP

The document discusses the translation lookaside buffer (TLB), which is used to reduce the effective memory access time in paged memory systems. The TLB stores recent translations between virtual and physical addresses. When a memory access occurs, the TLB is checked first. If the translation is present (a TLB hit), access is faster. If not present (TLB miss), slower access involves checking the page table first before accessing memory. By caching translations, the TLB reduces average memory access time compared to using just the page table. The TLB is updated each time a new translation is loaded from the page table.

Uploaded by

Khyati
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 10

TRANSLATIONAL

LOOKASIDE BUFFER

PRESENTED BY:
JYOTSANA (160130111037)

UNDER THE GUIDANCE: PROF.


SUHAS PATEL
SOME IMPORTANT TERMS
 Memory Management Unit: It is a hardware
device that maps virtual to physical address.

 Paging: It is a memory management technique in


which process add space is broken into blocks of
same size is called paging.
 Virtual Memory: Generated by CPU, more than
the memory amount physically installed on
system. Also called logical address or illusion.
 Physical address: It is seen by memory unit.

 Page table: Is a data structure that maps page


number to the frame number.
DISADVANTAGE OF PAGING-
One major disadvantage of paging is-

 It increases the effective access time due to


increased number of memory accesses

 One memory access is required to get the frame


number from the page table.

 Another memory access is required to get the


word from the page.
TRANSLATION LOOKASIDE BUFFER-
 Translation Look aside Buffer (TLB) is a solution
that tries to reduce the effective access time.
 Being a hardware, the access time of TLB is very
less as compared to the main memory.

 Structure-
TRANSLATIONAL LOOKASIDE BUFFER
IMPLEMENTATION

In a paging scheme using TLB,
 The logical address generated by the CPU is translated
into the physical address using following steps-

Step-01:
 CPU generates a logical address consisting of two parts-
 Page Number
 Page Offset

Step-02:

 TLB is checked to see if it contains an entry for the
referenced page number.
 The referenced page number is compared with the TLB
entries all at once.

 Now, two cases are possible-


Case-01: If there is a TLB hit-
 If TLB contains an entry for the referenced page number, a
TLB hit occurs.
 In this case, TLB entry is used to get the corresponding
frame number for the referenced page number.

Case-02: If there is a TLB miss-


 If TLB does not contain an entry for the referenced page
number, a TLB miss occurs.
 In this case, page table is used to get the corresponding
frame number for the referenced page number.
 Then, TLB is updated with the page number and frame
number for future references.

Step-03:
 After the frame number is obtained, it is combined with the
page offset to generate the physical address.
 Then, physical address is used to read the required word
from the main memory.
IMPORTANT POINTS-

When a new process gets scheduled-


 Initially, TLB is empty.

So, TLB misses are frequent.


 With every access from the

page table, TLB is updated.


 After some time, TLB hits

increases and TLB misses


reduces.
 Also, TLB is updated in parallel

while fetching the word from the


main memory.
Effective Access Time-
 In a single level paging using TLB, the effective access time is
given as-

Eg: A paging scheme uses a Translation Look aside buffer (TLB).


A TLB access takes 10 ns and a main memory access takes 50
ns. What is the effective access time (in ns) if the TLB hit ratio is
90% and there is no page fault?
 Sol: Effective Access Time
= 0.9 x { 10 ns + 50 ns } + 0.1 x { 10 ns + 2 x 50 ns }
= 0.9 x 60 ns + 0.1 x 110 ns
= 54 ns + 11 ns
= 65 ns

You might also like