JP2000181799A - Dynamic address conversion method and processor - Google Patents

Dynamic address conversion method and processor

Info

Publication number
JP2000181799A
JP2000181799A JP10361028A JP36102898A JP2000181799A JP 2000181799 A JP2000181799 A JP 2000181799A JP 10361028 A JP10361028 A JP 10361028A JP 36102898 A JP36102898 A JP 36102898A JP 2000181799 A JP2000181799 A JP 2000181799A
Authority
JP
Japan
Prior art keywords
address
extended
page table
page
tlb
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP10361028A
Other languages
Japanese (ja)
Inventor
Wataru Yamamoto
渉 山元
Toshihiko Kurihara
俊彦 栗原
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hitachi Ltd
Original Assignee
Hitachi Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hitachi Ltd filed Critical Hitachi Ltd
Priority to JP10361028A priority Critical patent/JP2000181799A/en
Publication of JP2000181799A publication Critical patent/JP2000181799A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/08Addressing or allocation; Relocation in hierarchically structured memory systems, e.g. virtual memory systems
    • G06F12/10Address translation
    • G06F12/1027Address translation using associative or pseudo-associative address translation means, e.g. translation look-aside buffer [TLB]
    • G06F12/1036Address translation using associative or pseudo-associative address translation means, e.g. translation look-aside buffer [TLB] for multiple virtual address spaces, e.g. segmentation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/65Details of virtual memory and virtual address translation
    • G06F2212/652Page size control

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Memory System Of A Hierarchy Structure (AREA)

Abstract

PROBLEM TO BE SOLVED: To realize address conversion in an optimum page size and to reduce a TLB(translation look aside buffer) error rate for plural programs having contrary requests on the page size. SOLUTION: Mapping units from a virtual address to a real address are set to be a page size and an extension page size. An address conversion mechanism 102 by a page table and TLB and an address conversion mechanism 103 by an extension page table and extension TLB are installed. The two conversion mechanisms 102 and 103 are simultaneously executed and a final real address is obtained from a side where conversion succeeds.

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】本発明は、仮想記憶方式を採
用したコンピュータシステムに係り、特に、複数のペー
ジサイズを同時にサポートする動的アドレス変換方法及
び該アドレス変換方法を適用したプロセッサに関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a computer system employing a virtual memory system, and more particularly, to a dynamic address translation method that simultaneously supports a plurality of page sizes and a processor to which the address translation method is applied.

【0002】[0002]

【従来の技術】多くのコンピュータシステムでは仮想記
憶(Virtual Memory/Storage)方式が採用されてい
る。仮想記憶方式は、主記憶装置の容量不足を補助記憶
装置/外部記憶装置との置換えにより補い、同時に実行
される複数のプログラムの各々に対してメモリ空間を矛
盾なく割当てるためには必須の技術である。
2. Description of the Related Art Many computer systems employ a virtual memory / storage system. The virtual storage method is an indispensable technique for compensating for the lack of capacity of the main storage device by replacing it with an auxiliary storage device / external storage device and allocating a memory space to each of a plurality of programs executed simultaneously without inconsistency. is there.

【0003】仮想記憶方式では、ユーザのプログラムに
対して仮想アドレス空間を提供し、OSが仮想アドレス
空間から実アドレス空間へのマッピングを管理する。仮
想アドレスから実アドレスへのマッピング情報は、通
常、主記憶上に配置されたページテーブルに保持されて
いる。
In the virtual storage system, a virtual address space is provided to a user program, and the OS manages mapping from the virtual address space to the real address space. The mapping information from the virtual address to the real address is normally held in a page table arranged on the main storage.

【0004】動的アドレス変換では、命令実行中に命令
フェッチ、ロード・ストア命令などによりアクセスする
実アドレスを計算するために、ページテーブルの情報を
参照する。しかし、各命令を実行する度にページテーブ
ルを参照していたのでは、主記憶へのアクセスが各命令
ごとに発生してしまい、実用的な時間内で命令を実行で
きない。
In the dynamic address translation, information of a page table is referred to in order to calculate a real address to be accessed by an instruction fetch, a load / store instruction or the like during the execution of an instruction. However, if the page table is referenced every time each instruction is executed, access to the main memory occurs for each instruction, and the instruction cannot be executed within a practical time.

【0005】そこで、高速小容量のリソースをCPU側
に用意し、アドレス変換のために主記憶のページテーブ
ルから読み出したマッピング情報を保持し、後続命令で
同じページに再びアクセスした場合は、リソースの情報
を再利用する方式が一般に用いられている。このリソー
スをTLB(Translation Lookaside Buffer)と呼
ぶ。TLBが有効な手段となる理由は、プログラムのメ
モリアクセスには局所性(Locality)の性質があり、
一度利用したマッピング情報は再び利用されることが多
いためである。
Therefore, a high-speed, small-capacity resource is prepared on the CPU side, the mapping information read from the page table of the main memory is held for address conversion, and when the same page is accessed again by a subsequent instruction, the resource is rewritten. A method of reusing information is generally used. This resource is called a TLB (Translation Lookaside Buffer). The reason that the TLB is an effective means is that the memory access of a program has the property of locality (Locity),
This is because the mapping information used once is often used again.

【0006】TLBは動的アドレス変換実現する上での
一機構であり、アドレス変換の論理的な機能という観点
からは必ずしも必要ではないが、TLBがなければ処理
性能が極めて劣ったものとなり無意味なものとなってし
まう。いいかえると、TLBの存在を前提としてはじめ
て動的アドレス変換は意味をもったものとなる。
The TLB is a mechanism for realizing the dynamic address translation, and is not necessarily required from the viewpoint of the logical function of the address translation. However, without the TLB, the processing performance is extremely poor and is meaningless. It will be something. In other words, the dynamic address translation becomes meaningful only on the premise of the existence of the TLB.

【0007】[0007]

【発明が解決しようとする課題】一回のメモリアクセス
についてアドレス変換のマッピング情報がTLBから得
られない割合をTLBミス率という。通常、TLBのエ
ントリ数が256以上であれば、TLBミス率は1%以
下であるといわれている。ところが、大規模科学計算の
ように膨大なデータを処理するプログラムにおいては、
メモリアクセスの局所性が必ずしも保証されず、TLB
の有効性の大前提が成り立たない場合もある。
The rate at which mapping information for address conversion cannot be obtained from the TLB for one memory access is called a TLB miss rate. Usually, if the number of entries in the TLB is 256 or more, it is said that the TLB miss rate is 1% or less. However, in programs that process huge amounts of data, such as large-scale scientific calculations,
Locality of memory access is not always guaranteed, and TLB
In some cases, the basic premise of the effectiveness of does not hold.

【0008】TLBからアドレス変換の情報(マッピン
グ情報)が得られない場合、主記憶からページテーブル
を読み出し、TLBに情報を登録しなければならない。
主記憶からページテーブルを読み出す際には、命令パイ
プラインは当然のことながら停止しなければならず、ア
ーキテクチャによっては割込みが必要になる場合もあ
る。したがって、性能の観点から無視できないペナルテ
ィが伴うため、TLBミス率を低減することは重要な問
題である。
When the address translation information (mapping information) cannot be obtained from the TLB, the page table must be read from the main memory and the information must be registered in the TLB.
When reading the page table from the main memory, the instruction pipeline must be stopped naturally, and an interrupt may be required depending on the architecture. Therefore, there is a penalty that cannot be ignored from a performance point of view, so reducing the TLB miss rate is an important issue.

【0009】TLBミス率は、ページサイズと関連が深
い。たとえば、プログラムが連続する8Kバイトの領域
をアクセスする場合、ページサイズが4Kバイトならば
2ページ必要だが、ページサイズを8Kバイトとするな
ら1ページしか必要としない。ページサイズを大きく
し、必要となるページ数をより少なくすれば、必要なマ
ッピング情報がTLBに格納されている確率も高くな
り、TLBミス率を低減できる。一方、ページサイズを
大きく設定すると、プログラムが利用しない無駄な領域
の割当てがより多く発生し、さらには、主記憶と外部記
憶装置間のページ転送に余計な時間がかかるといったデ
メリットが発生する。したがって、やみくもにページサ
イズを大きくすることはできないため、最適なページサ
イズを決定し、TLBミス率を低減するのは難しい問題
である。
The TLB miss rate is closely related to the page size. For example, when a program accesses a continuous area of 8 Kbytes, two pages are required if the page size is 4 Kbytes, but only one page is required if the page size is 8 Kbytes. If the page size is increased and the number of required pages is reduced, the probability that required mapping information is stored in the TLB increases, and the TLB miss rate can be reduced. On the other hand, when the page size is set to be large, there is a disadvantage that more useless areas are allocated that are not used by the program, and furthermore, extra time is required for page transfer between the main storage and the external storage device. Therefore, since the page size cannot be blindly increased, it is difficult to determine the optimum page size and reduce the TLB miss rate.

【0010】本発明の目的は、仮想アドレスを実アドレ
スに変換する機構を備えたプロセッサにおいて、それぞ
れのプログラムに対して最適なページサイズによるアド
レス変換を可能とし、TLBミス率を低減することにあ
る。
An object of the present invention is to enable a processor having a mechanism for converting a virtual address to a real address to perform address conversion with an optimum page size for each program and reduce the TLB miss rate. .

【0011】[0011]

【課題を解決するための手段】本発明では、複数のペー
ジサイズを同時に扱える動的アドレス変換手段を提供す
る。具体的には、仮想アドレスから実アドレスへのマッ
ピング単位を標準のページサイズと拡張ページサイズの
複数とし、標準のページサイズのマッピングを定義した
ページテーブルと、該ページテーブルのマッピング情報
のコピーを保持するTLBと、命令実行時にTLB、ペ
ージテーブルに従い仮想アドレスを実アドレスに変換す
る手段からなるアドレス変換機構と、拡張ページサイズ
のマッピングを定義した拡張ページテーブルと、該拡張
ページテーブルのマッピング情報のコピーを保持する拡
張TLBと、命令実行時に拡張TLB、拡張ページテー
ブルに従い仮想アドレスを実アドレスに変換する手段か
らなるアドレス変換機構とを設ける。
SUMMARY OF THE INVENTION The present invention provides a dynamic address translation means capable of simultaneously handling a plurality of page sizes. Specifically, the mapping unit from the virtual address to the real address is set to a plurality of the standard page size and the extended page size, and a page table defining the mapping of the standard page size and a copy of the mapping information of the page table are held. TLB to be executed, an address translation mechanism comprising means for translating a virtual address into a real address according to the TLB and the page table when executing an instruction, an extended page table defining an extended page size mapping, and a copy of mapping information of the extended page table And an address translation mechanism comprising means for translating a virtual address into a real address according to the extended TLB and the extended page table when executing an instruction.

【0012】本発明によれば、ページサイズの異なる複
数のマッピング情報を互いに独立した複数のアドレス変
換機構で個別に扱うことにより、複数のページサイズを
同時に扱うアドレス変換が可能となる。したがって、例
えばメモリアクセスの局所性が高いプログラムの実行に
はより小さいページサイズ(拡張ページサイズ)を利用
し、大規模なメモリ領域を利用するプログラムについて
はより大きいページサイズを利用することで、ページサ
イズを大きくすることによるデメリットを抑えつつ、T
LBミス率を低減することが可能となる。
According to the present invention, a plurality of mapping information items having different page sizes are individually handled by a plurality of address conversion mechanisms independent of each other, thereby enabling address conversion for simultaneously handling a plurality of page sizes. Therefore, for example, a smaller page size (extended page size) is used for executing a program having high locality of memory access, and a larger page size is used for a program using a large-scale memory area. While suppressing the disadvantages of increasing the size,
The LB miss rate can be reduced.

【0013】さらに、拡張ページサイズを複数のサイズ
から選択することにより、より細かいチューニングが可
能となる。また、一方のアドレス変換機構を無効に設定
することにより、一つのページサイズで十分な場合にシ
ステム設定を簡略にすることも可能である。
Further, by selecting the extension page size from a plurality of sizes, finer tuning is possible. Further, by setting one of the address translation mechanisms to invalid, it is possible to simplify the system setting when one page size is sufficient.

【0014】[0014]

【発明の実施の形態】図1は、本発明に基づき仮想アド
レスを実アドレスに変換するための概念図を示す。図1
に示すように、仮想アドレス101は、ページテーブル
およびTLBによるアドレス変換機構102の変換結
果、および、拡張ページテーブルおよび拡張ページテー
ブルによるアドレス変換機構103の変換結果を、セレ
クタ104により選択することで、実アドレス105に
変換される。セレクタ104は変換に成功した側の結果
を選択するが、両方が成功する場合にはアドレス変換機
構102の結果を選択する。
DESCRIPTION OF THE PREFERRED EMBODIMENTS FIG. 1 shows a conceptual diagram for converting a virtual address to a real address according to the present invention. FIG.
As shown in FIG. 5, the selector 104 selects the virtual address 101 by selecting the conversion result of the address conversion mechanism 102 using the page table and the TLB, and the conversion result of the address conversion mechanism 103 using the extended page table and the extended page table. It is converted to a real address 105. The selector 104 selects the result on the side where the translation is successful, but if both succeed, the result of the address translation mechanism 102 is selected.

【0015】アドレス変換機構102、103では、ま
ず、TLBおよび拡張TLBでアドレス変換を行い、両
方でアドレス変換に失敗した場合、ページテーブルおよ
び拡張テーブルを用いてアドレス変換を行う。テーブル
を検索する順序は、ページテーブル、拡張ページテーブ
ルの順番とする。また、ページテーブルがアドレス変換
に利用された場合は、該ページテーブルの参照/変更履
歴を更新し、拡張ページテーブルがアドレス変換に利用
された場合は、該拡張ページテーブルの参照/変更履歴
を更新する。システムは、アドレス変換機構102ある
いは103をそれぞれ有効/無効に設定する機能を備え
る。
In the address conversion mechanisms 102 and 103, first, the address conversion is performed in the TLB and the extended TLB, and if the address conversion fails in both, the address conversion is performed using the page table and the extended table. The order of searching the tables is the order of the page table and the extended page table. When the page table is used for address translation, the reference / change history of the page table is updated. When the extended page table is used for address translation, the reference / change history of the extended page table is updated. I do. The system has a function of setting the address translation mechanism 102 or 103 to valid / invalid.

【0016】次に、本発明によるアドレス変換の詳細を
実施例により説明する。なお、実施例では仮想アドレ
ス、実アドレスともに64ビットであるとする。
Next, details of the address conversion according to the present invention will be described with reference to an embodiment. In the embodiment, it is assumed that both the virtual address and the real address are 64 bits.

【0017】図2は、ページテーブルによるアドレス変
換の過程を示している。本実施例では、標準のページサ
イズは4Kバイトである。仮想アドレス201は、変換
の対象となる52ビットの仮想ページ番号(VPN)2
01aと、変換の対象にならない12ビットのオフセッ
ト201bからなる。実アドレス202は、52ビット
の実ページ番号(RPN)202aと12ビットのオフ
セット202bからなる。オフセットはアドレス変換の
対象とならない部分であるため、201bと202bは
等しい。
FIG. 2 shows a process of address conversion by a page table. In this embodiment, the standard page size is 4 Kbytes. The virtual address 201 is a 52-bit virtual page number (VPN) 2 to be converted.
01a and a 12-bit offset 201b that is not subject to conversion. The real address 202 includes a 52-bit real page number (RPN) 202a and a 12-bit offset 202b. Since the offset is a part that is not subject to address translation, 201b and 202b are equal.

【0018】ページテーブル203の大きさは256K
バイトである。その先頭アドレスは2の18乗の整数倍
である。ページテーブル203は、128バイトの領域
であるページテーブルエントリグループ(PTEG)が
2048個(PTEG0〜PTEG2047)、縦方向
に連続して並んだ構成になっている。各ページテーブル
エントリグループは、16バイトの領域であるページエ
ントリ(PTE)が8個(PTE0〜PTE7)、横方
向に連続して並ぶ構成になっている。
The size of the page table 203 is 256K
Bytes. The start address is an integral multiple of 2 to the 18th power. The page table 203 has a configuration in which 2048 page table entry groups (PTEGs) each of which is a 128-byte area (PTEG0 to PTEG2047) are arranged continuously in the vertical direction. Each page table entry group has a configuration in which eight page entries (PTE), which are 16-byte areas, are arranged in a row in the horizontal direction (PTE0 to PTE7).

