WO2010055562A1 - マイクロコンピュータ - Google Patents

マイクロコンピュータ Download PDF

Info

Publication number
WO2010055562A1
WO2010055562A1 PCT/JP2008/070669 JP2008070669W WO2010055562A1 WO 2010055562 A1 WO2010055562 A1 WO 2010055562A1 JP 2008070669 W JP2008070669 W JP 2008070669W WO 2010055562 A1 WO2010055562 A1 WO 2010055562A1
Authority
WO
WIPO (PCT)
Prior art keywords
detection time
program
counter
cpu
detection
Prior art date
Application number
PCT/JP2008/070669
Other languages
English (en)
French (fr)
Inventor
稔行 五十嵐
Original Assignee
富士通マイクロエレクトロニクス株式会社
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 富士通マイクロエレクトロニクス株式会社 filed Critical 富士通マイクロエレクトロニクス株式会社
Priority to PCT/JP2008/070669 priority Critical patent/WO2010055562A1/ja
Priority to JP2010537631A priority patent/JP5115628B2/ja
Publication of WO2010055562A1 publication Critical patent/WO2010055562A1/ja
Priority to US13/102,158 priority patent/US8522081B2/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/0703Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
    • G06F11/0751Error or fault detection not based on redundancy
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/0703Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
    • G06F11/0706Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation the processing taking place on a specific hardware platform or in a specific software environment
    • G06F11/0721Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation the processing taking place on a specific hardware platform or in a specific software environment within a central processing unit [CPU]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/0703Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
    • G06F11/0706Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation the processing taking place on a specific hardware platform or in a specific software environment
    • G06F11/0736Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation the processing taking place on a specific hardware platform or in a specific software environment in functional embedded systems, i.e. in a data processing system designed as a combination of hardware and software dedicated to performing a certain function
    • G06F11/0739Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation the processing taking place on a specific hardware platform or in a specific software environment in functional embedded systems, i.e. in a data processing system designed as a combination of hardware and software dedicated to performing a certain function in a data processing system embedded in automotive or aircraft systems

