Segmented paging 和 Paged segmentation 的异同? [英] Differences or similarities between Segmented paging and Paged segmentation?

查看:32
本文介绍了Segmented paging 和 Paged segmentation 的异同?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在研究组合分页/分段系统,在我的书中有两种方法:

I was studying combined paging/segmentation systems and in my book there were two approaches to this :

1.paged segmentation
2.segmented paging

我无法区分两者之间的区别.我认为在分页分段中,段被分成页面,在分段分页中,页面被分成段,虽然我不知道我是对还是错.同时在互联网上,仅使用一种方案来描述组合的寻呼/分段.我不明白为什么在我的课本中有两种方案.任何帮助将不胜感激.

I could not make out the difference between the two. I think in paged segmentation the segment is divided into pages and in segmented paging the pages are divided into segments, though I don't know if I am right or wrong. Meanwhile on the internet the combined paging/segmentation is described using one scheme only. I can't figure out why in my coursebook there are two schemes for this. Any help would be deeply appreciated.

推荐答案

所以,在网上大力搜索这两个术语的异同后,我得出了一个最终的答案.首先我会写下来相似之处:

So,after vigorously searching on net for the difference or similarity between these two terms,I have come up on a final answer.First of all I would write down the similarities:

  • 它们(segmented paging和paged segmentation)都是一种paging/segmentation组合系统(Paging和Segmentation可以通过将每个segment分成页面来组合).
  • 在这两个系统中,段都分为页面.

现在要描述差异,我必须分别定义和描述每个术语:

Now to describe the differences I will have to define and describe each term separately:

  • Segmented paging-将Segment分页.实现需要STR(segment table register)和PMT(page map table).在该方案中,每个虚拟地址由一个段号组成,该段内的页号和该页内的偏移量.段号索引到段表中,该段表产生该段的页表的基地址.页号索引到页表中,每个条目是一个页框.加上PFN(页框号)和偏移量得到物理地址.因此寻址可以用以下函数描述:
  • Segmented paging- Segments are divided into pages.Implementation requires STR(segment table register) and PMT(page map table).In this scheme, each virtual address consists of a segment number, page number within that segment and an offset within that page.The segment number indexes into segment table which yields the base address of the page table for that segment.The page number indexes into the page table,each of which entry is a page frame.Adding the PFN(page frame number) and the offset results in the physical address.Hence addressing can be described by the following function :

va = (s,p,w) 其中,va 是虚拟地址,|s|确定数量段(ST 的大小),|p|确定每段的页数(大小PT), |w|确定页面大小.

va = (s,p,w) where, va is the virtual address, |s| determines number of segments (size of ST), |p| determines number of pages per segment (size of PT), |w| determines page size.

address_map(s, p, w)
{
pa = *(*(STR+s)+p)+w;
return pa;
}

图表在这里:

  • 分页分段- 有时段表或页表可能太大而无法保存在物理内存中(它们甚至可以达到 MB).因此,段表也分为页,因此页表的 ST 页被创建.segment number分为page no.(s1)page offset(s2)的ST pages的页表.所以,虚拟地址可以描述为:
  • Paged Segmentation- Sometimes segment table or page table may too large to keep in physical memory(they can even reach MBs).Therefore,the segment table is divided into pages too and thus a page table of ST pages is created. The segment number is broken into page no.(s1) and page offset(s2) of page table of ST pages.So,the virtual address can be described as :

va = (s1,s2,p,w)

address_map
(s1, s2, p, w)
{
pa = *(*(*(STR+s1)+s2)+p)+w;
return pa;
}

图表说明在这里:

这篇关于Segmented paging 和 Paged segmentation 的异同?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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