JP2870202B2 - Method and apparatus for mutual monitoring between processors - Google Patents

Method and apparatus for mutual monitoring between processors

Info

Publication number
JP2870202B2
JP2870202B2 JP3036275A JP3627591A JP2870202B2 JP 2870202 B2 JP2870202 B2 JP 2870202B2 JP 3036275 A JP3036275 A JP 3036275A JP 3627591 A JP3627591 A JP 3627591A JP 2870202 B2 JP2870202 B2 JP 2870202B2
Authority
JP
Japan
Prior art keywords
processor
common memory
data
processors
memory
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP3036275A
Other languages
Japanese (ja)
Other versions
JPH04275664A (en
Inventor
茂 神谷
孝之 戸田
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Fuji Electric Co Ltd
Original Assignee
Fuji Electric Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Fuji Electric Co Ltd filed Critical Fuji Electric Co Ltd
Priority to JP3036275A priority Critical patent/JP2870202B2/en
Publication of JPH04275664A publication Critical patent/JPH04275664A/en
Application granted granted Critical
Publication of JP2870202B2 publication Critical patent/JP2870202B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Description

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

【0001】[0001]

【産業上の利用分野】本発明は、複数のプロセッサから
なるコンピュータシステムにおけるプロセッサ相互間の
監視方法及びその装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a method and an apparatus for monitoring between processors in a computer system comprising a plurality of processors.

【0002】[0002]

【従来の技術】複数のプロセッサからなるコンピュータ
システムでは、通常個々のプロセッサが自己診断機能を
有しており、自己の異常を検出したときには、異常の発
生を他のプロセッサに通知するようになっている。
2. Description of the Related Art In a computer system composed of a plurality of processors, each processor usually has a self-diagnosis function. When a self-abnormality is detected, the occurrence of the abnormality is notified to another processor. I have.

【0003】この自己診断機能により、例えばある機械
を制御するコンピュータシステムにおいて、制御を行っ
ているプロセッサが自己の異常を検出すると、他のプロ
セッサに異常の発生が通知され、正常に動作している他
のプロセッサが機械を安全に停止させることができる。
With this self-diagnosis function, for example, in a computer system that controls a certain machine, when a controlling processor detects its own abnormality, the other processor is notified of the occurrence of the abnormality and operates normally. Other processors can safely shut down the machine.

【0004】しかしながら、例えばプロセッサ自身が動
作を停止してしまうような故障では、当然のことながら
自己診断機能も働かなくなってしまうので、他のプロセ
ッサは異常の発生を知ることができないという問題点が
あった。
However, for example, in the case of a failure in which the processor itself stops operating, the self-diagnosis function does not work, of course, so that another processor cannot know the occurrence of the abnormality. there were.

【0005】そこで、従来、複数のプロセッサ間で相互
に動作の監視を行い、1つのプロセッサが故障して自己
診断機能が動作しない場合でも、他のプロセッサがその
プロセッサの異常を検出できるようにしている。
Therefore, conventionally, the operation of a plurality of processors is mutually monitored so that even if one processor fails and the self-diagnosis function does not operate, another processor can detect the abnormality of the processor. I have.

【0006】以下、少なくとも2個のプロセッサA、B
と、それらのプロセッサによりアクセスされる共通メモ
リC、Dとで構成されるマルチプロセッサシステムを例
にとり、従来の相互監視方法を説明する。
Hereinafter, at least two processors A and B
A conventional mutual monitoring method will be described using an example of a multiprocessor system composed of the common memories C and D accessed by these processors.

【0007】図11〜図15は、従来の相互監視方法に
おけるプロセッサA及びプロセッサBの処理内容を示す
フローチャートである。このプロセッサシステムでは、
プロセッサAにおいて周期t0 、t1 毎に相互監視の為
のプログラムA−1、A−2が実行され、プロセッサB
において周期t 2 、t3 毎に相互監視の為のプログラム
B−1、B−2が実行される。
FIGS. 11 to 15 show a conventional mutual monitoring method.
The processing contents of the processor A and the processor B in FIG.
It is a flowchart. In this processor system,
Period t in processor A0, T1For mutual monitoring every time
Are executed, and the processor B is executed.
At the period t Two, TThreeA program for mutual monitoring every time
B-1 and B-2 are executed.

【0008】先ず、図11及び図12を参照してプロセ
ッサA側での処理を説明する。プロセッサAでは、周期
0 毎に図11に示すプログラムA−1が起動される。
このプログラムA−1では、図11のステップS1に示
すように共通メモリCを「0」にクリアする。
First, the processing on the processor A side will be described with reference to FIGS. The processor A, the program A-1 shown in FIG. 11 every period t 0 is activated.
In the program A-1, the common memory C is cleared to "0" as shown in step S1 of FIG.

【0009】さらに、プロセッサAでは、周期t1 毎に
図12に示すプログラムA−2が起動される。このプロ
グラムA−2では、ステップS2で共通メモリCのデー
タを読み出し、次のステップS3で今回読み出したデー
タと前回読み出したデータとが一致するか否かを判別す
る。
Furthermore, the processor A, the program A-2 shown in FIG. 12 for each period t 1 is started. In the program A-2, the data in the common memory C is read in step S2, and it is determined in next step S3 whether the data read this time matches the data read last time.

【0010】データが一致しないときは、共通メモリC
が、後述するプロセッサB側のプログラムB−1により
「1」づつインクリメントされている場合であり、この
場合には、ステップS4でプロセッサBが正常に動作し
ているものと判断して、処理を終了させる。
If the data does not match, the common memory C
Is incremented by "1" by a program B-1 on the processor B side, which will be described later. In this case, in step S4, it is determined that the processor B is operating normally, and the processing is performed. Terminate.

【0011】他方、ステップS3の判別で今回読み出し
たデータと前回読み出したデータとが一致した場合には
ステップ5で、プロセッサBに何らかの異常が発生して
共通メモリCのデータがインクリメントされなかったも
のと判断して、処理を終了させる。
On the other hand, if it is determined in step S3 that the data read this time matches the data read last time, it is determined in step 5 that the data in the common memory C has not been incremented due to some abnormality in the processor B. And terminate the process.

【0012】次に、プロセッサB側での処理を図13及
び図14を参照して説明する。プロセッサBでは、周期
2 毎に図13に示すプログラムB−1が実行される。
このプログラムB−1では、図13のステップS6で共
通メモリCのデータを読み出し、次のステップS7でそ
の値をインクリメントする。さらに、ステップS8でそ
のインクリメントしたデータを共通メモリCに書き込
む。
Next, processing on the processor B side will be described with reference to FIGS. The processor B, program B-1 shown in FIG. 13 every cycle t 2 is executed.
In the program B-1, the data in the common memory C is read in step S6 in FIG. 13, and the value is incremented in the next step S7. Further, in step S8, the incremented data is written to the common memory C.

【0013】また、プロセッサBでは、周期t3 毎に図
14に示すプログラムB−2が実行される。このプログ
ラムB−2では、図14のステップS9で共通メモリC
のデータを読み出し、次のステップS10でそのデータ
が規定値未満か否かを判別する。
In the processor B, a program B-2 shown in FIG. 14 is executed every cycle t 3 . In the program B-2, the common memory C in step S9 in FIG.
Is read, and it is determined in the next step S10 whether or not the data is less than a specified value.

【0014】共通メモリCのデータが規定値未満のとき
は、上述したプロセッサB側のプログラムB−1により
「1」づつインクリメントされる共通メモリCの内容
が、プロセッサA側のプログラムA−1により周期t0
毎にクリアされている場合である。
When the data in the common memory C is less than the specified value, the contents of the common memory C incremented by "1" by the above-mentioned program B-1 on the processor B side are changed by the program A-1 on the processor A side. Period t 0
This is the case when it is cleared every time.

【0015】この場合には、ステップS11でプロセッ
サAが正常動作をしているものと判断して、処理を終了
させる。他方、ステップS10の判別で共通メモリCの
データが規定値以上のときは、プログラムA−1が実行
されず共通メモリCがクリアされない状態で、プログラ
ムB−1により共通メモリCのデータがインクリメント
され規定値以上となった場合である。
In this case, it is determined in step S11 that the processor A is operating normally, and the process is terminated. On the other hand, if the data in the common memory C is equal to or more than the specified value in the determination in step S10, the data in the common memory C is incremented by the program B-1 in a state where the program A-1 is not executed and the common memory C is not cleared. This is the case when it exceeds the specified value.

【0016】この場合には、ステップS12でプロセッ
サAに異常が発生したものと判断し、さらに次のステッ
プS13で共通メモリCに上記規定値を書き込み、処理
を終了させる。
In this case, it is determined in step S12 that an error has occurred in the processor A, and the specified value is written to the common memory C in the next step S13, and the process is terminated.

【0017】尚、プログラムB−1の起動周期t2 とプ
ログラムB−2の起動周期t3 とが等しいときには、そ
れらのプログラムを1つにまとめて、図15に示すプロ
グラムB−0を作成することができる。
[0017] Incidentally, when the activation period t 3 of the program B-1 activation period t 2 and Program B-2 are equal, together into one the programs, to create the program B-0 shown in FIG. 15 be able to.

【0018】このプログラムB−0では、ステップS1
4で共通メモリCのデータを読み出し、ステップS15
で読み出したデータが規定値未満か否かを判別する。読
み出したデータが規定値未満であれば、ステップS16
でプロセッサAは正常に動作しているものと判定し、次
のステップS17で共通メモリCのデータを「1」イン
クリメントし、さらにステップS18でそのデータを共
通メモリCに書き込んだ後、処理を終了する。
In this program B-0, step S1
In step S15, the data in the common memory C is read out.
Then, it is determined whether or not the data read out is smaller than a specified value. If the read data is less than the specified value, step S16
Determines that the processor A is operating normally, increments the data in the common memory C by "1" in the next step S17, writes the data in the common memory C in step S18, and ends the processing. I do.

【0019】他方、共通メモリCのデータが規定値以上
場合には、ステップS19でプロセッサAに異常が発
生したものと判定し、次のステップS20で規定値をセ
ットし、さらにステップS18でその規定値を共通メモ
リCに書き込んだ後、処理を終了する。
[0019] On the other hand, data of the common memory C is greater than or equal to the prescribed value
In step S19, it is determined that an error has occurred in the processor A in step S19, a specified value is set in the next step S20, and the specified value is written in the common memory C in step S18, and the process is terminated. I do.

【0020】次に、プロセッサA、Bが正常なとき、あ
るいはプロセッサA又はBに異常が発生したときのプロ
セッサの動作を、図16〜図18の動作タイムチャート
を参照して説明する。
Next, the operation of the processor when the processors A and B are normal or when the processor A or B has an abnormality will be described with reference to the operation time charts of FIGS.

【0021】プロセッサA、Bが正常に動作していると
きには、図16の動作タイムチャートに示すように、プ
ログラムB−1により周期t2 毎に共通メモリCのデー
タが「1」づつ増加し、さらに、プログラムA−1によ
り周期t0 毎に共通メモリCの内容がクリアされる。
[0021] When processor A, B are operating normally, as shown in operation timing chart of FIG. 16, the data of the common memory C every period t 2 by the program B-1 is increased by one "1", Further, the contents of the common memory C are cleared every cycle t 0 by the program A-1.

【0022】このときプロセッサAにおいて周期t1
に実行されるプログラムA−2により、共通メモリCの
値が変化していることが検出できるので、プロセッサB
が正常に動作しているものと判定できる。
At this time, the change in the value of the common memory C can be detected by the program A-2 executed in the processor A at each cycle t 1 , so that the processor B
Can be determined to be operating normally.

【0023】また、図16には示していないが、プロセ
ッサBにおいて周期t3 毎に実行されるプログラムB−
2により、共通メモリCのデータが規定値未満であるこ
とが検出できるので、プロセッサAが正常に動作してい
るものと判定できる。
Further, although not shown in FIG. 16, a program executed in each cycle t 3 in processor B B-
According to 2, it is possible to detect that the data in the common memory C is less than the specified value, so that it can be determined that the processor A is operating normally.

【0024】次に、プロセッサAに異常が発生した場合
の動作を、図17の動作タイムチャートを参照して説明
する。プロセッサAに異常が発生すると、プロセッサB
側のプログラムB−1により共通メモリCの内容はイン
クリメントされるが、プログラムA−1により共通メモ
リCの内容が「0」にクリアされなくなるので、図17
に示すように共通メモリCの値が次第に増大していく。
Next, an operation when an abnormality occurs in the processor A will be described with reference to an operation time chart of FIG. When an error occurs in the processor A, the processor B
Although the contents of the common memory C are incremented by the program B-1 on the side of FIG. 17, since the contents of the common memory C are not cleared to “0” by the program A-1, FIG.
The value of the common memory C gradually increases as shown in FIG.

【0025】その結果、プロセッサBにおいて周期t3
毎に実行されるプログラムB−2により、共通メモリC
の値が規定値以上であることが検出され、プロセッサA
は異常と判定される。
As a result, in the processor B, the period t 3
The common memory C is executed by the program B-2 executed every time.
Is detected to be equal to or greater than the specified value, and the processor A
Is determined to be abnormal.

【0026】次に、プロセッサBに異常が発生した場合
の動作を、図18の動作タイムチャート参照して説明す
る。プロセッサBに異常が発生すると、上述したプログ
ラムB−1により共通メモリCの値がインクリメントさ
れなくなり、図18に示すように共通メモリCの値が一
定値となる。
Next, an operation when an abnormality occurs in the processor B will be described with reference to an operation time chart of FIG. When an abnormality occurs in the processor B, the value of the common memory C is not incremented by the above-described program B-1, and the value of the common memory C becomes a constant value as shown in FIG.

【0027】その結果、プロセッサAで周期t1 毎に実
行されるプログラムA−1により、共通メモリCから今
回読み出したデータと前回読み出したデータとの一致が
検出され、プロセッサBは異常と判定される。
As a result, the coincidence between the data read this time from the common memory C and the data read last time is detected by the program A-1 executed by the processor A every cycle t 1 , and the processor B is determined to be abnormal. You.

【0028】なお、プロセッサBに異常が発生した場合
でも、プロセッサAにより共通メモリCがクリアされる
前後に共通メモリCのデータを読み出して比較したとき
には、今回のデータと前回のデータが一致しないことに
なるので、プロセッサBが正常と判断される場合が起こ
る。
Even if an error occurs in the processor B, when the data in the common memory C is read and compared before and after the common memory C is cleared by the processor A, the present data and the previous data do not match. Therefore, there is a case where the processor B is determined to be normal.

【0029】この場合でも、プログラムA−2での共通
メモリCのデータの比較を複数回繰り返すようにすれ
ば、プロセッサBに異常が発生している場合には、クリ
アした後の共通メモリCの内容が一定値「0」となるの
で、プロセッサBの異常を確実に検出することができ
る。
Even in this case, if the comparison of the data in the common memory C in the program A-2 is repeated a plurality of times, if an abnormality has occurred in the processor B, the data in the common memory C after clearing is cleared. Since the content becomes a constant value “0”, the abnormality of the processor B can be reliably detected.

【0030】なお、各プログラムの起動周期t0
1 、t2 は、次のような関係を満たす必要がある。 t0 >t2 1 >t2 1 ≠n×t0 (n=1、2、・・・) の条件は、正常時に共通メモリCのデータが増えてい
くための条件であり、の条件との条件は、正常時に
共通メモリCの前回の読み出しデータと今回の読み出し
データが一致しない為の条件である。
Note that the starting cycle t 0 of each program,
t 1 and t 2 need to satisfy the following relationship. The condition of t 0 > t 2 t 1 > t 2 t 1 ≠ n × t 0 (n = 1, 2,...) is a condition for increasing the data of the common memory C in a normal state. The condition is a condition that the previous read data of the common memory C does not match the present read data in the normal state.

【0031】[0031]

【発明が解決しようとする課題】しかしながら、上述し
た従来の相互監視方法では、プロセッサAとプロセッサ
Bとが非同期で動作している場合に、例えば図19に示
すタイミングでプログラムが起動すると問題が生じる。
However, in the above-described conventional mutual monitoring method, when the processor A and the processor B are operating asynchronously, a problem arises when the program is started, for example, at the timing shown in FIG. .

【0032】図19に示すように、プロセッサBが共通
メモリCのデータを読み出した直後に、プロセッサAが
共通メモリCを「0」にクリアした場合には、次にプロ
グラムB−1により、読み出したデータがインクリメン
トされ、そのインクリメントされたデータが共通メモリ
Cに書き込まれる。
As shown in FIG. 19, if the processor A clears the common memory C to "0" immediately after the processor B has read the data in the common memory C, then the program B-1 reads the data. The incremented data is incremented, and the incremented data is written to the common memory C.

【0033】この結果、共通メモリCのデータはクリア
されずデータが増え続け、規定値以上となった時点でプ
ログラムB−2によりプロセッサAに異常が発生したも
のと誤って判定されてしまう。
As a result, the data in the common memory C is not cleared, and the data continues to increase. When the data exceeds the specified value, the program B-2 erroneously determines that an abnormality has occurred in the processor A.

【0034】本発明の目的は、複数のプロセッサからな
るシステムにおいて、プロセッサの動作状態を正確に検
出できるプロセッサ間の相互監視方法及びその装置を提
供することである。
An object of the present invention is to provide a method and apparatus for mutual monitoring between processors which can accurately detect the operating state of the processors in a system including a plurality of processors.

【0035】[0035]

【課題を解決するための手段】図1は、本発明の原理説
明図である。複数のプロセッサとその複数のプロセッサ
からアクセス可能な共通メモリC、Dとからなるシステ
に用いられるプロセッサ間相互監視方法であって、複
数のプロセッサの中で互いに動作を監視しているプロセ
ッサA、Bの一方のプロセッサAが、周期t0 毎に共通
メモリDにメッセージを書き込む。さらに、周期t1
に共通メモリCのデータを読み出し、今回読み出したデ
ータと前回読み出したデータとを比較し、データが不一
致であればプロセッサBは正常と判定し、データが一致
すればプロセッサBは異常と判定する。
FIG. 1 is a diagram illustrating the principle of the present invention. An inter-processor mutual monitoring method used in a system including a plurality of processors and common memories C and D accessible from the plurality of processors, wherein processors A and B monitoring the operation among the plurality of processors. Processor A writes a message to the common memory D every cycle t 0 . Further, the data in the common memory C is read every cycle t 1, and the data read this time and the data read last time are compared. If the data does not match, the processor B determines that the data is normal. Is determined to be abnormal.

【0036】他方のプロセッサBが、周期t 1 よりも短
周期t2 毎に共通メモリDのメッセージを読み出し、
プロセッサAからのメッセージの有無を判断し、メッセ
ージが存在する場合には共通メモリCをクリア又は所定
値を設定し、メッセージが存在しない場合には共通メモ
リCのデータをインクリメント又はディクリメントす
る。さらに、共通メモリCのデータと基準値とを比較
し、データが基準値以内であればプロセッサAは正常と
判定し、基準値を越えたならプロセッサAは異常と判定
する
If the other processor B is shorter than the period t 1
Reads the message of the common memory D to have each period t 2,
The presence or absence of a message from the processor A is determined, and if a message exists, the common memory C is cleared or specified.
A value is set, and if there is no message, the data in the common memory C is incremented or decremented. Further, the data in the common memory C is compared with the reference value, and if the data is within the reference value, the processor A is determined to be normal, and if the data exceeds the reference value, the processor A is determined to be abnormal.

【0037】[0037]

【作用】本発明の相互監視方法では、一方のプロセッサ
Aが共通メモリDに所定のメッセージを書き込んだか否
かにより、他方のプロセッサBが共通メモリCのデータ
をクリア、あるいはインクリメント(又はディクリメン
ト)するようにした。
According to the mutual monitoring method of the present invention, the other processor B clears or increments (or decrements) the data in the common memory C depending on whether one processor A has written a predetermined message in the common memory D or not. I did it.

【0038】従って、従来のようにプログラムの起動タ
イミングによって、例えば共通メモリCのデータをイン
クリメント(又はディクリメント)している途中で、そ
の共通メモリCの内容がクリアされるということが発生
せず、プロセッサが正常に動作しているのに、誤って異
常と判定することを防止できる。
Therefore, the contents of the common memory C are not cleared during the increment (or decrement) of the data in the common memory C, for example, by the start timing of the program as in the related art. In addition, it is possible to prevent erroneous determination of an abnormality while the processor is operating normally.

【0039】[0039]

【実施例】以下、本発明の実施例を図面を参照しながら
説明する。図2は、本発明の第1実施例のプロセッサシ
ステムの構成図である。プロセッサカードA(例えば、
プロセッサAが搭載されたボード)と、N枚のプロセッ
サカードB〔以下、このカード上の任意のプロセッサを
プロセッサBM (M=1、2・・・N)と呼ぶ〕と、そ
れらのプロセッサから共通にアクセスされる共通メモリ
カードXとは、それぞれシステムバスEを介して接続さ
れている。
Embodiments of the present invention will be described below with reference to the drawings. FIG. 2 is a configuration diagram of the processor system according to the first embodiment of the present invention. Processor card A (for example,
A board on which a processor A is mounted) and N processor cards B (hereinafter, an arbitrary processor on this card is referred to as a processor B M (M = 1, 2,... N)). The common memory cards X that are commonly accessed are connected via a system bus E, respectively.

【0040】プロセッサカードAとプロセッサカードB
とは、共通メモリカードXを経由して互いのデータを受
け渡しする。共通メモリカードX内には多数のデータ格
納領域があり、このデータ格納領域には、プロセッサA
によりメッセージが書き込まれ、プロセッサBM により
そのメッセージが読み出される共通メモリDと、プロセ
ッサBM によりクリア又はインクリメント(又はディク
リメント)され、プロセッサAによりその内容が読み出
されるN個の共通メモリCM (M=1、2、3・・・
N)等が設けられている。
Processor card A and processor card B
Means that data is exchanged with each other via the common memory card X. There are a number of data storage areas in the common memory card X.
Message is written by a common memory D in which the message is read by the processor B M, cleared or incremented by the processor B M (or decrement), N pieces of the common memory C M, the contents of which are read by the processor A ( M = 1, 2, 3, ...
N) etc. are provided.

【0041】なお、この実施例では、N個のプロセッサ
Bの異常の有無を検出する為にN個の共通メモリCM
設けている。次に、第1実施例のプロセッサA及びBM
で実行される相互監視プログラムについて、図3〜図6
のフローチャートを参照しながら説明する。
In this embodiment, N common memories CM are provided to detect the presence or absence of an abnormality in the N processors B. Next, the processors A and B M of the first embodiment
3 to 6 about the mutual monitoring program executed in
This will be described with reference to the flowchart of FIG.

【0042】図3は、プロセッサAで周期t0 毎に実行
されるプログラムA−1のフローチャートである。この
プログラムA−1は、共通メモリDにメッセージとして
「0」又は「1」を書き込むプログラムである。
FIG. 3 is a flowchart of the program A-1 executed by the processor A every cycle t 0 . The program A-1 is a program for writing “0” or “1” as a message in the common memory D.

【0043】先ず、図3のステップS21で、前回共通
メモリDにメッセージとして「0」を書き込んだか否を
判別する。前回共通メモリDに「0」を書き込んでいる
場合には、ステップS22に進み、今回は共通メモリD
にメッセージとして「1」を書き込む。
First, in step S21 of FIG. 3, it is determined whether or not "0" was previously written in the common memory D as a message. If "0" has been previously written to the common memory D, the process proceeds to step S22, and this time the common memory D
"1" as a message.

【0044】一方、前回共通メモリDに「1」を書き込
んでいる場合には、ステップS23に進み今回は、共通
メモリDにメッセージとして「0」を書き込む。ここ
で、プログラムA−1において、共通メモリDにメッセ
ージとして「0」と「1」を交互に書き込んでいるの
は、プロセッサBM 側でプロセッサAが正常に動作して
いるか否かを判定できるようにする為である。
On the other hand, if "1" was previously written to the common memory D, the process proceeds to step S23, and "0" is written to the common memory D this time as a message. Here, in the program A-1, "0" and "1" are alternately written as a message in the common memory D because it is possible to determine whether the processor A is operating normally on the processor BM side. It is to do so.

【0045】次に、図4は、プロセッサAで周期t1
に実行されるプログラムA−2のフローチャートであ
る。このプログラムA−2は、共通メモリCM から今回
読み出したデータと、前回読み出したデータとを比較す
ることで、プロセッサBM の異常を検出する処理であ
る。
FIG. 4 is a flowchart of a program A-2 executed by the processor A at each cycle t 1 . The program A-2 includes a data read current from the common memory C M, by comparing the data previously read is a process for detecting an abnormality of the processor B M.

【0046】先ず、図4のステップS24で共通メモリ
M のデータを読み出す。次にステップS25で今回読
み出した共通メモリCM のデータと前回読み出したデー
タとを比較し、両者が一致するか否かを判別する。
Firstly, it reads the data of the common memory C M in step S24 in FIG. 4. Then comparing the common memory C M data and the previous read data read out this time in step S25, it is determined whether they match.

【0047】データが一致しない場合は、ステップS2
6でプロセッサBMは正常に動作しているものと判断
し、処理を終了する。他方、データが一致する場合は、
プロセッサBM において後述するプログラムBM −1が
実行されず、共通メモリCM の値がインクリメントされ
ない場合であり、この場合にはステップS27でプロセ
ッサBM に異常が発生したものと判断し、処理を終了す
る。
If the data do not match, step S2
At 6, it is determined that the processor BM is operating normally, and the process ends. On the other hand, if the data matches,
Not executed program B M -1, which will be described later in the processor B M, the case where the value of the common memory C M is not incremented in this case determines that an abnormality has occurred in the processor B M in step S27, the processing To end.

【0048】次に図5は、プロセッサBM で周期t2
に実行されるプログラムBM −1のフローチャートであ
る。このプログラムBM −1は、共通メモリDの値が前
回の値と同じか否かにより、共通メモリCM をクリア又
はインクリメントする処理である。
Next, FIG. 5 is a flowchart of the program B M -1 executed by the processor B M every cycle t 2 . The program B M -1 is a process for clearing or incrementing the common memory C M depending on whether the value of the common memory D is the same as the previous value.

【0049】先ず、図5のステップS28で共通メモリ
Dの内容を読み出す。そして、ステップS29で今回読
み出した共通メモリDの内容と、前回読み出した共通メ
モリDの内容とを比較し、両者が一致するか否かを判別
する。
First, the contents of the common memory D are read in step S28 in FIG. Then, in step S29, the content of the common memory D read this time is compared with the content of the common memory D read last time, and it is determined whether or not they match.

【0050】共通メモリDの内容が一致しないときは、
プロセッサAにより前述したプログラムA−1が実行さ
れ、共通メモリDの値が「0」から「1」に、あるいは
「1」から「0」に周期t0 毎に交互に書き換えられて
いる場合であり、この場合には、ステップS30に進み
共通メモリCM を「0」にクリアして、処理を終了す
る。
When the contents of the common memory D do not match,
In the case where the program A-1 described above by the processor A is executed, it has been rewritten alternately value of the common memory D from "0" to "1" or from "1" every period t 0 to "0" Yes, in this case, to clear the common memory C M to "0", the flow proceeds to step S30, and the process ends.

【0051】他方、共通メモリDの値が一致する場合
は、時間t0 の間プログラムA−1が実行されず、共通
メモリDの値が書き換えられていない場合であり、この
場合には、ステップS31に進み共通メモリCM
「1」インクリメントして、処理を終了する。
On the other hand, when the values of the common memory D match, the program A-1 is not executed during the time t 0 and the value of the common memory D is not rewritten. the common memory C M proceeds to S31 is incremented "1", the process ends.

【0052】次に図6は、プロセッサBM で周期t3
に実行されるプログラムBM ー2のフローチャートであ
る。このプログラムBM −2は、共通メモリCM のデー
タを規定値(基準値)と比較することで、プロセッサA
の異常を検出する処理である。
FIG. 6 is a flowchart of a program B M -2 executed by the processor B M every cycle t 3 . The program B M -2 compares the data in the common memory C M with a specified value (reference value) to generate the processor A M.
This is a process for detecting abnormalities in the data.

【0053】先ず、図6のステップS32で共通メモリ
M のデータを読み出す。次に、ステップS33で、読
み出した共通メモリCM のデータが規定値未満か否かを
判別する。
[0053] First, reading the data of the common memory C M in step S32 in FIG. 6. Next, in step S33, data of the common memory C M read it is determined whether or not less than a specified value.

【0054】共通メモリCM のデータが規定値未満であ
ったときには、プロセッサAにより周期t0 毎に共通メ
モリDの内容が書き換えられ、その結果に基づいてプロ
グラムBM −1により一定周期t2毎に共通メモリCM
が「0」にクリアされている場合である。
When the data in the common memory C M is less than the specified value, the content of the common memory D is rewritten by the processor A every cycle t 0 , and based on the result, the program B M -1 causes the fixed cycle t 2. Common memory C M for each
Is cleared to “0”.

【0055】この場合には、ステップS34でプロセッ
サAが正常に動作しているものと判断して、処理を終了
する。他方、共通メモリCM のデータが規定値以上であ
ったときには、プログラムA−1により共通メモリDの
値が書き換えられていない為に、プログラムBM −1に
より共通メモリCM がインクリメントされ規定値以上と
なった場合である。
In this case, it is determined in step S34 that the processor A is operating normally, and the process is terminated. On the other hand, when the data of the common memory C M is equal to or larger than the predetermined value, in order by a program A-1 has not been rewritten because of the common memory D, is incremented common memory C M by a program B M -1 specified value This is the case when the above is reached.

【0056】この場合には、ステップS35でプロセッ
サAに異常が発生したものと判断し、さらに次のステッ
プS36で共通メモリCM に規定値を設定してプロセッ
サAに異常が発生したことを記憶する。
[0056] store that in this case, it is determined that an abnormality has occurred in the processor A in step S35, an abnormality in the processor A has occurred further by setting the specified value to the common memory C M in the next step S36 I do.

【0057】次に、プロセッサA及びBM で上述したプ
ログラムが実行されたときの共通レジスタD及びCM
値の時間的変化を示した図7〜図9の動作タイムチャー
トを参照しながら、各プロセッサの動作を説明する。
Next, with reference to the shared register D and the operation time charts in FIGS. 7-9 showing the temporal change in the value of C M when the above program by the processor A and B M is executed, The operation of each processor will be described.

【0058】先ず、プロセッサA及びBM が正常なとき
のプロセッサの動作を、図7の動作タイムチャートを参
照して説明する。ある時刻にプロセッサAがプログラム
A−1を実行して共通メモリDのデータ値を「1」から
「0」に書き換えた後に、プロセッサBM がプログラム
M −1を実行したとする。この場合、共通メモリDか
ら今回読み出した値と前回読み出した値とは一致しない
ので、プログラムBM −1により共通メモリCM
「0」にクリアされる。
First, the operation of the processors when the processors A and B M are normal will be described with reference to the operation time chart of FIG. After rewriting the data value of the common memory D processor A in a certain time to execute the program A-1 from "1" to "0", the processor B M is the executing the program B M -1. In this case, the value read this time from the common memory D does not match the value read last time, so the program B M -1 clears the common memory CM to “0”.

【0059】次にプログラムA−1が実行されるまでの
0 期間、共通メモリDの値は「0」のまま変化しない
ので、その間プロセッサBM によりプログラムBM −1
が実行される毎に共通メモリCM の値が順次増加してい
く。
[0059] Next t 0 time to the program A-1 is executed, the value of the common memory D remains unchanged at "0", the program B M -1 by between processor B M
There the value of the common memory C M different runs is gradually increased sequentially.

【0060】そして、周期t0 後に再びプログラムA−
1が実行されて共通メモリDのデータ値が「0」から
「1」に書き換えられると、プログラムBM −1により
共通メモリDの今回の読み出し値と前回の読み出し値と
の不一致が検出され、再び共通メモリCM が「0」にク
リアされる。
After the period t 0 , the program A-
When 1 is executed and the data value of the common memory D is rewritten from "0" to "1", the program B M -1 detects a mismatch between the current read value and the previous read value of the common memory D, The common memory CM is cleared to "0" again.

【0061】すなわち、プロセッサAが正常に動作して
いるときには、共通メモリDの値が「1」から「0」
へ、あるいは「0」から「1」へ交互に書き換えられ、
プロセッサB側のプログラムBM −1で共通レジスタD
の前回の値と今回の値の不一致が検出され、共通メモリ
Cがクリアされる。この結果、共通メモリCM の値が一
定値以下に抑えられるので、プログラムBM −2により
プロセッサAが正常に動作していると判定される。
That is, when the processor A is operating normally, the value of the common memory D is changed from “1” to “0”.
Or from “0” to “1” alternately,
The common register D in the program B M -1 on the processor B side
Is detected, and the common memory C is cleared. As a result, the value of the common memory C M since suppressed below a predetermined value, it is determined that the processor A by the program B M -2 is operating normally.

【0062】また、プロセッサBが正常に動作している
ときには、プログラムBM −1により周期t2 毎に共通
メモリCM の値が「1」づつインクリメントされるの
で、この共通メモリCM の値の変化がプロセッサA側の
プログラムA−1で検出され、プロセッサBが正常に動
作していると判定される。
[0062] Also, when the processor B is operating properly, the value of the common memory C M every period t 2 by the program B M -1 is incremented one by "1", the value of the common memory C M Is detected by the program A-1 on the processor A side, and it is determined that the processor B is operating normally.

【0063】次に、プロセッサBM に異常が発生した場
合の動作を、図8の動作タイムチャートを参照して説明
する。図8に示すようにプロセッサBM に異常が発生す
ると、プロセッサBM 側のプログラムBM −1が実行さ
れなくなり、共通メモリCM の値がクリア又はインクリ
メントされなくなる。その為、共通メモリCM のデータ
値は増加せず一定値となる。
Next, the operation when abnormality occurs in the processor B M, will be described with reference to an operation timing chart of FIG. When abnormality in the processor B M is generated as shown in FIG. 8, the program B M -1 processor B M side from running, the value of the common memory C M is not cleared or incremented. Therefore, a constant value does not increase the data value of the common memory C M.

【0064】すると、プロセッサAで周期t1 毎に実行
されるプログラムA−2で読み出される共通メモリCM
の今回の読み出し値と前回の読み出し値とが一致する。
これによりプロセッサAは、プロセッサBM に異常が発
生したことを検出できる。
Then, the common memory C M read out by the program A-2 executed by the processor A every cycle t 1
The current read value and the previous read value match.
Thus the processor A can detect that an abnormality has occurred in the processor B M.

【0065】次に、プロセッサAに異常が発生した場合
の動作を、図9の動作タイムチャートを参照しながら説
明する。図9に示すようにプロセッサAに異常が発生す
ると、プロセッサA側のプログラムA−1が実行されな
くなり、共通メモリDの値が書き換えられなくなる。共
通メモリDの値が変化しなくなると、プロセッサB側の
プログラムBM −1で共通メモリCM の値が「0」にク
リアされず、その値が次第に増大する。
Next, an operation when an abnormality occurs in the processor A will be described with reference to an operation time chart of FIG. As shown in FIG. 9, when an abnormality occurs in the processor A, the program A-1 on the processor A side is not executed, and the value of the common memory D cannot be rewritten. When the value of the common memory D stops changing, the value of the common memory C M is not cleared to “0” by the program B M −1 on the processor B side, and the value gradually increases.

【0066】この結果、プロセッサBM で周期t3 毎に
実行されるプログラムBM −2により共通メモリCM
値が規定値以上となったことが検出される。これにより
プロセッサBM は、プロセッサAに異常が発生したこと
を検出できる。
As a result, it is detected by the program B M -2 executed by the processor B M every period t 3 that the value of the common memory C M has exceeded the specified value. Thereby, the processor B M can detect that an abnormality has occurred in the processor A.

【0067】ここで、従来の相互監視方法でプロセッサ
異常と誤って判定してしまった原因について検討して見
る。従来の相互監視方法では、プロセッサBのプログラ
ムB−1が共通メモリCのデータを読み出した直後に、
プロセッサAのプログラムA−1が共通メモリCの値を
「0」にクリアした場合に問題が発生していた。
Here, the cause of the erroneous determination that the processor is abnormal by the conventional mutual monitoring method will be examined. In the conventional mutual monitoring method, immediately after the program B-1 of the processor B reads the data of the common memory C,
A problem occurs when the program A-1 of the processor A clears the value of the common memory C to "0".

【0068】すなわち、従来の相互監視方法では、プロ
セッサA側のプログラムA−1で共通メモリCをクリア
し、プロセッサB側のプログラムB−1で共通メモリC
のデータをインクリメントしていたので、両者の起動タ
イミングによっては共通メモリCの値が増大してしまう
場合があった。
That is, in the conventional mutual monitoring method, the common memory C is cleared by the program A-1 on the processor A side, and the common memory C is cleared by the program B-1 on the processor B side.
Is incremented, the value of the common memory C may increase depending on the activation timing of the two.

【0069】これに対して本実施例の相互監視方法で
は、プロセッサAが共通メモリDのメッセージ(この場
合、「0」又は「1」)を書き換えているか否かに基づ
いて、プロセッサB側のプログラムBM −1が共通メモ
M の内容をクリア又はインクリメント(又はディク
リメント)するようにしている。
On the other hand, in the mutual monitoring method according to the present embodiment, the processor A determines whether or not the processor A has rewritten the message (in this case, “0” or “1”) in the common memory D. program B M -1 are in the common memory C M clear or increment the contents of (or decrement) it is so.

【0070】従って、プログラムの起動タイミングによ
って共通メモリ M の値が増大することが原理的に起こ
り得ず、判定誤りを完全になくすことができる。なお、
この実施例では、プロセッサA自身が共通メモリDの値
を、例えば「0」から「1」(あるいは「1」から
「0」)に交互に書き換えるようにしているので、共通
メモリのメッセージの書き換えをプロセッサB側のプロ
グラムから独立して行うことができる。
Therefore, the value of the common memory C M cannot be increased in principle due to the start timing of the program, and the determination error can be completely eliminated. In addition,
In this embodiment, the processor A itself rewrites the value of the common memory D alternately from, for example, “0” to “1” (or “1” to “0”). Can be performed independently of the program on the processor B side.

【0071】次に、本発明の第2実施例を説明する。こ
の実施例は、基本的には図2に示した第1実施例のシス
テム構成と同じ構成を有し、各プロセッサA、BM で実
行される各プログラムも基本的な部分は第1実施例と同
じである。
Next, a second embodiment of the present invention will be described. This embodiment is basically has the same configuration as the system configuration of the first embodiment shown in FIG. 2, each processor A, also basic part each program to be executed by the B M first embodiment Is the same as

【0072】以下、第2実施例の特徴となる部分につい
て説明する。この実施例では、プロセッサA側のプログ
ラムA−1が、周期t0 毎に共通メモリDに数値データ
Yを書き込んでいる。
Hereinafter, the characteristic portions of the second embodiment will be described. In this example, the program A-1 of the processor A side, writing the numerical data Y in the common memory D every period t 0.

【0073】そして、その共通メモリDの内容が数値デ
ータYであれば、プロセッサBM 側のプログラムBM
1が、周期t3 毎に共通メモリDと共通メモリCM とを
「0」にクリアし、共通メモリDの内容が数値データY
でなければ、共通メモリCM の値を「1」づつインクリ
メント(又はディクリメント)している。
[0073] Then, if the common memory D content numeric data Y, the processor B M side program B M -
1 clears the common memory D and the common memory CM to “0” at every cycle t 3, and the content of the common memory D is set to the numerical data Y
Otherwise, being "1" at a time increments the value of the common memory C M (or decrement).

【0074】なお、プログラムA−2とプログラムBM
ー2は第2実施例と同じである。上述したプログラムに
より、例えばプロセッサAに異常が発生して共通メモリ
Dに数値データYが書き込まれなくなると、プロセッサ
B側のプログラムBM −1により共通メモリCM の値が
増大し、規定値に達した時点でプロセッサAの異常と判
定される。
The program A-2 and the program B M
-2 is the same as that of the second embodiment. When, for example, an error occurs in the processor A and the numerical data Y is no longer written to the common memory D by the above-described program, the value of the common memory C M is increased by the program B M -1 on the processor B side, and the value becomes the specified value. At this point, it is determined that the processor A is abnormal.

【0075】次に、本発明の第3実施例を説明する。図
10は、第3実施例のプロセッサシステムのシステム構
成図である。この実施例は、前述したプロセッサAがN
個、プロセッサBが1個存在する場合の例である。
Next, a third embodiment of the present invention will be described. FIG. 10 is a system configuration diagram of the processor system of the third embodiment. In this embodiment, the processor A is N
This is an example in the case where there is one processor B.

【0076】図10において、プロセッサBが搭載され
たプロセッサカードBと、N個のプロセッサAM (M=
1、2、・・・N)がそれぞれ搭載されたN枚のプロセ
ッサカードAと、共通メモリカードXとは共通バスEに
接続されている。
In FIG. 10, a processor card B on which a processor B is mounted, and N processors A M (M =
, N) are connected to a common bus E.

【0077】共通メモリカードX内には、1つの共通メ
モリCとプロセッサAM からのメッセージ(例えば、数
値「1」又は「0」)が書き込まれるN個の共通メモリ
M とが設けられている。
In the common memory card X, one common memory C and N common memories D M to which messages (for example, numerical values “1” or “0”) from the processor A M are written are provided. I have.

【0078】また、プロセッサカードB内には、プロセ
ッサBがアクセス可能なN−1個のメモリCM (この実
施例では、プロセッサカードB内のプロセッサBがアク
セスするN−1個のメモリをメモリCM と呼ぶ)が設け
られている。
Further, in the processor card B, N-1 memories C M accessible by the processor B (in this embodiment, N-1 memories accessed by the processor B in the processor card B are stored in the memory). referred to as C M) is provided.

