JPH06119238A - Method and device for controlling main storage - Google Patents

Method and device for controlling main storage

Info

Publication number
JPH06119238A
JPH06119238A JP26842392A JP26842392A JPH06119238A JP H06119238 A JPH06119238 A JP H06119238A JP 26842392 A JP26842392 A JP 26842392A JP 26842392 A JP26842392 A JP 26842392A JP H06119238 A JPH06119238 A JP H06119238A
Authority
JP
Japan
Prior art keywords
data
write
address
register
memory
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP26842392A
Other languages
Japanese (ja)
Inventor
Yoshiaki Hisada
義明 久田
Masaaki Yamamoto
昌明 山本
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.)
Hitachi Ltd
Hitachi Industrial Equipment Co Ltd
Original Assignee
Hitachi Ltd
Hitachi West Service Engineering 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 Hitachi Ltd, Hitachi West Service Engineering Co Ltd filed Critical Hitachi Ltd
Priority to JP26842392A priority Critical patent/JPH06119238A/en
Publication of JPH06119238A publication Critical patent/JPH06119238A/en
Pending legal-status Critical Current

Links

Abstract

PURPOSE:To optimize a partial write operation and to control it at a high speed by providing a comparator for comparing occasionally a partial write exclusive address register and an address, in a main storage controller. CONSTITUTION:In the case actuated memory write is partial write, first of all, the contents of a partial write exclusive register 5 in a main storage controller 3, and the contents of an address register 6 latched at the time of actuating the memory write are compared by a comparator 7. In the case a result of comparison is formed, and also, the contents of a flag 8 set from a central processing unit 1 are set to an effective mode, an output of an AND gate 9 becomes '1' and a partial write hit is decided. An output of the hit is sent to selectors 19-22 of a data input and a memory data register 10. In such a way, data existing in the register 10 is used again.

Description

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

【0001】[0001]

【産業上の利用分野】本発明は、パ−シャルライトアク
セス(部分書き込み)の高速化が可能な主記憶制御方法
および装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a main memory control method and apparatus capable of speeding up partial write access (partial write).

【0002】[0002]

【従来の技術】従来、パ−シャルライトアクセスは、先
ずアクセスを行うアドレスに対する全ワ−ドデ−タを読
み込み、そのデ−タに書き込むデ−タをマ−ジして、マ
−ジしたライトデ−タに従ってECCコ−ドを生成し、
主記憶に書き込みを行っていた。すなわち、ECC方式
を用いた主記憶装置で、パ−シャルライトアクセスを行
う場合、アクセスを行うべきアドレスに対するメモリデ
−タを一時、主記憶制御装置内のメモリリ−ドデ−タレ
ジスタに取り込み、パ−シャルライトを行うべく中央処
理装置あるいはI/O制御装置から受け取ったライトデ
−タとマ−ジを行い、マ−ジを行ったライトデ−タに対
してECCコ−ドを生成して、主記憶装置に書き込みを
行っていた。従って、一般のメモリアクセスモ−ドとし
ては、最も長いアクセスタイムを必要としていた。ま
た、従来、主記憶装置との間のデ−タ転送を高速化する
ためには、キャッシュメモリ等の緩衝記憶装置を用いる
方法が最も一般的である。例えば、特開平3−2696
50号公報に記載された『バッファ記憶装置』では、バ
ッファへの登録をム−ブイン動作(アドレスが一致する
かを比較する)とストア命令によるストア動作を1つに
して、主記憶装置側に対しては部分書き込みをフルスト
アに変えることにより(ストアバッファ内のバイトマ−
ク内容に従って書き換える)、ストア動作の高速化を図
っている。この装置では、ライト用のアドレスレジスタ
とデ−タレジスタとを具備している。しかしながら、主
記憶装置からのリ−ドデ−タをライト用のデ−タレジス
タに保持しないので、パ−シャルライトが連続した場合
には、主記憶装置からのリ−ドを省略することができ
ず、必ずしも十分な方法ではなかった。
2. Description of the Related Art Conventionally, in partial write access, all word data for an address to be accessed is first read, and the data written to that data is merged and merged. Generate an ECC code according to the write data,
I was writing to main memory. That is, when performing a partial write access in the main memory device using the ECC system, the memory data for the address to be accessed is temporarily fetched in the memory read data register in the main memory control device and The write data received from the central processing unit or the I / O control unit is executed to perform the charr write, and an ECC code is generated for the written write data to generate the main memory. I was writing to the device. Therefore, the general memory access mode requires the longest access time. Further, conventionally, a method using a buffer storage device such as a cache memory is the most general method in order to speed up data transfer with the main storage device. For example, JP-A-3-2696
In the "buffer storage device" described in Japanese Patent Publication No. 50, the move-in operation for registering in the buffer (comparing whether the addresses match) and the store operation by the store instruction are integrated into one, and the main storage device side is provided. On the other hand, by changing partial write to full store (byte mark in store buffer
Rewrite according to the content), to speed up the store operation. This device is provided with a write address register and a data register. However, since the read data from the main memory is not held in the data register for writing, the read from the main memory can be omitted when the partial write continues. No, it wasn't always enough.

【0003】[0003]

