JP5176646B2 - Error correction function confirmation circuit, error correction function confirmation method, computer program thereof, and storage device - Google Patents
Error correction function confirmation circuit, error correction function confirmation method, computer program thereof, and storage device Download PDFInfo
- Publication number
- JP5176646B2 JP5176646B2 JP2008086965A JP2008086965A JP5176646B2 JP 5176646 B2 JP5176646 B2 JP 5176646B2 JP 2008086965 A JP2008086965 A JP 2008086965A JP 2008086965 A JP2008086965 A JP 2008086965A JP 5176646 B2 JP5176646 B2 JP 5176646B2
- Authority
- JP
- Japan
- Prior art keywords
- data
- circuit
- bits
- storage device
- error correction
- 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
Links
Images
Description
本発明は、ランダムアクセスメモリ(Random Access Memory、以下、RAMと表記する。)などの記憶装置に関する。特に、記憶装置における誤り訂正符号(Error Correcting Code、以下、ECCと表記する。)回路のECC機能を確認する回路及び方法等に関する。 The present invention relates to a storage device such as a random access memory (hereinafter referred to as RAM). In particular, the present invention relates to a circuit and method for confirming the ECC function of an error correcting code (hereinafter referred to as ECC) circuit in a storage device.
RAMなどの記憶装置においては、α線などを原因としたソフトエラーが生じることがある。そのため、このようなエラーを訂正できるECC回路が備えられることがある。 In a storage device such as a RAM, a soft error may occur due to α rays or the like. Therefore, an ECC circuit that can correct such an error may be provided.
ECC回路のECC機能を確認する技術としては、例えば特許文献1がある。特許文献1に開示された背景技術では、本来のデータである実データと、データの誤りを訂正するために実データとは別に付加されるECCデータとのそれぞれに、データ反転回路が備えられる。予め設定されたビット反転データにしたがって、データ反転回路により書き込みデータの所定ビットが反転される。これにより擬似的なエラーが生じる。 As a technique for confirming the ECC function of the ECC circuit, there is, for example, Patent Document 1. In the background art disclosed in Patent Document 1, a data inversion circuit is provided for each of actual data that is original data and ECC data that is added separately from the actual data in order to correct an error in the data. A predetermined bit of write data is inverted by the data inversion circuit in accordance with preset bit inversion data. This causes a pseudo error.
この他、ECC回路を介さずRAMに直接データを書き込みできるような機能を設けて、ソフトウェアにより擬似的なエラーを発生させるという方法も考えられる。例えば、ソフトウェアにより、RAMから一旦読み出されたデータをもとに任意のビットのみが反転されたデータが生成され、ECC回路を介さずRAMに直接書き込みし直される。これにより擬似的なエラーが生じる。 In addition, a method of providing a function capable of directly writing data to the RAM without using an ECC circuit and generating a pseudo error by software is also conceivable. For example, software in which only an arbitrary bit is inverted based on data once read from the RAM is generated by software, and directly written into the RAM without going through the ECC circuit. This causes a pseudo error.
しかしながら、特許文献1に開示された技術では、例えばフリップフロップなど、データ反転を指示するためのビット反転データを設定・記憶する回路を余計に設ける必要がある。 However, in the technique disclosed in Patent Document 1, it is necessary to provide an extra circuit for setting and storing bit inversion data for instructing data inversion, such as a flip-flop.
また、一般にECC機能を確認する際には、多様なパターンのエラーに対して確認を行うために、反転されるビットが頻繁に変更される必要がある。特許文献1に記載の技術と、上述されたソフトウェアによる方法との何れにおいても、反転されるビットを変更するためには、レジスタを書き換える必要がある。ECC機能の確認を容易に効率よく行いたいところ、これは非常に手間である。 In general, when checking the ECC function, it is necessary to frequently change the bit to be inverted in order to check various patterns of errors. In any of the technique described in Patent Document 1 and the above-described software method, it is necessary to rewrite the register in order to change the bit to be inverted. This is very troublesome when it is desired to easily and efficiently check the ECC function.
本発明は上記の課題に鑑み提案されたものである。本発明は、ECC機能の確認を容易に、かつ効率よく行うことが可能なECC機能確認回路及びECC機能確認方法とそのコンピュータプログラム、並びに記憶装置を提供することを目的とする。 The present invention has been proposed in view of the above problems. An object of the present invention is to provide an ECC function confirmation circuit, an ECC function confirmation method, a computer program thereof, and a storage device that can easily and efficiently confirm an ECC function.
本発明にかかるECC機能確認回路は、記憶装置の誤り訂正機能を確認するためのものである。ECC生成回路と、データ反転回路と、ECC誤り検出回路とを有する。ECC生成回路は、書き込みデータに誤り訂正データを加えて記憶装置に格納する。データ反転回路は、記憶装置の出力データを上位側Nビットと下位側Nビットに2分割し、出力データの上位側Nビットまたは下位側Nビットの一方と書き込みデータの下位側Nビットとを排他的論理和演算する。排他的論理和演算結果と出力データの上位側Nビットまたは下位側Nビットの他方を結合して生成したデータを、記憶装置のECC生成回路が格納したデータに上書きする。ECC誤り検出回路は、データ反転回路が上書きをした後に、記憶装置の出力データから誤りが発生しているビットを検出することを特徴とする。 The ECC function confirmation circuit according to the present invention is for confirming an error correction function of a storage device . An ECC generation circuit, a data inversion circuit, and an ECC error detection circuit are included. The ECC generation circuit adds error correction data to the write data and stores it in the storage device. The data inversion circuit divides the output data of the memory device into two parts, upper N bits and lower N bits, and excludes either the upper N bits or the lower N bits of the output data and the lower N bits of the write data Perform logical OR operation. Data generated by combining the result of the exclusive OR operation and the other of the upper N bits or the lower N bits of the output data is overwritten on the data stored in the ECC generation circuit of the storage device. The ECC error detection circuit is characterized by detecting a bit in which an error has occurred from the output data of the storage device after the data inversion circuit overwrites the data .
また、本発明にかかるECC機能確認方法は、上記の誤り訂正機能確認回路を用いてECC機能を確認するものである。 The ECC function confirmation method according to the present invention is for confirming the ECC function using the error correction function confirmation circuit.
まず、記憶装置の誤り訂正機能を確認する誤り訂正機能確認方法において、書き込みデータに誤り訂正データを加え記憶装置に格納し、記憶装置の出力データを上位側Nビットと下位側Nビットに2分割し、出力データの上位側Nビットまたは下位側Nビットの一方と書き込みデータの下位側Nビットとを排他的論理和演算し、排他的論理和演算結果と出力データの上位側Nビットまたは下位側Nビットの他方を結合して生成したデータを、記憶装置のECC生成回路が格納したデータに上書きし、データ反転回路が上書きをした後に、記憶装置の出力データから誤りが発生しているビットを検出する。 First, in the error correction function confirmation method for confirming the error correction function of the storage device, the error correction data is added to the write data and stored in the storage device, and the output data of the storage device is divided into upper N bits and lower N bits. Then, an exclusive OR operation is performed on one of the upper N bits or the lower N bits of the output data and the lower N bit of the write data, and the result of the exclusive OR operation and the upper N bits or the lower side of the output data The data generated by combining the other of the N bits is overwritten on the data stored by the ECC generation circuit of the storage device, and after the data inversion circuit overwrites, the bit in which an error has occurred from the output data of the storage device Detect .
また、本発明にかかる記憶装置は、上記の誤り訂正機能確認回路を備える。 A storage device according to the present invention includes the error correction function confirmation circuit.
これらにより、本発明では、データ反転を指示するためのビット反転データを設定・記憶する回路を特許文献1のように余計に設ける必要がなくなる。データ反転の指示は記憶装置への書き込みデータにより与えられるので、反転されるビットを変更するための頻繁なレジスタの書き換えが必要でなくなる。 Thus, according to the present invention, it is not necessary to provide an extra circuit for setting and storing bit inversion data for instructing data inversion as in Patent Document 1. Since the data inversion instruction is given by the write data to the storage device, it is not necessary to frequently rewrite the register to change the bit to be inverted.
本発明にかかるECC機能確認回路及びECC機能確認方法とそのコンピュータプログラム、並びに記憶装置によれば、ECC機能の確認を容易に、かつ効率よく行うことが可能となる。 According to the ECC function confirmation circuit, the ECC function confirmation method, the computer program, and the storage device according to the present invention, the ECC function can be confirmed easily and efficiently.
図1は本発明にかかるECC機能確認回路の全体構成について、第1実施形態を示すブロック図である。CPU1の出力は、ECC生成回路2の入力及びデータ反転回路3の入力と、それぞれ32ビットのバスで接続される。CPU1は、書き込みデータであるWDATA[31:0]を出力する。
FIG. 1 is a block diagram showing a first embodiment of the overall configuration of an ECC function confirmation circuit according to the present invention. The output of the CPU 1 is connected to the input of the
ECC生成回路2の出力及びデータ反転回路3の出力は、それぞれセレクタ4の入力と48ビットのバスで接続される。第1実施形態では、WDATA[31:0]の8ビットごとに誤り訂正用データ4ビットが付加されて、1ビットの誤りが訂正される。そのため、ECC生成回路2では、WDATA[31:0]に対応する誤り訂正用データであるECCDATA[15:0]が生成され、WDATA[31:0]+ECCDATA[15:0]が出力される。
The output of the
一方、データ反転回路3には、WDATA[31:0]の他に、48ビット保持レジスタ7の出力データであるKDATA[47:0]が入力され、CDATA[47:0]が出力される。
On the other hand, in addition to WDATA [31: 0], KDATA [47: 0], which is output data of the 48-bit holding register 7, is input to the
セレクタ4の出力は、ECCRAM5の入力と48ビットのバスで接続される。セレクタ4では、ECCOFF信号に応じて、入力端子0からの入力WDATA[31:0]+ECCDATA[15:0]と、入力端子1からの入力CDATA[47:0]との2つの入力のうちどちらかが選択され、出力される。
The output of the selector 4 is connected to the input of the ECCRAM 5 via a 48-bit bus. In the selector 4, in accordance with the ECCOFF signal, whichever of the two inputs of input WDATA [31: 0] + ECCDATA [15: 0] from the
ECCRAM5の出力は、ECC誤り検出訂正回路6の入力及び48ビット保持レジスタ7の入力と、それぞれ48ビットのバスで接続される。ECCRAM5はCPU1の主記憶装置であり、WDATA[31:0]とそれに対応するECCDATA[15:0]とを格納する。CPU1からのリード指示に応じて、ECCRAM5に格納されているデータが読み出される。
The output of the ECCRAM 5 is connected to the input of the ECC error detection and
ECC誤り検出訂正回路6の出力は、CPU1の入力と32ビットのバスで接続される。ECC誤り検出訂正回路6では、ECCRAM5から読み出されたデータの誤りが検出され、誤りが訂正されたデータであるRDATA[31:0]が出力される。
The output of the ECC error detection and
48ビット保持レジスタ7の出力は、データ反転回路3の入力と48ビットのバスで接続される。48ビット保持レジスタ7では、ECCRAM5からの読み出しデータが保持され、保持されたデータであるKDATA[47:0]が出力される。
The output of the 48-bit holding register 7 is connected to the input of the
このように構成された第1実施形態の作用について説明する。ECCRAM5への書き込みデータWDATA[31:0]が、CPU1から出力される。ECC生成回路2は、WDATA[31:0]に対応するECCDATA[15:0]を生成する。WDATA[31:0]にECCDATA[15:0]が付加されたWDATA[31:0]+ECCDATA[15:0]が出力される。通常、ECC機能は有効とされるため、ECCOFF信号は0(Lレベル)である。そのため、セレクタ4は入力端子0からの入力WDATA[31:0]+ECCDATA[15:0]を選択して出力する。ECCRAM5には、WDATA[31:0]+ECCDATA[15:0]が書き込まれる。
The operation of the first embodiment configured as described above will be described. Write data WDATA [31: 0] to the ECCRAM 5 is output from the CPU 1. The
ECC機能を確認する際は、擬似的なエラーを発生させるために、一旦ECC機能は無効とされるので、ECCOFF信号は1(Hレベル)とされる。ECCRAM5に格納されているWDATA[31:0]+ECCDATA[15:0]が読み出され、48ビット保持レジスタ7により保持される。データ反転を指示するWDATA[31:0]が、CPU1から出力される。データ反転回路3は、WDATA[31:0]によりデータ反転の指示が与えられて、48ビット保持レジスタ7から出力されるKDATA[47:0]の所定ビットを反転する。データ反転回路3は、KDATA[47:0]の所定ビットが反転されたデータであるCDATA[47:0]を出力する。ECCOFF信号は1であるので、セレクタ4は入力端子1からの入力CDATA[47:0]を選択して出力する。ECCRAM5には、CDATA[47:0]が上書きされる。これにより、擬似的なエラーが生じる。
When checking the ECC function, the ECC function is once invalidated in order to generate a pseudo error, so the ECCOFF signal is set to 1 (H level). WDATA [31: 0] + ECCATA [15: 0] stored in the ECCRAM 5 is read and held in the 48-bit holding register 7. WDATA [31: 0] instructing data inversion is output from the CPU 1. The
ECCOFF信号が0(Lレベル)に戻され、ECC機能が有効とされる。ECCRAM5に格納されているCDATA[47:0]が読み出され、ECC誤り検出訂正回路6に入力される。CDATA[47:0]は所定ビットが反転されているため、ECC誤り検出訂正回路6により誤りが検出され、誤りが訂正されたデータであるRDATA[31:0]が出力される。RDATA[31:0]と元の書き込みデータであるWDATA[31:0]とが一致するか否かを確認するなどすれば、ECC機能が正しく動作したか否かを確認することができる。
The ECCOFF signal is returned to 0 (L level), and the ECC function is enabled. CDATA [47: 0] stored in the ECCRAM 5 is read and input to the ECC error detection and
図2を参照して、データ反転回路3について詳細に説明する。図2はデータ反転回路3の内部構成の一例を示すブロック図である。図1で説明されたように、データ反転回路3には、WDATA[31:0]とKDATA[47:0]とが入力される。32ビットのWDATA[31:0]によりデータ反転の指示が与えられて、48ビットのKDATA[47:0]の所定ビットが反転される。そのため、KDATA[47:0]は、データ反転回路3の内部で、上位24ビットのKDATA[47:24]と下位24ビットのKDATA[23:0]とに分割される。24ビットずつに分割されたKDATA[47:24]とKDATA[23:0]とに対して、WDATA[31:0]の下位24ビットであるWDATA[23:0]により反転されるビットが指示される。
The
データ反転回路3は、EORゲート31、32を備える。EORゲート31には、WDATA[23:0]とKDATA[47:24]とが入力される。EORゲート32には、WDATA[23:0]とKDATA[23:0]とが入力される。EORゲート31の出力はセレクタ33の入力端子1に、EORゲート32の出力はセレクタ34の入力端子0にそれぞれ入力される。セレクタ33の他方の入力端子0にはKDATA[47:24]が、セレクタ34の他方の入力端子1にはKDATA[23:0]がそれぞれ入力される。セレクタ33、34はともにWDATA[31:0]の最上位ビットであるWDATA[31]に応じて、2つの入力のうちどちらかを選択して、出力する。セレクタ33の出力CDATA[47:24]と、セレクタ34の出力CDATA[23:0]とが、データ反転回路3の出力CDATA[47:0]となる。
The
例えば、KDATA[47:24]に含まれるビットが反転される場合、WDATA[31:0]は、最上位ビットWDATA[31]が1(Hレベル)で、下位24ビットWDATA[23:0]のうち反転されるKDATA[47:24]のビットに対応するビットが1(Hレベル)であるWDATA[31:0]がCPU1から出力される。EORゲート31により、WDATA[23:0]の1(Hレベル)となっているビットに対応するKDATA[47:24]のビットが反転される。WDATA[31:0]の最上位ビットWDATA[31]は1(Hレベル)なので、セレクタ33は入力端子1からの入力を選択して、出力する。したがって、EORゲート31の出力、すなわち、KDATA[47:24]の所定ビットが反転されたデータが選択されて、出力される。一方、セレクタ34はKDATA[23:0]を選択して、出力する。
For example, when the bits included in KDATA [47:24] are inverted, WDATA [31: 0] has the most significant bit WDATA [31] of 1 (H level) and the lower 24 bits WDATA [23: 0]. CPU 1 outputs WDATA [31: 0] in which the bit corresponding to the inverted KDATA [47:24] bit is 1 (H level). The
図1に示されたように、第1実施形態は、CPU1のデータバス幅32ビットを超える48ビットのECCRAM5を搭載した構成となっている。しかし、図2に示されるように、KDATA[47:0]が上位24ビット、下位24ビットに分割される。WDATA[31:0]の最上位ビットWDATA[31]により、KDATA[47:0]の上位、下位のどちらに含まれるビットが反転されるのかが切り替えられる。これにより、KDATA[47:0]の任意のビットを反転させることができる。したがって、ECCRAM5に格納されているデータに対して、任意のエラーを擬似的に発生させることが可能となる。データ反転の指示はWDATA[31:0]により与えられるため、データ反転を指示するためのビット反転データを設定・記憶する回路を特許文献1のように余計に設ける必要がなくなる。また、反転されるビットを変更するために頻繁にレジスタを書き換える必要がなくなる。
As shown in FIG. 1, the first embodiment has a configuration in which a 48-
図3は本発明にかかるECC機能確認回路の全体構成について、第2実施形態を示すブロック図である。第2実施形態では、書き込み動作時におけるECCRAM5は、直前の読み出しデータを保持し、出力する。そのため、第2実施形態では、ECCRAM5からの読み出しデータが保持される48ビット保持レジスタ7が不要であり、ECCRAM5の出力はデータ反転回路3の入力と接続される。
FIG. 3 is a block diagram showing a second embodiment of the overall configuration of the ECC function confirmation circuit according to the present invention. In the second embodiment, the
図3に示される第2実施形態は、制御信号生成部8を備える。制御信号生成部8には、CPU1からCPU.ADD信号とCPU.WRX信号とが入力される。制御信号生成部8は、ECCOFF信号に応じて、READY信号をCPU1に出力する。また、制御信号生成部8は、ECCRAM5にRAM.ADD信号とRAM.WRX信号とを出力する。その他の構成は図1に示される第1実施形態と同様なため、説明を省略する。
The second embodiment shown in FIG. 3 includes a control
このように構成された第2実施形態の作用について、図4のタイミング図を参照しながら説明する。図4は、図3に示される第2実施形態でのECC機能の確認において、ECCRAM5から読み出しデータKDATA[47:0]が読み出され、データ反転回路3により所定ビットが反転されたデータCDATA[47:0]がECCRAM5に上書きされて擬似的なエラーが生じるまでのタイミング図を示す。ここで、図4は、Advanced High-performance Bus(以下、AHBと表記する。)を例としたタイミング図である。AHBとは、バスの仕様として規定されているものである。なお、図4のタイミング図は、一般的にAHBで使用される信号名ではなく、図3にあわせた信号名を用いて記載されている。AHBで一般的に使用される信号名への置き換えは、それぞれ、CKをHCLK、CPU.ADDRをCPU.HADDR、CPU.WRXをCPU.HWRITEの反転、READYをHREADYとすることで可能である。
The operation of the second embodiment configured as described above will be described with reference to the timing chart of FIG. FIG. 4 shows data CDATA [47] in which read data KDATA [47: 0] is read from the
既に説明されたように、擬似的なエラーを発生させるために、ECCRAM5は読み出し動作の後、書き込み動作を行う。したがって、CPU1はECCRAM5に対して、リード→ライトと指示する。そのとき、CPU1によってはダミーリードが入る場合がある。ダミーリードが入ってしまった場合、意図されていないデータが読み出されてしまうおそれがある。そのため、図3に示される第2実施形態では、CPU1からのライト指示のみによってECCRAM5が読み出し動作の後、書き込み動作を行う構成となっている。
As already described, in order to generate a pseudo error, the
図4において、CK信号はクロックであり、cyc1〜cyc5はその周期である。CPU.ADD信号はCPU1がアドレスを示す信号であり、CPU.WRX信号はCPU1がライトを指示する信号である。CPU.WDATA信号は、図3においてCPU1が出力する書き込みデータWDATA[31:0]に対応する。READY信号は、CPU1にウェイトをかける信号である。すなわち、READY信号が出ている間は、CPU1は次の指示を出さない。RAM.CE信号は図3には図示されていないが、一般的なアドレスデコーダからECCRAM5に入力される信号である。RAM.ADD信号はECCRAM5がアドレスを示される信号であり、RAM.WRX信号はECCRAM5がライトを指示される信号である。第2実施形態では、ECCRAM5はRAM.CE信号がLレベル、かつRAM.WRX信号がLレベルで書き込み動作を行う。ECCRAM5はRAM.CE信号がLレベル、かつRAM.WRX信号がHレベルで読み出し動作を行う。RAM.RDATA信号は、図3においてECCRAM5が出力する読み出しデータKDATA[47:0]に対応する。RAM.WDATA信号は、図3においてデータ反転回路3が出力するデータCDATA[47:0]に対応する。
In FIG. 4, a CK signal is a clock, and cyc1 to cyc5 are periods thereof. CPU. The ADD signal is a signal that the CPU 1 indicates an address. The WRX signal is a signal that the CPU 1 instructs to write. CPU. The WDATA signal corresponds to the write data WDATA [31: 0] output by the CPU 1 in FIG. The READY signal is a signal for applying a wait to the CPU 1. That is, while the READY signal is output, the CPU 1 does not issue the next instruction. RAM. The CE signal is not shown in FIG. 3, but is a signal input to the
前述の通り、ECC機能を確認する際は、擬似的なエラーを発生させるために、ECCOFF信号が1(Hレベル)とされる(cyc1〜cyc5)。CPU1は、CPU.ADD信号によりECC機能確認対象アドレスAAを示し(cyc2)、CPU.WRX信号によりライトを指示し(cyc2)、CPU.WDATA信号を書き込みデータWAとする(cyc3)。ECCOFF信号が1(Hレベル)のとき、制御信号生成部8は、CPU.WRX信号によるライト指示を受けて、CPU1に対してREADY信号を出力する(cyc3)。そのため、CPU1は次の指示を出さず、CPU.WDATA信号が書き込みデータWAのまま維持される(cyc4)。また、ECCRAM5は制御信号生成部8から、RAM.ADD信号によりアドレスAAを示され(cyc3〜cyc4)、RAM.WRX信号によりcyc3ではリードを、cyc4ではライトを指示される(cyc3〜cyc4)。一方、RAM.CE信号がECCRAM5に入力される(cyc3〜cyc4)。
As described above, when checking the ECC function, the ECCOFF signal is set to 1 (H level) in order to generate a pseudo error (cyc1 to cyc5). CPU1 is CPU. The ECC function confirmation target address AA is indicated by the ADD signal (cyc2). Write is instructed by the WRX signal (cyc2), and CPU. The WDATA signal is set as write data WA (cyc3). When the ECCOFF signal is 1 (H level), the control
周期cyc3において、RAM.CE信号がLレベル、かつRAM.WRX信号がHレベルなので、ECCRAM5はRAM.ADD信号により示されるアドレスAAから読み出し動作を行う。RAM.RDATA信号は、アドレスAAから読み出されたデータRAとなる。
In the cycle cyc3, the RAM. CE signal is at L level and RAM. Since the WRX signal is H level, the
周期cyc4において、RAM.CE信号がLレベル、かつRAM.WRX信号がLレベルなので、ECCRAM5はRAM.ADD信号により示されるアドレスAAに書き込み動作を行う。前述の通り、第2実施形態では、書き込み動作時におけるECCRAM5は、直前の読み出しデータを保持し、出力する。そのため、RAM.RDATA信号は、データRAのままである。したがって、データ反転回路3は、CPU.WDATA信号の書き込みデータWAによりデータ反転の指示が与えられて、データRAの所定ビットが反転されたデータWA^RAを出力する。すなわち、RAM.WDATA信号は、データWA^RAとなる。ECCOFF信号は1(Hレベル)であるので、データWA^RAがセレクタ4を介してECCRAM5のアドレスAAに書き込まれる。
In the cycle cyc4, the RAM. CE signal is at L level and RAM. Since the WRX signal is L level, the
このように、ECCOFF信号が1(Hレベル)のとき、制御信号生成部8がCPU.WRX信号によるライト指示を受けて、CPU1に対してREADY信号を出力し、CPU1にウェイトをかける。READY信号が出ている間CPU1は次の指示を出さず、CPU.WDATA信号が書き込みデータWAのまま周期cyc4まで維持される。制御信号生成部8がRAM.WRX信号によるライト指示を周期cyc3ではなく、周期cyc4に出力することで、CPU1からのライト指示のみによってECCRAM5が読み出し動作(cyc3)の後、書き込み動作(cyc4)を行うことが可能となる。その結果、ダミーリードにより意図されていないデータが読み出されてしまうおそれがなくなる。
Thus, when the ECCOFF signal is 1 (H level), the control
なお、CPU1からのライト指示のみによってECCRAM5が読み出し動作の後、書き込み動作を行う構成であっても、CPU1は通常のリード指示を出すことは可能である。CPU1が通常のリード指示を出した場合、CPU1にはECC誤り検出訂正回路6による誤り検出訂正を経たデータRDATA[31:0]が入力される。そのため、ECCRAM5のECC機能確認対象となっている領域以外からECC機能確認プログラムなどを読み出す際には、ECC機能が有効とされる。したがって、ECC機能確認の際、ECC機能確認対象となっている領域以外でソフトエラーが生じても問題はない。
Even if the
また、書き込み動作時におけるECCRAM5は、直前の読み出しデータを保持し、出力するようにしたため、第2実施形態では、48ビット保持レジスタ7が不要である。したがって、回路が小さくて済むという効果がある。
In addition, since the
図5を参照して、第2実施形態におけるECC機能確認方法について説明する。図5は、第2実施形態のECC機能確認のフローを示す。最初は反転指示モードがオフとされる(S1)。このステップS1は、ECCOFF信号が0(Lレベル)とされることで実行される。 With reference to FIG. 5, the ECC function confirmation method in 2nd Embodiment is demonstrated. FIG. 5 shows a flow of ECC function confirmation according to the second embodiment. Initially, the reverse instruction mode is turned off (S1). This step S1 is executed when the ECCOFF signal is set to 0 (L level).
ECC機能確認対象アドレスに対して、任意の書き込みデータWDATA[31:0]のライトが指示される(S2)。ECCOFF信号は0(Lレベル)とされているので、ECC生成回路2によりECCDATA[15:0]が付加されたWDATA[31:0]+ECCDATA[15:0]が、セレクタ4を介してECCRAM5に書き込まれる。
Arbitrary write data WDATA [31: 0] is instructed to be written to the ECC function confirmation target address (S2). Since the ECCOFF signal is set to 0 (L level), WDATA [31: 0] + ECCATA [15: 0] to which ECCDATA [15: 0] is added by the
ECCOFF信号が1(Hレベル)とされて、反転指示モードがオンとされる(S3)。 The ECCOFF signal is set to 1 (H level), and the inversion instruction mode is turned on (S3).
データリード(S4)と反転指示データライト(S5)は、ECC機能確認対象アドレスに対して、任意のビットを反転させるような書き込みデータWDATA[31:0]のライトが指示されることで実行される。これにより、図4で説明されたように、制御信号生成部8に従って、ECCRAM5は読み出し動作の後、書き込み動作を行う。つまり、ECCRAM5から読み出しデータKDATA[47:0]が読み出される。ECCRAM5への書き込みデータWDATA[31:0]によりデータ反転の指示が与えられて、読み出しデータKDATA[47:0]の所定ビットが反転されたデータCDATA[47:0]が、セレクタ4を介してECCRAM5に上書きされる。なお、ステップS4、S5は、その後にレジスタ書き換え等の他の処理を挟むことなく、任意のアドレス、任意のデータに対し繰り返し行うことができる。
The data read (S4) and the inversion instruction data write (S5) are executed by instructing the write of the write data WDATA [31: 0] that inverts an arbitrary bit to the ECC function confirmation target address. The Accordingly, as described with reference to FIG. 4, the
ECCOFF信号が0(Lレベル)とされて、反転指示モードがオフとされる(S6)。 The ECCOFF signal is set to 0 (L level), and the inversion instruction mode is turned off (S6).
ECC機能確認対象アドレスに対して、リードが指示される(S7)。読み出しデータKDATA[47:0]の所定ビットの反転により生じた擬似的なエラーについて、ECC誤り検出訂正回路6により誤りが検出され、誤りが訂正されたデータであるRDATA[31:0]が出力される。
Read is instructed to the ECC function confirmation target address (S7). An error is detected by the ECC error detection and
ECC機能が正しく動作したか否かが確認される(S8)。このステップS8は、例えば、RDATA[31:0]と準備された期待値とを比較し、一致不一致を確認することで実行されたり、一般的なエラー発生ビットにより確認することで実行されたりする。 It is confirmed whether or not the ECC function has been operated correctly (S8). This step S8 is executed, for example, by comparing RDATA [31: 0] with the prepared expected value and confirming a coincidence / mismatch, or by confirming with a general error occurrence bit. .
このように、第2実施形態においても第1実施形態と同様に、任意のエラーを擬似的に発生させることが可能となる。データ反転の指示はWDATA[31:0]により与えられるため、データ反転を指示するためのビット反転データを設定・記憶する回路を特許文献1のように余計に設ける必要がなく、反転されるビットを変更するために頻繁にレジスタを書き換える必要がなくなる。 As described above, also in the second embodiment, it is possible to generate an arbitrary error in a pseudo manner as in the first embodiment. Since the data inversion instruction is given by WDATA [31: 0], it is not necessary to provide an extra circuit for setting and storing the bit inversion data for instructing the data inversion as in Patent Document 1, and the bit to be inverted There is no need to rewrite the register frequently to change
ここで、特許請求の範囲との対応は以下の通りである。
ECCRAM5は、記憶装置の一例である。
ECC生成回路2、ECCRAM5、及びECC誤り検出訂正回路6は、誤り訂正回路の一例である。
WDATA[31:0]は、書き込みデータの一例である。
KDATA[47:0]は、読み出しデータの一例である。
CDATA[47:0]は、所定ビットが反転されたデータの一例である。
データ反転回路3は、データ反転回路の一例である。
セレクタ4は、選択する回路の一例である。
48ビット保持レジスタ7は、保持する回路の一例である。
EORゲート31、32は、データ反転回路が備えるEORゲートの一例である。
データライトのステップS2は、記憶装置に書き込みデータが書き込まれるステップの一例である。
データリードのステップS4は、記憶装置から読み出しデータが読み出されるステップの一例である。
反転指示データライトのステップS5は、所定ビットが反転されたデータが記憶装置に上書きされるステップの一例である。
データリードのステップS7とECC機能確認のステップS8とは、記憶装置から上書きされたデータが読み出されて、誤り訂正回路の誤り訂正機能が確認されるステップの一例である。
Here, the correspondence with the claims is as follows.
The
The
WDATA [31: 0] is an example of write data.
KDATA [47: 0] is an example of read data.
CDATA [47: 0] is an example of data in which a predetermined bit is inverted.
The
The selector 4 is an example of a circuit to be selected.
The 48-bit holding register 7 is an example of a holding circuit.
The
The data write step S2 is an example of a step in which write data is written to the storage device.
The data read step S4 is an example of a step in which read data is read from the storage device.
The inversion instruction data write step S5 is an example of a step in which data in which a predetermined bit is inverted is overwritten in the storage device.
Data read step S7 and ECC function confirmation step S8 are examples of steps in which the overwritten data is read from the storage device and the error correction function of the error correction circuit is confirmed.
以上、詳細に説明したように、本発明の第1実施形態によれば、ECC機能を確認する際には、ECCRAM5からの読み出しデータKDATA[47:0]の所定ビットを反転するデータ反転回路3により擬似的なエラーが生じる。このデータ反転回路3に対して、ECCRAM5への書き込みデータWDATA[31:0]によりデータ反転の指示が与えられる。
As described above in detail, according to the first embodiment of the present invention, when the ECC function is confirmed, the
また、データ反転回路3では、ECCRAM5からの48ビットの読み出しデータKDATA[47:0]が上位24ビット、下位24ビットに分割される。32ビットの書き込みデータWDATA[31:0]の最上位ビットWDATA[31]により、KDATA[47:0]の上位、下位のどちらに含まれるビットが反転されるのかが切り替えられる。
In the
これにより、KDATA[47:0]の任意のビットを反転させることができる。第1実施形態のようにCPU1のデータバス幅32ビットを超える48ビットのECCRAM5を搭載した構成においても、ECCRAM5に格納されているデータに対して、任意のエラーを擬似的に発生させることが可能となる。データ反転の指示はWDATA[31:0]により与えられるため、データ反転を指示するためのビット反転データを設定・記憶する回路を特許文献1のように余計に設ける必要がなくなる。また、反転されるビットを変更するために頻繁にレジスタを書き換える必要がなくなる。ECC機能の確認を容易に、かつ効率よく行うことが可能となる。
Thereby, an arbitrary bit of KDATA [47: 0] can be inverted. Even in the configuration in which the 48-
また、本発明の第2実施形態によっても、第1実施形態と同様の効果が得られる。加えて、第2実施形態では、制御信号生成部8がCPU1からのCPU.WRX信号によるライト指示を受けて、CPU1に対してREADY信号を出力し、CPU1にウェイトをかける。これにより、CPU1からのライト指示のみによってECCRAM5が読み出し動作の後、書き込み動作を行うことが可能となる。その結果、ダミーリードにより意図されていないデータが読み出されてしまうおそれがなくなる。第2実施形態では、書き込み動作時におけるECCRAM5は、直前の読み出しデータを保持し、出力するようにしたため、48ビット保持レジスタ7が不要である。したがって、回路が小さくて済むという効果がある。
Also, the second embodiment of the present invention can provide the same effects as those of the first embodiment. In addition, in the second embodiment, the control
なお、本発明は前記実施形態に限定されるものではなく、本発明の趣旨を逸脱しない範囲内での種々の改良、変更が可能であることは言うまでもない。
例えば、図5に示される第2実施形態のECC機能確認のフローでは、ステップS2において、任意の書き込みデータWDATA[31:0]のライトが指示されるが、これに限られるものではない。通常は、起動時に記憶装置の全面ライトによって初期化が行われるので、それを用いてもよい。
Note that the present invention is not limited to the above-described embodiment, and it goes without saying that various improvements and modifications can be made without departing from the spirit of the present invention.
For example, in the ECC function confirmation flow of the second embodiment shown in FIG. 5, the write of arbitrary write data WDATA [31: 0] is instructed in step S2, but the present invention is not limited to this. Usually, since initialization is performed by full-surface writing of the storage device at the time of activation, it may be used.
図1に示される第1実施形態と図3に示される第2実施形態とはともに、ECC生成回路2、及びECC誤り検出訂正回路6がECCRAM5とは別にされた構成で示されている。しかし、これに限られない。ECCRAM5がECC生成及びECC誤り検出訂正を含むような構成であってもよい。
In both the first embodiment shown in FIG. 1 and the second embodiment shown in FIG. 3, the
また、データ反転回路3に入力される読み出しデータKDATA[47:0]はECCRAM5の出力から取られているが、ECC誤り検出訂正回路6の出力から取られるようにされてもよい。この構成の場合は、ECCOFF信号に応じてECC誤り検出訂正の有効、無効を切り替えるようなセレクタをECC誤り検出訂正回路6の後段に設けるなどすれば、前記実施形態と同様の効果が得られる。さらに、そのセレクタにライト指示を示すような信号を入力すれば、CPU1からのライト指示のみによってECCRAM5が読み出し動作の後、書き込み動作を行う構成であっても、ECC機能を有効にした読み出し動作が可能になる。したがって、ECC機能確認の際、ECC機能確認対象となっている領域以外でソフトエラーが生じても前記第2実施形態と同様に問題がない。
Further, the read data KDATA [47: 0] input to the
1 CPU
2 ECC生成回路
3 データ反転回路
4 セレクタ
5 ECCRAM
6 ECC誤り検出訂正回路
7 48ビット保持レジスタ
8 制御信号生成部
31、32 EORゲート
33、34 セレクタ
CDATA[47:0] 所定ビットが反転されたデータ
ECCDATA[15:0] 誤り訂正用データ
KDATA[47:0] 読み出しデータ
RDATA[31:0] 誤りが訂正されたデータ
WDATA[31:0] 書き込みデータ
1 CPU
2
6 ECC error detection and correction circuit 7 48-
Claims (5)
書き込みデータに誤り訂正データを加えて前記記憶装置に格納するECC生成回路と、 An ECC generation circuit for adding error correction data to write data and storing the data in the storage device;
前記記憶装置の出力データを上位側Nビットと下位側Nビットに2分割し、前記出力データの上位側Nビットまたは下位側Nビットの一方と前記書き込みデータの下位側Nビットとを排他的論理和演算し、当該排他的論理和演算結果と前記出力データの上位側Nビットまたは下位側Nビットの他方を結合して生成したデータを、前記記憶装置の前記ECC生成回路が格納したデータに上書きするデータ反転回路と、 The output data of the storage device is divided into two, upper N bits and lower N bits, and one of the upper N bits or the lower N bits of the output data and the lower N bits of the write data are exclusive logic Performs a sum operation, and overwrites the data stored by the ECC generation circuit of the storage device with data generated by combining the result of the exclusive OR operation and the other of the upper N bits or the lower N bits of the output data A data inversion circuit to
前記データ反転回路が前記上書きをした後に、前記記憶装置の出力データから誤りが発生しているビットを検出するECC誤り検出回路とを有することを特徴とする誤り訂正機能確認回路。 An error correction function confirmation circuit comprising: an ECC error detection circuit for detecting a bit in which an error has occurred from the output data of the storage device after the data inversion circuit performs the overwriting.
書き込みデータに誤り訂正データを加え前記記憶装置に格納するステップと、 Adding error correction data to the write data and storing it in the storage device;
前記記憶装置の出力データを上位側Nビットと下位側Nビットに2分割し、前記出力データの上位側Nビットまたは下位側Nビットの一方と前記書き込みデータの下位側Nビットとを排他的論理和演算し、当該排他的論理和演算結果と前記出力データの上位側Nビットまたは下位側Nビットの他方を結合して生成したデータを、前記記憶装置の前記ECC生成回路が格納したデータに上書きするステップと、 The output data of the storage device is divided into two, upper N bits and lower N bits, and one of the upper N bits or the lower N bits of the output data and the lower N bits of the write data are exclusive logic Performs a sum operation, and overwrites the data stored by the ECC generation circuit of the storage device with data generated by combining the result of the exclusive OR operation and the other of the upper N bits or the lower N bits of the output data And steps to
前記データ反転回路が前記上書きをした後に、前記記憶装置の出力データから誤りが発生しているビットを検出するステップとを有することを特徴とする誤り訂正機能確認方法。 And a step of detecting a bit having an error from the output data of the storage device after the data inversion circuit performs the overwriting.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2008086965A JP5176646B2 (en) | 2008-03-28 | 2008-03-28 | Error correction function confirmation circuit, error correction function confirmation method, computer program thereof, and storage device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2008086965A JP5176646B2 (en) | 2008-03-28 | 2008-03-28 | Error correction function confirmation circuit, error correction function confirmation method, computer program thereof, and storage device |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2009238359A JP2009238359A (en) | 2009-10-15 |
JP5176646B2 true JP5176646B2 (en) | 2013-04-03 |
Family
ID=41252082
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2008086965A Expired - Fee Related JP5176646B2 (en) | 2008-03-28 | 2008-03-28 | Error correction function confirmation circuit, error correction function confirmation method, computer program thereof, and storage device |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP5176646B2 (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2012073678A (en) * | 2010-09-27 | 2012-04-12 | Fujitsu Ltd | Pseudo error generator |
JP6858636B2 (en) * | 2017-05-18 | 2021-04-14 | 富士通セミコンダクターメモリソリューション株式会社 | Semiconductor storage device |
CN116467131B (en) * | 2023-06-19 | 2023-08-25 | 上海芯联芯智能科技有限公司 | ECC function verification method, device, medium and equipment of processor |
Family Cites Families (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPS61118842A (en) * | 1984-11-15 | 1986-06-06 | Fujitsu Ltd | Generating system of pseudo soft error |
JPS62226353A (en) * | 1986-03-28 | 1987-10-05 | Mitsubishi Electric Corp | Storage device with ras circuit |
JP2001351398A (en) * | 2000-06-12 | 2001-12-21 | Nec Corp | Storage device |
JP3940713B2 (en) * | 2003-09-01 | 2007-07-04 | 株式会社東芝 | Semiconductor device |
JP2007041665A (en) * | 2005-08-01 | 2007-02-15 | Nec Engineering Ltd | Ecc functional test circuit and ecc functional test method |
JP4889343B2 (en) * | 2006-03-31 | 2012-03-07 | パナソニック株式会社 | Semiconductor memory device |
JP4853650B2 (en) * | 2007-01-25 | 2012-01-11 | ラピスセミコンダクタ株式会社 | Nonvolatile semiconductor memory device and access evaluation method thereof. |
-
2008
- 2008-03-28 JP JP2008086965A patent/JP5176646B2/en not_active Expired - Fee Related
Also Published As
Publication number | Publication date |
---|---|
JP2009238359A (en) | 2009-10-15 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US7299400B2 (en) | Error correction circuit | |
JP5908375B2 (en) | Semiconductor memory device | |
JP5010271B2 (en) | Error correction code generation method and memory control device | |
US20090300297A1 (en) | Data processing apparatus, memory controller, and access control method of memory controller | |
JP2007041665A (en) | Ecc functional test circuit and ecc functional test method | |
JP4865016B2 (en) | Processor | |
JP5176646B2 (en) | Error correction function confirmation circuit, error correction function confirmation method, computer program thereof, and storage device | |
JP2010123156A (en) | Semiconductor storage device and control method thereof | |
JP2004246754A (en) | Semiconductor memory and its controller | |
JP2011257966A (en) | Cache device and information processor | |
JP5510107B2 (en) | Error correction test method | |
JP4742553B2 (en) | Storage device | |
JP5006121B2 (en) | Logic verification device and logic verification method | |
JP3882628B2 (en) | Memory control device and serial memory | |
JP4981918B2 (en) | Test apparatus and test method | |
US9378782B1 (en) | Apparatus with write-back buffer and associated methods | |
JPH0773114A (en) | Memory control circuit for space digital computer | |
JP2005302134A (en) | Nonvolatile semiconductor memory device | |
JP2004046593A (en) | Cache memory and method for controlling it | |
TWI723515B (en) | Memory apparatus and data accessing method thereof | |
JP2010140132A (en) | Memory system and memory controller | |
JP6358122B2 (en) | Microcomputer | |
KR100386253B1 (en) | Write data conviction circuit for fpga register in using parity bit | |
JP5477574B2 (en) | Integrated circuit device, electronic equipment | |
JPH11167497A (en) | Device and method for detecting memory rewrite operation error |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20101117 |
|
RD03 | Notification of appointment of power of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7423 Effective date: 20101117 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20120801 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20120807 |
|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20121003 |
|
TRDD | Decision of grant or rejection written | ||
A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 Effective date: 20121211 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20121224 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 5176646 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
S111 | Request for change of ownership or part of ownership |
Free format text: JAPANESE INTERMEDIATE CODE: R313113 |
|
R350 | Written notification of registration of transfer |
Free format text: JAPANESE INTERMEDIATE CODE: R350 |
|
S111 | Request for change of ownership or part of ownership |
Free format text: JAPANESE INTERMEDIATE CODE: R313111 |
|
R350 | Written notification of registration of transfer |
Free format text: JAPANESE INTERMEDIATE CODE: R350 |
|
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 |
|
LAPS | Cancellation because of no payment of annual fees |