Multiprocessor system and consistency maintaining method for data for the same
Abstract
[Task] Reduce load access latency and prevent message growth in loosely coupled multiprocessor systems.
Solution.It is a multiprocessor system composed of a plurality of nodes PE0 to PEn-1 connected to each other via an interconnect network, and each of the plurality of nodes PE0 to PEn-1 has a main memory 30 in which data is stored and a main memory 30. A cache memory 21 that stores a part of the data stored in the main memory 30 provided by any of the plurality of nodes PE0 to PEn-1 and can be accessed at a higher speed than the main memory 30, and a data access request. The issuing processor 20 and the state of the data stored in the main memory 30 and a copy of the data are held in the cache memory 21 and the node information is stored, and the processor 20 loads and stores the data at a predetermined address. When an access is made, the consistency maintenance control unit 16 that checks whether a valid copy of the data at the corresponding address exists in the cache memory 21 is provided, and the latency of the load access can be shortened.

Term
Term ended
Projected expiry passed 9 March 2019, 7.5 years ago.
- Priority and filed
- Published
- Projected expiry
- Today
11 claims: 2 independent, 9 dependent
- 1【特許請求の範囲】 【請求項1】 相互結合網を介して互いに接続された複数のノードから構成される マルチプロセッサシステムであって、 前記複数のノードはそれぞれデータが格納される主メモリと、 前記複数のノードのいずれかが備える主メモリに格納されているデータの一部が記憶される、前記主メモリよりも高速アクセスが可能なキャッシュメモリと、 データのアクセス要求を発行するプロセッサと、 前記主メモリのデータがシステム内でどういう状態にあるのか管理し、前記キャッシュメモリにあるデータのコピーの状態を管理し、前記プロセッサが所定のアドレスのデータに対してロードおよびストアアクセスを行ったとき、メモリアクセスに応じてノードPEi間でメッセージをやり取りし、それらの状態を変更したりデータの転送を行う機能を有する一貫性維持制御部と、を有し、前記一貫性維持制御部は、 前記キャッシュメモリに記憶されているデータの状態が記憶されるタグメモリと、 前記主メモリに記憶されているデータの状態が記憶されるディレクトリメモリと、 前記プロセッサからのアクセス要求、前記複数のノードが備えるホームアクセス制御部が発行する要求や応答を受け、前記キャッシュメモリやタグメモリに対しては一貫性維持のために必要な処理を行い、前記プロセッサに対してはアクセス要求に対する応答を行うローカルアクセス制御部と、 前記複数のノードが備える前記ローカルアクセス制御部が発行する要求や応答を受けて、前記主メモリやディレクトリメモリに対して一貫性維持のために必要な処理を行い、前記ローカルアクセス制御部に要求や応答を発行するホームアクセス制御部と、 前記プロセッサが同時に発行可能なメモリアクセスの最大数に対応するエントリを有するリクエスト管理テーブルと、 共有しているブロックに対して書き込みを行い前記キャッシュメモリに専有することになったブロックを記憶する書き戻しブロック選択手段と、を具備することを特徴とするマルチプロセッサシステム。
- 2【請求項2】 請求項1に記載のマルチプロセッサシステムにおいて、 前記書き戻しブロック選択手段は、前記ローカルアクセス手段が指定するアドレスを登録するアドレス登録手段と、 前記アドレス登録手段により登録されたアドレスを複数保持するアドレス保持手段と、 前記アドレス保持手段に格納された複数のアドレスから一つを選択して前記ローカルアクセス制御部に出力し、データの書き戻しを要求する書き戻し要求手段と、 前記ローカルアクセス制御部の指示に従い、前記書き戻し要求手段が選択しているエントリを削除するアドレス削除手段と、を具備することを特徴とするマルチプロセッサシステム。
- 3【請求項3】 請求項1に記載のマルチプロセッサシステムにおいて、 前記ローカルアクセス制御部は、前記書き戻しブロック選択手段に記憶されたブロックを前記キャッシュメモリから読み出し、データに書き戻し要求を前記ホームアクセス制御部に発行し、前記ローカルアクセス制御部が発行するデータの書き戻し要求を受けて前記主メモリにデータを書き戻すことを特徴とするマルチプロセッサシステム。
- 4【請求項4】 請求項3に記載のマルチプロセッサシステムにおいて、 前記ローカルアクセス制御部は、前記プロセッサへのデータの書き込み要求アクセスを受けて書き込み要求を前記ホームアクセス制御部に発行し、該書き込み要求を受けて、データを複数のノードが共有しているかどうかを示す前記ディレクトリメモリに保持されているデータの状態からデータが共有状態にあるのかどうかを判断し、その判断結果を前記ローカルアクセス制御部に発行する応答に付加して該ローカルアクセス制御部に応答を返し、その応答を受け前記ローカルアクセス制御部が前記複数のノードが共有状態にあるのかどうかの情報を元に、前記書き戻しブロック選択手段にブロックへの登録の有無を決定することを特徴とするマルチプロセッサシステム。
- 5【請求項5】 請求項4に記載のマルチプロセッサシステムにおいて、 前記ホームアクセス制御部は、許容する書き戻し回数を制限する閾値を有し、前記ローカルアクセス制御部から書き込み要求を受けたときに、それらの情報を元に実際にブロックを共有しているかどうかを判断することを特徴とするマルチプロセッサシステム。
- 6【請求項6】 請求項5に記載のマルチプロセッサシステムにおいて、 前記ホームアクセス制御部は、許容する書き戻し回数を制限する閾値を有し、前記ローカルアクセス制御部から書き込み要求を受けたときに、前記閾値と前記ディレクトリメモリに保持されている情報を元に実際にブロックが共有状態にあるかどうかを判断することを特徴とするマルチプロセッサシステム。
- 7【請求項7】 請求項6に記載のマルチプロセッサシステムにおいて、 前記ディレクトリメモリは、書き戻しを受けた回数およびデータが共有状態にあっても実際にブロックを保持するノードが一つの場合は そのノードを特定することができる情報を有していることを特徴とするマルチプロセッサシステム。
- 8【請求項8】 相互結合網を介して互いに接続された複数のノードから構成される マルチプロセッサシステムであって、前記複数のノードはそれぞれ、データが格納される主メモリと、 前記複数のノードのいずれかが備える主メモリに格納されているデータの一部が記憶される、前記主メモリよりも高速アクセスが可能な キャッシュメモリと、 データのアクセス要求を発行するプロセッサと、 前記主メモリ内のデータがシステム内でどういう状態にあるのか判断し、前記キャッシュメモリにあるデータのコピーの状態を管理し、前記プロセッサが所定のアドレスのデータに対してロードおよびストアアクセスを行ったとき、メモリアクセスに応じて、ノードPEi間でメッセージをやり取りし、それらの状態を変更したりデータの転送を行う機能を有する一貫性維持制御部と、を有し、前記一貫性維持制御部は、 前記キャッシュメモリに記憶されているデータの状態が記憶されるタグメモリと、 前記プロセッサからのアクセス要求、前記複数のノードが備えるホームアクセス制御部が発行する要求や応答を受け、前記キャッシュメモリやタグメモリに対しては一貫性維持のために必要な処理を行い、前記プロセッサに対してはアクセス要求に対する応答を行うローカルアクセス制御部と、 前記複数のノードが備える前記ローカルアクセス制御部が発行する要求や応答を受けて、前記主メモリやディレクトリメモリに対して一貫性維持のために必要な処理を行い、前記ローカルアクセス制御部に要求や応答を発行するホームアクセス制御部と、 前記プロセッサが同時に発行可能なメモリアクセスの最大数に対応するエントリを有するリクエスト管理テーブルと、 共有しているブロックに対して書き込みを行い前記キャッシュメモリに専有することになったブロックを記憶する書き戻しブロック選択手段と、を具備することを特徴とするマルチプロセッサシステム。
- 9【請求項9】 請求項1または8に記載のマルチプロセッサシステムにおいて、 前記一貫性維持制御部に含まれるローカルアクセス制御部とホームアクセス制御部は、前記プロセッサが前記主メモリに格納された処理プログラムを実行することにより実現されることを特徴とするマルチプロセッサシステム。
- 10【請求項10】 請求項1または8に記載のマルチプロセッサシステムにおいて、 前記一貫性維持制御部に含まれるローカルアクセス制御部とホームアクセス制御部は、前記プロセッサとは別に設けられた専用のサブプロセッサが、前記主メモリに格納されたプログラムを実行することにより実現されることを特徴とするマルチプロセッサシステム。
- 11【請求項11】 請求項1または8に記載のマルチプロセッサシステムにおいて、 前記一貫性維持制御部に含まれるローカルアクセス制御部とホームアクセス制御部は、それぞれモジュールの機能を実現するための専用のロジックに従って構成された専用のハードウェアを装備していることを特徴とするマルチプロセッサシステム。
Independent claims11
774 paragraphs in 1 section, as filed
Description: TECHNICAL FIELD [Detailed description of the invention]
【0001】
[Technical field to which the invention belongs]
The present invention relates to loosely coupled multiprocessor systems, and particularly data consistency in multiprocessor systems and multiprocessor systems that maintain data coherency between main memory and cache memory in such multiprocessor systems. Regarding sexual maintenance methods.
【0002】
[Conventional technology]
Techniques for maintaining data consistency between cache memory and main memory in traditional loosely coupled multiprocessor systems are described in "The Directory-Based Cache Coherence Protocol for the DASH Multiprocessor", Daniel Lenoski, James Laudon, It is disclosed in Kourosh Gharachorloo, Anoop Gupta and John Hennessy, In Proceedings of 17th International Symposium on Computer Architecture, p148-159, 1990).
【0003】
A loose coupling is a coupling having a small coupling coefficient. On the other hand, a bond having a large bond coefficient is called a tight bond.
【0004】
FIG. 15 is a block diagram showing the configuration of such a conventional multiprocessor system 1'.
【0005】
As shown in FIG. 15, this multiprocessor system 1'composed of a plurality of nodes PE0 to PEn-1 and an interconnect network 10'that connects each node.
【0006】
Each node (only PEi is shown in FIG. 15) has a processor 20'that performs operations, memory access, etc., a main memory 30'that holds data, and a main memory 30 that the processor 20'holds data temporarily. Consistency maintenance control unit for maintaining data consistency between cache memory 21'which can be accessed faster than'and main memory 30'and cache memory 21'(including those of other nodes) It has 55'and.
【0007】
FIG. 16A is a diagram showing a state in which a copy of data exists in the main memory 30'of a plurality of nodes, and FIG. 16B is a diagram showing a state in which a copy of data exists only in the main memory 30'of one node. It is a figure which shows the existence state.
【0008】
The consistency maintenance control unit 55'holds the contents of the cache memory 21', and the cache memory 21'holds the state of the data stored in the main memory 30' and a copy of the data in the cache memory 21'. Holds the information of the node (hereinafter referred to as the holding node information). There are two data states, "C" and "M". As shown in FIG. 16A, C represents a state in which a copy of data exists in the cache memory 21'of a plurality of nodes. At this time, the copy of the cache memory 21'and the data value of the main memory 30' are the same. M represents a state in which only the cache memory 21'of one node holds a copy of data, as shown in FIG. 16 (b). At this time, the copy value of the cache memory 21'and the data value of the main memory 30'are different, and the copy value of the cache memory 21'is the latest value.
【0009】
FIG. 17 (a) shows a state in which there is no consistent and valid data in the cache memory 21'of a plurality of nodes, and FIG. 17 (b) shows a valid copy of the data. , And the cache memory 21'of other nodes may also have valid data, FIG. 17 (c) shows that a valid copy of the data exists in only one node. It is a figure which shows the state that a valid copy does not exist in the cache memory 21'of another node, and the data of the main memory 30' and the data of the cache memory 21' are different.
【0010】
The consistency maintenance control unit 55'holds the state of the data stored in the cache memory 21' and the tag address of the data. There are three data states, "I", "S", and "D". I is a state in which there is no consistent and valid copy of the data, as shown in FIG. 17 (a). S is a state in which a valid copy of the data exists and there is a possibility that a valid copy also exists in the cache memory 21'of another node, as shown in FIG. 17 (b). As shown in FIG. 17 (c), "D" has a valid copy of data in the cache memory 21'of multiple nodes in only one node and is valid in the cache memory 21'of the other node. There is no copy, and the value is different from the value of the data in the main memory 30'.
【0011】
Here, the tag address indicates which address the data is.
【0012】
The interconnect network 10'is a network that delivers messages exchanged between nodes.
【0013】
Hereinafter, in order to maintain data consistency between the main memory 30'and the cache memory 21' in this multiprocessor system 1'when the processor 20'loads or stores access to the data at a predetermined address. The operation of the above will be described with reference to FIG.
【0014】
First, the operation when the processor 20'of node PE1 makes load access will be described.
【0015】
The consistency maintenance control unit 55'checks whether a valid copy of the data at the corresponding address also exists in the cache memory 21'. If there is a valid copy in the cache memory 21', that is, if the state is "S" or "D", the consistency control unit 55'passes the data read from the cache memory 21'to the processor 50'. By doing so, it responds to the processor and terminates processing.
【0016】
On the other hand, if there is no valid copy in the cache memory 21', that is, if the status is "I", a read request message for the data is sent to the node holding the data at the corresponding address, for example, node PEh. Is transmitted via the interconnect network 10'.
【0017】
The consistency maintenance control unit 55'of the node PEh that received the read request message checks whether the latest value for the data of the corresponding address exists in the main memory 30'of the node PEh. If the latest value for the data at the corresponding address exists in main memory 30', that is, if the state is "C", it is stored in node PE1 via interconnect network 10'in main memory 30'. The current data is transmitted via the interconnect network 10', and node PE1 is added to the holding node information.
【0018】
The consistency maintenance control unit 55'of the node PE1 that has received the data from the node PEh passes the received data to the processor 20' and copies the data to the cache memory 21'. Further, the state of the data in the cache memory 21'is set to "S".
【0019】
On the other hand, in the node PEh that received the read request message, if the latest value for the data at the corresponding address does not exist in the main memory 30', that is, if the state is "M", the holding node information is referred to. Then, a read request message is sent to the node holding the latest data, for example, the node PEr, via the interconnect network 10'.
【0020】
The consistency maintenance control unit 55'of the node PEr that received the read request message checks whether or not the data of the state "D" exists in the cache memory 21'. When the data in the state "D" exists in the cache memory 21', the data stored in the cache memory 21'is transmitted to the node PE1 via the interconnect network 10'and is sent to the cache memory 21'. A write-back request message with the stored data added is sent to the node PEh via the interconnect network 10'. Further, the state of the relevant data in the cache memory 21'is updated to "S".
【0021】
The consistency maintenance control unit 55'of the node PEh that received the write-back request message updates the data in the main memory 30'to the data added to the write-back request message. Furthermore, the state of the relevant data in the main memory 30'is updated to "C", and node PE1 is added to the holding node information.
【0022】
On the other hand, in the node PEr that received the read request message, if there is no data in the state "D" in the cache memory 21', a Nak (negative response) message is sent to the node PE1 via the interconnect network 10'. To do.
【0023】
The consistency maintenance control unit 55'of the node PE1 that received the Nak message sends a read request message to the node PEh again. After that, the same process is repeated until the data is transmitted to the node PE1 and the data is passed to the processor 20'of the node PE1.
【0024】
Next, the operation when the processor 50'of node PE1 performs store access will be described.
【0025】
Consistency maintenance control unit 55'checks whether the only copy in the system of the data at the corresponding address exists in the cache memory 21'. If a valid copy exists in the cache memory 21', that is, the state is "D", the data in the cache memory 21'is updated, the processor 50'is notified of the completion of access, and the process is terminated.
【0026】
If the only copy does not exist in cache memory 21', that is, if the state is "I" or "S", then the consistency maintenance control unit 55'of node PE1 is the node holding the data at the corresponding address. For example, an exclusive read request message is sent to the node PEh via the interconnect network 10'.
【0027】
The consistency maintenance control unit 55'of the node PEh that received the exclusive read request message checks whether the latest value for the data of the corresponding address exists in the main memory 30'of the node PEh. If the latest value of the data at the corresponding address exists in main memory 30', that is, if the state is "C", it is stored in node PE1 via interconnect network 10'in main memory 30'. The existing data is transmitted via the interconnect network 10'.
【0028】
If a node other than node PE1 holds a copy of the data in the cache memory 21', an invalid request message is sent to all nodes other than node PE1 (referred to as node PEk) in which the copy of the data exists. Transmit via interconnect network 10'. Furthermore, the state of the relevant data in the main memory 30'is updated to "M", and the holding node information is set to node PE1 only. The number of node PEks that sent the invalid request message is added to the data sent to node PE1.
【0029】
The consistency maintenance control unit 55'of the node PEk that received the invalid request message updates the state of the relevant data in the cache memory 21'to "I", and sends an Ack (acknowledgement) message via the interconnect network 10'. Send to node PE1.
【0030】
Upon receiving the data from the node PEh, the consistency maintenance control unit 55'of the node PE1 copies the data to the cache memory 21'. It also waits for as many Ack messages as the number of node PEks attached to the data. When as many Ack messages as the number of node PEks are received, the relevant data in the cache memory 21'is updated to the data of the store access performed by the processor 20'. Further, the state of the data in the cache memory 21 is updated to "D", the processor 20'is notified of the completion of access, and the process is terminated.
【0031】
On the other hand, in the node PEh that received the exclusive read request message, if the latest value of the data at the corresponding address does not exist in the main memory 30', that is, if the state is "M", the holding node information is referred to. Then, an exclusive read request message is sent to the node holding the latest data, for example, the node PEr, via the interconnect network 10.
【0032】
The consistency maintenance control unit 55'of the node PEr that received the exclusive read request message checks whether or not the data of the state "D" exists in the cache memory 21'. If there is no data in the state "D" in the cache memory 21', a Nak message is sent via the interconnect network 10.
【0033】
The consistency maintenance control unit 55'of the node PE1 that received the Nak message sends the exclusive read request message to the node PEh again. After that, the same process is repeated.
【0034】
On the other hand, in the node PEr that received the exclusive read request message, when the data in the state "D" exists in the cache memory 21', the data stored in the cache memory 21 is transferred via the interconnect network 10'. Send to node PE1. In addition, the holding node update request message is sent to the node PEh via the interconnect network 10', and the state of the data in the cache memory 21'is updated to "I".
【0035】
The consistency maintenance control unit 55'of the node PEh that received the hold node update request message updates the hold node information assuming that only the node PE1 holds the data in the main memory 30', and interconnects the Ack message. Send to node PE1 via 10'.
【0036】
The consistency maintenance control unit 55 of the node PE1 that has received the data from the node PEr copies the data to the cache memory 21'. It also waits for an Ack message from node PEh. When the Ack message from the node PEh is received, the data in the cache memory 21'is updated to the data of the store access performed by the processor 20'. Further, the state of the data in the cache memory 21'is updated to "D", and the processor 20'is notified of the completion of access to end the process.
【0037】
[Problems to be Solved by the Invention]
However, in the conventional multiprocessor system 1', when a cache miss occurs in which the data does not exist in the cache memory 21'accessed by reading the processor 20', the data is returned from the cache memory 21'to the processor 20. There was a problem that it took a long time to complete. Also, if the latest data does not exist in main memory 30', it will be necessary to transfer the request to the node that holds the latest data, compared to the case where the latest data exists in main memory 30'. There was a problem that it took a long time for processor 20'to receive data after making a request.
【0038】
The present invention has been made in view of the problems of the prior art as described above, and provides a data consistency maintenance control method that shortens the time required for data consistency maintenance control when a cache error occurs due to reading. It is an object of the present invention to provide a method for maintaining data consistency in a multiprocessor system and a multiprocessor system.
【0039】
[Means for solving problems]
In order to solve the above problems, according to the present invention, it is composed of a plurality of nodes connected to each other via an interconnect network. In a multiprocessor system, multiple nodes are faster than the main memory, where the main memory where the data is stored and a part of the data stored in the main memory of one of the multiple nodes are stored. It manages the accessible cache memory, the processor that issues the data access request, the state of the data in the main memory in the system, manages the state of copying the data in the cache memory, and the processor determines Consistency maintenance control unit that has the function of exchanging messages between node PEi according to memory access, changing their status, and transferring data when loading and storing data at the address of The consistency maintenance control unit has a tag memory that stores the state of the data stored in the cache memory, a directory memory that stores the state of the data stored in the main memory, and a processor. In response to access requests from, requests and responses issued by the home access control unit provided by multiple nodes, the cache memory and tag memory are processed as necessary to maintain consistency, and the processor is accessed. In response to requests and responses issued by the local access control unit that responds to requests and the local access control unit provided by multiple nodes, the main memory and directory memory are processed as necessary to maintain consistency. Writes to the shared block, the home access control unit that issues requests and responses to the local access control unit, the request management table that has entries corresponding to the maximum number of memory accesses that the processor can issue at the same time. It is characterized by comprising a write-back block selection means for storing a block to be exclusively occupied in the cache memory.
【0040】
Further, the write-back block selection means includes an address registration means for registering an address designated by the local access means, an address holding means for holding a plurality of addresses registered by the address registration means, and a plurality of address holding means stored in the address holding means. Select one from the addresses and output it to the local access control unit, and delete the write-back request means that requests the write-back of data and the entry selected by the write-back request means according to the instructions of the local access control unit. It is characterized by including an address deletion means.
【0041】
Further, the local access control unit reads the block stored in the write-back block selection means from the cache memory, issues a write-back request to the data to the home access control unit, and a data write-back request issued by the local access control unit. It is characterized in receiving and writing back data to the main memory.
【0042】
In addition, the local access control unit receives a data write request access to the processor, issues a write request to the home access control unit, receives the write request, and indicates whether or not the data is shared by a plurality of nodes. It judges whether the data is in the shared state from the state of the data held in the memory, adds the judgment result to the response issued to the local access control unit, returns the response to the local access control unit, and returns the response. The receiving local access control unit is characterized in that it determines whether or not to register the block in the write-back block selection means based on the information as to whether or not a plurality of nodes are in a shared state.
【0043】
In addition, the home access control unit has a threshold value that limits the number of writebacks allowed, and when a write request is received from the local access control unit, whether or not the block is actually shared based on the information is determined. It is characterized by making a judgment.
【0044】
In addition, the home access control unit has a threshold value that limits the number of writebacks allowed, and when a write request is received from the local access control unit, it actually blocks based on the threshold value and the information stored in the directory memory. It is characterized by determining whether or not is in a shared state.
【0045】
In addition, the directory memory is characterized in that it has the number of times it has been written back and information that can identify the node when there is only one node that actually holds the block even if the data is in the shared state. And.
【0046】
It also consists of multiple nodes connected to each other via an interconnect network. In a multiprocessor system, each of the multiple nodes stores the main memory in which the data is stored and a part of the data stored in the main memory of one of the multiple nodes, rather than the main memory. A cache memory capable of high-speed access, a processor that issues a data access request, determines the state of the data in the main memory in the system, manages the state of copying the data in the cache memory, and processes the processor. Consistency with the ability to exchange messages between node PEi, change their state, and transfer data in response to memory access when a load and store access is made to data at a given address. It has a maintenance control unit, and the consistency maintenance control unit includes a tag memory that stores the state of data stored in the cache memory, an access request from the processor, and a home access control unit provided by a plurality of nodes. A local access control unit that receives the request or response to be issued, performs the necessary processing for maintaining consistency in the cache memory and tag memory, and responds to the access request to the processor, and multiple nodes. Home access control unit that receives requests and responses issued by the local access control unit, performs necessary processing for maintaining consistency in the main memory and directory memory, and issues requests and responses to the local access control unit. And a request management table that has an entry corresponding to the maximum number of memory accesses that the processor can issue at the same time, and a write-back that writes to the shared block and stores the block that is exclusively occupied by the cache memory. It is characterized by comprising a block selection means.
【0047】
Further, the local access control unit and the home access control unit included in the consistency maintenance control unit are characterized in that they are realized by the processor executing a processing program stored in the main memory.
【0048】
In addition, the local access control unit and the home access control unit included in the consistency maintenance control unit are realized by a dedicated subprocessor provided separately from the processor executing a program stored in the main memory. It is characterized by.
【0049】
In addition, the local access control unit and the home access control unit included in the consistency maintenance control unit are each equipped with dedicated hardware configured according to the dedicated logic for realizing the function of the module. To do.
【0050】
By adopting the above configuration, even if the node processor writes to the shared node's main memory block and the node's cache memory is occupied, the node's write-back block is selected. The means and the local access control unit work to write the occupied block back to the node's main memory. As a result, when a processor of a node other than the node makes load access and there is no block in the cache memory, the block can be read from the main memory of the node, so that the latency of load access can be shortened.
【0051】
In addition, the directory memory is provided with information indicating whether or not it is shared, and the response message sent by the home access control unit that receives the write request to the node that issued the request contains information as to whether or not it was shared. Since it is given and whether or not it is the target of the block to be written back selected by the write-back block selection means, the write-back is not performed for the block that is not shared.
【0052】
In addition, the directory memory is provided with information that can identify the number of times the block has been written back and if there is only one node that actually holds the block even if it is in a state of sharing. In addition, the home access control unit has a threshold value for determining how many times the write back is allowed, thereby indicating that the home access control unit that receives the write request shares the state of the block. However, if only the node that issued the write request holds the block and the threshold value and the number of times the writeback is received match, it means that the response message sent to the node that issued the request is not shared. By having information and excluding it from the target of the write-back block selection means. As a result, it is possible to detect that the shared block is no longer shared over time and prevent unnecessary write-back, so that it is possible to prevent the number of messages from being increased due to write-back.
【0053】
BEST MODE FOR CARRYING OUT THE INVENTION
Next, an embodiment of the present invention will be described with reference to the drawings.
【0054】
In a multi-processor system equipped with cache memory, when a load / store access request is issued from the processor of a certain node into the main memory, the cache memory is first referred to, and as soon as the requested data exists in the cache memory. Transfer the data to the processor. If the data does not exist in the cache memory, a block of an appropriate size including the requested data is read (loaded) from the main memory and stored in the cache memory.
【0055】
On the other hand, when the request of the processor is write (store), if the data exists in the cache memory, not only the contents of the cache memory but also the main memory is rewritten at the same time, and both the main memory and the cache memory are rewritten. The store-through method (or write-through, store-immediate method) that always stores the latest data, and the contents of the cache memory are rewritten for the time being, and the data is written back to the main memory when the cache memory block is reassigned. There is a store back (or write back, swap method).
【0056】
When the latter storeback method is adopted, only the contents of the cache memory are rewritten and then written back to the main memory. Therefore, the contents of the main memory and the contents of the cache memory do not match, and coherency (data data) is adopted. Consistency) may not be maintained. This embodiment attempts to maintain the consistency of data in the main memory and the cache memory.
【0057】
FIG. 1 is a block diagram showing a configuration of a loosely coupled multiprocessor system 1 according to a first embodiment of the present invention.
【0058】
As shown in FIG. 1, the multiprocessor system 1 of this embodiment is composed of a plurality of nodes PE0 to PEn-1 and an interconnect network 10 that connects each node and delivers a message exchanged between the nodes. It is configured. In this embodiment, the number of nodes is n = 1024.
【0059】
FIG. 2 is a block diagram showing the internal configuration of the node PEi (i = 0 to n-1) shown in FIG.
【0060】
As shown in FIG. 2, the node PEi (i = 0 to n-1) has a processor 20, a main memory 30, a cache memory 21, and a consistency maintenance control unit 16, respectively.
【0061】
When the processor 20 makes a memory access, it outputs information about the memory access, here, information such as an access type (load or store), an address, and data. The processor 20 confirms that the memory access has been processed outside the processor 20 by receiving data if the memory access is a load access and a completion signal if the memory access is a store access. Processor 20 can issue the next memory access before confirming that the previous memory access has been processed externally. Therefore, an id is added to each memory access, and the id is output together with the access type, address, data, and cache algorithm type. This id is also added to the response to the processor 20, and it is possible to identify which memory access the response is for.
【0062】
By the way, loading means reading data from the cache memory 21, and store means writing data to the cache memory 21.
【0063】
Here, it is assumed that the type of access is represented by 1 bit, "0" represents load, and "1" represents store access. The address shall consist of 40 bits and the data shall consist of 64 bits. Processor 20 shall be able to issue up to four memory accesses simultaneously and be distinguished by a 2-bit id. In the following description, the least significant bit of the address is the 0th bit and the most significant bit is the 39th bit. Further, it is assumed that the main memory 30 has a 64-bit width × 2M entry = 512M bytes (1M = 1024 × 1024).
【0064】
The address output by the processor 20 represents the data stored in the main memory 30 of which node PEi in the upper bit, and represents the offset in the main memory 30 in the lower bit. Here, out of the 40 bits of the address output by the processor 20, the upper 10 bits from the 39th bit to the 30th bit represent the data of the main memory 30 of which node PEi, and the 29th to 0th bits are shown. The lower 30 bits up to are the offsets in each main memory 30.
【0065】
The cache memory 21 is composed of a memory having a higher speed than the main memory 30, although the amount is smaller than that of the main memory 30. As a result, when the data exists in the cache memory 21, it is possible to respond quickly to the memory access of the processor 20, and the time required for the memory access can be shortened. It is assumed that the cache memory 21 has a 64-bit width × 128K entry = 1 Mbyte (1K = 1024). Further, data transfer between the cache memory 21 and the main memory 30 is performed in a fixed size called a block (hereinafter referred to as 128 bytes).
【0066】
In this multiprocessor system 1, a copy of the data in the main memory 30 may exist in the cache memory 21 of the plurality of nodes PEi. Therefore, it is necessary to control the data consistency between the copy and the data in the main memory 30. The consistency maintenance control unit 16 controls the maintenance of such consistency, and manages the state of copying the data in the cache memory 21 and the state of the data in the main memory in the system. The consistency maintenance control unit 16 has a function of exchanging messages between the nodes PEi in response to memory access, changing their states, and transferring data. The configuration of the consistency maintenance control unit 16 will be described in more detail later.
【0067】
The interconnect network 10 shown in FIG. 1 has a function of delivering a message from a certain node PEi to a certain node PEi based on the routing information included in the message. As this routing information, it is assumed here that the destination node number is necessary and sufficient information. Further, it is assumed that there is only one path from a certain node to a certain node, and overtaking does not occur between messages passing through the same path. However, if either the sending node or the receiving node is different, the order of arrival between messages is not guaranteed.
【0068】
Next, the messages exchanged between the nodes PEi via the interconnect network 10 will be described.
【0069】
FIG. 3 (a) is a diagram showing a request message sent from the node PEi where the memory access was performed to the node PEi holding the data in the main memory 30, and FIG. 3 (b) is a diagram showing the data in the main memory 30. FIG. 3C is a diagram showing a request message sent from the node PEi holding the data to the node PEi holding a copy of the data in the cache memory 21, and FIG. 3 (c) shows a node holding a copy of the data in the cache memory 21. It is a figure which shows the report message sent from PEi to the node PEi which holds the data in the main memory 30, and FIG. 3 (d) is the node PEi where the memory access was made from the node PEi which holds the data in the main memory 30. It is a figure which shows the memory access completion message sent to.
【0070】
The messages are "BlkRdSh", "BlkRdEx", "Upgrade", "BlkWr", "RpBack", "Ack", "AckData", "IntvSh", "IntvEx", "Inv", "CmpDatSh", "CmpDatEx" There are 15 types of messages, "CmpSh", "CmpEx", and "NCmp". These messages are a block share / exclusive read / write message group.
【0071】
Of these, five types of messages, "BlkRdSh", "BlkRdEx", "Upgrade", "BlkWr", and "RpBack", are mainly sent from the node PEi where memory access was performed, as shown in Fig. 3 (a). This is a request message sent to the node PEi that holds data in memory 30.
【0072】
The BlkRdSh message is a block share read request message, the BlkRdEx message is a block exclusive read message, the Upgrade message is an ownership acquisition request message, and the BlkWr and RpBack messages are block write request messages.
【0073】
As shown in Fig. 3 (b), the three types of messages "IntvSh", "IntvEx", and "Inv" hold a copy of the data in the cache memory 21 from the node PEi that holds the data in the main memory 30. This is a request message sent to the node PEi. These messages are request messages for the memory 21 of the other node PEi derived from the BlkRdSh, BlkRdEx, and Upgrade messages.
【0074】
The IntvSh message is a shared read request message, the IntvEx message is an exclusive read request message, and Inv is an invalidation request message.
【0075】
As shown in Fig. 3 (c), the two types of messages "Ack" and "AckData" are from the node PEi that holds a copy of the data in the main memory in the cache memory 21 to the node PEi that holds the data in the main memory 30. This is a report message sent to. Ack and AckData messages are response messages to IntvSh, IntvEx and Inv messages.
【0076】
An Ack message is a response, and an AckData message is a response message with data.
【0077】
As shown in Fig. 3 (d), the five types of messages "CmpDatSh", "CmpDatEx", "CmpSh", "CmpEx", and "NCmp" are accessed by the node PEi that holds the data in the main memory 30. This is a memory access completion response message sent to the node PEi.
【0078】
CmpDatSh messages are shared response messages to BlkRDSh messages, CmpDatEx messages are exclusive response messages to BlkRdEx messages, and NCmp messages are incomplete response messages to BlkRDSh and BlkRdEx messages.
【0079】
FIG. 5 (a) shows the structure of a message with block data, and FIG. 5 (b) is a diagram showing the structure of a basic message.
【0080】
Next, the structure of each of the above-mentioned messages will be described with reference to FIGS. 3 (a), (b), (c), (d) and 5 (a), (b).
【0081】
Messages are classified into basic messages and messages with block data. The 10 types of messages "BlkRdSh", "BlkRdEx", "Upgrade", "Ack", "IntvSh", "IntvEx", "Inv", "CmpSh", "CmpEx", and "NCmp" are basic messages. The five types of messages "BlkWr", "RpBack", "AckData", "CmpDatSh", and "CmpDatEx" are messages with block data.
【0082】
As shown in Fig. 5 (a), the basic message consists of the destination node number (10 bits), the code indicating the message type (15 bits in total, so it is expressed in 4 bits), the requesting node number (10 bits), and mid ( It consists of a total of 66 bits (2 bits) and address (40 bits).
【0083】
As shown in Fig. 5 (b), the message with block data includes the destination node number (10 bits), the code indicating the message type (4 bits), the requesting node number (10 bits), mid (2 bits), and so on. In addition to the address (40 bits), the block size data (128 bytes) consists of a total of 66 bits + 128 bytes.
【0084】
Hereinafter, the consistency maintenance control unit 16 shown in FIG. 2 will be described in more detail. The consistency maintenance control unit 16 includes a tag memory 22, a request management table 24, a local access control unit 25, a write-back block selection means 26, a home access control unit 27, a directory memory 31, and a message transmission unit 35. And a message receiving unit 36.
【0085】
The directory memory 31 stores information indicating the state of the data stored in the main memory 30 for each block. The information of each block stored in the directory memory 31 includes the block status, the information of the node holding the copy in the cache memory 21 (hereinafter referred to as the holding node information), the format of the holding node information, and the number of writes back. Is.
【0086】
The block state is represented by one of five of "C", "M", "RSP", "REP", and "UP". For example, "C" is "000" and "M" is "M". "001" and "RSP" are coded as "100", "REP" is coded as "101", "UP" is coded as "110", and so on.
【0087】
C as the block state represents a state in which a copy of data exists in the cache memory 21 of a plurality of nodes PEi of 0 or more. At this time, the copy of the cache memory 21 and the data value of the main memory 30 are the same. M represents a state in which only the cache memory 21 of one node PEi holds a copy of data. At this time, the copy value of the cache memory 21 and the data value of the main memory 30 are different, and the copy value may be the latest value. "RSP", "REP", and "UP" are in the process of receiving a request message for consistency maintenance processing derived from a certain memory access and performing consistency maintenance processing in response to this request message. Is shown.
【0088】
The holding node information related to this embodiment takes the following three formats.
【0089】
(1) A pointer format that holds one node number (represented by 10 bits) that identifies the node PEi.
【0090】
(2) Course vector format (8 bits here).
【0091】
(3) A counter format that manages the number of nodes that hold copies in cache memory 21 (expressed in 10 bits and counting from 0 to 1023).
【0092】
In the course vector format, holding nodes are managed as follows.
【0093】
Divide the node PEi into several groups and manage the holders (nodes) with bits for the number of groups. Whether or not to set each bit is determined by whether or not there is a node PEi that holds at least one copy in the group corresponding to each bit. Here, this is represented by 8 bits, the 0th bit corresponds to node PE0 to node PE127, the 1st bit corresponds to node PE128 to node PE255, ....., and the 7th bit corresponds to node PE896 to node PE1023.
【0094】
When the status is "M" or "RSP", the holding node is managed in the pointer format. In the case of "REP" and "UP", the holding node is managed in the counter format. In the case of "C", the pointer format and the course vector format are switched according to the number of nodes to be held. Therefore, the directory memory 31 also has 2 bits indicating which format is currently managed for each block (for example, "00" is the course vector format, "01" is the pointer format, and "10" is the counter format). Be retained.
【0095】
The write-back count records the number of times the write-back has been received. Here, it is assumed that it consists of 1 bit, and the number from "0" to "1" can be counted.
【0096】
In this configuration, the directory memory 31 holds data for 16 bits (state 3 bits, holding node information 10 bits, holding format bit 2 bits, writeback count 1 bit) width 4M (main memory size / block size) entries. It becomes the memory to be used. The initial value of each entry stored in the directory memory 31 is "C" for the state, "0x000" for the holding node information (0x is hexadecimal notation), the holding format is the course vector format, and the number of writes back is "0". ".
【0097】
The tag memory 22 holds information indicating the state of the data stored in the cache memory 21 in block units. The information of each block stored in the tag memory 22 is the block state and the tag address. The state of the block is represented by one of the four "I", "S", "E", and "D", referring again to FIG. 6, indicating which state each corresponding block is in. .. For example, the block state is coded in 2 bits such as "00" for "I", "01" for "S", "1 0" for "E", and "11" for "D".
【0098】
An "I" as the block state indicates that there is no valid copy of the data that is consistent. S indicates a state in which a valid copy of the data exists, and a valid copy may also exist in the cache memory 21 of the other node. E indicates that there is a valid copy of the data, there is no valid copy in the cache memory 21 of the other node, and the state is the same as the value of the data in the main memory 30. D indicates a state in which a valid copy of the data exists, a valid copy does not exist in the cache memory 21 of the other node, and the value is different from the value of the data in the main memory 30.
【0099】
The tag address indicates which address the corresponding block is the data of. Here, the cache memory 21 is controlled by a direct map method in which data at a certain address is uniquely determined in which block of the cache memory 21 is stored. In this case, since the size of the cache memory 21 is 1 Mbyte, the upper 20 bits from the 39th bit to the 20th bit of the 40 bits of the address are the tag addresses.
【0100】
In the case of this configuration, the tag memory 22 is a memory that holds data for 22 bit width 8K (= cache memory size ÷ block size) entries. The initial value of each entry stored in the tag memory 22 is "I" in the state and 0x00000 in the tag address.
【0101】
FIG. 6 is a diagram showing the states of the directory memory 31, the tag memory 22, and the memory block.
【0102】
The message transmitting unit 35 and the message receiving unit 36 are each connected to the interconnect network 10, and transmit a message from the node PEi to the interconnect network 10 and receive a message from the interconnect network 10.
【0103】
The message transmission unit 35 is connected to two modules, a local access control unit 25 and a home access control unit 27, and arbitrates and captures the message output by each module.
【0104】
The message receiving unit 36 is connected to two modules of the local access control unit 25 and the home access control unit 27, and outputs a message to the above two modules according to the type of the message received from the interconnection network 10. When the type of the received message is "BlkRdSh", "BlkRdEx", "Upgrade", "BlkWr", "RpBack", "Ack", "AckData", the output destination of the message is the home access control unit 27. In the case of "IntvSh", "IntvEx", "Inv", "CmpDatSh", "CmpDatEx", "CmpSh", "CmpEx", "NCmp", the output destination of the message is the local access control unit 25.
【0105】
The request management table 24 is a table consisting of 4 entries corresponding to the maximum number of memory accesses (here, 4) that the processor 20 can issue at the same time. Each entry consists of a total of 106 bits, which are valid bits (1 bit) indicating whether the entry is valid, access type (1 bit), address (40 bits), and data (64 bits).
【0106】
The request management table 24 has the following functions.
【0107】
(a) A function to write the above setting data (106 bits) output by the local access control unit 25 to the entry specified by the local access control unit 25 according to the instruction of the local access control unit 25.
【0108】
(b) A function that outputs the contents of the entry specified by the local access control unit 25 to the local access control unit 25.
【0109】
The local access control unit 25 has a function of arbitrating and selecting the memory access output by the processor 20, the message output by the home access control unit 27 and the message receiving unit 36, and performing processing for maintaining data consistency. The processing for maintaining data consistency performed by the local access control unit 25 includes access to the tag memory 22, access to the cache memory 21, access to the request management table 24, access to the write-back block selection means 26, and so on. There is a response to the processor 20 and a message output to the message transmission unit 35 or the home access control unit 27.
【0110】
FIG. 4 is a diagram showing an internal configuration of the write-back block control means 26.
【0111】
The write-back block selection means 26 includes an address registration means 110 for registering an address designated by the local access control unit 25, an address holding means 111 for holding a plurality of registered addresses, and a plurality of addresses stored in the address holding means. The write-back request means 112 that selects one from and outputs it to the local access control unit 25 to request write-back, and the address to delete the entry selected by the write-back request means according to the instructions of the local access control unit 25. It has a deletion means 113 and.
【0112】
Here, the address holding means 111 is composed of a FIFO (First In First Out) that stores two entries. The address to be held is 33 bits from the 39th bit to the 7th bit. The address registration means 110 compares each entry of the address holding means 111 with the 39th to 7th bits of the address specified by the local access control unit 25, and if there is no matching entry, registers the address in the address holding means 111. The write-back request means 112 outputs the address of the first entry of the FIFO to the local access control unit 25 when the FIFO is full, and requests write-back. At this time, the 6th to 0th bits of the address are complemented with 0 and output. When the address deletion means 113 is instructed to delete the entry, the first entry of the FIFO is deleted.
【0113】
The home access control unit 27 has a function of receiving a message output by the local access control unit 25 and the message receiving unit 36 and performing a process for maintaining data consistency. The processing for maintaining data consistency performed by the home access control unit 27 includes access to the directory memory 31, access to the main memory 30, and message output to the local access control unit 25 or the message transmission unit 33.
【0114】
In addition, the home access control unit 27 holds a threshold value that limits the number of times of writing back. It consists of this threshold value and the same number of bits (1 bit here) as the number of writes back stored in the directory memory 31. Here, this threshold value may be setable from the processor 20, or a fixed value may be determined. Here, it is assumed that the value "1" is fixedly written.
【0115】
FIG. 7 is a diagram showing the state transitions of the node PEi40 of this embodiment and its constituent elements, the main memory 41 and the cache memory 42.
【0116】
FIG. 7 is a diagram showing the state transitions of the node PEi40 of this embodiment and its constituent elements, the main memory 41 and the cache memory 42.
【0117】
As shown in FIG. 7, when the node PEi40 has a memory access, the node PEi40 that has received the memory access issues a request message to the main memory 41. The main memory 41 further issues a request to the cache memory 42, and if desired data exists in the cache memory 42, the main memory 41 is notified by a report message. Then, a completion message is returned from the main memory 41 to the node PEi40.
【0118】
Hereinafter, the operation of the local access control unit 25 will be described with reference to FIGS. 8 to 13. In principle, this embodiment operates according to the flow shown in FIG.
【0119】
FIG. 8A is a flowchart showing the processing executed by the local access control unit 25 in response to the memory access output by the processor 20, and FIG. 8B9 shows the processing type in the processing of FIG. 8A. It is a table showing the relationship between the message type and the next state of the block. The local access control unit 25 stores the table showing the relationship shown in FIG. 8 (b).
【0120】
At this time, the local access control unit 25 receives information on the access type (1 bit), address (40 bits), id (2 bits), and data (64 bits) from the processor 20.
【0121】
First, in step S111, the local access control unit 25 accesses the tag memory 22 and reads the data (state and tag address) of the corresponding block. Here, among the entries of 8K (1K = 1024), the data of the entry specified by the 13th bit of the 19th to 7th bits of the address is read. From the three information of access type, status, and whether the upper 20 bits from the 39th to 20th bits of the address match the tag address (20 bits), the processing types of "AA" to "AD" described later. Determine which processing type is to be used. From these three pieces of information, the type of message output in steps S113 and S115 when the processing type is "AA" or "AB", and the state of the block updated in step S118 (the tag address is the top 20 of the address). (Always updated to a bit) is also determined.
【0122】
If the processing type determined in step S112 is "AA", the process proceeds to step S113.
【0123】
In step S113, the message to be generated is determined according to the table shown in FIG. 8 (b). The destination node number (10 bits) of the message is the upper 10 bits from the 39th bit to the 30th bit of the address, and the requesting node number (10 bits) is the node number (10 bits) of the node PEi. , Used respectively. For mid and address, the id and address obtained from the processor 20 are used, respectively. At this time, it is determined as follows whether to output the generated message to the message transmission unit 35 or the home access control unit 27. The destination node number is compared with the node number of the node PEi, and if the results do not match, a message is output to the message transmission unit 35, and if they match, the message is output to the home access control unit 27. At the same time, it is also registered in the request management table 24. The local access control unit 25 outputs the valid bit to "1", the type of access added to the received memory access, the address, and the data as setting data to the request management table 24, and is added to the received memory access. Set to the entry (0 to 3) indicated by the id number. When the process of step S113 is completed, the process proceeds to step S118.
【0124】
If the processing type determined in step S112 is "AB", the process proceeds to step S114.
【0125】
In step S114, a total of 16 entries, 128 bytes, specified by 17 bits with 4 bits changing from 0x0 to 0xf added to the 13 bits from the 19th bit to the 7th bit of the address obtained from the processor 20. The block data is read from the cache memory 21 (128K entry x 64-bit width), and the "BlkWr" message with the block data added is generated (step S114). The upper 10 bits from the 19th bit to the 10th bit of the tag address are used for the destination node number of this "BlkWr" message, and the node number of the node PEi is used as the requesting node number. Further, as the address, the tag address (20 bits) is the upper 20 bits, and 20 bits from the 19th bit to the 0th bit of the address obtained from the processor 20 are used as the lower 20 bits. Also, mid can be any value. Whether to output the generated message to the message transmission unit 35 or the home access control unit 27 is determined by the comparison result between the destination node number and the node number, as in the case of step S113. When the process of step S114 is completed, the process proceeds to step S115.
【0126】
Since the process executed in step S115 is the same as the process in step S113, the description thereof will be omitted. When the processing of step S115 is completed, the process proceeds to step S118.
【0127】
If the processing type determined in step S112 is "AC", the process proceeds to step S116.
【0128】
In step S116, 64-bit data corresponding to the entry specified by 17 bits from the 19th bit to the 3rd bit of the address obtained from the processor 20 is read from the cache memory 21, and the read data is returned to the processor 20. To do. At this time, the id obtained from the processor 20 is also passed to the processor 20 at the same time to indicate that it is a response to the memory access of the id. When the process of step S116 is completed, the process proceeds to step S118.
【0129】
If the processing type determined in step S112 is "AD", the process proceeds to step S117.
【0130】
In step S117, the 64-bit data obtained from the processor 20 is written to the entry of the cache memory 21 specified by the 17 bits from the 19th bit to the 3rd bit of the address obtained from the processor 20. It also outputs an id to the processor 20 and notifies the completion of memory access. As a result, the processor is notified that the processing for the memory access of the id is completed. When the process of step S117 is completed, the process proceeds to step S118.
【0131】
In step S118, a process for updating the tag memory 22 is performed. The entry to be updated is the entry accessed in step S111, the state is the next state of the block shown in FIG. 8 (b), and the tag address is the upper bit from the 39th bit to the 20th bit of the address obtained from the processor 20. Update to 20 bits. When the process of step S118 is completed, the process related to the memory access is completed.
【0132】
FIG. 9A shows the processing executed by the local access control unit 25 when three types of messages, IntvSh, IntvEx, and Upgrade, are received from the messages output by the home access control unit 27 or the message reception unit 36. 9 (b) is a table showing the relationship between the processing type, the message type, the next state of the block, and the like in the processing of FIG. 9 (a). The local access control unit 25 stores a table showing the relationship shown in FIG. 9 (b). First, in step S121, read access is performed to the tag memory 22 using the value of the address included in the message. The entry of the tag memory 22 to be accessed is specified by 13 bits from the 19th bit to the 7th bit of the address. As a result, the state and tag address of the corresponding block are read out. The message type, state, and the upper 20 bits from the 39th to 20th bits of the address attached to the message. From the three pieces of information on whether or not the tag addresses match, it is determined which of "BA" and "BB", which will be described later, will be the processing type. In addition, from the above three pieces of information, the type of message output in step S123 and the state of the block to be updated in step S125 (the value of the tag address is not changed) are also determined. The relationship between the above three pieces of information, the processing type, the message type, and the next state of the block is shown in Fig. 9 (b). The local access control unit 25 stores a table showing this relationship.
【0133】
If the processing type determined in step S122 is "BA", the process proceeds to step S123.
【0134】
In step S123, the message to be generated is determined according to the table shown in FIG. 9 (b). When generating a message, the request source node number, address, and mid of the received message are used as they are. For the destination node number, the upper 10 bits from the 39th bit to the 30th bit of the received message address are used. Whether to output the generated message to the message transmission unit 35 or the home access control unit 27 is determined by the comparison result between the destination node number and the node number, as in the case of step S113 in FIG. 8 (a). To do. When the processing of step S123 is completed, the process proceeds to step S125.
【0135】
If the processing type determined in step S122 is "BB", the process proceeds to step S124.
【0136】
In step S124, a total of 16 entries and 128 bytes of block data specified by 17 bits with 4 bits changing from 0x0 to 0xf added to the 13 bits from the 19th bit to the 7th bit of the received message address. Is read. The message to be generated is determined according to the table of FIG. 9 (b), the read block data is added to the generated message, and the message is transmitted via the transmission unit 35. When generating a message, the request source node number, address, and mid are the same as those of the received message. For the destination node number, the upper 10 bits from the 39th bit to the 30th bit of the received message address are used. The local access control unit 25 determines whether to output the generated message to the message transmission unit 38 or the home access control unit 27 based on the comparison result between the destination node number and the node number, as in the case of step S113. decide. When the process of step S124 is completed, the process proceeds to step S125.
【0137】
In step S125, the tag memory 22 is updated. The entry to be updated is the entry accessed in step S121, the state is updated to the next state of the block shown in FIG. 8, and the tag address is updated to the tag address read in step S121. When the processing of step S125 is completed, the processing related to the received message is completed.
【0138】
10 and 11 (a) show five types of messages output by the home access control unit 27 or the message receiving unit 36: CmpDatSh, CmpDatEx, CmpSh, CmpEx, and NCmp. It is a flowchart which shows the process which local access control part 25 executes when a message is received, and FIG. 11 (b) is next to the process type, message type, and block in the process of FIGS. 10 and 11 (a). It is a table showing relationships such as states. The local access control unit 25 stores a table showing the relationship shown in FIG. 11 (b).
【0139】
First, in step S131, the mid included in the message is output to the request management table 24, and the information of the mid th entry is read out. As a result, information on valid bits, access type, address, and data (64 bits) is obtained from the request management table 24. When the process of step S131 is completed, the process proceeds to step S132.
【0140】
In step S132, it is determined whether the received message has data, that is, "CmpDatSh" or "CmpDatEx", or a non-data "CmpSh", "CmpEx", "NCmp" message (step S132). .. If it is determined that the message does not have data, the process proceeds to step S133. On the other hand, if it is determined that the message has data, the process proceeds to step S135.
【0141】
In step S133, it is determined whether the received message is "NCmp". If it is not "NCmp", the process proceeds to step S137. In the case of "NCmp", the process proceeds to step S111 assuming that the access type, address, and data obtained from the request management table 24 are output by the processor 20, and the process shown in the flowchart of FIG. 8 (a) is performed again (step). S133).
【0142】
In step S134, the block data (128 bytes) attached to the message is written to the corresponding block of the cache memory 21. The entries to be written are 16 entries specified by a 17-bit index signal with 4 bits changing from 0x0 to 0xf added to the 13 bits from the 19th bit to the 7th bit of the address obtained from the request management table 24. And each is written in sequence by 64 bits. When the processing of step S134 is completed, the process proceeds to step S135.
【0143】
In step S135, check whether the type of access obtained from the request management table 24 is load or store. If the access type is store, the process proceeds to step S136. On the other hand, if the access type is load, the process proceeds to step S138.
【0144】
In step S136, the data (64 bits) obtained from the request management table 24 is written to the corresponding entry in the cache memory 21. The entry to be written is specified by 17 bits from the 19th bit to the 3rd bit of the address obtained from the request management table 24. In addition, the data with the valid bit set to "0" is output to the request management table 24, and the value is written to the entry specified by mid of the received message. This removes the corresponding entry from the request management table 24. Further, the process for updating the tag memory 22 is also performed. The entry to be updated is specified by 13 bits from the 19th bit to the 7th bit of the address obtained from the request management table 24. The data to be updated is the block status and tag address. Regarding the block status, the type of access is as shown in the table in Figure 11 (b). It is determined by the type of message received (here, the store). For the tag address, the upper 20 bits from the 39th bit to the 20th bit of the address read from the request management table 24 are used. In addition, it also notifies the processor 20 of the completion. At this time, the mid added to the message is output to the processor 20, and it is notified which memory access is completed. When the process of step S136 is completed, the process proceeds to step S137.
【0145】
In step S137, check whether the received message is "CmpSh" or "CmpDatSh". If "Yes", the process proceeds to step S141 and the write-back process is performed. If "No", the processing of the received message is terminated.
【0146】
In step S138, the 64-bit data of the entry of the cache memory 21 specified by the 17 bits from the 19th bit to the 3rd bit of the address obtained from the request management table 24 is read. The read 64-bit data is passed to the processor 20 together with the mid. It also updates the request management table 24 and the tag memory 22. All of these processes are the same as the respective processes in step S136, and the description thereof will be omitted. When the processing of step S138 is completed, the processing of the received message is completed.
【0147】
In step S141, it is checked whether the write-back block selection means 26 requests write-back. If writeback is requested, the process proceeds to step S142. If not requested, proceed to step S146.
【0148】
In step S142, the data of the entry of the tag memory 22 specified by the 13 bits from the 19th bit to the 7th bit of the address output by the write-back block selection means 26 is read, and the tag address and the state are obtained.
【0149】
In step S143, it is determined whether or not the tag address 20 bits and the upper 20 bits of the address output by the write-back block selection means 26 match, and whether or not write-back is necessary based on whether or not the state is D. If both are "Yes", it is judged that writing back is necessary, and the process proceeds to step S144. If either of them is "No", the process proceeds to step S145.
【0150】
In step S144, a total of 16 entries specified by 17 bits with 4 bits changing from 0x0 to 0xf added to the 13 bits from the 19th bit to the 7th bit of the address obtained from the write-back block selection means 26. , Reads 128 bytes of block data from the cache memory 21 and generates an "RpBack" message with the block data added. For the destination node number of this "RpBack" message, the upper 10 bits of the address obtained from the write-back block selection means 26 are used, and for the request source node number, the node number of the node PEi is used. Further, as the address, the address obtained from the write-back block selection means 26 is used. Also, mid can be any value. Whether to output the generated message to the message transmission unit 35 or the home access control unit 27 is determined by the comparison result between the destination node number and the node number, as in the case of step S113 in FIG. 8 (a). .. It also updates the tag memory 22. The entry to be updated is the entry specified in step S142, the state is updated to "S", and the tag address is updated to the tag address read in step S142. When the process of step S144 is completed, the process proceeds to step S145.
【0151】
In step S145, the address of the request received from the write-back block selection means 26 is deleted. When the process of step S145 is completed, the process proceeds to step S146.
【0152】
In step S146, the address added to the received message (CmpSh or CmpDatSh) is registered in the write-back block selection means 26. When this processing is completed, the processing of the received message is completed.
【0153】
Hereinafter, the operation of the home access control unit 27 will be described with reference to FIGS. 12 (a), 12 (b) and 13.
【0154】
FIG. 12 (a) is a flow chart showing the processing executed by the home access control unit 27, and FIGS. 12 (b) and 13 are received messages used in the processing of the flowchart of FIG. 12 (a). Type, directory memory read block status, retention format and uncached information obtained from the retention node information, four pieces of information such as whether the number of writes back and the threshold match, and the status and retention of the block stored in the directory memory. It is a table showing operations for node information, operations for writeback count, processing type, and message type.
【0155】
In the processing of the flowchart of FIG. 12A, the home access control unit 27 obtains the type of the received message, the state of the block read from the directory memory 31, the holding format, and the uncached information obtained from the holding node information. Based on the four information of whether the write-back count and the threshold value match, the state of the block stored in the directory memory 31 in step S152, the operation and retention format for the holding node information, the operation for the write-back count, and the operation in step S153. Determine the processing type, the type of message to be output in step S154, step S155, and step S156.
【0156】
The home access control unit 27 stores the tables shown in FIGS. 12 (b) and 13. In addition, in FIG. 12 (b) and FIG. 13, "-" indicates that any value may be used.
【0157】
The uncached information shown in FIGS. 12 (b) and 13 asks whether or not the other nodes PEi other than the requesting node PEi hold a copy. The method of obtaining the uncached information differs depending on the format of the holding node information.
【0158】
If the holding node information is in pointer format, the uncached information will be "Yes" if the requesting node number 10 bits of the received message and the holding node information 10 bits match, and if they do not match, the uncached information will be "Yes". It becomes "No".
【0159】
When the holding node information is in the course vector format, the uncached information is "Yes" when the course vector is "0" for all 8 bits, and "No" when "1" is set even for 1 bit. ".
【0160】
When the holding node information is in the counter format, if the value obtained by subtracting 1 from the number of holding nodes becomes "0", the uncached information becomes "Yes", and if it does not become "0", it becomes "0". No ".
【0161】
Next, an operation on the retained node information shown in FIGS. 12 (a) and 13 (referred to as retained node operation in the figure) will be described. There are six operations for the retained node information: "set", "add", "count", "dec", "clean", and "none".
【0162】
Set sets the requesting node number of the received message as the holding node number, and is held in the pointer format. At this time, the holding format is also set to "01" indicating the pointer format.
【0163】
Add is an operation performed on the retention node number format and the course vector format. In the case of the retention node number format, the 8 bits obtained by decoding the upper 3 bits of the read retention node number are decoded, in the case of the course vector format, the 8 bits are decoded as they are, and the upper 3 bits of the requesting node number are decoded. It is set to the value obtained by ORing the obtained 8 bits. By performing the "add" operation, the holding format becomes the course vector format. Accordingly, the retention format is also set to "00", which indicates the course vector format.
【0164】
"Count" is an operation performed for the holding node number format or the course vector format, and it means that several nodes PEi hold a copy of the read holding node information except for the requesting node number. It is an operation to find out. "Count" is set to "1" in the pointer format. In the case of the course vector format, it is calculated by multiplying the number of bits in which 1 is set out of 8 bits by the number of nodes PEi represented by 1 bit 128. However, when the bit corresponding to the request source node number is 1, a value obtained by subtracting 1 from the number obtained above is set. As a result, the holding format is also set to "10", which indicates the counter format.
【0165】
Dec is an operation performed on the counter format. It is set to the value obtained by subtracting 1 from the number of retained nodes read.
【0166】
Clean sets all 10 bits to 0. In this case, the retention format is set to "00", which indicates the course vector format.
【0167】
None is set as it is without performing any operation on the read value. The value of the retention format is also maintained.
【0168】
Next, the number of writebacks shown in FIGS. 12 (b) and 13 will be described. Operations related to the number of writebacks include an operation that initializes the value to "0" and an operation that adds 1 to the current value to set the next value. In the figure, "0" and "+1" correspond to each. If there is no description, it means that the same value as the current value is set as the next value.
【0169】
Hereinafter, the processing of the flowchart of FIG. 12A will be described.
【0170】
First, in step S151, the home access control unit 27 reads the data (state, holding node information, holding format, number of writes back) of the entry of the corresponding directory memory (step S151). The entry to be read is the data in the directory memory 31 indexed by 22 bits from the 28th bit to the 7th bit of the received message address. When the process of step S151 is completed, the process proceeds to step S152.
【0171】
In step S152, the value of the entry in the directory memory 31 read in step S151 is updated. The state is determined according to the table shown in FIGS. 12 (b) and 13. The holding node information is obtained by performing the operations shown in FIGS. 12 (b) and 13 with respect to the holding node information read in step S131. The holding node type is also determined as described above by the operation. The number of writebacks is determined by performing the operations shown in FIGS. 12 (b) and 13. The entry updated in step S152 is the same entry accessed in step S151. Further, if the message has data, the process of writing the block data to the main memory 30 is also performed. The entry of the main memory 30 to which the block data is written is the total specified by 26 bits, which is obtained by adding 4 bits changing from 0x0 to 0xf to 22 bits from the 28th bit to the 7th bit of the received message address. 16 entries (128 bytes). When the process of step S152 is completed, the process proceeds to step S153.
【0172】
In step S153, the processing type is set from four pieces of information: the type of message received, the state of the block read from the directory memory 31, the uncached information obtained from the holding format and holding node information, and the comparison result of the number of writes back and the threshold value. Determine which of "CA" to "CC". If it is determined that the processing type is "CA", the process proceeds to step S154. If it is determined in step S153 that the processing type is "CB", the process proceeds to step S155. If it is determined in step S153 that the processing type is "CC", the processing of the received message is terminated.
【0173】
In step S154, multiple messages are generated and output if necessary. The output destination is either the local access control unit 25 or the message transmission unit 35. Which one to output is determined by the comparison result between the destination node number of the generated message and the node number. If they match, it becomes the local access control unit 25, and if they do not match, it becomes the message transmission unit 35. The output message (destination node number, message type, address, mid, requesting node number) is generated as follows. The type of message is determined according to FIGS. 12 (b) and 13. The address, mid, and request source node number are the address, mid, and request source node number of the received message, respectively. The destination node number depends on the type of message being generated. The following shows how to obtain the destination node number according to the message type.
【0174】
In the case of "CmpDatSh", "CmpDatEx", "CmpSh", "CmpEx", "NCmp", the request source node number of the received message becomes the destination node number. In the case of "IntvSh" and "IntvEx", the format of the holding node information read from the directory memory 31 in step S141 is the pointer format, and the value is used as it is. In the case of the above messages, only one message is generated.
【0175】
In the case of "Inv", multiple messages differing only in the destination node number are generated and sent. This destination node number is generated according to the holding node information. The holding node information is in pointer format or course vector format. In the case of the pointer format, the holding node information is used as it is and only one message is generated as in the case of "IntvSh". In the case of the course vector format, the same message with a different destination is generated and output for a plurality of nodes PEi (excluding the requesting node) represented in this format. For example, if the holding node information is "00110100" and the requesting node number is "0010010110", the destination nodes are PE256 to PE383 and PE512 to PE807, for a total of 384 nodes, and an "Inv" message is sent to these 384 nodes. Will be sent. Further, for example, when the holding node information is "11001011" and the requesting node number is "0010010110", the destination nodes are PE0 to PE149, PE151 to PE255, PE384 to PE511, and PE808 to PE1023, for a total of 679 nodes. 679 An "Inv" message is sent to the node.
【0176】
When the message generation output is finished in step S154, the processing of the received message is finished.
【0177】
In step S155, the corresponding block data (128 bytes) is read from the main memory 30 (64M entry × 64-bit width). The block data to be read is a total of 16 entries of data specified by 26 bits with 4 bits changing from 0x0 to 0xf added to 22 bits from the 28th bit to the 7th bit of the received message address. It consists of 128 bytes. This block data is added to the generated message and output. The output destination is either the local access control unit 25 or the message transmission unit 35. Which one to output is determined in the same manner as in step S154. The same applies to message generation. When the processing of step S155 is completed, the processing of the received message is completed.
【0178】
The above is the description of the operation of the first embodiment of the present invention. Next, in order to help the understanding of this embodiment, specific examples of the operation of this embodiment will be described separately from Phase 1 to Phase 5B with reference to FIGS. 1 to 3.
【0179】
Here, Phase 1 is an operation from when the processor 20 of the node PE1 makes a rod access to the data in the main memory 30 of the node PE1 until it is completed.
【0180】
In Phase 2, after Phase 1, the processor 20 of Node PE2 makes load access to the data in the same block as the data in the main memory 30 of Node PE1 accessed by Node PE1 in Phase 1 until it is completed. It is an operation.
【0181】
Phase 3 is the operation from when the processor 20 of the node PE2 makes a store access to the data of the same block as the data of the main memory 30 of the node PE1 accessed in the phase 2 after the phase 2 until it is completed. ..
【0182】
Phase 4 is the operation until the "RpBack" message is transmitted as a result of the write-back processing being performed on the node PE2 after Phase 3 and the processing is performed.
【0183】
Phase 5A is the operation from the time when the processor 20 of the node PE1 makes load access to the data of the block written back in the phase 4 after the phase 4 until the completion of the load access.
【0184】
Phase 5B is the operation from the time when the processor 20 of the node PE2 makes a store access to the data of the block written back in the phase 4 after the phase 4 until the completion of the store access.
【0185】
1. Phase 1 (1) Load access processing Assume that processor 20 of node PE1 makes load access to address "0x0040030000" with id = "0".
【0186】
The local access control unit 25 that has received the memory access performed by the processor 20 operates as follows according to the flowchart of FIG. 8A.
【0187】
First, in step S111, the data at the address "0x0600" of the tag memory 22 (13 bits of the 19th to 7th bits of the address "0x0040030000" obtained from the processor 20) is read. Since the initial state is "I", the processing type is "AA", the message to be issued is "BlkRdSh", and the next state of the block is "I" from Fig. 8 (b). When the above processing is completed, the process proceeds to step S112.
【0188】
In step S112, since the processing type is AA, the process proceeds to step S113.
【0189】
In step S113, message generation output and registration in the request management table 24 are performed. The destination node number of the generated and output message is "0x001" (10 bits of the 39th to 30th bits of the address "0x0040030000"), the message type is "BlkRdSh", the address is "0x0040030000", and the mid is "0". (= id), the request source node number is "0x001". Further, since the destination node number and the node number of the node PE1 both match "0x001", the output destination is the home access control unit 27 of the node PE1. Also, write the data that the valid bit is "1", the access type is load, and the address is "0x0040030000" in the "0" (= id) entry of the request management table. When the above processing is completed, the process proceeds to step S118.
【0190】
In step S118, the data of the entry at address 0x0600 in the tag memory is updated to the state "I" and the tag address "0x00400" (20 bits of the 39th to 20th bits of the address "0x0040030000").
【0191】
With the above, the local access control unit 25 of the node PE1 ends the load access process.
【0192】
(2) BlkRdSh message processing Home of node PE1 that received the above "BlkRdSh" message (destination node number is "0x001", message type is "BlkRdSh", address is "0x0040030000", mid is "0", requesting node number is "0x001") The access control unit 27 operates as follows according to the flowchart of FIG. 12 (a).
【0193】
First, in step S151, the address "0x000600" (22 bits of the 28th to 7th bits of the address "0x0040030000" added to the message) of the directory memory 31 is accessed, and data such as the status is read out. The read state, retention node information, retention format, and writeback count are "C", "0x000", "00" (course vector format), and "0" in the initial state, respectively. Since the received message type is "BlkRdSh", the read state is "C", the retention format is course vector format, the retention node information is "0x000", and it is uncached, the processing type is "CB". , The next state of the block is "M", the hold node operation is "set", the number of writes back is the same, and the type of message to be output is "CmpDatEx" (see Fig. 12 (a) and Fig. 13). When the above processing is completed, the process proceeds to step S152.
【0194】
In step S152, based on this information, the data at the address "0x000600" of the directory memory 31 is written back, the state is "M", the holding node information is "0x001", the holding format is "01" (pointer format), and the data is written back. The number of times is updated to "0". Also, since it is not a message with data, block data is not written to the main memory 30. When the above processing is completed, the process proceeds to step S153.
【0195】
In step S153, since the processing type is "CB", the process proceeds to step S155.
【0196】
In step S155, block data of 64 bits × 16 entries = 128 bytes from the address 0x0006000 to the address 0x000600f of the main memory 30 is read, added to the generated message, and output. For this message, the destination node number is "0x001", the message type is "CmpDatEx", the address is "0x0040030000", the mid is "0", the requesting node number is "0x001", and the block data is read in the relevant step S145. This is a message to be block data. Since the destination node number and the node number match both with "0x001", the output destination of this message is the local access control unit 25 of the node.
【0197】
With the above, the home access control unit 27 of the node PE1 ends the processing of the "BlkRdSh" message.
【0198】
(3) CmpDatEx message processing Local of node PE1 that received the above "CmpDatEx" message (destination node number is "0x001", message type is "CmpDatEx", address is "0x0040030000", mid is "0", requesting node number is "0x001") The access control unit 25 operates as follows according to the flowcharts of FIGS. 10 and 11 (a).
【0199】
First, in step S131, the information of the "0" (= mid) entry in the request management table 24 is read, and the information that the access type is load and the address is "0x0 040030000" is obtained. When the above processing is completed, the process proceeds to step S132.
【0200】
In step S132, since the message has block data, the process proceeds to step S135.
【0201】
In step S135, the block data added to the message is written from the address "0x06000" to the address "0x0600f" of the cache memory 21. When the above processing is completed, the process proceeds to step S136.
【0202】
In step S136, since the access type is load, the process proceeds to step S139.
【0203】
In step S139, the 64-bit data at address 0x06000 is read from the cache memory 21 and passed to the processor 20 as response data for the memory access with id = 0. This completes the memory access. In addition, the data with the valid bit set to "0" is written to the "0" entry in the request management table 24, and the entry is deleted. Also, the state of address "0x0600" and the tag address of the tag memory are updated to "E" and "0x00400", respectively (see Fig. 11 (b)).
【0204】
With the above, the local access control unit 25 of the node PE1 ends the processing of the received "CmpDatEx" message.
【0205】
At this stage, the latest data exists in the main memory 30 of the node PE1 and the cache memory 21 of the node PE1 for addresses "0x0040030000" to "0x004003007f".
【0206】
2. Phase 2 (1) Load access processing Next, suppose that the load access is made to the address "0x0040030000" with id = "2" on the node PE2.
【0207】
The local access control unit 25 that has received the memory access (access type is load, address is "0x0040030000", id = "2") made by the processor 20 operates as follows according to the flowchart of FIG. 8 (a). ..
【0208】
First, in step S111, the data at address "0x0600" in the tag memory 22 is read (step S111). Since the initial state is "I", the processing type is "AA", the message to be issued is "BlkRdSh", and the next state of the block is "I" from Fig. 8 (b). When the above processing is completed, the process proceeds to step S112.
【0209】
In step S112, since the processing type is AA, the process proceeds to step S113.
【0210】
In step S113, message generation output and registration in the request management table 24 are performed. The destination node number of the generated and output message is "0x001" (10 bits of the 39th to 30th bits of the address "0x0040030000"), the message type is "BlkRdSh", the address is "0x0040030000", and the mid is "2". , The request source node number is "0x002". Further, since the destination node number and the node number of the node PE2 are different, the output destination is the message transmission unit 35. At this time, the data that the valid bit is "1", the access type is load, and the address is "0x0040030000" is written in the "2" (= id) entry of the request management table. When the above processing is completed, the process proceeds to step S118.
【0211】
In step S118, the data of the entry at address "0x0600" in the tag memory is updated to the state "I" and the tag address "0x00400" (20 bits of the 39th to 20th bits of the address "0x0040030000"). (Step S118).
【0212】
With the above, the local access control unit 25 of the node PE2 ends the load access process.
【0213】
(2) BlkRdSh message processing The above "BlkRdSh" message is sent to the home access control unit 27 of the node PE1 via the message transmission unit 35 of the node PE2, the interconnection network 10, and the message reception unit 36 of the node PE1.
【0214】
Home access control unit that received the above "BlkRdSh" message (destination node number is "0x001", message type is "BlkRdSh", address is "0x0040030000", mid is "2", requesting node number is "0x002") 27 operates as follows according to the flowchart of FIG. 12 (a).
【0215】
First, in step S151, the address "0x000600" (22 bits of the 28th to 7th bits of the address "0x0040030000" added to the message) of the directory memory 31 is accessed, and data such as the status is read out. In Phase 1, the status, retention node information, retention format, and write-back count are updated to "M", "0x001", "01", and "0", respectively, and their values are read out. The received message type is "BlkRdSh", the read state is "M", the retention format is pointer format and the retention node information is "0x001", which is not uncached. Therefore, the processing type is "M" according to Fig. 13. "CA", the next state of the block is "RSP", the hold node operation is "none", the number of writebacks is "0", and the type of message to be output is "IntvSh". .. When the above processing is completed, the process proceeds to step S152.
【0216】
In step S152, based on this information, the data at address "0x000600" in the directory memory 31 is stored, the status is "RSP", the retention node information is "0x001", the retention format is "01", and the number of writes back is "0". Update to. Here, since it is not a message with data, the block data is not written to the main memory 30. When the above processing is completed, the process proceeds to step S153.
【0217】
In step S153, since the processing type is "CA", the process proceeds to step S154.
【0218】
In step S154, a message is generated in which the destination no number is "0x001", the message type is "IntvSh", the address is "0x0040030000", the mid is "2", and the requesting node number is "0x002". Since the destination node number and the node number of the node PE1 match, the output destination of the message is the local access control unit 25 (step S144).
【0219】
With the above, the home access control unit 27 of the node PE1 ends the processing of the "BlkRdSh" message.
【0220】
(3) IntvSh message processing Local of node PE1 that received the above "IntvSh" message (destination node number is "0x001", message type is "IntvSh", address is "0x0040030000", mid is "2", requesting node number is "0x002") The access control unit 25 operates as follows according to the flowchart of FIG. 9A.
【0221】
First, in step S121, the data at address "0x0600" in the tag memory 22 is read out. In Phase 1, the state and tag address are updated to "E" and "0x00400", respectively, and these values are read. Since the received message is "IntvSh", the tag address matches, and the status is "E", the processing type is "BA" and the output message type is "Ack" according to Fig. 9 (b). The next state of the block is determined to be "S".
【0222】
In step S122, since the processing type is "BA", the process proceeds to step S123.
【0223】
In step S123, an "Ack" message is generated. In the "Ack" message, the destination node number is "0x001", the message type is "Ack", the address is "0x0040030000", the requesting node number is "0x002", and the mid is "2". Since the destination node number and the node number of the node PE1 match with "0x001", the output destination is the home access control unit 27. When the above processing is completed, the process proceeds to step S125.
【0224】
In step S125, the state of the tag memory address 0x0600 and the tag address are updated to S and 0x00400, respectively.
【0225】
With the above, the local access control unit 25 of the node PE1 ends the processing of the "IntvSh" message.
【0226】
(4) Processing of Ack messages Home access control unit that received the above "Ack" message (destination node number is "0x001", message type is "Ack", address is "0x0040030000", mid is "2", requesting node number is "0x002") 27 operates as follows according to FIG. 12 (a).
【0227】
First, in step S151, the address "0x000600" (22 bits of the 28th to 7th bits of the address "0x0040030000" added to the message) of the directory memory 31 is accessed, and data such as the status is read out. The read state, holding node information, holding format, and write-back count are updated to "RSP", "0x001", "01" (pointer format), and "0" in Phase 2, respectively, and their values are read. Since the type of the received message is "Ack" and the read state is "RSP", the processing type is "CB", the next state of the block is "C", and the number of writes back is the same, according to Fig. 13. The hold node operation is determined to be "add", and the type of message to be output is determined to be "CmpDatSh". When the above processing is completed, the process proceeds to step S152.
【0228】
In step S152, based on this information, the data at address "0x000600" in the directory memory 31 is written with the state "C", the holding node information "0x001", and the holding format "00" (course vector format). The number of returns is updated to "0". Also, since the "Ack" message is not a message with block data, the data is not written to the main memory 30. However, the latest data exists in the main memory 30. When the above processing is completed, the process proceeds to step S153.
【0229】
In step S153, since the processing type is "CB", the process proceeds to step S155.
【0230】
In step S155, block data of 64 bits × 16 entries = 128 bytes from the address 0x0006000 to the address 0x000600f of the main memory 30 is read, added to the generated message, and output. For this message, the destination node number is "0x002", the message type is "CmpDatSh", the address is "0x0040030000", the mid is "2", the requesting node number is "0x002", and the block data is read in the relevant step S145. This is a message to be block data. The output destination of this message is the message transmission unit 35 because the destination node number 0x002 and the node number 0x001 of the node PE1 do not match.
【0231】
With the above, the home access control unit 27 of the node PE1 ends the processing of the "Ack" message.
【0232】
(5) CmpDatSh message processing The above "CmpDatSh" message is output to the local access control unit 25 of the node PE2 via the message transmission unit 35 of the node PE1, the interconnection network 10, and the message reception unit 36 of the node PE2.
【0233】
The above "CmpDatSh" message (destination node number is "0x002", message type is "CmpDatSh", address is "0x0040030000", mid is "2", requesting node number is "0x002", block data is the latest data) The local access control unit 25 of the received node PE2 operates as follows according to the flowchart of FIG.
【0234】
First, in step S131, the information of the "2" (= mid) entry in the request management table 24 is read, and the information that the access type is load and the address is "0x0040030000" is obtained. When the above processing is completed, the process proceeds to step S132.
【0235】
In step S132, since the message has block data, the process proceeds to step S135.
【0236】
In step S135, the block data added to the message is written from the address "0x06000" to the address "0x0600f" of the cache memory 21. When the above processing is completed, the process proceeds to step S136.
【0237】
In step S136, since the access type is load, the process proceeds to step S139.
【0238】
In step S139, the 64-bit data at address 0x06000 is read from the cache memory 21 and passed to the processor 20 as response data for the memory access with id = 2. This completes the memory access. In addition, the data with the valid bit set to "0" is written to the "2" entry in the request management table 24, and the entry is deleted. In addition, the state of the address "0x0600" and the tag address of the tag memory are updated to "S" and "0x00400", respectively, according to FIG. 11 (b) (step S139).
【0239】
With the above, the local access control unit 25 of the node PE2 ends the processing of the received "CmpDatSh" message.
【0240】
At this stage, the latest data from addresses "0x0040030000" to "0x004003007f" are present in the cache memory 21 of the node PE1, the main memory 30 of the node PE1, and the cache memory 21 of the node PE2.
【0241】
3. Phase 3 (1) Store access processing Next, it is assumed that the store access is performed at the address "0x0040030010" with the id = "1" on the node PE2.
【0242】
The local access control unit 25 of the node PE2 that has received the memory access performed by the processor 20 operates as follows according to the flowchart of FIG. 8 (a).
【0243】
First, in step S111, the data at address "0x0600" in the tag memory 22 is read. In Phase 2, the state is updated to "S" and the tag address is updated to "0x00400", and the value is read out. Since the access type is store, the tag address matches with "0x00400", and the status is "S", the processing type is "AA", the output message type is "Upgrade", and the block is blocked according to Fig. 8 (b). The next state of is determined to be "S". When the above processing is completed, the process proceeds to step S112.
【0244】
In step S112, since the processing type is AA, the process proceeds to step S113.
【0245】
In step S113, message generation output and registration in the request management table 24 are performed. The destination node number of the generated and output message is "0x001" (10 bits of the 39th to 30th bits of the address "0x0040030010"), the message type is "Upgrade", the address is "0x0040030010", and the mid is "1". , The request source node number is "0x002". Further, since the destination node number and the node number of the node PE2 are different, the output destination is the message transmission unit 35. At this time, the valid bit is "1", the access type is store, the address is "0x0040030010", and the store data is written in the "1" (= id) entry of the request management table. When the above processing is completed, the process proceeds to step S118.
【0246】
In step S118, the data of the entry at address "0x0600" in the tag memory is updated to the state "S" and the tag address "0x00400" (20 bits of the 39th to 20th bits of the address "0x0040030010"). ..
【0247】
With the above, the local access control unit 25 of the node PE2 ends the store access process.
【0248】
(2) Upgrade message processing The above "Upgrade" message is sent to the home access control unit 27 of the node PE1 via the message transmission unit 35 of the node PE2, the interconnection network 10, and the message reception unit 36 of the node PE1.
【0249】
Home of node PE1 that received the above "Upgrade" message (destination node number is "0x001", message type is "Upgrade", address is "0x0040030010", mid is "1", requesting node number is "0x002") The access control unit 27 operates as follows according to the flowchart of FIG. 12 (a).
【0250】
First, in step S151, the address "0x000600" (22 bits of the 28th to 7th bits of the address "0x0040030010" added to the message) of the directory memory 31 is accessed, and data such as the status is read out. In Phase 2, the status, retention node information, retention format, and write-back count are updated to "C", "0x001", "00" (course vector format), and "0", respectively, and their values are read out. Since the received message type is "Upgrade", the read state is "C", the retention format is course vector format, the retention node information is "0x001", and it is not uncached, Fig. 12 (b) ), The processing type is "CA", the next state of the block is "UP", the hold node operation is "count", the number of write-back updates is the same, and the type of message to be output is "Inv". When the above processing is completed, the process proceeds to step S152.
【0251】
In step S152, based on this information, the data at address "0x000600" in the directory memory 31 is written back, the status is "UP", the retention node information is "0x07f", the retention format is "10" (counter format), and the data is written back. The number of times is updated to "0". Also, since the message being processed is not a message with block data, it is not written to the main memory 30. When the above processing is completed, the process proceeds to step S153.
【0252】
In step S153, since the processing type is "CA", the process proceeds to step S154.
【0253】
In step S154, multiple "Inv" messages differing only in the destination node number are generated and output. This "Inv" message is a message in which the message type is "Inv", the address is "0x0040030010", the mid is "1", and the requesting node number is "0x002". The destination node number changes from "0x000" to "0x07f" excluding the request source node number "0x002". 127 messages are generated by the above processing. The output destination of each message is determined by the comparison result of the destination node number and the node number. Since the message whose destination node number is "0x001" matches the node number "0x001" of the node PE1, it is output to the local access control unit 25. Other messages whose destination node number is not "0x001" do not match the node number of the node PE1, so they are output to the message transmission unit 35.
【0254】
With the above, the home access control unit 27 of the node PE2 ends the processing of the "Upgrade" message.
【0255】
(3) Inv message processing These "Inv" messages are output to the local access control unit 25 of each node via the message transmission unit 35 of node PE1, the interconnect network, and the message reception unit 36 of each node PE0 to PE127 (excluding PE1 and PE2). .. The "Inv" message to node PE1 is output directly to the local access control unit 25 as described above.
【0256】
Received the above "Inv" message (destination node number is the node number of the received node PEi, message type is "Inv", address is "0x0040030010", mid is "1", requesting node number is "0x002") The local access control unit 25 of each node PEi (i = 0, 1, 3, ..., 127) operates as follows according to the flowchart of FIG. 9A.
【0257】
First, in step S121, the local access control unit 25 that receives the "Inv" message reads the data at address "0x0600" in the tag memory 22. Depending on whether the read tag address matches "0x00400" and what the state is, according to the table in Fig. 9 (b), the processing type, the type of message to be output, and the next state of the block in tag memory 22 Is decided. When the above processing is completed, the process proceeds to step S122.
【0258】
In step S122, the processing type when the "Inv" message is received is "BA", so the process proceeds to step S123.
【0259】
In step S123, an "Ack" message is generated. In this "Ack" message, the destination node number is "0x001", the message type is "Ack", the address is "0x00400300010", the mid is "1", and the requesting node number is "0x002". The output destination is determined by the comparison result between the destination node number "0x001" and the node number. If it is node PE1, it matches, so it is output to the home access control unit 27. If it is another node, it does not match, so it is output to the message transmission unit 35. When the above processing is completed, the process proceeds to step S125.
【0260】
In step S125, the tag memory is then updated. The entry to be updated is the entry at the address "0x0600" read in step 121, the state is updated to the next state "I" of the block obtained from FIG. 8, and the tag address is the same as the value read from the tag memory 22 earlier. Written (step S125).
【0261】
With the above, the local access control unit 25 of each node PEi (i = 0,1,3, ..., 127) ends the processing of the "Inv" message.
【0262】
(4) Processing of Ack messages Node PE0 and node PE3 to node PE127 send the above "Ack" message to node PE1, respectively. This "Ack" message is output to the home access control unit 27 of the node PE1 via the message transmission unit 35 of each node, the interconnection network 10, and the message reception unit 36 of the node PE1.
【0263】
On the other hand, in node PE1, the local access control unit 25 outputs an "Ack" message to the home access control unit 27.
【0264】
The home access control unit 27 of node PE1 has a total of 127 same "Ack" messages (destination node "0x001", type "Ack", address "0x0040030010", mid "1", requesting node number. Receives "0x002") and processes it according to the flowchart of FIG. 12 (a). When the home access control unit 27 of node PE1 receives the first "Ack" message, it operates as follows.
【0265】
First, in step S151, the address "0x000600" (22 bits of the 28th to 7th bits of the address "0x0040030010" added to the message) of the directory memory 31 is accessed, and data such as the status is read out. The read state, holding node information, holding format, and write-back count are updated to "UP", "0x07f", "10" (counter format), and "0" in Phase 3, respectively, and their values are read. Since the received message type is "Ack", the read state is "UP", the holding node format is counter format, and the holding node information is 0x07f, which is not uncached, the processing type is according to the table in Fig. 13. Is "CC", the next state of the block is "UP", the hold node operation is "dec", the number of write-back updates is the same, and no message is output. When the above processing is completed, the process proceeds to step S152.
【0266】
In step S152, based on this information, the data at address "0x000600" in the directory memory 31 is changed to "UP" for the status, "0x07e" for the retention node information, "10" for the retention format, and "10" for the number of write-back updates. Update to "0". Moreover, since the message being processed is not a message with block data, it is not written to the main memory 30. When the above processing is completed, the process proceeds to step S153.
【0267】
In step S153, the process ends because the process type is CC.
【0268】
With the above, the home access control unit 27 of the node PE1 ends the processing of the "Ack" message.
【0269】
The home access control unit 27 processes the "Ack" message from each node PEi in the same manner as described above, and updates the value of the directory memory 31 to the value obtained by subtracting "1" from the read holding node information. I will be broken. This process continues until the value obtained by subtracting "1" from the read retention node information is not "0x000", that is, it is not uncached. However, when it becomes uncached, that is, when it receives the last 127th "Ack" message, it operates as follows.
【0270】
First, in step S151, the address "0x000600" (22 bits of the 28th to 7th bits of the address "0x0040030010" added to the message) of the directory memory 31 is accessed, and data such as the status is read out. The read state, holding node information, holding format, and write-back count are updated to "UP", "0x001", "10" (counter format), and "0", respectively, and their values are read. Since the received message type is "Ack", the read state is "UP", the retention format is counter format, and the retention node information is "0x001", which is uncached, processing is performed according to the table in FIG. The type is "CA", the next state of the block is "M", the hold node operation is "set", the number of write-back updates is the same, and the type of message to be output is "CmpSh". When the above processing is completed, the process proceeds to step S152.
【0271】
In step S152, based on this information, the data at the address "0x000600" of the directory memory 31 is written back, the state is "M", the holding node information is "0x002", the holding format is "01" (pointer format), and the data is written back. The number of times is updated to "0". Also, since the message being processed is not a message with block data, it is not written to the main memory 30. When the above processing is completed, the process proceeds to step S153.
【0272】
In step S153, since the processing type is "CA", the process proceeds to step S144.
【0273】
In step S154, a "CmpSh" message is generated. This "CmpSh" message has a destination node number of "0x002", a message type of "CmpSh", an address of "0x0040030010", a mid of "1", and a requesting node number of "0x002" ( Step S144). The output destination of this message is the message transmission unit 35 because the destination node number 0x002 and the node number 0x001 of the node PE1 do not match.
【0274】
With the above, the home access control unit 27 of the node PE1 ends the processing of the "Ack" message.
【0275】
(5) CmpSh message processing The above "CmpSh" message is output to the local access control unit 25 of the node PE2 via the message transmission unit 35 of the node PE1, the interconnection network 10, and the message reception unit 36 of the node PE2.
【0276】
Local of node PE2 that received the above "CmpSh" message (destination node number is "0x002", message type is "CmpSh", address is "0x0040030010", mid is "1", requesting node number is "0x002") The access control unit 25 operates as follows according to the flowchart of FIG. First, in step S131, the information of the "1" (= mid) entry in the request management table 24 is read, the access type is the store, the address is "0x0040030010", and the store data is obtained. When the above processing is completed, the process proceeds to step S132.
【0277】
In step S132, since it is not a message with block data, the process proceeds to step S133.
【0278】
In step S133, since it is not an "Ncmp" message, the process proceeds to step S137.
【0279】
In step S137, the process of updating the 64-bit data at address 0x06002 in the cache memory 21 to the store data obtained from the request management table 24 is performed. In addition, the data with the valid bit set to "0" is written to the "1" (= mid) entry in the request management table 24, and the entry is deleted. In addition, the data at address "0x0600" in the tag memory 22 is in the state "D" and the tag address is "0x00400" according to the table in FIG. 11 (b) (the 39th bit to the 39th bit of the address 0x0040030010 obtained from the request management table). Update to 20 bits (20 bits). It also outputs mid to the processor and notifies that memory access with id = "1" has been completed. When the above processing is completed, the process proceeds to step S138.
【0280】
In step S138, since the received message is CmpSh (step S138), the local access control unit 25 proceeds to step S161 of the flowchart of FIG. 11A and starts the write-back process.
【0281】
In step S141, it is checked whether or not write-back is requested by the write-back selection means 26 (step S161). In the initial state, nothing is registered in the address holding means 111 (2-entry FIFO) of the write-back selection means 26, and the write-back requesting means 112 does not issue a request. Therefore, the process proceeds to step S146.
【0282】
In step S146, the local access control unit 25 requests the address registration means 110 of the write-back block selection means 26 to register the address 0x0040030010. The address registration means 110 that has received the request registers the upper 33 bits of the address in the address holding means 111. As a result, one "0x000800600" is registered in the address holding means 111.
【0283】
With the above, the local access control unit 25 ends the processing of the received "CmpSh" message.
【0284】
At this stage, the latest data for addresses "0x0040030000" to "0x004003007f" exists only in the cache memory 21 of node PE2.
【0285】
Four. Phase 4 When processor 20 of node PE1 makes load access to the address "0x0040040000", the same processing as the operation shown in Phase 1 is performed. Next, when the processor 20 of the node PE2 makes a load access to the address "0x0040040000", the same processing as the operation shown in the phase 2 is performed. Next, when the processor 20 of the node PE2 makes a store access to the address "0x0040040010", the same processing as the operation shown in the phase 3 is performed. As a result, the address holding means 111 of the write-back block selection means 26 of the node PE2 has the addresses "0x0008006 00" (upper 33 bits of the address "0x0040030010") and "0x000800800" (upper 33 bits of the address "0x0040040000"). Two will be registered.
【0286】
The same processing as above is performed at another address (for example, "0x0040050000"), a "CmpSh" message is generated from the store access performed by the node PE2, and the local access control unit 25 of the node PE2 displays FIGS. 9 and 10 It is assumed that the processing is performed according to the flowchart of. At this time, two addresses are registered in the address holding means 111 of the write-back selection means 26, and they are in the full state. Therefore, the write-back requesting means 112 requests the local access control unit 25 to write back the address 0x0040030000 (40 bits in which 7 bits 0 are added to the lower ranks of 33 bits of 0x000800600).
【0287】
(1) CmpSh message processing The local access control unit 25 receives and processes the CmpSh message, and proceeds to step S141.
【0288】
In step S141, since the write-back requesting means 112 of the write-back selection means 26 requests write-back, the process proceeds to step S142.
【0289】
In step S142, the tag memory 22 is accessed using the 13 bits (0x0600) from the 19th bit to the 7th bit (0x0600) of the address "0x0040030000" output by the write-back request means 112 as an index to obtain the state and the tag address (step S162). ). In Phase 3, the state and tag address are updated to "D" and "0x00400", respectively, and their values are read out. When the above processing is completed, the process proceeds to step S143.
【0290】
In step S143, since the state is "D" and the upper 20 bits of the address "0x0040030000" output by the write-back requesting means 112 match, it is determined that write-back is necessary, and the process proceeds to step S144.
【0291】
In step S144, the data of the corresponding block is read from the cache memory 21 in order to write back. The block data to be read is 64 bits x 16 entries = 128 bytes from the address "0x06000" to the address "0x0600f". The read block data is added to the generated "RpBack" message. In the generated "RpBack" message, the destination node number is "0x001" (the upper 10 bits of the address output by the write-back block request means 112). G), the message type is "RpBack", the address is "0x0040030000", the request source node number is "0x002", mid is an arbitrary value, and the block data is the block data read from the cache memory 21 earlier. The output destination of this "RpBack" message is the message transmission unit 35 because the destination node number "0x001" and the node number "0x002" of the node PE2 are different. Also, the data at address "0x0600" in the tag memory 22 is updated with the status "S" and the tag address to the tag address read in step S142. When the above processing is completed, the process proceeds to step S145.
【0292】
In step S145, the address deletion means 113 of the write-back block selection means 26 is requested to delete the address currently requested by the write-back request means 112. Upon receiving the request, the write-back request means 112 deletes the address "0x000800600" from the address holding means 111. As a result, one address "0x000800800" is registered in the address holding means 111. When the above processing is completed, the process proceeds to step S146.
【0293】
In step S146, the local access control unit 25 requests the address registration means 110 of the write-back block selection means 26 to register the address "0x0040050000" of the message "CmpSh" currently being processed. Upon receiving the request, the address registration means 110 registers the upper 33 bits "0x000800A00" of the address "0x0040050000" in the address holding means 111. As a result, "0x000800800" and "0x000800A00" are registered in the address holding means 111 (step S166).
【0294】
With the above, the local access control unit 25 of the node PE2 ends the processing of the "CmpSh" message.
【0295】
(2) RpBack message processing The "RpBack" message output by the local access control unit 25 of the node PE2 to the message transmission unit 35 is passed to the message reception unit 36 of the node PE1 through the interconnect network 10. When the message receiving unit 36 receives the "RpBack" message, it outputs it to the home access control unit 27.
【0296】
Home access control of node PE1 that received the above "RpBack" message (destination node number is "0x001", message type is "RpBack", address is "0x0040030000", requesting node number is "0x002", and block data) Part 27 operates as follows according to the flowchart of FIG.
【0297】
First, in step S151, the address "0x000600" (22 bits of the 28th to 7th bits of the address "0x0040030000" added to the message) of the directory memory 31 is accessed, and data such as the status is read out. In phase 3, the status, retention node information, retention format, and write-back count are updated to "M", "0x002", "01" (pointer format), and "0", respectively, and their values are read out. Since the type of the received message is "RpBack" and the read state is "M", the processing type is "CC", the next state of the block is "C", and the hold node operation is "M" according to the table in Fig. 13. Determine "none" and the number of writebacks to "+1". When the above processing is completed, the process proceeds to step S152.
【0298】
In step S152, based on this information, the data at the address "0x000600" of the directory memory 31 is written back, the state is "C", the holding node information is "0x002", the holding format is "01" (pointer format), and the data is written back. The number of times is updated to "1". Here, since the message has data, the block data added to the message is written from the address "0x0006000" to the address "0x000600f" in the main memory. As a result, the latest data also exists in the main memory 30 of the node PE1. When the above processing is completed, the process proceeds to step S153.
【0299】
In step S153, the processing type is "CC".
【0300】
With the above, the home access control unit 27 of the node PE1 ends the processing of the "RpBack" message.
【0301】
At this stage, the latest data from addresses "0x0040030000" to "0x004003007f" exists in the main memory 30 of the node PE1 in addition to the cache memory 21 of the node PE2.
【0302】
Subsequent operations will be described separately for the case where the node PE1 makes load access to the address "0x0040030000" again and the case where it does not. First, the operation when performing load access will be described.
【0303】
Five. Phase 5A (1) Load access processing Assume that processor 20 of node PE1 makes load access to address "0x0040030000" with id = "0".
【0304】
The local access control unit 25 that has received the memory access performed by the processor 20 operates as follows according to the flowchart of FIG. 8A.
【0305】
First, in step S111, the data at the address "0x0600" of the tag memory 22 (13 bits of the 19th to 7th bits of the address "0x0040030000" obtained from the processor 20) is read. The state and tag address have been updated to "I" and "0x00400" in Phase 3 and their values are read out. From this value, the processing type is determined to be "AA", the message to be issued is determined to be "BlkRdSh", and the next state of the block is determined to be "I" according to the table in Fig. 8 (b). When the above processing is completed, the process proceeds to step S112.
【0306】
In step S112, since the processing type is AA, the process proceeds to step S113.
【0307】
In step S113, message generation output and registration in the request management table 24 are performed. The destination node number of the generated and output message is "0x001" (10 bits of the 39th to 30th bits of the address "0x0040030000"), the message type is "BlkRdSh", the address is "0x0040030000", and the mid is "0". (= id), the request source node number is "0x001". Further, since the destination node number and the node number of the node PE1 both match "0x001", the output destination is the home access control unit 27 of the node PE1. Also, write the data that the valid bit is "1", the access type is load, and the address is "0x0040030000" in the "0" (= id) entry of the request management table 24. When the above processing is completed, the process proceeds to step S118.
【0308】
In step S118, the data of the entry at address "0x0600" in the tag memory is updated to the state "I" and the tag address to 0x00400 (20 bits of the 39th to 20th bits of the address 0x0040030000).
【0309】
With the above, the local access control unit 25 of the node PE1 ends the processing of the received load access.
【0310】
(2) Send BlkRdSh message Home of node PE1 that received the above "BlkRdSh" message (destination node number is "0x001", message type is "BlkRdSh", address is "0x0040030000", mid is "0", requesting node number is "0x001") The access control unit 27 operates as follows according to the flowchart of FIG. 12 (a).
【0311】
First, in step S151, the address "0x000600" (22 bits of the 28th to 7th bits of the address "0x0040030000" added to the message) of the directory memory 31 is accessed, and data such as the status is read out. The read state, retention node information, retention format, and write-back count are updated to "C", "0x002", "01" (pointer type), and "1" in Phase 4, respectively, and their values are read. Since the received message type is "BlkRdSh", the read state is "C", the retention format is pointer format and the retention node information is "0x002", and it is not uncached, the processing type is according to the table in Fig. 13. Is "CB", the next state of the block is "C", the hold node operation is "add", the writeback count is "0", and the output message type is "CmpDatSh". When the above processing is completed, the process proceeds to step S152.
【0312】
In step S152, based on this information, the data at address "0x000600" in the directory memory 31 is written back, the state is "C", the holding node information is "0x001", the holding format is "00" (course vector), and so on. The number of times is updated to "0". When the above processing is completed, the process proceeds to step S153.
【0313】
In step S153, since the processing type is "CB", the process proceeds to step S155.
【0314】
In step S155, block data of 64 bits × 16 entries = 128 bytes from the address 0x0006000 to the address 0x000600f of the main memory 30 is read, added to the generated message, and output. For this message, the destination node number is "0x001", the message type is "CmpDatSh", the address is "0x0040030000", the mid is "0", the requesting node number is "0x001", and the block data is read in step S155. This is a message to be block data (step S145). Since the destination node number and the node number of the node PE1 match, the output destination of this message is the local access control unit 25 of the node.
【0315】
With the above, the home access control unit 27 ends the processing of the "BlkRdSh" message.
【0316】
(3) CmpdatSh message processing Row of node PE1 that received the above "CmpDatSh" message (destination node number is "0x001", message type is "CmpDatSh", address is "0x0040030000", mid is "0", requesting node number is "0x001") The cal access control unit 25 operates as follows according to the flowchart of FIG.
【0317】
First, in step S131, the information of the "0" (= mid) entry in the request management table 24 is read, and the information that the access type is load and the address is "0x0040030000" is obtained. When the above processing is completed, the process proceeds to step S132.
【0318】
In step S132, since the message has block data, the process proceeds to step S135.
【0319】
In step S153, the block data added to the message is written from the address "0x06000" to the address "0x0600f" of the cache memory 21. When the above processing is completed, the process proceeds to step S136.
【0320】
In step S136, since the access type is load, in step S139, the 64-bit data at address "0x06000" is read from the cache memory 21 and passed to the processor 20 as response data for the memory access with id = "0". This completes the memory access. Also, write the data with the valid bit set to "0" in the "0" entry of the request management table, and delete the entry. In addition, the state of address "0x0600" and the tag address of the tag memory are updated to "S" and "0x00400" according to the table in FIG. 11, respectively.
【0321】
With the above, the local access control unit 25 of the node PE1 ends the processing of the received "CmpDatSh" message.
【0322】
At this stage, the latest data exists in the cache memory 21 and main memory 30 of node PE1 and the cache memory 21 of node PE2 for addresses "0x0040030000" to "0x004003007f".
【0323】
By writing the block back from the cache memory 21 of the node PE2 to the main memory 30 of the node PE1, the load access from the node other than the node PE2 (here, the node PE1) that already holds the data is received by the node PE1. It is possible to read data directly from the main memory 30 and respond. If the write-back is not performed, the data is requested to be written back to the node PE2 via the node PE1, and the data is returned after receiving the write-back.
【0324】
As is clear from this, the multiprocessor system of the first embodiment of the present invention has the effect of reducing the latency of load access.
【0325】
Next, the operation when a node other than the node PE2 does not access the block including the address "0x0040030000" and only the node PE2 repeats the access will be described.
【0326】
6. Phase 5B (1) Store access processing The operation when the processor 20 of the node PE2 makes a store access to the address "0x0040030020" again with id = "1" will be described.
【0327】
The local access control unit 25 that has received the memory access performed by the processor 20 operates as follows according to the flowchart of FIG. 8A.
【0328】
First, in step S111, the data at address "0x0600" in the tag memory 22 is read. In Phase 4, the state is updated to "S" and the tag address is updated to "0x00400", and the value is read out. Since the access type is store, the tag address matches "0x00400", and the status is "S", the processing type is "AA" and the output message type is "Upgrade" according to the table in Fig. 8 (b). , The next state of the block is determined to be "S". When the above processing is completed, the process proceeds to step S112.
【0329】
In step S112, since the processing type is AA, the process proceeds to step S113.
【0330】
In step S113, message generation output and registration in the request management table 24 are performed. The destination node number of the generated and output message is "0x001" (10 bits of the 39th to 30th bits of the address "0x0040030020"), the message type is "Upgrade", the address is "0x0040030020", and the mid is "1". , The request source node number is "0x002". Further, since the destination node number and the node number of the node PE2 are different, the output destination is the message transmission unit 35. At this time, the valid bit is "1", the access type is store, the address is "0x0040030020", and the store data is written in the entry "1" (= id) of the request management table 24. When the above processing is completed, the process proceeds to step S118.
【0331】
In step S118, the data of the entry at address "0x0600" in the tag memory is updated to the state "S" and the tag address "0x00400" (20 bits of the 39th to 20th bits of the address "0x0040030020"). ..
【0332】
With the above, the local access control unit 25 of the node PE2 ends the store access process.
【0333】
(2) Upgrade message processing The above "Upgrade" message is sent to the home access control unit 27 of the node PE1 via the message transmission unit 35 of the node PE2, the interconnection network 10, and the message reception unit 36 of the node PE1.
【0334】
Home of node PE1 that received the above "Upgrade" message (destination node number is "0x001", message type is "Upgrade", address is "0x0040030020", mid is "1", requesting node number is "0x002") The access control unit 27 operates as follows.
【0335】
First, in step S151, the address "0x000600" (22 bits of the 28th to 7th bits of the address "0x0040030020" added to the message) of the directory memory 31 is accessed, and data such as the status is read out. In Phase 4, the status, retention node information, retention format, and writeback count are updated to "C", "0x002", "01" (pointer format), and "1", respectively, and their values are read out. The type of message received is "Upgrade", the read state is "C", the retention format is pointer format, the retention node information is "0x002" and uncached, and the number of writebacks and threshold value "1". Therefore, according to the table in Fig. 12 (b), the processing type is "CA", the next state of the block is "M", the hold node operation is "none", the writeback update count is the same, and the type of message to be output. Is determined to be "CmpEx". When the above processing is completed, the process proceeds to step S152.
【0336】
In step S152, based on this information, the data at the address "0x000600" of the directory memory 31 is written back, the state is "M", the holding node information is "0x002", the holding format is "01" (pointer format), and the data is written back. The number of times is updated to "1". Also, since the message being processed is not a message with block data, it is not written to the main memory 30. When the above processing is completed, the process proceeds to step S153.
【0337】
In step S153, since the processing type is "CA", the process proceeds to step S154.
【0338】
In step S154, a "CmpEx" message is generated. This "CmpEx" message has a destination node number of "0x002", a message type of "CmpEx", an address of "0x0040030020", a mid of "1", and a requesting node number of "0x002" (step). S144). The output destination of this message is the message transmission unit 35 because the destination node number 0x002 and the node number 0x001 of the node PE1 do not match. With the above, the home access control unit 27 of the node PE1 ends the processing of the "Upgrade" message.
【0339】
(3) CmpEx message processing The above "CmpEx" message is output to the local access control unit 25 of the node PE2 via the message transmission unit 35 of the node PE1, the interconnection network 10, and the message reception unit 36 of the node PE2.
【0340】
Local of node PE2 that received the above "CmpEx" message (destination node number is "0x002", message type is "CmpEx", address is "0x0040030020", mid is "1", requesting node number is "0x002") The access control unit 25 operates as follows according to the flowchart of FIG. First, in step S131, the information of the 1 (= mid) entry in the request management table 24 is read, the access type is the store, the address is "0x0040030020", and the store data is obtained. When the above processing is completed, the process proceeds to step S132.
【0341】
In step S132, since it is not a message with block data, the process proceeds to step S133.
【0342】
In step S133, since it is not an NCmp message, the process proceeds to step S137.
【0343】
In step S137, the process of updating the 64-bit data at address "0x06004" (17 bits from the 19th bit to the 3rd bit of the address "0x0040030020") of the cache memory 21 to the store data obtained from the request management table 24 is performed. Do. Also, write the data with the valid bit set to "0" in the "1" (= mid) entry of the request management table, and delete the entry. In addition, the data at address "0x0600" in the tag memory 22 is in the state "D" according to the table in FIG. 11 (b), and the tag address is "0x00400" (the 39th bit of the address "0x0040030020" obtained from the request management table 24". ~ Update to the 20th bit (20 bits). It also outputs mid to the processor and notifies that memory access with id = "1" has been completed. When the above processing is completed, the process proceeds to step S138.
【0344】
The message received in step S138 is neither "CmpSh" nor "CmpDatSh".
【0345】
With the above, the local access control unit 25 of the node PE2 ends the processing of the received "CmpEx" message.
【0346】
At this stage, the latest data for addresses "0x0040030000" to "0x004003007f" exists only in the cache memory 21 of node PE2.
【0347】
When the threshold value is set to "1" in this way, from one write-back from the same node PEi (here, node PE2) to the next write-back from another node on node PE2. If there is no access, the data is stopped from being rewritten to the main memory 30 of the node PE1 and is excluded from the target of the write-back block.
【0348】
In addition, by setting the threshold value, it is possible to change how many times the write-back is received before the write-back block is excluded.
【0349】
As described above, according to this embodiment, it is possible to prevent unnecessary writing back to the main memory 30 from occurring.
【0350】
The present invention is not limited to that described in the first embodiment described above, and various modifications are possible.
【0351】
Next, a second embodiment of the present invention will be described.
【0352】
FIG. 14 is a block diagram showing a configuration of a loosely coupled multiprocessor system 1'related to a second embodiment of the present invention.
【0353】
This embodiment also makes it possible to configure a multiprocessor system that does not have the directory memory 31. In this case, the information stored in the directory memory 31 may be stored in the area (directory area) of the main memory 30. The access made by the home access control unit 27 to the directory memory 31 is realized by accessing the directory area of the main memory 30.
【0354】
Since the other configurations are the same as those of the first embodiment shown in FIG. 1, they are shown with the same reference numerals as those in FIG.
【0355】
The types and configurations of the messages in the first and second embodiments can be variously modified as long as they can accurately convey the processing request and response between the node PEi. In particular, for requests between the same nodes (access requests, etc.), the request is transmitted by sending a predetermined signal via a signal line provided in the node without taking the form of a message. May be good.
【0356】
In the first and second embodiments described above, the functions of the local access control unit 25 and the home access control unit 27 included in the consistency maintenance control unit 16 may be realized by any of the following. Good.
【0357】
(a) Execution of a processing program (or a program stored in the instruction cache) stored in the main memory 30 by the processor 20.
【0358】
(b) Execution of a processing program stored in dedicated memory by a dedicated subprocessor provided separately from processor 20 and main memory 30 (or instruction cache).
【0359】
(c) Dedicated hardware configured according to the logic to implement the functionality of each module.
【0360】
The multiprocessor system shown in the first and second embodiments above was composed of 1024 nodes PE0 to PE1023 connected to each other via one interconnect network 10. However, in this embodiment, the number of nodes is arbitrary. Further, it may have a redundant configuration in which there are a plurality of interconnect networks. In this case, a plurality of interconnect networks can be used for system failure countermeasures.
【0361】
As described above, according to this embodiment, it is possible not only to simplify the device configuration but also to prevent unnecessary writing back to the main memory 30 at the same time.
【0362】
Although the embodiments of the present invention have been described above, it goes without saying that the present invention is not limited to the above-described embodiments and can be modified in various ways.
【0363】
[Effect of the invention]
As described above, according to the present invention, the following remarkable effects are obtained.
【0364】
(1) When the processor writes to the shared block, the cache memory of the node is occupied. Such a block is written back to the main memory by the write-back block selection means and the local access control unit of the node. With this function, when a processor of another node makes a load access to the block, the block can be read from the main memory instead of the cache memory of the node that has been occupied, so that the latency of the load access can be shortened.
【0365】
(2) Have information indicating whether or not it is shared in the directory memory. Based on that information, the response message sent by the home access control unit that received the write request to the node that issued the request has information on whether or not it was shared. The local access control unit that receives the response message decides whether or not to target the block to be written back selected by the write-back block selection means, depending on whether or not it was shared. With the above function, it is possible to prevent writing back for blocks that are not shared.
【0366】
(3) Give the directory memory information that can identify the number of times the block has been written back, and if there is only one node that actually holds the block even if it is in a state indicating that it is shared. .. In addition, the home access control unit is provided with a threshold value for determining how many times write-back is allowed. Based on this information, even if the home access control unit that received the write request indicates that the state of the block is shared, only the node that issued the request holds the block. If the threshold value and the number of times the write-back is received match, the response message is provided with information indicating that it is not shared, and the write-back block selection means is excluded. With the above function, it is possible to detect that the shared block is no longer shared with the passage of time, prevent unnecessary write-back, and prevent the number of messages from being increased due to write-back.
[Simple explanation of drawings]
[Figure 1]
It is a block diagram which shows the structure of the loosely coupled multiprocessor system which concerns on 1st Example of this invention.
[Figure 2]
It is a block diagram which shows the internal structure of the node shown in FIG.
[Fig. 3]
(a) is a diagram showing a request message sent from a node in which memory access is performed to a node that holds data in main memory, and (b) is a diagram showing the data from a node that holds data in main memory. It is a figure which shows the request message sent to the node which holds a copy in cache memory, (c) is the report which is sent from the node which holds a copy of data in cache memory to the node which holds data in main memory. It is a figure which shows the message, (d) is a figure which shows the memory access completion message sent from the node which holds the data in the main memory to the node which made the memory access.
[Fig. 4]
It is a figure which shows the internal structure of the write-back block control means. ..
[Fig. 5]
(a) is a diagram showing the structure of a message with block data, and (b) is a diagram showing the structure of a basic message.
[Fig. 6]
It is a figure which shows the state of a directory memory, a tag memory, and this memory block.
[Fig. 7]
It is a figure which shows the state transition of the node of this embodiment and the main memory and the cache memory which are the constituent elements thereof.
[Fig. 8]
(a) is a flowchart showing the process executed by the local access control unit in response to the memory access output by the processor, and (b) is the process type, message type, and block next to the process in (a). It is a table showing the relationship of states, etc. [Fig. 9]
(a) is a flowchart showing the processing executed by the local access control unit when three types of messages, IntvSh, IntvEx, and Upgrade, are received from the messages output by the home access control unit or the message receiving unit. (b) is a table showing the relationship between the processing type, the message type, the next state of the block, etc. in the processing of (a).
[Fig. 10]
It is a flowchart which shows the process which a local access control part executes when the home access control part or a message receiving part receives five kinds of messages of CmpDatSh, CmpDatEx, CmpSh, CmpEx, NCmp.
[Fig. 11]
(a) is a process executed by the local access control unit when receiving five types of messages, CmpDatSh, CmpDatEx, CmpSh, CmpEx, and NCmp, among the messages output by the home access control unit or the message reception unit. It is a flow chart which shows, and (b) is a table which shows the relationship such as the processing type, the message type, the next state of a block in the processing of FIGS. 10 and 11 (a).
[Fig. 12]
(a) is a flowchart showing the processing executed by the home access control unit, and (b) is a table showing the relationship between the processing type, the message type, the next state of the block, etc. in the processing of (a).
[Fig. 13]
Whether the type of received message, the state of the block read from the directory memory, the uncached information obtained from the holding format and the holding node information, the number of writes back, and the threshold value used in the processing of the flowchart of FIG. 12 (a) match. It is a table showing the four pieces of information, the state of the block stored in the directory memory, the operation for the retained node information, the operation for the number of writes back, the processing type, and the message type.
[Fig. 14]
It is a block diagram which shows the structure of the loosely coupled multiprocessor system which concerns on 2nd Example of this invention.
[Fig. 15]
It is a block diagram which shows the structure of the conventional multiprocessor system.
[Fig. 16]
(a) is a diagram showing a state in which a copy of data exists in the main memory of a plurality of nodes, and (b) is a diagram showing a state in which a copy of data exists in the main memory of only one node. ..
[Fig. 17]
(a) is a diagram showing a state in which there is no consistent and valid data in the cache memory of a plurality of nodes, and (b) is a diagram in which a valid copy of the data exists and the other nodes have. It is a diagram showing a state in which valid data may also exist in the cache memory, and (c) shows that a valid copy of the data exists in only one node and is valid in the cache memory of the other nodes. It is a figure which shows the state that the copy does not exist, and the data of a main memory and the data of a cache memory are different.
[Explanation of symbols]
PE0 ~ PEn-1, PE0'~ PEn-1'node 10 interconnect network 16 Consistency maintenance control unit 20 processors 21,42 Cache memory 22 Tag memory 24 Request management table 25 Local access control unit 26 Writeback block selection method 27 Home access control unit 30,41 Main memory 31 directory memory 35 Message transmitter 36 Message receiver 40 node PEi 55 Consistency control unit 110 Address registration method 111 Address retention means 112 Write-back request means 113 Address deletion method 1
18 sheets
Sheet 1 Sheet 2 Sheet 3 Sheet 4 Sheet 5 Sheet 6 Sheet 7 Sheet 8 Sheet 9 Sheet 10 Sheet 11 Sheet 12 Sheet 13 Sheet 14 Sheet 15 Sheet 16 Sheet 17 Sheet 18
Every citation, both ways
| Document | Relation | Office | Cited during |
|---|---|---|---|
| US7181292B2 | Cited by | United States of America | Applicant |
| US7904665B2 | Cited by | United States of America | Applicant |
| EP2784684A1 | Cited by | European Patent Office (EPO) | Applicant |
2 members in 1 office
Priority claims2
| Document | Office | Kind | Date |
|---|---|---|---|
| 6190599 | Japan | A | |
| JP19990061905 | – | – | – |
Members2
| Document | Office | Kind | |
|---|---|---|---|
| JP2000259596AThis record | Japan | A | |
| JP3769411B2 | Japan | B2 |
14 legal events, as the office reported them to INPADOC
Over the term
Point at a mark for the eventEvents
| Event | Code | |
|---|---|---|
| Cancellation because of no payment of annual feesLAPS | LAPS | |
| Renewal fee payment (event date is renewal date of database)FPAY | FPAY | |
| Renewal fee payment (event date is renewal date of database)FPAY | FPAY | |
| Renewal fee payment (event date is renewal date of database)FPAY | FPAY | |
| Renewal fee payment (event date is renewal date of database)FPAY | FPAY | |
| Renewal fee payment (event date is renewal date of database)FPAY | FPAY | |
| Renewal fee payment (event date is renewal date of database)FPAY | FPAY | |
| Renewal fee payment (event date is renewal date of database)FPAY | FPAY | |
| Renewal fee payment (event date is renewal date of database)FPAY | FPAY | |
| Renewal fee payment (event date is renewal date of database)FPAY | FPAY | |
| Certificate of patent or registration of utility modelJAPANESE INTERMEDIATE CODE: R150R150 | R150 | |
| First payment of annual fees (during grant procedure)JAPANESE INTERMEDIATE CODE: A61A61 | A61 | |
| Written amendmentJAPANESE INTERMEDIATE CODE: A523A521 | A521 | |
| Notification of change of attorneyJAPANESE INTERMEDIATE CODE: A7421RD01 | RD01 |
Numbers
- Publication
- 2000-259596
- Publication, DOCDB
- 2000259596
- Publication, EPODOC
- JP2000259596
- Application
- 11061905
- Application, DOCDB
- 6190599
- Application, EPODOC
- JP19990061905
Titles2
- Japanese
- マルチプロセッサシステムおよびマルチプロセッサシステムにおけるデータの一貫性維持方法
- English
- Description: A method for maintaining data consistency in a multiprocessor system and a multiprocessor system
Classification
- IPC, 3
- G06F12 08
- G06F15 16
- G06F15 177