JPH077365B2 - Information processing equipment - Google Patents

Information processing equipment

Info

Publication number
JPH077365B2
JPH077365B2 JP62136879A JP13687987A JPH077365B2 JP H077365 B2 JPH077365 B2 JP H077365B2 JP 62136879 A JP62136879 A JP 62136879A JP 13687987 A JP13687987 A JP 13687987A JP H077365 B2 JPH077365 B2 JP H077365B2
Authority
JP
Japan
Prior art keywords
address
memory
entry
instruction
virtual
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 - Fee Related
Application number
JP62136879A
Other languages
Japanese (ja)
Other versions
JPS63298652A (en
Inventor
陽一 矢野
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
NEC Corp
Original Assignee
NEC Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by NEC Corp filed Critical NEC Corp
Priority to JP62136879A priority Critical patent/JPH077365B2/en
Publication of JPS63298652A publication Critical patent/JPS63298652A/en
Publication of JPH077365B2 publication Critical patent/JPH077365B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Description

【発明の詳細な説明】 [産業上の利用分野] 本発明は、情報処理装置に関するものであり、特に、仮
想記憶環境下で、マルチプロセサ構成をサポートする不
可分更新命令の方式に関するものである。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an information processing apparatus, and more particularly, to an atomic update instruction method that supports a multiprocessor configuration in a virtual memory environment.

[従来の技術] 計算機システムの発展にともない、計算機には高速な処
理のみならず、高度な処理も要求されるようになってき
ている。半導体技術を応用したマイクロプロセッサ(MP
Uと略す)の分野でも高度な処理が要求されており、特
にその中でも32ビットMPUと呼ばれる分野において、そ
の傾向は顕著である。
[Prior Art] With the development of computer systems, not only high-speed processing but also high-level processing is required of computers. Microprocessor that applies semiconductor technology (MP
U) is also required in the field of advanced processing, especially in the field called 32-bit MPU, the tendency is remarkable.

高度な処理の1つに、複数のMPUからなるマルチプロセ
ッサ・システムがある。このシステムでは、複数のプロ
セッサが同時に動作し処理を行うので、処理性能の向上
が図れる(負荷分散)こと、また異種のMPUを接続する
ことにより問題に適したMPUに処理を委託することがで
きる(機能分散)こと、などの利点がある。この種のマ
ルチプロセッサ環境では、MPUが資源にアクセスすると
きに競合が起こることがある。たとえば、システムに1
つのCRT装置しかないとき、複数のプロセッサが同時にC
RTへの出力要求を出すならば、画面には複数プロセッサ
の出力を重畳したイメージが表示されてしまう。このと
き、複数の要求を逐次化する機構が必要である。通常
は、マルチプロセサ環境での逐次化を実現するために、
テストとセット(TASI)命令などのインターロック付き
の命令が提供されている。これらの命令では、あるメモ
リ領域の内容のリード・モディファイ・ライト(RMWと
略す)のアクセスを単一の不可分アクセスとして実現し
ており、複数のプロセッサが同時に同じ領域にこのアク
セスを行おうとしても、正しい結果(逐次化された結
果)が得られるようにしている。たとえば、 TASI lock_byte という命令では、lock_byteという名称のメモリ中の情
報に対するRMWアクセスを、他のプロセッサの介入を許
すことなく不可分に行う。命令はlock byteの読み込
み、0との比較、そして定数(例えば0xff)の書き込
み、の3ステップをインターロック付きで実現する。マ
ルチプロセッサ環境での逐次化処理では、そのような不
可分の機構が提供されている必要性は言うまででもない
が、その処理時間が短いことも重要である。とくに、プ
ロセッサ数が大きくなるにしたがって逐次化処理の頻度
が大きくなるため、高速の逐次化処理が必要となる。一
方、最近のMPUでは、仮想記憶管理機構(例えばページ
ング方式)を組み込んだものが現れてきている。仮想記
憶管理機構を採用することにより、実メモリの大きさに
とらわれることなくプログラムの作成ができる(仮想記
憶)こと、あまり使用しないデータを含む領域を二次記
憶装置に保持することで実メモリの有効活用が図れるこ
と、更に仮想記憶管理機構に特有のアクセス保護機構に
より安全なシステム走行が実現できる(実行時安全保
証)ことなどの利点がある。仮想記憶管理機構では、メ
モリ中の情報であるアドレス変換テーブルを頻繁に書き
換える。これは、あるページを二次記憶装置に追い出し
たときにそのページがもはや実メモリ上にはないことを
記すとき、ページのアクセス情報(参照されたか、書き
換えられたか)を変更するとき、あるいはどのページを
追い出すかの参照の頻度を記録するときなどの場合であ
る。このとき、オペレーティング・システム(OS)がア
ドレス変換テーブルの内容を捜し出し書き換えるときに
は仮想空間上でのアドレスでアクセスできれば便利であ
る。それは、ある仮想アドレスを含むページのアドレス
変換情報(ページ・テーブル・エントリ;PTEと略す)に
アクセスするのに、アーキテクチャが定義するアドレス
変換のパスに従ってPTEを捜し出すことをハードウエア
が自動的に行うので、ソフトウェアがプログラムにより
捜し出すのに対して高速だからである。
One of the advanced processes is a multiprocessor system consisting of multiple MPUs. In this system, multiple processors operate simultaneously and perform processing, so processing performance can be improved (load balancing), and by connecting different types of MPUs, processing can be outsourced to an MPU suitable for the problem. There are advantages such as (function distribution). In this kind of multiprocessor environment, contention may occur when the MPU accesses the resource. For example, one in the system
When you have only one CRT device, multiple processors can
If you issue an output request to the RT, an image with the output of multiple processors superimposed will be displayed on the screen. At this time, a mechanism for serializing a plurality of requests is required. Normally, to achieve serialization in a multiprocessor environment,
Instructions with interlock such as test and set (TASI) instructions are provided. These instructions realize read-modify-write (abbreviated as RMW) access to the contents of a certain memory area as a single atomic access, even if multiple processors try to access this area at the same time. , So that the correct result (serialized result) can be obtained. For example, the TASI lock_byte instruction makes an RMW access to the information in the memory named lock_byte in an atomic manner without allowing the intervention of other processors. The instruction implements the three steps of reading the lock byte, comparing with 0, and writing a constant (eg 0xff) with interlock. Needless to say, it is necessary to provide such an inseparable mechanism in serialization processing in a multiprocessor environment, but it is also important that the processing time is short. In particular, since the frequency of serialization processing increases as the number of processors increases, high-speed serialization processing is required. On the other hand, in recent MPUs, those incorporating a virtual memory management mechanism (for example, a paging method) have appeared. By adopting a virtual memory management mechanism, programs can be created regardless of the size of the real memory (virtual memory), and by holding an area containing data that is rarely used in secondary memory, There are advantages such as effective utilization, and safe system running (runtime security guarantee) due to the access protection mechanism peculiar to the virtual memory management mechanism. The virtual memory management mechanism frequently rewrites the address translation table which is the information in the memory. This is because when a page is flushed to secondary storage, it is noted that the page is no longer in real memory, when it changes access information (whether it was referenced or rewritten), or which This is the case, for example, when recording the frequency of references to eject a page. At this time, when the operating system (OS) finds out and rewrites the contents of the address translation table, it is convenient if the address can be accessed in the virtual space. It accesses the address translation information (page table entry; abbreviated as PTE) of a page containing a virtual address, and the hardware automatically finds the PTE according to the architecture-defined address translation path. Therefore, the software is faster than the program can find it.

[発明が解決しようとする問題点] 上述のような、マルチプロセッサ環境では、これらアド
レス変換テーブルそのものが主記憶上にあるシステム資
源であるために、頻繁に逐次化処理が行われる。特に、
アドレス変換テーブルの内容を書き換えるときには必ず
不可分のRMWアクセスが必要となる。一般のMPUでは、仮
想記憶管理機構に関連した不可分RMW命令は提供されて
おらず、仮想記憶管理を行う度毎にアドレス変換テーブ
ルのエントリを捜し出し、不可分アクセスを行わなけれ
ばならず、マルチプロセッサ環境では頻繁に起こる不可
分動作の速度を低下させるという問題点があった。
[Problems to be Solved by the Invention] In the multiprocessor environment as described above, serialization processing is frequently performed because these address conversion tables themselves are system resources in the main memory. In particular,
When rewriting the contents of the address translation table, inevitable RMW access is required. In general MPU, the atomic RMW instruction related to the virtual memory management mechanism is not provided, and every time virtual memory management is performed, the entry of the address translation table must be searched and the atomic access must be performed. Then, there was a problem that the speed of the inseparable operation that frequently occurs was reduced.

したがって、本発明の目的は中央処理装置の動作速度の
向上を図ることである。
Therefore, an object of the present invention is to improve the operating speed of the central processing unit.

[問題点を解決するための手段および作用] 本発明は、仮想記憶システムを実現させるアドレス変換
機構と、 メモリに対するアクセスを制御する不可分更新命令を実
行可能な命令実現部と、仮想アドレスから実アドレスへ
の変換を可能にするアドレス変換部とをそれぞれ備えた
複数の中央処理装置を含む情報処理装置において、 メモリに対する各中央処理装置の排他的アクセスを可能
にする制御線を有し、上記各中央処理装置のアドレス変
換部は仮想アドレスから実アドレスへアドレス変換する
際に参照する上記メモリ内の第1アドレス変換テーブル
に対応する第2アドレス変換テーブルを有し、 上記第1アドレス変換テーブルは仮想アドレスと実アド
レスの関係を保持する変換テーブル内エントリを有し、 一の中央処理装置の命令実行部は上記変換テーブル内エ
ントリに対する不可分更新命令の実行時に上記制御線を
活性化して上記メモリに対する排他的アクセスを実行
し、上記メモリの変換テーブル内エントリに対応する第
2アドレス変換テーブルの変換テーブル内エントリを更
新すると共に、上記メモリの変換テーブル内エントリも
更新することを特徴とする情報処理装置。
[Means and Actions for Solving Problems] The present invention relates to an address translation mechanism for implementing a virtual memory system, an instruction implementation unit capable of executing an indivisible update instruction for controlling access to a memory, and a virtual address to a real address. In an information processing apparatus including a plurality of central processing units each including an address conversion unit that enables conversion to the central processing unit, a control line that enables exclusive access of each central processing unit to the memory is provided. The address conversion unit of the processing device has a second address conversion table corresponding to the first address conversion table in the memory that is referred to when the address is converted from the virtual address to the real address, and the first address conversion table is the virtual address. Has an entry in the translation table that holds the relationship between the Performs the exclusive access to the memory by activating the control line when executing the atomic update command for the entry in the translation table, and the entry in the translation table of the second address translation table corresponding to the entry in the translation table of the memory. And an entry in the conversion table of the memory are also updated.

[実施例] 第1実施例 本発明について、図面を用いつつ説明する。第1図は本
発明の第1実施例におけるシステム構成のブロック図で
ある。第1図において、100は1つのMPUを示す。101は
システム・バスとの通信を制御するバス・インターフェ
ース部である。102は仮想アドレス・モードで実行中に
仮想アドレスから実アドレスへとアドレス変換するアド
レス変換部である。103は実行すべき命令をデコードす
る命令デコーダである。104は実行すべき命令機能を実
現する命令実行部である。105はシステムに共通のシス
テム・バスである。106はMPU100とシステム・バス105の
間にあるデータ・バスである。107はMPU100からシステ
ム・バス105へのアドレス・バスである。108はシステム
・バス105への排他的アクセス、すなわちメモリへの不
可分アクセスを制御するための制御信号線である。109
はマルチプロセッサ構成をとったときの、他のMPUであ
る。このMPUの構造はMPU100と全く同じである。複数存
在するが、代表を109としている。110はそのMPU109とシ
ステム・バスとのあいだの排他制御のための信号線であ
り、排他制御信号108と同じ働きをMPU109のためにす
る。111はシステムに共通のデータを保持する主メモリ
装置である。
Embodiments First Embodiment The present invention will be described with reference to the drawings. FIG. 1 is a block diagram of the system configuration in the first embodiment of the present invention. In FIG. 1, 100 indicates one MPU. Reference numeral 101 is a bus interface unit that controls communication with the system bus. An address translation unit 102 translates a virtual address into a real address during execution in the virtual address mode. An instruction decoder 103 decodes an instruction to be executed. 104 is an instruction execution unit that realizes an instruction function to be executed. 105 is a system bus common to the systems. 106 is a data bus between the MPU 100 and the system bus 105. 107 is an address bus from the MPU 100 to the system bus 105. Reference numeral 108 is a control signal line for controlling exclusive access to the system bus 105, that is, indivisible access to the memory. 109
Is another MPU in a multiprocessor configuration. The structure of this MPU is exactly the same as the MPU100. There are multiple, but the representative is 109. 110 is a signal line for exclusive control between the MPU 109 and the system bus, and performs the same function as the exclusive control signal 108 for the MPU 109. 111 is a main memory device that holds data common to the system.

この図において、MPU100は主メモリ111内の命令に、シ
ステム・バス105、データ・バス106、アドレス・バス10
7、バス・インターフェース部101等を経由しフェッチす
る。フェッチした命令を命令デコーダ部103は解読し、
実際の命令機能の処理を実行部104にゆだねる。もし、
その命令がシステム資源への排他的な不可分アクセスを
必要とするときには、主メモリ111内にある共通資源制
御のためのデータへのアクセスを、他のMPU109が中断し
たり横取りしないように、排他制御信号線108を用い排
他制御を実現する。この時、MPU100が仮想アドレス・モ
ードで実行しているならば主メモリ111へのアクセスを
実アドレスで行うように、アドレス変換部102を用いて
仮想アドレスから実アドレスへの変換を行う。アドレス
変換を高速に行うために、通常この部分は高速変換緩衝
機構(TLBと略す)で実現する。
In this figure, the MPU 100 has instructions in the main memory 111 for the system bus 105, the data bus 106, and the address bus 10.
7. Fetch via the bus interface unit 101 or the like. The instruction decoder unit 103 decodes the fetched instruction,
The processing of the actual command function is delegated to the execution unit 104. if,
When the instruction requires exclusive atomic access to system resources, exclusive control is performed so that other MPUs 109 do not interrupt or preempt access to data for common resource control in main memory 111. Exclusive control is realized using the signal line 108. At this time, if the MPU 100 is executing in the virtual address mode, the virtual memory is translated into the real address using the address translation unit 102 so that the main memory 111 is accessed by the real address. In order to perform address translation at high speed, this part is usually realized by a high-speed translation buffer mechanism (abbreviated as TLB).

第2図は、本実施例における、仮想アドレスから実アド
レスへの変換の様子を示したものである。第2図におい
て、200は仮想アドレスである。201は仮想アドレス200
のうち、セグメント・テーブル内のエントリ(セグメン
ト・テーブル・エントリ;STEと略す)206を指定する情
報である。202は仮想アドレス200のうち、ページ・テー
ブル内のエントリ(ページ・テーブル・エントリ;PTEと
略す)208を指定する情報である。203はアクセスするデ
ータ211のページ内オフセットを指定する情報である。2
04はアドレス変換テーブルのルートを指すレジスタであ
る。テーブル・ルート・レジスタ(TRRと略す)と呼
ぶ。この場合、セグメント・テーブル205のベース・ア
ドレスを保持する。205はセグメント・テーブルであ
る。アドレス変換テーブルの第1段となる。TRRレジス
タ204がそのベース・アドレスを保持する。206は201が
指定するSTEである。207はページ・テーブルである。ア
ドレス変換テーブルの第2段となる。STE206がそのベー
ス・アドレスを指定する。208は202が指定するPTEであ
る。209は主メモリである。210は主メモリの中のページ
枠であり、PTE208がそのベース・アドレスを指定する。
211はアクセスすべきデータである。ページ内の位置を2
03が指定する。
FIG. 2 shows how a virtual address is converted to a real address in this embodiment. In FIG. 2, 200 is a virtual address. 201 is a virtual address 200
Of these, the information specifies an entry (segment table entry; abbreviated as STE) 206 in the segment table. Information 202 designates an entry (page table entry; abbreviated as PTE) 208 in the page table of the virtual address 200. 203 is information designating an in-page offset of the data 211 to be accessed. 2
04 is a register that points to the root of the address translation table. It is called a table route register (abbreviated as TRR). In this case, the base address of the segment table 205 is held. 205 is a segment table. It is the first stage of the address translation table. The TRR register 204 holds its base address. 206 is the STE specified by 201. 207 is a page table. This is the second stage of the address conversion table. STE206 specifies its base address. 208 is a PTE designated by 202. 209 is a main memory. 210 is a page frame in the main memory, and the PTE 208 specifies its base address.
211 is the data to be accessed. Position on page 2
03 specifies.

第2図に示すように、仮想アドレスから実アドレスへの
アドレス変換は2段のテーブルを参照して行う。第1段
目をセグメント・テーブルと呼び、第2段目をページ・
テーブルと呼ぶ。それぞれのテーブルは、テーブル・エ
ントリからなる。セグメント・テーブルのエントリをセ
グメント・テーブル・エントリ(STE)と呼び、ページ
・テーブルのエントリをページ・テーブル・エントリ
(PTE)と呼ぶ。
As shown in FIG. 2, address conversion from a virtual address to a real address is performed by referring to a two-stage table. The first row is called the segment table and the second row is the page
Call it a table. Each table consists of table entries. An entry in the segment table is called a segment table entry (STE), and an entry in the page table is called a page table entry (PTE).

従来の方式では、マルチプロセッサ構成をとる場合のア
ドレス変換テーブルへの排他的アクセスを2段階の課程
で処理していた。例としてPTEへの排他的RMWアクセスを
する場合を考える。最初の段階ではPTEを探し出すため
に第2図に従ってアドレス変換の手順と同一の手段をソ
フトウェアでたどりPTEを特定する。次の段階では、PTE
自身の内容を更新するために不可分操作命令を使用して
内容のロック付き書換えを行う。
In the conventional method, exclusive access to the address conversion table in the case of the multiprocessor configuration is processed in a two-step process. As an example, consider the case of exclusive RMW access to PTE. In the first stage, in order to find the PTE, the same means as the procedure for address conversion is followed by software according to FIG. 2 to specify the PTE. The next stage is PTE
Rewrite with locks using atomic operations to update its contents.

しかしこの方法では、ソフトウェア的に変換手順をたど
るために性能が低くなるだけでなく、第1段のアドレス
変換テーブル(セグメント・テーブル・エントリ)の内
容の書換えがもし同時に他のプロセッサにより行われた
場合、ソフトウェア的に変換手順をたどる際に正しいPT
Eをアクセスできなくなる可能性がある。従ってPTEへの
排他的アクセスは、STEをまずロックしページ・テーブ
ル全体へのアクセスの権利を確保したのちに行わなくて
はならない。
However, in this method, not only the performance is lowered because the translation procedure is followed by software, but the contents of the address translation table (segment table entry) in the first stage are rewritten by another processor at the same time. If the correct PT when following the conversion procedure by software
E may be inaccessible. Therefore, exclusive access to the PTE must be done after first locking the STE and securing the right to access the entire page table.

本実施例では、次のステップに従ってPTEへの排他的ア
クセスを実現する。まず、命令機能としては TASPIV va,mask という命令を用意する。TASPIVは、Test and set PT
E interlocked with Virtual address access の
略であり、この命令はPTEへの排他的アクセスと書換え
の機能を持つ。オペランドは2つあり、第1オペランド
はPTEを同定するための仮想アドレスを指定するオペラ
ンドで、vaが指定する仮想アドレスを変換するときに参
照するPTEが実際にロックされる対象となる。第2オペ
ランドは、マスク・パタンを指定するオペランドで、PT
Eのうち書き換えるべきビットを指定する。例えばもしP
TEが32ビット長であればマスクも32ビット長である。
In this embodiment, exclusive access to the PTE is realized according to the following steps. First, as the instruction function, an instruction called TASPIV va, mask is prepared. TASPIV is Test and set PT
This is an abbreviation for E interlocked with Virtual address access, and this instruction has the functions of exclusive access to the PTE and rewriting. There are two operands. The first operand is an operand that specifies a virtual address for identifying the PTE, and the PTE that is referenced when converting the virtual address specified by va is the target that is actually locked. The second operand is the operand that specifies the mask pattern and is PT
Specify the bit to be rewritten in E. For example if P
If TE is 32 bits long, the mask is also 32 bits long.

この命令が実行される過程は次のとおりである。第3図
に命令実行フローを示す。
The process by which this instruction is executed is as follows. FIG. 3 shows the instruction execution flow.

(1)排他的にアクセスするために、排他制御線108に
より主メモリ111への排他的アクセス権を得る。
(1) An exclusive access right to the main memory 111 is obtained by the exclusive control line 108 for exclusive access.

(2)第1オペランドvaが指定するオペランド・データ
を仮想アドレス200とみなし、第2図で示すアドレス変
換プロセスをたどり、TRR204、セグメント・テーブル20
6、ベージ・テーブルをアクセスし、PTE208を特定す
る。
(2) The operand data specified by the first operand va is regarded as the virtual address 200, and the address conversion process shown in FIG. 2 is followed, TRR204, segment table 20.
6. Access the page table and identify the PTE 208.

(3)特定したPTE208の内容を読みだし、マスクをと
り、書き換える。命令機能は、 TMP ← PTE ;PTEをフェッチする 比較 ← (OXFFFFFFFF and(not mask))−(TMP
and(not mask));マスク付きでオール1のパタン
と比較する PTE ← TMP and (not mask));PTEを更新する というものである。ここでPTEはページ・テーブル・エ
ントリ208自身、maskは第2オペランドが指定するマス
ク・パタンのデータである。
(3) Read out the contents of the specified PTE208, remove the mask, and rewrite. Instruction function is TMP ← PTE; PTE fetch comparison ← (OXFFFFFFFF and (not mask)) − (TMP
and (not mask)); PTE ← TMP and (not mask)); PTE that is compared with the pattern of all 1s with a mask is updated. Here, PTE is the page table entry 208 itself, and mask is the data of the mask pattern specified by the second operand.

