Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
JP2608680B2 - CPU execution method - Google Patents
[go: Go Back, main page]

JP2608680B2 - CPU execution method - Google Patents

CPU execution method

Info

Publication number
JP2608680B2
JP2608680B2 JP5501650A JP50165093A JP2608680B2 JP 2608680 B2 JP2608680 B2 JP 2608680B2 JP 5501650 A JP5501650 A JP 5501650A JP 50165093 A JP50165093 A JP 50165093A JP 2608680 B2 JP2608680 B2 JP 2608680B2
Authority
JP
Japan
Prior art keywords
address
address space
match
memory
entry
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.)
Expired - Lifetime
Application number
JP5501650A
Other languages
Japanese (ja)
Other versions
JPH06500417A (en
Inventor
アンドリュー エイチ メイソン
ジュディス エス ホール
リチャード ティー ワイテク
ポール ティー ロビンソン
Original Assignee
ディジタル イクイップメント コーポレイション
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
Priority claimed from US07/722,869 external-priority patent/US5319760A/en
Application filed by ディジタル イクイップメント コーポレイション filed Critical ディジタル イクイップメント コーポレイション
Publication of JPH06500417A publication Critical patent/JPH06500417A/en
Application granted granted Critical
Publication of JP2608680B2 publication Critical patent/JP2608680B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Landscapes

  • Memory System Of A Hierarchy Structure (AREA)

Description

【発明の詳細な説明】 発明の技術分野 本発明はデジタルコンピュータ、特に多重プロセッサ
を実行するCPU用の仮想管理システムに関するものであ
る。
Description: FIELD OF THE INVENTION The present invention relates to digital computers, and more particularly to a virtual management system for a CPU running multiple processors.

発明の背景 仮想メモリ管理システムを実行する簡略命令セットプ
ロセッサチップは既知である。かかるシステムではメモ
リ参照を実行する前に仮想アドレスを物理アドレスにト
ランスレートし、この物理アドレスを主メモリのアクセ
スに用いるようにしている。この物理アドレスは仮想ア
ドレスでインデックスされたページテーブルに保持し、
従って仮想メモリが存在する度毎にメモリ管理システム
はページテーブルを参照して物理アドレスを見いだすよ
うにする。所定時にかかるマシンで実行するプロセスは
数ページのみを用い従ってこれら最尤度に用いられるペ
ージテーブルエントリをCPUチップ自体内でトランスレ
ーションバッファに保持し、これによりメモリ参照を用
いてページテーブルエントリをフェッチする必要性を除
去するようにする。トランスレーションバッファに含ま
れるページテーブルエントリは特権情報、アクセス権等
のようなメモリ管理システムによって用いられる他の情
報を含んで保全およびローバスト作動を提供するもので
ある。メッセージ参照を許容する前にプロセッサの現在
の状態およびメモリ参照の特性をページテーブルエント
リの情報に対しチェックしてメモリ参照が好適であるこ
とを確証する。
BACKGROUND OF THE INVENTION Simplified instruction set processor chips for implementing virtual memory management systems are known. In such a system, a virtual address is translated into a physical address before executing a memory reference, and this physical address is used for accessing the main memory. This physical address is stored in the page table indexed by the virtual address,
Therefore, every time a virtual memory exists, the memory management system refers to the page table to find a physical address. The process running on such a machine at a given time uses only a few pages and therefore holds the page table entries used for these maximum likelihoods in a translation buffer within the CPU chip itself, thereby fetching the page table entries using memory references Try to eliminate the need to The page table entries contained in the translation buffer include other information used by the memory management system, such as privilege information, access rights, etc., to provide integrity and robust operation. Before allowing a message reference, the current state of the processor and the characteristics of the memory reference are checked against the information in the page table entries to confirm that the memory reference is preferred.

多数のプロセス(タスク)は所定時間にCPUで時分割
態様で実行でき、且つこれらプロセスの各々は仮想メモ
リのそれ自体の区域を有する。作動システム自体はこれ
らプロセスの各々によって参照する必要のある多数のペ
ージを含む。従ってプロセスによって斯様に分割された
ページはスワップアウトされるよりも主メモリに好適に
保持され、しかも、かかるページのページテーブルエン
トリはトランスレーションバッファに保持されるのが好
適である。その理由はこれらエントリが継続して参照さ
れるからである。しかし、トランスレーションバッファ
はコンテキストスイッチが実行される際にすべてのエン
トリを無効とすることによって通常フラッシュされるよ
うになる。
Many processes (tasks) can be executed in a time-division manner on the CPU at a given time, and each of these processes has its own area of virtual memory. The actuation system itself contains a number of pages that need to be referenced by each of these processes. Thus, pages so divided by the process are preferably held in main memory rather than swapped out, and the page table entries for such pages are preferably held in a translation buffer. The reason is that these entries are referred to continuously. However, the translation buffer is usually flushed by invalidating all entries when a context switch is performed.

いわゆる“アドレススペース番号”を用いるメカニズ
ムはプロセッサで実行して、文脈スイッチが発生する際
にプロセス−特定アドレスに対するトランスレーション
バッファでキャッシュアドレストランスレーションを無
効にする必要性を減少する。現在のプロセスに対するア
ドレススペース番号(プロセスタグ)をプロセッサのレ
ジスタにロードして現在の状態の一部分となるようにす
る。即ち、このロードはメッセージのプロセス−特定ブ
ロックから特権命令によって行う。これがため各プロセ
スはこれをアドレススペース番号と関連させ、このアド
レススペース番号は作動システムによって発生した任意
−アサイン番号である。このアドレススペース番号はマ
シン状態の一部分として保持されるとともにこのプロセ
スに属する各ページエントリに対するトランスレーショ
ンバッファにも記憶する。メモリ参照を行うと、トラン
スレーションバッファにおけるタグ整合の一部分として
メモリ参照を行うと、現在のアドレススペース番号をト
ランスレーションバッファのエントリと比較して整合が
あるかどうかをみる。エントリの分割を収容するため
に、アドレススペース整合機能を上記比較されたものに
加えることができる;即ち、エントリ内の“整合”ビッ
トによってアドレススペース番号を整合する要求をター
ンオンまたはオフすることができる。このビットがター
ンオンすると、エントリはアドレスタグが整合するかど
うかをアドレススペース番号に関係なく“整合”する。
これがため、動作システムはあるページテーブルエント
リをこの整合ビットでロードしてこれらページがすべて
のプロセスにより分割されるようにする。
A mechanism using so-called "address space numbers" is implemented in the processor to reduce the need to disable cache address translation in the translation buffer for a process-specific address when a context switch occurs. Load the address space number (process tag) for the current process into the processor's registers so that it becomes part of the current state. That is, this loading is performed by a privileged instruction from the message process-specific block. This causes each process to associate it with an address space number, which is an arbitrary-assign number generated by the operating system. This address space number is kept as part of the machine state and is also stored in the translation buffer for each page entry belonging to this process. If a memory reference is made as part of the tag match in the translation buffer, the current address space number is compared with the translation buffer entry to see if there is a match. To accommodate the splitting of entries, an address space matching function can be added to the above comparison; that is, a request to match the address space number by the "match" bit in the entry can be turned on or off. . When this bit is turned on, the entry "matches" whether the address tag matches regardless of the address space number.
Because of this, the operating system loads certain page table entries with this match bit so that these pages are split by all processes.

仮想マシンを用いるCPUの作動に当たり、各仮想マシ
ンはこれが独立のプロセッサであるかのように機能し、
且つ各仮想マシンは、ただ一つのCPUを機能させる際
に、仮想マシン作動システムおよび多数のプロセスラン
ニングを有する。仮想マシンは、シービオレック等著
“コンピュータの構成:原理および例”、マックグロー
ヒル社発行、1982年、第227−228頁に記載されている。
これらの仮想マシンを作動させるために、仮想マシンモ
ニタ(他の実行レベル)を実行する。前述したように、
仮想マシンでプロセッサの全部により用いられる動作シ
ステムによって使用されるページがある。また、プロセ
ス間あるいは仮想マシン間にコンテキストスイッチを設
ける場合にページのエントリがトランスレーションバッ
ファに保持されているとその性能が改善されるようにな
る。
In operating a CPU using virtual machines, each virtual machine functions as if it were an independent processor,
And each virtual machine has a virtual machine operating system and multiple process running when only one CPU is functioning. The virtual machine is described in "Composition of Computers: Principles and Examples" by C. Biolec et al., Published by McGraw-Hill, 1982, pp. 227-228.
To run these virtual machines, run a virtual machine monitor (another execution level). As previously mentioned,
There are pages used by the operating system used by all of the processors in the virtual machine. When a context switch is provided between processes or between virtual machines, the performance is improved if page entries are held in the translation buffer.

数個の仮想マシンおよびCPUで実行される仮想マシン
メモリは互いに離間され且つ分離されたメモリスペース
を有し、しかもシステムの性能を最大とする必要があ
る。この目的のために、仮想マシンおよび仮想マシンモ
ニタは他の目的に対し同一の仮想アドレスを用いうるよ
うにする必要がある。しかし、文脈が1つの仮想マシン
から他の仮想マシンに、または仮想マシンモニタに切換
える場合あるいは仮想マシンモニタから切換える場合に
は新たな文脈に用いられるトランスレーションバッファ
にエントリを不必要にフラッシュすることによって性能
ペナルティを課すようにする。これがため、仮想マシン
を実行する際アドレススペース番号および整合特性の双
方をオッファするのが重要である。
Several virtual machines and virtual machine memories running on the CPU need to have separate and separated memory spaces, while maximizing system performance. For this purpose, the virtual machine and the virtual machine monitor need to be able to use the same virtual address for other purposes. However, when the context switches from one virtual machine to another, or to a virtual machine monitor, or when switching from a virtual machine monitor, by unnecessarily flushing the entry into the translation buffer used for the new context. Try to impose a performance penalty. For this reason, it is important to offer off both address space numbers and matching characteristics when running a virtual machine.

発明の概要 本発明は仮想アドレスを物理アドレスにトランスレー
トするトランスレーションバッファを具えたプロセッサ
の作動方法において、 このトランスレーションバッファに、各々が仮想アド
レスタグによりインデックスされたページフレーム番号
を含む複数のページテーブルエントリを記憶させ; さらにこのトランスレーションバッファには、各ペー
ジテーブルエントリに対しアドレススペース番号および
アドレススペース整合エントリをも記憶させ、ここにお
いて、このアドレススペース番号は前記プロセッサで実
行されたプロセスに対応する値であり、前記整合エント
リは、アドレススペース番号が整合される必要があるこ
とを示すある値を有し、且つアドレススペース番号が整
合される必要がないことを示す他の値を有するフィール
ドであり、 前記プロセッサの状態を反映する値としてこのプロセ
ッサに現在の番号を記憶させ、 前記整合エントリをディスエーブルする必要があると
いうある条件と、ディスエーブルする必要がないという
他の条件とを示す第3の整合値を記憶させ、 前記仮想アドレスタグと前記プロセッサにより発生し
た仮想アドレスのフィールドとを比較するとともに、前
記アドレススペース番号と前記現在の番号とを比較し
て、前記仮想アドレスタグと仮想アドレスの前記フィー
ルドの比較で整合あるときは; 前記アドレススペース番号と前記現在の番号との比較
によって前記整合が生じ、且つ整合エントリが前記ある
値である場合には、メモリ参照に対し前記ページフレー
ム番号を用い;かつ 前記整合エントリが前記他の値であっても、前記第3
の整合値が前記ある条件を示す場合には、前記アドレス
スペース番号が前記現在の番号と整合するかどうかにか
かわらずメモリ参照に対しページフレーム番号を用いる
各ステップを具えることを特徴とする。
SUMMARY OF THE INVENTION The present invention is a method of operating a processor comprising a translation buffer for translating a virtual address to a physical address, the translation buffer comprising a plurality of pages each including a page frame number indexed by a virtual address tag. The translation buffer also stores an address space number and an address space match entry for each page table entry, wherein the address space number corresponds to a process executed on the processor. The matching entry has a value indicating that the address space numbers need to be matched and a flag having another value indicating that the address space numbers need not be matched. A condition that the processor must store the current number as a value reflecting the state of the processor and that the matching entry needs to be disabled and another condition that does not need to be disabled. Storing the third match value, and comparing the virtual address tag with a field of a virtual address generated by the processor, comparing the address space number with the current number, and comparing the virtual address tag with the virtual address tag. If the comparison of the field of the virtual address is consistent; the match occurs by comparing the address space number with the current number, and if the matching entry is the certain value, the page relative to a memory reference Using a frame number; and even if the matching entry is the other value, Third
If the match value indicates the condition, the method includes using a page frame number for memory reference regardless of whether the address space number matches the current number.

また、本発明はCPUおよびメモリを有するプロセッサ
システムにおいて、a)前記CPU内で前記メモリから命
令をフェッチし、このCPU内でこの命令を復号化し、CPU
内で読取りおよび書込みデータのメモリにアクセスする
命令を実行する手段と; b)前記CPU内で前記命令のフェッチ手段およびデータ
メモリのアクセス手段に用いられる仮想アドレスを発生
する手段と; c)前記メモリ内に記憶され各々が前記メモリの異なる
ページを参照するページフレーム番号を有する複数のペ
ージテーブルエントリを含むページテーブルと; d)多数の前記ページテーブルエントリを記憶するトラ
ンスレーションバッファを含み、前記メモリに対し仮想
アドレスを物理アドレスにトランスレートする手段と; e)前記トランスレーションバッファからのページフレ
ーム番号を用いるとともに仮想アドレスの一部分を用い
るメモリをアドレス指定する手段とを具え; f)前記トランスレーションバッファは各ページテーブ
ルエントリに対しアドレスタグおよびアドレススペース
番号を記憶するとともにアドレススペース整合エントリ
を記憶し、ここで前記アドレススペース番号は前記CPU
で実行されたプロセスに対応する値とし、且つ前記整合
エントリはアドレススペース番号が整合される必要があ
ることを示すある値と、かつアドレススペース番号が整
合される必要のないことを示す他の値とを有するインデ
ィケータとし、また前記トランスレーションバッファは
各ページテーブルエントリに対し整合ディスエーブルイ
ンディケータをも記憶し、前記CPU内で現在の値を記憶
する手段によって前記CPUのある状態の一部として保持
されるアドレススペース番号を表わし; g)トランスレーションバッファ内で前記アドレスタグ
と前記CPUにより発生した前記仮想アドレスのフィール
ドとを比較するとともに前記アドレススペース番号と前
記CPUの前記状態の部分として保持される前記現在の番
号とをも比較する比較手段とを具え; 前記比較手段による比較動作の双方が整合を発生する
とともに前記整合エントリが前記ある値である場合には
前記アドレス指定手段はメモリ参照に対しあるページフ
レーム番号を用い;また 前記アドレスタグと前記仮想アドレスのフィールドと
の比較により整合が生ずる場合および前記整合エントリ
が前記他の値である場合には、前記ディスエーブル整合
インディケータをセットしなれば、前記アドレススペー
ス番号が前記現在の番号と整合するかどうかにかかわら
ず前記アドレス指定手段が前記メモリ参照に対し前記ペ
ージフレーム番号を用いるようにしたことを特徴とす
る。
The present invention also relates to a processor system having a CPU and a memory, comprising: a) fetching an instruction from the memory in the CPU, decoding the instruction in the CPU,
Means for executing instructions for accessing a memory of read and write data within; b) means for generating virtual addresses for use in said instruction fetch means and data memory access means within said CPU; c) said memory A page table including a plurality of page table entries each having a page frame number referring to a different page of the memory; and d) including a translation buffer for storing a number of the page table entries; Means for translating a virtual address to a physical address; and e) means for addressing a memory using a page frame number from said translation buffer and using a portion of the virtual address; f) said translation buffer comprising: Each page Storing the address space matching entry stores the address tag and the address space number for table entries, wherein said address space number is the CPU
And a value indicating that the address space numbers need to be matched, and another value indicating that the address space numbers do not need to be matched. And the translation buffer also stores a matching disable indicator for each page table entry and is held as part of a state of the CPU by means for storing a current value in the CPU. G) comparing the address tag with a field of the virtual address generated by the CPU in a translation buffer and maintaining the address space number and a portion of the state of the CPU. With means for comparing also with the current number; When both of the comparing operations by the comparing unit generate a match and the matching entry is the certain value, the address specifying unit uses a certain page frame number for memory reference; If a match occurs due to a comparison with a field and if the match entry is the other value, setting the disable match indicator will determine whether the address space number matches the current number. Regardless, the address designating means uses the page frame number for the memory reference.