【0079】プロセッサAM 側で実行されるプログラム
M −1は、周期t0 毎に起動され、共通メモリDM
メッセージとして「0」と「1」とを交互に書き込む処
理である。
The program A M -1 executed on the processor A M side is a process which is started every period t 0 and writes “0” and “1” as messages in the common memory D M alternately.

【0080】また、プログラムAM −2は、周期t1
に起動され、共通メモリCのデータを読み出し、今回読
み出したデータと前回読み出したデータと比較し、一致
すればプロセッサBは異常、不一致であればプロセッサ
Bは正常と判定する処理である。
The program A M -2 is started every cycle t 1 , reads out the data in the common memory C, compares the data read out this time with the data read out last time. If so, the processor B determines that it is normal.

【0081】プロセッサB側で実行されるプログラムB
−1は、周期t2 毎に起動され、共通メモリDM の内容
を読み出し、今回読み出した値と前回読み出した値とを
比較し、一致すれば(プロセッサAM からのメッセージ
が存在しない場合)、メモリCM (共通メモリCを含
む、以下同じ)のデータをインクリメント(又はディク
リメント)し、不一致であれば(プロセッサAM からの
メッセージが存在する場合)、メモリCを「0」にクリ
アする処理である。
Program B Executed on Processor B
-1 is activated every period t 2, the common memory read the contents of the D M, compares the read value and the present value previously read, if they match (if the message from processor A M is absent) , The data of the memory C M (including the common memory C, the same applies hereinafter) is incremented (or decremented), and if they do not match (when there is a message from the processor A M ), the memory C is cleared to “0”. This is the processing to be performed.

