Difference between Cache and Translation LookAside Buffer[TLB]

前端 未结 4 739
栀梦
栀梦 2020-12-29 05:19

What is the difference between Cache and Translation LookAside Buffer [TLB] ?

4条回答
  •  陌清茗
    陌清茗 (楼主)
    2020-12-29 05:38

    From Wiki:

    In computer science, a cache (pronounced /kæʃ/, kash) is a collection of data duplicating original values stored elsewhere or computed earlier, where the original data is expensive to fetch (owing to longer access time) or to compute, compared to the cost of reading the cache. In other words, a cache operates as a temporary storage area where frequently accessed data can be stored for rapid access. Once the data is stored in the cache, it can be used in the future by accessing the cached copy rather than re-fetching or recomputing the original data.

    whereas

    A Translation lookaside buffer(TLB) is a CPU cache that memory management hardware uses to improve virtual address translation speed. It was the first cache introduced in processors. All current desktop and server processors (such as x86) use a TLB. A TLB has a fixed number of slots that contain page table entries, which map virtual addresses to physical addresses. It is typically a content-addressable memory (CAM), in which the search key is the virtual address and the search result is a physical address.

    Also have a look at this.

提交回复
热议问题