zoukankan      html  css  js  c++  java
  • Translation Lookaside Buffer

    COMPUTER ORGANIZATION AND ARCHITECTURE DESIGNING FOR PERFORMANCE NINTH EDITION

    In principle, then, every virtual memory reference can cause two physical mem-
    ory accesses: one to fetch the appropriate page table entry, and one to fetch the
    desired data. Thus, a straightforward virtual memory scheme would have the effect
    of doubling the memory access time. To overcome this problem, most virtual
    memory schemes make use of a special cache for page table entries, usually called
    a translation lookaside buffer (TLB). This cache functions in the same way as a
    memory cache and contains those page table entries that have been most recently
    used. Figure 8.18 is a flowchart that shows the use of the TLB. By the principle of
    locality, most virtual memory references will be to locations in recently used pages.
    Therefore, most references will involve page table entries in the cache. Studies of
    the VAX TLB have shown that this scheme can significantly improve performance
    [CLAR85, SATY81].

    Note that the virtual memory mechanism must interact with the cache system
    (not the TLB cache, but the main memory cache). This is illustrated in Figure 8.19.
    A virtual address will generally be in the form of a page number, offset. First, the
    memory system consults the TLB to see if the matching page table entry is present.
    If it is, the real (physical) address is generated by combining the frame number with
    the offset. If not, the entry is accessed from a page table. Once the real address is
    generated, which is in the form of a tag and a remainder, the cache is consulted to
    see if the block containing that word is present (see Figure 4.5). If so, it is returned
    to the processor. If not, the word is retrieved from main memory.

    The reader should be able to appreciate the complexity of the processor hard-
    ware involved in a single memory reference. The virtual address is translated into
    a real address. This involves reference to a page table, which may be in the TLB, in

    main memory, or on disk. The referenced word may be in cache, in main memory,
    or on disk. In the latter case, the page containing the word must be loaded into main
    memory and its block loaded into the cache. In addition, the page table entry for
    that page must be updated.

  • 相关阅读:
    Python3爬虫之爬取某一路径的所有html文件
    python获取数据网页数据并创建文件夹保存(基于python3.6)
    Python 爬取单个网页所需要加载的地址和CSS、JS文件地址
    java的关闭钩子(Shutdown Hook)
    如何形象的解释 webhook 这个词
    Webhook
    什么是webhook
    瞎折腾之Webhooks
    Java-马士兵设计模式学习笔记-观察者模式-读取properties文件,动态增加观察者
    怎么解决重装系统后“我的文档”拒绝访问(更改权限就可以了)
  • 原文地址:https://www.cnblogs.com/rsapaper/p/6216984.html
Copyright © 2011-2022 走看看