【発明が解決しようとする課題】このように、従来のE
CC方式の主記憶装置に対するパ−シャルライト制御
は、メモリライト制御を行う前に、ライトすべきアドレ
スの全ワ−ドデ−タを一時主記憶制御装置内に取り込
み、このデ−タと中央処理装置またはI/O制御装置か
ら受け取ったライトデ−タをマ−ジして、その結果をも
とにECCコ−ドを生成し直し、主記憶装置に対してラ
イト処理を行っていた。このために、パ−シャルライト
アクセス時の主記憶装置においては、メモリライト制御
に加えてメモリリ−ド制御が必要となり、アクセスタイ
ムの高速化のネックとなっていた。本発明の目的は、こ
のような従来の課題を解決し、パ−シャルライトが同じ
アドレスに連続して行われる場合に、アクセス時間を短
縮してメモリアクセスを高速化できる主記憶制御方法お
よび装置を提供することにある。
As described above, the conventional E
In the partial write control for the CC type main memory device, all the word data of the address to be written is fetched into the temporary main memory control device before the memory write control, and this data and the central data are stored. The write data received from the processing unit or the I / O control unit is merged, the ECC code is regenerated based on the result, and the write process is performed on the main storage unit. Therefore, in the main memory at the time of the partial write access, the memory read control is required in addition to the memory write control, which has been a bottleneck in shortening the access time. SUMMARY OF THE INVENTION An object of the present invention is to solve such a conventional problem, and when a partial write is continuously performed to the same address, a main memory control method and apparatus capable of shortening access time and speeding up memory access. To provide.

【0004】[0004]

【課題を解決するための手段】上記目的を達成するた
め、本発明の主記憶制御装置は、(イ)中央処理装置あ
るいはこれと同等の機能を有する処理装置と、ECCを
具備した主記憶装置と、主記憶装置を制御する主記憶制
御装置を有する処理システムにおいて、主記憶制御装置
内に、主記憶装置から前回に読み出した全ワ−ドデ−タ
を格納し、次回のパ−シャルライトアクセスが前回と同
じアドレスの場合に、主記憶装置から読み出す代りにこ
の内容が読み出される1ないし複数本のメモリデ−タレ
ジスタと、主記憶装置へ前回アクセスされたパ−シャル
ライトアドレスの全ワ−ドに対応するアドレスを格納す
るパ−シャルライト専用アドレスレジスタと、パ−シャ
ルライト専用アドレスレジスタと中央処理装置あるいは
他の処理装置からのパ−シャルライトアドレスを比較し
て、一致した場合には、メモリデ−タレジスタの上記パ
−シャルライトアドレスに対応した部分を中央処理装置
あるいは他の処理装置から出力されたライトデ−タとマ
−ジして、マ−ジしたデ−タを主記憶装置に書き込むた
めの比較手段とを具備することを特徴としている。ま
た、本発明の主記憶制御方法は、(ロ)主記憶装置に部
分書き込みを実行する場合に、主記憶装置からパ−シャ
ルライトアドレスに対応する全ワ−ドデ−タを読み出
し、読み出されたデ−タを部分変更し、部分変更された
デ−タに対するECCコ−ドの生成を行った後、変更さ
れたデ−タと生成されたECCコ−ドを書き込む主記憶
制御方法において、前回アクセスされたパ−シャルライ
トアドレスが格納されたアドレスレジスタと、今回アク
セスされたパ−シャルライトアドレスとを比較し、比較
結果が一致した場合には、前回読み出された全ワ−ドデ
−タが格納されているメモリデ−タレジスタのパ−シャ
ルライトアドレスに対応した部分を、今回アクセスされ
るメモリライトデ−タに書き換え、主記憶装置に書き換
えたメモリライトレジスタのデ−タおよびメモリライト
レジスタのデ−タより生成されたECCコ−ドをメモリ
デ−タレジスタに格納し、また比較結果が不一致の場合
には、主記憶装置からパ−シャルライトアドレスに対応
した全リ−ドデ−タを読み出し、読み出されたデ−タを
メモリデ−タレジスタに格納し、格納されたデ−タのパ
−シャルライトアドレスに対応する部分をメモリライト
レジスタに置き換え、置き換えたメモリライトデ−タお
よびメモリライトデ−タより生成されたECCコ−ドを
主記憶装置およびメモリデ−タレジスタに同時に格納す
ることを特徴としている。また、(ハ)前回アクセスさ
れたパ−シャルライトアドレスが格納されたアドレスレ
ジスタには、メモリライトレジスタに格納されるデ−タ
の有効性を判断するためのフラグを設け、システムパワ
−オン時および障害発生時には上記フラグを無効と設定
し、アドレスレジスタでパ−シャルライトアドレスが正
常に更新された時には有効と設定し、フラグが無効の場
合には、前回アクセスされたパ−シャルライトアドレス
が格納されたアドレスレジスタと、今回アクセスされた
パ−シャルライトアドレスとを比較した場合の比較結果
を強制的に不一致とすることも特徴としている。また、
(ニ)中央処理装置あるいは他の処理装置からフルライ
ト起動があった場合、起動時のライトアドレスと前回ア
クセスされたパ−シャルライトアドレスが格納されたア
ドレスレジスタの内容とを比較し、比較結果が一致の場
合には、アドレスレジスタの内容をライトアドレスの内
容に更新することも特徴としている。
To achieve the above object, a main memory control device of the present invention comprises: (a) a central processing device or a processing device having a function equivalent to this; and a main memory device having an ECC. In a processing system having a main memory control device for controlling the main memory device, all word data previously read from the main memory device is stored in the main memory controller, and the next partial write is performed. When the access is at the same address as the last time, one or more memory data registers whose contents are read instead of being read from the main memory and all words of the partial write address last accessed to the main memory Partial write dedicated address register that stores the address corresponding to, the partial write dedicated address register and the central processing unit or another processing unit -Compare the write write addresses and if they match, the part of the memory data register corresponding to the above partial write address is merged with the write data output from the central processing unit or another processing unit. And comparing means for writing the merged data to the main memory. Further, according to the main memory control method of the present invention, (b) when partial writing is executed in the main memory device, all word data corresponding to the partial write address are read from and read from the main memory device. In a main memory control method in which the changed data is partially changed, an ECC code is generated for the partially changed data, and then the changed data and the generated ECC code are written. , The address register storing the previously accessed partial write address is compared with the partial write address accessed this time, and if the comparison results match, all words read last time are read. A memory write in which the portion corresponding to the partial write address of the memory data register in which the data is stored is rewritten to the memory write data to be accessed this time and rewritten to the main memory device. The ECC code generated from the data of the register and the data of the memory write register is stored in the memory data register, and when the comparison result does not match, the main memory corresponds to the partial write address. Read all read data, store the read data in the memory data register, and replace the part corresponding to the partial write address of the stored data with the memory write register. The memory write data and the ECC code generated from the memory write data are simultaneously stored in the main memory and the memory data register. In addition, (c) a flag for judging the validity of the data stored in the memory write register is provided in the address register storing the previously accessed partial write address, and when the system power is turned on. And when a failure occurs, the flag is set to invalid, when the partial write address is updated normally in the address register, it is set to valid. When the flag is invalid, the previously accessed partial write address is set. It is also characterized in that the comparison result when the stored address register is compared with the partial write address accessed this time is forcibly made to be inconsistent. Also,
(D) When a full write is activated from the central processing unit or another processing unit, the write address at the time of activation is compared with the contents of the address register that stores the previously accessed partial write address, and the comparison result If the two match, the contents of the address register are updated to the contents of the write address.