Definitions

  • the present invention relates to a microcomputer.
  • a watchdog timer is well known as a function for detecting a failure.
  • the watchdog timer determines that the CPU has failed when the CPU periodically clears the timer and the timer overflows.
  • the watchdog timer does not directly detect a CPU failure, it may miss the failure.
  • Japanese Patent Laid-Open No. 5-2654 discloses a microcomputer failure detection method for improving the failure detection rate of a microcomputer with a simple configuration and further reducing the time from occurrence of a failure to detection. Has been.
  • Japanese Patent Laid-Open No. 2001-188688 discloses a microcomputer runaway detection circuit for the purpose of detecting that an erroneous instruction code has been processed.
  • An object of the present invention is to provide a microcomputer capable of detecting a failure of a circuit that controls the instruction flow of a program.
  • the microcomputer of the present invention includes a program counter that updates and stores the address of the next program instruction to be executed each time the program instruction is executed, and the program instruction at the address stored in the program counter In sequence, a program counter expected value register that stores an expected value of an address stored in the program counter, an address stored in the program counter, and an expected value stored in the program counter expected value register A first comparator for comparing values and a detection time counter for counting detection time, and when the CPU executes the failure detection program, the CPU after the detection time from the start of execution of the failure detection program The expected value of the address stored in the program counter The first counter is stored in the program counter when the detection time counter finishes counting the detection time. The comparison result between the stored address and the expected value stored in the program counter expected value register is output as a failure detection result.
  • FIG. 1 is a block diagram showing a configuration example of a microcomputer system according to the first embodiment of the present invention.
  • FIG. 2 is a block diagram illustrating a configuration example of the microcomputer according to the first embodiment.
  • FIG. 3 is a flowchart illustrating a processing example of the microcomputer.
  • FIG. 4 is a timing chart showing a processing example of the flowchart of FIG.
  • FIG. 5 is a block diagram showing a configuration example of a microcomputer according to the second embodiment of the present invention.
  • FIG. 1 is a block diagram showing a configuration example of a microcomputer system according to the first embodiment of the present invention.
  • the microcomputer system includes a CPU board 108, a motor 106 and another CPU board 107.
  • the CPU board 108 includes a bus 100, a microcomputer 101, a timer 102, a serial input / output interface 103, a ROM 104, and a RAM 105.
  • a microcomputer 101, a timer 102, a serial input / output interface 103, a ROM 104 and a RAM 105 are connected to the bus 100.
  • the motor 106 is connected to the timer 102.
  • the CPU board 107 has the same configuration as the CPU board 108 and is connected to the serial input / output interface 103.
  • the ROM 104 or RAM 105 stores a failure detection program.
  • the microcomputer 101 can detect a failure of the CPU in the microcomputer 101 by reading and executing a failure detection program in the ROM 104 or RAM 105.
  • FIG. 2 is a block diagram illustrating a configuration example of the microcomputer 101.
  • the microcomputer 101 includes a CPU (central processing unit) 201, a detection time counter 203, a detection time register 204, a program counter (PC) expected value register 205, a first comparator 207, and a second comparator 206.
  • the CPU 201 has a program counter 202.
  • a CPU 201, a detection time counter 203, a detection time register 204 and a program counter expected value register 205 are connected to the bus 100.
  • the program counter 202 updates and stores the address of the next program instruction to be executed each time the program instruction is executed.
  • the CPU 201 sequentially executes the program instructions at the addresses stored in the program counter 202.
  • the program counter expected value register 205 stores the expected value of the address stored in the program counter 202.
  • the detection time register 204 stores the detection time.
  • the detection time counter 203 counts the detection time.
  • the second comparator 206 compares the detection time stored in the detection time register 204 with the count value of the detection time counter 203. When the second comparator 206 outputs a comparison result in which the detection time stored in the detection time register 204 matches the count value of the detection time counter 203, the first comparator 207 is stored in the program counter 202.
  • the comparison result between the stored address and the expected value stored in the program counter expected value register 205 is output to the CPU 201 as a failure detection result.
  • the CPU 201 determines that a failure of the CPU 201 has been detected and performs failure countermeasure processing.
  • FIG. 3 is a flowchart showing a processing example of the microcomputer 101
  • FIG. 4 is a timing chart showing a processing example of the flowchart of FIG.
  • the CPU 201 executes the failure detection program in the ROM 104 or RAM 105
  • the CPU 201 performs the processing of the flowchart of FIG. 3 according to the failure detection program.
  • Steps S1 to S3 are a preprocessing unit of the failure detection program.
  • Step S4 is a substantial part of the failure detection program.
  • Steps S6 and S7 are post-processing units of the failure detection program.
  • the failure detection program has a pre-processing unit, a substantial unit, and a post-processing unit.
  • step S1 the CPU 201 sets and stores the expected value of the address stored in the program counter 202 after the detection time from the start of execution of the failure detection program in the program counter expected value register 205.
  • the expected value is the expected value of the address stored in the program counter 202 when the entity part of the failure detection program ends.
  • step S1 of FIG. 4 for example, “a” is stored in the program counter expected value register 205 as the expected value of the address.
  • the CPU 201 stores the detection time in the detection time register 204.
  • the detection time is the time taken from the start to the end of the execution of the entity part of the failure detection program, and is expressed by the number of clocks. That is, the time when the entity part of the failure detection program ends is stored in the detection time register 204, and the expectation of the address stored in the program counter 202 when the entity part of the failure detection program ends is stored in the program counter expected value register 205. The value is stored. If the CPU 201 executes the failure detection program normally, the address of the expected value in the program counter expected value register 205 is stored in the program counter 202 when the detection time in the detection time register 204 elapses. By verifying this, a failure of the CPU 201 can be detected.
  • the detection time register 204 stores, for example, “b” as the detection time.
  • step S3 the CPU 201 causes the detection time counter 203 to start counting the detection time. Specifically, the CPU 201 causes the detection time counter 203 to start counting up from zero. The detection time counter 203 starts up-counting from 0, and increases the count value as time passes. In step S3 of FIG. 4, the detection time counter 203 starts counting up from zero.
  • step S4 the CPU 201 executes the substantial part of the failure detection program.
  • the substantial part of the failure detection program is a program that performs arithmetic processing.
  • step S6 after the completion of the substantial part of the failure detection program, the CPU 201 can detect the failure of the CPU 201 by verifying whether the calculation result is correct.
  • step S4 of FIG. 4 the processing of the substantial part of the failure detection program is performed in the period from the end of step S3 to the start of step S5.
  • step S5 the count value of the detection time counter 203 increases, and the count value of the detection time counter 203 eventually coincides with the detection time stored in the detection time register 204.
  • the second comparator 206 compares the detection time stored in the detection time register 204 with the count value of the detection time counter 203, and outputs a matching comparison result to the first comparator 207 if they match. .
  • the first comparator 207 is stored in the program counter 202.
  • the comparison result between the stored address and the expected value stored in the program counter expected value register 205 is output to the CPU 201 as a failure detection result.
  • step S5 of FIG. 4 the count value of the detection time counter 203 becomes the same value as the detection time “b” stored in the detection time register 204.
  • the address stored in the program counter 202 is “c”, for example, which is different from the expected value “a” stored in the program counter expected value register 205.
  • the first comparator 207 outputs a mismatch signal.
  • the CPU 201 proceeds to step S6 when a coincidence signal is input as a failure detection result from the first comparator 207, and proceeds to step S7 when a disagreement signal is input as the failure detection result from the first comparator 207.
  • step S6 the CPU 201 determines that no failure of the CPU 201 has been detected, and ends the failure detection program.
  • step S7 the CPU 201 determines that a failure of the CPU 201 has been detected, and executes failure countermeasure processing (a processing program corresponding to the failure) as an exception processing routine.
  • the failure countermeasure processing is processing for stopping the processing of the CPU 201 and causing the CPU in another CPU board 107 to perform processing instead.
  • the failure countermeasure process is a process for safely ending the operation of the entire microcomputer system or a process for safely running with limited functions.
  • step S7 of FIG. 4 the CPU 201 inputs a mismatch signal from the first comparator 207, and performs failure countermeasure processing as an exception routine.
  • Another CPU in the CPU board 107 may input the mismatched output signal of the first comparator 207 and perform failure countermeasure processing as an exception routine.
  • FIG. 5 is a block diagram showing a configuration example of the microcomputer 101 according to the second embodiment of the present invention.
  • the microcomputer 101 (FIG. 5) of the present embodiment is obtained by deleting the detection time register 204 and the second comparator 206 from the microcomputer 101 (FIG. 2) of the first embodiment.
  • FIG. 5 the points of the present embodiment different from the first embodiment will be described.
  • step S2 in FIG. 3 is deleted.
  • step S3 of FIG. 3 when the CPU 201 is instructed to start counting, the detection time counter 203 starts to count down the count value. Due to the down-counting, the count value of the detection time counter 203 decreases with time. Specifically, when executing the failure detection program, the CPU 201 causes the detection time counter 203 to start down-counting from the above detection time. For example, in FIG. 4, the down-counting from the detection time “b” is started.
  • step S5 of FIG. 3 when the count value of the detection time counter 203 reaches 0, the first comparator 207 determines the address stored in the program counter 202 and the expected value stored in the program counter expected value register 205. The comparison result with is output as a failure detection result.
  • the CPU 201 proceeds to step S6 when a coincidence signal is input as a failure detection result from the first comparator 207, and proceeds to step S7 when a disagreement signal is input as the failure detection result from the first comparator 207.
  • Steps S6 and S7 are the same as those in the first embodiment.
  • the first comparator 207 uses the address stored in the program counter 202 and the expected value stored in the program counter expected value register 205. Compare.
  • the detection time counter 203 counts the detection time. Specifically, when the CPU 201 executes the failure detection program, the CPU 201 stores the expected value of the address stored in the program counter 202 after the detection time from the start of execution of the failure detection program in the program counter expected value register 205, and the detection time counter 203 starts counting the detection time. In the first embodiment, the detection time counter 203 performs up-counting, and in the second embodiment, the detection time counter 203 performs down-counting. When the detection time counter 203 finishes counting the detection time, the first comparator 207 compares the address stored in the program counter 202 with the expected value stored in the program counter expected value register 205. Is output as a failure detection result.
  • the failure detection program detects a failure of the CPU 201.
  • An expected value of the program counter 202 when the failure detection program is executed and a detection time when the expected value is expected to appear are set in advance, and the expected value of the program counter 202 and the expected value of the program counter 202 are set to the expected detection time. Compare values. If they do not match, a failure of the CPU 201 has been detected.
  • the first and second embodiments it is possible to directly check the flow control of the program instruction, so it is possible to detect a failure of the circuit that controls the program instruction flow.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Debugging And Monitoring (AREA)
  • Microcomputers (AREA)

