JPH06250937A - Method for memory control, memory control circuit with ecc function and information processor - Google Patents

Method for memory control, memory control circuit with ecc function and information processor

Info

Publication number
JPH06250937A
JPH06250937A JP5021105A JP2110593A JPH06250937A JP H06250937 A JPH06250937 A JP H06250937A JP 5021105 A JP5021105 A JP 5021105A JP 2110593 A JP2110593 A JP 2110593A JP H06250937 A JPH06250937 A JP H06250937A
Authority
JP
Japan
Prior art keywords
information
address
cpu
data
ecc
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.)
Pending
Application number
JP5021105A
Other languages
Japanese (ja)
Inventor
Norio Fujita
典生 藤田
Nobuhito Fujita
信人 藤田
Satoru Yamazaki
哲 山崎
Mitsuhiro Aida
光宏 合田
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.)
International Business Machines Corp
Original Assignee
International Business Machines Corp
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 International Business Machines Corp filed Critical International Business Machines Corp
Priority to JP5021105A priority Critical patent/JPH06250937A/en
Publication of JPH06250937A publication Critical patent/JPH06250937A/en
Pending legal-status Critical Current

Links

Landscapes

  • Detection And Correction Of Errors (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)

Abstract

PURPOSE: To suppress the increase of the number of times of memory access at the time of adding an ECC code to each data with specific length and operating an ECC processing, and to prevent the executing speed of a program from being sharply deteriorated even at the time of executing the ECC processing. CONSTITUTION: At the time of adding an ECC code to each data with specific bit length and writing the data in a memory element 20, when the length of writing data from a CPU 10 is less than the specific bit length, data previously read from the memory element 20 are held in a mean 42 different from the memory element 20, and data with the specific bit length are generated based on the held data and the writing data from the CPU 10. Thus, the ECC processing can be attained even when the reading from the memory is not necessarily operated before the writing in the memory.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】本発明はECC(エラー・チェッ
ク・アンド・コレクション)機能を有するシステムのメ
モリ制御装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a memory controller for a system having an ECC (Error Check and Correction) function.

【0002】[0002]

【従来の技術】ECC処理機能を備えた情報処理装置で
は、CPUからの特定の長さのデータ毎にECCコード
が付加されてシステム・メモリに記憶される。例えば、
現在最も一般的に用いられているハミング・コード・チ
ェック方式では、32ビット長のデータに対して7ビッ
ト長のECCコードが付加される。また、64ビット長
のデータに対しては8ビット長のECCコードが付加さ
れる。従って、32ビットのCPUが搭載されているE
CC機能付きのパーソナル・コンピュータでは、ECC
コードのための記憶容量を節約する観点から、CPUか
らの情報のビット長に関わりなく、64ビットのデータ
毎に8ビット長のECCコードを付加する場合がある。
2. Description of the Related Art In an information processing apparatus having an ECC processing function, an ECC code is added to each piece of data of a specific length from a CPU and stored in a system memory. For example,
In the Hamming code check method most commonly used at present, a 7-bit length ECC code is added to 32-bit length data. An 8-bit length ECC code is added to 64-bit length data. Therefore, an E equipped with a 32-bit CPU
For personal computers with CC function, ECC
From the viewpoint of saving the storage capacity for the code, an 8-bit length ECC code may be added to each 64-bit data regardless of the bit length of the information from the CPU.

【0003】このような場合、メモリに対する書き込み
に際してはリード・モディファイ・ライトという手法が
用いられることが通常であった。リード・モディファイ
・ライトでは、メモリへの書き込み前に、書き込みアド
レスに連続する記憶場所からのメモリ情報の読み出しを
行う。次に、読み出した情報とCPUからの書き込み情
報とに基づいて64ビットの書き込み情報を生成し、生
成した64ビットの情報に対して8ビットのECCコー
ドを付加してメモリに書き込むのである。32ビット型
のCPUでは、CPUからの1回の書き込み情報のデー
タ幅は最大で32ビットであり、64ビットには満たな
いので、メモリへの書き込み時には必ずリード・モディ
ファイ・ライトが行われる。
In such a case, a method called read-modify-write is usually used when writing to the memory. In read-modify-write, memory information is read from memory locations consecutive to the write address before writing to the memory. Next, 64-bit write information is generated based on the read information and the write information from the CPU, and an 8-bit ECC code is added to the generated 64-bit information and written in the memory. In a 32-bit type CPU, the maximum data width of one-time write information from the CPU is 32 bits, which is less than 64 bits, so that read-modify-write is always performed when writing to the memory.