【0005】[0005]

【作用】本発明においては、パ−シャルライト専用のア
ドレスレジスタとアドレスを随時比較する手段を用いる
ことにより、パ−シャルライトを行う前に、ライトすべ
きアドレスに対する全ワ−ドデ−タを主記憶装置内に一
旦取り込む動作が必要であるか否かを判定し、同じアド
レスに対する書き込みのときには、取り込み動作を省略
することにより、パ−シャルライト時のメモリアクセス
最適化、高速化を実現する。すなわち、中央処理装置ま
たはI/O制御装置からのパ−シャルライト起動時に、
比較回路の結果が一致した場合には、今回の起動以前に
行ったパ−シャルライトアクセスにおけるライトすべき
アドレスの全ワ−ドのデ−タが既に主記憶制御装置内に
存在するので、メモリリ−ド動作を行う必要がなく、起
動時に受け取ったライトデ−タと既存のデ−タをマ−ジ
し、ECCコ−ドを生成してメモリライト制御のみを行
うだけでよい。つまり、見掛けは主記憶装置に対するフ
ルライト制御と同じになるので、パ−シャルライトアク
セスの高速化が可能となる。
In the present invention, by using the address register dedicated to the partial write and the means for comparing the addresses at any time, all the word data for the address to be written can be obtained before the partial write. It is determined whether a fetch operation is required once in the main memory, and when writing to the same address, skip the fetch operation to realize memory access optimization and speedup at the time of partial write. . That is, at the time of starting the partial write from the central processing unit or the I / O control unit,
If the results of the comparison circuit match, the data of all the words of the address to be written in the partial write access performed before this activation is already present in the main memory control device, so the memory memory is rewritten. It is not necessary to perform the read operation, and it is sufficient to manage the write data received at the time of start-up and the existing data, generate the ECC code, and perform only the memory write control. That is, since the appearance is the same as the full write control for the main storage device, the speed of the partial write access can be increased.

【0006】[0006]