Abstract

 CPU(201)は、故障検出プログラムを実行すると、故障検出プログラムの実行開始から検出時間後のプログラムカウンタ(201)が記憶するアドレスの期待値をプログラムカウンタ期待値レジスタ(205)に記憶させ、検出時間カウンタ(203)に検出時間のカウントを開始させる。第1の比較器(207)は、検出時間カウンタ(203)が検出時間のカウントを終了すると、プログラムカウンタ(202)に記憶されているアドレスとプログラムカウンタ期待値レジスタ(205)に記憶されている期待値との比較結果を故障検出結果として出力する。

Description

マイクロコンピュータ
 本発明は、マイクロコンピュータに関する。
 近年、自動車向けのLSIに対して、故障検出を行い、重大な事故を招く前に、システムで事故を防ぐ事が求められている。故障を検出する機能としては、ウォッチドッグタイマが良く知られている。ウォッチドッグタイマは、CPUが定期的にタイマをクリアし、タイマがオーバーフローすると、CPUが故障したと判断するものである。しかし、ウォッチドッグタイマでは、直接的にCPUの故障を検出するわけでは無い為、故障を見逃す可能性がある。
 また、検出用に演算をさせて、その演算結果を確認する手段が有る。しかし、命令のフローを制御する回路に不具合が発生した場合は、検出用のプログラム実行時に、暴走してしまい、演算結果が得られない可能性がある。
 また、特開平5-2654号公報には、簡単な構成でマイクロコンピュータの故障検出率を向上させ、さらに故障発生から検知までの時間を短縮することを目的とするマイクロコンピュータの故障検知方法が開示されている。
 また、特開2001-188688号公報には、誤った命令コードが処理されたことを検知することを目的とするマイクロコンピュータの暴走検知回路が開示されている。
