【问题标题】:(Operating System) Calculate page number and page offset(操作系统)计算页码和页偏移量
【发布时间】:2021-07-03 18:35:37
【问题描述】:

给定页面大小为4KB,求该地址的页码和页偏移量(十进制提供)21235。

偏移量为 21235 / (4*2^10) = 5.xxx => 5

页码为 21235 % (4*2^10) = 755

我想知道对此的解释?我知道数字但不知道解释

谢谢大家!

【问题讨论】:

  • 你能详细说明一下你理解的翻译度是什么意思吗?
  • @wxz 这是页面偏移量,对不起

标签: memory-management system paging explain


【解决方案1】:

更新

本例中页码 = 逻辑地址 / 页大小为 21205 / 1024 = 20

Offset = 逻辑地址 mod page size 在这种情况下是 21205 mod 1024 = 725

来源:

http://www.yorku.ca/pkashiya/cse1520/Paged%20memory%20technique.htmhttp://www2.cs.uregina.ca/~hamilton/courses/330/notes/memory/paging.html

Meta 上的帖子:

https://cs.stackexchange.com/questions/124826/determine-page-number-and-offsets-for-address-references/142321#142321

【讨论】:

猜你喜欢
  • 2013-03-15
  • 2013-08-24
  • 2021-10-14
  • 2011-04-01
  • 2015-03-15
  • 2014-01-03
  • 1970-01-01
  • 2017-03-21
  • 1970-01-01
相关资源
最近更新 更多