JP2518333B2 - Storage device - Google Patents

Storage device

Info

Publication number
JP2518333B2
JP2518333B2 JP63009498A JP949888A JP2518333B2 JP 2518333 B2 JP2518333 B2 JP 2518333B2 JP 63009498 A JP63009498 A JP 63009498A JP 949888 A JP949888 A JP 949888A JP 2518333 B2 JP2518333 B2 JP 2518333B2
Authority
JP
Japan
Prior art keywords
data
circuit
check
mode register
selector
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
JP63009498A
Other languages
Japanese (ja)
Other versions
JPH01185753A (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.)
NEC Corp
Original Assignee
Nippon 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 Nippon Electric Co Ltd filed Critical Nippon Electric Co Ltd
Priority to JP63009498A priority Critical patent/JP2518333B2/en
Publication of JPH01185753A publication Critical patent/JPH01185753A/en
Application granted granted Critical
Publication of JP2518333B2 publication Critical patent/JP2518333B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Techniques For Improving Reliability Of Storages (AREA)

Description

【発明の詳細な説明】 〔産業上の利用分野〕 本発明は、記憶装置に係わり、特に1ビットエラー訂
正/2ビットエラー検出機能を有し、診断時に誤り訂正コ
ードを用いて部分書込動作を可能とする記憶装置に関す
る。
The present invention relates to a storage device, and more particularly, to a storage device, which has a 1-bit error correction / 2-bit error detection function, and a partial write operation using an error correction code during diagnosis. The present invention relates to a storage device that enables

〔従来の技術〕[Conventional technology]

この種の記憶装置は、誤り検出訂正(以下ECCと呼
ぶ。)機構により、1ビットエラーを訂正し、2ビット
エラーを検出する能力を有している。すなわち、演算処
理装置や入出力処理装置などの要求装置からのデータの
書き込み、読み出しおよび部分書き込みは、メモリセル
からデータとチェックビットを読み出し、1ビットエラ
ーがあるときは誤り訂正回路でこれを訂正することによ
り実施していた。しかしながら、要求装置から部分書き
込みを行う場合、例えば必要なバイトだけを記憶装置に
書き込もうとするときは、次のような問題があった。す
なわち、全バイトの書込動作以前に部分書き込みを行う
と、データが部分的なので、2ビットエラーが検出され
る。このように2ビットエラーが検出されると、従来の
記憶装置では以後の書込動作が禁止され、したがって部
分書込動作は実行されなかった。
This type of storage device has a capability of correcting a 1-bit error and detecting a 2-bit error by an error detection and correction (hereinafter referred to as ECC) mechanism. That is, in writing, reading, and partial writing of data from a request device such as an arithmetic processing device or an input / output processing device, data and check bits are read from a memory cell, and if there is a 1-bit error, an error correction circuit corrects this. It was carried out by doing. However, when performing partial writing from the request device, for example, when writing only the necessary bytes to the storage device, there were the following problems. That is, if partial writing is performed before the writing operation of all bytes, a 2-bit error is detected because the data is partial. When the 2-bit error is detected in this manner, the subsequent write operation is prohibited in the conventional memory device, and therefore the partial write operation is not executed.

〔発明が解決しようとする課題〕[Problems to be Solved by the Invention]

このように、従来の記憶装置では部分書込動作をいき
なり実施することができず、1度全バイトを書き込んだ
後でなければならないという問題があった。このため、
システム立ち上げ時に余分な時間がかかるという欠点が
生じた。
As described above, the conventional storage device has a problem in that the partial write operation cannot be suddenly performed, and it is necessary to write all bytes once. For this reason,
The disadvantage is that it takes extra time to start up the system.

そこで本発明の目的は、全バイトの書き込みを予め行
わなくても部分書き込みが可能な記憶装置を提供するこ
とにある。
Therefore, an object of the present invention is to provide a storage device capable of partial writing without writing all bytes in advance.

〔課題を解決するための手段〕[Means for solving the problem]