(4)結果をPTE208の場所に書き込んだあとに排他的ア
クセスが終了するので、排他制御線108により主メモリ1
11への排他的アクセスを終らせる。
(4) Since exclusive access ends after writing the result to the PTE208 location, the exclusive control line 108 causes the main memory 1
End exclusive access to 11.

第2実施例 次に、本発明の第2実施例について図面を用いつつ説明
する。
Second Embodiment Next, a second embodiment of the present invention will be described with reference to the drawings.

第1の実施例では、2段の変換テーブルをアクセスしPT
Eを不可分動作で更新する際に、PTEの処理がすべて終了
するまでセグメント・テーブルへのアクセスがロックさ
れ禁止されているため、複数のMPUが同一のページ・テ
ーブル内の複数のPTEを同時に更新しようとしても、一
度に1つのPTEしか更新できないという問題がある。す
なわち、2段の変換テーブル全体へのアクセスを不可分
としている。その間に他のMPUが横取り(ブリエンプシ
ョン)をしようとしてもできない。
In the first embodiment, the two-stage conversion table is accessed to access the PT
When E is updated by atomic operation, access to the segment table is locked and prohibited until all PTEs are processed, so multiple MPUs update multiple PTEs in the same page table at the same time. Even if it tries, there is a problem that only one PTE can be updated at a time. That is, access to the entire two-stage conversion table is inseparable. In the meantime, even if another MPU tries to steal (briemption), it cannot be done.