【実施例】以下、本発明の実施例を、図面により詳細に
説明する。図1は、本発明が適用される主記憶制御装置
のブロック図である。図1において、1は中央処理装
置、2は主記憶装置、3は主記憶制御装置、4は中央処
理装置1からのライトデ−タを保持するメモリライトレ
ジスタ、5はパ−シャルライト専用アドレスレジスタ、
6はアドレスレジスタ、7はレジスタ5と6の内容を比
較する比較器、8は比較結果が有効であるか否かを制御
するフラグ、9は比較器により比較された結果を、フラ
グ8により無条件に無効にするためのANDゲ−ト、1
0主記憶装置2から読み出されたデ−タを蓄積するメモ
リデ−タレジスタ、11は主記憶装置2に対する制御信
号を生成するタイミング制御回路、12はメモリデ−タ
レジスタ10に取り込まれたデ−タのECCチェックを
行うECCチェックカ、13は主記憶装置2に対してラ
イトを行う時のECCを生成するためのECC生成回
路、14は主記憶装置2と主記憶制御装置3との間のデ
−タ方向制御を行う双方向ドライバ、15〜18はパ−
シャルライトを行うためのマ−ジセレクタ、19〜22
はメモリデ−タレジスタ10に対するデ−タ入力セレク
タであって、通常のメモリリ−ドデ−タバス26とメモ
リライトデ−タバス27とを選択するように接続されて
いる。23はパ−シャルライトすべきバイト位置を示す
バイトイネ−ブル、24はデ−タバス、25はアドレス
バス、28はパ−シャルライト専用アドレスレジスタ5
の内容を、アドレスレジスタ6の内容に更新を行う時に
用いるアドレス更新専用バスである。
Embodiments of the present invention will now be described in detail with reference to the drawings. FIG. 1 is a block diagram of a main memory control device to which the present invention is applied. In FIG. 1, reference numeral 1 is a central processing unit, 2 is a main memory unit, 3 is a main memory control unit, 4 is a memory write register for holding write data from the central processing unit 1, and 5 is a partial address dedicated to partial write. ,
6 is an address register, 7 is a comparator for comparing the contents of the registers 5 and 6, 8 is a flag for controlling whether the comparison result is valid, 9 is the result of comparison by the comparator, and 8 is the flag. AND gate to invalidate the condition, 1
0 a memory data register for accumulating data read from the main memory 2, 11 a timing control circuit for generating a control signal for the main memory 2, 12 a data fetched in the memory data register 10 An ECC checker for performing an ECC check, 13 an ECC generation circuit for generating an ECC when writing to the main memory 2, and 14 a data between the main memory 2 and the main memory controller 3. Bidirectional driver for controlling data direction
Margin selectors 19 to 22 for performing charlight
Is a data input selector for the memory data register 10 and is connected so as to select a normal memory read data bus 26 and a memory write data bus 27. Reference numeral 23 is a byte enable indicating a byte position to be partially written, 24 is a data bus, 25 is an address bus, and 28 is a dedicated address register 5 for partial write.
Is an address update-dedicated bus used for updating the contents of the address register 6 to the contents of the address register 6.

【0007】図2は、図1における動作フロ−チャ−ト
である。ここでは、中央処理装置1からのパ−シャルラ
イトアクセスを例にして、パ−シャルライトの高速化に
ついて説明する。中央処理装置1からメモリライト起動
がかけられると(ステップ51)、先ずバイトイネ−ブ
ル23の情報を元にして、メモリライトモ−ドがパ−シ
ャルライトであるか否かを判断する(ステップ52)。
起動されたメモリライトがパ−シャルライトであった場
合には、先ず比較器7により主記憶制御装置3内のパ−
シャルライト専用レジスタ5の内容と、メモリライト起
動の際にラッチしたアドレスレジスタ6の内容とを比較
する(ステップ53)。比較結果が成立し、かつ中央処
理装置1から設定されているフラグ8の内容が有効モ−
ドに設定されている場合には、ANDゲ−ト9の出力が
1となって、パ−シャルライトヒットを判断する。ヒッ
トの出力は、デ−タ入力のセレクタ19〜22およびメ
モリデ−タレジスタ10に送られる。これにより、メモ
リデ−タレジスタ10に存在するデ−タは再度使用され
ることになる。すなわち、今回起動されたメモリライト
アクセス以前のメモリライト起動により、主記憶制御装
置3内のメモリデ−タレジスタ10には、パ−シャルラ
イトを行おうとしている主記憶装置アドレス内デ−タと
同じ内容が既に取り込まれているので、メモリリ−ド処
理を行う必要はなく、メモリデ−タレジスタ10の内容
とメモリライトレジスタ4の内容を、バイトイネ−ブル
23の情報に従ってセレクタ15〜18を使用してマ−
ジを行う(ステップ54)。そして、そのマ−ジしたデ
−タを元に、ECC生成回路12により新たにECCコ
−ドを生成し(ステップ55)、メモリライト処理を行
う(ステップ56)。これにより、パ−シャルライト処
理は終了する。
FIG. 2 is an operation flowchart in FIG. Here, the speeding up of the partial write will be described by taking the partial write access from the central processing unit 1 as an example. When the memory write is activated from the central processing unit 1 (step 51), it is first judged based on the information in the byte enable 23 whether the memory write mode is the partial write (step 52). ).
When the activated memory write is a partial write, the comparator 7 first causes the partial memory in the main memory control device 3 to be accessed.
The contents of the dedicated write dedicated register 5 are compared with the contents of the address register 6 latched when the memory write is activated (step 53). If the comparison result is satisfied and the content of the flag 8 set by the central processing unit 1 is valid mode.
If it is set to the read mode, the output of the AND gate 9 becomes 1 and a partial write hit is judged. The output of the hit is sent to the data input selectors 19 to 22 and the memory data register 10. As a result, the data existing in the memory data register 10 is reused. That is, by the memory write activation before the memory write access activated this time, the memory data register 10 in the main memory control device 3 has the same contents as the data in the main memory device address which is about to be partially written. Since it has already been fetched, it is not necessary to carry out the memory read processing, and the contents of the memory data register 10 and the memory write register 4 are read by the selectors 15 to 18 according to the information of the byte enable 23.
(Step 54). Then, based on the merged data, the ECC generating circuit 12 newly generates an ECC code (step 55), and a memory write process is performed (step 56). As a result, the partial write process ends.