【0019】一つのページテーブルエントリ204は、
16バイトが8バイトずつ仮想アドレス側と実アドレス
側に2分されて、アドレス変換に必要な情報が格納され
ている。204aは仮想ページ番号VPNを、204b
はリザーブフィールド(Reserved Field)を、204
cはエントリの内容が有効であることを示すバリッドV
を表わし、また、204dは実ページ番号RPNを、2
04eはリザーブフィールドを、206fはページ保護
情報、参照履歴、変更履歴などの付随情報を表す。リザ
ーブフィールド204b、204eは現在は使用されて
いないが、将来なんらかの意味を割当てられるかもしれ
ないフィールドである。フィールド206fのページ保
護情報はOSのシステム管理データなどを格納したペー
ジについて、ユーザプログラムからのアクセスを禁止す
るなどの目的で使用する情報である。参照履歴は当該ペ
ージに対するアクセスがあったことを示す情報であり、
主記憶からページアウトする対象をOSが決定するなど
の目的に利用される情報である。変更履歴は当該ページ
がストア命令によりアクセスされたことを示す情報であ
り、主記憶からページアウトする場合に外部記憶装置へ
のデータ転送が必要になることをOSが判断するなどの
目的に利用される情報である。
One page table entry 204 is
The 16 bytes are divided into a virtual address side and a real address side by 8 bytes at a time, and information necessary for address conversion is stored. 204a is a virtual page number VPN, 204b
Is the Reserved Field, 204
c is a valid V indicating that the contents of the entry are valid
204d represents the real page number RPN as 2
04e indicates a reserve field, and 206f indicates accompanying information such as page protection information, reference history, and change history. Reserved fields 204b and 204e are fields that are not currently used but may be assigned some meaning in the future. The page protection information in the field 206f is information used for the purpose of, for example, prohibiting access from a user program to a page storing OS system management data and the like. The reference history is information indicating that the page has been accessed,
This information is used for the purpose of, for example, determining the target of page-out from the main memory by the OS. The change history is information indicating that the page has been accessed by a store instruction, and is used for the purpose of, for example, the OS determining that data transfer to an external storage device is required when page-out from the main memory. Information.

【0020】アドレス変換が成功する条件は、仮想アド
レス201のVPN201aとページテーブルエントリ
204のVPN204aが等しく、かつ、バリッドV2
04cが1であるようなエントリの検索に成功すること
である。この場合、仮想アドレス201のVPN201
aが当該ページテーブルエントリ204のRPN204
dに置換えられることにより実アドレス202のRPN
202aが得られ、フィールド204fによりページ保
護などの付随情報が得られる。実アドレス202のオフ
セット202bには、仮想アドレス201のオフセット
201bがそのまま設定される。
The condition that the address conversion is successful is that the VPN 201a of the virtual address 201 is equal to the VPN 204a of the page table entry 204 and the valid V2
That is, a search for an entry whose 04c is 1 is successful. In this case, the VPN 201 of the virtual address 201
a is the RPN 204 of the page table entry 204
d to replace the RPN of the real address 202
202a is obtained, and accompanying information such as page protection is obtained by the field 204f. As the offset 202b of the real address 202, the offset 201b of the virtual address 201 is set as it is.

【0021】ストレージディスクリプションレジスタ1
(SDR1)205は、8バイト幅のレジスタであり、
205aで示したページテーブル203の先頭アドレス
を示す46ビットのフィールド(HTABORG)と、
205bで示したリザーブフィールドからなる。このS
DR(1)205は、制御レジスタの一つとしてあらか
じめCPUに用意されるものである。
Storage description register 1
(SDR1) 205 is an 8-byte width register,
A 46-bit field (HTABORG) indicating the head address of the page table 203 indicated by 205a;
It comprises a reserved field indicated by 205b. This S
DR (1) 205 is prepared in the CPU in advance as one of the control registers.

【0022】ページテーブル参照アドレス206は、ペ
ージテーブル203の検索対象となるページテーブルエ
ントリの参照アドレスである。206aで示す先頭の4
6ビットには、SDR(1)のHTABORG205a
が設定され、次の206bで示す11ビットには、仮想
アドレス201のVPN201中のLSB側11ビット
201が設定される。この206aと206bの57ビ
ットの値で、ページテーブル203のページテーブルエ
ントリグループの先頭アドレスを示す。例えば、201
cがオール0ならばフィールド206bもオール0であ
り、203a0で示したPTEG0が指定されたことに
なる。206cで示す7ビットは、当該ページテーブル
エントリグループ内のページテーブルエントリを示す。
The page table reference address 206 is a reference address of a page table entry to be searched in the page table 203. The first 4 indicated by 206a
Six bits include HTABORG 205a of SDR (1).
Is set, and in the next 11 bits indicated by 206 b, the LSB side 11 bits 201 in the VPN 201 of the virtual address 201 are set. The 57-bit values 206a and 206b indicate the head address of the page table entry group of the page table 203. For example, 201
If c is all 0, the field 206b is also all 0, meaning that PTEG0 indicated by 203a0 has been designated. The 7 bits 206c indicate a page table entry in the page table entry group.

【0023】ページテーブル検索処理においては、ま
ず、SDR(1)205のフィールド205a、仮想ア
ドレス201のVPNの201cで示すLSB側11ビ
ットを、ページテーブル参照アドレス206のフィール
ド206aと206bに設定し、フィールド206cに
は初期値としてオール0を設定して、ページテーブル2
03の該当ページテーブルエントリグループ(PTE
G)の先頭アドレスを求める。次に、該ページテーブル
エントリグループに含まれるページテーブルエントリ
(PTE)を逐次参照し、アドレス変換の成功条件を満
たすエントリであるかどうかをチェックする。すなわ
ち、ページテーブル参照アドレス206の下位アドレス
204cを16バイトずつインクリメントし、各エント
リを読み出しながら前記のチェックを適用し、該当する
エントリが見つかれば、その時点でアドレス変換成功と
なる。
In the page table search process, first, the field 205a of the SDR (1) 205 and the LSB side 11 bits indicated by the VPN 201c of the virtual address 201 are set in the fields 206a and 206b of the page table reference address 206. All 0 is set as an initial value in the field 206c, and the page table 2
03 corresponding page table entry group (PTE
G) Find the start address. Next, the page table entry (PTE) included in the page table entry group is sequentially referred to, and it is checked whether the entry satisfies the condition for successful address translation. That is, the lower address 204c of the page table reference address 206 is incremented by 16 bytes, and the above check is applied while reading each entry. If the corresponding entry is found, the address conversion is successful at that point.

【0024】もし、複数のエントリが該当する場合は最
初に検索されるエントリ、すなわち、メモリの上位に配
置されたエントリがヒットし、もう一方のエントリは無
視される。したがって、OSおよびソフトウェアでは該
当するエントリが唯一になるように設定するべきであ
る。アドレス変換の対象となったページがアクセスをさ
れた場合は、該当ページエントリ204のフィールド2
04fに含まれる参照履歴を更新し、さらに、アクセス
がストア命令による場合は該フィールド204fに含ま
れる変更履歴を更新する。
If a plurality of entries are applicable, the first searched entry, that is, the entry located in the upper part of the memory hits, and the other entry is ignored. Therefore, the OS and software should be set so that the corresponding entry is unique. If the page subjected to the address translation is accessed, field 2 of the corresponding page entry 204
The reference history contained in the field 204f is updated, and when the access is made by a store instruction, the change history contained in the field 204f is updated.

【0025】図3は、拡張ページテーブルによるアドレ
ス変換の過程を示している。本実施例において、拡張ペ
ージテーブルのページサイズは16M〜128Mバイト
可変であるとする。ページサイズの指定方法は後述す
る。
FIG. 3 shows a process of address conversion by the extended page table. In the present embodiment, it is assumed that the page size of the extended page table is variable from 16M to 128M bytes. The method for specifying the page size will be described later.

【0026】仮想アドレス301は、変換の対象となる
40〜37ビットの拡張仮想ページ番号(XVPN)3
03aと、12〜15ビットの拡張オフセット301d
と、12ビットのオフセット(標準オフセット)301
bからなる。フィールド303a、303cのビット幅
は、拡張するページサイズに従い可変であり、本実施例
では、(ページサイズ、XVPNのビット幅、拡張オフ
セットのビット幅)の関係は、(16Mバイト、40、
12)、(32Mバイト、41、11)、(64Mバイ
ト、42、10)、(128Mバイト、43、9)とな
る。実アドレス302は、仮想アドレス301のフィー
ルド301aと同じビット幅の拡張実ページ番号(XR
PN)301a、仮想アドレス301のフィールド30
1bおよび301dとビット幅および値ともに等しいオ
フセット302bおよび302cからなる。すなわち、
仮想アドレス301の拡張オフセット301dとオフセ
ット301bがそのまま実アドレス302の拡張オフセ
ット302cとオフセット302bに設定される。
The virtual address 301 is an extended virtual page number (XVPN) 3 of 40 to 37 bits to be converted.
03a and an extended offset 301d of 12 to 15 bits
And a 12-bit offset (standard offset) 301
b. The bit widths of the fields 303a and 303c are variable according to the page size to be extended. In this embodiment, the relationship between (page size, XVPN bit width, and extension offset bit width) is (16 Mbytes, 40,
12), (32 Mbytes, 41, 11), (64 Mbytes, 42, 10), and (128 Mbytes, 43, 9). The real address 302 is an extended real page number (XR) having the same bit width as the field 301a of the virtual address 301.
PN) 301a, field 30 of virtual address 301
The offsets 302b and 302c have the same bit width and value as 1b and 301d. That is,
The extended offset 301d and the offset 301b of the virtual address 301 are set as the extended offset 302c and the offset 302b of the real address 302 as they are.

【0027】拡張ページテーブル303の大きさは、図
2のページテーブル202と同じく256Kバイトであ
る。その先頭アドレスは2の18乗の整数倍である。拡
張ページテーブル303は、128バイトの領域である
拡張ページテーブルエントリグループ(XTEG)が2
048個(XTEG0〜XTEG2047)、縦方向に
連続して並んだ構成になっている。各拡張ページテーブ
ルエントリグループは、16バイトの領域である拡張ペ
ージエントリ(XTE)が8個(XTE0〜XTE
7)、横方向連続して並ぶ構成になっている。
The size of the extended page table 303 is 256 Kbytes, similar to the page table 202 of FIG. The start address is an integral multiple of 2 to the 18th power. The extended page table 303 has an extended page table entry group (XTEG) of 128 bytes,
048 pieces (XTEG0 to XTEG2047) are arranged continuously in the vertical direction. Each extended page table entry group has eight extended page entries (XTE), which are 16-byte areas (XTE0 to XTE).
7), they are arranged continuously in the horizontal direction.

【0028】一つの拡張ページテーブルエントリ304
は、16バイトが仮想アドレス側と実アドレス側に2分
されて、アドレス変換に必要な情報が格納されている。
304aは拡張仮想ページ番号XVPNを、304bは
リザーブフィールドを、304cはバリッドVを表わ
し、また、304dは拡張実ページ番号XRPNを、3
04eはリザーブフィールドを、306fはページ保護
情報、参照履歴、変更履歴などの付随情報を表す。ペー
ジサイズに従い、XVPN304aの下位mビットは任
意の値でよく、XRPN304dの下位mビットは0で
なければならない。ここで、(ページサイズ,m)は
(16Mバイト,0)、(32Mバイト,1)、(64M
バイト,2)、(128Mバイト,3)という関係にな
っている。
One extended page table entry 304
In the example, 16 bytes are divided into a virtual address side and a real address side, and information necessary for address conversion is stored.
304a represents an extended virtual page number XVPN, 304b represents a reserved field, 304c represents valid V, and 304d represents an extended actual page number XRPN.
04e indicates a reserve field, and 306f indicates accompanying information such as page protection information, reference history, and change history. According to the page size, the lower m bits of the XVPN 304a may be any value, and the lower m bits of the XRPN 304d must be zero. Here, (page size, m) is (16 Mbytes, 0), (32 Mbytes, 1), (64 Mbytes, 1)
Byte, 2), (128 Mbytes, 3).

【0029】アドレス変換が成功する条件は、仮想アド
レス301のXVPN301aと拡張ページテーブルエ
ントリ304のXVPN304aの上位nビットが等し
く、かつ、バリッドV304cが1であるようなエント
リの検索に成功することである。ここで、(ページサイ
ズ,n)は(16Mバイト,40)、(32Mバイト,
39)、(64Mバイト,38)、(128Mバイト,
37)という関係になっている。アドレス変換が成功す
ると、仮想アドレス301のXVPN301aが当該拡
張ページテーブルエントリ304のXRPN304dに
置換えられることにより実アドレス302のXRPN3
02aが得られ、フィールド304fによりページ保護
などの付随情報が得られる。実アドレス302の拡張オ
フセット302cとオフセット302bには、仮想アド
レス301の拡張オフセット301bとオフセット30
1bがそのまま設定される。
The condition for successful address translation is that the search for an entry in which the upper n bits of the XVPN 301a of the virtual address 301 and the XVPN 304a of the extended page table entry 304 are equal and the valid V304c is 1 is successful. . Here, (page size, n) is (16 Mbytes, 40), (32 Mbytes,
39), (64 Mbytes, 38), (128 Mbytes,
37). If the address conversion is successful, the XRPN 301a of the virtual address 301 is replaced with the XRPN 304d of the extended page table entry 304, and the XRPN3 of the real address 302 is replaced.
02a is obtained, and accompanying information such as page protection is obtained by the field 304f. The extended offset 302c and the offset 302b of the real address 302 correspond to the extended offset 301b and the offset 30 of the virtual address 301, respectively.
1b is set as it is.