第2実施例として次に説明するものは、2段のアクセス
の最中に横取りを許す方法である。
What will be described below as a second embodiment is a method of permitting pre-emption during two-stage access.

第4図は本発明の第2実施例におけるシステム構成のブ
ロック図である。第4図において、400は1つのMPUを示
す。401はシステム・バスとの通信を制御するバス・イ
ンターフェース部である。402は仮想アドレス・モード
で実行中に、仮想アドレスから実アドレスへと変換する
アドレス変換部である。403は実行すべき命令をデコー
ドする命令デコーダである。404は実行すべき命令機能
を行う命令実行部である。405はシステムに共通のシス
テム・バスである。406はMPU400とシステム・バス405の
あいだにあるデータ・バスである。407はMPU400からシ
ステム・バス405へのアドレス・バスである。408はシス
テム・バス405への排他的アクセスすなわちメモリへの
不可分アクセスを制御するための制御信号線である。40
9はマルチプロセッサ構成をとったときの、他のMPUであ
る。このMPUの構造はMPU400と全く同じである。複数存
在するが、代表を409としている。410はそのMPU409とシ
ステム・バスとのあいだの排他制御のための信号線であ
り、排他制御信号408と同じ働きをMPU409のためにす
る。411はシステムに共通のデータを保持する主メモリ
装置である。
FIG. 4 is a block diagram of the system configuration in the second embodiment of the present invention. In FIG. 4, 400 indicates one MPU. 401 is a bus interface unit that controls communication with the system bus. Reference numeral 402 is an address translation unit that translates a virtual address into a real address during execution in the virtual address mode. An instruction decoder 403 decodes an instruction to be executed. An instruction execution unit 404 performs an instruction function to be executed. 405 is a system bus common to the systems. 406 is a data bus between the MPU 400 and the system bus 405. 407 is an address bus from the MPU 400 to the system bus 405. Reference numeral 408 is a control signal line for controlling exclusive access to the system bus 405, that is, indivisible access to the memory. 40
9 is another MPU in a multiprocessor configuration. The structure of this MPU is exactly the same as the MPU400. There are multiple, but the representative is 409. Reference numeral 410 is a signal line for exclusive control between the MPU 409 and the system bus, and performs the same function as the exclusive control signal 408 for the MPU 409. Reference numeral 411 is a main memory device that holds data common to the system.