【0008】図2において、比較器7の比較が不一致で
あったときには(ステップ53)、次のメモリパ−シャ
ルライトアクセスに備えて、メモリデ−タレジスタ10
の内容も、メモリライトを行ったライトデ−タをセレク
タ19〜22を介して取り込み、更新を行っておく(ス
テップ57)。このように、メモリライト処理におい
て、中央処理装置1から起動されたライトモ−ドがパ−
シャルライトモ−ドである場合でも、リ−ドモディファ
イライトを行うことなく、主記憶装置2に対してはフル
ライトのモ−ドの如く処理を行わせることができる。そ
の結果、従来は必須であったパ−シャルライト実行時の
メモリリ−ド処理を省略することができるので、主記憶
装置2に対するパ−シャルライト時のアクセスタイムを
短縮することができる。このように、起動されたメモリ
ライトアクセスがパ−シャルライトであっても、比較器
7の比較結果が不一致であるときには(ステップ5
3)、従来のパ−シャルライトアクセスの処理と同じよ
うに、先ず主記憶装置2の全ワ−ドの内容をメモリリ−
ド処理を行うことによりメモリデ−タレジスタ10に取
り込み(ステップ57)、比較器7の比較結果が不一致
であったので、パ−シャルライト専用アドレスレジスタ
5の内容も、アドレス更新専用バス28を介して今回の
メモリライト起動アドレスの内容に更新しておく(ステ
ップ58)。この後、メモリデ−タレジスタ10の内容
と、中央処理装置1から受け取ったメモリライトデ−タ
がラッチされているメモリライトレジスタ4の内容を、
セレクタ15〜18によりマ−ジを行い(ステップ5
4)、マ−ジした結果を元にECC生成回路12を用い
てECCコ−ドを生成し(ステップ55)、メモリライ
ト処理を行うと同時に、ライトしたデ−タをセレクタ1
9〜22を介してメモリデ−タレジスタ10に更新して
おく(ステップ56)。
In FIG. 2, when the comparison by the comparator 7 does not match (step 53), the memory data register 10 is prepared for the next memory partial write access.
The contents of the above are also fetched via the selectors 19 to 22 with the write data for which the memory has been written, and updated (step 57). Thus, in the memory write process, the write mode activated by the central processing unit 1 is
Even in the Charle write mode, the main memory 2 can be processed in the full write mode without performing the read modify write. As a result, the memory read processing at the time of executing the partial write, which was indispensable in the past, can be omitted, so that the access time at the time of the partial write to the main memory 2 can be shortened. Thus, even if the activated memory write access is a partial write, when the comparison result of the comparator 7 does not match (step 5).
3) Like the conventional partial write access processing, first, the contents of all words of the main memory 2 are stored in the memory.
The data is fetched into the memory data register 10 by performing the read processing (step 57), and the comparison result of the comparator 7 does not match. Therefore, the contents of the partial address dedicated register 5 are also updated via the dedicated address update bus 28. The contents of the memory write activation address of this time are updated (step 58). Thereafter, the contents of the memory data register 10 and the contents of the memory write register 4 in which the memory write data received from the central processing unit 1 are latched are
Marging is performed by the selectors 15 to 18 (step 5
4) Based on the result of the merge, an ECC code is generated using the ECC generation circuit 12 (step 55), memory write processing is performed, and at the same time the written data is selected by the selector 1
The memory data register 10 is updated via 9 to 22 (step 56).

