JPH0373040A - Cache memory - Google Patents

Cache memory

Info

Publication number
JPH0373040A
JPH0373040A JP1210336A JP21033689A JPH0373040A JP H0373040 A JPH0373040 A JP H0373040A JP 1210336 A JP1210336 A JP 1210336A JP 21033689 A JP21033689 A JP 21033689A JP H0373040 A JPH0373040 A JP H0373040A
Authority
JP
Japan
Prior art keywords
write
byte
buffer
data
write data
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
JP1210336A
Other languages
Japanese (ja)
Inventor
Katsunori Uchida
内田 克典
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
NEC 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 NEC Corp filed Critical NEC Corp
Priority to JP1210336A priority Critical patent/JPH0373040A/en
Publication of JPH0373040A publication Critical patent/JPH0373040A/en
Pending legal-status Critical Current

Links

Landscapes

  • Memory System Of A Hierarchy Structure (AREA)

Abstract

PURPOSE:To improve efficiency for using a system bus by controlling a write data buffer with n-byte width in a cachememory for each byte and writing the data of n-bytes to a main memory by using the system bus after the data are stored to the write data buffer. CONSTITUTION:At the time of a read access or when a word address is changed, a write buffer control circuit 40 starts a bus request to the main memory and when there is a response from a bus controller, the data of a write data buffer 50 are written into a main storage device 10. The write data buffer 50 is equipped with latch control for each byte and the data of the byte, to which the output of a decoder 3 is inputted, are latched. When the output of the write buffer control circuit 40 is active, an address driver 8 and a data driver 9 output the contents of a write address buffer 7 and the write data buffer 50 through a system bus 801 to the main storage device 10. Thus, the efficiency for using the system bus can be improved.

Description

【発明の詳細な説明】 〔産業上の利用分野〕 本発明は情報処理装置のキャッシュメモリに関し、特に
ライトスルー方式のキヤ・ンシュメモリにおけるライト
バッファの制御に関する。
DETAILED DESCRIPTION OF THE INVENTION [Field of Industrial Application] The present invention relates to a cache memory for an information processing device, and more particularly to write buffer control in a write-through type cache memory.

〔従来の技術〕[Conventional technology]

第4図を参照すると、従来のnバイトのデータ幅のライ
トバッファ5を持つライトスルー方式のキャッシュメモ
リ2は、プロセッサ1からのライト制御信号102から
つくられたラッチ信号41によりnバイ1分のデータ1
04が一度にライトデータバッファ5にラッチされ、そ
の後ライトデータバッファ5のデータをライトアドレス
バッファ7にストアされたワードアドレス101と共に
ドライバ9.8を介してシステムバス801を使って主
記憶10へ書き込んでいた。
Referring to FIG. 4, a write-through type cache memory 2 having a conventional write buffer 5 with a data width of n bytes is operated by a latch signal 41 generated from a write control signal 102 from the processor 1. data 1
04 is latched into the write data buffer 5 at a time, and then the data in the write data buffer 5 is written to the main memory 10 using the system bus 801 via the driver 9.8 along with the word address 101 stored in the write address buffer 7. It was.

〔発明が解決しようとする課題〕[Problem to be solved by the invention]

上述した従来のキャッシュメモリではプロセッサ1から
の1回のライトアクセスごとに主記憶装置10に書き込
みに行くので、ストリング処理の場合のように順番に連
続したアドレスのパイトライトアクセスが連続する場合
でも、1ノベイトデータコトニライトバツフア5にラッ
チされ、その都度nバイト幅のシステムバス801を使
って主記+!10に書き込まれるためシステムバス80
1の使用効率が悪いという欠点があった。
In the above-mentioned conventional cache memory, data is written to the main storage device 10 for each write access from the processor 1, so even when there are successive write accesses to successive addresses as in the case of string processing, 1 novate data is latched into the write buffer 5, and the system bus 801 with a width of n bytes is used each time to write the main message +! 10 to system bus 80
The disadvantage was that the usage efficiency of 1 was poor.

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

