Translation Lookaside Buffer

Created: 28.07.2022

In this article I will dissect what TLB is. It can help understand how Meltdown and Specter work.

Usually, OS performs translations between PA and VA. Those addresses already translated are cached in TLB (Translation Lookaside Buffer). The 1st priority is TLB, the second - page table lookup (since it takes more time).

If TLB’s full, least used entry will be replaced with the one just requested.

img

So, on the picture above virtual page #3 = physical page #6.

If the requested memory address is on Disk, there will be TLB miss (nothing found). Then TLB eviction (popping off the least used entry) and reading from DISK then which is very costy.

img

References

Expand… Something here