本発明の1例によれば、仮想メモリ管理システムを実
行するCPUはアドレススペース番号特性を用いてエント
リを現在実行されていないプロセスのトランスレーショ
ンバッファに残存せしめるとともに個別のプロセスまた
は動作システムによって共通に参照されたメモリのかか
るページに対するトランスレーションバッファのエント
リを再使用する。これを行うために、アドレススペース
番号を整合する必要のない場合でもアドレスが整合する
際にトランスレーションバッファコンテントを用い得る
ページテーブルエントリ信号に“アドレススペース整
合”エントリを使用する。このCPUで仮想マシンを実行
する場合には仮想マシン内にアドレススペース整合特性
を用いるが、追加のエントリを用いて仮想マシンモニタ
用のすべてのアドレススペース番号に対しアドレススペ
ース整合特性を実行不可能とする。他の例では追加のエ
ントリをトランスレーションバッファに用いて単一仮想
マシンまたは仮想マシンモニタに関連するアドレススペ
ースにアドレススペース整合特性を制限する。
According to one embodiment of the present invention, a CPU executing a virtual memory management system uses an address space number characteristic to cause an entry to remain in a translation buffer of a currently unexecuted process and be shared by individual processes or operating systems. Reuse the translation buffer entry for such a page of referenced memory. To do this, an "address space match" entry is used in the page table entry signal that can use the translation buffer content when the addresses match, even if the address space numbers do not need to match. When executing a virtual machine with this CPU, the address space matching property is used in the virtual machine, but it is impossible to execute the address space matching property for all the address space numbers for the virtual machine monitor using an additional entry. I do. In another example, additional entries are used in the translation buffer to limit address space matching properties to the address space associated with a single virtual machine or virtual machine monitor.

図面の簡単な説明 図1は、本発明の特徴を採用し得るCPUを有するコン
ピュータシステムの電気回路のブロック図; 図2は図1のCPUの命令ユニット、即ち、I−ボック
スの電気回路のブロック図; 図3は図1のCPUの整数実行ユニット、即ち、E−ボ
ックスの電気回路のブロック図、 図4は図1のCPUのアドレス指定ユニット、即ち、A
−ボックスの電気回路のブロック図; 図5は図1のCPUの浮動少数点実行ユニット、即ち、
F−ボックスの電気回路のブロック図; 図6は図1〜5のCPUにおけるパイプリングの時間ダ
イアグラムを示す説明図; 図7は図1〜5のCPUの命令セットに使用する命令フ
ォーマットのダイアグラムを示す説明図; 図8は図1〜5のCPUに使用する仮想アドレスのフォ
ーマットのダイアグラムを示す説明図; 図9は図1〜5のCPUに使用する仮想アドレスのフォ
ーマットのダイアグラムを示す説明図; 図10は図1〜5のCPUに使用するアドレストランスレ
ーションメカニズムのダイアグラムを示す説明図; 図11は図1〜5のシステムに使用する仮想対物理アド
レスマッピングのダイアグラムを示す説明図; 図12は図1〜5のシステムに使用するプロセス制御プ
ロセッサのダイアグラムを示す説明図; 図13は図1〜5のシステムを仮想マシンとともに作動
する例に対するアドレススペース番号のテーブルを示す
説明図; 図14は本発明の特徴を用いるトランスレーションバッ
ファエントリの評価マシンのダイアグラムを示す説明
図: 図15は本発明の他の例に対するトランスレーションバ
ッファエントリのダイアグラムを示す説明図である。
BRIEF DESCRIPTION OF THE DRAWINGS FIG. 1 is a block diagram of an electrical circuit of a computer system having a CPU that may employ features of the present invention; FIG. 2 is a block of instruction units of the CPU of FIG. FIG. 3 is a block diagram of an integer execution unit of the CPU of FIG. 1, ie, an electric circuit of the E-box. FIG. 4 is an addressing unit of the CPU of FIG.
FIG. 5 is a floating-point execution unit of the CPU of FIG.
FIG. 6 is a block diagram of an electric circuit of the F-box; FIG. 6 is an explanatory diagram showing a time diagram of pipelining in the CPU of FIGS. 1 to 5; FIG. FIG. 8 is an explanatory diagram showing a diagram of a format of a virtual address used for the CPU shown in FIGS. 1 to 5; FIG. 9 is an explanatory diagram showing a diagram of a format of a virtual address used for the CPU shown in FIGS. FIG. 10 is an explanatory diagram showing a diagram of an address translation mechanism used for the CPU of FIGS. 1 to 5; FIG. 11 is an explanatory diagram showing a diagram of virtual-to-physical address mapping used for the system of FIGS. 1 to 5; FIG. 13 is an explanatory diagram showing a diagram of a process control processor used in the system of FIGS. 1 to 5; FIG. 13 shows the system of FIGS. Illustration showing a table of address space numbers for a working example; FIG. 14 shows a diagram of a translation buffer entry evaluation machine using features of the invention; FIG. 15 shows a translation buffer for another example of the invention; FIG. 4 is an explanatory diagram showing a diagram of an entry.

発明を実施するための最良の形態 図1に示すように、本発明の一例によるコンピュータ
システムはシステムバス11により主メモリ12に接続され
たCPU10と、システムバス11を経てアクセスされるディ
スクメモリ13とを具える。本例ではコンピュータシステ
ムは単一CPUを用いるがマルチプロセッサ構成をとるこ
ともでき、この場合には多のCPU14もシステムバス11を
経て主メモリ12にアクセスする。
BEST MODE FOR CARRYING OUT THE INVENTION As shown in FIG. 1, a computer system according to an embodiment of the present invention includes a CPU 10 connected to a main memory 12 by a system bus 11, and a disk memory 13 accessed via the system bus 11. Equipped. In this example, the computer system uses a single CPU, but may have a multiprocessor configuration. In this case, many CPUs 14 also access the main memory 12 via the system bus 11.

CPU10は単一チップ集積回路装置とするが本発明によ
ればボードに装着された集積回路装置に構成されたプロ
セッサとすることもできる。単一チップCPU内には整数
実行ユニット16(“E−ボックス”とも称する)と、浮
動小数点実行ユニット17(“F−ボックス”とも称す
る)とを含める。フェッチおよび復号化命令は命令ユニ
ット18または“I−ボックス”で行う。アドレスユニッ
トまたは“A−ボックス"19はアドレス発生、メモリ管
理、書込みバッファリングおよびバスインターフェース
の機能を呈する。即ち、本発明による仮想アドレスシス
テムおよびトランスレーションバッファはアドレスユニ
ット19で実現する。メモリはオン−チップ命令による階
層型とするとともにデータキャッシュは1例として命令
ユニット18およびアドレスユニット19に含めるが、大型
の第2レベルキャッシュ20はアドレスユニット19のキャ
ッシュコントローラにより制御されるオフ−チップ型と
する。
Although the CPU 10 is a single-chip integrated circuit device, according to the present invention, the CPU 10 may be a processor configured in an integrated circuit device mounted on a board. A single chip CPU includes an integer execution unit 16 (also referred to as an "E-box") and a floating point execution unit 17 (also referred to as an "F-box"). Fetch and decode instructions are performed in the instruction unit 18 or "I-box". The address unit or "A-box" 19 performs the functions of address generation, memory management, write buffering and bus interface. That is, the virtual address system and the translation buffer according to the present invention are realized by the address unit 19. The memory is hierarchical with on-chip instructions and the data cache is included in the instruction unit 18 and address unit 19 as an example, while the large second level cache 20 is off-chip controlled by the cache controller of address unit 19. Type.

CPU10は、すべての命令を固定サイズ、この場合32ビ
ット即ち、1倍長語とする命令セットを採用する。メモ
リ参照は一般に整列(同期)されたクォッドワードが、
整数データ型のバイト、ワード、倍長語およびクォッド
ワードは内部的に処理する。本例で使用するように、1
バイトは8ビット、1ワードは16ビット、即ち、2バイ
ト、倍長語は32ビット、即ち、4バイト、およびクォッ
ドワードは64ビット、即ち、8バイトとする。CPU10内
のデータ経路およびレジスタは一般に64ビット、即ち、
クォッドワードの大きさとし、主メモリ12およびキャッ
シュは転送の基本ユニットとしてのクォッドワードを使
用する。性能はクォッドワードまたは倍長語ロードおよ
びメモリのみを許容することにより増大される。
The CPU 10 employs an instruction set in which all instructions have a fixed size, in this case, 32 bits, that is, a single word. Memory references are generally aligned (synchronized) quadwords,
Bytes, words, doublewords and quadwords of the integer data type are processed internally. As used in this example, 1
A byte is 8 bits, a word is 16 bits, ie, 2 bytes, a double word is 32 bits, ie, 4 bytes, and a quadword is 64 bits, ie, 8 bytes. The data paths and registers within CPU 10 are generally 64 bits,
Given the size of a quadword, the main memory 12 and cache use quadwords as the basic unit of transfer. Performance is increased by allowing only quadword or double word loads and memory.

命令ユニット18即ち、I−ボックスを図2に詳細に示
す。命令ユニット18の一次機能はE−ボックス16、A−
ボックス19、およびF−ボックス17に命令を出すことで
ある。命令ユニット18は8Kバイトの命令ストリームデー
タを記憶する命令キャッシュ21を具え、この命令ストリ
ームデータを復号化の各サイクルで命令レジスタ22にロ
ードする。一例では2つの命令を並列に復号化する。命
令はデコーダ23で復号化し、ライン26にレジスタアドレ
スを発生するとともにマイクロ制御バス28に制御ビット
を発生する。
Instruction unit 18, the I-box, is shown in detail in FIG. The primary function of the instruction unit 18 is E-box 16, A-box 16.
Box 19, and F-Box 17. The instruction unit 18 includes an instruction cache 21 for storing 8K bytes of instruction stream data, and loads the instruction stream data into the instruction register 22 in each decoding cycle. In one example, two instructions are decoded in parallel. The instruction is decoded by decoder 23, generating a register address on line 26 and a control bit on microcontrol bus 28.

命令ユニット18はレジスタ22にロードすべき命令スト
リームの命令に応答して分岐予測回路30を含むアドレス
発生回路29を具える。分岐予測回路30を用いて分岐アド
レスを予測するとともにアドレス発生回路29により必要
前の命令ストリームをプレフェッチする。前アドレス発
生回路29には仮想PC(プログラムカウンタ)33をも含め
て命令ストリームデータのアドレスを発生させるように
する。
Instruction unit 18 includes an address generation circuit 29 including a branch prediction circuit 30 in response to instructions in the instruction stream to be loaded into register 22. The branch address is predicted using the branch prediction circuit 30, and the instruction generation circuit 29 prefetches a pre-necessary instruction stream. The previous address generation circuit 29 generates an address of instruction stream data including a virtual PC (program counter) 33.