【0009】一方、中央処理装置1から起動されたメモ
リライト処理のモ−ドがパ−シャルライトではなく、フ
ルライトであった場合には(ステップ52)、パ−シャ
ルライトのモ−ドと同じように、先ず比較器7により今
回のメモリライトアクセスで受け取ったアドレスがラッ
チされているアドレスレジスタ6の内容と、パ−シャル
ライト専用アドレスレジスタ5の内容とを比較する(ス
テップ59)。比較器7の比較結果が一致している場合
には、パ−シャルライト専用アドレスレジスタ5の内容
をアドレ更新専用バス28を介してアドレスレジスタ6
の内容に更新する(ステップ60)。その後、中央処理
装置1から受け取ったメモリライトデ−タがラッチされ
ているメモリライトレジスタ4の内容を、セレクタ15
〜18をスル−させて、ECC生成回路12を用いてE
CCコ−ドを生成し(ステップ55)、メモリフルライ
トを実行し、同時にメモリライトデ−タをセレクタ19
〜22を介してメモリデ−タレジスタ10の更新を行う
(ステップ56)。同じようにして、メモリライト処理
のモ−ドがパ−シャルライトではなく(ステップ5
2)、かつ比較器7の比較結果が不一致であった場合に
は(ステップ59)、パ−シャルライト専用アドレスレ
ジスタ5の内容、メモリデ−タレジスタ10の内容とも
に更新することなく、中央処理装置1から受け取ったデ
−タが保持されているメモリライトレジスタ4の内容
を、セレクタ15〜18をスル−させ、ECC生成回路
12を用いてECCコ−ドを生成し(ステップ55)、
メモリフルライトを実行する(ステップ56)。
On the other hand, when the mode of the memory write process started from the central processing unit 1 is not the partial write but the full write (step 52), the partial write mode is set. Similarly, the contents of the address register 6 in which the address received by the memory write access this time is latched by the comparator 7 are compared with the contents of the address register 5 dedicated to the partial write (step 59). If the comparison results of the comparator 7 match, the contents of the address register 5 dedicated to the partial write are transferred to the address register 6 via the bus 28 dedicated to the address update.
(Step 60). Thereafter, the contents of the memory write register 4 in which the memory write data received from the central processing unit 1 are latched are changed to the selector 15
Through 18 and use the ECC generation circuit 12 to E
The CC code is generated (step 55), the memory full write is executed, and at the same time, the memory write data is selected by the selector 19
22 to 22 to update the memory data register 10 (step 56). Similarly, the mode of memory write processing is not partial write (step 5
2) and when the comparison result of the comparator 7 is inconsistent (step 59), the contents of the address register 5 for exclusive use of the partial write and the contents of the memory data register 10 are not updated, and the central processing unit 1 The contents of the memory write register 4 in which the data received from the memory 15 are passed through the selectors 15 to 18, and the ECC code is generated using the ECC generation circuit 12 (step 55).
Memory full write is executed (step 56).

【0010】このように、本実施例においては、中央処
理装置1とECCを備えた主記憶装置2と主記憶制御装
置3で、前回のパ−シャルライトアクセスと同じアドレ
スへのパ−シャルライトアクセスが発生した場合には、
主記憶制御装置3内にパ−シャルライト専用アドレスレ
ジスタ5と、メモリデ−タレジスタ10とを設け、パ−
シャルライトアクセス時に、これらのレジスタにそれぞ
れアドレス、ライトデ−タを格納し、次のパ−シャルラ
イトアドレスがパ−シャルライト専用アドレスレジスタ
5の内容と等しいときには、主記憶装置2からデ−タを
読み出す代れにメモリデ−タレジスタ10よりデ−タを
読み出すので、アクセス時間を短縮することができる。
As described above, in this embodiment, the central processing unit 1 and the main memory 2 having the ECC and the main memory control unit 3 are used for the partial write to the same address as the previous partial write access. If access occurs,
An address register 5 dedicated to partial write and a memory data register 10 are provided in the main memory controller 3,
Addresses and write data are stored in these registers at the time of a charal write access, and when the next partial write address is equal to the content of the partial write dedicated address register 5, the data is read from the main memory device 2. Since the data is read from the memory data register 10 instead of being read, the access time can be shortened.

【0011】[0011]

【発明の効果】以上説明したように、本発明によれば、
パ−シャルライト動作の最適化および高速化制御が可能
となる。すなわち、主記憶制御装置内に、パ−シャラル
ライト専用アドレスレジスタとアドレスを随時比較する
比較器を設けることにより、パ−シャルライトを行う前
にライトすべきアドレスに対する全ワ−ドデ−タを主記
憶装置内に一旦取り込む動作が必要であるか否かを判定
するので、パ−シャルライト時のメモリアクセスの最適
化および高速化が可能となる。
As described above, according to the present invention,
It is possible to optimize the partial write operation and control the speedup. That is, the main memory controller is provided with a special address register for partial write and a comparator for comparing the addresses at any time, so that all word data for the addresses to be written before the partial write is performed. Since it is determined whether or not it is necessary to temporarily take the data into the main storage device, it is possible to optimize and speed up the memory access during the partial write.

【0012】[0012]

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

【図1】本発明の一実施例を示す主記憶制御装置のブロ
ック図である。
FIG. 1 is a block diagram of a main memory control device showing an embodiment of the present invention.

【図2】図1におけるパ−シャルライト動作のフロ−チ
ャ−トである。
FIG. 2 is a flowchart of the partial write operation in FIG.

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

1 中央処理装置 2 主記憶装置 3 主記憶制御装置 4 メモリライトレジスタ 5 パ−シャルライト専用アドレスレジスタ 6 アドレスレジスタ 7 比較器 8 フラグ 9 ANDゲ−ト 10 メモリデ−タレジスタ 11 タイミング制御回路 12 ECCチェック回路 13 ECC生成回路 14 双方向ドライバ 15〜22 セレクタ 23 バイトイネ−ブル 24 デ−タバス 25 アドレスバス 26 メモリリ−ドデ−タバス 27 メモリライトデ−タバス 28 アドレス更新専用バス 1 central processing unit 2 main memory unit 3 main memory control unit 4 memory write register 5 partial write dedicated address register 6 address register 7 comparator 8 flag 9 AND gate 10 memory data register 11 timing control circuit 12 ECC check circuit 13 ECC generation circuit 14 Bidirectional driver 15 to 22 selector 23 Byte enable 24 Data bus 25 Address bus 26 Memory read data bus 27 Memory write data bus 28 Address update dedicated bus