特開平5-2654号公報 特開2001-188688号公報
 本発明の目的は、プログラムの命令フローを制御する回路の故障を検出することができるマイクロコンピュータを提供することである。
 本発明のマイクロコンピュータは、プログラムの命令が実行される毎に次に実行すべきプログラムの命令のアドレスを更新して記憶するプログラムカウンタを含み、前記プログラムカウンタに記憶されているアドレスのプログラムの命令を順番に実行するCPUと、前記プログラムカウンタが記憶するアドレスの期待値を記憶するプログラムカウンタ期待値レジスタと、前記プログラムカウンタに記憶されているアドレスと前記プログラムカウンタ期待値レジスタに記憶されている期待値とを比較する第1の比較器と、検出時間のカウントを行う検出時間カウンタとを有し、前記CPUは、故障検出プログラムを実行すると、前記故障検出プログラムの実行開始から検出時間後の前記プログラムカウンタが記憶するアドレスの期待値を前記プログラムカウンタ期待値レジスタに記憶させ、前記検出時間カウンタに前記検出時間のカウントを開始させ、前記第1の比較器は、前記検出時間カウンタが前記検出時間のカウントを終了すると、前記プログラムカウンタに記憶されているアドレスと前記プログラムカウンタ期待値レジスタに記憶されている期待値との比較結果を故障検出結果として出力することを特徴とする。