また、命令ユニット18には完全連想型トランスレーシ
ョンバッファ(TB)36を設けて最新に用いられた命令ス
トリームアドレストランスレーションおよび8Kバイトペ
ージ用の保護情報をキャッシュする。64ビットアドレス
が通常可能であるが、実際問題として43ビットアドレス
が好適である。各サイクル毎に命令ストリームTB36に対
し仮想プログラムカウンタ33を存在させる。仮想PCから
からアドレスに関連するページテーブルエントリ(PT
E)を命令ストリームTB36にキャッシュすると、ページ
フレーム番号(PFN)と仮想PCを含むページの保護ビッ
トとを用いて命令ユニット18によりアドレストランスレ
ーションおよびアクセスチェックを完了する。斯様にし
て物理アドレスを命令キャッシュ21のアドレス入力37に
供給するかまたはキャッシュミスが生じる場合にはこの
命令ストリーム物理アドレスをバス38によりアドレスユ
ニット19を経てキャッシュ20または主メモリ12に供給す
る。
Also, the instruction unit 18 is provided with a completely associative translation buffer (TB) 36 to cache the latest used instruction stream address translation and protection information for 8 Kbyte pages. A 64-bit address is usually possible, but in practice a 43-bit address is preferred. A virtual program counter 33 is provided for the instruction stream TB36 for each cycle. Page table entry related to address from virtual PC (PT
When E) is cached in the instruction stream TB36, the address translation and access check are completed by the instruction unit 18 using the page frame number (PFN) and the protection bits of the page including the virtual PC. In this way, a physical address is provided to the address input 37 of the instruction cache 21 or, in the event of a cache miss, this instruction stream physical address is provided by the bus 38 to the cache 20 or the main memory 12 via the address unit 19.

実行ユニット、即ち、E−ボックス16を図3において
詳細に説明する。実行ユニット16は論理演算装置(AL
U)40、バレルシフタ41、および整数乗算器42を含む64
ビット整数実行データ経路を具える。また、実行ユニッ
ト16はレジスタR0〜R31を含む32−レジスタ、64−ビッ
トワイドレジスタファイル43を具え、レジスタR31は全
て零にハードワイヤードされる。このレジスタファイル
43は4つの読取りポートおよび2つの書込みポートを有
し、これらポートによって整数実行データ経路およびア
ドレスユニット19の双方にオペランド(結果)をソーシ
ング(シンキング)する。バス構体44によって、命令ユ
ニット18からのライン28の復号化された命令の制御ビッ
トにより指定される際シフター41または乗算器42の選択
された入力に前記レジスタファイル43の読取りポートの
うちの2つを接続するとともに適宜の機能の出力側を前
記レジスタファイルの書込みポートのうちの1つに接続
して前記結果を記憶する。即ち、命令ユニットからのア
ドレスフィールドをライン26により供給して命令の実行
に用いる必要のあるレジスタを選択し、且つ制御ビット
28によってALU等の作動を規定するとともにバス構体44
の何れの内部バスを使用すべきかを規定する。
The execution unit or E-box 16 is described in detail in FIG. The execution unit 16 is a logical operation device (AL
U) 64 including 40, barrel shifter 41, and integer multiplier 42
Provides a bit integer execution data path. Execution unit 16 also includes a 32-register, 64-bit wide register file 43 including registers R0-R31, all of which are hardwired to zero. This register file
43 has four read ports and two write ports that source (sink) operands (results) to both the integer execution data path and the address unit 19. The bus structure 44 allows two of the read ports of the register file 43 to be applied to the selected input of the shifter 41 or the multiplier 42 as specified by the control bits of the decoded instruction on line 28 from the instruction unit 18. And the output of the appropriate function is connected to one of the write ports of the register file to store the result. That is, the address field from the instruction unit is provided on line 26 to select the register that needs to be used to execute the instruction, and the control bit
The operation of the ALU etc. is specified by 28 and the bus structure 44
Which internal bus should be used.

A−ボックス、即ち、アドレスユニット19を図4によ
り詳細に説明する。このA−ボックス19は5つの機能
を、即ち、データ経路トランスレーションバッファ48を
用いるアドレストランスレーション、データを入力する
ロードサイロ49、書込みデータを出力する書込みバッフ
ァ50、データキャッシュに対するインターフェース51、
およびバス11に対する外部インターフェース52を有す
る。このアドレストランスレーションデータ経路は読取
りポートおよび書込みポートの第2セットを経てレジス
タファイル43をアクセスすることにより有効アドレスを
発生する変位アダー53と、アドレスバス554に物理アド
レスを発生するデータTB48とを有する。
The A-box or address unit 19 will be described in more detail with reference to FIG. The A-box 19 has five functions: address translation using a data path translation buffer 48, a load silo 49 for inputting data, a write buffer 50 for outputting write data, an interface 51 for a data cache,
And an external interface 52 to the bus 11. This address translation data path has a displacement adder 53 that generates a valid address by accessing the register file 43 via a second set of read and write ports, and data TB48 that generates a physical address on an address bus 554. .

データ経路トランスレーションバッファ48は8kバイト
の大きさのページに対し後述するように多数(例えば3
2)の最新に使用されたデータストリームページテーブ
ルエントリをキャッシュする。各エントリによって4つ
の粒度ヒントのうちの任意のものをサポートするととも
に検出器55を米国特許願第547,630号に記載されている
粒度ヒントに応答し仮想アドレスバス56から物理アドレ
スバス54に通過する仮想アドレスの低次のビットの数を
変化させるようにする。
The data path translation buffer 48 has a large number (for example, 3
2) Cache the most recently used data stream page table entry. Each entry supports any of the four granularity hints and a detector 55 is passed from the virtual address bus 56 to the physical address bus 54 in response to the granularity hints described in U.S. Pat. No. 5,47,630. The number of low-order bits of the address is changed.

読取りおよび記憶命令に対しては有効43ビット仮想ア
ドレスをバス56を経てTB48に存在させる。供給された仮
想アドレスのPTEをTB48でキャッシュすると、PTEおよび
アドレスを含むページに対する保護ビットをアドレスユ
ニット19で使用してアドレストランスレショーンおよび
アクセスチェックを完了する。
For read and store instructions, a valid 43 bit virtual address is present on TB 48 via bus 56. When the PTE of the supplied virtual address is cached in the TB 48, the protection bits for the page including the PTE and the address are used in the address unit 19 to complete the address transduction and the access check.

図5に詳細に示すようにオン−チップパイプラインさ
れた浮動小数点ユニット17、即ち、F−ボックスはDEC
およびIEEE浮動小数点命令の双方を実行することができ
る。浮動小数点ユニット17は浮動小数点レジスタF0〜F3
1を有する32エントリ64ビット浮動小数点レジスタファ
イル61と、浮動小数点論理演算ユニット62を具える。除
算および乗算は乗算/除算回路63で行う。バス構体64
は、命令ユニット18からのライン28の復号化された命令
の制御ビットにより指向されるように、レジスタファイ
ル61の2つの読取りポートを適切な機能回路に相互接続
する。作動い対し選択されたレジスタは復号化された命
令から出力バス26によって規定する。浮動小数点ユニッ
ト17は、数サイクル毎に受けることができる浮動小数点
除算命令を除き各サイクル毎に命令を受ける。全ての浮
動小数点命令に対し1サイクル以上の待ち時間を設け、
この待ち時間中整数ユニットは多の命令を実行し続ける
ことができる。
As shown in detail in FIG. 5, the on-chip pipelined floating point unit 17, ie, the F-box
And IEEE floating-point instructions. The floating-point unit 17 has floating-point registers F0 to F3
It comprises a 32-entry 64-bit floating-point register file 61 having a 1 and a floating-point logical operation unit 62. The division and multiplication are performed by the multiplication / division circuit 63. Bus structure 64
Interconnects the two read ports of the register file 61 to the appropriate functional circuits, as directed by the control bits of the decoded instruction on line 28 from the instruction unit 18. The register selected for operation is defined by the output bus 26 from the decoded instruction. Floating point unit 17 receives instructions every cycle, except for floating point divide instructions, which can be received every few cycles. Provide a wait time of at least one cycle for all floating-point instructions,
During this latency, the integer unit can continue to execute many instructions.

1例では、CPU10は8kバイトデータキャッシュ59およ
び8kバイト命令キャッシュ21を有し、このキャッシュの
大きさは有効なチップ面積に依存する。オン−チップデ
ータキャッシュ59はライトスルー直線マップ読取りアロ
ケイト物理キャッシュであり、32バイト(1−ヘキサワ
ード)ブロックを有する。従ってシステムは無効バス
(図示せず)を用いることにより主メモリ12と同期して
データキャッシュ59を保持することができる。
In one example, CPU 10 has an 8 kbyte data cache 59 and an 8 kbyte instruction cache 21, the size of which depends on the available chip area. The on-chip data cache 59 is a write-through linear map read allocate physical cache and has 32 byte (1-hexaword) blocks. Accordingly, the system can maintain the data cache 59 in synchronization with the main memory 12 by using an invalid bus (not shown).

命令キャッシュ21は8kバイトまたは16kバイトとする
ことができ、あるいは半導体ICチップの面積に依存して
大きくまたは小さくすることができる。上述した所では
TB36による物理アドレッシングを用いるがこれを仮想キ
ャッシュとすることもでき、この場合には主メモリ12と
の同期を保持する手段を設けない。キャッシュ21を物理
アドレスキャッシュとする場合には、チップには主メモ
リとの同期を保持する主段を設ける:(1)書込みバッ
ファ50のエントリをバスインターフェース52に送る場合
にはアドレスを二重命令キャッシュ21のタグに対し比較
し、且つ命令キャッシュ21の関連するブロックを条件付
で無効とする;(2)無効バスは命令キャッシュ2)に
接続する。
Instruction cache 21 can be 8 kbytes or 16 kbytes, or can be larger or smaller depending on the area of the semiconductor IC chip. In the places mentioned above
Although physical addressing by the TB 36 is used, this can be used as a virtual cache. In this case, there is no means for maintaining synchronization with the main memory 12. When the cache 21 is a physical address cache, the chip is provided with a main stage for maintaining synchronization with the main memory: (1) When an entry of the write buffer 50 is sent to the bus interface 52, the address is duplicated. Compare against tags in cache 21 and conditionally invalidate the associated block in instruction cache 21; (2) Invalidate bus connects to instruction cache 2).

主データ経路およびCPU10のレジスタを64ビット幅と
する。整数レジスタ(レジスタファイルをも構成する)
43の各々および浮動小数点レジスタ61の各々は64ビット
レジスタであり、ALU40は64ビット入力40aおよび40b並
びに64ビット出力40cを有する。実際上、1つ以上のバ
スより成る実行ユニット16のバス構体44は整数レジスタ
(レジスタファイルをも構成する)43とALU40の入力お
よび出力との間にオペランドを転送する64ビットの広い
データ経路を有する。命令デコーダ23はレジスタアドレ
ス出力26を発生し、これらレジスタアドレス出力を整数
レジスタ(レジスタファイルをも構成する)43および/
または浮動小数点レジスタ61のアドレス指定回路に供給
して何れのレジスタオペランドをALU41または62への入
力として用いるか、およびレジスタ43または61の何れを
ALU(または多の機能ユニット)の出力の宛先とするか
を選択する。
The main data path and the register of the CPU 10 have a 64-bit width. Integer registers (also make up the register file)
Each of 43 and each of floating point registers 61 are 64-bit registers, and ALU 40 has 64-bit inputs 40a and 40b and 64-bit output 40c. In effect, the bus structure 44 of the execution unit 16 comprising one or more buses provides a 64-bit wide data path for transferring operands between the integer register (which also comprises the register file) 43 and the inputs and outputs of the ALU 40. Have. The instruction decoder 23 generates a register address output 26, and outputs these register address outputs to an integer register (which also forms a register file) 43 and / or
Alternatively, it is supplied to the addressing circuit of the floating-point register 61, which register operand is used as an input to the ALU 41 or 62, and which register 43 or 61 is used.
Selects the output destination of ALU (or multiple functional units).

この例の図1〜6のCPU10の特性はそのRISC特徴であ
る。このCPU10により実行された命令は可変長さの命令
とする代わりに、常時同一の大きさ、この場合には32ビ
ットである。これらの命令は可変数のサイクルよりも
(後述するようにパイプラインされ、機能停止されない
ものとすると)平均で1マシンサイクルで実行されるよ
うになる。命令セットはレジスタ−レジスタ論理演算型
の作動、またはレジスタ−メモリ(またはメモリ−レジ
スタ)ロード/記憶型の作動を含み、間接、等のような
複雑なメモリアドレス指定モードは存在しない。ALU40
で作動を行う命令はレジスタファイル43から(または命
令自体のファイルから)そのオペランドを常時得るとと
もにその結果をレジスタファイル43に常時書込む;これ
らオペランドはメモリからは決して得られず、且つ前記
結果はALU作動を呈する同一の命令のメモリに決して書
込まれない。メッセージからのロードはレジスタファイ
ル43または61のレジスタに対する常時行われるとともに
メモリへの書込みはレジスタファイルのレジスタから常
時行われる。
The characteristics of the CPU 10 of FIGS. 1 to 6 in this example are its RISC characteristics. The instructions executed by the CPU 10 are always of the same size, in this case 32 bits, instead of being of variable length. These instructions will execute in an average of one machine cycle rather than a variable number of cycles (assuming they are pipelined and not disabled, as described below). The instruction set includes register-register logical operation type operation, or register-memory (or memory-register) load / store type operation, and there is no complicated memory addressing mode such as indirect. ALU40
The instructions that operate on always get their operands from register file 43 (or from their own files) and always write their results to register file 43; these operands are never obtained from memory, and the results are It is never written to the memory of the same instruction exhibiting ALU operation. The loading from the message is always performed to the register of the register file 43 or 61, and the writing to the memory is always performed from the register of the register file.

図6に示すように、CPU10は整数作動およびメモリ参
照命令に対し7つのステージパイプラインを有する。図
6は実行ユニット16、命令ユニット18およびアドレスユ
ニット19のパイプラインに対するパイプラインダイアグ
ラムである。浮動小数点ユニット17によって実行ユニッ
ト16のパイプラインに並列なパイプラインを規定する
が、通常実行に一層多数のステージを用いる。7つのス
テージはS0−S6と称し、1つのステージは1マシンサイ
クル(クロックサイクル)で実行する必要がある。最初
の4つのステージS0,S1,S2およびS3は命令ユニット18で
実行されるとともに最後の3つのステージS4,S5およびS
6は、命令が1作動または1ロード/メモリであるか否
かに依存して実行ユニット16またはアドレスユニット19
の一方または他方で実行する。
As shown in FIG. 6, CPU 10 has seven stage pipelines for integer operation and memory reference instructions. FIG. 6 is a pipeline diagram for the pipeline of the execution unit 16, the instruction unit 18 and the address unit 19. The floating point unit 17 defines a pipeline parallel to the pipeline of the execution unit 16, but typically uses more stages for execution. The seven stages are called S0-S6, and one stage needs to be executed in one machine cycle (clock cycle). The first four stages S0, S1, S2 and S3 are executed in the instruction unit 18 and the last three stages S4, S5 and S3
6 is an execution unit 16 or an address unit 19 depending on whether the instruction is one operation or one load / memory.
On one or the other.