第5図は、本実施例における、仮想アドレスから実アド
レスへの変換の様子を示したものである。第5図におい
て、500は仮想アドレスである。501は仮想アドレス500
のうち、セグメント・テーブル内のエントリ(セグメン
ト・テーブル・エントリ;STEと略す)506を指定する情
報である。502は仮想アドレス500のうち、ページ・テー
ブル内のエントリ(ページ・テーブル・エントリ;PTEと
略す)508を指定する情報である。503はアクセスするデ
ータ511のページ内オフセットを指定する情報である。5
04はアドレス変換テーブルのルートを指すレジスタであ
る。テーブル・ルート・レジスタ(TRRと略す)と呼
ぶ。この場合、セグメント・テーブル505のベース・ア
ドレスを保持する。505はセグメント・テーブルであ
る。アドレス変換テーブルの第1段となる。TRRレジス
タ504がそのベース・アドレスを保持する。506は501が
指定するSTEである。507はページ・テーブルである。ア
ドレス変換テーブルの第2段となる。STE506がそのベー
ス・アドレスを指定する。508は502が指定するPTEであ
る。509は主メモリである。510は主メモリの中のページ
枠であり、PTE508がそのベース・アドレスを指定する。
511はアクセスすべきデータである。ページ内の位置を5
03が指定する。第2実施例では、次のステップに従って
PTEへの排他的アクセスを実現する。まず、命令機能と
しては TASPIV2 va,mask という命令を用意する。TASPIV2は、Test and Set P
TE interlocked with Virtual address access,pa
rt2の略であり、この命令はPTEへの排他的アクセスと書
換えの機能を持つ、オペランドの機能は、第1実施例と
同じである。
FIG. 5 shows how a virtual address is converted to a real address in this embodiment. In FIG. 5, 500 is a virtual address. 501 is a virtual address 500
Of these, the information specifies an entry (segment table entry; abbreviated as STE) 506 in the segment table. 502 is information that specifies an entry (page table entry; abbreviated as PTE) 508 in the page table of the virtual address 500. Reference numeral 503 is information designating an in-page offset of the data 511 to be accessed. Five
04 is a register that points to the root of the address translation table. It is called a table route register (abbreviated as TRR). In this case, the base address of the segment table 505 is held. 505 is a segment table. It is the first stage of the address translation table. The TRR register 504 holds its base address. 506 is an STE designated by 501. 507 is a page table. This is the second stage of the address conversion table. STE506 specifies its base address. 508 is a PTE designated by 502. 509 is the main memory. 510 is a page frame in the main memory, and the PTE 508 specifies its base address.
Reference numeral 511 is data to be accessed. Position on page 5
03 specifies. In the second embodiment, follow the steps below:
Achieve exclusive access to the PTE. First, the instruction function TASPIV2 va, mask is prepared. TASPIV2 is Test and Set P
TE interlocked with Virtual address access, pa
This command is an abbreviation for rt2, and this instruction has the functions of exclusive access to the PTE and rewriting. The function of the operand is the same as in the first embodiment.