図1は、本発明の第1の実施形態によるマイクロコンピュータシステムの構成例を示すブロック図である。 図2は、第1の実施形態によるマイクロコンピュータの構成例を示すブロック図である。 図3は、マイクロコンピュータの処理例を示すフローチャートである。 図4は、図3のフローチャートの処理例を示すタイミングチャートである。 図5は、本発明の第2の実施形態によるマイクロコンピュータの構成例を示すブロック図である。
 図1は、本発明の第1の実施形態によるマイクロコンピュータシステムの構成例を示すブロック図である。マイクロコンピュータシステムは、CPUボード108、モータ106及び他のCPUボード107を有する。CPUボード108は、バス100、マイクロコンピュータ101、タイマ102、シリアル入出力インターフェース103、ROM104、及びRAM105を有する。バス100には、マイクロコンピュータ101、タイマ102、シリアル入出力インターフェース103、ROM104、及びRAM105が接続される。モータ106は、タイマ102に接続される。CPUボード107は、CPUボード108と同様の構成を有し、シリアル入出力インターフェース103に接続される。ROM104又はRAM105は、故障検出プログラムを記憶する。マイクロコンピュータ101は、ROM104又はRAM105内の故障検出プログラムを読み出して実行することにより、マイクロコンピュータ101内のCPUの故障を検出することができる。
 図2は、マイクロコンピュータ101の構成例を示すブロック図である。マイクロコンピュータ101は、CPU(中央処理装置)201、検出時間カウンタ203、検出時間レジスタ204、プログラムカウンタ(PC)期待値レジスタ205、第1の比較器207、及び第2の比較器206を有する。CPU201は、プログラムカウンタ202を有する。バス100には、CPU201、検出時間カウンタ203、検出時間レジスタ204及びプログラムカウンタ期待値レジスタ205が接続される。
 プログラムカウンタ202は、プログラムの命令が実行される毎に次に実行すべきプログラムの命令のアドレスを更新して記憶する。CPU201は、プログラムカウンタ202に記憶されているアドレスのプログラムの命令を順番に実行する。プログラムカウンタ期待値レジスタ205は、プログラムカウンタ202が記憶するアドレスの期待値を記憶する。検出時間レジスタ204は、検出時間を記憶する。検出時間カウンタ203は、検出時間のカウントを行う。第2の比較器206は、検出時間レジスタ204に記憶されている検出時間と検出時間カウンタ203のカウント値とを比較する。第1の比較器207は、第2の比較器206が検出時間レジスタ204に記憶されている検出時間と検出時間カウンタ203のカウント値とが一致する比較結果を出力すると、プログラムカウンタ202に記憶されているアドレスとプログラムカウンタ期待値レジスタ205に記憶されている期待値との比較結果を故障検出結果としてCPU201に出力する。CPU201は、第1の比較器207により不一致の比較結果が出力されると、CPU201の故障が検出されたと判断し、故障対策処理を行う。
 図3はマイクロコンピュータ101の処理例を示すフローチャートであり、図4は図3のフローチャートの処理例を示すタイミングチャートである。CPU201は、ROM104又はRAM105内の故障検出プログラムを実行すると、故障検出プログラムに従って図3のフローチャートの処理を行う。ステップS1~S3は、故障検出プログラムの前処理部である。ステップS4は、故障検出プログラムの実体部である。ステップS6及びS7は、故障検出プログラムの後処理部である。故障検出プログラムは、上記のように、前処理部、実体部及び後処理部を有する。
 ステップS1では、CPU201は、故障検出プログラムの実行開始から検出時間後のプログラムカウンタ202が記憶するアドレスの期待値をプログラムカウンタ期待値レジスタ205に設定記憶させる。例えば、上記の期待値は、故障検出プログラムの実体部の終了時にプログラムカウンタ202が記憶するアドレスの期待値である。図4のステップS1において、プログラムカウンタ期待値レジスタ205には、アドレスの期待値として例えば「a」が記憶される。
 次に、ステップS2では、CPU201は、検出時間レジスタ204に上記の検出時間を記憶させる。例えば、検出時間は、故障検出プログラムの実体部の実行開始から終了までにかかる時間であり、クロック数で表現される。すなわち、検出時間レジスタ204には故障検出プログラムの実体部の終了時の時間が記憶され、プログラムカウンタ期待値レジスタ205には故障検出プログラムの実体部の終了時にプログラムカウンタ202に記憶されるアドレスの期待値が記憶される。CPU201が正常に故障検出プログラムを実行すれば、検出時間レジスタ204内の検出時間が経過すると、プログラムカウンタ期待値レジスタ205内の期待値のアドレスがプログラムカウンタ202に記憶されていることになる。これを検証することにより、CPU201の故障を検出することができる。図4のステップS2において、検出時間レジスタ204には、例えば検出時間として例えば「b」が記憶される。
 次に、ステップS3では、CPU201は、検出時間カウンタ203に上記の検出時間のカウントを開始させる。具体的には、CPU201は、検出時間カウンタ203に0からのアップカウントを開始させる。検出時間カウンタ203は、0からアップカウントを開始し、そのカウント値を時間経過に応じて増加させる。図4のステップS3において、検出時間カウンタ203は0からのカウントアップを開始する。
 次に、ステップS4では、CPU201は、故障検出プログラムの実体部を実行する。例えば、故障検出プログラムの実体部は、演算処理を行うプログラムである。故障検出プログラムの実体部の終了後のステップS6において、CPU201は、その演算結果が正しいか否かを検証することにより、CPU201の故障を検出することができる。図4のステップS4では、ステップS3の終了時からステップS5の開始時までの期間において故障検出プログラムの実体部の処理が行われる。
 次に、ステップS5では、検出時間カウンタ203のカウント値が増加し、やがて検出時間カウンタ203のカウント値と検出時間レジスタ204に記憶されている検出時間とが一致する。第2の比較器206は、検出時間レジスタ204に記憶されている検出時間と検出時間カウンタ203のカウント値とを比較し、両者が一致すると一致の比較結果を第1の比較器207に出力する。第1の比較器207は、第2の比較器206が検出時間レジスタ204に記憶されている検出時間と検出時間カウンタ203のカウント値とが一致する比較結果を出力すると、プログラムカウンタ202に記憶されているアドレスとプログラムカウンタ期待値レジスタ205に記憶されている期待値との比較結果を故障検出結果としてCPU201に出力する。
 図4のステップS5において、検出時間カウンタ203のカウント値が検出時間レジスタ204に記憶されている検出時間「b」と同じ値になる。この時、プログラムカウンタ202に記憶されているアドレスは例えば「c」であり、プログラムカウンタ期待値レジスタ205に記憶されている期待値「a」と異なる値になっている。その結果、第1の比較器207は、不一致の信号を出力する。
 CPU201は、第1の比較器207から故障検出結果として一致の信号を入力するとステップS6へ進み、第1の比較器207から故障検出結果として不一致の信号を入力するとステップS7へ進む。
 ステップS6では、CPU201は、CPU201の故障が検出されなかったと判断し、故障検出プログラムを終了する。
 ステップS7では、CPU201は、CPU201の故障が検出されたと判断し、例外処理ルーチンとして故障対策処理(故障に対応した処理プログラム)を実行する。例えば、故障対策処理は、CPU201の処理を止め、その代わりに他のCPUボード107内のCPUに処理させる処理である。また、故障対策処理は、マイクロコンピュータシステム全体の動作を安全に終了する処理、又は機能を限定して安全に走行させる等の処理である。図4のステップS7では、CPU201は、第1の比較器207から不一致の信号を入力し、例外ルーチンとして故障対策処理を行う。
 なお、他のCPUボード107内CPUが、第1の比較器207の不一致の出力信号を入力し、例外ルーチンとして故障対策処理を行ってもよい。
 図5は、本発明の第2の実施形態によるマイクロコンピュータ101の構成例を示すブロック図である。本実施形態のマイクロコンピュータ101(図5)は、第1の実施形態のマイクロコンピュータ101(図2)に対して、検出時間レジスタ204及び第2の比較器206を削除したものである。以下、本実施形態が第1の実施形態と異なる点を説明する。
 本実施形態では、図3のステップS2が削除される。図3のステップS3では、検出時間カウンタ203は、CPU201によりカウントの開始を指示されると、カウント値のダウンカウントを開始する。ダウンカウントにより、検出時間カウンタ203のカウント値は時間経過と共に減少する。具体的には、CPU201は、故障検出プログラムを実行すると、検出時間カウンタ203に上記の検出時間からのダウンカウントを開始させる。例えば、図4において、検出時間「b」からのダウンカウントを開始させる。図3のステップS5では、第1の比較器207は、検出時間カウンタ203のカウント値が0になると、プログラムカウンタ202に記憶されているアドレスとプログラムカウンタ期待値レジスタ205に記憶されている期待値との比較結果を故障検出結果として出力する。
 CPU201は、第1の比較器207から故障検出結果として一致の信号を入力するとステップS6へ進み、第1の比較器207から故障検出結果として不一致の信号を入力するとステップS7へ進む。ステップS6及びS7の処理は、第1の実施形態と同じである。
 以上のように、第1及び第2の実施形態によれば、第1の比較器207は、プログラムカウンタ202に記憶されているアドレスとプログラムカウンタ期待値レジスタ205に記憶されている期待値とを比較する。検出時間カウンタ203は、検出時間のカウントを行う。具体的には、CPU201は、故障検出プログラムを実行すると、故障検出プログラムの実行開始から検出時間後のプログラムカウンタ202が記憶するアドレスの期待値をプログラムカウンタ期待値レジスタ205に記憶させ、検出時間カウンタ203に上記の検出時間のカウントを開始させる。第1の実施形態では検出時間カウンタ203はアップカウントを行い、第2の実施形態では検出時間カウンタ203はダウンカウントを行う。第1の比較器207は、検出時間カウンタ203が上記の検出時間のカウントを終了すると、プログラムカウンタ202に記憶されているアドレスとプログラムカウンタ期待値レジスタ205に記憶されている期待値との比較結果を故障検出結果として出力する。
 上記のように、故障検出プログラムがCPU201の故障を検出する。故障検出プログラムを実行した際の、プログラムカウンタ202の期待値と、その期待値が出現する予定の検出時間を予め設定し、その予定の検出時間に、プログラムカウンタ202の期待値とプログラムカウンタ202の値を比較する。両者が不一致であれば、CPU201の故障が検出されたことになる。
 第1及び第2の実施形態によれば、プログラムの命令のフロー制御を直接的に検査することができるので、プログラムの命令フローを制御する回路の故障を検出することができる。
 なお、上記実施形態は、何れも本発明を実施するにあたっての具体化の例を示したものに過ぎず、これらによって本発明の技術的範囲が限定的に解釈されてはならないものである。すなわち、本発明はその技術思想、又はその主要な特徴から逸脱することなく、様々な形で実施することができる。
 プログラムの命令のフロー制御を直接的に検査することができるので、プログラムの命令フローを制御する回路の故障を検出することができる。