【0082】また、プログラムB−2は、周期t3 毎に
起動され、メモリCM のデータ値と規定値とを比較し、
データ値が規定値より小さければ、プロセッサAM は正
常と判定し、データ値が規定値以上であれば、プロセッ
サAM は異常と判定する処理である。
[0082] Also, the program B-2 is activated every period t 3, compared with the data value of the memory C M a specified value,
If the data value is smaller than the specified value, the processor A M is judged to be normal, if the data is the specified value or higher, the processor A M is the process of determining as abnormal.

【0083】これらのプログラムにより、上述した第1
及び第2実施例と同様にして、プロセッサAM 及びプロ
セッサBが、お互いのプロセッサの異常を検出すること
ができる。
The above first program is used by these programs.
Similarly to the second embodiment, the processor AM and the processor B can detect an abnormality of each other.

【0084】この実施例では、プロセッサBが1個であ
るので、プロセッサBの異常を検出する為にN個のプロ
セッサAM から読み出す必要のある共通メモリCは1個
で充分である。そこで、共通メモリCを1個とし、N−
1個のプロセッサAM の異常を検出する為に必要なN−
1個のメモリC(残りの1個のプロセッサAM に付いて
は共通メモリCを使用する)を、プロセッサBからだけ
アクセスできるプロセッサカードB内に設けている。
[0084] In this embodiment, since the processor B is one, common memory C that must be read to detect the abnormality of the processor B from the N processors A M is sufficient one. Therefore, the number of common memories C is set to one, and N-
Required to detect an abnormality in one of the processors A M N-
One memory C (in attached to the remaining one processor A M using a common memory C), are provided only accessible processor card B from the processor B.