第2実施例が第1実施例と異なる点は、変換テーブル・
アクセスの際に、アクセスを不可分とせず、途中でプリ
エンプションを許す点である。ただし論理的な矛盾が起
こらないように、セグメント・テーブル・エントリに使
用数カウンタを設け使用中かどうか、使用中の場合はい
くつのプロセスが使用しているかを記す。使用中でなけ
ればカウンタは0である。STEを更新する場合には、PTE
へのアクセスを禁止しなければならないのでSTE使用中
という状態を、使用数カウンタが−1という値で示す。
PTEの更新の場合は、もしSTEの使用数カウンタが−1で
あればアクセスできないので異常終了となる。
The difference between the second embodiment and the first embodiment is that the conversion table
When accessing, preemption is allowed on the way without making the access indivisible. However, in order to prevent a logical inconsistency, the segment table entry is provided with a usage counter, and it is noted whether it is in use, and if so, how many processes are using it. The counter is 0 when not in use. To update the STE, use the PTE
Since the access to the STE must be prohibited, the STE in use status is indicated by a value of -1 in the usage counter.
In the case of updating the PTE, if the usage counter of the STE is -1, access is not possible and the processing ends abnormally.

この命令の実行フローを第6図に示す。The execution flow of this instruction is shown in FIG.