Claims (6)

  1.  プログラムの命令が実行される毎に次に実行すべきプログラムの命令のアドレスを更新して記憶するプログラムカウンタを含み、前記プログラムカウンタに記憶されているアドレスのプログラムの命令を順番に実行するCPUと、
     前記プログラムカウンタが記憶するアドレスの期待値を記憶するプログラムカウンタ期待値レジスタと、
     前記プログラムカウンタに記憶されているアドレスと前記プログラムカウンタ期待値レジスタに記憶されている期待値とを比較する第1の比較器と、
     検出時間のカウントを行う検出時間カウンタとを有し、
     前記CPUは、故障検出プログラムを実行すると、前記故障検出プログラムの実行開始から検出時間後の前記プログラムカウンタが記憶するアドレスの期待値を前記プログラムカウンタ期待値レジスタに記憶させ、前記検出時間カウンタに前記検出時間のカウントを開始させ、
     前記第1の比較器は、前記検出時間カウンタが前記検出時間のカウントを終了すると、前記プログラムカウンタに記憶されているアドレスと前記プログラムカウンタ期待値レジスタに記憶されている期待値との比較結果を故障検出結果として出力することを特徴とするマイクロコンピュータ。
  2.  前記CPUは、前記第1の比較器により不一致の比較結果が出力されると、前記CPUの故障が検出されたと判断し、故障対策処理を行うことを特徴とする請求項1記載のマイクロコンピュータ。
  3.  さらに、検出時間を記憶する検出時間レジスタと、
     前記検出時間レジスタに記憶されている検出時間と前記検出時間カウンタのカウント値とを比較する第2の比較器とを有し、
     前記検出時間カウンタは、前記CPUによりカウントの開始を指示されると、カウント値のアップカウントを開始し、
     前記CPUは、前記故障検出プログラムを実行すると、前記検出時間レジスタに前記検出時間を記憶させ、
     前記第1の比較器は、前記第2の比較器が前記検出時間レジスタに記憶されている検出時間と前記検出時間カウンタのカウント値とが一致する比較結果を出力すると、前記プログラムカウンタに記憶されているアドレスと前記プログラムカウンタ期待値レジスタに記憶されている期待値との比較結果を故障検出結果として出力することを特徴とする請求項1記載のマイクロコンピュータ。
  4.  前記CPUは、前記故障検出プログラムを実行すると、前記検出時間カウンタに0からのアップカウントを開始させることを特徴とする請求項3記載のマイクロコンピュータ。
  5.  前記検出時間カウンタは、前記CPUによりカウントの開始を指示されると、カウント値のダウンカウントを開始することを特徴とする請求項1記載のマイクロコンピュータ。
  6.  前記CPUは、前記故障検出プログラムを実行すると、前記検出時間カウンタに前記検出時間からのダウンカウントを開始させ、
     前記第1の比較器は、前記検出時間カウンタのカウント値が0になると、前記プログラムカウンタに記憶されているアドレスと前記プログラムカウンタ期待値レジスタに記憶されている期待値との比較結果を故障検出結果として出力することを特徴とする請求項5記載のマイクロコンピュータ。