パイプラインの第1ステージS0は命令フェッチまたは
IFステージであり、このステージ中命令ユニット18はPC
33アドレスをベースとして用いて命令フェッチ21から新
たな命令をフェッチする。第2ステージS2は評価ステー
ジであり、このステージ中2つのフェッチされた命令を
評価して二重イッシューが可能であるかどうかをみる。
第3ステージS2は復号化ステージであり、このステージ
中命令をデコーダ23で復号化してライン26に制御信号28
およびレジスタアドレスを発生する。第4ステージは作
動命令のステージおよび命令イッシューステージをアク
セスするレジスタファイル43である。第5ステージS4は
動作命令が存在する場合(例えばALU40における)計算
のサイクル−1であり、しかも命令ユニット18はアドレ
ス発生器29の新たなPC33を計算する;メモリ参照命令が
存在する場合アドレスユニット19はアダー53を用いて有
効データストリームアドレスを計算する。第6ステージ
S5は作動命令がある場合(例えばALU40における)計算
のサイクル−2であり、しかもデータTB48はメモリ参照
ステージを検索する。最後のステージS6はレジスタ書込
みを有する作動命令の書込みステージであり、このステ
ージ中例えばALU40の出力40cを書込みポートを経てレジ
スタファイル43に書込み、しかも命令ストリームまたは
データストリーム参照に対するデータキャッシュ59また
は命令キャッシュ21ヒット/ミス決定点である。
The first stage S0 of the pipeline is an instruction fetch or
Instruction stage 18 during the IF stage
A new instruction is fetched from the instruction fetch 21 using the address 33 as a base. The second stage S2 is an evaluation stage in which two fetched instructions are evaluated to see if a double issue is possible.
The third stage S2 is a decoding stage in which the instructions are decoded by the decoder 23 and the control signals 28
And a register address. The fourth stage is a register file 43 for accessing the operation instruction stage and the instruction issue stage. The fifth stage S4 is cycle 1 of the calculation if an operation instruction is present (for example in the ALU 40), and the instruction unit 18 calculates a new PC 33 of the address generator 29; 19 calculates an effective data stream address using the adder 53. 6th stage
S5 is a cycle-2 of the calculation when there is an operation instruction (for example, in the ALU 40), and the data TB48 searches the memory reference stage. The last stage S6 is a write stage of an operation instruction having a register write, in which, for example, the output 40c of the ALU 40 is written to the register file 43 via the write port, and the data cache 59 or the instruction cache for the instruction stream or the data stream reference. 21 hit / miss decision points.

図1〜7のCPU10により実行される命令セットの種々
の型のフォーマットを図7に示す。図7のフォーマット
を用いることにより図1のCPUは9つの型の命令を含む
命令セットを実行する。これら命令セットは(1)整数
ロードおよび記憶命令、(2)整数制御命令、(3)整
数算術、(4)論理シフト命令、(5)バイト操作、
(6)浮動小数点ロードおよび記憶、(8)浮動小数点
算術、(9)その他付帯である。この命令セットは米国
特許願第547,630号明細書に詳細に記載されている。1
つの型はメモリ(即ち、ロードおよび記憶)命令70であ
り、この命令はビット<31:26>の1つの6ビット演算
符号、ビット<25:21>の2つの5ビットレジスタアド
レスフィールドRaおよびRb、ビット<15:0>の1つの16
ビット符号の変位である。この命令はレジスタ43および
メモリ(メモリ12あるいはキャッシュ59または20)間に
データを転送するとともに有効アドレスをレジスタファ
イル43のレジスタにロードするために用い、且つサブル
ーチンのジャンプに用いる。変位フィールド<15:0>は
バイトオフセットとする;これはレジスタRbの内容に符
号拡張され加えられて仮想アドレスを形成する。仮想ア
ドレスはメモリロード/記憶アドレス又は特定の命令に
依存する結果の値として用いる。また、図7に示す分岐
命令フォーマット71はビット<31:26>の1つの6ビッ
ト演算符号、ビット<25:21>の1つの5ビットアドレ
スフィールドおよびビット<20:0>の1つの21ビット符
号の変位である。この変位は倍長語オフセットとして処
理し、これは2ビット左にシフトして倍長語境界をアド
レスし、64ビットに符号拡張され、PC33の更新内容に加
えて目標仮想アドレスを形成する(オーバーフローは無
視)ことを意味する。
Various types of formats of the instruction set executed by the CPU 10 of FIGS. 1 to 7 are shown in FIG. By using the format of FIG. 7, the CPU of FIG. 1 executes an instruction set including nine types of instructions. These instruction sets are: (1) integer load and store instructions, (2) integer control instructions, (3) integer arithmetic, (4) logical shift instructions, (5) byte operations,
(6) Floating point load and storage, (8) Floating point arithmetic, (9) Others. This instruction set is described in detail in U.S. Pat. No. 5,47,630. 1
One type is a memory (ie, load and store) instruction 70, which is one 6-bit opcode in bits <31:26> and two 5-bit register address fields Ra and Rb in bits <25:21>. , One of bits <15: 0>
This is the displacement of the bit code. This instruction is used to transfer data between the register 43 and the memory (the memory 12 or the cache 59 or 20), load an effective address into the register of the register file 43, and use it for a subroutine jump. The displacement field <15: 0> is a byte offset; this is sign-extended and added to the contents of register Rb to form a virtual address. The virtual address is used as a memory load / store address or as a result value depending on the particular instruction. The branch instruction format 71 shown in FIG. 7 has one 6-bit operation code of bits <31:26>, one 5-bit address field of bits <25:21>, and one 21-bit of bits <20: 0>. This is the displacement of the sign. This displacement is treated as a doubleword offset, which is shifted 2 bits to the left to address the doubleword boundary, sign extended to 64 bits and forming the target virtual address in addition to the PC33 updates (overflow Means ignore).

作動命令72および73は図7に示すフォーマットであ
り、一方のフォマット72は3つのレジスタオペランド、
他方のフォーマットは2つのレジスタオペランドおよび
1つのリテラルに対して用いる。作動フォーマットは、
整数レジスタ作動を行い2つのソースオペランド行い1
つの行先オペランドをレジスタファイル43で許容する命
令に対して用いる。一方のソースオペランドはリテラル
定数とすることができる。ビット−12によって作動命令
が2ソースレジスタ作動に対するものであるかまたは1
つのソースレジスタおよびリテラルに対するものである
かを規定する。ビット<31:26>の6ビット演算符号に
加えて、作動フォーマットはビット<11:5>の7ビット
機能フィールドを有し、論理演算作動に対する広い範囲
の選択を行うようにする。ソースレジスタRaは何れの場
合にもビット<25:21>で特定され、且つ行先レジスタR
cはブロックビット<4:0>で選定する。ビット−12が零
の場合にはソースレジスタRbはビット<20:16>に規定
するされるが、ビット−12が1の場合には8ビット零拡
張されたリテラル定数は命令のビット<20:13>により
形成される。このリテラルは範囲0〜255で正の整数と
してインタープリータされるとともに64ビットに対し零
拡張される。
Actuating instructions 72 and 73 are in the format shown in FIG. 7, where one format 72 has three register operands,
The other format uses two register operands and one literal. The working format is
Perform integer register operation and perform two source operands 1
One destination operand is used for an instruction permitted in the register file 43. One source operand can be a literal constant. Bit -12 indicates whether the operation instruction is for a two-source register operation or 1
Specifies whether one is for one source register and a literal. In addition to the 6-bit operation code of bits <31:26>, the operation format has a 7-bit function field of bits <11: 5> to provide a wide range of choices for logical operation. The source register Ra is specified in each case by bits <25:21> and the destination register R
c is selected by block bits <4: 0>. If bit -12 is zero, source register Rb is defined in bits <20:16>, but if bit -12 is one, the 8-bit zero-extended literal constant is the bit <20:16> of the instruction. 13>. This literal is interpreted as a positive integer in the range 0-255 and zero extended to 64 bits.

また図7には浮動小数点レジスタ61の作動を行う命令
に用いてられる浮動小数点作動命令をも示す、浮動小数
点作動命令は前述したようにビット<31:26>の1つの
6ビット演算符号とビット<15:5>の1つの11−ビット
機能フィールドとを含む。また3つのペランドフィール
ドFa,FbおよびFcがあり、その各々は整数かまたは命令
により規定された浮動小数点オペランドかを特定する;
レジスタ61のみはオペランドフィールドFa,FbおよびFc
により特定されるが、これらレジスタは整数かまたは浮
動小数点値を含むことができる。リテラルはサポートさ
れない。浮動小数点の変換は図7の浮動小数点作動フォ
ーマット74のサブセットを用い且つレジスタ−レジスタ
変換作動を行う;Fbオペランドによってソースを特定
し、且つFaオペランドはレグ−31(全て零)とする必要
がある。
FIG. 7 also shows a floating-point operation instruction used for an instruction for operating the floating-point register 61. The floating-point operation instruction includes one 6-bit operation code of bits <31:26> and a bit as described above. <15: 5>. There are also three peland fields Fa, Fb and Fc, each of which specifies either an integer or an instruction defined floating point operand;
Register 61 only has operand fields Fa, Fb and Fc
, These registers may contain integers or floating point values. Literals are not supported. The floating-point conversion uses a subset of the floating-point operating format 74 of FIG. 7 and performs a register-to-register conversion operation; the source is specified by the Fb operand, and the Fa operand must be leg-31 (all zeros). .

図7の他の命令フォーマットは特権アーキテクチュア
ライブラリ(PALまたはPALコード)命令に対し、何れが
特定の拡張されたプロセッサ機能に用いられるかを示
す。これらの命令では前述したようにビット<31:26>
に6ビット演算符号が存在し、且つ26ビットPALコード
機能フィールド<25:0>によって作動を特定する。PAL
コード命令用のソースおよび行先オペランドは個別の命
令精細で特定された固定のレジスタで供給される。通常
PALコード命令はメモリに記憶されたフォーマット70−7
4の多数の命令を用いて例えば作動システムの一部とし
て特権モードで実行される一層複雑な命令を形成する。
図7の命令フォーマットにおける6ビット演算符号フィ
ールド<31:26>によって26即ち、64個の個となる命令
を符号化する。これがため、命令セットは64個に限定さ
れるようになる。しかし、命令フォーマット72,73およ
び74の“機能”フィールドによってビット<31:26>に
同一の演算符号を有する命令を変化させることができ
る。また、ジャンプ命令の“ヒント”ビットによってJS
RまたはRETのような変化を生ぜしめるようにする。
The other instruction formats in FIG. 7 indicate for privileged architecture library (PAL or PAL code) instructions which are used for a particular extended processor function. In these instructions, bits <31:26>
Has a 6-bit operation code, and specifies operation by a 26-bit PAL code function field <25: 0>. PAL
Source and destination operands for code instructions are provided in fixed registers specified in the individual instruction details. Normal
PAL code instructions are stored in memory in format 70-7
The multiple instructions of 4 are used to form more complex instructions that are executed in privileged mode, for example, as part of an operating system.
26, that is, 64 instructions are encoded by the 6-bit operation code field <31:26> in the instruction format of FIG. This limits the instruction set to 64 instructions. However, the "function" fields of the instruction formats 72, 73 and 74 allow the instructions having the same operation code in bits <31:26> to be changed. In addition, JS
Try to make a change like R or RET.

内部アドレスバス56に割当てられた仮想アドレスのフ
ォーマット76を図8によって示す。このアドレスは64ビ
ット幅とするが現在の実際的な実現では充分に小さなア
ドレスを用いる。例えば、43ビットのアドレスによって
8テラバイトのアドレス指定範囲を得ることができる。
フォーマットは使用するページサイズに依存し、例えば
大きさが13ビット〜16ビットのバイトオフセット77を含
むようにすることができる。ページが8Kバイトである場
合にはバイトウイズインページフィールド77は13ビット
であり、16Kバイトに対してはフィールド77を14ビット
とする。図示のフォーマット76は実現に依存し変化し得
る大きさのSeg1,Seg2およびSeg3とラベルされた3つの
セグメント78,79および80を有する。例えば、セグメン
トSeg1、Seg2およびSeg3は10−13ビットとすることがで
きる。各セグメントの大きさが10ビットである場合には
Seg3により規定されたセグメントの長さは1Kページであ
り、Seg2のセグメントは1Mページであり、Seg3のセグメ
ントは1Gページである。PTEのページフレーム番号(PF
N)フィールドは常時32ビットである;これがためペー
ジの大きさが大きくなるにつれて仮想および物理アドレ
スの大きさも大きくなる。
The format 76 of the virtual address assigned to the internal address bus 56 is shown in FIG. This address is 64 bits wide, but current practical implementations use addresses that are small enough. For example, a 43-bit address can provide an addressing range of 8 terabytes.
The format depends on the page size used and can include, for example, a byte offset 77 of 13 to 16 bits in size. When the page is 8 Kbytes, the byte-with-in-page field 77 has 13 bits, and for 16 Kbytes, the field 77 has 14 bits. The illustrated format 76 has three segments 78, 79 and 80 labeled Seg1, Seg2 and Seg3 of varying sizes depending on the implementation. For example, segments Seg1, Seg2 and Seg3 can be 10-13 bits. If the size of each segment is 10 bits
The segment length specified by Seg3 is 1K pages, the segment of Seg2 is 1M pages, and the segment of Seg3 is 1G pages. PTE page frame number (PF
N) Fields are always 32 bits; this increases the size of virtual and physical addresses as the size of the page increases.