本発明の記憶装置は、データとこのデータのチェック
ビットとを記憶するメモリマトリックス回路と、第1お
よび第2の状態のいずれかに設定されるモードレジスタ
と、このモードレジスタが前記第1の状態に設定されて
いるときには前記メモリマトリクス回路から読み出され
たデータおよびチェックビットを出力し前記モードレジ
スタが前記第2の状態に設定されているときにはECCコ
ードに合わせたデータおよびチェックビットを選択する
セレクタと、このセレクタによって選択されたデータお
よびチェックビットのエラーを検出または訂正する検出
訂正回路と、この検出訂正回路から出力されたデータと
部分書き込みデータとをマージするマージ回路と、この
マージ回路によってマージされたデータのチェックビッ
トを生成するチェックビット発生回路と、前記マージ回
路によってマージされたデータと前記チェックビット発
生回路によって生成されたチェックビットとを前記メモ
リマトリクス回路に書き込む手段とを含む。
A storage device of the present invention includes a memory matrix circuit for storing data and a check bit of the data, a mode register set to one of a first state and a second state, and the mode register having the first state. A selector for outputting the data and check bits read from the memory matrix circuit when set to 1, and selecting the data and check bits according to the ECC code when the mode register is set to the second state. A detection / correction circuit that detects or corrects errors in the data and check bits selected by the selector; a merge circuit that merges the data output from the detection / correction circuit with the partial write data; A check that produces a check bit for the data Tsu including a preparative generating circuit, and means for writing the check bits generated by the merged data and the check bit generating circuit by said merging circuit to the memory matrix circuit.

〔実施例〕〔Example〕

以下実施例につき本発明を詳細に説明する。 The present invention will be described in detail below with reference to examples.

第1図は本実施例の記憶装置を示すブロック図であ
る。
FIG. 1 is a block diagram showing the storage device of this embodiment.

入出力装置などの図示しない要求装置から部分書込命
令があると、メモリマトリックス回路11からデータおよ
びチェックビット12が読み出される。読み出されたデー
タおよびチェックビット12は、セレクタ13およびレジス
タ14を介し、読出データ15としてシンドローム生成回路
16に送出される。ここで、1ビットエラーまたは2ビッ
トエラーが検出される。1ビットエラーのときは、デコ
ーダ18、訂正回路19により訂正されて訂正データ20にな
る。このようにして、読み出されたデータおよびチェッ
クビット12に誤りがないか、または訂正されると、レジ
スタ22を介して、再書込データ26としてセレクタ27に転
送される。セレクタ27は、この再書込データ26を、図示
しない要求装置から書込データ30としてレジスタ31を介
して与えられた要求装置からのデータ33とマージする。
このようにしてマージされたデータ35はチェックビット
発生回路36で発生されたチェックビット37と共に書込デ
ータとしてメモリマトリックス回路11に書き込まれる。
一方、2ビットエラーのときは、上記とは異なり、以後
の動作は禁止され、その旨が禁止信号40として図示しな
い要求装置に報告される。このように、部分書込動作
が、全バイト書込動作以前に実施されると、2ビットエ
ラーが検出され、その動作は実行されない。
When there is a partial write command from a request device (not shown) such as an input / output device, the data and check bit 12 are read from the memory matrix circuit 11. The read data and the check bit 12 are passed through the selector 13 and the register 14 as read data 15 and the syndrome generation circuit.
Sent to 16. Here, a 1-bit error or a 2-bit error is detected. When there is a 1-bit error, the data is corrected by the decoder 18 and the correction circuit 19 and becomes corrected data 20. In this way, if the read data and the check bit 12 have no error or are corrected, they are transferred to the selector 27 as rewrite data 26 via the register 22. The selector 27 merges the rewrite data 26 with the data 33 from the requesting device which is given as the write data 30 from the requesting device (not shown) via the register 31.
The data 35 thus merged is written in the memory matrix circuit 11 as write data together with the check bit 37 generated by the check bit generation circuit 36.
On the other hand, in the case of a 2-bit error, unlike the above, the subsequent operation is prohibited, and that effect is reported to the requesting device (not shown) as a prohibition signal 40. Thus, if the partial write operation is performed before the full byte write operation, a 2-bit error is detected and that operation is not performed.