PCT/JP2008/070669 2008-11-13 2008-11-13 マイクロコンピュータ WO2010055562A1 (ja)

Priority Applications (3)

Application Number Priority Date Filing Date Title
PCT/JP2008/070669 WO2010055562A1 (ja) 2008-11-13 2008-11-13 マイクロコンピュータ
JP2010537631A JP5115628B2 (ja) 2008-11-13 2008-11-13 マイクロコンピュータ
US13/102,158 US8522081B2 (en) 2008-11-13 2011-05-06 Microcomputer outputting failure detection result

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/JP2008/070669 WO2010055562A1 (ja) 2008-11-13 2008-11-13 マイクロコンピュータ

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US13/102,158 Continuation US8522081B2 (en) 2008-11-13 2011-05-06 Microcomputer outputting failure detection result

Publications (1)

Publication Number Publication Date
WO2010055562A1 true WO2010055562A1 (ja) 2010-05-20

Family

ID=42169711

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2008/070669 WO2010055562A1 (ja) 2008-11-13 2008-11-13 マイクロコンピュータ

Country Status (3)

Country Link
US (1) US8522081B2 (ja)
JP (1) JP5115628B2 (ja)
WO (1) WO2010055562A1 (ja)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2015136844A1 (ja) * 2014-03-14 2015-09-17 株式会社デンソー 電子制御装置

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10445168B2 (en) * 2013-06-18 2019-10-15 Nxp Usa, Inc. Device and method for executing a program, and method for storing a program

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH01140350A (ja) * 1987-11-27 1989-06-01 Nec Corp マイクロコンピュータのプログラム暴走検出回路
JPH0535892A (ja) * 1991-06-26 1993-02-12 Nec Ic Microcomput Syst Ltd マイクロコンピユータ
JPH05189255A (ja) * 1992-01-14 1993-07-30 Matsushita Electric Ind Co Ltd プログラム暴走検知方法
JPH10161908A (ja) * 1996-11-27 1998-06-19 Sharp Corp マイクロコンピュータの暴走検出方法
JPH1115699A (ja) * 1997-06-20 1999-01-22 Kansei Corp 車両用マイクロコンピュータのリセット機構
JP2001188688A (ja) * 2000-01-05 2001-07-10 Matsushita Electric Ind Co Ltd 暴走検知回路

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH052654A (ja) 1991-06-25 1993-01-08 Nissan Motor Co Ltd マイクロコンピユータの故障検知方法および回路
KR100337149B1 (ko) * 2000-07-05 2002-05-18 권 기 홍 프로그램 테스트 및 디버깅이 용이한 중앙처리장치
JP3698123B2 (ja) * 2002-06-25 2005-09-21 セイコーエプソン株式会社 情報処理装置及び電子機器
KR100586309B1 (ko) * 2004-02-23 2006-06-07 엔컴퓨팅 주식회사 다운로드 방식의 운영체제로 구동되는 네트워크 단말장치및 그 동작 방법
US7269764B2 (en) * 2004-06-18 2007-09-11 International Business Machines Corporation Monitoring VRM-induced memory errors
US8248425B2 (en) * 2009-09-16 2012-08-21 Ncomputing Inc. Optimization of memory bandwidth in a multi-display system

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH01140350A (ja) * 1987-11-27 1989-06-01 Nec Corp マイクロコンピュータのプログラム暴走検出回路
JPH0535892A (ja) * 1991-06-26 1993-02-12 Nec Ic Microcomput Syst Ltd マイクロコンピユータ
JPH05189255A (ja) * 1992-01-14 1993-07-30 Matsushita Electric Ind Co Ltd プログラム暴走検知方法
JPH10161908A (ja) * 1996-11-27 1998-06-19 Sharp Corp マイクロコンピュータの暴走検出方法
JPH1115699A (ja) * 1997-06-20 1999-01-22 Kansei Corp 車両用マイクロコンピュータのリセット機構
JP2001188688A (ja) * 2000-01-05 2001-07-10 Matsushita Electric Ind Co Ltd 暴走検知回路

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2015136844A1 (ja) * 2014-03-14 2015-09-17 株式会社デンソー 電子制御装置
JP2015176284A (ja) * 2014-03-14 2015-10-05 株式会社デンソー 電子制御装置
CN106104494A (zh) * 2014-03-14 2016-11-09 株式会社电装 电子控制装置

