JPH03230251A - Bus control system - Google Patents
Bus control systemInfo
- Publication number
- JPH03230251A JPH03230251A JP2644890A JP2644890A JPH03230251A JP H03230251 A JPH03230251 A JP H03230251A JP 2644890 A JP2644890 A JP 2644890A JP 2644890 A JP2644890 A JP 2644890A JP H03230251 A JPH03230251 A JP H03230251A
- Authority
- JP
- Japan
- Prior art keywords
- bus
- memory
- bus control
- processor
- output buffer
- 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.)
- Granted
Links
Landscapes
- Multi Processors (AREA)
- Information Transfer Systems (AREA)
Abstract
Description
【発明の詳細な説明】
〔産業上の利用分野〕
本発明は、複数のプロセッサとメモリが複数本のバスで
接続されたマルチプロセッサのバス制御方式に関するも
のである。DETAILED DESCRIPTION OF THE INVENTION [Field of Industrial Application] The present invention relates to a bus control system for a multiprocessor in which a plurality of processors and memories are connected by a plurality of buses.
複数台のプロセッサがメモリを共有するマルチプロセッ
サ構成において、互いに矛盾なく処理を実行するために
は、プロセッサ間で共有するデータの排他制御が必要で
ある。In a multiprocessor configuration in which a plurality of processors share memory, exclusive control of data shared among the processors is necessary in order to execute processes without contradiction.
排他制御とは、あるプロセッサが共有データを使用して
処理している間は、他のプロセッサに共用データを使用
させないようにするためのものであり、一般に、次の6
つの処理からなっている(第2図参照)。Exclusive control is to prevent other processors from using shared data while one processor is processing the shared data.
It consists of two processes (see Figure 2).
処理■、テスト&セット命令(T&S)共用データは、
そのデータがプロセッサによる処理を受けているかどう
かを示すロックバイトを持っている。ある共用データの
ロックバイトにtt 1 ttがセットされていれば、
その共用データがプロセッサによる処理を受けているこ
とを示し、0”ならば、処理を受けていない状態にある
ことを示す。Processing ■, test & set instruction (T&S) shared data,
It has a lock byte that indicates whether the data is being processed by the processor. If tt 1 tt is set in the lock byte of some shared data,
This indicates that the shared data is being processed by the processor, and if it is 0'', it indicates that it is not being processed.
テスト&セット命令は、プロセッサが共有データを使え
るか否かをチエツクするための命令であり、
(1)ロックバイトのリードアクセス、(2)読み込ん
だロックバイトがセットされているか否かの判断、
(3)ロックバイトがl Onである場合に“1”にセ
ットするためのメモリへのライトアクセス(1”である
場合は、既に他のプロセッサが、対応するロックバイト
を持つ共用データを用いて処理を行っていることを示す
)、
(4)ロックバイトが“O”であるか、パ1”であるか
をプログラムに通知するため、コンデイションコードの
設定、
の4つの処理からなる。プロセッサがテスト&セット命
令を実行している期間中は、他プロセッサからのロック
バイトへのアクセスを抑止するため、プロセッサとメモ
リを結合する該バスのロック信号をオンとして、該バス
を占有(ロック)し、他のプロセッサが該バスを使用で
きないようにする(参考二パコンピュータ・アーキテク
チャ 第2版”、村岡陽−、コンピュータ・サイエンス
大学講座11、pp137−139、近代科学社)。The test and set instruction is an instruction for checking whether the processor can use shared data. (1) Read access to the lock byte, (2) Determine whether the read lock byte is set or not. (3) Write access to memory to set the lock byte to “1” if it is On (if it is “1”, another processor has already used the shared data with the corresponding lock byte) (4) Setting a condition code to notify the program whether the lock byte is "O" or "Pa1". While the processor is executing the test & set instruction, the lock signal of the bus connecting the processor and memory is turned on to prevent other processors from accessing the lock byte, and the bus is occupied (locked). ), and prevents other processors from using the bus (Reference: "Nipah Computer Architecture 2nd Edition", Yo Muraoka, Computer Science University Course 11, pp137-139, Kindai Kagakusha).
処理■、共用データの使用可否の判断
コンデイションコードをチエツクし、ロックバイトが1
1011であった場合は処理■、ロックバイトが“1″
であった場合は処理■、に進む。Process ■, check the condition code to determine whether the shared data can be used, and check if the lock byte is 1.
If it is 1011, process ■, lock byte is “1”
If so, proceed to process ■.
処理■、共用データのリード メモリから共用データを読み込む。Processing■, Read shared data Read shared data from memory.
処理■、プロセッサ内焙処 理ロセッサによる読み込んだデータの処理。Processing ■, roasting process in the processor Processing of the read data by the processor.
処理■、共有データの書換え
プロセッサが処理したデータをメモリへ書き込むための
ライトアクセス(以後、STIと記す)。Processing (2): Rewriting shared data Write access to write data processed by the processor to memory (hereinafter referred to as STI).
処理■、ロックバイトのリセット
プロセッサがアクセスした共用データのロックバイトを
リセット(即ち“0”)するためのメモリライトアクセ
ス(以後、ST2と記す)。Process ①: Resetting the lock byte Memory write access (hereinafter referred to as ST2) to reset (to "0") the lock byte of the shared data accessed by the processor.
以上の順番に従って処理を実行することにより、複数プ
ロセッサ間で、共用データを用いた処理が矛盾なく行わ
れる。By executing the processes in the above order, processes using shared data can be performed consistently among multiple processors.
プロセッサの単位性能を向上させる一つの方法として、
メモリへのライトアクセスのおいてきぼり制御がある。One way to improve the unit performance of a processor is to
There is occasional control of write access to memory.
おいてきぼり制御とは、命令実行部(以下、CPUとい
う)がライトアクセスを実行する際、バス制御部が、そ
のライトアドレスとデータを内部の出力バッファに保持
し、CPUに対しては該アドレスとデータを受け取った
時点でライトアクセスの終了を通知するとともに、次の
命令の実行を促し、メモリへの書き込みはCPUの後続
命令の実行と並行して行うものである。この制御により
、CPUは、ライトアクセスの度にメモリへの書き込み
終了を待たされることなく、次の命令の実行を行うこと
ができるので、処理性能が向上する。Leave control means that when the instruction execution unit (hereinafter referred to as the CPU) executes a write access, the bus control unit holds the write address and data in an internal output buffer, and transmits the address and data to the CPU. When the CPU receives the instruction, it notifies the end of the write access and prompts the execution of the next instruction, and the writing to the memory is performed in parallel with the execution of the subsequent instruction by the CPU. This control allows the CPU to execute the next instruction without having to wait for the completion of writing to the memory each time a write access is made, thereby improving processing performance.
しかしながら、前記従来の複゛数のバスで結合されたマ
ルチプロセッサの場合、おいてきぼり制御を行うと、先
に述べた排他制御がうまく機能しないという問題がある
。However, in the case of the conventional multiprocessors connected by a plurality of buses, there is a problem in that the above-mentioned exclusive control does not work well when the predetermined control is performed.
以下、この問題について説明する。This problem will be explained below.
ここでは、前記問題点を分かりやすく説明するために、
2台のプロセッサと1台のメモリが、バスをロックする
ための機能(ロック信号)を持つ2本のバスで結合され
たマルチプロセッサ構成を想定する。各プロセッサは1
台のCPUとバス対応に2台のバス制御部とからなり、
バス制御部はおいてきぼり制御用の出力バッファを持つ
ものとする。メモリ上の1番地には共用データ、0番地
には共用データに対応するロックバイトが格納され、共
用データの値は“A−ロックバイトの値は“0”になっ
ているものとする、更に、メモリの偶数番地へのアクセ
スはバス0、奇数番地へのアクセスはバス1を経由して
行なわれるものとする。ここで想定するマルチプロセッ
サ構成の全体図を第3図に示す。Here, in order to explain the above problem in an easy-to-understand manner,
Assume a multiprocessor configuration in which two processors and one memory are connected by two buses that have a bus locking function (lock signal). Each processor has 1
Consists of one CPU and two bus control units for bus support.
It is assumed that the bus control unit has an output buffer for left-behind control. The shared data is stored at address 1 on the memory, and the lock byte corresponding to the shared data is stored at address 0, and the value of the shared data is assumed to be "A-the value of the lock byte is "0". It is assumed that access to even memory addresses is via bus 0, and access to odd addresses is via bus 1.An overall diagram of the multiprocessor configuration assumed here is shown in FIG.
第3図において、100はメモリ、#1.#2はプロセ
ッサである。プロセッサ#1はバス制御部10、11及
びCPU12からなっている。また、プロセッサ#2は
バス制御部20.21及びCPU22からなっている。In FIG. 3, 100 is a memory, #1. #2 is a processor. Processor #1 consists of bus control units 10 and 11 and a CPU 12. Further, processor #2 includes a bus control section 20.21 and a CPU 22.
バス制御部10は出力バッファIOAを有し、バス制御
部11は出力バッファIIAを有している。また、バス
制御部20は出力バッファ20Aを有し、バス制御部2
1は出力バッファ21Aを有している。The bus control section 10 has an output buffer IOA, and the bus control section 11 has an output buffer IIA. Further, the bus control unit 20 has an output buffer 20A, and the bus control unit 20 has an output buffer 20A.
1 has an output buffer 21A.
次に、前記のマルチプロセッサの構成における各プロセ
ッサ#1及び#2の動作について説明する。Next, the operation of each processor #1 and #2 in the multiprocessor configuration described above will be explained.
プロセッサ#2のCPU22は、バス0のロック信号を
オン状態にして、バス制御部20、バスOを経由して、
テスト&セット命令を実行し、メモリ100上の0番地
にあるロックバイトを“1”にセットする。ロックバイ
トをセットしたプロセッサ#2は、バスOのロック信号
をオフ状態にして。The CPU 22 of the processor #2 turns on the lock signal of the bus 0, and via the bus control unit 20 and the bus O,
Execute the test & set instruction and set the lock byte at address 0 on memory 100 to "1". Processor #2, which has set the lock byte, turns off the lock signal on bus O.
1番地にある共用データ(元データはAとする)に対す
るアクセス権を獲得する。Obtain access rights to the shared data at address 1 (original data is A).
プロセッサ#2のCPU22は、バス制御部21、バス
1を介して、メモリ100上の1番地にある共用データ
に対してリードアクセスを行い、CPU22内で処理を
行う。The CPU 22 of the processor #2 performs read access to the shared data at address 1 on the memory 100 via the bus control unit 21 and the bus 1, and performs processing within the CPU 22.
次に、プロセッサ#2のCPU22は、処理した共用デ
ータ(新データはBとする)をメモリ100上の1番地
に書き込む(STI)ため、ライトアドレスと書換えデ
ータ(アドレスは1.データはBである)をバス制御部
21の出力バッファ21Aに送る。Next, the CPU 22 of processor #2 writes the processed shared data (new data is B) to address 1 on the memory 100 (STI), so the CPU 22 uses a write address and rewrite data (address is 1. Data is B). ) is sent to the output buffer 21A of the bus control section 21.
バス制御部21は、STIを出力バッファ21Aに格納
し、CPU22に対してライトアクセスの終了を通知す
る。The bus control unit 21 stores the STI in the output buffer 21A, and notifies the CPU 22 of the end of the write access.
続いて、プロセッサ#2のCPU22は、メモリ100
上の0番地にある口、ツクバイトをリセット(Sr1)
するため、ライトアドレスと、データ(アドレスはO,
データはOである)をバス制御部20に送る。Subsequently, the CPU 22 of processor #2 uses the memory 100
Reset the mouth at address 0 above (Sr1)
In order to do this, write address and data (address is O,
The data is O) is sent to the bus control unit 20.
バス制御部20はSr1を出力バッファ20Aに格納し
、CPU22に対してライトアクセスの終了を通知する
。The bus control unit 20 stores Sr1 in the output buffer 20A, and notifies the CPU 22 of the end of the write access.
次に、プロセッサ#2のバス制御部20は、バス0のバ
ス権を獲得し、出力バッファ2OAに格納されているS
r1をバスOを経由してメモリ100に送出して、メモ
リ100上の0番地のロックバイトを“1”から3′0
”にリセットする。この時、たまたま、バス1がプロセ
ッサ#1または図に示していないが入出力チャネルによ
って使用されており、バス制御部21はバス1を獲得で
きず、′sT1はバス制御部21の出力バッファに保留
されたままになっている。Next, the bus control unit 20 of the processor #2 acquires the bus right to the bus 0, and the S
Send r1 to memory 100 via bus O, and change the lock byte at address 0 on memory 100 from "1" to 3'0.
”. At this time, by chance, bus 1 is being used by processor #1 or an input/output channel (not shown in the figure), bus controller 21 cannot acquire bus 1, and 'sT1 is being used by bus controller 21. 21 remains pending in the output buffer.
今度は、プロセッサ#1のCPU12は、バス0のロッ
ク信号をオン状態にして、バス制御部1o、バスOを経
由して、テスト&セット命令を実行し、メモリ上の0番
地にあるロックバイトを“1″にセットする。ロックバ
イトをセットしたプロセッサ#1は、バス0のロック信
号をオフ状態にして、1番地にある共用データに対する
アクセス権を獲得する。This time, the CPU 12 of processor #1 turns on the lock signal of bus 0, executes the test & set instruction via the bus control unit 1o and bus O, and sets the lock byte at address 0 on the memory. is set to “1”. Processor #1, which has set the lock byte, turns off the lock signal of bus 0 and acquires the right to access the shared data at address 1.
この時、プロセッサ#2のバス制御部21の出力バッフ
ァにあるSTI (アドレスは1.データはBである)
は依然として保留状態にあるとする。At this time, the STI in the output buffer of the bus control unit 21 of processor #2 (address is 1. data is B)
is still on hold.
次に、プロセッサ#1のCPU12は、メモリ100上
の1番地にある共用データに対してリードアクセスをバ
ス制御部11に要求する。Next, the CPU 12 of the processor #1 requests the bus control unit 11 to read access to the shared data at address 1 on the memory 100.
バス制御部11は1番地のリードアクセス、バス制御部
21は1番地へのライトアクセス(STI)のため、バ
ス1を獲得しようとし1図には示していないがバス使用
権割当回路によってバス制御部11にバスの使用権が与
えられたとする。バス制御部11は、STIが行われる
以前の旧データ(A)を読み出し、プロセッサ#1のC
PU12に与える。Bus control unit 11 attempts to acquire bus 1 for read access to address 1 and bus control unit 21 for write access (STI) to address 1. Although not shown in Figure 1, the bus control unit 21 attempts to acquire bus 1 by using a bus right allocation circuit. Assume that section 11 is given the right to use the bus. The bus control unit 11 reads old data (A) before STI was performed, and reads the old data (A) from the processor #1.
Give to PU12.
以後、プロセッサ#1は、書き換えられる以前の旧デー
タを用いて処理を継続することになり、処理の矛盾が発
生する。Thereafter, processor #1 will continue processing using the old data before being rewritten, resulting in processing inconsistency.
複数本のバス及びおいてきぼり制御を行うプロセッサか
ら構成されるマルチプロセッサにおいては、上記の矛盾
が発生する。このため、従来のマルチプロセッサの構成
方法として、バス制御部に出力バッファを設けずライト
アクセスのおいてきぼり制御を行わない方法またはバス
を1本にする方法などが採られていた。The above-mentioned contradiction occurs in a multiprocessor that includes a plurality of buses and processors that perform left-behind control. For this reason, conventional methods for configuring a multiprocessor include a method in which no output buffer is provided in the bus control unit and control of write access is not performed in advance, or a method in which only one bus is used.
前者の方法は、メモリへのライトアクセス(STl)が
メモリ上で実行されて、終了するまでは次のメモリアク
セス(S T 2)を実行させないことで、処理の矛盾
を起こさせない方法である。しかし、この項目の前半で
説明したように、おいてきぼり制御を行わないため、プ
ロセッサの単体性能が向上しないという問題があった。The former method prevents processing inconsistency by not allowing the next memory access (S T 2) to be executed until the memory write access (STl) is executed on the memory and completed. However, as explained in the first half of this article, there was a problem in that the performance of the processor alone was not improved because it did not perform left-behind control.
後者の方法は、バスを1本にすることによりメモリへの
ライトアクセスSTIとSr1がバスでシリアライズさ
れ、Sr1がSTIを追い越してメモリに反映されるこ
とがないため、前述の問題は発生しない。しかし、この
方法では、プロセッサ台数の増加に伴って、バス競合が
増し、それによる処理性能が飽和するという問題があっ
た。In the latter method, by using one bus, write access STI and Sr1 to the memory are serialized on the bus, and Sr1 does not overtake STI and is reflected in the memory, so the above-mentioned problem does not occur. However, this method has a problem in that bus contention increases as the number of processors increases, resulting in saturation of processing performance.
本発明は、前記問題点を解決するためになされたもので
ある。The present invention has been made to solve the above problems.
本発明の目的は、複数本のバスを持ち、かつ、おいてき
ぼり制御を行うプロセッサから構成されるマルチプロセ
ッサに適したバス制御方式を提供することにある。SUMMARY OF THE INVENTION An object of the present invention is to provide a bus control method suitable for a multiprocessor that has a plurality of buses and is configured of processors that perform selective control.
本発明の前記ならびにその他の目的と新規な特徴は、本
明細書の記述及び添付図面によって明らかになるであろ
う。The above and other objects and novel features of the present invention will become apparent from the description of this specification and the accompanying drawings.
前記目的を達成するために、本発明のバス制御方式は、
メモリへのライトアクセスに有効なおいてきぼり制御を
可能とする出力バッファを持つ複数台のプロセッサとメ
モリとが、複数のプロセッサからのメモリアクセスの排
他制御を行うためのロック信号を有する複数本のバスで
結合されたマルチプロセッサの構成において、所定のプ
ロセッサのCPUが所定のバス制御部及びバスを経由し
ロック信号をオンとしたリードアクセスを発出した場合
、他のプロセッサの所定のバス以外に接続された全ての
バス制御部は該ロック信号を検出し、出力バッファにメ
モリへのライトアクセスが存在しないときは出力バッフ
ァが空である旨を、一方、出力バッファにメモリへのラ
イトアクセスが存在するときは、該ライトアクセスをメ
モリに対して行った後、出力バッファが空になった旨を
ロック信号をオンとしたリードアクセスを発出したバス
制御部に通知し、該バス制御部は他のプロセッサの所定
バス以外に接続された全てのバス制御部からの該通知を
受け取った後、メモリから読み出したデータをCPUに
送ることを最も主要な特徴とする。In order to achieve the above object, the bus control method of the present invention includes:
Multiple processors with output buffers that enable effective left-handed control of write access to memory and memory are connected to multiple buses with lock signals for exclusive control of memory access from multiple processors. In a combined multiprocessor configuration, if the CPU of a predetermined processor issues a read access with the lock signal turned on via a predetermined bus control unit and bus, the CPU of a predetermined processor is connected to a bus other than the predetermined bus of another processor. All bus controllers detect this lock signal and indicate that the output buffer is empty when there is no write access to memory in the output buffer, while indicating that the output buffer is empty when there is a write access to memory in the output buffer. , after performing the write access to the memory, notifies the bus control unit that issued the read access with the lock signal turned on that the output buffer is empty, and the bus control unit The most important feature is that the data read from the memory is sent to the CPU after receiving the notification from all the bus control units connected to the bus other than the bus.
前述の手段によれば、所定のCPUが所定のバス制御部
及びバスを経由しロック信号をオンとしたリードアクセ
スを発出した場合、他プロセッサの所定のバス以外に接
続された全てのバス制御部は、該ロック信号を検出し、
出力バッファにメモリへのライトアクセスが存在しない
ときは出力バッファが空である旨を、一方、出力バッフ
ァにメモリへのライトアクセスが存在するときは、該ラ
イトアクセスをメモリに対して行った後、出力バッファ
が空になった旨をロック信号をオンとしたリードアクセ
スを発出したバス制御部に通知し、該バス制御部は他プ
ロセッサの前記所定のバス以外に接続された全てのバス
制御部からの該通知を受け取った後、メモリから読み出
したデータをCPUに送るので、複数本のバスを持ち、
かつ、おいてきぼり制御を行うプロセッサから構成され
るマルチプロセッサに適したバス制御方式を実現するこ
とができる。According to the above-mentioned means, when a predetermined CPU issues a read access with a lock signal turned on via a predetermined bus control unit and bus, all bus control units connected to other processors other than the predetermined bus detects the lock signal,
When there is no write access to memory in the output buffer, the output buffer is empty; on the other hand, when there is a write access to memory in the output buffer, after performing the write access to memory, The bus control unit that issued the read access with the lock signal turned on is notified that the output buffer is empty, and the bus control unit receives notification from all bus control units connected to other processors other than the predetermined bus. After receiving the notification, the data read from memory is sent to the CPU, so it has multiple buses.
Furthermore, it is possible to realize a bus control method suitable for a multiprocessor configured of processors that perform left-behind control.
すなわち1本発明のバス制御方式は、従来の技術とは、
ロック信号をオンとしたバス以外に接続された全てのバ
ス制御部が該ロック信号を検出するための信号線とバス
制御部の出力バッファにメモリへのライトアクセスが存
在するか否かをロック信号をオンにしたバス制御部に通
知するための信号線を有する点が異なる。In other words, the bus control method of the present invention is different from the conventional technology as follows.
All bus control units connected to the bus other than the one on which the lock signal is turned on use the lock signal to detect whether or not there is a write access to memory on the signal line for detecting the lock signal and the output buffer of the bus control unit. The difference is that it has a signal line for notifying the bus control unit that the bus has been turned on.
以下、本発明の一実施例を図面を用いて具体的に説明す
る。Hereinafter, one embodiment of the present invention will be specifically described using the drawings.
第1図は、本発明を複数本のバスを持ち、かつ、おいて
きぼり制御を行うプロセッサから構成されるマルチプロ
セッサに適用した一実施例のバス制御方式を説明するた
めのマルチプロセッサの構成を示すブロック図である。FIG. 1 is a block diagram showing the configuration of a multiprocessor for explaining a bus control method according to an embodiment in which the present invention is applied to a multiprocessor that has a plurality of buses and is composed of processors that perform leftover control. It is a diagram.
第1図において、100は共用データとそのデータに対
するアクセスの有無を示すロックバイトを持つメモリ、
101.103はバス、102.104はバス制御部の
出力バッファがメモリへのライトアクセスを持っている
か否かを通知する信号線、105.106はロック信号
をオンとしたバス以外に接続されたバス制御部が該ロッ
ク信号を検出するための信号線、107.109.11
2.114はメモリ100へのアクセスを制御するため
のバス制御部、108.110.113゜115はおい
てきぼり制御を行うために必要なバス制御部の出力バッ
ファ、111.116は命令を実行するCPU (命令
実行部)である。In FIG. 1, 100 is a memory having shared data and a lock byte indicating whether or not the data is accessed;
101.103 is a bus, 102.104 is a signal line that notifies whether the output buffer of the bus control unit has write access to memory, and 105.106 is connected to a bus other than the bus with the lock signal turned on. Signal line for the bus control unit to detect the lock signal, 107.109.11
2.114 is a bus control unit for controlling access to the memory 100, 108.110.113° 115 is an output buffer of the bus control unit necessary for performing leftover control, and 111.116 is a CPU that executes instructions. (instruction execution unit).
本発明のバス制御方式を適用した場合、複数のプロセッ
サ間で行われる動作を分かりやすく説明するために、新
たに追加した2種類の信号線(102、104,105
,106)の部分を除いては、全体のブロック構成は第
3図のマルチプロセッサ構成と全く同じであるとする。When the bus control method of the present invention is applied, two types of newly added signal lines (102, 104, 105
, 106), the overall block configuration is assumed to be exactly the same as the multiprocessor configuration shown in FIG.
次に、前記マルチプロセッサの構成における各プロセッ
サの動作について説明する。Next, the operation of each processor in the multiprocessor configuration will be explained.
プロセッサ#2のCPU116は、バスOのロック信号
をオン状態にして、バス制御部112、バス101を経
由して、テスト&セット命令を実行し、メモリ上の0番
地にあるロックバイトを1”にセットする。ロックバイ
トをセットしたプロセッサ#2は、バス101のロック
信号をオフ状態にして、1番地にある共用データ(元デ
ータはAとする)に対するアクセス権を獲得する。The CPU 116 of the processor #2 turns on the lock signal of the bus O, executes the test & set instruction via the bus control unit 112 and the bus 101, and sets the lock byte at address 0 on the memory to 1''. Processor #2, which has set the lock byte, turns off the lock signal on bus 101 and acquires the right to access the shared data at address 1 (original data is A).
プロセッサ#2のc p U116は、バス制御部11
4、バス103を介して、メモリ100上の1番地にあ
る共用データに対してリードアクセスを行い、CPU1
16内で処理を行う。The cp U116 of the processor #2 is the bus control unit 11
4. Read access is made to the shared data at address 1 on the memory 100 via the bus 103, and the CPU 1
Processing is performed within 16.
次に、プロセッサ#2のCPU116は、処理した共用
データ(新データはBとする)をメモリ100上の1番
地の領域に書き込む(STI)ため、ライトアドレスと
書換えデータ(アドレスは1゜データはBである)をバ
ス制御部114に送る。Next, the CPU 116 of processor #2 writes the processed shared data (the new data is B) to the area at address 1 on the memory 100 (STI), so the CPU 116 of processor #2 writes the write address and the rewrite data (the address is 1° and the data is B) is sent to the bus control unit 114.
バス制御部114は、STIが出力バッファ115に格
納し、CPU116に対してライトアクセスの終了を通
知する。The bus control unit 114 stores the STI in the output buffer 115 and notifies the CPU 116 of the end of the write access.
続いて、プロセッサ#2のC:PU116は、メモリ1
00上の0番地のロックバイトをリセット(Sr1)す
るため、ライトアドレスとデータ(アドレスはO,デー
タは0である)をバス制御部112に送る。Subsequently, the C:PU 116 of processor #2
In order to reset the lock byte at address 0 on 00 (Sr1), the write address and data (address is O, data is 0) are sent to the bus control unit 112.
バス制御部112は、Sr1を出力バッファ113に格
納し、CP U116に対してライトアクセスの終了を
通知する。The bus control unit 112 stores Sr1 in the output buffer 113 and notifies the CPU 116 of the end of the write access.
次に、プロセッサ#2のバス制御部112は、バス0の
バス権を獲得し、出力バッファに格納されているSr1
をバス101を経由してメモリ100に送出して、0番
地のロックバイトを“1”からII OITにリセット
する。この時、たまたま、バス103がプロセッサ#1
または図に示していないが入出力制御チャネルによって
使用されており、バス制御部114はバス103を獲得
できず、STIはバス制御部114の出力バッファ11
5に保留されたままになっている。Next, the bus control unit 112 of processor #2 acquires the bus right to bus 0 and uses Sr1 stored in the output buffer.
is sent to the memory 100 via the bus 101, and the lock byte at address 0 is reset from "1" to II OIT. At this time, bus 103 happened to be connected to processor #1.
Or, although not shown in the figure, the bus 103 is used by the input/output control channel, the bus control unit 114 cannot acquire the bus 103, and the STI is used by the output buffer 11 of the bus control unit 114.
5 remains pending.
第1図は、マルチプロセッサが前述した状態にあること
を図示したものである。FIG. 1 illustrates the multiprocessor in the state described above.
マルチプロセッサが第1図の状態にあるものとして、プ
ロセッサ#1のCP Ulllは、テスト&セット命令
の実行のため、メモリ100上の0番地のロックバイト
のリード要求をバス制御部107に出す。バス制御部1
07はバス101のバス権を獲得して、バス101のロ
ック信号をオンとし、メモリ100上のO番地のリード
要求を出す。Assuming that the multiprocessor is in the state shown in FIG. 1, CP Ull of processor #1 issues a read request for the lock byte at address 0 on memory 100 to bus control unit 107 in order to execute a test & set instruction. Bus control section 1
07 acquires the bus right to the bus 101, turns on the lock signal of the bus 101, and issues a read request for address O on the memory 100.
この時、プロセッサ#2のバス制御部114は、バス1
01のロック信号がオン状態になっていることを信号線
105を通じて検出する。At this time, the bus control unit 114 of processor #2
It is detected through the signal line 105 that the lock signal 01 is in the on state.
バス制御部114は、その検出を受けて、出力バッファ
115に保留されている共用データを書き換えるための
ライトアドレスとデータ(STIニアドレスは1.デー
タはBである)をバス103を経由してメモ官月00に
対して送出し、メモ1月00上の1番地にある共用デー
タを“A”から“B ITに書き換える。In response to this detection, the bus control unit 114 sends a write address and data (STI near address is 1, data is B) to rewrite the shared data held in the output buffer 115 via the bus 103. Send to memo official month 00 and rewrite the shared data at address 1 on memo January 00 from "A" to "B IT".
プロセッサ#2のライトアクセスが終了すると、バス制
御部114の出力バッファ115は空になっているので
、バス制御部114はその旨を信号線104を通じてバ
ス制御部107に報告する。When the write access by processor #2 is completed, the output buffer 115 of the bus control unit 114 is empty, so the bus control unit 114 reports this to the bus control unit 107 via the signal line 104.
プロセッサ#1のバス制御部107は、メモリ100か
らロックバイトをリードした後、前記の報告をCP U
lllに送る。CP Ulllは、ロックバイトがOの
ため、共用データに対するアクセス権を獲得し、ロック
バイトを1にするライトアクセスをバス制御部107に
送る。バス制御部107は、該ライトアクセスを出力バ
ッファ108に格納し、CP Ulllに対しライトア
クセスの終了を通知する。After reading the lock byte from the memory 100, the bus control unit 107 of processor #1 sends the above report to the CPU
Send to lll. Since the lock byte is O, CP Ull acquires the access right to the shared data and sends a write access to set the lock byte to 1 to the bus control unit 107. The bus control unit 107 stores the write access in the output buffer 108 and notifies the CPU Ull of the end of the write access.
次に、CP Ulllは、共用データの読み出しに移る
が、この時、共用データは′B″に書き換えられており
、以後矛盾なくに処理が行われる。Next, CP Ull moves on to reading the shared data, but at this time, the shared data has been rewritten to 'B', and henceforth processing is performed without any contradiction.
以上、本発明を実施例にもとづき具体的に説明したが、
本発明は、前記実施例に限定されるものではなく、その
要旨を逸脱しない範囲において種々変更可能であること
は言うまでもない。The present invention has been specifically explained above based on examples, but
It goes without saying that the present invention is not limited to the embodiments described above, and can be modified in various ways without departing from the spirit thereof.
以上、説明したように、本発明によれば、おいてきぼり
ライト制御を行うプロセッサを複数本のバスで結合した
マルチプロセッサ構成を採ることが可能となり、システ
ムの高性能化が図れる。As described above, according to the present invention, it is possible to adopt a multiprocessor configuration in which processors that perform leftover write control are connected via a plurality of buses, and the performance of the system can be improved.
第1図は1本発明を複数本のバスを持ち、かつ、おいて
きぼり制御を行うプロセッサから構成されるマルチプロ
セッサに適用した一実施例のバス制御方式を説明するた
めのマルチプロセッサの構成を示すブロック図、
第2図は、プロセッサが行うメモリへのライトアクセス
の排他制御の動作フローチャート、第3図は、従来の複
数本のバスを持つマルチプロセッサの動作を説明するた
めの図である。
図中、100・メモリ、101.103・・・バス、1
02.104・・・信号線、105.106・・・信号
線、107.109.112゜114・・・バス制御部
、108.110.113.115・・・出力バッファ
、111.116・・・CPU。FIG. 1 is a block diagram showing the configuration of a multiprocessor for explaining a bus control system according to an embodiment in which the present invention is applied to a multiprocessor that has a plurality of buses and is composed of processors that perform leftover control. FIG. 2 is an operation flowchart of exclusive control of write access to memory performed by a processor, and FIG. 3 is a diagram for explaining the operation of a conventional multiprocessor having a plurality of buses. In the figure, 100, memory, 101, 103, bus, 1
02.104...Signal line, 105.106...Signal line, 107.109.112゜114...Bus control unit, 108.110.113.115...Output buffer, 111.116...・CPU.
Claims (1)
続され、各プロセッサは命令実行部とメモリへのアクセ
スを制御するためバス対応に設けられた複数のバス制御
部とから構成され、命令実行部からのメモリアクセスは
アドレスによりどのバス制御部を経由して行なうか、あ
らかじめ決められた規則に従って一義的に決定され、各
バスは複数のプロセッサからのメモリアクセスの排他制
御用のロック信号を有し、該ロック信号がオンの間は他
プロセッサからのメモリアクセスができないようになっ
ており、前記バス制御部は出力バッファを有し、命令実
行部からのライトアクセスに対しアドレスとデータを出
力バッファに格納すると命令実行部に対しライトアクセ
スの終了を通知し、バスが獲得できた時点でメモリに対
しライトアドレスとデータを送るように構成されたマル
チプロセッサのバス制御方式において、所定の命令実行
部が所定のバス制御部及びバスを経由しロック信号をオ
ンとしたリードアクセスを発出した場合、他プロセッサ
の所定のバス以外に接続された全てのバス制御部は、該
ロック信号を検出し、出力バッファにメモリへのライト
アクセスが存在しないときは出力バッファが空である旨
を、一方、出力バッファにメモリへのライトアクセスが
存在するときは、該ライトアクセスをメモリに対して行
なった後、出力バッファが空になった旨をロック信号を
オンとしたリードアクセスを発出したバス制御部に通知
し、該バス制御部は他プロセッサの前記所定のバス以外
に接続された全てのバス制御部からの該通知を受け取っ
た後、メモリから読み出したデータを命令実行部に送る
ことを特徴とするバス制御方式。(1) Multiple processors and memories are connected by multiple buses, and each processor is composed of an instruction execution unit and multiple bus control units provided corresponding to the buses to control access to the memory. Memory access from the execution unit is performed via an address, which is uniquely determined according to predetermined rules, and each bus receives a lock signal for exclusive control of memory access from multiple processors. The bus control unit has an output buffer and outputs addresses and data in response to write access from the instruction execution unit. In a multiprocessor bus control system configured to notify the instruction execution unit of the end of write access when stored in the buffer, and send the write address and data to the memory when the bus is acquired, a predetermined instruction is executed. When a processor issues a read access with a lock signal turned on via a predetermined bus controller and bus, all bus controllers connected to other processors other than the predetermined bus detect the lock signal, When there is no write access to memory in the output buffer, the output buffer is empty; on the other hand, when there is a write access to memory in the output buffer, after the write access to memory is performed, The bus control unit that issued the read access with the lock signal turned on is notified that the output buffer is empty, and the bus control unit receives notification from all bus control units connected to other processors other than the predetermined bus. A bus control method characterized in that after receiving the notification, data read from memory is sent to an instruction execution unit.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2644890A JP2825589B2 (en) | 1990-02-05 | 1990-02-05 | Bus control method |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2644890A JP2825589B2 (en) | 1990-02-05 | 1990-02-05 | Bus control method |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JPH03230251A true JPH03230251A (en) | 1991-10-14 |
| JP2825589B2 JP2825589B2 (en) | 1998-11-18 |
Family
ID=12193786
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2644890A Expired - Fee Related JP2825589B2 (en) | 1990-02-05 | 1990-02-05 | Bus control method |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP2825589B2 (en) |
-
1990
- 1990-02-05 JP JP2644890A patent/JP2825589B2/en not_active Expired - Fee Related
Also Published As
| Publication number | Publication date |
|---|---|
| JP2825589B2 (en) | 1998-11-18 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| EP0443557A2 (en) | Interrupt controller capable of realizing interrupt nesting function | |
| JP4874165B2 (en) | Multiprocessor system and access right setting method in multiprocessor system | |
| US6839811B2 (en) | Semaphore management circuit | |
| US10628352B2 (en) | Heterogeneous multi-processor device and method of enabling coherent data access within a heterogeneous multi-processor device | |
| US4864533A (en) | Data transfer control unit permitting data access to memory prior to completion of data transfer | |
| JPH03230251A (en) | Bus control system | |
| JPH0355657A (en) | Shared memory access method for multi-task/multi-processor system | |
| JPH01125633A (en) | System for debugging multi-processing system | |
| JP4818820B2 (en) | Bus system, bus slave and bus control method | |
| JPH04140860A (en) | Method for controlling bus of multi-processor | |
| CN109358903A (en) | Data Access Device and Access Error Notification Method | |
| JP2679440B2 (en) | Information processing device | |
| JP3130798B2 (en) | Bus transfer device | |
| JP3219422B2 (en) | Cache memory control method | |
| JPS5834856B2 (en) | Kiokuseigiyosouchi | |
| JPS62184564A (en) | Electronic computer control system | |
| JPH0528090A (en) | Memory controller | |
| JPH07111711B2 (en) | Processing end interrupt control system | |
| JPH08328997A (en) | Local bus access method and bus adapter | |
| JPH01310466A (en) | Multiprocessor system | |
| JPH058459B2 (en) | ||
| JPS62229457A (en) | Data transfer controller | |
| JPH01300365A (en) | Exclusive control system for multi-processor system | |
| JPH04305746A (en) | Cache memory control device | |
| JPH04330549A (en) | Controller |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| LAPS | Cancellation because of no payment of annual fees |