【0030】ストレージディスクリプションレジスタ2
(SDR2)305は、8バイト幅のレジスタであり、
305aの46ビットのフィールド(XTABOR
G)、305bのリザーブフィールド、305cの2ビ
ットのフィールド(PS)、303dのバリッド(V)
からなる。XTABORGフィールド305aは拡張ペ
ージテーブル303の先頭アドレス、PSはフィールド
305cページサイズの種類、Vビット303dは拡張
ページテーブル303によるアドレス変換が有効/無効
であることを表す。本実施例では、PSフィールド30
5cが表すページサイズの種類については、(PS,ペ
ージサイズ)の関係を(00”,16Mバイト)、(”
01”,32Mバイト)、(”10”,64Mバイ
ト)、(”11”,128Mバイト)とする。このSD
R(2)305は、図2のSDR(1)205と同様
に、制御レジスタの一つとしてあらかじめCPUに用意
されるものである。
Storage description register 2
(SDR2) 305 is an 8-byte width register,
305a 46-bit field (XTABOR
G), reserved field of 305b, 2-bit field (PS) of 305c, valid (V) of 303d
Consists of The XTABORG field 305a indicates the start address of the extension page table 303, the PS indicates the type of page size in the field 305c, and the V bit 303d indicates that address conversion by the extension page table 303 is valid / invalid. In this embodiment, the PS field 30
Regarding the type of page size represented by 5c, the relationship of (PS, page size) is represented by (00 ", 16 Mbytes), ("
01 ", 32 Mbytes), (" 10 ", 64 Mbytes), (" 11 ", 128 Mbytes).
R (2) 305 is prepared in advance in the CPU as one of the control registers, similarly to SDR (1) 205 in FIG.

【0031】拡張ページテーブル参照アドレス306
は、拡張ページテーブル303の検索対象となるページ
テーブルエントリの参照アドレスを示す。306aで示
す先頭の46ビットには、SDR(2)305のXTA
BORG305aが設定され、次の306bで示す11
ビットには、仮想アドレス301のXVPN中のLSB
側11ビット301cが設定される。この306aと3
06bの57ビットのLSB側11ビット301cが設
定される。この306aと306bの57ビットの値
で、拡張ページテーブル303のエントリグループ(X
TEG)の先頭アドレスを示す。例えば、仮想アドレス
301内のビット301cがオール0ならば、拡張ペー
ジテーブル参照アドレス306のフィールド306bも
オール0であり、拡張ページテーブル303のXTEG
0が指定されたことになる。306cで示す7ビット
は、当該拡張ページテーブルエントリグループ(XTE
G)内の拡張ページテーブルエントリ(XTE)を示
す。
Extension page table reference address 306
Indicates a reference address of a page table entry to be searched in the extended page table 303. The first 46 bits indicated by 306a include the XTA of SDR (2) 305.
BORG 305a is set, and 11 shown by next 306b is set.
Bits include LSB in XVPN of virtual address 301
The side 11 bits 301c are set. These 306a and 3
The 11 bits 301c on the LSB side of 57 bits of 06b are set. The 57-bit values of 306a and 306b are used to define the entry group (X
TEG) indicates the start address. For example, if the bit 301c in the virtual address 301 is all 0, the field 306b of the extended page table reference address 306 is also all 0, and the XTEG of the extended page table 303 is
0 is specified. 7 bits indicated by 306c are the extended page table entry group (XTE
G) shows the extended page table entry (XTE) in FIG.

【0032】拡張ページテーブル検索処理においては、
まず、SDR(2)305のフィールド305a、仮想
アドレス201内の所定ビット301cを、拡張ページ
テーブル参照アドレス306のフィールド306aと3
06bに設定し、フィールド306cには初期値として
オール0を設定して、拡張ページテーブル303の該当
エントリグループ(XTEG)の先頭アドレスを算出す
る。次に、該エントリグループ(XTEG)に含まれる
拡張ページテーブルエントリ(XTE)を逐次参照し、
アドレス変換の成功条件を満たすエントリであるかどう
かをチェックする。すなわち、拡張ページテーブル参照
アドレス306の下位アドレス304cを16バイトず
つインクリメントし、各エントリを読み出しながら前記
のチェックを適用し、該当するエントリが見つかれば、
その時点でアドレス変換成功となる。
In the extended page table search processing,
First, the field 305a of the SDR (2) 305 and the predetermined bit 301c in the virtual address 201 are stored in the fields 306a and 3 of the extended page table reference address 306.
06b, the field 306c is set to all 0s as an initial value, and the start address of the corresponding entry group (XTEG) of the extended page table 303 is calculated. Next, the extended page table entry (XTE) included in the entry group (XTEG) is sequentially referred to,
Check if the entry satisfies the condition for successful address translation. That is, the lower address 304c of the extended page table reference address 306 is incremented by 16 bytes, and the above check is applied while reading each entry.
At that point, the address translation is successful.

【0033】もし、複数のエントリが該当する場合は最
初に検索されるエントリ、すなわち、メモリの上位に配
置されたエントリがヒットし、もう一方のエントリは無
視される。したがって、OSおよびソフトウェアでは該
当するエントリが唯一になるように設定するべきであ
る。
If a plurality of entries are applicable, the first searched entry, that is, the entry located in the upper part of the memory hits, and the other entry is ignored. Therefore, the OS and software should be set so that the corresponding entry is unique.

【0034】アドレス変換成功となった場合、該当拡張
ページテーブルエントリ304のXRPN304dを実
アドレス302のフィールド302aに設定し、仮想ア
ドレス301の拡張オフセット301dとオフセット3
01bを実アドレス302のフィールド302cと30
2bに設定する。そして、該当拡張ページテーブルエン
トリ304のフィールド304fに含まれる参照履歴を
更新し、さらに、アクセスがストア命令による場合は3
04fに含まれる変更履歴を更新する。
If the address conversion is successful, the XRPN 304d of the corresponding extended page table entry 304 is set in the field 302a of the real address 302, and the extended offset 301d and the offset 3 of the virtual address 301 are set.
01b in the fields 302c and 30 of the real address 302.
Set to 2b. Then, the reference history included in the field 304f of the corresponding extended page table entry 304 is updated.
The change history included in 04f is updated.

【0035】図4は、図2のページテーブル203と図
3の拡張ページテーブル303を使ったアドレス変換の
フローの全体を示している。ここでは、テーブルはペー
ジテーブル203、拡張ページテーブル303の順番に
検索する。
FIG. 4 shows the entire flow of address conversion using the page table 203 of FIG. 2 and the extended page table 303 of FIG. Here, the table is searched in the order of the page table 203 and the extended page table 303.

【0036】ステップ401〜407はページテーブル
203によるアドレス変換のフローである。ステップ4
01で、SDR(1)のHTABORGと仮想アドレス
の所定11ビットによりページテーブル203の該当ペ
ージテーブルエントリグループ(PTEG)204の先
頭アドレスPTE_ADRを算出し、ステップ402,
403,406,407に示すように、16バイトずつ
PTE_ADRをインクリメントしながら該当ページテ
ーブルエントリグループ内のページテーブルエントリ
(PTE)を順次ロードする。そして、ステップ404
において、仮想アドレスのVPNとページテーブルエン
トリのVPNの比較、Vビットにより、該当するエント
リであるかどうかを判定し、該当すれば、ステップ40
5のようにページテーブルによるアドレス変換が成功
し、該当しなければ、引き続き隣接する16バイト、す
なわち、次のエントリをロードする。
Steps 401 to 407 are a flow of address conversion by the page table 203. Step 4
In step 01, the start address PTE_ADR of the corresponding page table entry group (PTEG) 204 of the page table 203 is calculated from the HTABORG of SDR (1) and the predetermined 11 bits of the virtual address.
As shown by 403, 406, and 407, the page table entries (PTE) in the corresponding page table entry group are sequentially loaded while incrementing PTE_ADR by 16 bytes. Then, step 404
In the above, the VPN of the virtual address is compared with the VPN of the page table entry, and whether or not the entry is a relevant entry is determined by the V bit.
If the address conversion by the page table succeeds as shown in FIG. 5, and if it does not correspond, the adjacent 16 bytes, that is, the next entry, are loaded.

【0037】該当するページエントリグループに含まれ
る8個のエントリを全て検索しても該当するエントリが
見つからない場合は、ステップ409の判定に移る。ス
テップ409では、レジスタSDR(2)のバリッドビ
ットVが1の場合は拡張ページテーブルによるアドレス
変換に移行し、0の場合は、ステップ430に示すよう
に、テーブル検索失敗として処理を終了する。
If the corresponding entry is not found even if all eight entries included in the corresponding page entry group are searched, the process proceeds to step 409. In step 409, if the valid bit V of the register SDR (2) is 1, the processing shifts to address conversion by the extended page table. If it is 0, the processing ends as a table search failure as shown in step 430.

【0038】ステップ421〜427は拡張ページテー
ブル303によるアドレス変換のフローである。ステッ
プ421、SDR(2)のXTABORGと仮想アドレ
スの所定11ビットにより、拡張ページテーブル303
の該当で拡張ページテーブルエントリグループ(XTE
G)の先頭アドレスXTE_ADRを算出し、ステップ
422、423、426、427に示すように、16バ
イトずつXTE_ADRをインクリメントしながら、拡
張ページテーブルエントリを順次ロードする。そして、
ステップ424において、仮想アドレスのXVPNと該
当エントリ(XTE)のXVPNとの比較、Vビットの
参照により、該当するエントリであるかどうかを判定
し、該当すればステップ425のように、拡張ページテ
ーブル303によるアドレス変換が成功し、該当しなけ
れば隣接する16バイト、すなわち、次のエントリをロ
ードする。
Steps 421 to 427 are a flow of address conversion by the extended page table 303. Step 421, the XTABORG of SDR (2) and the predetermined 11 bits of the virtual address are used to set the extended page table 303
Extended page table entry group (XTE
G), the start address XTE_ADR is calculated, and as shown in steps 422, 423, 426, and 427, the extended page table entries are sequentially loaded while incrementing the XTE_ADR by 16 bytes. And
In step 424, the XVPN of the virtual address is compared with the XVPN of the corresponding entry (XTE), and it is determined whether or not the entry is a corresponding entry by referring to the V bit. Is successful, and if not, the next 16 bytes, that is, the next entry is loaded.

【0039】当該拡張ページエントリグループに含まれ
る8個のエントリXTE0〜XTE7を全て検索しても
該当するエントリが見つからない場合は、ステップ43
0に示したように、テーブル検索失敗で処理を終了す
る。テーブル検索失敗の場合は、割込みを発生させOS
のハンドラに処理を委ねる。
If all eight entries XTE0 to XTE7 included in the extended page entry group have not been found even after searching, step 43
As shown in FIG. 0, the process ends when the table search fails. If the table search fails, an interrupt is generated and the OS
Delegate the process to the handler.

【0040】図5は、アドレス変換情報を保持するオン
チップのバッファであるTLBおよび拡張TLBの構成
とそのアドレス変換フローである。
FIG. 5 shows the configuration of the TLB and the extended TLB which are on-chip buffers for holding the address conversion information and the address conversion flow.

【0041】TLB510および拡張TLB520は、
ページテーブルおよび拡張ページテーブルによるアドレ
ス変換処理で一度利用した仮想アドレスから実アドレス
へのマッピング情報を保持し、それ以降のアドレス変換
において再利用することで、テーブル検索処理の回数を
削減する。本実施例では、TLB510、拡張TLB5
20の両方をインプリメントしているが、いずれか一方
をインプリメントした形態、いずれもインプリメントし
ない形態もありえる。
TLB 510 and extended TLB 520 are:
The mapping information from the virtual address to the real address once used in the address conversion processing by the page table and the extended page table is held and reused in the subsequent address conversion, thereby reducing the number of table search processing. In this embodiment, the TLB 510 and the extended TLB 5
20 are implemented, but there may be a form in which either one is implemented or a form in which neither is implemented.

【0042】図2、図3と同様に、仮想アドレス501
はVPN501aとオフセット501bからなり、変換
結果である実アドレス502はRPN502aとオフセ
ット502bからなる。502aは501bは等しい。
As in FIGS. 2 and 3, the virtual address 501
Is composed of a VPN 501a and an offset 501b, and a real address 502 as a conversion result is composed of an RPN 502a and an offset 502b. 502a is equal to 501b.

【0043】TLB510は、256エントリからな
り、CPU内のRAMに実装され、図2に示したような
ページテーブル203にしたがったアドレス変換結果を
格納する。510aはページテーブル203のVPNの
上位44ビットに相当するフィールドである。該フィー
ルド510aの内容と仮想アドレス501の511aで
示す上位44ビットとが比較器512で比較一致し、か
つ、アンド回路513により、該一致信号と501dの
エントリ・バリッドが1であるアンド条件がとられた場
合に、TLBがヒットした、すなわち、TLB510の
該当エントリに格納された内容がアドレス変換情報とし
て有効であるとみなす。510bはTLB510インデ
ックス・アドレスであり、仮想アドレス501の511
bで示す44〜51ビット部分を入力とする。TLB5
10がヒットした場合、該当エントリのRPNフィール
ド510cが実アドレス502のRPN502aに設定
され、仮想アドレス501のオフセット501bがその
まま実アドレス502のオフセット502bとして設定
されて、実アドレス502が得られる。フィールド51
0eにはページ保護情報、参照履歴、更新履歴を保持す
る。ページ保護情報はアクセス権限の判定に利用する。
参照履歴と更新履歴は主記憶上のページテーブルに対し
て履歴を更新するかどうかの判定に利用し、さらに、履
歴を更新した場合は510eのフィールドも同様に更新
する。
The TLB 510 has 256 entries, is mounted on the RAM in the CPU, and stores an address conversion result according to the page table 203 as shown in FIG. A field 510a corresponds to the upper 44 bits of the VPN of the page table 203. The contents of the field 510a and the upper 44 bits indicated by 511a of the virtual address 501 are compared and matched by the comparator 512, and the match signal and the AND condition where the entry valid of 501d is 1 are determined by the AND circuit 513. In this case, the TLB is hit, that is, the contents stored in the corresponding entry of the TLB 510 are regarded as valid as the address translation information. Reference numeral 510b denotes a TLB 510 index address, which is 511 of the virtual address 501.
The 44 to 51 bit portion indicated by b is input. TLB5
When 10 is hit, the RPN field 510c of the entry is set to the RPN 502a of the real address 502, the offset 501b of the virtual address 501 is set as it is as the offset 502b of the real address 502, and the real address 502 is obtained. Field 51
0e holds page protection information, reference history, and update history. The page protection information is used for determining access authority.
The reference history and the update history are used to determine whether to update the history for the page table in the main memory, and when the history is updated, the field of 510e is also updated.

【0044】拡張TLB520は、TLB510と同様
に256エントリからなり、CPU内のRAMに実装さ
れ、図3に示したような拡張ページテーブル303にし
たがったアドレス変換結果を格納する。520aは拡張
ページテーブル303のXVPNに相当し、比較器52
2により仮想アドレス501の上位ビット521aと比
較され、比較結果が一致し、かつ、アンド回路523に
より比較回路522の一致信号と、520dのエントリ
・バリッドVが1、かつ、524で示すのSDR2のバ
リッドVが1のアンド条件がとられた場合に、拡張TL
Bがヒットした、すなわち、拡張TLBの該当エントリ
に格納された内容がアドレス変換情報として有効である
とみなす。
The extended TLB 520 has 256 entries like the TLB 510, is mounted on the RAM in the CPU, and stores an address conversion result according to the extended page table 303 as shown in FIG. 520a corresponds to the XVPN of the extended page table 303,
2 is compared with the upper bit 521a of the virtual address 501, and the comparison result matches, and the match signal of the comparison circuit 522 and the entry valid V of 520d are 1 by the AND circuit 523 and the SDR2 of 524 indicated by 524 When the AND condition of valid V is 1 is taken, the extended TL
B is hit, that is, the content stored in the corresponding entry of the extended TLB is regarded as valid as the address translation information.

【0045】523aは比較器522の比較範囲を指定
するマスクテーブルであり、拡張ページサイズにしたが
い比較範囲を変更する。拡張ページサイズと比較範囲の
関係は、(ページサイズ、比較範囲)=(16Mバイ
ト、0〜31ビット)、(32Mバイト、0〜30ビッ
ト)、(64Mバイト、0〜29ビット)、(128M
バイト、0〜28ビット)となる。
A mask table 523a specifies the comparison range of the comparator 522, and changes the comparison range according to the extended page size. The relation between the extended page size and the comparison range is (page size, comparison range) = (16 Mbytes, 0 to 31 bits), (32 Mbytes, 0 to 30 bits), (64 Mbytes, 0 to 29 bits), (128 Mbytes)
Byte, 0 to 28 bits).

