- 1、本文档共95页,可阅读全部内容。
- 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
- 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载。
- 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
作业 什么是内部碎片;什么是外部碎片 画出最基本的分页地址变换机构。 分页和分段的主要区别是什么? 页表存放在内存中 访问一个逻辑地址中的内容需要两次访问内存 第一次:页表项,进而转换成物理地址 第二次:对应物理地址中的内容 速度:CPU vs. 2倍访存 解决方案:高速缓存(块表,TLB)Translation Lookaside Buffer 基本的地址变换机构 Page table is kept in main memory, Table Base Register (PTBR) Points to the page table currently used table length register (PRLR) Indicates size of the page table Context switch + 3 b Effective memory-access time, time needed for every data/instruction access 需要2次访存 Access the page table Access the data/instruction Solution: A special fast-lookup hardware cache called associative registers or translation look-aside buffers (TLBs) 联想存储器,快表 Associative registers Each register : a key a value Parallel search (high speed) Expensive, typically 8~2048 entries Address translation (A′, A′′) If A′ is in associative register, get frame # out. Otherwise get frame # from page table in memory 联想存储器,快表 TLB miss(TLB缺失) If the page number is not in the associative registers Get store Hit ratio(命中率) The percentage of times that a page number is found in the associative registers Context switch ? TLB flushed TLB replacement algorithm 具有块表的地址变换机构 + Effective Access Time 有效存取时间 设: Associative Lookup = ? time unit;memory cycle time = t time unit;Hit ratio = ? Effective Access Time (EAT) EAT = (t + ?) ? + (2t + ?)(1 – ?) = 2t + ? – t? If ?(20 ns), t(100 ns), ?1(80%), ?2(98%): TLB hit: 20+100=120 ns TLB miss: 20+100+100=220 ns EAT1 = 120*0.8 + 220 * 0.2 = 140 ns EAT2 = 120*0.98 + 220 * 0.02 = 122 ns 思考 从页表中读取数据的时间开销是5ns,从块表中读取数据的开销则是1ns,为使平均开销降为1ns,则块表的命中率至少为多少? Memory Protection 内存保护 If page size 2n, page frame is aligned at 2n, so … Memory protection implemented by associating protection bit with each frame Provide read only, read-write, execute-only protection or… Valid-invalid “valid”: the associated page is in the process’ logical address space, and is thus a legal page. “invalid”: the page is not in the process’ logical address space. Valid/invalid bit example Address
您可能关注的文档
- VC++第一章.ppt
- VC++语言基础之一.ppt
- VELOG PMP方案.ppt
- VerilogHDL实验内容.ppt
- Visual Fortran90第8章.ppt
- WCB水冷却盘式刹车常见故障分析和维修.ppt
- webinfoDB设计简介.ppt
- WH500209 UMG8900系统备份与恢复 ISSUE1.0.ppt
- Win2003_TPCHAP7灾难恢复.ppt
- Windows 2000操作系统概述.ppt
- 2024年沧州市公务员考试行测真题及答案详解(名师系列).docx
- 粮油食品检验人员复习提分资料带答案详解(精练).docx
- 粮油食品检验人员自我提分评估(考点精练)附答案详解.docx
- 粮油食品检验人员全真模拟模拟题附参考答案详解(精练).docx
- 2025年延安市公务员考试行测试卷历年真题附答案详解(突破训练).docx
- 2025年株洲市公务员考试行测试卷历年真题含答案详解.docx
- 2024年枣庄市公务员考试行测真题及完整答案详解1套.docx
- 2024年抚顺市公务员考试行测真题及答案详解(各地真题).docx
- 2025年常州市公务员考试行测真题及一套参考答案详解.docx
- 2023年德州市公务员考试行测试卷历年真题及1套完整答案详解.docx
文档评论(0)