そこで、部分書込動作を全バイト書込動作以前でも実
行できるようにするため、次のように工夫する。すなわ
ち、モードレジスタ43を設けてセレクタ13に接続する。
モードレジスタ43を論理「1」に設定すると、この設定
がセレクタ13に通知される。セレクタ13は、モードレジ
スタ43の設定に応じて、メモリマトリックス回路11から
のデータおよびチェックビット12と、上記ECCコードに
合わせたデータおよびチェックビット46のいずれか一方
を選択する。モードレジスタ43が論理「1」に設定され
ているとき、セレクタ13は後者を選択する。したがっ
て、現在の場合は後者が選択される。このように、部分
書込に際しては、モードレジスタ43とセレクタ13を用い
て、ECCコードに合わせたデータおよびチェックビット4
6をシンドローム生成回路16に送出するようにすれば、
ハード障害がない限りエラーは検出されず、部分書込動
作が可能になる。その後、このデータおよびチェックビ
ット46は、レジスタ22を介して再書込データ48としてセ
レクタ27に送出される。そして、セレクタ27は、図示し
ない要求装置からの書込データ33とこのレジスタ22から
の再書込データ48とをマージする。マージされたデータ
49はチェックビット発生回路36からのチェックビットと
共にメモリマトリックス回路11に書き込まれる。
Therefore, in order to be able to execute the partial write operation even before the all byte write operation, the following measures are taken. That is, the mode register 43 is provided and connected to the selector 13.
When the mode register 43 is set to logic "1", this setting is notified to the selector 13. The selector 13 selects one of the data and the check bit 12 from the memory matrix circuit 11 and the data and the check bit 46 according to the ECC code according to the setting of the mode register 43. When the mode register 43 is set to logic "1", the selector 13 selects the latter. Therefore, in the present case, the latter is selected. As described above, at the time of partial writing, the mode register 43 and the selector 13 are used to check the data and the check bit 4 that match the ECC code.
If 6 is sent to the syndrome generation circuit 16,
As long as there is no hardware failure, no error will be detected and a partial write operation will be possible. Thereafter, this data and the check bit 46 are sent to the selector 27 as rewrite data 48 via the register 22. Then, the selector 27 merges the write data 33 from the request device (not shown) and the rewrite data 48 from the register 22. Merged data
49 is written in the memory matrix circuit 11 together with the check bit from the check bit generation circuit 36.

ここで、第2図をみると、上記のセレクタ13にECCコ
ードに合わせたデータおよびチェックビット46を送ると
きに用いられるECCコードの一例が示してある。この例
では、データ49はd1……d32の配列で構成される。この
データ49は、第1バイト52(データd1……d8)、第2バ
イト53(データd9……d16)、第3バイト54(データd17
……d24)、第4バイト55(d25……d32)の4バイトか
らなる。また、それぞれのバイトはb1……b8のビット57
で構成される。本実施例で用いるシンドローム60はs1
s6で構成され、図示のような1、0のパターンを有する
(0は略してある)。チェックビット62はc1〜c7で構成
され、シンドローム60のs1〜s7にそれぞれ対応してい
る。このように、シンドローム60が与えられ、データ49
のd1……d32が与えられれば、チェックビット62のc1〜c
7を具体的に求めることができる。例えば、簡単のた
め、データ49(d1……d32)を全て論理0とすると、次
に説明するようにチェックビット62(c1〜c7)も論理0
となる。つまり、すでに与えた説明のとおり、セレクタ
13はECCコードに合わせたデータおよびチェックビット
として、全て論理0のデータ49(d1……d32)と、同様
に全て論理0のチェックビット62(c1〜c7)を選択する
ことになる。
Here, referring to FIG. 2, there is shown an example of the ECC code used when the data and the check bit 46 matched with the ECC code are sent to the selector 13. In this example, the data 49 is composed of an array of d 1 ... D 32 . This data 49 includes a first byte 52 (data d 1 ... d 8 ), a second byte 53 (data d 9 ...... d 16 ), and a third byte 54 (data d 17).
...... d 24 ), the 4th byte 55 (d 25 ...... d 32 ) consists of 4 bytes. Also, each byte is bit 1 of b 1 ... b 8
Composed of. The syndrome 60 used in this example is s 1 ~
s 6 and has a pattern of 1, 0 as shown (0 is omitted). The check bit 62 is composed of c 1 to c 7 , and corresponds to s 1 to s 7 of the syndrome 60, respectively. Thus, given the syndrome 60, the data 49
Given d 1 ...... d 32 , check bits 62 c 1 to c
7 can be specifically requested. For example, for simplification, if all the data 49 (d 1 ... d 32 ) are logic 0, the check bits 62 (c 1 to c 7 ) are also logic 0 as described below.
Becomes In other words, as explained earlier,
13 is to select the data 49 (d 1 ... d 32 ) of all logic 0 and the check bits 62 (c 1 to c 7 ) of all logic 0 as data and check bits matched with the ECC code. Become.