本発明のキャッシュメモリは、1バイトごとにラッチ制
御を持つnバイト幅のライトデータバッファと、プロセ
ッサ側からのバイト制御信号からライトデータバッファ
の各バイトへのラッチ信号をつくる手段(たとえばデコ
ーダ)と、バイトライトアクセスの場合に直ちに主記憶
装置へ書き込むのではなくプロセッサの次のアクセスが
リードアクセスまたは異なるワード(nバイトアドレス
)へのライトアクセスであることを検知してその時にラ
イトデータバッファのライトデータを主記憶装置へ書き
込みに行くライトバッファ制御回路とを有することを特
徴とする。
The cache memory of the present invention includes an n-byte wide write data buffer that has latch control for each byte, and means (for example, a decoder) for generating a latch signal for each byte of the write data buffer from a byte control signal from the processor side. , in the case of a byte write access, instead of writing to the main memory immediately, the processor detects that the next access is a read access or a write access to a different word (n byte address) and writes the write data buffer at that time. It is characterized by having a write buffer control circuit that writes data to the main memory.

なお、nバイトアドレスのライトアドレスバッファをも
備え、そこに格納されたライトアドレスをライトデータ
と共にシステムバスへ送り出す制御も同時に行わせるの
が好ましい。
Note that it is preferable that a write address buffer with n-byte addresses is also provided, and that the write address stored therein is also controlled to be sent to the system bus together with the write data.

本発明のキャッシュメモリではnバイト幅のライトデー
タバッファへのデータの格納を1バイトごとに制御し、
順番に連続したアドレスのバイトアクセスが連続した場
合はnバイトのデータが格納されてライトバッファがフ
ルになるまではライトデータバッファからシステムバス
を用いての主記憶への書き込みを行なわないことによっ
て、システムバスの使用効率を従来のn倍に高めること
ができる。
In the cache memory of the present invention, data storage in the n-byte wide write data buffer is controlled for each byte,
When byte accesses of consecutive addresses occur in sequence, writing from the write data buffer to the main memory using the system bus is not performed until n bytes of data are stored and the write buffer is full. System bus usage efficiency can be increased n times compared to the conventional system.

〔実施例〕〔Example〕

次に本発明について図面を参照して説明する。 Next, the present invention will be explained with reference to the drawings.

第1図は本発明の一実施例を示し、本発明に係る部分の
みを示している。本実施例では32ビツト(4バイト)
のデータ幅を持ったシステムについて説明する。
FIG. 1 shows an embodiment of the present invention, showing only the parts related to the present invention. In this example, 32 bits (4 bytes)
We will explain a system with a data width of .

第1図において、プロセッサ1はワードアドレス信号1
01.リードライト制御信号102.バイトアドレス信
号103.32ビツトのライトデータ信号104を出力
する。キャッシュメモリ2はライトビット時にキャッシ
ュメモリ内をライトデータで更新する。本発明によるデ
コーダ3はバイトアドレス103によって示されるバイ
ト位置を示し該当するバイト制御信号301,302゜
303.304を出力する。ライトバッファ制御回路4
0はリード/ライト制御信号102.アドレス遷移検出
回路6の出力601を入力し、リードアクセスの場合ま
たはワードアドレス〈4バイト)が変化した場合に主記
憶へのバスリクエストを開如し、バスコントローラから
の応答があればドライバ制御信号401を出力し、ライ
トデータバッファ50のデータを主記憶装置 10に書
き込む、ライトデータバッファ50は■バイトごとにラ
ッチ制御を持ちデコーダ3の出力301゜302.30
3,304が入力されたバイトのデータをラッチする。
In FIG. 1, a processor 1 has a word address signal 1
01. Read/write control signal 102. A byte address signal 103 and a 32-bit write data signal 104 are output. The cache memory 2 updates the cache memory with write data at the time of write bit. The decoder 3 according to the present invention indicates the byte position indicated by the byte address 103 and outputs corresponding byte control signals 301, 302, 303, and 304. Write buffer control circuit 4
0 is the read/write control signal 102. The output 601 of the address transition detection circuit 6 is input, and in the case of read access or when the word address (4 bytes) changes, a bus request to the main memory is opened, and if there is a response from the bus controller, a driver control signal is sent. 401 and writes the data in the write data buffer 50 to the main memory 10. The write data buffer 50 has latch control for each byte and the output of the decoder 3 is 301°302.30.
3, 304 latches the input byte data.