物理アドレスは多くとも32ビットであるが、プロセッ
サは高次のビットのある番号を実行しないことによって
小さなアドレスを実行することができる。2つの最上位
実行物理アドレスビットによってキャッシュ戦略または
実行依存型のアドレススペースを選択することができ
る。種々の異なる実行によってシステムに対する適宜の
ものとしてこれらビットの異なる使用および制限を行う
ことができる。例えば、30ビット<29:0>物理アドレス
スペースを有するワークステーションではビット<29>
はメモリおよびI/O間を選択し、且つビット<28>はI/O
スペースにおけるキャッシュ動作をイネーブルまたはデ
ィスイネーブルするとともにメモリスペースにおいて零
とすることができる。
Although the physical address is at most 32 bits, the processor can implement small addresses by not performing certain numbers of higher order bits. The two most significant execution physical address bits can select a cache strategy or an execution dependent address space. Different implementations may make different uses and restrictions of these bits as appropriate for the system. For example, for a workstation having a 30-bit <29: 0> physical address space, bits <29>
Selects between memory and I / O, and bit <28> is I / O
Cache operations in the space can be enabled or disabled and zeroed in the memory space.

代表的には、マルチタスクシステムにおいて数個のプ
ロセスは物理メモリ12(またはキャッシュ)に同時に存
在するため、メモリ保護および(アドレススペース番号
を用いる)多重アドレススペースはCPUにより用いられ
て1つのプロセスが他のプロセスまたは作動中のシステ
ムの何れかとインターフェースしないようする。ソフト
ウエアの信頼性をさらに改善するために、4つのハイア
ラーキアクセスモード(特権モード)によってメモリの
アクセス制御を行う。これらは最上位から最下位まで特
権付けられている。:即ち、カーネル、実行、スーパー
バイザおよびユーザは作動システムモードおよび適用プ
ログラムに関連する。保護は個別のページレベルで特定
され、ここでページは4つのアクセスモードの各々に対
してアクセス不可能、読取り専用、または読取り/書込
みとすることができる。アクセス可能なページはデータ
または命令アクセスのみを有するように制限することが
できる。
Typically, in a multitasking system, since several processes reside in physical memory 12 (or cache) simultaneously, memory protection and multiple address spaces (using address space numbers) are used by the CPU to Avoid interfacing with any other processes or running systems. In order to further improve the reliability of software, memory access is controlled by four hierarchical access modes (privileged modes). These are privileged from top to bottom. I.e., kernel, run, supervisor and user are related to operating system modes and application programs. Protection is specified at the individual page level, where pages can be inaccessible, read-only, or read / write for each of the four access modes. Accessible pages can be restricted to have only data or instruction access.

トランスレーションバッファ36または48に記憶された
あるいは作動システムによりメモリ12ないにセットされ
たページテーブルに記憶されたページテーブルエントリ
即ち、PTE81を図9に示す。PTE81は幅がクォッドワード
(64ビット)でビット<63:32>の32ビットページフレ
ーム番号即ち、PFN82、および表Aに示すようにビット
<15:0>を有するフィールド83にあるソフトウエアおよ
びハードウエア制御情報を具え、保護特性等を実行す
る。
The page table entry or PTE 81 stored in the translation table 36 or 48 or in the page table set by the operating system in the memory 12 is shown in FIG. PTE 81 is a quadword (64 bits) wide and has a 32-bit page frame number of bits <63:32>, i.e., PFN82 and software and hardware in field 83 with bits <15: 0> as shown in Table A. With control information, execute protection characteristics and the like.

トランスレーションバッファ36および48は、各々が仮
想アドレスのある高次のビットより成るタグに関連し、
このPFNが作動システムによりこの仮想アドレスに割当
てられた多数のページテーブルエントリ81を記憶する。
例えば、タグは、図8の仮想アドレス76のSeg1,Seg2お
よびSeg3値に対するフィールド78,79および80によって
構成することができる。これに加えるにTBがフラッシュ
される際エントリが無効であったか否かを示す有効ビッ
トを具える。従来はコンテキストスイッチが形成される
際TBをフラッシュして全てのエントリを無効としてい
る;しかし、本発明の特徴によっていまだ有効であるエ
ントリを継続して使用し、従って性能が改善されるよう
になる。この目的のため、トランスレーションバッファ
36および48は以下に説明するようにプロセス制御ブロッ
クからロードされた幅が16ビットのアドレススペース番
号フィールドを追加する。図10に示すようにバス56の仮
想アドレス76(図8参照)を用いてトランスレーション
バッファのPTEに対するタグ整合を探索し、これが見い
出せない場合にはSeg1フィールド78を用いてページテー
ブルベースレジスタと称される内部レジスタ86に記憶さ
れたベースアドレスで見い出された第1ページテーブル
85にインデックスする。テーブル85のSeg1インデックス
で見い出されたエントリ87は第2ページテーブル88に対
するベースアドレスであり、これによりSeg2フィールド
79をエントリ89へのインデックスに用いる。エントリ89
は第3ページテーブル90のベースにポイントし、Seg3フ
ィールド80をPTE91へのインデックスに用いる。PTE91か
らの物理ページフレーム番号は仮想アドレスからのバイ
トオフセット77とアダー92で組合せてバス54に物理アド
レスを発生する。上述したようにPTEによりマップされ
たページのサイズおよびバイトオフセット77のサイズを
粒度ヒントに依存して変化させるようにする。
Translation buffers 36 and 48 are associated with tags, each consisting of a higher order bit of the virtual address,
This PFN stores a number of page table entries 81 assigned by the operating system to this virtual address.
For example, a tag may be configured by fields 78, 79 and 80 for the Seg1, Seg2 and Seg3 values of virtual address 76 in FIG. In addition, it has a valid bit that indicates whether the entry was invalid when the TB was flushed. Conventionally, the TB is flushed to invalidate all entries when a context switch is formed; however, features of the present invention continue to use entries that are still valid, thus improving performance. . For this purpose, a translation buffer
36 and 48 add a 16-bit wide address space number field loaded from the process control block as described below. As shown in FIG. 10, a tag match for the PTE of the translation buffer is searched for using the virtual address 76 of the bus 56 (see FIG. 8), and if this cannot be found, the page table base register is called using the Seg1 field 78. Page table found at the base address stored in internal register 86 to be read
Index to 85. The entry 87 found in the Seg1 index of the table 85 is the base address for the second page table 88, and thus the Seg2 field
Use 79 as an index into entry 89. Entry 89
Points to the base of the third page table 90 and uses the Seg3 field 80 as an index into the PTE 91. The physical page frame number from the PTE 91 is combined with the byte offset 77 from the virtual address and the adder 92 to generate a physical address on the bus 54. As described above, the size of the page mapped by the PTE and the size of the byte offset 77 are changed depending on the granularity hint.

仮想アドレス76のタグフィールドとトランスレーショ
ンバッファ36または48のタグフィールドとを整合するほ
かに、トランスレーションバッファに記憶されたアドレ
ススペース番号を内部プロセッサレジスタの1つである
ASNレジスタに記憶されたCPU10の現在の状態のアドレス
スペース番号と比較する。アドレススペース整合フィー
ルド(ビット<4>,A)がクリア(零)されている場合
には現在のASNおよびフィールド94は使用すべきPTEに対
し整合させる必要があるが、アドレススペース整合フィ
ールドがセット(論理1)されている場合には整合は必
要なく、即ち、アドレススペース番号は無視されるよう
になる。しかし、本発明の特別の特徴は各PTEに記憶さ
れた追加の整合ディスエーブルビット96であり、これに
よりある条件の下で(即ち、仮想マシンモニタプロセス
が実行されている場合)アドレススペース整合特徴をデ
ィスエーブルする。
In addition to matching the tag field of virtual address 76 with the tag field of translation buffer 36 or 48, the address space number stored in the translation buffer is one of the internal processor registers.
This is compared with the address space number of the current state of the CPU 10 stored in the ASN register. If the address space match field (bit <4>, A) is cleared (zero), the current ASN and field 94 need to match for the PTE to be used, but the address space match field is set ( If it is a logical 1) no match is needed, ie the address space number will be ignored. However, a particular feature of the present invention is the additional matching disable bit 96 stored in each PTE, which allows the address space matching feature to be under certain conditions (ie, when the virtual machine monitor process is running). Disable.

整合ディスエーブルビットはトランスレーションバッ
ファの各エントリに保持する必要はない。アドレススペ
ース整合をディスエーブルすべきかどうかは仮想アドレ
スの実行環境よりもCPUの実行環境の関数である。仮想
マシンモニタが(後述するように)実行されている場合
にはアドレススペース整合はディスエーブルされる;仮
想マシン即ち、VMのあるプロセスが実行されると、アド
レススペース整合はイネーブルされるようになる。本発
明の他の例では、整合ディスエーブルビットはトランス
レーションバッファでグローバルに記憶される。本発明
のさらに他の例では、整合ディスエーブルはCPU自体に
保持される。何れの場合にも、その値はVMMからVMへ、
またはVMからVMMへの遷移で変化し、その現在の値はト
ランスレーションバッファの遷移比較論理に用いる必要
がある。
A match disable bit need not be maintained in each entry of the translation buffer. Whether address space matching should be disabled is a function of the CPU's execution environment rather than the virtual address's execution environment. Address space matching is disabled when the virtual machine monitor is running (as described below); when a process with a virtual machine, ie, a VM, is executed, address space matching is enabled. . In another example of the invention, the match disable bit is stored globally in a translation buffer. In yet another example of the present invention, the match disable is maintained on the CPU itself. In each case, the value is from VMM to VM,
Or it changes at the transition from VM to VMM, and its current value must be used for the transition comparison logic of the translation buffer.

CPU10は、まず最初バス56に仮想アドレス76を形成
し、図11に示すように関連する43ビットアドレス幅によ
り規定された全仮想範囲97内にアドレスを表わすかまた
は作動システムにより用いられるアドレス幅の部分を表
わすことによってメモリ参照を発生する。従ってメモリ
のページテーブル85,88,90を用いるかまたはトランスレ
ーションバッファ36または48を用いることにより仮想ア
ドレスをアドレスマップ98により表わされる物理アドレ
スにトランスレートする;即ち、物理メモリは主メモリ
12のサイズによって強制される。トランスレーションは
各ページ(例えば8Kバイトブロック)に対して行われる
ため、仮想メモリマップ97のページ92に対する仮想ペー
ジアドレスは物理メモリマップ98のページ(ページフレ
ームと称する)に対する物理アドレス99′にトランスレ
ートされる。ページテーブルはメモリ12またはキャッシ
ュ20に保持されて仮想アドレスおよび物理アドレス間で
トランスレーションを行い、且つトランスレーションバ
ッファはCPUに含めて最新に用いられたトランスレーシ
ョンを保持し、従って殆どの場合にデータ参照を行う前
にトランスレーションを得るためにはメモリ12のページ
テーブルへの参照は必要でない;即ち、メモリ12のペー
ジテーブルへの参照を行うに必要な時間はトランスレー
ションバッファからトランスレーションを得るに必要な
時間よりも充分長くなる。現在実行されているタスクに
より使用されるページのみ(および作動システム自体)
は所定時間に物理メモリ12にあるようになる:即ち、ア
ドレス99′へのトランスレーションは物理メモリ12に実
際に存在するこれらページのみに対しページテーブル8
5,88,90にある。CPU10により参照されるページが物理メ
モリ12に見い出せない場合にはページ欠陥が実行されて
物理メモリ12からのページがディスクメモリ13に保持さ
れる所望のページと交換される交換作動を開始し、この
交換は作動システムの制御の下で行われる。作動システ
ムカーネルにより使用される物理メモリ12またはページ
テーブル85,88,90自体のあるいはページは固定位置にあ
り、ディスク13に交換されないかまたは他のページトラ
ンスレーションに移動するようになる;しかし、タスク
の実行により使用される多くのページは更新されたペー
ジテーブルを単に保持することにより物理メモリ12内を
自由に動き得るようになる。
The CPU 10 first forms a virtual address 76 on the bus 56 and either represents the address within the entire virtual range 97 defined by the associated 43-bit address width as shown in FIG. 11, or the address width used by the operating system. Generate memory references by representing parts. Thus, the virtual address is translated to the physical address represented by the address map 98 by using the page tables 85, 88, 90 of the memory or by using the translation buffers 36 or 48;
Mandated by 12 sizes. Since the translation is performed for each page (for example, an 8K byte block), the virtual page address for the page 92 of the virtual memory map 97 is translated to the physical address 99 'for the page (referred to as a page frame) of the physical memory map 98. Is done. The page table is maintained in the memory 12 or cache 20 to translate between virtual and physical addresses, and the translation buffer contains the most recently used translation, including the CPU, and in most cases data A reference to the page table in memory 12 is not necessary to obtain the translation before making the reference; that is, the time required to make a reference to the page table in memory 12 is sufficient to obtain the translation from the translation buffer. It will be much longer than required. Only pages used by the currently executing task (and the actuation system itself)
Will be in the physical memory 12 at a given time: the translation to the address 99 'will be in the page table 8 for only those pages that actually exist in the physical memory 12.
5,88,90. If the page referenced by the CPU 10 is not found in the physical memory 12, a page fault is performed to initiate a swap operation where the page from the physical memory 12 is replaced with the desired page held in the disk memory 13, The exchange takes place under the control of the operating system. The physical memory 12 used by the operating system kernel or the page tables 85, 88, 90 themselves or the pages are in fixed locations and will not be swapped to disk 13 or will be moved to other page translations; Of the physical memory 12 can be moved freely by simply maintaining the updated page table.