【0085】これにより、N個のプロセッサAの異常を
検出する為のメモリ(第1実施例の共通メモリCM に相
当する)を、必ずしも共通メモリとする必要がなくな
り、プロセッサカードB内のメモリ領域を使用すること
ができるので、メモリ構成がより自由になる。
[0085] Thus, the memory for detecting an abnormality of N processors A (corresponds to a common memory C M of the first embodiment), always it is not necessary to the common memory, the memory in the processor card B Since the area can be used, the memory configuration becomes more free.

【0086】次に、本発明の第4実施例を説明する。こ
の実施例のシステム構成は、図10に示した第3実施例
のシステム構成と同じであり、また各プロセッサAM
Bで実行される各プログラムも基本となる部分は、第3
実施例のプログラムと同じである。以下、第4実施例の
特徴となる部分について説明する。
Next, a fourth embodiment of the present invention will be described. System configuration of this embodiment is the same as the system configuration of the third embodiment shown in FIG. 10, and each processor A M,
The basic part of each program executed in B is the third part.
This is the same as the program of the embodiment. Hereinafter, the characteristic portions of the fourth embodiment will be described.

【0087】この実施例は、プロセッサAM が一定周期
毎に共通メモリDM にメッセージとして数値データYを
書き込んでいる。そして、共通メモリDM に数値データ
Yが書き込まれているときには、プロセッサBが一定周
期毎にその共通メモリDM とメモリCM (共通メモリC
を含む、以下同じ)とを「0」にクリアし、数値データ
Yが書き込まれていないときには、メモリCM をインク
リメントするようにしている。
[0087] This example, processor A M is writing numerical data Y as a message to the common memory D M at fixed intervals. Then, when the numerical data Y is written in the common memory D M , the processor B sends the common memory D M and the memory C M (the common memory C M) at regular intervals.
And the same hereinafter) are cleared to "0", and when the numerical data Y is not written, the memory CM is incremented.