ここで、ECCコードのシンドロームが与えられたとき
のチェックビットの求め方を簡単に説明しておく。
Here, how to obtain the check bit when the ECC code syndrome is given will be briefly described.

一般に、パリティチェックにおいて、データ(情報)
ビット数k、チェックビット数をmとする。データビッ
トとチェックビットを含む符号語1u=(x1,x2,……)
(k,)(k+1,……)(n)(但し、n=k+m)の満
たすべきパリティチェック方程式は となる。係数hij(i=1,……,m,j=1,……,n)は全て
0か1で、行列の形で表わした はパリティチェック行列と呼ばれる、始めの方式を行列
で書き直すと、 w1HT=(0,0,……0)=0 ……(3) となる(1HTは1Hの転置行列)。ここで、第i要素だけ
1であるような誤りベクトルciに対するシンドローム
s′iは s′=(h1i,h2i,……,hmi) ……(4) として与えられる。ここでiを1から39まで変えれば、
現在の場合のシンドロームパターンが得られる。すなわ
ち、(1)式で、k=32、m=7とすると となる。(5)式のそれぞれの方程式のhの配列に第2
図のシンドローム60のs1〜s7のそれぞれの1、0の値を
対応させると、 となる。
Generally, in parity check, data (information)
The number of bits k and the number of check bits are m. Codeword including data bit and check bit 1u = (x 1 , x 2 , ...)
The parity check equation that (k,) (k + 1 , ...) (n) (where n = k + m) should be satisfied is Becomes Coefficients hij (i = 1, ..., m, j = 1, ..., n) are all 0 or 1 and expressed in matrix form. Is called the parity check matrix, is rewritten at the beginning of the scheme matrix, w1H T = (0,0, ...... 0) becomes = 0 ...... (3) (1H T is the transpose matrix of IH). Here, the syndrome s′i for the error vector c i in which only the i-th element is 1 is given as s ′ i = (h 1i , h 2i , ..., h mi ) ... (4). If i is changed from 1 to 39,
The syndrome pattern of the current case is obtained. That is, if k = 32 and m = 7 in the equation (1), Becomes The second is added to the array of h in each equation of equation (5).
When the values of 1 and 0 of s 1 to s 7 of the syndrome 60 in the figure are associated, Becomes

x1〜x32データ49のd1〜d32に、x33〜x39はチェックビ
ット62のc1〜c7に対応している。これからデータ値を具
体的に代入すればチェックビットが求まる。部分バイト
に対しても、同様にチェックビットが求まるのはもちろ
んである。
The x 1 to x 32 data 49 correspond to d 1 to d 32 , and the x 33 to x 39 correspond to check bits 62, c 1 to c 7 . By substituting the data value concretely, the check bit can be obtained. Needless to say, check bits are similarly obtained for partial bytes.

〔発明の効果〕〔The invention's effect〕

このように、本発明の記憶装置は、モードレジスタを
セットして、ECCコードに合わせたデータおよびチェッ
クビットを選択することにより、全バイトの書込動作を
行わずに、初めから部分書込動作を実施することができ
る。このため、システム立ち上げ時などにおける実行時
間を短縮できる効果がある。また、読出動作時にも、モ
ードレジスタをセットすることにより、シンドローム生
成回路のチェックができる効果がある。
As described above, the memory device of the present invention sets the mode register and selects the data and the check bit in accordance with the ECC code, thereby performing the partial write operation from the beginning without performing the write operation of all bytes. Can be carried out. Therefore, there is an effect that the execution time can be shortened when the system is started. In addition, even during the read operation, the syndrome generating circuit can be checked by setting the mode register.

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

第1図は本発明による記憶装置の一実施例を示すブロッ
ク図、第2図はこの実施例に用いられるECCコードの一
例を示す図である。 11……メモリマトリックス回路、 13……セレクタ、 19……訂正回路、 43……モードレジスタ。
FIG. 1 is a block diagram showing an embodiment of a storage device according to the present invention, and FIG. 2 is a diagram showing an example of an ECC code used in this embodiment. 11 …… Memory matrix circuit, 13 …… Selector, 19 …… Correction circuit, 43 …… Mode register.