【0046】520bは拡張TLB520のインデック
ス・アドレスであり、テーブル523bにより、ページ
サイズにしたがって、521bの仮想アドレス29〜3
9ビットのうちから8ビットを選択して入力とする。。
ページサイズと520bへの入力範囲の関係は、(ペー
ジサイズ、アドレス入力範囲)=(16Mバイト、32
〜39ビット)、(32Mバイト、31〜38ビッ
ト)、(64Mバイト、30〜37ビット)、(128
Mバイト、29〜36ビット)となる。
Reference numeral 520b denotes an index address of the extended TLB 520. According to the table 523b, the virtual addresses 29 to 3 of the 521b are determined according to the page size.
8 bits are selected from 9 bits and input. .
The relationship between the page size and the input range to 520b is (page size, address input range) = (16 Mbytes, 32
(Up to 39 bits), (32 Mbytes, 31 to 38 bits), (64 Mbytes, 30 to 37 bits), (128
M bytes, 29 to 36 bits).

【0047】拡張TLB520がヒットした場合、該当
エントリのXRPNフィールド520c、および、仮想
アドレスの拡張オフセット下位である521cと521
dをあわせて実ページ番号502aが得られ、仮想アド
レスのオフセット501bとあわせることで、実アドレ
ス502となる。ここで、拡張TLBのXRPNフィー
ルド520cの上位37ビットは実アドレスの上位37
ビットとしてそのまま用いられる。該フィールド520
cの下位3ビットは、仮想アドレスの拡張オフセットの
上位3ビット521c、および、テーブル523cに関
連して、アンド回路525a、オア回路525bの論理
演算を通して、実アドレスの37〜39ビットの値とな
る。
When the extension TLB 520 hits, the XRPN field 520c of the corresponding entry and 521c and 521 which are the lower extension offsets of the virtual address.
The real page number 502a is obtained by adding d, and the real page number 502a is obtained by adding it to the offset 501b of the virtual address. Here, the upper 37 bits of the XRPN field 520c of the extended TLB are the upper 37 bits of the real address.
Used as it is as a bit. The field 520
The lower 3 bits of c become the values of bits 37 to 39 of the real address through the logical operation of the AND circuit 525a and the OR circuit 525b in relation to the upper 3 bits 521c of the extended offset of the virtual address and the table 523c. .

【0048】テーブル523cのマスクはページサイズ
により変化し、(ページサイズ、マスク)=(16Mバ
イト,”000”)、(32Mバイト,”001”)、
(64Mバイト,”011”)、(128Mバイト,”
111”)となる。拡張オフセットの521dで示す下
位12ビットは実アドレス502の40〜51ビット目
として用いられる。
The mask of the table 523c changes according to the page size. (Page size, mask) = (16 Mbytes, “000”), (32 Mbytes, “001”),
(64 Mbytes, “011”), (128 Mbytes, “
111 "). The lower 12 bits indicated by the extended offset 521d are used as the 40th to 51st bits of the real address 502.

【0049】拡張TBL520のフィールド520eに
はページ保護情報、参照履歴、更新履歴を保持する。ペ
ージ保護情報はアクセス権限の判定に利用する。参照履
歴と更新履歴は主記憶上のページテーブルに対して履歴
を更新するかどうかの判定に利用し、さらに、履歴を更
新した場合は520eのフィールドも同様に更新する。
セレクタ530は、TLB510により得られるRP
Nと拡張TLB520により得られるRPNのセレクタ
であり、ヒットした側を選択する。TLB510と拡張
TLB520の両方がヒットした場合は、TLB510
による変換結果を採用する。これは、ページテーブル2
03と拡張ページテーブル303の両方でアドレス変換
が成功した場合に、ページテーブル203による変換結
果を採るのに対応している。
The field 520e of the extended TBL 520 holds page protection information, reference history, and update history. The page protection information is used for determining access authority. The reference history and the update history are used to determine whether or not to update the history for the page table in the main memory. When the history is updated, the field 520e is also updated.
The selector 530 selects the RP obtained by the TLB 510
N and an RPN selector obtained by the extended TLB 520, and selects a hit side. If both the TLB 510 and the extended TLB 520 are hit, the TLB 510
The result of the conversion is adopted. This is page table 2
When the address conversion is successful in both the address table 03 and the extended page table 303, the result of conversion by the page table 203 is obtained.

【0050】図5のTLB510と拡張TLB520の
いずれもヒットしなかった場合、図4で説明した検索フ
ローにしたがい、主記憶上のページテーブル203、拡
張ページテーブル303を検索し、ページテーブル20
3が検索成功した場合は当該ページテーブルエントリの
内容をTLB510へ格納し、拡張ページテーブル30
3が検索成功した場合は当該拡張ページテーブルエント
リの内容を拡張TLB520へ格納する。
If neither the TLB 510 nor the extended TLB 520 in FIG. 5 is hit, the page table 203 and the extended page table 303 in the main memory are searched according to the search flow described in FIG.
3 succeeds in the search, the content of the page table entry is stored in the TLB 510, and the extended page table 30
If the search for No. 3 is successful, the contents of the extended page table entry are stored in the extended TLB 520.

【0051】上記処理の具体的な実現方法としては、ペ
ージテーブルあるいは拡張ページテーブルの内容をTL
B510あるいは拡張TLB520へ格納する処理をハ
ードウェアのシーケンサにより実現し、いずれのテーブ
ルも検索できなかった場合の検索失敗処理では割込みを
発生させOSのハンドラに処理を委ねる方式が考えられ
る。また、これとは別の実現方法としては、ロード命令
でテーブルを読出し、テーブル書込み専用命令でTLB
510あるいは拡張TLB520に情報を格納するとい
うソフトウェアによる実現も考えられる。いずれのテー
ブルも検索できなかった場合は、割込みを発生させるこ
とはなくOSのハンドラへ処理を分岐させればよい。な
お、アドレス変換に一度利用したページテーブルや拡張
ページテーブルのマッピング情報をTLBや拡張TLB
に格納する処理過程は、基本的に従来と同様であるの
で、ここでは説明を省略する。
As a specific method for realizing the above processing, the contents of the page table or the extended page table are stored in the TL
A method of realizing the processing of storing data in the B510 or the extended TLB 520 by a hardware sequencer, and in the search failure processing when none of the tables can be searched, generating an interrupt and entrusting the processing to an OS handler may be considered. As another implementation method, a table is read by a load instruction, and TLB is read by a table write-only instruction.
Software realization of storing information in 510 or extended TLB 520 is also conceivable. If none of the tables can be retrieved, the processing may be branched to the OS handler without generating an interrupt. It should be noted that the mapping information of the page table or the extended page table used once for the address conversion is stored in the TLB or the extended TLB.
Is basically the same as that of the related art, and a description thereof will be omitted.

【0052】TLBを実装するプロセッサにおいては、
TLB無効化命令が一般に用意されている。TLBの情
報はページテーブルの内容と矛盾してはならない。ペー
ジテーブルを管理するソフトウェアがテーブル内容を更
新する場合、ストア命令によって主記憶上のページテー
ブルを書き換える。ところが、このままではTLBは書
き換えられないため、ページテーブルとTLBが不一致
になってしまう。この不一致を避けるためTLB無効化
命令が用意されており、ページテーブルを書き換えたと
きには対応するTLBエントリを無効化することで不一
致を防止する。同様に、拡張TLBに関しても拡張TL
B無効化命令を用意し、拡張ページテーブルを更新する
場合には拡張TLBの対応するエントリを無効化するこ
とで不一致を防止する。
In a processor implementing the TLB,
A TLB invalidation instruction is generally provided. The TLB information must not conflict with the contents of the page table. When software that manages the page table updates the table contents, the page table on the main memory is rewritten by a store instruction. However, since the TLB is not rewritten as it is, the page table does not match the TLB. To avoid this mismatch, a TLB invalidation instruction is prepared. When the page table is rewritten, the corresponding TLB entry is invalidated to prevent the mismatch. Similarly, regarding the extended TLB, the extended TL
When a B invalidation instruction is prepared and the extended page table is updated, the mismatch is prevented by invalidating the corresponding entry in the extended TLB.

【0053】図6は、本発明の他の実施例であり、命令
フェッチにはページテーブルおよびTLBによるアドレ
ス変換機構602のみを、ロード・ストア命令アクセス
にはページテーブルおよびTLBによるアドレス変換機
構612と拡張ページテーブルおよび拡張TLBによる
アドレス変換機構613を備えた実施例である。614
はアドレス変換結果のセレクタを示す。すなわち、命令
領域へのアクセスではある1つのページサイズによるア
ドレス変換手段で十分であり、データ領域へのアクセス
ではより大きいページサイズによるアドレス変換手段が
有効となる場合の実施例である。
FIG. 6 shows another embodiment of the present invention, in which only an address translation mechanism 602 based on a page table and TLB is used for instruction fetch, and an address translation mechanism 612 based on a page table and TLB is used for load / store instruction access. This is an embodiment including an address conversion mechanism 613 using an extended page table and an extended TLB. 614
Indicates a selector of the address conversion result. That is, this embodiment is an example in which an address conversion unit using one page size is sufficient for accessing the instruction area, and an address conversion unit using a larger page size is effective for accessing the data area.

【0054】図7は、本発明によるアドレス変換方法を
適用したプロセッサの一実施例の概略ブロック図であ
る。プロセッサはCPU710と主記憶720で構成さ
れ、CPU710は標準ページサイズアドレス変換論理
部711とTLB712、及び、拡張ページサイズアド
レス変換論理部713と拡張TLB714を具備し、主
記憶720はページテーブル721及び拡張ページテー
ブル722を具備する。標準ページサイズアドレス変換
論理部711および拡張ページサイズアドレス変換論理
部713は、命令実行時、まず、TLB712および拡
張TLB714を参照してアドレス変換を試み、TLB
712と拡張TLB714のいずれにもピットしなかっ
た場合、主記憶720のページテーブル721、拡張ペ
ージテーブル722を検索してアドレス変換を行う。標
準ページサイズアドレス変換論理部711と拡張ページ
サイズアドレス変換論理部713との間では、相互に処
理結果を伝達しあい、これにより処理の順序性を保証す
る。
FIG. 7 is a schematic block diagram of an embodiment of a processor to which the address translation method according to the present invention is applied. The processor includes a CPU 710 and a main memory 720. The CPU 710 includes a standard page size address conversion logic unit 711 and a TLB 712, and an extended page size address conversion logic unit 713 and an extended TLB 714. The main memory 720 includes a page table 721 and an extended TLB 714. A page table 722 is provided. When executing an instruction, the standard page size address conversion logic unit 711 and the extended page size address conversion logic unit 713 first attempt address conversion by referring to the TLB 712 and the extended TLB 714, and
If no pit is found in either the 712 or the extended TLB 714, the page table 721 and the extended page table 722 in the main memory 720 are searched to perform address conversion. The standard page size address conversion logic unit 711 and the extended page size address conversion logic unit 713 mutually transmit processing results, thereby guaranteeing the order of processing.

【0055】上述した実施例は単なる例示であって、本
発明の技術的範囲を制限するものではない。本発明は、
様々な変形、変更が可能である。例えば、図2のページ
テーブルや図3の拡張ページテーブルは、必ずしもエン
トリグループとエントリの組み合せで構成する必要はな
く、エントリグループの概念を省略してページテーブル
エントリ(PTE)や拡張ページテーブルエントリ(X
TE)単位で並べてもよい。
The embodiments described above are merely examples, and do not limit the technical scope of the present invention. The present invention
Various modifications and changes are possible. For example, the page table of FIG. 2 and the extended page table of FIG. 3 do not necessarily need to be configured by a combination of an entry group and an entry. The concept of an entry group is omitted and a page table entry (PTE) or an extended page table entry ( X
They may be arranged in units of TE).

【0056】[0056]

【発明の効果】本発明によれば、ページサイズに関して
相反する要求を持つ複数のプログラムに対し、それぞれ
に適したページサイズにもとづくアドレス変換を同時に
実現できる。また、マッピング情報のコピーを保持する
バッファ(TLB)を具備するプロセッサでは、TLB
ミス率が低減し、プログラムの実行時間の短縮が可能に
なる。
According to the present invention, address conversion based on a page size suitable for each of a plurality of programs having conflicting requirements regarding the page size can be simultaneously realized. In a processor including a buffer (TLB) for holding a copy of mapping information, the TLB
The error rate is reduced, and the execution time of the program can be reduced.

【図面の簡単な説明】[Brief description of the drawings]

【図1】本発明によるアドレス変換の基本概念を示す図
である。
FIG. 1 is a diagram showing a basic concept of address conversion according to the present invention.

【図2】本発明の一実施例におけるページテーブルによ
るアドレス変換を説明する図である。
FIG. 2 is a diagram illustrating address conversion by a page table according to an embodiment of the present invention.

【図3】本発明の一実施例における拡張ページテーブル
によるアドレス変換を説明する図である。
FIG. 3 is a diagram illustrating address conversion by an extended page table according to an embodiment of the present invention.

【図4】本発明の一実施例におけるアドレス変換の処理
フローを示す図である。
FIG. 4 is a diagram showing a processing flow of address conversion in one embodiment of the present invention.

【図5】本発明の一実施例におけるTLBおよび拡張T
LBによるアドレス変換を説明する図である。
FIG. 5 shows TLB and extended T in one embodiment of the present invention.
FIG. 4 is a diagram illustrating address conversion by LB.

【図6】本発明の他の実施例によるアドレス変換を説明
する。
FIG. 6 illustrates an address translation according to another embodiment of the present invention.

【図7】本発明によるアドレス変換方法を適用するプロ
セッサの一実施例のブロック図である。
FIG. 7 is a block diagram of an embodiment of a processor to which an address translation method according to the present invention is applied.

【符号の説明】[Explanation of symbols]

101 仮想アドレス 102 ページテーブルおよびTLBによるアドレス変
換機構 103 拡張ページテーブルおよび拡張TLBによるア
ドレス変換機構 104 セレクタ 203 ページテーブル 204 ページテーブルエントリ 303 拡張ページテーブル 304 拡張ページテーブルエントリ 510 TLB 520 拡張TLB 710 CPU 720 主記憶
101 Virtual address 102 Address translation mechanism using page table and TLB 103 Address translation mechanism using extended page table and extended TLB 104 Selector 203 Page table 204 Page table entry 303 Extended page table 304 Extended page table entry 510 TLB 520 Extended TLB 710 CPU 720 Main Memory

─────────────────────────────────────────────────────
────────────────────────────────────────────────── ───

【手続補正書】[Procedure amendment]

【提出日】平成11年1月8日(1999.1.8)[Submission date] January 8, 1999 (1999.1.8)

【手続補正1】[Procedure amendment 1]

【補正対象書類名】明細書[Document name to be amended] Statement

【補正対象項目名】全文[Correction target item name] Full text

【補正方法】変更[Correction method] Change

【補正内容】[Correction contents]

【書類名】 明細書[Document Name] Statement

【発明の名称】 動的アドレス変換方法及びプロセッ
Patent application title: Dynamic address translation method and processor

【特許請求の範囲】[Claims]

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】本発明は、仮想記憶方式を採
用したコンピュータシステムに係り、特に、複数のペー
ジサイズを同時にサポートする動的アドレス変換方法及
び該アドレス変換方法を適用したプロセッサに関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a computer system employing a virtual memory system, and more particularly, to a dynamic address translation method that simultaneously supports a plurality of page sizes and a processor to which the address translation method is applied.

【0002】[0002]

【従来の技術】多くのコンピュータシステムでは仮想記
憶(Virtual Memory/Storage)方式が採用されてい
る。仮想記憶方式は、主記憶装置の容量不足を補助記憶
装置/外部記憶装置との置換えにより補い、同時に実行
される複数のプログラムの各々に対してメモリ空間を矛
盾なく割当てるためには必須の技術である。
2. Description of the Related Art Many computer systems employ a virtual memory / storage system. The virtual storage method is an indispensable technique for compensating for the lack of capacity of the main storage device by replacing it with an auxiliary storage device / external storage device and allocating a memory space to each of a plurality of programs executed simultaneously without inconsistency. is there.

【0003】仮想記憶方式では、ユーザのプログラムに
対して仮想アドレス空間を提供し、OSが仮想アドレス
空間から実アドレス空間へのマッピングを管理する。仮
想アドレスから実アドレスへのマッピング情報は、通
常、主記憶上に配置されたページテーブルに保持されて
いる。
In the virtual storage system, a virtual address space is provided to a user program, and the OS manages mapping from the virtual address space to the real address space. The mapping information from the virtual address to the real address is normally held in a page table arranged on the main storage.

【0004】動的アドレス変換では、命令実行中に命令
フェッチ、ロード・ストア命令などによりアクセスする
実アドレスを計算するために、ページテーブルの情報を
参照する。しかし、各命令を実行する度にページテーブ
ルを参照していたのでは、主記憶へのアクセスが各命令
ごとに発生してしまい、実用的な時間内で命令を実行で
きない。
In the dynamic address translation, information of a page table is referred to in order to calculate a real address to be accessed by an instruction fetch, a load / store instruction or the like during the execution of an instruction. However, if the page table is referenced every time each instruction is executed, access to the main memory occurs for each instruction, and the instruction cannot be executed within a practical time.

【0005】そこで、高速小容量のリソースをCPU側
に用意し、アドレス変換のために主記憶のページテーブ
ルから読み出したマッピング情報を保持し、後続命令で
同じページに再びアクセスした場合は、リソースの情報
を再利用する方式が一般に用いられている。このリソー
スをTLB(Translation Lookaside Buffer)と呼
ぶ。TLBが有効な手段となる理由は、プログラムのメ
モリアクセスには局所性(Locality)の性質があり、
一度利用したマッピング情報は再び利用されることが多
いためである。
Therefore, a high-speed, small-capacity resource is prepared on the CPU side, the mapping information read from the page table of the main memory is held for address conversion, and when the same page is accessed again by a subsequent instruction, the resource is rewritten. A method of reusing information is generally used. This resource is called a TLB (Translation Lookaside Buffer). The reason that the TLB is an effective means is that the memory access of a program has the property of locality (Locity),
This is because the mapping information used once is often used again.

【0006】TLBは動的アドレス変換実現する上での
一機構であり、アドレス変換の論理的な機能という観点
からは必ずしも必要ではないが、TLBがなければ処理
性能が極めて劣ったものとなり無意味なものとなってし
まう。いいかえると、TLBの存在を前提としてはじめ
て動的アドレス変換は意味をもったものとなる。
The TLB is a mechanism for realizing the dynamic address translation, and is not necessarily required from the viewpoint of the logical function of the address translation. However, without the TLB, the processing performance is extremely poor and is meaningless. It will be something. In other words, the dynamic address translation becomes meaningful only on the premise of the existence of the TLB.

【0007】[0007]

【発明が解決しようとする課題】一回のメモリアクセス
についてアドレス変換のマッピング情報がTLBから得
られない割合をTLBミス率という。通常、TLBのエ
ントリ数が256以上であれば、TLBミス率は1%以
下であるといわれている。ところが、大規模科学計算の
ように膨大なデータを処理するプログラムにおいては、
メモリアクセスの局所性が必ずしも保証されず、TLB
の有効性の大前提が成り立たない場合もある。
The rate at which mapping information for address conversion cannot be obtained from the TLB for one memory access is called a TLB miss rate. Usually, if the number of entries in the TLB is 256 or more, it is said that the TLB miss rate is 1% or less. However, in programs that process huge amounts of data, such as large-scale scientific calculations,
Locality of memory access is not always guaranteed, and TLB
In some cases, the basic premise of the effectiveness of does not hold.

【0008】TLBからアドレス変換の情報(マッピン
グ情報)が得られない場合、主記憶からページテーブル
を読み出し、TLBに情報を登録しなければならない。
主記憶からページテーブルを読み出す際には、命令パイ
プラインは当然のことながら停止しなければならず、ア
ーキテクチャによっては割込みが必要になる場合もあ
る。したがって、性能の観点から無視できないペナルテ
ィが伴うため、TLBミス率を低減することは重要な問
題である。
When the address translation information (mapping information) cannot be obtained from the TLB, the page table must be read from the main memory and the information must be registered in the TLB.
When reading the page table from the main memory, the instruction pipeline must be stopped naturally, and an interrupt may be required depending on the architecture. Therefore, there is a penalty that cannot be ignored from a performance point of view, so reducing the TLB miss rate is an important issue.

【0009】TLBミス率は、ページサイズと関連が深
い。たとえば、プログラムが連続する8Kバイトの領域
をアクセスする場合、ページサイズが4Kバイトならば
2ページ必要だが、ページサイズを8Kバイトとするな
ら1ページしか必要としない。ページサイズを大きく
し、必要となるページ数をより少なくすれば、必要なマ
ッピング情報がTLBに格納されている確率も高くな
り、TLBミス率を低減できる。一方、ページサイズを
大きく設定すると、プログラムが利用しない無駄な領域
の割当てがより多く発生し、さらには、主記憶と外部記
憶装置間のページ転送に余計な時間がかかるといったデ
メリットが発生する。したがって、やみくもにページサ
イズを大きくすることはできないため、最適なページサ
イズを決定し、TLBミス率を低減するのは難しい問題
である。
The TLB miss rate is closely related to the page size. For example, when a program accesses a continuous area of 8 Kbytes, two pages are required if the page size is 4 Kbytes, but only one page is required if the page size is 8 Kbytes. If the page size is increased and the number of required pages is reduced, the probability that required mapping information is stored in the TLB increases, and the TLB miss rate can be reduced. On the other hand, when the page size is set to be large, there is a disadvantage that more useless areas are allocated that are not used by the program, and furthermore, extra time is required for page transfer between the main storage and the external storage device. Therefore, since the page size cannot be blindly increased, it is difficult to determine the optimum page size and reduce the TLB miss rate.

【0010】本発明の目的は、仮想アドレスを実アドレ
スに変換する機構を備えたプロセッサにおいて、それぞ
れのプログラムに対して最適なページサイズによるアド
レス変換を可能とし、TLBミス率を低減することにあ
る。
An object of the present invention is to enable a processor having a mechanism for converting a virtual address to a real address to perform address conversion with an optimum page size for each program and reduce the TLB miss rate. .

【0011】[0011]

【課題を解決するための手段】本発明では、複数のペー
ジサイズを同時に扱える動的アドレス変換手段を提供す
る。具体的には、仮想アドレスから実アドレスへのマッ
ピング単位を標準のページサイズと拡張ページサイズの
複数とし、標準のページサイズのマッピングを定義した
ページテーブルと、該ページテーブルのマッピング情報
のコピーを保持するTLBと、命令実行時にTLB、ペ
ージテーブルに従い仮想アドレスを実アドレスに変換す
る手段からなるアドレス変換機構と、拡張ページサイズ
のマッピングを定義した拡張ページテーブルと、該拡張
ページテーブルのマッピング情報のコピーを保持する拡
張TLBと、命令実行時に拡張TLB、拡張ページテー
ブルに従い仮想アドレスを実アドレスに変換する手段か
らなるアドレス変換機構とを設ける。
SUMMARY OF THE INVENTION The present invention provides a dynamic address translation means capable of simultaneously handling a plurality of page sizes. Specifically, the mapping unit from the virtual address to the real address is set to a plurality of the standard page size and the extended page size, and a page table defining the mapping of the standard page size and a copy of the mapping information of the page table are held. TLB to be executed, an address translation mechanism comprising means for translating a virtual address into a real address according to the TLB and the page table when executing an instruction, an extended page table defining an extended page size mapping, and a copy of mapping information of the extended page table And an address translation mechanism comprising means for translating a virtual address into a real address according to the extended TLB and the extended page table when executing an instruction.

【0012】本発明によれば、ページサイズの異なる複
数のマッピング情報を互いに独立した複数のアドレス変
換機構で個別に扱うことにより、複数のページサイズを
同時に扱うアドレス変換が可能となる。したがって、例
えばメモリアクセスの局所性が高いプログラムの実行に
通常の、標準のページサイズを利用し、大規模なメモ
リ領域を利用するプログラムについてはより大きいペー
ジサイズ(拡張ページサイズ)を利用することで、ペー
ジサイズを大きくすることによるデメリットを抑えつ
つ、TLBミス率を低減することが可能となる。
According to the present invention, a plurality of mapping information items having different page sizes are individually handled by a plurality of address conversion mechanisms independent of each other, thereby enabling address conversion for simultaneously handling a plurality of page sizes. Therefore, for example, a normal standard page size is used for executing a program having high locality of memory access, and a larger page size (extended page size) is used for a program using a large memory area. Thus, it is possible to reduce the TLB miss rate while suppressing disadvantages caused by increasing the page size.

【0013】さらに、拡張ページサイズを複数のサイズ
から選択することにより、より細かいチューニングが可
能となる。また、一方のアドレス変換機構を無効に設定
することにより、一つのページサイズで十分な場合にシ
ステム設定を簡略にすることも可能である。
Further, by selecting the extension page size from a plurality of sizes, finer tuning is possible. Further, by setting one of the address translation mechanisms to invalid, it is possible to simplify the system setting when one page size is sufficient.

【0014】[0014]

【発明の実施の形態】図1は、本発明に基づき仮想アド
レスを実アドレスに変換するための概念図を示す。図1
に示すように、仮想アドレス101は、ページテーブル
およびTLBによるアドレス変換機構102の変換結
果、および、拡張ページテーブルおよび拡張ページテー
ブルによるアドレス変換機構103の変換結果を、セレ
クタ104により選択することで、実アドレス105に
変換される。セレクタ104は変換に成功した側の結果
を選択するが、両方が成功する場合にはアドレス変換機
構102の結果を選択する。
DESCRIPTION OF THE PREFERRED EMBODIMENTS FIG. 1 shows a conceptual diagram for converting a virtual address to a real address according to the present invention. FIG.
As shown in FIG. 5, the selector 104 selects the virtual address 101 by selecting the conversion result of the address conversion mechanism 102 using the page table and the TLB, and the conversion result of the address conversion mechanism 103 using the extended page table and the extended page table. It is converted to a real address 105. The selector 104 selects the result on the side where the translation is successful, but if both succeed, the result of the address translation mechanism 102 is selected.

【0015】アドレス変換機構102、103では、ま
ず、TLBおよび拡張TLBでアドレス変換を行い、両
方でアドレス変換に失敗した場合、ページテーブルおよ
び拡張テーブルを用いてアドレス変換を行う。テーブル
を検索する順序は、ページテーブル、拡張ページテーブ
ルの順番とする。また、ページテーブルがアドレス変換
に利用された場合は、該ページテーブルの参照/変更履
歴を更新し、拡張ページテーブルがアドレス変換に利用
された場合は、該拡張ページテーブルの参照/変更履歴
を更新する。システムは、アドレス変換機構102ある
いは103をそれぞれ有効/無効に設定する機能を備え
る。
In the address conversion mechanisms 102 and 103, first, the address conversion is performed in the TLB and the extended TLB, and if the address conversion fails in both, the address conversion is performed using the page table and the extended table. The order of searching the tables is the order of the page table and the extended page table. When the page table is used for address translation, the reference / change history of the page table is updated. When the extended page table is used for address translation, the reference / change history of the extended page table is updated. I do. The system has a function of setting the address translation mechanism 102 or 103 to valid / invalid.

【0016】次に、本発明によるアドレス変換の詳細を
実施例により説明する。なお、実施例では仮想アドレ
ス、実アドレスともに64ビットであるとする。
Next, details of the address conversion according to the present invention will be described with reference to an embodiment. In the embodiment, it is assumed that both the virtual address and the real address are 64 bits.

【0017】図2は、ページテーブルによるアドレス変
換の過程を示している。本実施例では、標準のページサ
イズは4Kバイトである。仮想アドレス201は、変換
の対象となる52ビットの仮想ページ番号(VPN)2
01aと、変換の対象にならない12ビットのオフセッ
ト201bからなる。実アドレス202は、52ビット
の実ページ番号(RPN)202aと12ビットのオフ
セット202bからなる。オフセットはアドレス変換の
対象とならない部分であるため、201bと202bは
等しい。
FIG. 2 shows a process of address conversion by a page table. In this embodiment, the standard page size is 4 Kbytes. The virtual address 201 is a 52-bit virtual page number (VPN) 2 to be converted.
01a and a 12-bit offset 201b that is not subject to conversion. The real address 202 includes a 52-bit real page number (RPN) 202a and a 12-bit offset 202b. Since the offset is a part that is not subject to address translation, 201b and 202b are equal.

【0018】ページテーブル203の大きさは256K
バイトである。その先頭アドレスは2の18乗の整数倍
である。ページテーブル203は、128バイトの領域
であるページテーブルエントリグループ(PTEG)が
2048個(PTEG0〜PTEG2047)、縦方向
に連続して並んだ構成になっている。各ページテーブル
エントリグループは、16バイトの領域であるページエ
ントリ(PTE)が8個(PTE0〜PTE7)、横方
向に連続して並ぶ構成になっている。
The size of the page table 203 is 256K
Bytes. The start address is an integral multiple of 2 to the 18th power. The page table 203 has a configuration in which 2048 page table entry groups (PTEGs) each of which is a 128-byte area (PTEG0 to PTEG2047) are arranged continuously in the vertical direction. Each page table entry group has a configuration in which eight page entries (PTE), which are 16-byte areas, are arranged in a row in the horizontal direction (PTE0 to PTE7).

【0019】一つのページテーブルエントリ204は、
16バイトが8バイトずつ仮想アドレス側と実アドレス
側に2分されて、アドレス変換に必要な情報が格納され
ている。204aは仮想ページ番号VPNを、204b
はリザーブフィールド(Reserved Field)を、204
cはエントリの内容が有効であることを示すバリッドV
を表わし、また、204dは実ページ番号RPNを、2
04eはリザーブフィールドを、206fはページ保護
情報、参照履歴、変更履歴などの付随情報を表す。リザ
ーブフィールド204b、204eは現在は使用されて
いないが、将来なんらかの意味を割当てられるかもしれ
ないフィールドである。フィールド204fのページ保
護情報はOSのシステム管理データなどを格納したペー
ジについて、ユーザプログラムからのアクセスを禁止す
るなどの目的で使用する情報である。参照履歴は当該ペ
ージに対するアクセスがあったことを示す情報であり、
主記憶からページアウトする対象をOSが決定するなど
の目的に利用される情報である。変更履歴は当該ページ
がストア命令によりアクセスされたことを示す情報であ
り、主記憶からページアウトする場合に外部記憶装置へ
のデータ転送が必要になることをOSが判断するなどの
目的に利用される情報である。
One page table entry 204 is
The 16 bytes are divided into a virtual address side and a real address side by 8 bytes at a time, and information necessary for address conversion is stored. 204a is a virtual page number VPN, 204b
Is the Reserved Field, 204
c is a valid V indicating that the contents of the entry are valid
204d represents the real page number RPN as 2
04e indicates a reserve field, and 206f indicates accompanying information such as page protection information, reference history, and change history. Reserved fields 204b and 204e are fields that are not currently used but may be assigned some meaning in the future. The page protection information in the field 204f is information used for the purpose of, for example, prohibiting access from a user program to a page storing OS system management data and the like. The reference history is information indicating that the page has been accessed,
This information is used for the purpose of, for example, determining the target of page-out from the main memory by the OS. The change history is information indicating that the page has been accessed by a store instruction, and is used for the purpose of, for example, the OS determining that data transfer to an external storage device is required when page-out from the main memory. Information.

【0020】アドレス変換が成功する条件は、仮想アド
レス201のVPN201aとページテーブルエントリ
204のVPN204aが等しく、かつ、バリッドV2
04cが1であるようなエントリの検索に成功すること
である。この場合、仮想アドレス201のVPN201
aが当該ページテーブルエントリ204のRPN204
dに置換えられることにより実アドレス202のRPN
202aが得られ、フィールド204fによりページ保
護などの付随情報が得られる。実アドレス202のオフ
セット202bには、仮想アドレス201のオフセット
201bがそのまま設定される。
The condition that the address conversion is successful is that the VPN 201a of the virtual address 201 is equal to the VPN 204a of the page table entry 204 and the valid V2
That is, a search for an entry whose 04c is 1 is successful. In this case, the VPN 201 of the virtual address 201
a is the RPN 204 of the page table entry 204
d to replace the RPN of the real address 202
202a is obtained, and accompanying information such as page protection is obtained by the field 204f. As the offset 202b of the real address 202, the offset 201b of the virtual address 201 is set as it is.

【0021】ストレージディスクリプションレジスタ1
(SDR1)205は、8バイト幅のレジスタであり、
205aで示したページテーブル203の先頭アドレス
を示す46ビットのフィールド(HTABORG)と、
205bで示したリザーブフィールドからなる。このS
DR(1)205は、制御レジスタの一つとしてあらか
じめCPUに用意されるものである。
Storage description register 1
(SDR1) 205 is an 8-byte width register,
A 46-bit field (HTABORG) indicating the head address of the page table 203 indicated by 205a;
It comprises a reserved field indicated by 205b. This S
DR (1) 205 is prepared in the CPU in advance as one of the control registers.

【0022】ページテーブル参照アドレス206は、ペ
ージテーブル203の検索対象となるページテーブルエ
ントリの参照アドレスである。206aで示す先頭の4
6ビットには、SDR(1)のHTABORG205a
が設定され、次の206bで示す11ビットには、仮想
アドレス201のVPN201a中のLSB側11ビッ
201cが設定される。この206aと206bの5
7ビットの値で、ページテーブル203のページテーブ
ルエントリグループの先頭アドレスを示す。例えば、2
01cがオール0ならばフィールド206bもオール0
であり、203a0で示したPTEG0が指定されたこ
とになる。206cで示す7ビットは、当該ページテー
ブルエントリグループ内のページテーブルエントリを示
す。
The page table reference address 206 is a reference address of a page table entry to be searched in the page table 203. The first 4 indicated by 206a
Six bits include HTABORG 205a of SDR (1).
Is set, and the 11 bits indicated by the next 206b are set to the LSB side 11 bits 201c in the VPN 201a of the virtual address 201. 5 of 206a and 206b
A 7-bit value indicating the head address of the page table entry group of the page table 203. For example, 2
If 01c is all 0, field 206b is also all 0
This means that PTEG0 indicated by 203a0 has been designated. The 7 bits 206c indicate a page table entry in the page table entry group.

【0023】ページテーブル検索処理においては、ま
ず、SDR(1)205のフィールド205a、仮想ア
ドレス201のVPNの201cで示すLSB側11ビ
ットを、ページテーブル参照アドレス206のフィール
ド206aと206bに設定し、フィールド206cに
は初期値としてオール0を設定して、ページテーブル2
03の該当ページテーブルエントリグループ(PTE
G)の先頭アドレスを求める。次に、該ページテーブル
エントリグループに含まれるページテーブルエントリ
(PTE)を逐次参照し、アドレス変換の成功条件を満
たすエントリであるかどうかをチェックする。すなわ
ち、ページテーブル参照アドレス206の下位アドレス
206cを16バイトずつインクリメントし、各エント
リを読み出しながら前記のチェックを適用し、該当する
エントリが見つかれば、その時点でアドレス変換成功と
なる。
In the page table search process, first, the field 205a of the SDR (1) 205 and the LSB side 11 bits indicated by the VPN 201c of the virtual address 201 are set in the fields 206a and 206b of the page table reference address 206. All 0 is set as an initial value in the field 206c, and the page table 2
03 corresponding page table entry group (PTE
G) Find the start address. Next, the page table entry (PTE) included in the page table entry group is sequentially referred to, and it is checked whether the entry satisfies the condition for successful address translation. That is, the lower address of the page table reference address 206
206c is incremented by 16 bytes, and the above-described check is applied while reading each entry. If a corresponding entry is found, the address conversion is successful at that point.

【0024】もし、複数のエントリが該当する場合は最
初に検索されるエントリ、すなわち、メモリの上位に配
置されたエントリがヒットし、もう一方のエントリは無
視される。したがって、OSおよびソフトウェアでは該
当するエントリが唯一になるように設定するべきであ
る。アドレス変換の対象となったページがアクセスをさ
れた場合は、該当ページエントリ204のフィールド2
04fに含まれる参照履歴を更新し、さらに、アクセス
がストア命令による場合は該フィールド204fに含ま
れる変更履歴を更新する。
If a plurality of entries are applicable, the first searched entry, that is, the entry located in the upper part of the memory hits, and the other entry is ignored. Therefore, the OS and software should be set so that the corresponding entry is unique. If the page subjected to the address translation is accessed, field 2 of the corresponding page entry 204
The reference history contained in the field 204f is updated, and when the access is made by a store instruction, the change history contained in the field 204f is updated.

【0025】図3は、拡張ページテーブルによるアドレ
ス変換の過程を示している。本実施例において、拡張ペ
ージテーブルのページサイズは16M〜128Mバイト
可変であるとする。ページサイズの指定方法は後述す
る。
FIG. 3 shows a process of address conversion by the extended page table. In the present embodiment, it is assumed that the page size of the extended page table is variable from 16M to 128M bytes. The method for specifying the page size will be described later.

【0026】仮想アドレス301は、変換の対象となる
40〜37ビットの拡張仮想ページ番号(XVPN)
01aと、12〜15ビットの拡張オフセット301d
と、12ビットのオフセット(標準オフセット)301
bからなる。フィールド301a301cのビット幅
は、拡張するページサイズに従い可変であり、本実施例
では、(ページサイズ、XVPNのビット幅、拡張オフ
セットのビット幅)の関係は、(16Mバイト、40、
12)、(32Mバイト、41、11)、(64Mバイ
ト、42、10)、(128Mバイト、43、9)とな
る。実アドレス302は、仮想アドレス301のフィー
ルド301aと同じビット幅の拡張実ページ番号(XR
PN)302a、仮想アドレス301のフィールド30
1bおよび301dとビット幅および値ともに等しいオ
フセット302bおよび302cからなる。すなわち、
仮想アドレス301の拡張オフセット301dとオフセ
ット301bがそのまま実アドレス302の拡張オフセ
ット302cとオフセット302bに設定される。
The virtual address 301 is a 40-37 bit extended virtual page number (XVPN) 3 to be converted.
01a and 12-15 bit extended offset 301d
And a 12-bit offset (standard offset) 301
b. The bit widths of the fields 301a and 301c are variable according to the page size to be extended. In the present embodiment, the relationship between (page size, XVPN bit width, and extension offset bit width) is (16 Mbytes, 40,
12), (32 Mbytes, 41, 11), (64 Mbytes, 42, 10), and (128 Mbytes, 43, 9). The real address 302 is an extended real page number (XR) having the same bit width as the field 301a of the virtual address 301.
PN) 302a , field 30 of virtual address 301
The offsets 302b and 302c have the same bit width and value as 1b and 301d. That is,
The extended offset 301d and the offset 301b of the virtual address 301 are set as the extended offset 302c and the offset 302b of the real address 302 as they are.

【0027】拡張ページテーブル303の大きさは、図
2のページテーブル202と同じく256Kバイトであ
る。その先頭アドレスは2の18乗の整数倍である。拡
張ページテーブル303は、128バイトの領域である
拡張ページテーブルエントリグループ(XTEG)が2
048個(XTEG0〜XTEG2047)、縦方向に
連続して並んだ構成になっている。各拡張ページテーブ
ルエントリグループは、16バイトの領域である拡張ペ
ージエントリ(XTE)が8個(XTE0〜XTE
7)、横方向連続して並ぶ構成になっている。
The size of the extended page table 303 is 256 Kbytes, similar to the page table 202 of FIG. The start address is an integral multiple of 2 to the 18th power. The extended page table 303 has an extended page table entry group (XTEG) of 128 bytes,
048 pieces (XTEG0 to XTEG2047) are arranged continuously in the vertical direction. Each extended page table entry group has eight extended page entries (XTE), which are 16-byte areas (XTE0 to XTE).
7), they are arranged continuously in the horizontal direction.