【0004】以下、図面を参照して従来技術を更に詳細
に説明する。図3には従来の情報処理システムの構成の
一例が示されている。図中、情報処理システム1にはC
PU10が備えられている。CPU10は、32ビット
型のプロセッサであり、そのアドレス線12上に32ビ
ットのアドレス信号を出力し、データ線14上に8ビッ
ト、16ビット、24ビット、或は32ビットの情報を
出力する。CPU10のアドレス線12はメモリ・コン
トローラ16に入力し、メモリ・コントローラ16の出
力はメモリ素子20に繋がっている。メモリ素子20は
8個のメモリ・ブロック20−0乃至20−7から構成
されている。
The prior art will now be described in more detail with reference to the drawings. FIG. 3 shows an example of the configuration of a conventional information processing system. In the figure, the information processing system 1 has a C
The PU 10 is provided. The CPU 10 is a 32-bit type processor, which outputs a 32-bit address signal on the address line 12 and outputs 8-bit, 16-bit, 24-bit, or 32-bit information on the data line 14. The address line 12 of the CPU 10 is input to the memory controller 16, and the output of the memory controller 16 is connected to the memory element 20. The memory element 20 is composed of eight memory blocks 20-0 to 20-7.

【0005】CPU10の出力したアドレス信号に基づ
いて、メモリ・コントローラ16は、ロー・アドレス信
号、コラム・アドレス信号、RAS(ロー・アドレス・
ストローブ)信号、及び、CAS(コラム・アドレス・
ストローブ)信号をメモリ素子20に対して出力する。
ロー・アドレス及びコラム・アドレスは、メモリ素子2
0の各メモリ・ブロックに共通に与えられる。ロー・ア
ドレス及びコラム・アドレスにより、各メモリ・ブロッ
クの夫々において1つの記憶領域100が指定される。
記憶領域100は8ビット(1バイト)のデータ100
Aと1ビットのECCコード100Bとから成る。RA
S信号及びCAS信号は8個のメモリ・ブロック20−
0乃至20−7の内の1個を指定するために利用され
る。
Based on the address signal output from the CPU 10, the memory controller 16 controls the row address signal, the column address signal, and the RAS (row address signal).
Strobe) signal and CAS (column address
Strobe signal is output to the memory element 20.
The row address and the column address are stored in the memory device 2
0 is commonly given to each memory block. The row address and the column address specify one storage area 100 in each of the memory blocks.
Storage area 100 is 8-bit (1 byte) data 100
A and 1-bit ECC code 100B. RA
The S signal and the CAS signal consist of eight memory blocks 20-
Used to specify one of 0 to 20-7.

【0006】64ビット長毎のデータに対してECC処
理を施す場合は、メモリ素子20に対して1度に64ビ
ット長のデータのアクセスが行われる。この場合は、8
個のメモリ・ブロック20−0乃至20−7に対するア
クセスが同時に行われ、メモリ素子20全体として、6
4ビット長(8ビット長×8個)のデータ・ビットと8
ビット長(1ビット長×8個)のECCコードのための
1つの記憶領域が指定されることになる。
When ECC processing is performed on data of each 64-bit length, the data of 64-bit length is accessed to the memory element 20 at once. In this case, 8
The memory blocks 20-0 to 20-7 are simultaneously accessed, and the memory device 20 as a whole has 6
4-bit length (8-bit length x 8) data bits and 8
One storage area for an ECC code having a bit length (1 bit length × 8 pieces) is designated.

【0007】データ線14上のデータはミキサー22を
介してECCコード・ジェネレータ24に与えられる。
CPU10がデータ線14上に出力するデータは8ビッ
ト、16ビット、24ビット、或は32ビットの何れか
であるが、ミキサー22からECCコード・ジェネレー
タ24に与えられるデータは必ず64ビットである。E
CCジェネレータ24は64ビットのデータに対して8
ビットのECCコードを発生し、64ビットのデータと
ともに8ビットのECCコードをメモリ素子20に与え
る。
The data on data line 14 is provided to ECC code generator 24 via mixer 22.
The data output from the CPU 10 onto the data line 14 is either 8 bits, 16 bits, 24 bits or 32 bits, but the data supplied from the mixer 22 to the ECC code generator 24 is always 64 bits. E
CC generator 24 has 8 bits for 64-bit data
A bit ECC code is generated, and an 8-bit ECC code is given to the memory element 20 together with 64-bit data.

【0008】メモリ素子20から読み出された64ビッ
トのデータと8ビットのECCコードの内、ECCコー
ドを含む72ビットの情報についてはエラー・ビット検
出回路32に与えられる。メモリ素子20から読み出さ
れた64ビットのデータと8ビットのECCコードの
内、ECCコードを含まない64ビットのデータについ
てはエラー・ビット訂正回路34に与えられる。エラー
・ビット訂正回路34は、エラー・ビット検出回路32
に応答して64ビットのデータ中のエラー・ビットの訂
正を行う。エラー・ビット訂正回路34によりエラー・
ビットが訂正された64ビットのデータはミキサー22
に与えられる。ミキサー22はエラー・ビットが訂正さ
れた64ビットのデータとCPU10からのデータとを
合成して64ビットのデータを生成する。また、エラー
・ビット訂正回路34によりエラー・ビットが訂正され
た64ビットのデータはリード・バッファ28にも与え
られる。CPU10はリード・バッファ28内のデータ
を32ビット単位で2回に分けてリードする。
Of the 64-bit data read from the memory device 20 and the 8-bit ECC code, 72-bit information including the ECC code is supplied to the error bit detection circuit 32. Of the 64-bit data read from the memory element 20 and the 8-bit ECC code, 64-bit data not including the ECC code is supplied to the error / bit correction circuit 34. The error bit correction circuit 34 includes an error bit detection circuit 32.
To correct the error bit in the 64-bit data. Error by the error bit correction circuit 34
The 64-bit data with the corrected bits is the mixer 22.
Given to. The mixer 22 synthesizes the 64-bit data in which the error bits have been corrected and the data from the CPU 10 to generate 64-bit data. Further, the 64-bit data whose error bits have been corrected by the error bit correction circuit 34 is also given to the read buffer 28. The CPU 10 reads the data in the read buffer 28 twice in 32-bit units.

【0009】このような従来構造において行われていた
リード・モディファイ・ライトについて説明する。アド
レス0のデータ"A"("A"は8ビットのデータとす
る。)をデータ"B"("B"は8ビットのデータとす
る。)に書き換える場合を取り上げる。図2に示される
ように、データの書き換え前のアドレス0からアドレス
7の全体として64ビット(8ビット×8個)分の記憶
領域内の各8ビットの記憶場所には全て"A"というデー
タが記憶されているものとし、アドレス0内の"A"を"
B"に書き換えるが、アドレス1からアドレス7の7つ
の記憶領域についてはデータの書き換えは行われないも
のとする。
Read modify write performed in such a conventional structure will be described. The case where the data "A"("A" is 8-bit data) at address 0 is rewritten to the data "B"("B" is 8-bit data) will be taken up. As shown in FIG. 2, all the data of "A" is stored in each 8-bit storage area in the storage area of 64 bits (8 bits × 8 pieces) as a whole from address 0 to address 7 before data rewriting. Is stored, and "A" in address 0 is changed to "
Although it is rewritten to B ″, data rewriting is not performed for the seven storage areas of address 1 to address 7.

【0010】CPU10は、アドレス線12上にアドレ
ス0信号(32ビット)を出力するとともに、データ線
14上に8ビットのデータ("B")を出力する。この8
ビットのデータ("B")のメモリ素子20への書き込み
に先立って、メモリ素子20からの64ビットのデータ
("AAAAAAAA")の読み出しが行われる。64ビ
ットのデータ("AAAAAAAA")の読み出しのため
に、メモリ・コントローラ16は、8個のメモリ・ブロ
ックに対して共通のロー・アドレス及びコラム・アドレ
スを出力して8個のメモリ・ブロックから同時にデータ
を読み出す。この64ビットのデータ("AAAAAA
AA")は、メモリ素子20のアドレス0からアドレス
7までの64ビット分の記憶領域に記憶されていたデー
タである。
The CPU 10 outputs an address 0 signal (32 bits) on the address line 12 and outputs 8-bit data ("B") on the data line 14. This 8
Prior to writing bit data (“B”) to the memory element 20, 64-bit data (“AAAAAAAA”) is read from the memory element 20. In order to read 64-bit data ("AAAAAAAA"), the memory controller 16 outputs a common row address and column address to the eight memory blocks, and outputs the common row address and column address from the eight memory blocks. Read data at the same time. This 64-bit data ("AAAAAA"
AA ″) is data stored in the 64-bit storage area from address 0 to address 7 of the memory element 20.

【0011】メモリ素子20からは64ビットのデータ
("AAAAAAAA")の他に8ビットのECCコード
も読み出される。64ビットのデータ("AAAAAA
AA")と8ビットのECCコードはエラー・ビット検
出回路32に取り込まれる。この64ビットのデー
タ("AAAAAAAA")に対してエラー・ビット検出
回路32及びエラー・ビット訂正回路34により、エラ
ー・ビットの訂正が行われる。
From the memory device 20, 8-bit ECC code is read out in addition to 64-bit data ("AAAAAAAA"). 64-bit data ("AAAAAA"
The AA ") and the 8-bit ECC code are fetched by the error bit detection circuit 32. The error bit detection circuit 32 and the error bit correction circuit 34 detect the error of the 64-bit data (" AAAAAAAA "). Bit correction is performed.

【0012】エラー・ビット訂正済みの64ビットのデ
ータ("AAAAAAAA")は、ミキサー22に与えら
れ、ミキサー22は、このようにしてメモリ素子20か
ら読み出された64ビットのデータ("AAAAAAA
A")とCPU10からの8ビットのデータ("B")と
を合成して新たに64ビットのデータ("BAAAAA
AA")を出力する。ECCコード・ジェネレータ24
は、ミキサー22が生成した64ビットのデータ("B
AAAAAAA")に対してECCコードを生成する。
こうして生成された64ビットのデータ("BAAAA
AAA")とECCコードとがメモリ素子20に書き込
まれる。
The error-bit-corrected 64-bit data ("AAAAAAAA") is supplied to the mixer 22, which then reads the 64-bit data ("AAAAAAAA" from the memory element 20 in this manner.
A ") and 8-bit data (" B ") from the CPU 10 are combined to newly add 64-bit data (" BAAAA ").
AA ") is output. ECC code generator 24
Is the 64-bit data ("B
An ECC code is generated for AAAAAA ").
The 64-bit data ("BAAAA" generated in this way
AAA ″) and the ECC code are written in the memory device 20.

【0013】このような従来技術の例では、メモリ素子
20のアドレス0に8ビットのデータ"B"を書き込むた
めには、メモリ素子20のアドレス0からアドレス7内
の64ビットのデータ("AAAAAAAA")を読み出
した後、書き込むべき64ビットのデータ("BAAA
AAAA")を生成し、この生成した64ビットのデー
タ("BAAAAAAA")をメモリ素子20に書き込む
という手順を経なければならない。即ち、リード・モデ
ィファイ・ライトは、メモリへの書き込みの度に、メモ
リへの2回のアクセス動作を必要とするため、メモリへ
の書き込み動作が遅くなり、延いては、パーソナル・コ
ンピュータ上のプログラムの実行速度の高速化を阻んで
いた。
In such an example of the prior art, in order to write 8-bit data "B" to address 0 of the memory element 20, 64-bit data ("AAAAAAAA" in address 0 to address 7 of the memory element 20 is written. After reading "", 64-bit data to be written ("BAAA
(AAAAA ") and write the generated 64-bit data (" BAAAAAAA ") to the memory element 20. That is, the read-modify-write operation is performed every time data is written to the memory. Since the access operation to the memory is required twice, the write operation to the memory is slowed down, and thus the execution speed of the program on the personal computer is prevented from being increased.

【0014】尚、特開平4−219700には、エラー
が検出されたデータを保持するアドレス及び訂正済みの
データをアドレス格納回路及び修正データ格納回路の夫
々に記憶させ、以後、前記アドレスがアクセスされたこ
とがアドレス比較回路により検出されると、メモリ内の
前記アドレスに対応する記憶場所からデータを読み出す
のではなく、前記修正済みデータ格納回路から読み出す
ようにした半導体記憶装置が示されている。しかしなが
ら、同出願は本発明を示唆するものではない。
In Japanese Patent Laid-Open No. 4-219700, an address holding data in which an error has been detected and corrected data are stored in an address storage circuit and a correction data storage circuit, respectively, and then the address is accessed. There is shown a semiconductor memory device in which when the address is detected by the address comparison circuit, the data is read from the modified data storage circuit instead of being read from the memory location corresponding to the address. However, this application does not suggest the present invention.

【0015】[0015]

【解決しようとする問題点】本発明の目的は、ECC処
理に伴うメモリ・アクセスの回数の増大を抑え、ECC
処理を実行してもプログラムの実行速度の大きな低下を
招くことのない、メモリ制御方法、ECC機能付きメモ
リ制御回路、及び、情報処理装置を提供することであ
る。
An object of the present invention is to suppress an increase in the number of memory accesses associated with ECC processing,
It is an object of the present invention to provide a memory control method, a memory control circuit with an ECC function, and an information processing device that do not cause a large reduction in the execution speed of a program even if a process is executed.

【0016】[0016]

【課題を解決するための手段】前記目的を達成するた
め、本発明に係るメモリ制御方法は、特定ビット長さの
情報毎にECCコードを加えてメモリ素子に書き込む際
に、CPUからの書き込み情報が前記特定ビット長さに
満たない場合は、以前に前記メモリ素子から読み出した
情報を前記メモリ素子とは別の手段に保持しておき、こ
の保持しておいた情報と前記CPUからの書き込み情報
とに基づいて前記特定ビット長さの情報を生成するよう
にして、メモリへの書き込み前にメモリからの読み出し
を必ずしも行わなくともECC処理が行えるようにし
た。
In order to achieve the above object, a memory control method according to the present invention provides a write information from a CPU when an ECC code is added to each piece of information of a specific bit length and the information is written in a memory element. Is less than the specific bit length, the information previously read from the memory element is held in a means different from the memory element, and the held information and the write information from the CPU are held. The information of the specific bit length is generated based on the above, and the ECC process can be performed without necessarily reading from the memory before writing to the memory.

【0017】また、本発明に係るECC機能付きメモリ
制御回路は、(a)CPUからのCPUアドレスに基づ
いて、前記CPUアドレスに対応するメモリ素子の記憶
領域を含む特定ビット長さ毎の記憶領域を特定するアド
レス情報を出力するためのアドレス発生手段と、(b)
前記特定ビット長さ毎の情報に対してECCコードを発
生するためのECCコード発生手段と、(c)メモリ素
子から読み出された前記特定ビット長さの情報を保持す
るための読み出し情報保持手段と、(d)前記読み出し
情報保持手段内の情報を前記ECCコードを用いて訂正
するためのECC手段と、(e)情報読み出し時又は情
報書き込み時に用いたCPUアドレスを保持するための
CPUアドレス保持手段と、(f)メモリ素子への情報
の書き込み時にCPUが発生したCPUアドレスと前記
CPUアドレス保持手段に保持されているCPUアドレ
スとを比較するためのアドレス比較手段と、(g)前記
アドレス比較手段の比較結果に応じて、前記読み出し情
報保持手段内の情報とCPUからの情報との両方に基づ
いて前記特定ビット長さの情報を生成して前記ECC手
段に与えるための書き込み情報生成手段と、を有するよ
うにして、メモリへの書き込み前にメモリからの読み出
しを必ずしも行わなくともECC処理が行えるようにし
た。
Further, the memory control circuit with an ECC function according to the present invention comprises: (a) a storage area for each specific bit length including a storage area of a memory element corresponding to the CPU address based on the CPU address from the CPU. Address generating means for outputting address information for specifying
ECC code generating means for generating an ECC code for the information for each specific bit length, and (c) read information holding means for holding the information of the specific bit length read from the memory element. And (d) ECC means for correcting the information in the read information holding means using the ECC code, and (e) CPU address holding for holding the CPU address used when reading or writing information. Means, (f) address comparing means for comparing the CPU address generated by the CPU when writing information to the memory element with the CPU address held in the CPU address holding means, and (g) the address comparison. According to the comparison result of the means, the specific bit is based on both the information in the read information holding means and the information from the CPU. Generates length information so as to have a, and write information generating means for providing to the ECC means and to allow the ECC processing not necessarily performed reading from the memory before writing to the memory.

【0018】[0018]

【実施例】以下、本発明の実施例を図面に基づいて説明
するが、前記従来例と同一又は類似する部分は同一の符
号を用いて説明を省略又は簡単にする。図1には本発明
に係る情報処理システムの一実施例が示されている。図
中、情報処理システム1のCPU10の出力するアドレ
ス信号はメモリ・コントローラ46の他にアドレス・ラ
ッチ42及びアドレス・コンパレータ44にも与えられ
る。アドレス・ラッチ42はアドレス線12上のアドレ
ス信号の値を保持する。アドレス・コンパレータ44は
アドレス・ラッチ42に保持されているアドレス値とア
ドレス線12上に新たに現れたアドレス信号の値とを比
較する。
Embodiments of the present invention will now be described with reference to the drawings. The same or similar parts as those of the conventional example will be designated by the same reference numerals and the description thereof will be omitted or simplified. FIG. 1 shows an embodiment of an information processing system according to the present invention. In the figure, the address signal output from the CPU 10 of the information processing system 1 is applied to the address latch 42 and the address comparator 44 in addition to the memory controller 46. Address latch 42 holds the value of the address signal on address line 12. The address comparator 44 compares the address value held in the address latch 42 with the value of the address signal newly appearing on the address line 12.

【0019】メモリ・コントローラ46はアドレス・コ
ンパレータ44における比較結果に応答してメモリ素子
20に対するアクセス動作を行う。メモリ素子20から
読み出されたデータはリード/ライト・バッファ26に
保持され、リード/ライト・バッファ26に保持された
データがエラー訂正された後に、ミキサー22において
CPU10からのデータと合成されてECCコード・ジ
ェネレータ24を経て、メモリ素子20に書き込まれる
ようになっている。
The memory controller 46 performs an access operation to the memory element 20 in response to the comparison result of the address comparator 44. The data read from the memory element 20 is held in the read / write buffer 26, and after the data held in the read / write buffer 26 is error-corrected, it is combined with the data from the CPU 10 in the mixer 22 to obtain the ECC. It is adapted to be written in the memory element 20 via the code generator 24.

【0020】このような実施例において、図2に示され
るように、アドレス0の"A"というデータを"B"という
データに書き換える場合について説明する。先ず、CP
U10は、アドレス線12上にアドレス0信号(32ビ
ット)を出力するとともに、データ線14上に8ビット
のデータ("B")を出力する。アドレス・ラッチ42に
はメモリ素子20に対する前回の読み出し時のアドレス
が保持されている。ここでは、前回の読み出し時のアド
レスがアドレス0からアドレス7の内の何れかであると
する。この場合、リード/ライト・バッファ26には前
回読み出されたデータ、即ち、64ビットのデータ("
AAAAAAAA")が保持されていることになる。
In such an embodiment, as shown in FIG. 2, a case where the data "A" at address 0 is rewritten to the data "B" will be described. First, CP
The U10 outputs an address 0 signal (32 bits) on the address line 12 and outputs 8-bit data ("B") on the data line 14. The address latch 42 holds the address of the memory element 20 at the time of the previous reading. Here, it is assumed that the address at the time of the previous reading is any one of the addresses 0 to 7. In this case, the read / write buffer 26 has previously read data, that is, 64-bit data ("
AAAAAAAA ″) is held.

【0021】アドレス・コンパレータ44は、CPU1
0が新たに出力したアドレス(この場合は、アドレス
0)とアドレス・ラッチ42に保持されているアドレス
値とを比較する。CPU10が新たに出力したアドレス
値がアドレス0であるときに、アドレス・ラッチ42に
保持されているアドレス値がアドレス0からアドレス7
の内の何れかである場合は、その旨を示す信号がアドレ
ス・コンパレータ44からメモリ・コントローラ46に
与えられ、メモリ・コントローラ46はメモリ素子20
に対するリード・モディファイ・ライトのための読み出
し動作を行わない。前述したように、アドレス・ラッチ
42に保持されているアドレス値がアドレス0からアド
レス7の内の何れかである場合は、リード/ライト・バ
ッファ26には前回読み出されたデータとして64ビッ
トのデータ("AAAAAAAA")が保持されている。
The address comparator 44 is the CPU 1
The address 0 newly output (address 0 in this case) is compared with the address value held in the address latch 42. When the address value newly output by the CPU 10 is the address 0, the address value held in the address latch 42 is changed from the address 0 to the address 7
If it is any of the above, a signal indicating that is given from the address comparator 44 to the memory controller 46, and the memory controller 46 causes the memory element 20 to operate.
The read operation for read modify write is not performed. As described above, when the address value held in the address latch 42 is any one of the addresses 0 to 7, the read / write buffer 26 has 64-bit data as the previously read data. The data ("AAAAAAAA") is held.

【0022】ミキサー22は、リード/ライト・バッフ
ァ26から与えられる64ビットのデータ("AAAA
AAAA")とCPU10からの8ビットのデータ("
B")とを合成して新たに64ビットのデータ("BAA
AAAAA")を生成して出力する。ECCコード・ジ
ェネレータ24は、ミキサー22が生成した64ビット
のデータ("BAAAAAAA")に対してECCコード
を生成する。こうして生成された64ビットのデー
タ("BAAAAAAA")とECCコードとがメモリ素
子20に書き込まれる。
The mixer 22 receives the 64-bit data ("AAAAA" supplied from the read / write buffer 26).
AAAA ") and 8-bit data (""from the CPU 10
B ") and newly combine with 64-bit data (" BAA
The ECC code generator 24 generates an ECC code for the 64-bit data ("BAAAAAAA") generated by the mixer 22. The 64-bit data (" BAAAAAAA ″) and the ECC code are written to the memory element 20.

【0023】CPU10が新たに出力したアドレス値が
アドレス0であるときに、アドレス・ラッチ42に保持
されているアドレス値がアドレス0からアドレス7の内
の何れでもないときは、その旨を示す信号がアドレス・
コンパレータ44からメモリ・コントローラ46に与え
られ、メモリ・コントローラ46はメモリ素子20に対
するリード・モディファイ・ライトのための読み出し動
作を行う。
When the address value newly output by the CPU 10 is the address 0 and the address value held in the address latch 42 is not one of the addresses 0 to 7, a signal indicating that fact. Is the address
The data is supplied from the comparator 44 to the memory controller 46, and the memory controller 46 performs a read operation for read-modify-write on the memory element 20.

【0024】このような本実施例によれば、直前のメモ
リ・サイクルのアドレス及びデータを保持しておく手段
を設けたことにより、特定ビット長さ毎のデータに対す
るECC処理のために行っていたリード・モディファイ
・ライトのためのメモリ読み出しの回数を減らすことが
できる。直前のメモリ・サイクルで読み出したデータが
利用できない場合もある。しかし、プログラムの実行に
おいては、メモリ素子20の連続するアドレスに順番に
アクセスしていくことが多い。連続するアドレスに順番
にアクセスする場合には、直前のメモリ・サイクルのデ
ータを利用できることが多く、リード・モディファイ・
ライトのための読み出し動作の回数を十分に減らすこと
ができる。
According to this embodiment, the means for holding the address and the data of the immediately preceding memory cycle is provided, so that the ECC processing is performed on the data of each specific bit length. The number of memory readings for read-modify-write can be reduced. In some cases, the data read in the last memory cycle may not be available. However, in executing a program, it is often the case that successive addresses of the memory element 20 are sequentially accessed. When accessing consecutive addresses in order, the data of the immediately preceding memory cycle is often available, and read modify
The number of read operations for writing can be sufficiently reduced.

【0025】尚、前記実施例では64ビット長のデータ
毎に8ビットのECCコードを付加したが、本発明が適
用されるのは64ビット以外の長さのデータであっても
よいし、それに伴い、ECCコードの長さも8ビット以
外であってもよい。また、CPUは32ビット型でなく
ともよいし、RISC型であるかCISC型であるかも
問わない。メモリ素子の構成も前述の構成に限られず、
インタリーブ・アクセス方式であるか非インタリーブ・
アクセス方式であるか等も問わない。
In the above embodiment, an 8-bit ECC code is added to each 64-bit data, but the present invention may be applied to data having a length other than 64 bits. Accordingly, the length of the ECC code may be other than 8 bits. Further, the CPU does not have to be a 32-bit type and may be a RISC type or a CISC type. The configuration of the memory element is not limited to the above configuration,
Interleaved access method or non-interleaved
It does not matter whether it is an access method or the like.

【0026】[0026]

【発明の効果】上述のように本発明によれば、ECC処
理に伴うメモリ・アクセスの回数の増大を抑え、ECC
処理を実行してもプログラムの実行速度の大きな低下を
招くことのない、メモリ制御方法、ECC機能付きメモ
リ制御回路、及び、情報処理装置を提供できる。
As described above, according to the present invention, it is possible to suppress an increase in the number of memory accesses associated with ECC processing,
It is possible to provide a memory control method, a memory control circuit with an ECC function, and an information processing device that do not cause a large reduction in the execution speed of a program even if a process is executed.

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

【図1】本発明によるECC処理機能を備えたデータ処
理システムの一実施例の構成を示すブロック図である。
FIG. 1 is a block diagram showing the configuration of an embodiment of a data processing system having an ECC processing function according to the present invention.

【図2】メモリへの書き込み前と書き込み後のデータの
構成の一例を示すブロック図である。
FIG. 2 is a block diagram showing an example of a configuration of data before and after writing to a memory.

【図3】従来のECC処理機能を備えたデータ処理シス
テムの一例の構成を示すブロック図である。
FIG. 3 is a block diagram showing a configuration of an example of a conventional data processing system having an ECC processing function.

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

1 情報処理システム 10 CPU 16 メモリ・コントローラ 20 メモリ素子 22 ミキサー 24 ECCコード・ジェネレータ 26 リード/ライト・バッファ 28 リード・バッファ 32 エラー・ビット検出回路 34 エラー・ビット訂正回路 42 アドレス・ラッチ 44 アドレス・コンパレータ 46 メモリ・コントローラ 1 Information Processing System 10 CPU 16 Memory Controller 20 Memory Element 22 Mixer 24 ECC Code Generator 26 Read / Write Buffer 28 Read Buffer 32 Error Bit Detection Circuit 34 Error Bit Correction Circuit 42 Address Latch 44 Address Comparator 46 memory controller

───────────────────────────────────────────────────── フロントページの続き (72)発明者 藤田 信人 滋賀県野洲郡野洲町大字市三宅800番地 日本アイ・ビー・エム株式会社 野洲事業 所内 (72)発明者 山崎 哲 神奈川県大和市下鶴間1623番地14 日本ア イ・ビー・エム株式会社 大和事業所内 (72)発明者 合田 光宏 神奈川県大和市下鶴間1623番地14 日本ア イ・ビー・エム株式会社 大和事業所内 ─────────────────────────────────────────────────── ─── Continuation of the front page (72) Innovator Nobuto Fujita 800 Miyake, Yasu-cho, Yasu-gun, Shiga Prefecture In the Yasu Business Office, IBM Japan, Ltd. (72) Satoshi Yamazaki 1623 Shimotsuruma, Yamato-shi, Kanagawa Prefecture Address 14 Japan AIBM Co., Ltd. Yamato Works (72) Inventor Mitsuhiro Goda 1623 Shimotsuruma, Yamato City, Kanagawa Prefecture 14 Japan AIBM Co., Ltd. Yamato Works

Claims (3)

【特許請求の範囲】[Claims] 【請求項1】特定ビット長さの情報毎にECCコードを
加えてメモリ素子に書き込む際に、CPUからの書き込
み情報が前記特定ビット長さに満たない場合は、以前に
前記メモリ素子から読み出した情報を前記メモリ素子と
は別の手段に保持しておき、この保持しておいた情報と
前記CPUからの書き込み情報とに基づいて前記特定の
ビット長さの情報を生成することを特徴とする、メモリ
制御方法。
1. When an ECC code is added to each piece of information of a specific bit length and written in a memory element, if the write information from the CPU is less than the specific bit length, it is read from the memory element before. Information is held in a means different from the memory element, and the information of the specific bit length is generated based on the held information and the write information from the CPU. , Memory control method.
【請求項2】CPUとメモリ素子との間に介在するEC
C機能付きメモリ制御回路において、(a)CPUから
のCPUアドレスに基づいて、前記CPUアドレスに対
応するメモリ素子の記憶領域を含む特定ビット長さ毎の
記憶領域を特定するアドレス情報を出力するためのアド
レス発生手段と、(b)前記特定ビット長さ毎の情報に
対してECCコードを発生するためのECCコード発生
手段と、(c)メモリ素子から読み出された前記特定ビ
ット長さの情報を保持するための読み出し情報保持手段
と、(d)前記読み出し情報保持手段内の情報を前記E
CCコードを用いて訂正するためのECC手段と、
(e)情報読み出し時又は情報書き込み時に用いたCP
Uアドレスを保持するためのCPUアドレス保持手段
と、(f)メモリ素子への情報の書き込み時にCPUが
発生したCPUアドレスと前記CPUアドレス保持手段
に保持されているCPUアドレスとを比較するためのア
ドレス比較手段と、(g)前記アドレス比較手段の比較
結果に応じて、前記読み出し情報保持手段内の情報とC
PUからの情報との両方に基づいて前記特定ビット長さ
の情報を生成して前記ECC手段に与えるための書き込
み情報生成手段と、を有するECC機能付きメモリ制御
回路。
2. An EC interposed between a CPU and a memory element
In the memory control circuit with C function, (a) for outputting address information for specifying a storage area for each specific bit length including a storage area of the memory element corresponding to the CPU address, based on the CPU address from the CPU Address generating means, (b) ECC code generating means for generating an ECC code for the information for each specific bit length, and (c) the specific bit length information read from the memory device. Read information holding means for holding the information, and (d) the information in the read information holding means
ECC means for correction using CC code,
(E) CP used when reading or writing information
CPU address holding means for holding the U address, and (f) an address for comparing the CPU address generated by the CPU at the time of writing information to the memory element with the CPU address held in the CPU address holding means. And (g) the information in the read information holding means and C in accordance with the comparison result of the address comparing means.
A memory control circuit with an ECC function, comprising: write information generating means for generating the information of the specific bit length based on both of the information from the PU and giving it to the ECC means.
【請求項3】CPUと、メモリ素子と、前記CPUと前
記メモリ素子との間に介在するECC機能付きメモリ制
御回路と、を有する情報処理装置において、前記メモリ
制御回路は、(a)CPUからのCPUアドレスに基づ
いて、前記CPUアドレスに対応するメモリ素子の記憶
領域を含む特定ビット長さ毎の記憶領域を特定するアド
レス情報を出力するためのアドレス発生手段と、(b)
前記特定ビット長さ毎の情報に対してECCコードを発
生するためのECCコード発生手段と、(c)メモリ素
子から読み出された前記特定ビット長さの情報を保持す
るための読み出し情報保持手段と、(d)前記読み出し
情報保持手段内の情報を前記ECCコードを用いて訂正
するためのECC手段と、(e)情報読み出し時又は情
報書き込み時に用いたCPUアドレスを保持するための
CPUアドレス保持手段と、(f)メモリ素子への情報
の書き込み時にCPUが発生したCPUアドレスと前記
CPUアドレス保持手段に保持されているCPUアドレ
スとを比較するためのアドレス比較手段と、(g)前記
アドレス比較手段の比較結果に応じて、前記読み出し情
報保持手段内の情報とCPUからの情報との両方に基づ
いて前記特定ビット長さの情報を生成して前記ECC手
段に与えるための書き込み情報生成手段と、を有する、
情報処理装置。
3. An information processing apparatus comprising a CPU, a memory element, and a memory control circuit with an ECC function interposed between the CPU and the memory element, wherein the memory control circuit comprises: Address generation means for outputting address information for specifying a storage area for each specific bit length including the storage area of the memory element corresponding to the CPU address,
ECC code generating means for generating an ECC code for the information for each specific bit length, and (c) read information holding means for holding the information of the specific bit length read from the memory element. And (d) ECC means for correcting the information in the read information holding means using the ECC code, and (e) CPU address holding for holding the CPU address used when reading or writing information. Means, (f) address comparing means for comparing the CPU address generated by the CPU when writing information to the memory element with the CPU address held in the CPU address holding means, and (g) the address comparison. According to the comparison result of the means, the specific bit is based on both the information in the read information holding means and the information from the CPU. It generates the length information having a write information generating means for providing to the ECC unit,
Information processing equipment.
JP5021105A 1993-02-09 1993-02-09 Method for memory control, memory control circuit with ecc function and information processor Pending JPH06250937A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP5021105A JPH06250937A (en) 1993-02-09 1993-02-09 Method for memory control, memory control circuit with ecc function and information processor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP5021105A JPH06250937A (en) 1993-02-09 1993-02-09 Method for memory control, memory control circuit with ecc function and information processor

Publications (1)

Publication Number Publication Date
JPH06250937A true JPH06250937A (en) 1994-09-09

Family

ID=12045602

Family Applications (1)

Application Number Title Priority Date Filing Date
JP5021105A Pending JPH06250937A (en) 1993-02-09 1993-02-09 Method for memory control, memory control circuit with ecc function and information processor

Country Status (1)

Country Link
JP (1) JPH06250937A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016219071A (en) * 2015-05-15 2016-12-22 ラピスセミコンダクタ株式会社 Semiconductor memory and data write method

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH04104345A (en) * 1990-08-23 1992-04-06 Pfu Ltd Write control system for partial rewrite data of main storage device with ecc mechanism

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH04104345A (en) * 1990-08-23 1992-04-06 Pfu Ltd Write control system for partial rewrite data of main storage device with ecc mechanism

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016219071A (en) * 2015-05-15 2016-12-22 ラピスセミコンダクタ株式会社 Semiconductor memory and data write method

Similar Documents

Publication Publication Date Title
US6009548A (en) Error correcting code retrofit method and apparatus for multiple memory configurations
US5481552A (en) Method and structure for providing error correction code for 8-byte data words on SIMM cards
JPH06250937A (en) Method for memory control, memory control circuit with ecc function and information processor
US5359719A (en) Address range setting method and apparatus for a computer expansion card
JP3507193B2 (en) Load / store instruction processor
JPH01194046A (en) Memory access system
JPH0355918B2 (en)
JPH05158810A (en) Error detection circuit
JP2565590B2 (en) Data processing device
JPH11194975A (en) Memory system
JPH01140359A (en) Main storage device
JPH0520215A (en) Information processor
JPH06301604A (en) Storage reproducing system
JPS59110098A (en) Error correcting device of data storage device
JPS5936398A (en) Storage device
JPS61110247A (en) Storage device
JPH02110741A (en) Microprogram controller
JPH0452976B2 (en)
JPH0646520B2 (en) Semiconductor memory device
JPS59129995A (en) Storage device
JPH09114748A (en) Memory error correction circuit
JPH02144633A (en) Error correcting device for control storage
JPS63216150A (en) Storage device
JPH04101247A (en) Main storage device
JPS61139836A (en) Instruction control system of pipeline computer