[発明の効果] 上記の方法を採用することにより、 (1)一命令でページ・テーブル・エントリ(PTE)へ
の排他的リード・モディファイ・ライトRMW)アクセス
ができる (2)排他的アクセスの時間を短くできるという効果が
得られる。
[Advantages of the Invention] By adopting the above method, (1) exclusive read-modify-write RMW) access to a page table entry (PTE) can be performed with one instruction (2) exclusive access time The effect is that the can be shortened.

すなわち、従来のMPUでは単にメモリ上にある逐次化ア
クセスしなければならないデータに対する不可分RMW命
令が存在していたのみであり、アドレス変換テーブルの
なかのエントリに対して仮想アドレスでアクセスし、か
つ不可分にRMWを行うという機能は提供していなかっ
た。しかしながら、本発明では一命令でページ・エント
リ・テーブルへの排他的リード・モディファイ・ライト
が可能になった。
That is, in the conventional MPU, there is only an indivisible RMW instruction for the data in the memory that must be serialized and accessed, and the entry in the address translation table is accessed by the virtual address, and It did not provide the function of performing RMW. However, the present invention enables exclusive read-modify-write to the page entry table with one instruction.

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

第1図は本発明の第1実施例における複数プロセッサ構
成のシステム構成と各中央処理装置の構成を示すブロッ
ク図、第2図は本発明の第1実施例における仮想アドレ
スと実アドレスとの対応を示すブロック図、第3図は本
発明の第1実施例における変換テーブルの更新を不可分
に行う命令の処理の手順を示すフローチャート図、第4
図は本発明の第2実施例における複数プロセッサ構成の
システム構成と各中央処理装置の構成を示すブロック
図、第5図は本発明の第2実施例における仮想アドレス
と実アドレスとの対応を示すブロック図、第6図は本発
明の第2実施例における変換テーブルの更新を不可分に
行う命令の処理の手順を示すフローチャート図である。 100,400……マイクロプロセッサ、 101,401……バスインターフェース部、 102,402……アドレス変換部、 103,403……命令デコーダ部、 104,404……実行部、 105,405……システムバス、 106,406……データバス、 107,407……アドレスバス、 108,408……排他制御線、 109,409……マイクロプロセッサ、 110,410……排他制御線、 111,411……メモリ。
FIG. 1 is a block diagram showing the system configuration of a multiprocessor configuration and the configuration of each central processing unit in the first embodiment of the present invention, and FIG. 2 is the correspondence between virtual addresses and real addresses in the first embodiment of the present invention. FIG. 3 is a block diagram showing the first embodiment of the present invention, and FIG. 4 is a flow chart showing the procedure of processing an instruction for inseparably updating the conversion table in the first embodiment of the present invention.
FIG. 5 is a block diagram showing the system configuration of a multiprocessor configuration and the configuration of each central processing unit in the second embodiment of the present invention, and FIG. 5 shows the correspondence between virtual addresses and real addresses in the second embodiment of the present invention. A block diagram and FIG. 6 are flowcharts showing a procedure of processing of an instruction for inseparably updating the conversion table in the second embodiment of the present invention. 100,400 ... Microprocessor, 101,401 ... Bus interface section, 102,402 ... Address conversion section, 103,403 ... Instruction decoder section, 104,404 ... Execution section, 105,405 ... System bus, 106,406 ... Data bus, 107,407 ... Address bus , 108,408 …… Exclusive control line, 109,409 …… Microprocessor, 110,410 …… Exclusive control line, 111,411 …… Memory.