プロセス(またはタスク)はCPU10による実行に計画
された基本エントリである。プロセスは実行の単一スレ
ッドを表わし、アドレススペースと、ハードウエアおよ
びソフトウエアコンテキストの双方とで構成される。ハ
ードウエアコンテキストは整数レジスタ(レジスタファ
イルをも構成する)43、浮動小数点レジスタ61、内部プ
ロセッサレジスタに含まれるプロセッサの状態、プログ
ラムカウンタ33、4つのスタックポインタ、ページテー
ブルベースレジスタ86、アドレススペース番号95その他
CPUの設計に依存する値によって規定される。プロセス
のソフトウエア文脈は作動システムソフトウエアによっ
て規定され且つシステムに依存する。プロセスは同一の
アドレススペースを他のプロセスと共用するかまたはそ
れ自体のアドレススペースを有する;しかし、これはシ
ステムソフトウエアに対する個別のアドレススペースで
はなく、従って作動システムは各プロセスのアドレスス
ペースにマップする必要がある。プロセスを実行すうる
ためにはそのハードウエア文脈を整数レジスタ(レジス
タファイルをも構成する)43、浮動小数点レジスタ61お
よび内部プロセッサレジスタにロードする必要がある。
プロセスが実行されると、そのハードウエア文脈は、種
々のレジスタがロードされ、書込まれていくにつれて、
連続的に更新される。プロセスが実行されないと、その
ハードウエア文脈はメモリ12に記憶されるようになる。
メモリの現在のプロセスのハードウエア文脈を節約し、
次いで新たなプロセスのハードウエア文脈をロードする
ことを文脈交換と称する。文脈交換は実行に対し作動シ
ステムにより計画された後に1つのプロセスとして発生
する。プロセスのハードウエア文脈は特権部分および特
権のない文脈によって規定する。この特権部分はプロセ
スが実行されていない場合には図12に示すように128バ
イトブロック100のメモリに記憶するとともに文脈を特
権命令によって交換する。各プロセスに対し1ブロック
100が存在する。
A process (or task) is a basic entry planned for execution by the CPU 10. A process represents a single thread of execution and consists of an address space and both hardware and software contexts. The hardware context includes an integer register (which also forms a register file) 43, a floating-point register 61, a processor state included in an internal processor register, a program counter 33, four stack pointers, a page table base register 86, and an address space number 95. Other
It is specified by a value that depends on the CPU design. The software context of the process is defined by the operating system software and is system dependent. A process shares the same address space with other processes or has its own address space; however, this is not a separate address space for system software, so the operating system maps to each process's address space. There is a need. To be able to execute a process, its hardware context must be loaded into the integer registers (which also make up the register file) 43, floating point registers 61 and internal processor registers.
As the process runs, its hardware context is such that as various registers are loaded and written,
Updated continuously. If the process is not executed, its hardware context will be stored in memory 12.
Save the hardware context of the current process in memory,
Loading the hardware context of the new process is then called context exchange. Context exchange occurs as a process after being scheduled by the operating system for execution. The hardware context of a process is defined by privileged and unprivileged contexts. When the process is not being executed, this privileged portion is stored in the memory of the 128-byte block 100 as shown in FIG. 12, and the context is exchanged by the privileged instruction. One block for each process
There are 100.

図12に示すように、文脈ブロック100はフィールド101
に4つのスタックポインタを含み、これらポインタはカ
ーネル、実行、スーパーバイザおよびユーザに対するス
タックポインタである。ページテーブルベースレジスタ
86はフィールド102に存在する。(レジスタ95にロード
すべき)このプロセスに対するアドレススペース番号は
フィールド103に存在する。他のフィールド104はこれら
の値に対しては用いない。メモリのこのブロック100の
位置は文脈ブロックベースレジスタ105によって現在の
プロセスに対し特定する。スワップコンテキスト命令は
現在のプロセスの特権文脈をこのレジスタ105により特
定された文脈ブロックに供給して新たな値をレジスタ10
5にロードし、次いで新たなブロック100からの新たなプ
ロセスの特権文脈を適宜のハードウエアレジスタ(レジ
スタファイルをも構成する)43等にロードする。
As shown in FIG. 12, the context block 100 includes a field 101
Contains four stack pointers, which are stack pointers for the kernel, execution, supervisor and user. Page table base register
86 is in the field 102. The address space number for this process (to load into register 95) is in field 103. The other fields 104 are not used for these values. The location of this block 100 of memory is specified by the context block base register 105 for the current process. The swap context instruction supplies the privilege context of the current process to the context block identified by this register 105 and adds a new value to register 10
5 and then load the privilege context of the new process from the new block 100 into the appropriate hardware register (which also comprises the register file) 43, etc.

上述したアーキテクチュアによってプロセッサにより
アドレススペース番号(プロセスタグ)を実行しコンテ
キストスイッチが生じる際プロセス規定アドレスに対す
るトランスレーションバッファにおけるキャッシュされ
たアドレストランスレーションの無効に対する必要性を
減少する。現在のプロセスに対するアドレススペース番
号はフィールド103からの特権命令によって内部プロセ
ッサレジスタ95にロードする。
The architecture described above reduces the need for invalidating cached address translations in the translation buffer for process-defined addresses when the processor executes address space numbers (process tags) and context switches occur. The address space number for the current process is loaded into internal processor register 95 by a privileged instruction from field 103.

図9および表Aのページテーブルエントリ81では、
“アドレススペース整合”と称されるフィールド(ビッ
ト<4>)が存在する。この特徴によって作動システム
により全てのプロセス間で共用されるシステムの仮想ア
ドレススペース97の位置を示すようにする。かかる仮想
アドレスは各プロセスのアドレススペースにおいて同一
の物理アドレスに関連するよういなる。
In FIG. 9 and page table entry 81 in Table A,
There is a field (bit <4>) called "Address Space Match". This feature causes the location of the system's virtual address space 97 to be shared by all processes by the operating system. Such virtual addresses will be associated with the same physical address in the address space of each process.

図1−5のCPU10は“仮想マシンシステム”を採用す
ることができ、このマシンシステムはハードウエア、フ
ァームウエア、およびソフトウエア機構の組合せを用い
て各々が同一物理的コンピュータで実行される独立して
シミュレートされる多重コンピュータまたは仮想コンピ
ュータの錯覚を生じるようになる。仮想マシンシステム
によって一組の仮想マシン(VMs)を同様に発生し、時
間分割システムによって一組の独立ユーザプロセスを発
生する。図1−5のアーキテクチュアを経て仮想化する
には性能および機能の観点からハードウエア手段を経て
仮想マシンにアドレス−スペース−整合特性を与える必
要がある。
1-5 may employ a "virtual machine system", which uses a combination of hardware, firmware, and software mechanisms to operate independently, each running on the same physical computer. Simulated multi-computer or virtual computer illusions. A set of virtual machines (VMs) is similarly generated by the virtual machine system, and a set of independent user processes is generated by the time-sharing system. Virtualization via the architecture of FIGS. 1-5 requires that the virtual machine be provided with address-space-matching characteristics via hardware means from a performance and functional point of view.

仮想マシンは仮想マシンモニタ(VMM)と称されるCPU
で実行する層によって発生される。VMMはハードウエア
の制御下にあり、メモリ管理(アドレストランスレーシ
ョンおよび保護機構)およびページテーブルを含む。各
仮想マシンは範囲97の個別の仮想アドレススペースで実
行されるとともにVMMにより割当てられた個別の組のア
ドレススペース番号を有する。VMMはそれ自体範囲97の
仮想アドレススペースの個別の組で実行される。本発明
の目的はシステムの性能を小型化し、仮想マシンをカー
ネルモードで実行してこれらが特権命令(さもないと著
しい性能のペナルテイでこれら作動に対するトラップを
用いる必要がある)を実行し得るようにする。;即ち、
この目的のためにVMMはVMsを抑制する必要がある。本発
明の実現に必要な問題は互いに離間された数個のVMsお
よびVMMのアドレススペースを保持すことにあり、一方
これと同時にTB〜VMsに整合機能を設けることによりシ
ステムの性能を最大化する。問題解決へのさらに他の制
限はVMsおよびVMMが異なる目的に同一の仮想アドレスを
用いるようにしたいことである。これがため、VMsに割
当てられたアドレスからVMMに個別のアドレス領域を割
当てることは解決にはならない。
A virtual machine is a CPU called a virtual machine monitor (VMM)
Generated by layers running on. The VMM is under hardware control and includes memory management (address translation and protection mechanisms) and page tables. Each virtual machine runs in a separate virtual address space in the range 97 and has a separate set of address space numbers assigned by the VMM. VMM itself runs on a separate set of virtual address spaces in the 97 range. It is an object of the present invention to reduce the performance of the system so that virtual machines can be run in kernel mode so that they can execute privileged instructions (otherwise traps for these operations must be used with a significant performance penalty). I do. That is,
For this purpose, VMM needs to suppress VMs. The problem required to implement the present invention is to keep the address space of several VMs and VMMs separated from each other, while at the same time maximizing system performance by providing matching functions in TB to VMs . Yet another limitation to solving the problem is that VMs and VMMs want to use the same virtual address for different purposes. Therefore, allocating an individual address area to the VMM from the address allocated to the VMs does not solve the problem.

本発明の一例を示す。ハードウエアウエアによってソ
オフトウエアで用いされる15のアドレススペースASN−
0〜ASN−14N−14はVMMにより用いるものとする。本例
システムには各々が5つのユーザプロセスを実行する2
つの仮想マシンAおよびBが存在する。この仮想マシン
へのアドレススペースの可能な割当てはアドレススペー
スASN−1〜ASN−6、ASN−7、ASN−8、ASN−10およ
びASN−11をVMBに向けるようにする。この例を図13に示
す。
1 shows an example of the present invention. 15 address spaces ASN used in software by hardware
0 to ASN-14N-14 shall be used by the VMM. The system in this example runs 5 user processes each 2
There are two virtual machines A and B. The possible allocation of address space to this virtual machine causes the address spaces ASN-1 to ASN-6, ASN-7, ASN-8, ASN-10 and ASN-11 to be directed to the VMB. This example is shown in FIG.

システムの安全性および完全性を確保するために、2
つの仮想マシンを完全に独立させる必要がある。これは
これらメモリがそれぞれ他のメモリを参照し得ないこと
を意味する。同様にVMMのメモリは仮想マシンから独立
させる必要がある。しかし、仮想マシン内ではアドレス
スペース整合特性は正しく働き、各VMs作動システムの
制御の下で個別のプロセスによりメモリを共用する。
To ensure the safety and integrity of the system,
Two virtual machines need to be completely independent. This means that each of these memories cannot reference another memory. Similarly, the VMM memory needs to be independent of the virtual machine. However, within a virtual machine, the address space matching feature works correctly and shares memory with individual processes under the control of each VMs operating system.

正規のトランスレーションバッファの設計によって各
アドレススペースをアドレススペース番号(以下ASNと
称する)に割当てる。CPUの状態情報の一部分は現在実
行しているエントリまたはプロセスレジスタ95に割当て
られたASNである。TBエントリはアドレススペースのASN
とともにフィールド94でタグされ、これらエントリはこ
のアドレススペースに属する。さらにTB(表A、ASNビ
ット<4>)には1ビットまたはフィールドが存在し、
これはエントリが任意のアドレススペースと整合し、実
際上ASN94のタグを無効にすることを示する。
Each address space is assigned to an address space number (hereinafter, referred to as ASN) by a proper translation buffer design. Part of the CPU status information is the currently executing entry or ASN assigned to the process register 95. TB entry is ASN of address space
Along with field 94, and these entries belong to this address space. In addition, TB (Table A, ASN bit <4>) has one bit or field,
This indicates that the entry matches any address space, effectively overriding the ASN94 tag.

この種のTBは著しいパフォーマンスのペナルティで仮
想マシンシステムに使用することができる。メモリの分
離要求を行うために、TBは、(1)全ての整合を示す整
合フィールド(ビット<4>)を有するTBに任意のエン
トリが存在する場合、および(2)次のイベントの任意
のものが発生する場合に完全にフラッシュする必要があ
る。これらイベントは(a)リアルマシンで現在実行さ
れているエントリは一方のVMから他方のVMに変化する、
(b)リアルマシンで現在実行されているエントリはあ
るVMからVMMに変化する、(c)リアルマシンで現在実
行されているエントリはあるVMMからVMに変化する、で
ある。TBフラッシュを最小とするために、従って全シス
テムの性能を改善するために、VMMにある制限を課すと
ともにTBの構成を本発明に従って変化させるようにす
る。VMMに課す制限はディスエーブル整合特性を用いる
必要があることである。これにより仮想マシンによる使
用のアドレススペース整合特性を確保し、VMMアドレス
が整合フィールドセットによるもTBによってマップしな
いことである。
This kind of TB can be used for virtual machine systems with a significant performance penalty. To make a memory isolation request, the TB must: (1) have any entry in the TB with a match field (bit <4>) indicating all matches; and (2) have any match in the next event. Need to flush completely when things happen. These events are: (a) the entry currently running on the real machine changes from one VM to the other,
(B) The entry currently executed in the real machine changes from a certain VM to a VMM, and (c) the entry currently executed in the real machine changes from a certain VMM to a VM. To minimize TB flash, and thus improve overall system performance, impose certain restrictions on the VMM and vary the TB configuration in accordance with the present invention. The limitation imposed on VMM is that it is necessary to use a disable matching property. This ensures address space matching characteristics for use by virtual machines, and VMM addresses are not mapped by TB, even with matching field sets.

TB自体は図10のフィールド96であるいわゆる“ディス
エーブル整合”のCPU状態の他の部分を加えることによ
って変更することができる。VMMによってプレアドレス
スペースに基づきディスエーブル整合フィールド96の値
を決めるとともに現在の値をTBに供給する。このフィー
ルド96はセットまたはクリアし得るフラグである。ディ
スエーブル整合フィールド96がクリアされると、アドレ
スが正しい場合にTBは参照と整合するとともに(1)TB
エントリのASNはCPUの現在のASNと整合し、(2)TBエ
ントリの整合フィールドはセットされる。
The TB itself can be changed by adding another part of the so-called "disable matching" CPU state, field 96 of FIG. The VMM determines the value of the disable matching field 96 based on the pre-address space and supplies the current value to the TB. This field 96 is a flag that can be set or cleared. When the disable match field 96 is cleared, the TB matches the reference if the address is correct, and (1) TB
The ASN of the entry matches the current ASN of the CPU, and (2) the matching field of the TB entry is set.