【0088】以下、プロセッサAM 及びBで実行される
プログラムについて説明する。プロセッサAM で実行さ
れるプログラムAM −1は、周期t0 毎に起動され、共
通メモリDM に数値データYを書き込む。
[0088] The following describes a program to be executed by the processor A M and B. The program A M -1 executed by the processor A M is started every period t 0 and writes the numerical data Y to the common memory D M.

【0089】プロセッサBで実行されるプログラムB−
1は、周期t2 毎に起動され、共通メモリDM の内容を
読み出し、読み出したデータが数値データYならば、メ
モリCM と共通メモリDM を「0」にクリアし、読み出
したデータが数値データYでなければ、メモリCM
「1」インクリメントする処理である。
Program B- Executed by Processor B
1 is activated every period t 2, reads the contents of the common memory D M, if the read data is numerical data Y, clears the common memory D M and memory C M to "0", the read data is Otherwise numerical data Y, is a process that is incremented by "1" the memory C M.

【0090】また、プログラムAM −2とプログラムB
−2は、第3実施例のプログラムと同一である。これら
のプログラムにより、プロセッサAM が正常に動作して
いて共通メモリDM に数値データYが書き込まれている
場合には、一定周期毎にメモリCM のデータが「0」に
クリアされ、メモリCM のデータが常に規定値未満とな
る。一方、プロセッサAM に異常が発生すると、メモリ
M のデータが規定値以上となるので、N個のプロセッ
サAM が正常か否かを誤りなく判定することができる。
The program A M -2 and the program B
-2 is the same as the program of the third embodiment. With these programs, when the processor A M is operating normally and the numerical data Y is written in the common memory D M , the data in the memory C M is cleared to “0” at regular intervals, and data C M becomes always less than the specified value. On the other hand, when an abnormality occurs in the processor A M , the data in the memory C M becomes equal to or more than the specified value, so that it is possible to determine without error whether the N processors A M are normal.