Claims (2)

【特許請求の範囲】[Claims] 【請求項1】仮想記憶システムを実現させるアドレス変
換機構と、 メモリに対するアクセスを制御する不可分更新命令を実
行可能な命令実現部と、仮想アドレスから実アドレスへ
の変換を可能にするアドレス変換部とをそれぞれ備えた
複数の中央処理装置を含む情報処理装置において、 メモリに対する各中央処理装置の排他的アクセスを可能
にする制御線を有し、上記各中央処理装置のアドレス変
換部は仮想アドレスから実アドレスへアドレス変換する
際に参照する上記メモリ内の第1アドレス変換テーブル
に対応する第2アドレス変換テーブルを有し、 上記第1アドレス変換テーブルは仮想アドレスと実アド
レスの関係を保持する変換テーブル内エントリを有し、 一の中央処理装置の命令実行部は上記変換テーブル内エ
ントリに対する不可分更新命令の実行時に上記制御線を
活性化して上記メモリに対する排他的アクセスを実行
し、上記メモリの変換テーブル内エントリに対応する第
2アドレス変換テーブルの変換テーブル内エントリを更
新すると共に、上記メモリの変換テーブル内エントリも
更新することを特徴とする情報処理装置。
1. An address translation mechanism that implements a virtual memory system, an instruction implementation unit that can execute an atomic update instruction that controls access to a memory, and an address translation unit that enables translation from a virtual address to a real address. In an information processing apparatus including a plurality of central processing units, each of which has a control line that enables each central processing unit to have exclusive access to a memory, and the address conversion unit of each central processing unit converts a virtual address to a real address. It has a second address conversion table corresponding to the first address conversion table in the memory that is referred to when the address is converted into an address, and the first address conversion table is in the conversion table that holds the relationship between the virtual address and the real address. The instruction execution unit of one central processing unit has an entry When the divisible update instruction is executed, the control line is activated to perform exclusive access to the memory, update the entry in the translation table of the second address translation table corresponding to the entry in the translation table of the memory, and An information processing device characterized by also updating an entry in a conversion table of a memory.
【請求項2】上記メモリの変換テーブル内エントリは上
記不可分更新命令のオペランドが指定する仮想アドレス
に基づきアドレス指定される特許請求の範囲1項記載の
情報処理装置。
2. The information processing apparatus according to claim 1, wherein an entry in the conversion table of the memory is addressed based on a virtual address designated by an operand of the atomic update instruction.
JP62136879A 1987-05-29 1987-05-29 Information processing equipment Expired - Fee Related JPH077365B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP62136879A JPH077365B2 (en) 1987-05-29 1987-05-29 Information processing equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP62136879A JPH077365B2 (en) 1987-05-29 1987-05-29 Information processing equipment