【0028】一つの拡張ページテーブルエントリ304
は、16バイトが仮想アドレス側と実アドレス側に2分
されて、アドレス変換に必要な情報が格納されている。
304aは拡張仮想ページ番号XVPNを、304bは
リザーブフィールドを、304cはバリッドVを表わ
し、また、304dは拡張実ページ番号XRPNを、3
04eはリザーブフィールドを、304fはページ保護
情報、参照履歴、変更履歴などの付随情報を表す。ペー
ジサイズに従い、XVPN304aの下位mビットは任
意の値でよく、XRPN304dの下位mビットは0で
なければならない。ここで、(ページサイズ,m)は
(16Mバイト,0)、(32Mバイト,1)、(64M
バイト,2)、(128Mバイト,3)という関係にな
っている。
One extended page table entry 304
In the example, 16 bytes are divided into a virtual address side and a real address side, and information necessary for address conversion is stored.
304a represents an extended virtual page number XVPN, 304b represents a reserved field, 304c represents valid V, and 304d represents an extended actual page number XRPN.
04e indicates a reserve field, and 304f indicates accompanying information such as page protection information, reference history, and change history. According to the page size, the lower m bits of the XVPN 304a may be any value, and the lower m bits of the XRPN 304d must be zero. Here, (page size, m) is (16 Mbytes, 0), (32 Mbytes, 1), (64 Mbytes, 1)
Byte, 2), (128 Mbytes, 3).