【0091】また、メモリCM の値が変化しているか否
かにより、プロセッサBが正常に動作しているか否かを
判定することができる。以上述べたように上記実施例で
は、複数のプロセッサが非同期で動作するプロセッサシ
ステムにおいて、共通メモリ領域を少なくとも2種類用
意し(例えば、共通メモリCと共通メモリD)、一方の
プロセッサAが、一定周期毎に共通メモリDにメッセー
ジとして、例えば「0」又は「1」を交互に書き込んで
いる。そして、プロセッサAにより共通メモリDのメッ
セージが書き換えられているときには、他のプロセッサ
Bが別の共通メモリCの値を「0」にクリアし、メッセ
ージが書き換えられていないときには、共通メモリCの
データをインクリメント(又はディクリメント)するよ
うにしている。
[0091] Further, depending on whether the value of the memory C M is changed, it is possible to determine whether the processor B is operating normally. As described above, in the above embodiment, in a processor system in which a plurality of processors operate asynchronously, at least two types of common memory areas are prepared (for example, a common memory C and a common memory D), and one processor A is fixed. For example, “0” or “1” is alternately written to the common memory D as a message in each cycle. When the message of the common memory D is rewritten by the processor A, the other processor B clears the value of another common memory C to "0", and when the message is not rewritten, the data of the common memory C is cleared. Is incremented (or decremented).

【0092】これにより、プロセッサAが正常に動作し
ている場合には、共通メモリCの値が増大せず、プロセ
ッサAに異常が発生した場合にだけ共通メモリCの値が
規定値以上となる。よって、この共通メモリCの値と規
定値とを比較することで、プロセッサAの異常を正確に
検出することができる。
Thus, when the processor A is operating normally, the value of the common memory C does not increase, and only when an abnormality occurs in the processor A, the value of the common memory C becomes more than the specified value. . Therefore, by comparing the value of the common memory C with the specified value, the abnormality of the processor A can be accurately detected.