図14に示すように、本発明に従って実行される論理は
次の関係により示すことができる。
As shown in FIG. 14, the logic performed in accordance with the present invention can be represented by the following relationship:

IF(ADDR.TAG=TB.TAG)&((CPU.ASN=TB.ASN)| (TB.ASM&NOT TB.DIS) THEN MATCH ここにADD.TAGは仮想アドレス76のタグフィールド78,7
9,80であり、TB.TAGはトランスレーションバッファのタ
グ93であり、CPU.ASNは制御ブロックのフィールド103か
らプロセッサレジスタ95に記憶された値であり、TB.ASN
はトランスレーションバッファのフィールド94に記憶さ
れたアドレススペース番号であり、TB.ASMはトランスレ
ーションバッファのフィールド96のディスエーブルビッ
トである。これらの値は図4のA−ボックスの論理回路
106に供給してTBで選択されたPTEを使用する必要がある
か否かを示す整合信号を発生する。
IF (ADDR.TAG = TB.TAG) & ((CPU.ASN = TB.ASN) | (TB.ASM & NOT TB.DIS) THEN MATCH where ADD.TAG is the tag field 78,7 of the virtual address 76
9,80, TB.TAG is the translation buffer tag 93, and CPU.ASN is the value stored in the processor register 95 from the control block field 103, TB.ASN
Is the address space number stored in the translation buffer field 94, and TB.ASM is the disable bit of the translation buffer field 96. These values are the logic circuit of the A-box in FIG.
A matching signal is provided to 106 to indicate whether the PTE selected by the TB needs to be used.

回路106で実行された前の章で与えられた式の形状の
論理は以下に示す真理値表で表わすことができる。(各
々の場合アドレスタグが整合するものとする。) ディスエーブル整合フィールド96がセットされると、
TBは、アドレスが正しく、TBエントリのASN94がCPUの現
在のASN95と整合する際に、参照と整合する。実際上デ
ィスエーブル整合状態ビット96はTBの整合フィールドを
オーバーライドする。
The logic of the form of the expression given in the previous section, implemented in circuit 106, can be represented by the following truth table. (In each case, the address tags match.) When disable match field 96 is set,
The TB matches the reference when the address is correct and the ASN94 of the TB entry matches the current ASN95 of the CPU. In effect, the disable match status bit 96 overrides the TB match field.

変更設計を使用するためには、VMMによってディスエ
ーブル整合ビット96をVMM自体(上述した例ではASN−0
およびASN−9)に向けられた他のASNの全てに対しセッ
トするとともにVMMによってディスエーブル整合ビット9
6を他の全てのASNに対しクリアする。CPUが同一の文脈
でVMMまたは同一のVM/プロセスついのいずれかを実行す
るかぎりにおいて、ディスエーブル整合ビット96の1つ
の主な特徴はその値が一定となることである。従ってビ
ットの値はメモリ参照中計算する必要はない。その代わ
り特定のTB設計に依存し、TBエントリが重点されている
際またはCPUが文脈を変化する際その値は計算し且つロ
ードすることができる。本発明による変更設計の結果
は、TBはマシンの現在実行されてるエントリが一方のVM
から他方のVMに変化する際にのみフラッシュする必要が
ある。
In order to use the modified design, the disable match bit 96 is added by the VMM to the VMM itself (ASN-0 in the example described above).
And set to all of the other ASNs directed to ASN-9 and disabled match bit 9 by the VMM.
Clear 6 for all other ASNs. As long as the CPU executes either the VMM or the same VM / process in the same context, one key feature of the disable match bit 96 is that its value remains constant. Therefore, the value of the bit need not be calculated during the memory reference. Instead, depending on the particular TB design, its value can be calculated and loaded when the TB entry is stressed or when the CPU changes context. The result of the change design according to the present invention is that the TB is
It only needs to be flushed when changing from one VM to the other.

本発明の他の例では仮想マシン番号VMNに対する多重
ビットフィールドを上述したように単一ビットディスエ
ーブルインジケータの代わりに図15に示すように各トラ
ンスレーションバッファエントリに加えるようにする。
同様に多重ビット仮想マシン番号VMNを内部プロセッサ
レジスタのCPUの状態に加えるとともにASN94のフィール
ドにも加えるようにする。次いで、トランスレーション
バッファはタグの仮想アドレスに整合する論理部を具え
るとともに前述したようにASNとも整合し、仮想マシン
番号で整合する論理部をも具える。実行された論理部を
次に示すように表わす。
In another example of the present invention, a multi-bit field for the virtual machine number VMN is added to each translation buffer entry as shown in FIG. 15 instead of the single-bit disable indicator as described above.
Similarly, the multi-bit virtual machine number VMN is added to the CPU state of the internal processor register and also to the ASN94 field. The translation buffer then comprises a logic portion that matches the virtual address of the tag and also has a logic portion that matches the ASN and matches by the virtual machine number as described above. The executed logic part is represented as follows.

IF(ADDR.TAG=TB.TAG)&(CPU.VMN=TB.VMN) &((CPU.ASN=TB.ASN)|(TB.ASM) THEN MATCH ここにCPU.VMNはマシン状態として記憶された仮想マシ
ン番号であり、TB.VMNはトランスレーションバッファエ
ントリのVMNフィールドである。
IF (ADDR.TAG = TB.TAG) & (CPU.VMN = TB.VMN) & ((CPU.ASN = TB.ASN) | (TB.ASM) THEN MATCH CPU.VMN is stored here as machine state Is the virtual machine number, and TB.VMN is the VMN field of the translation buffer entry.

この例では、各VMは1つ(以上)のVMNに割当てら
れ、各々はVMNを個別に用いる作動を保持する。しか
し、前述した例に対し、VM間が任意にスイッチングされ
る際トランスレーションバッファはクリアする必要はな
い。追加の利点は仮想マシンモニタにアドレススペース
整合を用いてトランスレーションバッファエントリをそ
のプロセス中に共用することができる。この例の不利な
点はトランスレーションバッファエントリに一層多くの
ビットを必要とすることである。
In this example, each VM is assigned to one (or more) VMNs, each holding the act of using the VMN individually. However, the translation buffer does not need to be cleared when the switching between the VMs is arbitrarily performed in the example described above. An additional advantage is that translation buffer entries can be shared during the process using address space matching for the virtual machine monitor. The disadvantage of this example is that it requires more bits for the translation buffer entry.

本発明は上述した例にのみ限定されるものではなく、
用紙を変更しない範囲内で種々の変形または変更が可能
である。
The invention is not limited only to the examples described above,
Various modifications or changes are possible without changing the sheet.

表 A ページテーブルエントリ ページテーブルエントリのフィールドは次のように解
釈される。
Table A Page Table Entry The page table entry fields are interpreted as follows.

ビット 決定 <0> 有効(V)−PENの有効性を示す <1> 読取り故障(FOR)−セット時FOR以外試行時に
発生ページに位置読取り <2> 書込い故障(FOW)−セット時FOW以外試行時に
発生ページに位置書込み <3> 実行故障(FOE)−このPTEは全てのアドレスス
ペース番号と整合。VA,ASNh a全てのプロセスで考慮 <4> アドレススペース整合(ASM)−セット時このP
TEは全てのアドレススペース番号と整合。VA,ASMは全て
のプロセスで考慮 <6:5> 細分性ヒント(GH)−ソフトウエアはこれら
ビットを非零値にセットしてヒントをトランスレーショ
ンバッファに供給し、ページのブロックが単一の大きな
ページとして処理される。
Bit Decision <0> Valid (V)-Indicates the validity of PEN <1> Read failure (FOR)-Position read on page generated at trial other than FOR when set <2> Write failure (FOW)-FOW when set <3> Execution failure (FOE)-This PTE matches all address space numbers. VA, ASNha considered in all processes <4> Address space matching (ASM)
TE matches all address space numbers. VA and ASM are considered in all processes. <6: 5> Granularity hint (GH)-software sets these bits to non-zero values and provides hints to the translation buffer so that blocks of pages are Treated as a large page.

<7> 将来の使用に保存 <8> カーネル読取り可能(KRE)−このビットはカ
ーネルモードから読取る。このビットが0の場合および
LOADまたは命令フェッチがカーネルモードで試行される
場合にはアクセスバイオレーションが発生する。このビ
ットはV=0でも有効である。
<7> Save for future use. <8> Kernel readable (KRE)-This bit is read from kernel mode. If this bit is 0 and
An access violation occurs if LOAD or instruction fetch is attempted in kernel mode. This bit is valid even when V = 0.

<9> 実行読取り可能(ERE)−このビットは実行モ
ードからの読取り可能。このビームが0でLOADまたは命
令フェッチが実行モード時に試行されると、アドレスバ
イオレーションが発生する。このビットはV=0時でも
有効である。
<9> Read executable (ERE)-This bit is readable from Run mode. If this beam is 0 and LOAD or instruction fetch is attempted in execute mode, address violation will occur. This bit is valid even when V = 0.

<10> スパーバイザ読取り可能(SRE)−このビット
はスーパーバイザモードから読取る。このビームが0で
LOADまたは命令フェッチがスパーバイザモード時に試行
されると、アドレスバイオレーションが発生する。この
ビットはV=0時でも有効である。
<10> Supervisor Readable (SRE)-This bit is read from supervisor mode. This beam is 0
If a LOAD or instruction fetch is attempted in supervisor mode, an address violation will occur. This bit is valid even when V = 0.

<11> ユーザ読取り可能(URE)−このビットはユー
ザモードから読取る。このビームが0でLOADまたは命令
フェッチがユーザモード時に試行されると、アドレスバ
イオレーションが発生する。このビットはV=0時でも
有効である。
<11> User Readable (URE)-This bit is read from user mode. If this beam is 0 and a LOAD or instruction fetch is attempted in user mode, an address violation will occur. This bit is valid even when V = 0.

<12> カーネル書込み可能(KWE)−このビットはカ
ーネルモードから書込む。このビームが0でSTOREがカ
ーネルモード時に試行されると、アドレスバイオレーシ
ョンが発生する。このビットはV=0時でも有効であ
る。
<12> Kernel writable (KWE)-This bit is written from kernel mode. When this beam is 0 and STORE is attempted in kernel mode, address violation occurs. This bit is valid even when V = 0.

<13> 実行書込み可能(EWE)−このビットは実行モ
ードから書込む。このビームが0でSTOREが実行時に試
行されると、アドレスバイオレーションが発生する。
<13> Execute write enable (EWE)-This bit is written from execute mode. If this beam is 0 and STORE is attempted at run time, address violation will occur.

<14> スパーバイザ書込み可能(SWE)−このビット
はスパーバイザモードから書込む。このビームが0でST
OREがスパーバイザ時に試行されると、アドレスバイオ
レーションが発生する。
<14> Supervisor write enable (SWE)-This bit is written from supervisor mode. This beam is 0 and ST
If ORE is attempted at supervisor time, address violation will occur.

<15> ユーザ書込み可能(UWE)−このビットはユー
ザモードから書込む。このビームが0でSTOREがユーザ
時に試行されると、アドレスバイオレーションが発生す
る。
<15> User writable (UWE)-This bit is written from user mode. If this beam is 0 and STORE is attempted at user time, address violation will occur.

<31:16> ソフトウエア用に保持 <63:32> ページフレーム番号(PFN)−PFNフィール
ドはページ境界に常時指向する。Vがセットされると、
PFNは仮想アドレスのバイトウイズインページで連結さ
れて物理アドレスを得る。Vがクリアされるとこのフィ
ールドはソフトウエアにより使用できる。
<31:16> Reserved for software. <63:32> Page frame number (PFN)-The PFN field always points to the page boundary. When V is set,
The PFN is concatenated by the byte-in-page of the virtual address to obtain the physical address. When V is cleared, this field can be used by software.

───────────────────────────────────────────────────── フロントページの続き (72)発明者 ワイテク リチャード ティー アメリカ合衆国 マサチューセッツ州 01460 リトルトン シルヴァーバード レイン 8 (72)発明者 ロビンソン ポール ティー アメリカ合衆国 マサチューセッツ州 02174 アーリントン ガードナー ス トリート 61 (56)参考文献 特開 平1−255945(JP,A) 特開 昭61−206057(JP,A) 特開 昭62−212746(JP,A) 特開 昭59−218693(JP,A) 特開 昭60−171552(JP,A) ──────────────────────────────────────────────────続 き Continued on the front page (72) Inventor Wi-Tech Richard Tea USA Massachusetts 01460 Littleton Silverbird Lane 8 (72) Inventor Robinson Paul Tee Massachusetts USA 02174 Arlington Gardner's Treat 61 (56) References JP1 -255945 (JP, A) JP-A-61-206057 (JP, A) JP-A-62-212746 (JP, A) JP-A-59-218693 (JP, A) JP-A-60-171552 (JP, A) )

Claims (4)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】仮想アドレスを物理アドレスにトランスレ
ートするトランスレーションバッファを具えたプロセッ
サの作動方法において、 このトランスレーションバッファに、各々が仮想アドレ
スタグによりインデックスされたページフレーム番号を
含む複数のページテーブルエントリを記憶させ; さらにこのトランスレーションバッファには、各ページ
テーブルエントリに対しアドレススペース番号およびア
ドレススペース整合エントリをも記憶させ、ここにおい
て、このアドレススペース番号は前記プロセッサで実行
されたプロセスに対応する値であり、前記整合エントリ
は、アドレススペース番号が整合される必要があること
を示すある値を有し、且つアドレススペース番号が整合
される必要がないことを示す他の値を有するフィールド
であり、 前記プロセッサの状態を反映する値としてこのプロセッ
サに現在の番号を記憶させ、 前記整合エントリをディスエーブルする必要があるとい
うある条件と、ディスエーブルする必要がないという他
の条件とを示す第3の整合値を記憶させ、 前記仮想アドレスタグと前記プロセッサにより発生した
仮想アドレスのフィールドとを比較するとともに、前記
アドレススペース番号と前記現在の番号とを比較して、
前記仮想アドレスタグと仮想アドレスの前記フィールド
の比較で整合あるときは; 前記アドレススペース番号と前記現在の番号との比較に
よって前記整合が生じ、且つ整合エントリが前記ある値
である場合には、メモリ参照に対し前記ページフレーム
番号を用い;かつ 前記整合エントリが前記他の値であっても、前記第3の
整合値が前記ある条件を示す場合には、前記アドレスス
ペース番号が前記現在の番号と整合するかどうかにかか
わらずメモリ参照に対しページフレーム番号を用いる各
ステップを具えることを特徴とするプロセッサ作動方
法。
1. A method of operating a processor comprising a translation buffer for translating a virtual address to a physical address, the translation buffer having a plurality of page tables each containing a page frame number indexed by a virtual address tag. The translation buffer also stores an address space number and an address space match entry for each page table entry, where the address space number corresponds to a process executed on the processor. A value, wherein the matching entry has a value indicating that the address space number needs to be matched and a field having another value indicating that the address space number does not need to be matched. And having the processor store a current number as a value reflecting the state of the processor, indicating certain conditions that the matching entry needs to be disabled and other conditions that do not need to be disabled. Storing a third match value, comparing the virtual address tag with a virtual address field generated by the processor, and comparing the address space number with the current number;
If there is a match in the comparison of the virtual address tag and the field of the virtual address; if the match occurs by comparing the address space number with the current number, and if the match entry is the certain value, the memory Use the page frame number for reference; and if the third match value indicates the certain condition, even if the match entry is the other value, the address space number is the same as the current number. A method of operating a processor, comprising the steps of using a page frame number for memory references, whether matched or not.
【請求項2】仮想アドレスを物理アドレスにトランスレ
ートするトランスレーションバッファを有するCPUおよ
びメモリを具えるプロセッサシステムを作動させるに当
たり、 前記トランスレーションバッファに多数のページテーブ
ルエントリ番号を記憶し、各ページテーブルエントリは
仮想アドレスタグ、ページフレーム番号及びアドレスス
ペース番号を含んで前記ページフレーム番号により参照
された前記メモリ内に、ある位置を特徴付け; また各ページテーブルエントリに対し前記トランスレー
ションバッファ内に、 (a)前記アドレススペース番号が前記プロセッサのあ
る状態の一部分として記憶された現在の値と整合する必
要があることを示すある値と、前記アドレススペース番
号が前記現在の値と整合する必要がないことを示す他の
値とを有するアドレススペース整合表示を記憶し、さら
に (b)前記アドレススペース整合インディケータをエン
トリに対し作動させるべきことを特定する第1の値と、
前記アドレススペース整合インディケータをエントリに
対し作動させる必要のないことを示す第2の値とを有す
る整合ディスエーブル表示を記憶し;且つ 前記プロセッサにより発生した仮想アドレスのフィール
ドと、前記トランスレーションバッファのページテーブ
ルエントリの1つの仮想アドレスタグとを比較する比較
ステップを具え; 前記比較ステップが整合を示し、前記アドレススペース
整合表示が他の値であり、前記アドレススペース番号が
前記プロセッサの状態の一部として記憶された前記現在
の値と整合する際、前記メモリをアドレス指定する前記
ページフレーム番号を用い; 前記比較ステップが前記整合を示し、前記アドレススペ
ース整合表示が前記ある値をとるときは、前記アドレス
スペース番号が前記現在の値と整合するかどうかに関係
なく、前記メモリをアドレス指定するページフレーム番
号を用い; 前記比較ステップが整合を示し、かつ前記整合ディエー
ブル表示が第2の値であるときは前記アドレススペース
整合表示が前記ある値であるか前記他の値であるかに関
係なく、前記アドレススペース番号が前記現在の値と整
合する場合にのみ前記メモリをアドレス指定するページ
フレーム番号を用いるようにしたことを特徴とするプロ
セッサシステム作動方法。
2. In operating a processor system having a CPU and a memory having a translation buffer for translating a virtual address to a physical address, a plurality of page table entry numbers are stored in the translation buffer. An entry characterizes a location in the memory referenced by the page frame number, including a virtual address tag, a page frame number and an address space number; and in the translation buffer for each page table entry: a) a value indicating that the address space number needs to match a current value stored as part of a state of the processor, and that the address space number does not need to match the current value. Other A first value specifying that stores an address space alignment indicia and a value, to further (b) is operated to entry the address space matching indicator,
Storing a match disable indication having a second value indicating that the address space match indicator need not be activated for an entry; and a field of a virtual address generated by the processor, and a page of the translation buffer. A comparison step of comparing a table entry with one virtual address tag; said comparison step indicating a match, said address space match indication being another value, and said address space number being part of a state of said processor. Using the page frame number to address the memory when matching with the stored current value; the address when the comparing step indicates the match and the address space match indication takes on the certain value. Space number matches the current value Using a page frame number to address the memory, whether or not; if the comparing step indicates a match and the match disable indication is a second value, the address space match indication is at the certain value. Processor system operation, characterized in that a page frame number addressing the memory is used only when the address space number matches the current value, regardless of whether it is or the other value. Method.
【請求項3】プロセッサにおいて、仮想アドレスを物理
アドレスにトランスレートするトランスレーションバッ
ファを含み、このトランスレーションバッファによって
複数のページテーブルエントリを記憶し、各ページテー
ブルエントリは仮想アドレスタグによりインデックスさ
れるページフレーム番号を含むアドレス指定手段と; 前記トランスレーションバッファは、各前記ページテー
ブルエントリに対するアドレススペース番号記憶手段、
アドレススペース整合エントリ記憶手段、および整合デ
ィスエーブルインディケータの記憶手段とを含み、前記
アドレススペース番号は前記プロセッサで実行されたプ
ロセスに対応し、前記整合エントリはアドレススペース
番号が整合されることが必要であることを示すある値
と、アドレススペース番号が整合されることが必要でな
いことを示す他の値とを有するフィールドとし、前記整
合ディスエーブルインディケータは整合エントリが無視
されることを示す第1の値と、整合エントリが無視すべ
きでないことを示す第2の値とを有する表示とし; さらに前記プロセッサのある状態の一部として、前記ア
ドレススペース番号を表わす現在の番号を前記プロセッ
サに保持する手段と; 前記仮想アドレスタグと前述したプロセッサにより発生
した仮想アドレスのフィールドとを比較する第1手段
と、前記アドレススペース番号と現在の番号とを比較す
る第2手段とを具え; 前記第1および第2比較手段の双方が整合を発生し、前
記整合エントリが前記ある値である際前記アドレス指定
手段はメモリ参照に対し前記ページフレーム番号を用
い; 前記仮想アドレスタグと前記仮想アドレスの前記フィー
ルドとの比較手段が前記整合を発生し前記整合エントリ
が前記他の値である場合には、前記ディスエーブルイン
ディケータが前記他の値にセットされなければ、前記第
2比較手段によって前記アドレススペース番号が前記現
在の番号と整合することを検出するかどうかにかかわら
ず、前記アドレス指定手段がメモリ参照に対し前記ペー
ジフレーム番号を用いるようにしたことを特徴とするプ
ロセッサ。
3. The processor includes a translation buffer for translating a virtual address to a physical address, the translation buffer storing a plurality of page table entries, each page table entry being a page indexed by a virtual address tag. Addressing means including a frame number; the translation buffer comprising an address space number storing means for each of the page table entries;
Address space matching entry storage means, and storage means for a matching disable indicator, wherein the address space number corresponds to a process executed by the processor, and the matching entry requires that the address space number be matched. A field having a value indicating that there is one and another value indicating that the address space number does not need to be matched, wherein the match disable indicator is a first value indicating that the match entry is ignored And an indication having a second value indicating that the matching entry should not be ignored; and means for maintaining in the processor a current number representing the address space number as part of a state of the processor; Generated by said virtual address tag and said processor First means for comparing the address space number with a current number; and both the first and second comparing means generate a match, The addressing means uses the page frame number for memory references when the match entry is the certain value; the means for comparing the virtual address tag with the field of the virtual address generates the match and the match entry is If the other value, if the disable indicator is not set to the other value, the second comparing means determines whether the address space number matches the current number. Regardless, the address designating means uses the page frame number for memory reference. Processor.
【請求項4】CPUおよびメモリを有するプロセッサシス
テムにおいて、 a)前記CPU内で前記メモリから命令をフェッチし、こ
のCPU内でこの命令を復号化し、CPU内で読取りおよび書
込みデータのメモリにアクセスする命令を実行する手段
と; b)前記CPU内で前記命令のフェッチ手段およびデータ
メモリのアクセス手段に用いられる仮想アドレスを発生
する手段と; c)前記メモリ内に記憶され各々が前記メモリの異なる
ページを参照するページフレーム番号を有する複数のペ
ージテーブルエントリを含むページテーブルと; d)多数の前記ページテーブルエントリを記憶するトラ
ンスレーションバッファを含み、前記メモリに対し仮想
アドレスを物理アドレスにトランスレートする手段と; e)前記トランスレーションバッファからのページフレ
ーム番号を用いるとともに仮想アドレスの一部分を用い
るメモリをアドレス指定する手段とを具え; f)前記トランスレーションバッファは各ページテーブ
ルエントリに対しアドレスタグおよびアドレススペース
番号を記憶するとともにアドレススペース整合エントリ
を記憶し、ここで前記アドレススペース番号は前記CPU
で実行されたプロセスに対応する値とし、且つ前記整合
エントリはアドレススペース番号が整合される必要があ
ることを示すある値と、かつアドレススペース番号が整
合される必要のないことを示す他の値とを有するインデ
ィケータとし、また前記トランスレーションバッファは
各ページテーブルエントリに対し整合ディスエーブルイ
ンディケータをも記憶し、前記CPU内で現在の値を記憶
する手段によって前記CPUのある状態の一部として保持
されるアドレススペース番号を表わし; g)トランスレーションバッファ内で前記アドレスタグ
と前記CPUにより発生した前記仮想アドレスのフィール
ドとを比較するとともに前記アドレススペース番号と前
記CPUの前記状態の部分として保持される前記現在の番
号とをも比較する比較手段とを具え; 前記比較手段による比較動作の双方が整合を発生すると
ともに前記整合エントリが前記ある値である場合には前
記アドレス指定手段はメモリ参照に対しあるページフレ
ーム番号を用い;また 前記アドレスタグと前記仮想アドレスのフィールドとの
比較により整合が生ずる場合および前記整合エントリが
前記他の値である場合には、前記ディスエーブル整合イ
ンディケータをセットしなければ、前記アドレススペー
ス番号が前記現在の番号と整合するかどうかにかかわら
ず前記アドレス指定手段が前記メモリ参照に対し前記ペ
ージフレーム番号を用いるようにしたことを特徴とする
プロセッサシステム。
4. A processor system having a CPU and a memory, comprising: a) fetching an instruction from the memory in the CPU, decoding the instruction in the CPU, and accessing a memory of read and write data in the CPU. Means for executing instructions; b) means for generating virtual addresses in the CPU for use in fetching the instructions and accessing the data memory; c) different pages stored in the memory, each of which being a different page of the memory. Means for translating a virtual address to a physical address for said memory, including a translation buffer for storing a plurality of said page table entries; E) the page from the translation buffer Means for addressing memory using a frame number and a portion of the virtual address; f) said translation buffer stores an address tag and an address space number for each page table entry and an address space matching entry. Where the address space number is the CPU
And a value indicating that the address space numbers need to be matched, and another value indicating that the address space numbers do not need to be matched. And the translation buffer also stores a matching disable indicator for each page table entry and is held as part of a state of the CPU by means for storing a current value in the CPU. G) comparing the address tag with a field of the virtual address generated by the CPU in a translation buffer and maintaining the address space number and a portion of the state of the CPU. With means for comparing also with the current number; When both of the comparing operations by the comparing unit generate a match and the matching entry is the certain value, the address specifying unit uses a certain page frame number for memory reference; If the match with the field results in a match and the match entry is the other value, then setting the disable match indicator will determine whether the address space number matches the current number. Processor system, wherein the address designating means uses the page frame number for the memory reference.
JP5501650A 1991-06-28 1992-06-25 CPU execution method Expired - Lifetime JP2608680B2 (en)