【0029】アドレス変換が成功する条件は、仮想アド
レス301のXVPN301aと拡張ページテーブルエ
ントリ304のXVPN304aの上位nビットが等し
く、かつ、バリッドV304cが1であるようなエント
リの検索に成功することである。ここで、(ページサイ
ズ,n)は(16Mバイト,40)、(32Mバイト,
39)、(64Mバイト,38)、(128Mバイト,
37)という関係になっている。アドレス変換が成功す
ると、仮想アドレス301のXVPN301aが当該拡
張ページテーブルエントリ304のXRPN304dに
置換えられることにより実アドレス302のXRPN3
02aが得られ、フィールド304fによりページ保護
などの付随情報が得られる。実アドレス302の拡張オ
フセット302cとオフセット302bには、仮想アド
レス301の拡張オフセット301bとオフセット30
1bがそのまま設定される。
The condition for successful address translation is that the search for an entry in which the upper n bits of the XVPN 301a of the virtual address 301 and the XVPN 304a of the extended page table entry 304 are equal and the valid V304c is 1 is successful. . Here, (page size, n) is (16 Mbytes, 40), (32 Mbytes,
39), (64 Mbytes, 38), (128 Mbytes,
37). If the address conversion is successful, the XRPN 301a of the virtual address 301 is replaced with the XRPN 304d of the extended page table entry 304, and the XRPN3 of the real address 302 is replaced.
02a is obtained, and accompanying information such as page protection is obtained by the field 304f. The extended offset 302c and the offset 302b of the real address 302 correspond to the extended offset 301b and the offset 30 of the virtual address 301, respectively.
1b is set as it is.

【0030】ストレージディスクリプションレジスタ2
(SDR2)305は、8バイト幅のレジスタであり、
305aの46ビットのフィールド(XTABOR
G)、305bのリザーブフィールド、305cの2ビ
ットのフィールド(PS)、303dのバリッド(V)
からなる。XTABORGフィールド305aは拡張ペ
ージテーブル303の先頭アドレス、PSはフィールド
305cページサイズの種類、Vビット303dは拡張
ページテーブル303によるアドレス変換が有効/無効
であることを表す。本実施例では、PSフィールド30
5cが表すページサイズの種類については、(PS,ペ
ージサイズ)の関係を(”00”,16Mバイ
ト)、(”01”,32Mバイト)、(”10”,64M
バイト)、(”11”,128Mバイト)とする。この
SDR(2)305は、図2のSDR(1)205と同
様に、制御レジスタの一つとしてあらかじめCPUに用
意されるものである。
Storage description register 2
(SDR2) 305 is an 8-byte width register,
305a 46-bit field (XTABOR
G), reserved field of 305b, 2-bit field (PS) of 305c, valid (V) of 303d
Consists of The XTABORG field 305a indicates the start address of the extension page table 303, the PS indicates the type of page size in the field 305c, and the V bit 303d indicates that address conversion by the extension page table 303 is valid / invalid. In this embodiment, the PS field 30
Regarding the type of page size represented by 5c, the relationship of (PS, page size) is represented by ( "00" , 16 Mbytes), ("01", 32 Mbytes), ("10", 64M).
Bytes), (“11”, 128 Mbytes). The SDR (2) 305 is prepared in advance in the CPU as one of the control registers, similarly to the SDR (1) 205 in FIG.

【0031】拡張ページテーブル参照アドレス306
は、拡張ページテーブル303の検索対象となるページ
テーブルエントリの参照アドレスを示す。306aで示
す先頭の46ビットには、SDR(2)305のXTA
BORG305aが設定され、次の306bで示す11
ビットには、仮想アドレス301のXVPN中のLSB
側11ビット301cが設定される。この306aと3
06bの57ビットのLSB側11ビット301cが設
定される。この306aと306bの57ビットの値
で、拡張ページテーブル303のエントリグループ(X
TEG)の先頭アドレスを示す。例えば、仮想アドレス
301内のビット301cがオール0ならば、拡張ペー
ジテーブル参照アドレス306のフィールド306bも
オール0であり、拡張ページテーブル303のXTEG
0が指定されたことになる。306cで示す7ビット
は、当該拡張ページテーブルエントリグループ(XTE
G)内の拡張ページテーブルエントリ(XTE)を示
す。
Extension page table reference address 306
Indicates a reference address of a page table entry to be searched in the extended page table 303. The first 46 bits indicated by 306a include the XTA of SDR (2) 305.
BORG 305a is set, and 11 shown by next 306b is set.
Bits include LSB in XVPN of virtual address 301
The side 11 bits 301c are set. These 306a and 3
The 11 bits 301c on the LSB side of 57 bits of 06b are set. The 57-bit values of 306a and 306b are used to define the entry group (X
TEG) indicates the start address. For example, if the bit 301c in the virtual address 301 is all 0, the field 306b of the extended page table reference address 306 is also all 0, and the XTEG of the extended page table 303 is
0 is specified. 7 bits indicated by 306c are the extended page table entry group (XTE
G) shows the extended page table entry (XTE) in FIG.

【0032】拡張ページテーブル検索処理においては、
まず、SDR(2)305のフィールド305a、仮想
アドレス201内の所定ビット301cを、拡張ページ
テーブル参照アドレス306のフィールド306aと3
06bに設定し、フィールド306cには初期値として
オール0を設定して、拡張ページテーブル303の該当
エントリグループ(XTEG)の先頭アドレスを算出す
る。次に、該エントリグループ(XTEG)に含まれる
拡張ページテーブルエントリ(XTE)を逐次参照し、
アドレス変換の成功条件を満たすエントリであるかどう
かをチェックする。すなわち、拡張ページテーブル参照
アドレス306の下位アドレス306cを16バイトず
つインクリメントし、各エントリを読み出しながら前記
のチェックを適用し、該当するエントリが見つかれば、
その時点でアドレス変換成功となる。
In the extended page table search processing,
First, the field 305a of the SDR (2) 305 and the predetermined bit 301c in the virtual address 201 are stored in the fields 306a and 3 of the extended page table reference address 306.
06b, the field 306c is set to all 0s as an initial value, and the start address of the corresponding entry group (XTEG) of the extended page table 303 is calculated. Next, the extended page table entry (XTE) included in the entry group (XTEG) is sequentially referred to,
Check if the entry satisfies the condition for successful address translation. That is, the lower address 306c of the extended page table reference address 306 is incremented by 16 bytes, and the above check is applied while reading each entry.
At that point, the address translation is successful.

【0033】もし、複数のエントリが該当する場合は最
初に検索されるエントリ、すなわち、メモリの上位に配
置されたエントリがヒットし、もう一方のエントリは無
視される。したがって、OSおよびソフトウェアでは該
当するエントリが唯一になるように設定するべきであ
る。
If a plurality of entries are applicable, the first searched entry, that is, the entry located in the upper part of the memory hits, and the other entry is ignored. Therefore, the OS and software should be set so that the corresponding entry is unique.

【0034】アドレス変換成功となった場合、該当拡張
ページテーブルエントリ304のXRPN304dを実
アドレス302のフィールド302aに設定し、仮想ア
ドレス301の拡張オフセット301dとオフセット3
01bを実アドレス302のフィールド302cと30
2bに設定する。そして、該当拡張ページテーブルエン
トリ304のフィールド304fに含まれる参照履歴を
更新し、さらに、アクセスがストア命令による場合は3
04fに含まれる変更履歴を更新する。
If the address conversion is successful, the XRPN 304d of the corresponding extended page table entry 304 is set in the field 302a of the real address 302, and the extended offset 301d and the offset 3 of the virtual address 301 are set.
01b in the fields 302c and 30 of the real address 302.
Set to 2b. Then, the reference history included in the field 304f of the corresponding extended page table entry 304 is updated.
The change history included in 04f is updated.

【0035】図4は、図2のページテーブル203と図
3の拡張ページテーブル303を使ったアドレス変換の
フローの全体を示している。ここでは、テーブルはペー
ジテーブル203、拡張ページテーブル303の順番に
検索する。
FIG. 4 shows the entire flow of address conversion using the page table 203 of FIG. 2 and the extended page table 303 of FIG. Here, the table is searched in the order of the page table 203 and the extended page table 303.