Publications (2)

Publication Number Publication Date
JPS63298652A JPS63298652A (en) 1988-12-06
JPH077365B2 true JPH077365B2 (en) 1995-01-30

Family

ID=15185673

Family Applications (1)

Application Number Title Priority Date Filing Date
JP62136879A Expired - Fee Related JPH077365B2 (en) 1987-05-29 1987-05-29 Information processing equipment

Country Status (1)

Country Link
JP (1) JPH077365B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2015061731A1 (en) 2013-10-27 2015-04-30 Advanced Micro Devices, Inc. Input/output memory map unit and northbridge

Also Published As

Publication number Publication date
JPS63298652A (en) 1988-12-06

Similar Documents

Publication Publication Date Title
US6430657B1 (en) Computer system that provides atomicity by using a tlb to indicate whether an exportable instruction should be executed using cache coherency or by exporting the exportable instruction, and emulates instructions specifying a bus lock
CA2024444C (en) Process using virtual addressing in a non-privileged instruction to control the copying of a page of data in or between multiple media
US4347565A (en) Address control system for software simulation
US6321314B1 (en) Method and apparatus for restricting memory access
JP6202543B2 (en) Method, system and computer program for managing dynamic address translation table
US4742450A (en) Method to share copy on write segment for mapped files
JP4668166B2 (en) Method and apparatus for guest to access memory converted device
US8386750B2 (en) Multiprocessor system having processors with different address widths and method for operating the same
JP6284130B2 (en) Local clear control
US20140337585A1 (en) Page table management
JPH0658650B2 (en) Virtual computer system
JPS6248258B2 (en)
KR970011207B1 (en) Method and apparatus for a register providing atomic access to set and clear individual bits of shared registers without software interlock
JPH08278886A (en) Method and system for operation of extended system management in data-processing system
US20090216929A1 (en) System, method and computer program product for providing a programmable quiesce filtering register
WO1997046937A1 (en) Method and apparatus for caching system management mode information with other information
US8458438B2 (en) System, method and computer program product for providing quiesce filtering for shared memory
US5745676A (en) Authority reduction and restoration method providing system integrity for subspace groups and single address spaces during program linkage
US6865651B2 (en) Method and system for optimizing translation buffer recovery after a miss operation within a multi-processor environment
US5459872A (en) Software control of hardware interruptions
US4991083A (en) Method and system for extending address space for vector processing
US5802397A (en) System for storage protection from unintended I/O access using I/O protection key by providing no control by I/O key entries over access by CP entity
US6862675B1 (en) Microprocessor and device including memory units with different physical addresses
JPH077365B2 (en) Information processing equipment
JPH06332803A (en) Tlb control method in virtual computer system

Legal Events

Date Code Title Description
LAPS Cancellation because of no payment of annual fees