───────────────────────────────────────────────────── フロントページの続き (72)発明者 山本 昌明 大阪府大阪市北区長柄西一丁目7番31号 株式会社日立西サービスエンジニアリング 内 ─────────────────────────────────────────────────── ─── Continuation of the front page (72) Inventor Masaaki Yamamoto 1-31-31 Nagara Nishi, Kita-ku, Osaka City, Osaka Prefecture Hitachi Nishi Service Engineering Co., Ltd.

Claims (4)

【特許請求の範囲】[Claims] 【請求項1】 中央処理装置あるいはこれと同等の機能
を有する処理装置と、ECCを具備した主記憶装置と、
該主記憶装置を制御する主記憶制御装置を有する処理シ
ステムにおいて、上記主記憶制御装置内に、上記主記憶
装置から前回に読み出した全ワ−ドデ−タを格納し、次
回のパ−シャルライトアクセスが前回と同じアドレスの
場合に、該主記憶装置から読み出す代りにこの内容が読
み出される1ないし複数本のメモリデ−タレジスタと、
主記憶装置へ前回アクセスされたパ−シャルライトアド
レスの全ワ−ドに対応するアドレスを格納するパ−シャ
ルライト専用アドレスレジスタと、該パ−シャルライト
専用アドレスレジスタと上記中央処理装置あるいは他の
処理装置からのパ−シャルライトアドレスを比較して、
一致した場合には、上記メモリデ−タレジスタの上記パ
−シャルライトアドレスに対応した部分を上記中央処理
装置あるいは他の処理装置から出力されたライトデ−タ
とマ−ジして、マ−ジしたデ−タを上記主記憶装置に書
き込むための比較手段とを具備することを特徴とする主
記憶制御装置。
1. A central processing unit or a processing unit having a function equivalent to the central processing unit, and a main storage unit having an ECC,
In a processing system having a main memory control device for controlling the main memory device, all word data previously read from the main memory device is stored in the main memory control device, and the next partial is stored. One or more memory data registers whose contents are read instead of being read from the main memory when the write access is at the same address as before;
A partial address for exclusive use of a partial write for storing an address corresponding to all the words of the partial write address previously accessed to the main memory, the partial register for exclusive use of the partial write and the above central processing unit or other Compare the partial write address from the processor,
If they match, the portion of the memory data register corresponding to the partial write address is merged with the write data output from the central processing unit or another processing unit, and the merged data is merged. A main memory control device, comprising: a comparison unit for writing the data into the main memory device.
【請求項2】 主記憶装置に部分書き込みを実行する場
合に、該主記憶装置からパ−シャルライトアドレスに対
応する全ワ−ドデ−タを読み出し、読み出されたデ−タ
を部分変更し、部分変更されたデ−タに対するECCコ
−ドの生成を行った後、変更されたデ−タと生成された
ECCコ−ドを書き込む主記憶制御方法において、前回
アクセスされたパ−シャルライトアドレスが格納された
アドレスレジスタと、今回アクセスされたパ−シャルラ
イトアドレスとを比較し、比較結果が一致した場合に
は、前回読み出された全ワ−ドデ−タが格納されている
メモリデ−タレジスタの上記パ−シャルライトアドレス
に対応した部分を、今回アクセスされるメモリライトデ
−タに書き換え、上記主記憶装置に書き換えたメモリラ
イトレジスタのデ−タおよび該メモリライトレジスタの
デ−タより生成されたECCコ−ドを上記メモリデ−タ
レジスタに格納し、また比較結果が不一致の場合には、
上記主記憶装置からパ−シャルライトアドレスに対応し
た全リ−ドデ−タを読み出し、読み出されたデ−タを上
記メモリデ−タレジスタに格納し、格納されたデ−タの
上記パ−シャルライトアドレスに対応する部分を上記メ
モリライトレジスタに置き換え、置き換えたメモリライ
トデ−タおよび該メモリライトデ−タより生成されたE
CCコ−ドを上記主記憶装置および上記メモリデ−タレ
ジスタに同時に格納することを特徴とする主記憶制御方
法。
2. When partial writing is executed in the main memory, all word data corresponding to the partial write address is read from the main memory and the read data is partially changed. In the main memory control method of writing the changed data and the generated ECC code after the ECC code is generated for the partially changed data, the previously accessed partial is used. The address register storing the write address is compared with the partial write address accessed this time. If the comparison result is the same, all the word data read out previously are stored. The data corresponding to the above partial write address of the memory data register is rewritten into the memory write data to be accessed this time, and the data of the memory write register is rewritten into the above main memory device. And an ECC code generated from the data of the memory write register is stored in the memory data register, and when the comparison result is inconsistent,
All read data corresponding to the partial write address is read from the main memory, the read data is stored in the memory data register, and the partial of the stored data is stored. The portion corresponding to the write address is replaced with the memory write register, the replaced memory write data and the E generated from the memory write data.
A main memory control method characterized in that a CC code is stored in the main memory device and the memory data register at the same time.
【請求項3】 請求項2に記載の主記憶制御方法におい
て、上記前回アクセスされたパ−シャルライトアドレス
が格納されたアドレスレジスタには、上記メモリライト
レジスタに格納されるデ−タの有効性を判断するための
フラグを設け、システムパワ−オン時および障害発生時
には上記フラグを無効と設定し、上記アドレスレジスタ
でパ−シャルライトアドレスが正常に更新された時には
有効と設定し、該フラグが無効の場合には、前回アクセ
スされたパ−シャルライトアドレスが格納されたアドレ
スレジスタと、今回アクセスされたパ−シャルライトア
ドレスとを比較した場合の比較結果を強制的に不一致と
することを特徴とする主記憶制御方法。
3. The main memory control method according to claim 2, wherein the address register storing the previously accessed partial write address stores the validity of the data stored in the memory write register. A flag for determining whether the flag is set, the flag is set to be invalid when the system is powered on and a failure occurs, and is set to be valid when the partial write address is normally updated in the address register. If it is invalid, the comparison result of comparing the address register that stores the previously accessed partial write address with the currently accessed partial write address is forcibly set as a mismatch. Main memory control method.
【請求項4】 請求項2に記載の主記憶制御方法におい
て、上記中央処理装置あるいは他の処理装置からフルラ
イト起動があった場合、該起動時のライトアドレスと前
回アクセスされたパ−シャルライトアドレスが格納され
たアドレスレジスタの内容とを比較し、比較結果が一致
の場合には、上記アドレスレジスタの内容を上記ライト
アドレスの内容に更新することを特徴とする主記憶制御
方法。
4. The main memory control method according to claim 2, wherein when a full write is activated from the central processing unit or another processing unit, the write address at the time of activation and the partial write accessed last time. A main memory control method comprising: comparing the contents of an address register in which an address is stored, and updating the contents of the address register to the contents of the write address if the comparison result is a match.
JP26842392A 1992-10-07 1992-10-07 Method and device for controlling main storage Pending JPH06119238A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP26842392A JPH06119238A (en) 1992-10-07 1992-10-07 Method and device for controlling main storage

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP26842392A JPH06119238A (en) 1992-10-07 1992-10-07 Method and device for controlling main storage