【0093】また、共通メモリCの値が変化しているか
否かによりプロセッサBが正常に動作しているか否かを
検出している。しかも上述した相互監視方法では、一方
のプロセッサBが、他方のプロセッサAによって共通メ
モリDに書き込まれるメッセージに基づいて、共通メモ
リCを「0」にクリア、あるいはインクリメント(又は
ディクリメント)するようにしている。
Further, whether or not the processor B is operating normally is detected based on whether or not the value of the common memory C has changed. Moreover, in the mutual monitoring method described above, one processor B clears or increments (or decrements) the common memory C to “0” based on a message written to the common memory D by the other processor A. ing.

【0094】従って、従来の相互監視方法のようにプロ
グラムの起動タイミングによって、共通メモリCがクリ
アされないでその値が増大してしまうという問題が発生
ぜず、プロセッサの異常の検出の誤りをなくすことがで
きる。
Therefore, unlike the conventional mutual monitoring method, the problem that the value of the common memory C increases without being cleared by the start timing of the program does not occur, and the error in detecting the abnormality of the processor is eliminated. Can be.

【0095】尚、上記実施例では、1個のプロセッサA
(又はB)と複数のプロセッサBM (又はAM )からな
るプロセッサシステムについて説明したが、プロセッサ
A、Bがそれぞれ1個でもよいし、あるいはプロセッサ
A、Bがそれぞれ複数あっても良い。
In the above embodiment, one processor A
(Or B) and a processor system including a plurality of processors B M (or A M ) has been described. However, one processor A and B may be provided, respectively, or a plurality of processors A and B may be provided.

【0096】また、共通メモリDに書き込むメッセージ
は、実施例に述べた「0」、「1」、あるいは数値デー
タに限らずどのようなメッセージであっても良く、一方
のプロセッサが何らかの情報を書き込めば良い。
The message to be written to the common memory D is not limited to "0", "1" or numerical data described in the embodiment, and may be any message. One of the processors can write some information. Good.

【0097】[0097]

【発明の効果】本発明によれば、複数のプロセッサから
なるシステムにおいて、個々のプロセッサのプログラム
の起動タイミングにより発生するプロセッサの動作状態
の検出誤りをなくすことができる。
According to the present invention, in a system including a plurality of processors, it is possible to eliminate a detection error of an operating state of a processor caused by a timing of starting a program of each processor.

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

【図1】本発明の原理説明図である。FIG. 1 is a diagram illustrating the principle of the present invention.

【図2】本発明の第1実施例のシステム構成図である。FIG. 2 is a system configuration diagram of a first embodiment of the present invention.

【図3】実施例のプロセッサAで実行されるプログラム
A−1のフローチャートである。
FIG. 3 is a flowchart of a program A-1 executed by a processor A of the embodiment.

【図4】実施例のプロセッサAで実行されるプログラム
A−2のフローチャートである。
FIG. 4 is a flowchart of a program A-2 executed by a processor A of the embodiment.

【図5】実施例のプロセッサBM で実行されるプログラ
ムBM −1のフローチャートである。
FIG. 5 is a flowchart of a program B M -1 executed by the processor B M of the embodiment.

【図6】実施例のプロセッサBM で実行されるプログラ
ムB−2のフローチャートである。
FIG. 6 is a flowchart of a program B-2 executed by a processor B M of the embodiment.

【図7】実施例の相互監視方法でプロセッサA、BM
正常なときの動作タイムチャートである。
FIG. 7 is an operation time chart when the processors A and BM are normal in the mutual monitoring method according to the embodiment.

【図8】実施例の相互監視方法でプロセッサBM に異常
が発生した場合の動作タイムチャートである。
8 is an operational time chart in the case where abnormality occurs in the processor B M in mutual monitoring method in Example.

【図9】実施例の相互監視方法でプロセッサAに異常が
発生した場合の動作タイムチャートである。
FIG. 9 is an operation time chart when an abnormality occurs in the processor A in the mutual monitoring method of the embodiment.

【図10】第3実施例のシステム構成図である。FIG. 10 is a system configuration diagram of a third embodiment.

【図11】従来の相互監視方法におけるプロセッサAの
処理フローチャートである。
FIG. 11 is a processing flowchart of a processor A in a conventional mutual monitoring method.

【図12】従来の相互監視方法におけるプロセッサAの
処理フローチャートである。
FIG. 12 is a processing flowchart of a processor A in a conventional mutual monitoring method.

【図13】従来の相互監視方法におけるプロセッサBの
処理フローチャートである。
FIG. 13 is a processing flowchart of a processor B in a conventional mutual monitoring method.

【図14】従来の相互監視方法におけるプロセッサBの
処理フローチャートである。
FIG. 14 is a processing flowchart of a processor B in a conventional mutual monitoring method.

【図15】t3 =t2 の場合のプロセッサBの処理フロ
ーチャートである。
FIG. 15 is a processing flowchart of the processor B when t 3 = t 2 .

【図16】従来の相互監視方法でプロセッサA、Bが正
常なときの動作タイムチャートである。
FIG. 16 is an operation time chart when the processors A and B are normal in the conventional mutual monitoring method.

【図17】従来の相互監視方法でプロセッサAに異常が
発生した場合の動作タイムチャートである。
FIG. 17 is an operation time chart when an error occurs in the processor A in the conventional mutual monitoring method.

【図18】従来の相互監視方法でプロセッサBに異常が
発生した場合の動作タイムチャートである。
FIG. 18 is an operation time chart when an error occurs in the processor B by the conventional mutual monitoring method.

【図19】従来の相互監視方法の問題点の説明図であ
る。
FIG. 19 is an explanatory diagram of a problem of the conventional mutual monitoring method.

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

A、B、AM 、BM プロセッサ C、D、CM 、DM 共通メモリ Ci メモリ A, B, A M, B M processor C, D, C M, D M common memory C i memory

───────────────────────────────────────────────────── フロントページの続き (58)調査した分野(Int.Cl.6,DB名) G06F 15/16 G06F 11/00 ──────────────────────────────────────────────────続 き Continued on the front page (58) Field surveyed (Int.Cl. 6 , DB name) G06F 15/16 G06F 11/00