アドレス遷移検出回路6はワードアドレス(4バイト)
101の変化を検出し、検出信号601をライトバッフ
ァ制御回路40へ出力する。ライトアドレスバッファ7
はライトアドレス101を格納する。アドレスドライバ
8、データドライバ9はライトバッファ制御回路40の
出力401がアクティブな場合にライトアドレスバッフ
ァ7およびライトデータバッファ50の内容をシステム
バス801を通して主記憶10へ出力する0次に第2図
のタイミングチャートを参照して説明する。プロセッサ
のサイクルはITでメモリサイクルとする。この例では
T1からT4の間はワードアドレス101は変化せずバ
イト制御によりバイトライトアクセスが行なわれている
とする。この場合、ライトデータ104のうちT1サイ
クルではDo〜D7の8ビツトのデータAが、T2サイ
クルではD8〜D15の8ビツトデータBが、T3サイ
クルではD16〜D23の8ビツトデータCが、T4サ
イクルではD24〜D31の8ビツトデータDがそれぞ
れ有効なデータとする。これらのデータA〜Dはデコー
ダ3からのバイト制御信号301〜304によってそれ
ぞれライトデータバッファ5oの各バイトに書き込まれ
る。すなわちバイト制御信号がアクティグになっている
バイトのみ書き込まれる。またライト・データバッファ
50の各バイトの出力データ501,502,503,
504も書き込みに応じて図示のように変化する。プロ
セッササイクルT5でワードアドレス101が変化して
いるのでアドレス遷移検出回路6の出力信号601がア
クティブになり、ライトバッファ制御回路40の出力4
01によりライトバッファの内容すなわちA、B、C,
Dの4バイトのデータ(Do〜D3□)がシステムバス
801に出力される。
Address transition detection circuit 6 is a word address (4 bytes)
101 is detected, and a detection signal 601 is output to the write buffer control circuit 40. Write address buffer 7
stores the write address 101. Address driver 8 and data driver 9 output the contents of write address buffer 7 and write data buffer 50 to main memory 10 through system bus 801 when output 401 of write buffer control circuit 40 is active. This will be explained with reference to a timing chart. A processor cycle is a memory cycle in IT. In this example, it is assumed that the word address 101 does not change between T1 and T4, and byte write access is performed under byte control. In this case, of the write data 104, 8-bit data A of Do to D7 is written in the T1 cycle, 8-bit data B of D8 to D15 is written in the T2 cycle, 8-bit data C of D16 to D23 is written in the T3 cycle, and 8-bit data C of D16 to D23 is written in the T4 cycle. Here, it is assumed that the 8-bit data D of D24 to D31 are each valid data. These data A to D are written into each byte of the write data buffer 5o by byte control signals 301 to 304 from the decoder 3, respectively. That is, only bytes whose byte control signal is active are written. Also, the output data 501, 502, 503 of each byte of the write data buffer 50,
504 also changes as shown in the figure in response to writing. Since the word address 101 changes in processor cycle T5, the output signal 601 of the address transition detection circuit 6 becomes active, and the output signal 601 of the write buffer control circuit 40 becomes active.
By 01, the contents of the write buffer, ie A, B, C,
The 4-byte data of D (Do to D3□) is output to the system bus 801.