Claims (1)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】データとこのデータのチェックビットとを
記憶するメモリマトリックス回路と、 第1および第2の状態のいずれかに設定されるモードレ
ジスタと、 このモードレジスタが前記第1の状態に設定されている
ときには前記メモリマトリクス回路から読み出されたデ
ータおよびチェックビットを出力し、前記モードレジス
タが前記第2の状態に設定されているときにはECCコー
ドに合わせたデータおよびチェックビットを選択するセ
レクタと、 このセレクタによって選択されたデータおよびチェック
ビットのエラーを検出または訂正する検出訂正回路と、 この検出訂正回路から出力されたデータと部分書き込み
データとをマージするマージ回路と、 このマージ回路によってマージされたデータのチェック
ビットを生成するチェックビット発生回路と、 前記マージ回路によってマージされたデータと前記チェ
ックビット発生回路によって生成されたチェックビット
とを前記メモリマトリクス回路に書き込む手段とを含む
ことを特徴とする記憶装置。
1. A memory matrix circuit for storing data and a check bit of the data, a mode register set to one of a first state and a second state, and the mode register set to the first state. And a selector that outputs the data and check bits read from the memory matrix circuit when the mode register is set, and selects the data and check bits that match the ECC code when the mode register is set to the second state. , A detection / correction circuit that detects or corrects an error in the data and the check bit selected by this selector, a merge circuit that merges the data output from this detection / correction circuit and the partial write data, and a merge circuit that merges them. Check bits that generate check bits for Doo and generating circuit, a storage device which comprises a means for writing the check bits generated by the merged data and the check bit generating circuit by said merging circuit to the memory matrix circuit.
JP63009498A 1988-01-21 1988-01-21 Storage device Expired - Fee Related JP2518333B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP63009498A JP2518333B2 (en) 1988-01-21 1988-01-21 Storage device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP63009498A JP2518333B2 (en) 1988-01-21 1988-01-21 Storage device

Publications (2)

Publication Number Publication Date
JPH01185753A JPH01185753A (en) 1989-07-25
JP2518333B2 true JP2518333B2 (en) 1996-07-24

Family

ID=11721900

Family Applications (1)

Application Number Title Priority Date Filing Date
JP63009498A Expired - Fee Related JP2518333B2 (en) 1988-01-21 1988-01-21 Storage device

Country Status (1)

Country Link
JP (1) JP2518333B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4764945B2 (en) 2007-06-20 2011-09-07 富士通株式会社 Cache control device, cache control method, and cache control program

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS6190241A (en) * 1984-10-08 1986-05-08 Nec Corp Read control circuit
JPS61123950A (en) * 1984-11-07 1986-06-11 Fujitsu Ltd Memory access control method
JPS62187350U (en) * 1986-05-16 1987-11-28

Also Published As

Publication number Publication date
JPH01185753A (en) 1989-07-25

Similar Documents

Publication Publication Date Title
JPH10207726A (en) Semiconductor disk device
JPH0260013B2 (en)
JPH03501660A (en) Error detection in partial write operations to storage devices
US5063565A (en) Single-error detecting and correcting system
JP2518333B2 (en) Storage device
JPH0756640B2 (en) Storage device
JPS61290556A (en) Memory error recovering system
JP3123855B2 (en) Patrol control circuit of memory device
JPH0520215A (en) Information processor
JPH0434786B2 (en)
JPH04115340A (en) Duplex storage circuit
JPS6223902B2 (en)
JP2567986B2 (en) Data processing system
SU765886A1 (en) Device for correcting for errors in storage unit
SU970480A1 (en) Self-checking memory device
JPS6142305B2 (en)
JPS6232825B2 (en)
JPS59110098A (en) Error correcting device of data storage device
JPS6232826B2 (en)
JPH0646520B2 (en) Semiconductor memory device
JPS61110247A (en) Storage device
JPH038029A (en) Microprogram controller
JPS6142304B2 (en)
JPH04233052A (en) Duplex memory device
JPS63170756A (en) Main storage initializing system

Legal Events

Date Code Title Description
LAPS Cancellation because of no payment of annual fees