【0036】ステップ401〜408はページテーブル
203によるアドレス変換のフローである。ステップ4
01で、SDR(1)のHTABORGと仮想アドレス
の所定11ビットによりページテーブル203の該当ペ
ージテーブルエントリグループ(PTEG)204の先
頭アドレスPTE_ADRを算出し、ステップ402,
403,406,408に示すように、16バイトずつ
PTE_ADRをインクリメントしながら該当ページテ
ーブルエントリグループ内のページテーブルエントリ
(PTE)を順次ロードする。そして、ステップ404
において、仮想アドレスのVPNとページテーブルエン
トリのVPNの比較、Vビットにより、該当するエント
リであるかどうかを判定し、該当すれば、ステップ40
5のようにページテーブルによるアドレス変換が成功
し、該当しなければ、引き続き隣接する16バイト、す
なわち、次のエントリをロードする。
Steps 401 to 408 are a flow of address conversion by the page table 203. Step 4
In step 01, the start address PTE_ADR of the corresponding page table entry group (PTEG) 204 of the page table 203 is calculated from the HTABORG of SDR (1) and the predetermined 11 bits of the virtual address.
As indicated by 403, 406 , and 408 , the page table entries (PTE) in the corresponding page table entry group are sequentially loaded while incrementing PTE_ADR by 16 bytes. Then, step 404
In the above, the VPN of the virtual address is compared with the VPN of the page table entry, and whether or not the entry is a relevant entry is determined by the V bit.
If the address conversion by the page table is successful as shown in FIG.

【0037】該当するページエントリグループに含まれ
る8個のエントリを全て検索しても該当するエントリが
見つからない場合は、ステップ409の判定に移る。ス
テップ409では、レジスタSDR(2)のバリッドビ
ットVが1の場合は拡張ページテーブルによるアドレス
変換に移行し、0の場合は、ステップ430に示すよう
に、テーブル検索失敗として処理を終了する。
If the corresponding entry is not found even if all eight entries included in the corresponding page entry group are searched, the process proceeds to step 409. In step 409, if the valid bit V of the register SDR (2) is 1, the processing shifts to address conversion by the extended page table. If it is 0, the processing ends as a table search failure as shown in step 430.

【0038】ステップ421〜427は拡張ページテー
ブル303によるアドレス変換のフローである。ステッ
プ421、SDR(2)のXTABORGと仮想アドレ
スの所定11ビットにより、拡張ページテーブル303
の該当で拡張ページテーブルエントリグループ(XTE
G)の先頭アドレスXTE_ADRを算出し、ステップ
422,423,426,427に示すように、16バ
イトずつXTE_ADRをインクリメントしながら、拡
張ページテーブルエントリを順次ロードする。そして、
ステップ424において、仮想アドレスのXVPNと該
当エントリ(XTE)のXVPNとの比較、Vビットの
参照により、該当するエントリであるかどうかを判定
し、該当すればステップ425のように、拡張ページテ
ーブル303によるアドレス変換が成功し、該当しなけ
れば隣接する16バイト、すなわち、次のエントリをロ
ードする。
Steps 421 to 427 are a flow of address conversion by the extended page table 303. Step 421, the XTABORG of SDR (2) and the predetermined 11 bits of the virtual address are used to set the extended page table 303
Extended page table entry group (XTE
G), the start address XTE_ADR is calculated, and as shown in steps 422, 423, 426, and 427, the extension page table entries are sequentially loaded while incrementing the XTE_ADR by 16 bytes. And
In step 424, the XVPN of the virtual address is compared with the XVPN of the corresponding entry (XTE), and it is determined whether or not the entry is a corresponding entry by referring to the V bit. Is successful, and if not, the next 16 bytes, that is, the next entry is loaded.

【0039】当該拡張ページエントリグループに含まれ
る8個のエントリXTE0〜XTE7を全て検索しても
該当するエントリが見つからない場合は、ステップ43
0に示したように、テーブル検索失敗で処理を終了す
る。テーブル検索失敗の場合は、割込みを発生させOS
のハンドラに処理を委ねる。
If all eight entries XTE0 to XTE7 included in the extended page entry group have not been found even after searching, step 43
As shown in FIG. 0, the process ends when the table search fails. If the table search fails, an interrupt is generated and the OS
Delegate the process to the handler.

【0040】図5は、アドレス変換情報を保持するオン
チップのバッファであるTLBおよび拡張TLBの構成
とそのアドレス変換フローである。
FIG. 5 shows the configuration of the TLB and the extended TLB which are on-chip buffers for holding the address conversion information and the address conversion flow.

【0041】TLB510および拡張TLB520は、
ページテーブルおよび拡張ページテーブルによるアドレ
ス変換処理で一度利用した仮想アドレスから実アドレス
へのマッピング情報を保持し、それ以降のアドレス変換
において再利用することで、テーブル検索処理の回数を
削減する。本実施例では、TLB510、拡張TLB5
20の両方をインプリメントしているが、いずれか一方
をインプリメントした形態、いずれもインプリメントし
ない形態もありえる。
TLB 510 and extended TLB 520 are:
The mapping information from the virtual address to the real address once used in the address conversion processing by the page table and the extended page table is held and reused in the subsequent address conversion, thereby reducing the number of table search processing. In this embodiment, the TLB 510 and the extended TLB 5
20 are implemented, but there may be a form in which either one is implemented or a form in which neither is implemented.

【0042】図2、図3と同様に、仮想アドレス501
はVPN501aとオフセット501bからなり、変換
結果である実アドレス502はRPN502aとオフセ
ット502bからなる。502bは501b等しい。
As in FIGS. 2 and 3, the virtual address 501
Is composed of a VPN 501a and an offset 501b, and a real address 502 as a conversion result is composed of an RPN 502a and an offset 502b. 502b is equal to 501b.

【0043】TLB510は、256エントリからな
り、CPU内のRAMに実装され、図2に示したような
ページテーブル203にしたがったアドレス変換結果を
格納する。510aはページテーブル203のVPNの
上位44ビットに相当するフィールドである。該フィー
ルド510aの内容と仮想アドレス501の511aで
示す上位44ビットとが比較器512で比較一致し、か
つ、アンド回路513により、該一致信号と501dの
エントリ・バリッドが1であるアンド条件がとられた場
合に、TLBがヒットした、すなわち、TLB510の
該当エントリに格納された内容がアドレス変換情報とし
て有効であるとみなす。510bはTLB510インデ
ックス・アドレスであり、仮想アドレス501の511
bで示す44〜51ビット部分を入力とする。TLB5
10がヒットした場合、該当エントリのRPNフィール
ド510cが実アドレス502のRPN502aに設定
され、仮想アドレス501のオフセット501bがその
まま実アドレス502のオフセット502bとして設定
されて、実アドレス502が得られる。フィールド51
0eにはページ保護情報、参照履歴、更新履歴を保持す
る。ページ保護情報はアクセス権限の判定に利用する。
参照履歴と更新履歴は主記憶上のページテーブルに対し
て履歴を更新するかどうかの判定に利用し、さらに、履
歴を更新した場合は510eのフィールドも同様に更新
する。
The TLB 510 has 256 entries, is mounted on the RAM in the CPU, and stores an address conversion result according to the page table 203 as shown in FIG. A field 510a corresponds to the upper 44 bits of the VPN of the page table 203. The contents of the field 510a and the upper 44 bits indicated by 511a of the virtual address 501 are compared and matched by the comparator 512, and the match signal and the AND condition where the entry valid of 501d is 1 are determined by the AND circuit 513. In this case, the TLB is hit, that is, the contents stored in the corresponding entry of the TLB 510 are regarded as valid as the address translation information. Reference numeral 510b denotes a TLB 510 index address, which is 511 of the virtual address 501.
The 44 to 51 bit portion indicated by b is input. TLB5
When 10 is hit, the RPN field 510c of the entry is set to the RPN 502a of the real address 502, the offset 501b of the virtual address 501 is set as it is as the offset 502b of the real address 502, and the real address 502 is obtained. Field 51
0e holds page protection information, reference history, and update history. The page protection information is used for determining access authority.
The reference history and the update history are used to determine whether to update the history for the page table in the main memory, and when the history is updated, the field of 510e is also updated.

【0044】拡張TLB520は、TLB510と同様
に256エントリからなり、CPU内のRAMに実装さ
れ、図3に示したような拡張ページテーブル303にし
たがったアドレス変換結果を格納する。520aは拡張
ページテーブル303のXVPNに相当し、比較器52
2により仮想アドレス501の上位ビット521aと比
較され、比較結果が一致し、かつ、アンド回路523に
より比較回路522の一致信号と、520dのエントリ
・バリッドVが1、かつ、524で示すのSDR2のバ
リッドVが1のアンド条件がとられた場合に、拡張TL
Bがヒットした、すなわち、拡張TLBの該当エントリ
に格納された内容がアドレス変換情報として有効である
とみなす。
The extended TLB 520 has 256 entries like the TLB 510, is mounted on the RAM in the CPU, and stores an address conversion result according to the extended page table 303 as shown in FIG. 520a corresponds to the XVPN of the extended page table 303,
2 is compared with the upper bit 521a of the virtual address 501, and the comparison result matches, and the match signal of the comparison circuit 522 and the entry valid V of 520d are 1 by the AND circuit 523 and the SDR2 of 524 indicated by 524 When the AND condition of valid V is 1 is taken, the extended TL
B is hit, that is, the content stored in the corresponding entry of the extended TLB is regarded as valid as the address translation information.

【0045】523aは比較器522の比較範囲を指定
するマスクテーブルであり、拡張ページサイズにしたが
い比較範囲を変更する。拡張ページサイズと比較範囲の
関係は、(ページサイズ、比較範囲)=(16Mバイ
ト、0〜31ビット)、(32Mバイト、0〜30ビッ
ト)、(64Mバイト、0〜29ビット)、(128M
バイト、0〜28ビット)となる。
A mask table 523a specifies the comparison range of the comparator 522, and changes the comparison range according to the extended page size. The relation between the extended page size and the comparison range is (page size, comparison range) = (16 Mbytes, 0 to 31 bits), (32 Mbytes, 0 to 30 bits), (64 Mbytes, 0 to 29 bits), (128 Mbytes)
Byte, 0 to 28 bits).

【0046】520bは拡張TLB520のインデック
ス・アドレスであり、テーブル523bにより、ページ
サイズにしたがって、521bの仮想アドレス29〜3
9ビットのうちから8ビットを選択して入力とする
ージサイズと520bへの入力範囲の関係は、(ページ
サイズ、アドレス入力範囲)=(16Mバイト、32〜
39ビット)、(32Mバイト、31〜38ビット)、
(64Mバイト、30〜37ビット)、(128Mバイ
ト、29〜36ビット)となる。
Reference numeral 520b denotes an index address of the extended TLB 520. According to the table 523b, the virtual addresses 29 to 3 of the 521b are determined according to the page size.
8 bits are selected from 9 bits and input . The relationship between the page size and the input range to 520b is (page size, address input range) = (16 Mbytes, 32 to
39 bits), (32 Mbytes, 31-38 bits),
(64 Mbytes, 30 to 37 bits) and (128 Mbytes, 29 to 36 bits).

【0047】拡張TLB520がヒットした場合、該当
エントリのXRPNフィールド520c、および、仮想
アドレスの拡張オフセット下位である521cと521
dをあわせて実ページ番号502aが得られ、仮想アド
レスのオフセット501bとあわせることで、実アドレ
ス502となる。ここで、拡張TLBのXRPNフィー
ルド520cの上位37ビットは実アドレスの上位37
ビットとしてそのまま用いられる。該フィールド520
cの下位3ビットは、仮想アドレスの拡張オフセットの
上位3ビット521c、および、テーブル523cに関
連して、アンド回路525a、オア回路525bの論理
演算を通して、実アドレスの37〜39ビットの値とな
る。
When the extension TLB 520 hits, the XRPN field 520c of the corresponding entry and 521c and 521 which are the lower extension offsets of the virtual address.
The real page number 502a is obtained by adding d, and the real page number 502a is obtained by adding it to the offset 501b of the virtual address. Here, the upper 37 bits of the XRPN field 520c of the extended TLB are the upper 37 bits of the real address.
Used as it is as a bit. The field 520
The lower 3 bits of c become the values of bits 37 to 39 of the real address through the logical operation of the AND circuit 525a and the OR circuit 525b in relation to the upper 3 bits 521c of the extended offset of the virtual address and the table 523c. .