第3図は本発明の第2の実施例のブロック図である。こ
の実施例はライトアドレスバッファ、ライトデータバッ
ファをそれぞれ2段(7および12.50および11〉
有する例である。この例では前段のライトデータバッフ
ァ50がフル、またはリードアクセスまたはワードが異
なるバイトライトアクセスの場合、ライトバッファ制御
回路40の出力信号402により前段のライトデータバ
ッファ50の内容が後段のライトデータバッファ11ヘ
ラツチされる。次にライトデータバッファ50がフルま
たはリードアクセスまたはワードが異なるバイトライト
アクセスがあった場合に後段のライトデータバッファ1
1の内容11○1がシステムバス801に出力されて主
記憶10に書き込まれる。
FIG. 3 is a block diagram of a second embodiment of the invention. This embodiment has two stages of write address buffers and write data buffers (7 and 12, 50 and 11).
This is an example of having In this example, when the preceding write data buffer 50 is full, or in the case of read access or byte write access with different words, the output signal 402 of the write buffer control circuit 40 transfers the contents of the preceding write data buffer 50 to the subsequent write data buffer 11. It's hard to do. Next, when the write data buffer 50 is full or there is a read access or a byte write access with a different word, the write data buffer 1 of the subsequent stage
The contents 11○1 of 1 are output to the system bus 801 and written to the main memory 10.

〔発明の効果〕〔Effect of the invention〕

以上説明したように、本発明はキャッシュメモリのnバ
イト幅のライトデータバッファを1バイトごとに制御し
、ライトデータバッファにnバイトのデータが格納され
た後にシステムバスを使って主記憶への書き込みを行な
うようにすることにより、ストリング処理のようなバイ
トライトアクセスが連続する場合にもnバイト幅のシス
テムバスを1バイトごとのアクセスに比べn倍効率良く
使える効果がある。
As explained above, the present invention controls the n-byte wide write data buffer of the cache memory byte by byte, and after n-byte data is stored in the write data buffer, the write data is written to the main memory using the system bus. By performing this, even when byte write accesses such as string processing are continuous, the system bus having an n-byte width can be used n times more efficiently than when accessing each byte at a time.

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

第1図は本発明の第1の実施例の要部ブロック図、第2
図は第1図の実施例のタイミングチャート、第3図は第
2の実施例2の要部プロ1.り図、第4図は従来例のブ
ロック図である。 111.プロセッサ、2・・・キャッシュメモリ、3・
・・デコーダ、4.40・・・ライトバッファ制御回路
、5.50.11・・・ライトデータバッファ、6・・
・アドレス遷移検出回路、7.12・・・ライトアドレ
スバッファ、8・・・アドレスドライバ、9・・・デー
タドライバ、10・・・主記憶、101・・・ワードア
ドレス信号、102・・・リード/ライト制御信号、1
03・・・バイトアドレス信号、104・・・ライトデ
ータ信号、301,302,303,304・・・バイ
ト制御信号、401・・・ドライバイネーブル信号、5
01.502,503,504・・・ライトデータバッ
ファ5出力信号、601・・・アドレス遷移検出回路出
力信号、801・・・システムバス、1101・・・ラ
イトデータバッファ11の出力信号。 第4循
FIG. 1 is a block diagram of main parts of the first embodiment of the present invention, and FIG.
The figure shows a timing chart of the embodiment shown in FIG. 1, and FIG. FIG. 4 is a block diagram of a conventional example. 111. Processor, 2... Cache memory, 3.
...Decoder, 4.40...Write buffer control circuit, 5.50.11...Write data buffer, 6...
・Address transition detection circuit, 7.12... Write address buffer, 8... Address driver, 9... Data driver, 10... Main memory, 101... Word address signal, 102... Read /light control signal, 1
03... Byte address signal, 104... Write data signal, 301, 302, 303, 304... Byte control signal, 401... Driver enable signal, 5
01.502, 503, 504...Write data buffer 5 output signal, 601...Address transition detection circuit output signal, 801...System bus, 1101...Write data buffer 11 output signal. 4th cycle

Claims (1)

【特許請求の範囲】[Claims] nバイトのデータ幅を持つライトスルー方式のキャッシ
ュメモリにおいて、1バイトごとのラッチ制御が可能な
nバイト幅のライトデータバッファと、プロセッサ側か
らのバイト制御信号を受けて前記ライトデータバッフア
へのラッチ信号をつくる手段と、プロセッサの次のアク
セスがnバイト幅の異なるワードのアドレスへのライト
アクセスであることを少くとも検知して既に前記ライト
データバッファへ格納済みのライトデータを主記憶装置
へ書き込む制御をするライトバッファ制御回路とを有す
ることを特徴とするキャッシュメモリ。
A write-through type cache memory with a data width of n bytes includes an n-byte wide write data buffer that can latch control each byte, and a write data buffer that receives a byte control signal from the processor side to write to the write data buffer. means for generating a latch signal, and at least detecting that the next access by the processor is a write access to an address of a word different in n-byte width, and transferring the write data already stored in the write data buffer to the main memory. A cache memory comprising a write buffer control circuit that controls writing.
JP1210336A 1989-08-14 1989-08-14 Cache memory Pending JPH0373040A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP1210336A JPH0373040A (en) 1989-08-14 1989-08-14 Cache memory

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP1210336A JPH0373040A (en) 1989-08-14 1989-08-14 Cache memory

Publications (1)

Publication Number Publication Date
JPH0373040A true JPH0373040A (en) 1991-03-28

Family

ID=16587725

Family Applications (1)

Application Number Title Priority Date Filing Date
JP1210336A Pending JPH0373040A (en) 1989-08-14 1989-08-14 Cache memory

Country Status (1)

Country Link
JP (1) JPH0373040A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1071018A2 (en) * 1993-04-30 2001-01-24 Packard Bell NEC, Inc. Symmetric multiprocessing system with unified environment and distributed system functions
KR100455838B1 (en) * 2002-04-16 2004-11-10 송영철 Carrying belt on the shoulder of bag for active load dispersion
JP2013536526A (en) * 2010-08-20 2013-09-19 アップル インコーポレイテッド Combined write buffer with dynamically adjustable flash index

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1071018A2 (en) * 1993-04-30 2001-01-24 Packard Bell NEC, Inc. Symmetric multiprocessing system with unified environment and distributed system functions
EP1071018A3 (en) * 1993-04-30 2001-02-07 Packard Bell NEC, Inc. Symmetric multiprocessing system with unified environment and distributed system functions
KR100455838B1 (en) * 2002-04-16 2004-11-10 송영철 Carrying belt on the shoulder of bag for active load dispersion
JP2013536526A (en) * 2010-08-20 2013-09-19 アップル インコーポレイテッド Combined write buffer with dynamically adjustable flash index

Similar Documents

Publication Publication Date Title
JPH0248747A (en) Microprocessor
JPS6365953B2 (en)
JPH0373040A (en) Cache memory
JP3132566B2 (en) Instruction precedence controller
JPS6029860A (en) Updating method of data
JPS60103454A (en) Instruction pre-reading controller
JPH03231345A (en) Cache device
JPH10187119A (en) Display control device
JP3299147B2 (en) Cache control circuit
JPS62274349A (en) Data processing system
JPS61237145A (en) Controlling system for store buffer
JPH07152650A (en) Cache control unit
JP2604604B2 (en) Stack control device
JPH06266612A (en) Dma controller
JPS63115251A (en) Disk cache controller
JPS6135583B2 (en)
JPH04112251A (en) Microcomputer
JPH0363850A (en) Store system
JPH0219898A (en) Image decoding and displaying device
JPH02195456A (en) Cache storage system
JPH10105457A (en) Memory control system and memory control circuitt
JPS6385949A (en) Cache memory storing system
JPH08166905A (en) Cache memory control method
JPH04102143A (en) Compare and swap control system
JPS60196858A (en) Input processor of data with label