Also Published As

Publication number Publication date
JPWO2010055562A1 (ja) 2012-04-05
JP5115628B2 (ja) 2013-01-09
US20110209006A1 (en) 2011-08-25
US8522081B2 (en) 2013-08-27

Similar Documents

Publication Publication Date Title
US8819485B2 (en) Method and system for fault containment
JPH0528063A (ja) マイクロコンピユータ
CN1993679A (zh) 执行计算机程序的方法、操作系统和计算设备
US20120317576A1 (en) method for operating an arithmetic unit
JP2008513900A (ja) コンピュータシステム上でコンピュータプログラムを処理する方法
JP5115628B2 (ja) マイクロコンピュータ
TWI676889B (zh) 開機啟動資料有效性技術
JP5537140B2 (ja) 安全制御装置、及びその安全制御プログラム
CN109254898B (zh) 一种软件模块执行顺序监视方法及监视系统
US20190250578A1 (en) Method and device for computing data models in safety-critical systems
US8954794B2 (en) Method and system for detection of latent faults in microcontrollers
JP5226653B2 (ja) 車載制御装置
KR102603835B1 (ko) 프로세서 시스템의 프로그램 카운터 구조를 보호하고 인터럽트 요청의 처리를 모니터링하기 위한 방법 및 장치
CN108733502B (zh) 用于操作系统中的错误识别的方法
US10514970B2 (en) Method of ensuring operation of calculator
JP5978873B2 (ja) 電子制御装置
CN114718706A (zh) 传感器检测方法、装置和可读存储介质
WO2013073009A1 (ja) マイコンシステム、監視マイコン
KR20140039356A (ko) 소프트웨어 모듈의 오류 검출 장치 및 그 방법
US7844858B2 (en) Method for analyzing program errors
US20240007486A1 (en) Signal detection apparatus, vehicle, and method
US20230308456A1 (en) In-vehicle equipment, vehicle, and method
JP2012059127A (ja) 情報処理装置、ウォッチドッグタイマ、異常検出方法
JP2011232910A (ja) メモリ診断方式
JP2009282849A (ja) マイクロコンピュータ

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 08878108

Country of ref document: EP

Kind code of ref document: A1

WWE Wipo information: entry into national phase

Ref document number: 2010537631

Country of ref document: JP

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 08878108

Country of ref document: EP

Kind code of ref document: A1