【0048】テーブル523cのマスクはページサイズ
により変化し、(ページサイズ、マスク)=(16Mバ
イト,”000”)、(32Mバイト,”001”)、
(64Mバイト,”011”)、(128Mバイト,”
111”)となる。拡張オフセットの521dで示す下
位12ビットは実アドレス502の40〜51ビット目
として用いられる。
The mask of the table 523c changes according to the page size. (Page size, mask) = (16 Mbytes, “000”), (32 Mbytes, “001”),
(64 Mbytes, “011”), (128 Mbytes, “
111 "). The lower 12 bits indicated by the extended offset 521d are used as the 40th to 51st bits of the real address 502.

【0049】拡張TBL520のフィールド520eに
はページ保護情報、参照履歴、更新履歴を保持する。ペ
ージ保護情報はアクセス権限の判定に利用する。参照履
歴と更新履歴は主記憶上のページテーブルに対して履歴
を更新するかどうかの判定に利用し、さらに、履歴を更
新した場合は520eのフィールドも同様に更新する。
セレクタ530は、TLB510により得られるRP
Nと拡張TLB520により得られるRPNのセレクタ
であり、ヒットした側を選択する。TLB510と拡張
TLB520の両方がヒットした場合は、TLB510
による変換結果を採用する。これは、ページテーブル2
03と拡張ページテーブル303の両方でアドレス変換
が成功した場合に、ページテーブル203による変換結
果を採るのに対応している。
The field 520e of the extended TBL 520 holds page protection information, reference history, and update history. The page protection information is used for determining access authority. The reference history and the update history are used to determine whether or not to update the history for the page table in the main memory. When the history is updated, the field 520e is also updated.
The selector 530 selects the RP obtained by the TLB 510
N and an RPN selector obtained by the extended TLB 520, and selects a hit side. If both the TLB 510 and the extended TLB 520 are hit, the TLB 510
The result of the conversion is adopted. This is page table 2
When the address conversion is successful in both the address table 03 and the extended page table 303, the result of conversion by the page table 203 is obtained.

【0050】図5のTLB510と拡張TLB520の
いずれもヒットしなかった場合、図4で説明した検索フ
ローにしたがい、主記憶上のページテーブル203、拡
張ページテーブル303を検索し、ページテーブル20
3が検索成功した場合は当該ページテーブルエントリの
内容をTLB510へ格納し、拡張ページテーブル30
3が検索成功した場合は当該拡張ページテーブルエント
リの内容を拡張TLB520へ格納する。
If neither the TLB 510 nor the extended TLB 520 in FIG. 5 is hit, the page table 203 and the extended page table 303 in the main memory are searched according to the search flow described in FIG.
3 succeeds in the search, the content of the page table entry is stored in the TLB 510, and the extended page table 30
If the search for No. 3 is successful, the contents of the extended page table entry are stored in the extended TLB 520.

【0051】上記処理の具体的な実現方法としては、ペ
ージテーブルあるいは拡張ページテーブルの内容をTL
B510あるいは拡張TLB520へ格納する処理をハ
ードウェアのシーケンサにより実現し、いずれのテーブ
ルも検索できなかった場合の検索失敗処理では割込みを
発生させOSのハンドラに処理を委ねる方式が考えられ
る。また、これとは別の実現方法としては、ロード命令
でテーブルを読出し、テーブル書込み専用命令でTLB
510あるいは拡張TLB520に情報を格納するとい
うソフトウェアによる実現も考えられる。いずれのテー
ブルも検索できなかった場合は、割込みを発生させるこ
とはなくOSのハンドラへ処理を分岐させればよい。な
お、アドレス変換に一度利用したページテーブルや拡張
ページテーブルのマッピング情報をTLBや拡張TLB
に格納する処理過程は、基本的に従来と同様であるの
で、ここでは説明を省略する。
As a specific method for realizing the above processing, the contents of the page table or the extended page table are stored in the TL
A method of realizing the processing of storing data in the B510 or the extended TLB 520 by a hardware sequencer, and in the search failure processing when none of the tables can be searched, generating an interrupt and entrusting the processing to an OS handler may be considered. As another implementation method, a table is read by a load instruction, and TLB is read by a table write-only instruction.
Software realization of storing information in 510 or extended TLB 520 is also conceivable. If none of the tables can be retrieved, the processing may be branched to the OS handler without generating an interrupt. It should be noted that the mapping information of the page table or the extended page table used once for the address conversion is stored in the TLB or the extended TLB.
Is basically the same as that of the related art, and a description thereof will be omitted.

【0052】TLBを実装するプロセッサにおいては、
TLB無効化命令が一般に用意されている。TLBの情
報はページテーブルの内容と矛盾してはならない。ペー
ジテーブルを管理するソフトウェアがテーブル内容を更
新する場合、ストア命令によって主記憶上のページテー
ブルを書き換える。ところが、このままではTLBは書
き換えられないため、ページテーブルとTLBが不一致
になってしまう。この不一致を避けるためTLB無効化
命令が用意されており、ページテーブルを書き換えたと
きには対応するTLBエントリを無効化することで不一
致を防止する。同様に、拡張TLBに関しても拡張TL
B無効化命令を用意し、拡張ページテーブルを更新する
場合には拡張TLBの対応するエントリを無効化するこ
とで不一致を防止する。
In a processor implementing the TLB,
A TLB invalidation instruction is generally provided. The TLB information must not conflict with the contents of the page table. When software that manages the page table updates the table contents, the page table on the main memory is rewritten by a store instruction. However, since the TLB is not rewritten as it is, the page table does not match the TLB. To avoid this mismatch, a TLB invalidation instruction is prepared. When the page table is rewritten, the corresponding TLB entry is invalidated to prevent the mismatch. Similarly, regarding the extended TLB, the extended TL
When a B invalidation instruction is prepared and the extended page table is updated, the mismatch is prevented by invalidating the corresponding entry in the extended TLB.

【0053】図6は、本発明の他の実施例であり、命令
フェッチにはページテーブルおよびTLBによるアドレ
ス変換機構602のみを、ロード・ストア命令アクセス
にはページテーブルおよびTLBによるアドレス変換機
構612と拡張ページテーブルおよび拡張TLBによる
アドレス変換機構613を備えた実施例である。614
はアドレス変換結果のセレクタを示す。すなわち、命令
領域へのアクセスではある1つのページサイズによるア
ドレス変換手段で十分であり、データ領域へのアクセス
ではより大きいページサイズによるアドレス変換手段が
有効となる場合の実施例である。
FIG. 6 shows another embodiment of the present invention, in which only an address translation mechanism 602 based on a page table and TLB is used for instruction fetch, and an address translation mechanism 612 based on a page table and TLB is used for load / store instruction access. This is an embodiment including an address conversion mechanism 613 using an extended page table and an extended TLB. 614
Indicates a selector of the address conversion result. That is, this embodiment is an example in which an address conversion unit using one page size is sufficient for accessing the instruction area, and an address conversion unit using a larger page size is effective for accessing the data area.

【0054】図7は、本発明によるアドレス変換方法を
適用したプロセッサの一実施例の概略ブロック図であ
る。プロセッサはCPU710と主記憶720で構成さ
れ、CPU710は標準ページサイズアドレス変換論理
部711とTLB712、及び、拡張ページサイズアド
レス変換論理部713と拡張TLB714を具備し、主
記憶720はページテーブル721及び拡張ページテー
ブル722を具備する。標準ページサイズアドレス変換
論理部711および拡張ページサイズアドレス変換論理
部713は、命令実行時、まず、TLB712および拡
張TLB714を参照してアドレス変換を試み、TLB
712と拡張TLB714のいずれにもピットしなかっ
た場合、主記憶720のページテーブル721、拡張ペ
ージテーブル722を検索してアドレス変換を行う。標
準ページサイズアドレス変換論理部711と拡張ページ
サイズアドレス変換論理部713との間では、相互に処
理結果を伝達しあい、これにより処理の順序性を保証す
る。
FIG. 7 is a schematic block diagram of an embodiment of a processor to which the address translation method according to the present invention is applied. The processor includes a CPU 710 and a main memory 720. The CPU 710 includes a standard page size address conversion logic unit 711 and a TLB 712, and an extended page size address conversion logic unit 713 and an extended TLB 714. The main memory 720 includes a page table 721 and an extended TLB 714. A page table 722 is provided. When executing an instruction, the standard page size address conversion logic unit 711 and the extended page size address conversion logic unit 713 first attempt address conversion by referring to the TLB 712 and the extended TLB 714, and
If no pit is found in either the 712 or the extended TLB 714, the page table 721 and the extended page table 722 in the main memory 720 are searched to perform address conversion. The standard page size address conversion logic unit 711 and the extended page size address conversion logic unit 713 mutually transmit processing results, thereby guaranteeing the order of processing.

【0055】上述した実施例は単なる例示であって、本
発明の技術的範囲を制限するものではない。本発明は、
様々な変形、変更が可能である。例えば、図2のページ
テーブルや図3の拡張ページテーブルは、必ずしもエン
トリグループとエントリの組み合せで構成する必要はな
く、エントリグループの概念を省略してページテーブル
エントリ(PTE)単位や拡張ページテーブルエントリ
(XTE)単位で並べてもよい。
The embodiments described above are merely examples, and do not limit the technical scope of the present invention. The present invention
Various modifications and changes are possible. For example, the page table shown in FIG. 2 and the extended page table shown in FIG. 3 do not necessarily need to be constituted by a combination of an entry group and an entry. The concept of the entry group is omitted, and the page table entry (PTE) unit and the extended page table entry are omitted. They may be arranged in (XTE) units.

【0056】[0056]

【発明の効果】本発明によれば、ページサイズに関して
相反する要求を持つ複数のプログラムに対し、それぞれ
に適したページサイズにもとづくアドレス変換を同時に
実現できる。また、マッピング情報のコピーを保持する
バッファ(TLB)を具備するプロセッサでは、TLB
ミス率が低減し、プログラムの実行時間の短縮が可能に
なる。
According to the present invention, address conversion based on a page size suitable for each of a plurality of programs having conflicting requirements regarding the page size can be simultaneously realized. In a processor including a buffer (TLB) for holding a copy of mapping information, the TLB
The error rate is reduced, and the execution time of the program can be reduced.

【図面の簡単な説明】[Brief description of the drawings]

【図1】本発明によるアドレス変換の基本概念を示す図
である。
FIG. 1 is a diagram showing a basic concept of address conversion according to the present invention.

【図2】本発明の一実施例におけるページテーブルによ
るアドレス変換を説明する図である。
FIG. 2 is a diagram illustrating address conversion by a page table according to an embodiment of the present invention.

【図3】本発明の一実施例における拡張ページテーブル
によるアドレス変換を説明する図である。
FIG. 3 is a diagram illustrating address conversion by an extended page table according to an embodiment of the present invention.

【図4】本発明の一実施例におけるアドレス変換の処理
フローを示す図である。
FIG. 4 is a diagram showing a processing flow of address conversion in one embodiment of the present invention.

【図5】本発明の一実施例におけるTLBおよび拡張T
LBによるアドレス変換を説明する図である。
FIG. 5 shows TLB and extended T in one embodiment of the present invention.
FIG. 4 is a diagram illustrating address conversion by LB.

【図6】本発明の他の実施例によるアドレス変換を説明
する。
FIG. 6 illustrates an address translation according to another embodiment of the present invention.

【図7】本発明によるアドレス変換方法を適用するプロ
セッサの一実施例のブロック図である。
FIG. 7 is a block diagram of an embodiment of a processor to which an address translation method according to the present invention is applied.

【符号の説明】 101 仮想アドレス 102 ページテーブルおよびTLBによるアドレス変
換機構 103 拡張ページテーブルおよび拡張TLBによるア
ドレス変換機構 104 セレクタ 203 ページテーブル 204 ページテーブルエントリ 303 拡張ページテーブル 304 拡張ページテーブルエントリ 510 TLB 520 拡張TLB 710 CPU 720 主記憶
[Description of Signs] 101 Virtual address 102 Address conversion mechanism using page table and TLB 103 Address conversion mechanism using extended page table and extended TLB 104 Selector 203 Page table 204 Page table entry 303 Extended page table 304 Extended page table entry 510 TLB 520 Extension TLB 710 CPU 720 Main memory

【手続補正2】[Procedure amendment 2]

【補正対象書類名】図面[Document name to be amended] Drawing

【補正対象項目名】図5[Correction target item name] Fig. 5

【補正方法】変更[Correction method] Change

【補正内容】[Correction contents]

【図5】 FIG. 5

Claims (5)

【特許請求の範囲】[Claims] 【請求項1】 仮想アドレスを実アドレスに変換する機
構を備えたプロセッサにおける動的アドレス変換方法で
あって、 仮想アドレスから実アドレスへのマッピング単位をペー
ジサイズと拡張ページサイズの複数とし、 ページサイズのマッピングを定義したページテーブル
と、拡張ページサイズを定義した拡張ページテーブルと
を用意し、 命令実行時に、ページテーブル、拡張ページテーブルに
より、仮想アドレスを実アドレスに変換することを特徴
とする動的アドレス変換方法。
1. A dynamic address translation method in a processor having a mechanism for translating a virtual address into a real address, wherein a mapping unit from a virtual address to a real address is set to a plurality of page sizes and extended page sizes. Dynamic mapping characterized by preparing a page table defining the mapping of the above and an extended page table defining the extended page size, and converting a virtual address to a real address by the page table and the extended page table when executing an instruction. Address translation method.
【請求項2】 請求項1記載のアドレス変換方法におい
て、 アドレス変換に利用したページテーブルのマッピング情
報のコピーを保持する手段(以下、TLBと称す)、ア
ドレス変換に利用した拡張ページテーブルのマッピング
情報のコピーを保持する手段(以下、拡張TLBと称
す)を備え、 命令実行時、はじめにTLB、拡張TLBにより仮想ア
ドレスから、実アドレスへの変換を試み、該アドレス変
換に失敗した場合にページテーブル、拡張ページテーブ
ルにより仮想アドレスを実アドレスに変換することを特
徴とする動的アドレス変換方法。
2. The address translation method according to claim 1, wherein means for holding a copy of mapping information of a page table used for address translation (hereinafter referred to as TLB), and mapping information of an extended page table used for address translation. (Hereinafter, referred to as an extended TLB). At the time of executing an instruction, first, a translation from a virtual address to a real address is attempted by the TLB and the extended TLB, and if the address translation fails, a page table. A dynamic address translation method comprising: translating a virtual address into a real address using an extended page table.
【請求項3】 請求項1、2記載のアドレス変換方法に
おいて、複数の拡張ページサイズを用意し、その中から
任意に選択することを特徴とする動的アドレス変換方
法。
3. The dynamic address translation method according to claim 1, wherein a plurality of extended page sizes are prepared and arbitrarily selected from among them.
【請求項4】 請求項1乃至3記載のアドレス変換方法
において、命令フェッチアドレス変換にはページサイズ
を用い、ロード・ストア命令アクセスのアドレス変換に
はページサイズと拡張ページサイズの両方を用いること
を特徴とする動的アドレス変換方法。
4. The address conversion method according to claim 1, wherein a page size is used for instruction fetch address conversion, and both a page size and an extended page size are used for load / store instruction access address conversion. Characteristic dynamic address translation method.
【請求項5】 仮想アドレスを実アドレスに変換する機
構を備えたプロセッサにおいて、 仮想アドレスから実アドレスへのマッピング単位をペー
ジサイズとし、該ページサイズのマッピングを定義した
ページテーブルと、アドレス変換に利用したページテー
ブルのマッピング情報のコピーを保持するTLBと、命
令実行時にTLB、ページテーブルに従い仮想アドレス
を実アドレスに変換する手段からなる第1アドレス変換
系と、 仮想アドレスから実アドレスへのマッピング単位を拡張
ページサイズとし、該拡張ページサイズのマッピングを
定義した拡張ページテーブルと、アドレス変換に利用し
た拡張ページテーブルのマッピング情報のコピーを保持
する拡張TLBと、命令実行時に拡張TLB、拡張ペー
ジテーブルに従い仮想アドレスを実アドレスに変換する
手段からなる第2アドレス変換系と、を具備しているこ
とを特徴とするプロセッサ。
5. A processor having a mechanism for converting a virtual address to a real address, wherein a unit of mapping from the virtual address to the real address is a page size, and a page table defining the mapping of the page size is used for address conversion. A first address translation system comprising means for translating a virtual address into a real address according to the TLB and the page table when executing an instruction, and a mapping unit from the virtual address to the real address. The extended page size is defined as the extended page size, the extended page table defining the mapping of the extended page size, the extended TLB holding a copy of the extended page table mapping information used for address translation, the extended TLB at the time of executing the instruction, address Processor, characterized in that it comprises a second address translation system comprising a means for converting the address, the.
JP10361028A 1998-12-18 1998-12-18 Dynamic address conversion method and processor Pending JP2000181799A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP10361028A JP2000181799A (en) 1998-12-18 1998-12-18 Dynamic address conversion method and processor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP10361028A JP2000181799A (en) 1998-12-18 1998-12-18 Dynamic address conversion method and processor

Publications (1)

Publication Number Publication Date
JP2000181799A true JP2000181799A (en) 2000-06-30

Family

ID=18471893

Family Applications (1)

Application Number Title Priority Date Filing Date
JP10361028A Pending JP2000181799A (en) 1998-12-18 1998-12-18 Dynamic address conversion method and processor

Country Status (1)

Country Link
JP (1) JP2000181799A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006525607A (en) * 2003-04-30 2006-11-09 シリコン・グラフィックス・インコーポレイテッド System and method for performing address translation in a computer system

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006525607A (en) * 2003-04-30 2006-11-09 シリコン・グラフィックス・インコーポレイテッド System and method for performing address translation in a computer system

Similar Documents

Publication Publication Date Title
US4731739A (en) Eviction control apparatus
US4332010A (en) Cache synonym detection and handling mechanism
KR100297454B1 (en) Computer
US4797814A (en) Variable address mode cache
US5282274A (en) Translation of multiple virtual pages upon a TLB miss
US6256715B1 (en) System and method of performing gateway access
EP1941375B1 (en) Caching memory attribute indicators with cached memory data
US5060137A (en) Explicit instructions for control of translation lookaside buffers
US6189074B1 (en) Mechanism for storing system level attributes in a translation lookaside buffer
US20130262816A1 (en) Translation lookaside buffer for multiple context compute engine
US6493812B1 (en) Apparatus and method for virtual address aliasing and multiple page size support in a computer system having a prevalidated cache
EP1096385A1 (en) A method and apparatus for forming an entry address
US6625714B1 (en) Parallel distributed function translation lookaside buffer
JPH03194632A (en) Cache access on the basis of translation look ahead
US6732238B1 (en) Set-associative cache memory having variable time decay rewriting algorithm
WO1995016963A1 (en) Variable page size translation lookaside buffer
JPH10177520A (en) Data processor and data processing system
JPH04320553A (en) Address converting mechanism
US6553477B1 (en) Microprocessor and address translation method for microprocessor
US6766434B2 (en) Method for sharing a translation lookaside buffer between CPUs
US5737575A (en) Interleaved key memory with multi-page key cache
US5479629A (en) Method and apparatus for translation request buffer and requestor table for minimizing the number of accesses to the same address
US6990551B2 (en) System and method for employing a process identifier to minimize aliasing in a linear-addressed cache
EP0212129B1 (en) Method of updating information in a translation lookaside buffer
US4648033A (en) Look-aside buffer LRU marker controller

Legal Events

Date Code Title Description
A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20060329

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20060405

A02 Decision of refusal

Free format text: JAPANESE INTERMEDIATE CODE: A02

Effective date: 20060726