计算页面大小和段大小 [英] calculating page size and segment size

查看:34
本文介绍了计算页面大小和段大小的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在分页分段系统中,我们有 32 位的虚拟地址和 12 位的偏移量、11 位的段和 9 位的页码.我们如何计算页面大小、最大段大小和最大段数段大小?

in a paged-segmented system we have the virtual address of 32 bits and 12 bits for the offset,11 bits for segment and 9 bits for page number.the how can we calculate the page size ,maximum segment size and maximum number of segment size?

推荐答案

  • 12 位保留用于偏移量,因此页面大小为 2^12 = 4KB
  • 为页码保留 9 位,因此每个段可以包含 2^9 = 512 页
  • 每个段可以增长到 (# of pages) * (pages size),因此最大段大小为 512 * 4K = 2M
  • 欲了解更多信息,请参见 http://www.cs.umass.edu/~weems/CmpSci535/Discussion21.html

    For more information see http://www.cs.umass.edu/~weems/CmpSci535/Discussion21.html

    这篇关于计算页面大小和段大小的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