并行处理与体系结构hitsz-lec08-review2.ppt

  1. 1、本文档共21页,可阅读全部内容。
  2. 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
  3. 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载
  4. 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
并行处理与体系结构hitsz-lec08-review2

* Memory Hierarchy Review 2 Outline 7.4 Virtual Memory Address Mapping Key Design Issues Page Table Page Faults Translation lookaside buffer (TLB) Protection with Virtual Memory 7.5 Common Framework Four question Miss rates with setassociative and cache size Three misses 7.6 Modern memory hierarchies 7.8 Concluding Remark 7.4 Virtual Memory Main memory can act as a cache for the secondary storage (disk) Motivation To allow efficient and safe sharing of memory among multiple programs. Allow a single user program to exceed the size of primary memory Previous solution: programmers divided programs into pieces, called overlays Advantages: illusion of having more physical memory program relocation protection 7.4 Address Mapping for Virtual Memory Virtual address Physical address Page : blocks of memory Page in disk 7.4 Mapping From Virtual to Physical Pages: virtual memory blocks Virtual address space=232 =4GB Physical address space=230=1GB 7.4 Key Design Issues in VM Pages should be large enough to amortize the high access time huge miss penalty, thus pages should be fairly large E.g 32-64KB pages Reduce the page fault rate full-associative placement Page fault penalty takes millions of cycles can handle the faults in software instead of hardware Use clever algorithm to replace pages while page faults occur. E.g. LRU (least recently used) Use write-back instead of write-through using write-through is too expensive so we use write-back 7.4 Page Tables Page tables are used to located pages by using a full table that indexes the memory Because full-associative placement to locate a entry is difficult Page tables are stored in main memory, each program has its own page table 7.4 Page Tables Page table is indexed with the virtual page number to obtain the corresponding portion of the physical address Example: Page size : 212 = 4 KB, number of page entry: 220 = 1 million entries Page entry only need 19 bits, other bits are used to store additional information,

文档评论(0)

wyjy + 关注
实名认证
内容提供者

该用户很懒,什么也没介绍

1亿VIP精品文档

相关文档