Applications Claiming Priority (4)

Application Number Priority Date Filing Date Title
US07/722,869 US5319760A (en) 1991-06-28 1991-06-28 Translation buffer for virtual machines with address space match
US89243292A 1992-06-10 1992-06-10
US892,432 1992-06-10
US722,869 1992-06-10

Publications (2)

Publication Number Publication Date
JPH06500417A JPH06500417A (en) 1994-01-13
JP2608680B2 true JP2608680B2 (en) 1997-05-07

Family

ID=27110681

Family Applications (1)

Application Number Title Priority Date Filing Date
JP5501650A Expired - Lifetime JP2608680B2 (en) 1991-06-28 1992-06-25 CPU execution method

Country Status (1)

Country Link
JP (1) JP2608680B2 (en)

Also Published As

Publication number Publication date
JPH06500417A (en) 1994-01-13

Similar Documents

Publication Publication Date Title
EP0548315B1 (en) Translation buffer for virtual machines with address space match
US5367705A (en) In-register data manipulation using data shift in reduced instruction set processor
KR100218572B1 (en) Granularity hint for translation buffer in high performace processor
KR100230643B1 (en) Branch prediction in hi performance processor
EP0465321B1 (en) Ensuring data integrity in multiprocessor or pipelined processor system
US5995746A (en) Byte-compare operation for high-performance processor
KR100230105B1 (en) Data prefetch instruction in a reduced instruction set processor
US6167509A (en) Branch performance in high speed processor
WO1996012231A1 (en) A translation buffer for detecting and preventing conflicting virtual addresses from being stored therein
US5469551A (en) Method and apparatus for eliminating branches using conditional move instructions
US5819080A (en) Microprocessor using an instruction field to specify condition flags for use with branch instructions and a computer system employing the microprocessor
JP2608680B2 (en) CPU execution method