Claims (4)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】複数のプロセッサと該複数のプロセッサか
らアクセス可能な共通メモリC、Dとからなるシステム
に用いられるプロセッサ間相互監視方法であって、 前記複数のプロセッサの中で互いに動作を監視している
プロセッサA、Bの一方のプロセッサAが、 周期t0 毎に前記共通メモリDにメッセージを書き込
み、 周期t1 毎に前記共通メモリCのデータを読み出し、今
回読み出したデータと前回読み出したデータとを比較
し、データが不一致であればプロセッサBは正常と判定
し、データが一致したならプロセッサBは異常と判定
し、 他方のプロセッサBが、前期周期t 1 よりも短い 周期t2 毎に前記共通メモリD
の内容を読み出し、プロセッサAからのメッセージの有
無を判断し、 メッセージが存在する場合には前記共通メモリCをクリ
又は所定値を設定し、メッセージが存在しない場合に
は前記共通メモリCのデータをインクリメント又はディ
クリメントし、前記 共通メモリCのデータと基準値とを比較し、基準値
以内であればプロセッサAは正常と判定し、基準値を
えたならプロセッサAは異常と判定する、 ことを特徴とするプロセッサ間相互監視方法。
1. A system comprising a plurality of processors and common memories C and D accessible from the plurality of processors.
A processor mutual monitoring method for use in a processor A, which monitors the operation together among the plurality of processors, one processor A and B, writes a message to the common memory D every period t 0 The data in the common memory C is read every cycle t 1, and the data read this time and the data read last time are compared. If the data does not match, the processor B determines that the data is normal. It determines the abnormality, the other processor B, the common memory D short every period t 2 than the previous year period t 1
Is read and the presence or absence of a message from the processor A is determined. If a message is present, the common memory C is cleared or a predetermined value is set. Increments or decrements, compares the data in the common memory C with a reference value,
Processor A is determined to be normal if it is within the reference value Yue
The processor A determines that an abnormality has occurred, the mutual monitoring method between the processors.
【請求項2】少なくとも1個のプロセッサAとN個のプ
ロセッサBM (M=1、2・・・N)と、該プロセッサ
A、BM からアクセス可能な共通メモリDとN個の共通
メモリCM とからなるシステムに用いられるプロセッサ
間相互監視方法であって、 プロセッサAが、 周期t0 毎に前記共通メモリDにメッセージを書き込
み、 周期t1 毎に前記共通メモリCM のデータを読み出し、
今回読み出したデータと前回読み出したデータとを比較
し、データが不一致であれば、該共通メモリCM に対応
するプロセッサBM は正常と判定し、データが一致した
ならプロセッサBM は異常と判定し、 プロセッサBM が、前期周期t 1 よりも短い 周期t2 毎に前記共通メモリD
の内容を読み出し、プロセッサAからのメッセージの有
無を判断し、 メッセージが存在する場合には前記共通メモリCM の内
容をクリア又は所定値を設定し、メッセージが存在しな
い場合には該共通メモリCM の内容をインクリメント又
はディクリメントし、前記 共通メモリCM のデータと基準値とを比較し、基準
以内であればプロセッサAは正常と判定し、基準値を
越えたならプロセッサAは異常と判定する、 ことを特徴とするプロセッサ間相互監視方法。
2. At least one processor A and N processors B M (M = 1, 2,... N), a common memory D accessible from the processors A and B M and N common memories processor for use in a system comprising a C M
Be between mutual monitoring, the processor A is writing a message to the common memory D every period t 0, it reads the data of the common memory C M every period t 1,
Comparing the current read data and the previous data read, if the data mismatch, processor B M which corresponds to the common memory C M is determined to be normal, the processor B M if the data are matched with the abnormality determination Then, the processor B M transmits the common memory D every cycle t 2 shorter than the previous cycle t 1.
Reading the contents, the processor determines whether the message from A, the message sets clear or predetermined value the contents of the common memory C M, if present, the common memory if the message is not present C incrementing or decrementing the contents of the M, it compares the data with a reference value of said common memory C M, the processor a is determined to be normal if it is within the reference value, the reference value
The processor A determines that the processor A is abnormal if the number exceeds the threshold value .
【請求項3】N個のプロセッサAM (M=1、2・・・
N)と少なくとも1個のプロセッサBと、該プロセッサ
M 、Bからアクセス可能なN個の共通メモリDM と少
なくと1個の共通メモリCと、該プロセッサBからアク
セス可能な複数のメモリCi とからなるシステムに用い
られるプロセッサ間相互監視方法であって、 プロセッサAM が、 周期t0 毎に前記共通メモリDM にメッセージを書き込
み、 周期t1 毎に前記共通メモリCのデータを読み出し、今
回読み出したデータと前回読み出したデータとを比較
し、データが不一致であればプロセッサBは正常と判定
し、データが一致したならプロセッサBは異常と判定
し、 プロセッサBが、前期周期t 1 よりも短い 周期t2 毎に前記共通メモリD
M の内容を読み出し、プロセッサAM からのメッセージ
の有無を判断し、 メッセージが存在する場合にはプロセッサAM に対応す
る前記共通メモリC又はメモリCi の内容をクリア又は
所定値を設定し、メッセージが存在しない場合には該共
通メモリC又はメモリCi の内容をインクリメント又は
ディクリメントし、前記 共通メモリC及びメモリCi のデータと基準値とを
比較し、基準値以内であれば該メモリに対応するプロセ
ッサAM は正常と判定し、基準値を越えたならプロセッ
サAM は異常と判定する、 ことを特徴とするプロセッサ間相互監視方法。
3. The N processors A M (M = 1, 2,...)
N), at least one processor B, N common memories D M and at least one common memory C accessible from the processors A M and B, and a plurality of memories C accessible from the processor B. Used for the system consisting of i
Is a processor mutual monitoring, the processor A M is, write messages to the common memory D M for each period t 0, it reads the data of the common memory C every period t 1, read time data and the previous comparing the read data, the processor B is determined to be normal if the data mismatch, processor B if the data match, it is determined that the abnormality, the processor B is shorter each period t 2 than the previous year period t 1 The common memory D
Reads the contents of the M, it is determined whether the message from processor A M, clears the contents of the common memory C or the memory C i corresponding to the processor A M when a message is present or
Setting a predetermined value, if there are no messages will increment or decrement the contents of said common memory C or the memory C i, comparing the data with a reference value of said common memory C and memory C i, the reference value processor a M is determined to be normal, processor <br/> if exceeds the reference value Sa a M determines that abnormality, interprocessor mutual monitoring method characterized by corresponding to the memory if it is within.
【請求項4】複数のプロセッサと該複数のプロセッサか
らアクセス可能な共通メモリC、Dとからなるシステム
であって、 前記複数のプロセッサの中で互いに動作を監視している
プロセッサA、Bの一方のプロセッサAが、 周期t0 毎に前記共通メモリDにメッセージを書き込
み、 周期t1 毎に前記共通メモリCのデータを読み出し、今
回読み出したデータと前回読み出したデータとを比較
し、データが不一致であればプロセッサBは正常と判定
し、データが一致したならプロセッサBは異常と判定
し、 他方のプロセッサBが、前期周期t 1 よりも短い 周期t2 毎に前記共通メモリD
の内容を読み出し、プロセッサAからのメッセージの有
無を判断し、 メッセージが存在する場合には前記共通メモリCをクリ
又は所定値を設定し、メッセージが存在しない場合に
は前記共通メモリCのデータをインクリメント又はディ
クリメントし、前記 共通メモリCのデータと基準値とを比較し、基準値
以内であればプロセッサAは正常と判定し、基準値を
えたならプロセッサAは異常と判定する、 ことを特徴とするプロセッサ間相互監視装置。
4. A system comprising a plurality of processors and common memories C and D accessible from the plurality of processors, wherein one of the processors A and B monitors the operation among the plurality of processors. Processor A writes a message to the common memory D every cycle t 0 , reads data from the common memory C every cycle t 1 , compares the data read this time with the data read last time, and the data does not match. processor B is judged to be normal if the processor B if the data match, it is determined that the abnormality, the other processor B, the common memory D short every period t 2 than the previous year period t 1
Is read and the presence or absence of a message from the processor A is determined. If a message is present, the common memory C is cleared or a predetermined value is set. Increments or decrements, compares the data in the common memory C with a reference value,
Processor A is determined to be normal if it is within the reference value Yue
The processor A determines that an abnormality has occurred, and the mutual monitoring device between the processors.
JP3036275A 1991-03-01 1991-03-01 Method and apparatus for mutual monitoring between processors Expired - Fee Related JP2870202B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP3036275A JP2870202B2 (en) 1991-03-01 1991-03-01 Method and apparatus for mutual monitoring between processors

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP3036275A JP2870202B2 (en) 1991-03-01 1991-03-01 Method and apparatus for mutual monitoring between processors

Publications (2)

Publication Number Publication Date
JPH04275664A JPH04275664A (en) 1992-10-01
JP2870202B2 true JP2870202B2 (en) 1999-03-17

Family

ID=12465225

Family Applications (1)

Application Number Title Priority Date Filing Date
JP3036275A Expired - Fee Related JP2870202B2 (en) 1991-03-01 1991-03-01 Method and apparatus for mutual monitoring between processors

Country Status (1)

Country Link
JP (1) JP2870202B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4475598B2 (en) * 2007-06-26 2010-06-09 株式会社日立製作所 Storage system and storage system control method
JP5383590B2 (en) * 2010-05-21 2014-01-08 株式会社東芝 Abnormality detection method and vehicle control apparatus

Also Published As

Publication number Publication date
JPH04275664A (en) 1992-10-01

Similar Documents

Publication Publication Date Title
US5768496A (en) Method and apparatus for obtaining a durable fault log for a microprocessor
US4852092A (en) Error recovery system of a multiprocessor system for recovering an error in a processor by making the processor into a checking condition after completion of microprogram restart from a checkpoint
JP3481737B2 (en) Dump collection device and dump collection method
JP2870202B2 (en) Method and apparatus for mutual monitoring between processors
JP3192354B2 (en) Computer system retry processor
JPH04241642A (en) Runaway detecting system for microcomputer
JP3094924B2 (en) Communication device control circuit
JPS62106552A (en) Loop detector
JP3154853B2 (en) Illegal memory access detection method
JPS62175834A (en) Detecting circuit for runaway of central processing unit
JPH06214831A (en) Abnormality detector for central processing unit
JP2002073375A (en) Software operation monitoring method in system that contains microcomputer
JPH0822419A (en) Miswriting prevention system
JPS60233743A (en) Fault detecting circuit of computer system
JP2635777B2 (en) Programmable controller
JPH0619744A (en) Operation monitoring system for multiprocessor system
JPH086864A (en) Diagnostic system for address bus for memory control
JP2506199B2 (en) Electronics
JPS6074052A (en) History memory control system
JPH05289946A (en) Memory control system
JPS5827538B2 (en) Mutual monitoring method
JPS62166449A (en) History storage device for logical unit
JPH02103647A (en) Method for controlling intelligent measuring card
JPH04338842A (en) Information processor with error detecting function
JPS5935455B2 (en) Seigiyo Souchi

Legal Events

Date Code Title Description
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 19981201

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20080108

Year of fee payment: 9

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090108

Year of fee payment: 10

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20100108

Year of fee payment: 11

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110108

Year of fee payment: 12

LAPS Cancellation because of no payment of annual fees