Publications (1)

Publication Number Publication Date
JPH06119238A true JPH06119238A (en) 1994-04-28

Family

ID=17458284

Family Applications (1)

Application Number Title Priority Date Filing Date
JP26842392A Pending JPH06119238A (en) 1992-10-07 1992-10-07 Method and device for controlling main storage

Country Status (1)

Country Link
JP (1) JPH06119238A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002373349A (en) * 2001-06-15 2002-12-26 Sony Corp Image memory controller, graphic arithmetic unit and rendering processing method
JPWO2008155850A1 (en) * 2007-06-20 2010-08-26 富士通株式会社 Cache control device, cache control method, and cache control program
WO2012098655A1 (en) 2011-01-19 2012-07-26 富士通株式会社 Data writing control device, data writing control method, and information processing device

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002373349A (en) * 2001-06-15 2002-12-26 Sony Corp Image memory controller, graphic arithmetic unit and rendering processing method
JP4622165B2 (en) * 2001-06-15 2011-02-02 ソニー株式会社 Image memory control device, graphic operation device, and rendering processing method
JPWO2008155850A1 (en) * 2007-06-20 2010-08-26 富士通株式会社 Cache control device, cache control method, and cache control program
JP4764945B2 (en) * 2007-06-20 2011-09-07 富士通株式会社 Cache control device, cache control method, and cache control program
US8533565B2 (en) 2007-06-20 2013-09-10 Fujitsu Limited Cache controller and cache controlling method
WO2012098655A1 (en) 2011-01-19 2012-07-26 富士通株式会社 Data writing control device, data writing control method, and information processing device
JP5569598B2 (en) * 2011-01-19 2014-08-13 富士通株式会社 Data write control device, data write control method, and information processing device

Similar Documents

Publication Publication Date Title
US4648033A (en) Look-aside buffer LRU marker controller
JP2570859B2 (en) Data processing device
JPH06119238A (en) Method and device for controlling main storage
JPH0548497B2 (en)
US5233700A (en) Address translation device with an address translation buffer loaded with presence bits
JPS5991551A (en) Instruction prefetching device forecasting address to be branched
JPS6232508B2 (en)
JP3132566B2 (en) Instruction precedence controller
JP2894438B2 (en) Pipeline processing equipment
JP2540959B2 (en) Information processing device
JP2953451B2 (en) Interrupt handling method
JPH04245334A (en) Instruction prereading control system for information processor
JP2762798B2 (en) Information processing apparatus of pipeline configuration having instruction cache
JPH01255933A (en) Sweeping-out control system
JPH1185613A (en) Cache memory
JP2864548B2 (en) Instruction cache device
JPH08161226A (en) Data look-ahead control method, cache controller and data processor
JP2762797B2 (en) Information processing apparatus of pipeline configuration having instruction cache
JPH04104345A (en) Write control system for partial rewrite data of main storage device with ecc mechanism
JP2902847B2 (en) Self-modifying code execution method
JPH10254782A (en) Data processor
JP2000267885A (en) Breakpoint setting method and computer readable recording medium recording program for setting breakpoint
JPH03225529A (en) Microprocessor
JPH09305476A (en) Data processor
JP2002007154A (en) Information processor