JPH0354372B2 - - Google Patents

Info

Publication number
JPH0354372B2
JPH0354372B2 JP50319282A JP50319282A JPH0354372B2 JP H0354372 B2 JPH0354372 B2 JP H0354372B2 JP 50319282 A JP50319282 A JP 50319282A JP 50319282 A JP50319282 A JP 50319282A JP H0354372 B2 JPH0354372 B2 JP H0354372B2
Authority
JP
Japan
Prior art keywords
word
memory
data
cache
address
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
Application number
JP50319282A
Other languages
Japanese (ja)
Other versions
JPS58501645A (en
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 filed Critical
Priority claimed from PCT/US1982/001294 external-priority patent/WO1983001323A1/en
Publication of JPS58501645A publication Critical patent/JPS58501645A/en
Publication of JPH0354372B2 publication Critical patent/JPH0354372B2/ja
Granted legal-status Critical Current

Links

Landscapes

  • Memory System Of A Hierarchy Structure (AREA)

Description

請求の範囲 1 データ処理システムの記憶能力を増強する装
置であつて、該システムは: メイン・メモリ102と; キヤツシユ・メモリ・システム100と; 該キヤツシユ・メモリ・システムおよびメイ
ン・メモリをアドレス指定する手段101とを含
み; 前記キヤツシユ・メモリ・システム100は: 各々がメイン・メモリ102中にも重複して存
在するワード・グループを含む複数個のキヤツシ
ユ・メモリ107−109と; メイン・メモリ中に記憶された第1のワードが
キヤツシユ・メモリの1つにもまた記憶されてい
るか否かを決定する手段104−106と; 第1のワードがキヤツシユ・メモリの1つに記
憶されていないという前記決定手段104−10
6からの指示に応動して第1のワードの第1のキ
ヤツシユ・メモリへの記憶を行わせる制御回路1
03とを含み; 該第1のメモリは第1のワードの受信に応動し
て最も以前に使用された先に記憶されているワー
ドを第2のキヤツシユ・メモリに転送することを
特徴とするデータ処理システムの記憶能力を増強
する装置。 2 データ処理システムの記憶能力を増強する方
法であつて、該システムは: メイン・メモリ102と; キヤツシユ・メモリ・システム100と; キヤツシユ・メモリ・システムおよびメイン・
メモリへのアドレス指定を行う手段101とを含
み; 該方法は: キヤツシユ・メモリ・システム100中に記憶
されたワードを使用された相対時刻に従つて順序
づけ、メイン・メモリ中に記憶されたワードがま
たキヤツシユ・メモリ・システム100を形成す
るキヤツシユ・メモリ107−109の1つに記
憶されているかどうか決定し、 該ワードを第1のキヤツシユ・メモリ中に記憶
させ、 最も以前に使用された先に記憶されているワー
ドの第1のメモリから第2のキヤツシユ・メモリ
への転送を行わせる階程より成ることを特徴とす
るデータ処理システムの記憶能力を増強する方
法。 3 データ処理システムにおいて、該システム
は: メイン・メモリ・アドレス信号を発生するプロ
セツサ手段と; メイン・メモリ・ワードを記憶する複数個のメ
モリ・ロケーシヨンを有するメイン・メモリと; キヤツシユ制御手段と; 各々メイン・メモリ・アドレスおよび相応する
キヤツシユ・データ・ワードを記憶する複数個の
メモリ・ロケーシヨンを有し、その中に記憶され
たすべてのメイン・メモリ・アドレスと不整合な
メイン・メモリ・アドレス信号に応動してキヤツ
シユ制御手段に不整合信号を発生して伝送する第
1および第2のキヤツシユ・メモリを含み; キヤツシユ制御手段は第1および第2のキヤツ
シユ・メモリにより不整合信号が同時に発生され
ることに応動して第1の制御信号をメイン・メモ
リおよび第1ならびに第2のキヤツシユ・メモリ
に対し発生して伝送し; メイン・メモリは前記第1の制御信号および不
整合であつたメイン・メモリ・アドレス信号に応
動してメイン・メモリ・ワードを第1のキヤツシ
ユ・メモリに伝送し; 第1のキヤツシユ・メモリは第1の制御信号に
応動して最も以前に使用されたキヤツシユ・デー
タ・ワードおよびこれと相応する記憶されたメイ
ン・メモリ・アドレスを第2のキヤツシユ・メモ
リに伝送し、伝送されたメイン・メモリ・ワード
およびメイン・メモリ・アドレス信号を記憶し; 第2のキヤツシユ・メモリは第1の制御信号に
応動して伝送されたキヤツシユ・データ・ワード
およびこれと相応するメイン・メモリ・アドレス
を記憶することを特徴とするデータ処理システ
ム。 4 請求の範囲第3項記載のデータ処理システム
において、 第2のキヤツシユ・メモリは更にメイン・アド
レスを記憶する複数個のメモリ・ロケーシヨンを
有する整合メモリと、キヤツシユ・データ・ワー
ドを記憶する複数個のメモリ・ロケーシヨンを有
するデータ・メモリより成り; 前記整合メモリは整合したメイン・メモリ・ア
ドレス信号に応動してその内容がデータ・メモリ
に対する整合したメイン・アドレス信号と整合し
たメモリ・ロケーシヨンのキヤツシユ・メモリ・
アドレスを発生して伝送し、不整合となつたメイ
ン・メモリ・アドレス信号に応動して不整合信号
を発生して伝送し、; データ・メモリはキヤツシユ・メモリ・アドレ
スに応動して相応するキヤツシユ・データ・ワー
ドにアクセスして伝送することを特徴とするデー
タ処理システム。 技術分野 本発明は計算機システムに、細目的には新らし
い情報を記憶するロケーシヨンがキヤツシユ・メ
モリ中の最下位プライオリテイを有するワードの
ロケーシヨンであるキヤツシユ・メモリを使用す
るシステムに関する。 発明の背景 最近の計算機システムは単一の大容量メモリが
追従し得ないような高速度の動作が可能なプロセ
ツサを使用している。このため小容量の高速キヤ
ツシユ・メモリがプログラムの実行速度を改善す
るために大容量のメイン・メモリと共に使用され
ているのが普通である。キヤツシユ・メモリは限
定された個数のインストラクシヨンまたはデー
タ・ワードを記憶しており、メモリの読み出し操
作毎にキヤツシユ・メモリ中に情報が存在するか
否かが調べられる。情報が存在する場合にはその
情報はキヤツシユ・メモリから読み出される。も
しキヤツシユ・メモリ中に情報が存在しない場合
にはメイン・メモリから読み出される。情報がメ
イン・メモリから読み出されねばならない場合に
は、新らしい情報はキヤツシユ・メモリ中の既存
の情報と置き換えられねばならない。キヤツシ
ユ・メモリ中の新らしい情報を記憶するのに適し
たロケーシヨンは幾つかの広く使用されている置
き換えアルゴリズム(例えばランダム置き換え、
最も以前に使用されたものと置き換える等)の内
の1つにより定められる。一般に最も以前に使用
されたものと置き換えるアルゴリズムは最も効率
のよいアルゴリズムであると考えられている。し
かしどのロケーシヨンが最も以前に使用されたワ
ードを含んでいるかの決定を、多大の時間を要す
ることなく経済的に引き合う仕方で実現すること
は困難であるとされていた。 発明の要旨 本発明に従うキヤツシユ・メモリ・システムは
データ・ワードのグループを含む幾つかのセクシ
ヨンに分割されている。各セクシヨンはその中に
記憶されたワードが最後に使用された時刻に従つ
て決定される相対的プライオリテイを保持してい
るプライオリテイ回路を有している。キヤツシ
ユ・メモリ中に挿入されねばならないメイン・メ
モリ・ワードを受け取つたときキヤツシユ・メモ
リを更新するのに要求される時間は、該ワードを
1つのセクシヨン中に記憶させると同時に最も低
いプライオリテイ・ワードをより高いプライオリ
テイ・セクシヨンからより低いプライオリテイ・
セクシヨンに移動することにより減少させること
が出来る。 本発明の一実施例では、データ処理システムは
メイン・メモリ・アドレス信号を発生することに
よりデータ・ワードを要求するプロセツサと、メ
イン・メモリとキヤツシユ・メモリ・システムよ
り成つている。キヤツシユ・メモリ・システムは
キヤツシユ制御回路と第1および第2のキヤツシ
ユ・メモリより成る。1つ以上のキヤツシユ・メ
モリを有するキヤツシユ・メモリ・システムは現
場でシステムを拡張することを許容する。また
各々のキヤツシユ・メモリは一つのLSI回路とし
て実現することが可能である。各キヤツシユ・メ
モリはキヤツシユ・データ・ワード(これはメイ
ン・メモリ中に記憶されたワードの複製である)
と相応するメイン・メモリ・アドレスを記憶して
いる。プロセサはメイン・メモリ・アドレス信号
を伝送することによりデータ・ワードを要求す
る。第1および第2のキヤツシユ・メモリの内容
を調べて要求されたワードがその中に存在するか
否かが決定される。キヤツシユ・メモリが所望の
ワードを含んでいる場合には、該キヤツシユ・メ
モリはキヤツシユ制御回路に整合信号を伝送す
る。もし所望のワードが含まれていない場合には
キヤツシユ・メモリは不整合信号を伝送する。キ
ヤツシユ制御回路が両方のキヤツシユ・メモリか
ら不整合信号を受信すると、該制御回路は2つの
動作を実行させる。第1の動作期間中、メイン・
メモリはメイン・メモリ・アドレス信号に応動し
て所望のメイン・メモリ・ワードにアクセスして
プロセツサおよび第1のキヤツシユ・メモリに伝
送する。またこの第1の動作期間中、第1のキヤ
ツシユ・メモリは記憶された関連するメイン・メ
モリ・アドレスを有する最もプライオリテイの低
いキヤツシユ・データ・ワードにアクセスして、
該ワードを第2のキヤツシユ・メモリに伝送す
る。第2の動作期間中、第1のキヤツシユ・メモ
リはアクセスされたメイン・メモリ・ワードとメ
イン・メモリ・アドレス信号を先にアクセスされ
た第1のキヤツシユ・メモリ・ロケーシヨン中に
記憶し、第2のキヤツシユ・メモリは第1のキヤ
ツシユ・メモリからの最もプライオリテイの低い
キヤツシユ・データ・ワードと記憶されたメイ
ン・メモリ・アドレスを先にアクセスされた第2
のキヤツシユ・メモリのロケーシヨン中に記憶す
る。 キヤツシユ制御手段は第1のキヤツシユ・メモ
リから不整合信号および第2のキヤツシユ・メモ
リからの整合信号に応動してキヤツシユ・メモリ
内で実行すべき2つの動作を実行させる。第1の
動作期間中、第1のキヤツシユ・メモリは最も低
いプライオリテイのキヤツシユ・データ・ワード
および関連するメイン・メモリ・アドレスにアク
セスして第2のキヤツシユ・メモリに伝送し、第
2のキヤツシユ・メモリは整合した記憶されてい
るメモリ・アドレスと関連するキヤツシユ・デー
タ・ワードを第1のキヤツシユ・メモリおよびプ
ロセツサに伝送する。第2の動作期間中、第1の
キヤツシユ・メモリは第2のキヤツシユ・メモリ
からのキヤツシユ・データ・ワードとアドレスを
それより以前には最もプライオリテイの低いキヤ
ツシユ・データ・ワードおよびメモリ・アドレス
によつて使用されていたメモリ・ロケーシヨン中
に記憶する。また第2の動作期間中、第2のキヤ
ツシユ・メモリは第1のキヤツシユ・メモリから
伝送されたキヤツシユ・データ・ワードと関連す
るアドレスを記憶する。 各々のキヤツシユ・メモリは整合メモリおよび
データ・メモリを含んでいる。整合メモリはメイ
ン・メモリ・アドレスを記憶しており、データ・
メモリはキヤツシユ・データ・ワードを記憶して
いる。整合メモリはプロセツサが送出するメイ
ン・メモリ・アドレス信号の各々の組を比較し、
整合または不整合を指示する。整合が生じると、
整合メモリはアドレスをデータ・メモリに伝送
し、それによつて所望のキヤツシユ・データ・ワ
ードにアクセスし、伝送する。コンテント・アド
レツサブル・メモリが整合メモリを実現するのに
使用出来る。 更に、各々のキヤツシユ・メモリは各キヤツシ
ユ・データ・ワードが第1のキヤツシユ・メモリ
内において何時アクセスされたかに関する各キヤ
ツシユ・データ・ワードのプライオリテイを保持
するプライオリテイ回路を有している。該プライ
オリテイ回路により保持されているプライオリテ
イはキヤツシユ・データ・ワードの使用時刻に関
する履歴である。最もプライオリテイの低いキヤ
ツシユ・データ・ワードは最も以前に使用された
ワードである。 キヤツシユ・メモリ・システムは第1のセクシ
ヨンが第2のセクシヨン中に記憶されているワー
ドより高いプライオリテイを有するワードを含む
ようにキヤツシユ・データ・ワードをキヤツシ
ユ・メモリ・システム中に記憶することによりア
クセスされ、更新される。プロセツサがデータ・
ワードにアクセスするとき、各セクシヨンは所望
のワードがそのセクシヨン中に含まれているかど
うかがチエツクされる。所望のワードがいずれの
セクシヨン中にも含まれていない場合には、メイ
ン・メモリがアクセスされ、所望のワードはプロ
セツサおよび第1のセクシヨンに伝送される。ア
クセスされたメイン・メモリ・ワードは第1のセ
クシヨンの最もプライオリテイの低いキヤツシ
ユ・データ・ワードを置き換えるのに使用され、
最もプライオリテイの高いキヤツシユ・データ・
ワードとなる。このとき2番目のプライオリテイ
の低いワードは最もプライオリテイの低いキヤツ
シユ・データ・ワードとなる。それより前に最も
プライオリテイが低かつたキヤツシユ・データ・
ワードは第2のセクシヨンに伝送され、そこで該
データ・ワードは第2のセクシヨンの最もプライ
オリテイの低いワードと入れ替わり、該セクシヨ
ンにおける最もプライオリテイの高いワードとな
る。このとき第2のセクシヨン中で2番目に低い
プライオリテイを有していたワードは最もプライ
オリテイの低いワードとなる。 要求されたワードが第2のセクシヨン中に存在
することが分ると、第2のセクシヨンからのワー
ドがプロセツサに伝送され、第1のセクシヨンの
最もプライオリテイの高いワードとして第1のセ
クシヨン中に記憶される。このとき第1のセクシ
ヨンの最もプライオリテイの低いワードは第2の
セクシヨンに転送され、そこで該ワードは第2の
セクシヨンの最もプライオリテイの高いワードと
なる。最もプライオリテイの低いワードは最も以
前に使用されたワードで、最もプライオリテイの
高いワードは最も最近使用されたワードである。
Claim 1: An apparatus for increasing the storage capacity of a data processing system, the system comprising: a main memory 102; a cache memory system 100; addressing the cache memory system and the main memory. means 101; the cache memory system 100 includes: a plurality of cache memories 107-109, each containing word groups that also exist redundantly in main memory 102; means 104-106 for determining whether the stored first word is also stored in one of the cache memories; Determination means 104-10
a control circuit 1 for storing a first word in a first cache memory in response to an instruction from 6;
03; wherein the first memory transfers the most recently used previously stored word to the second cache memory in response to receiving the first word. A device that increases the storage capacity of a processing system. 2. A method for increasing storage capacity of a data processing system, the system comprising: a main memory 102; a cache memory system 100; a cache memory system and a main memory system 100;
means 101 for addressing memory; the method includes: ordering words stored in cache memory system 100 according to relative time of use; and determining whether the word is stored in one of the cache memories 107-109 forming the cache memory system 100, storing the word in the first cache memory, and storing the word in the least recently used cache memory. A method for increasing the storage capacity of a data processing system comprising the steps of causing a transfer of stored words from a first memory to a second cache memory. 3. In a data processing system, the system comprises: processor means for generating main memory address signals; main memory having a plurality of memory locations for storing main memory words; cache control means; having a plurality of memory locations for storing main memory addresses and corresponding cache data words, and having a main memory address signal inconsistent with all main memory addresses stored therein; first and second cache memories responsive to generating and transmitting a mismatch signal to the cache control means; the cache control means generating the mismatch signal simultaneously by the first and second cache memories; in response to generating and transmitting a first control signal to the main memory and the first and second cache memories; the main memory generating the first control signal and the mismatched main control signal; transmitting the main memory word to the first cache memory in response to the memory address signal; the first cache memory transmitting the most recently used cache data word in response to the first control signal; transmitting the word and corresponding stored main memory address to a second cache memory and storing the transmitted main memory word and main memory address signal; A data processing system for storing a cache data word and a corresponding main memory address transmitted in response to a first control signal. 4. The data processing system of claim 3, wherein the second cache memory further comprises a coherent memory having a plurality of memory locations for storing main addresses and a plurality of memory locations for storing cache data words. a data memory having memory locations for the data memory; the aligned memory responsive to aligned main memory address signals; memory·
generating and transmitting an address, and generating and transmitting a mismatch signal in response to the mismatched main memory address signal; - A data processing system characterized by accessing and transmitting data words. TECHNICAL FIELD The present invention relates to computer systems, and more particularly to systems that use a cache memory in which the location for storing new information is the location of the lowest priority word in the cache memory. BACKGROUND OF THE INVENTION Modern computer systems use processors capable of operating at high speeds that a single large capacity memory cannot keep up with. For this reason, small amounts of high-speed cache memory are typically used in conjunction with large amounts of main memory to improve program execution speed. The cache memory stores a limited number of instructions or data words, and each memory read operation examines the cache memory for the presence of information. If the information is present, it is read from cache memory. If the information does not exist in cache memory, it is read from main memory. If information has to be read from main memory, the new information must replace the existing information in cache memory. Suitable locations for storing new information in cache memory include several widely used replacement algorithms (e.g., random replacement,
(replace most previously used, etc.). It is generally believed that the algorithm that replaces the one most previously used is the most efficient algorithm. However, determining which location contains the least recently used word has proven difficult to accomplish in a time-consuming and economically competitive manner. SUMMARY OF THE INVENTION A cache memory system according to the present invention is divided into several sections containing groups of data words. Each section has a priority circuit that maintains a relative priority determined according to the time the word stored therein was last used. Upon receiving a main memory word that must be inserted into cache memory, the time required to update the cache memory is such that the word is stored in one section while the lowest priority word from a higher priority section to a lower priority section.
It can be reduced by moving to the section. In one embodiment of the invention, a data processing system comprises a processor that requests data words by generating main memory address signals, and a main memory and cache memory system. The cache memory system includes a cache control circuit and first and second cache memories. A cache memory system having one or more cache memories allows the system to be expanded in the field. Furthermore, each cache memory can be implemented as a single LSI circuit. Each cache memory contains a cache data word (which is a duplicate of the word stored in main memory)
and the corresponding main memory address. A processor requests a data word by transmitting a main memory address signal. The contents of the first and second cache memories are examined to determine whether the requested word is present therein. If the cache memory contains the desired word, the cache memory transmits a match signal to the cache control circuit. If the desired word is not included, the cache memory transmits a mismatch signal. When the cache control circuit receives mismatch signals from both cache memories, it causes two operations to occur. During the first operating period, the main
The memory is responsive to main memory address signals to access and transmit desired main memory words to the processor and first cache memory. Also during this first period of operation, the first cache memory accesses the lowest priority cache data word having the associated main memory address stored;
Transfer the word to a second cache memory. During a second period of operation, the first cache memory stores the accessed main memory word and main memory address signal in the previously accessed first cache memory location; cache memory stores the lowest priority cache data word from the first cache memory and the stored main memory address from the first accessed second cache memory.
Stored in cache memory location. The cache control means causes two operations to be performed in the cache memory in response to a mismatch signal from the first cache memory and a match signal from the second cache memory. During a first period of operation, the first cache memory accesses and transmits the lowest priority cache data word and associated main memory address to the second cache memory, and transfers the lowest priority cache data word and associated main memory address to the second cache memory. - The memory transmits the cache data word associated with the aligned stored memory address to the first cache memory and processor. During the second period of operation, the first cache memory transfers cache data words and addresses from the second cache memory to the previously lowest priority cache data words and memory addresses. stored in the memory location previously used. Also during the second period of operation, the second cache memory stores addresses associated with cache data words transmitted from the first cache memory. Each cache memory includes alignment memory and data memory. Coherent memory stores main memory addresses and stores data.
The memory stores cache data words. The matched memory compares each set of main memory address signals sent by the processor;
Indicate alignment or inconsistency. When alignment occurs,
The matching memory transmits the address to the data memory, thereby accessing and transmitting the desired cache data word. Content addressable memory can be used to implement coherent memory. Additionally, each cache memory has a priority circuit that maintains the priority of each cache data word as to when it is accessed within the first cache memory. The priorities maintained by the priority circuit are a history of the times of use of cache data words. The lowest priority cache data word is the most recently used word. The cache memory system stores the cache data words in the cache memory system such that the first section contains words that have a higher priority than the words stored in the second section. accessed and updated. Processor
When accessing a word, each section is checked to see if the desired word is contained within it. If the desired word is not contained in either section, main memory is accessed and the desired word is transmitted to the processor and the first section. the accessed main memory word is used to replace the lowest priority cache data word of the first section;
The highest priority cache data
Becomes a word. The second lowest priority word then becomes the lowest priority cache data word. Prior to that, the lowest priority cache data
The word is transmitted to the second section where the data word replaces the lowest priority word in the second section and becomes the highest priority word in the section. At this time, the word with the second lowest priority in the second section becomes the word with the lowest priority. If the requested word is found to be in the second section, the word from the second section is transmitted to the processor and placed in the first section as the highest priority word in the first section. be remembered. The lowest priority word of the first section is then transferred to the second section, where it becomes the highest priority word of the second section. The word with the lowest priority is the word most recently used, and the word with the highest priority is the word most recently used.

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

第1図は本発明のデータ処理システムのブロツ
ク図、第2および3図は第1図のLRU回路10
5を更に詳細に示す図、第4図は第1図のLRU
回路104のコンテント・アドレツサブル・メモ
リを更に詳細に示す図、第5図は第3図のプライ
オリテイ回路の動作例を示す表である。 詳細な説明 第1図に示すデータ処理システムにおいてデー
タおよびインストラクシヨン・ワードはメイン・
メモリ102およびキヤツシユ・システム100
のメモリ・ロケーシヨン中に記憶されている。プ
ロセツサ101はアドレス・バス112を介して
アドレスを、制御バス113を介して制御信号を
伝送することによりこれらのメモリ・ロケーシヨ
ンの内容を読み出す。キヤツシユ・システム10
0は制御シーケンサ103、LRU回路104,
105および106、キヤツシユ・データ・メモ
リ107,108および109、ならびにキヤツ
シユ・データ・ゲート回路110より成る。
LRU回路およびキヤツシユ・データ・メモリは
対を成しており、各対はキヤツシユ・メモリ・ユ
ニツトを形成している。例えばLRU回路104
およびキヤツシユ・データ・メモリ107が1つ
のキヤツシユ・メモリ・ユニツトを形成してい
る。 キヤツシユ・データ・メモリ中に記憶されたキ
ヤツシユ・データ・ワードはグループに分割され
ており、各グループは同じ時点においてプロセツ
サ101により最後に読み出されたキヤツシユ・
データ・ワードを含んでいる。各グループはキヤ
ツシユ・データ・メモリの内の1つに記憶されて
いる。例えば最も最近使用されたワードのグルー
プはキヤツシユ・データ・メモリ107中に記憶
されており、最も以前に使用されたワードのグル
ープはキヤツシユ・データ・メモリ109中に記
憶されている。プロセツサ101が読み出しを行
うとき、キヤツシユ・データ・ワードは、メモリ
の使用時刻履歴を保持するためキヤツシユ・デー
タ・メモリ間で転送される。例えばメイン・メモ
リ102から1つのワードを読み出す必要がある
場合、このメイン・メモリ・ワードはキヤツシ
ユ・データ・メモリ104の最も以前に使用され
たキヤツシユ・データ・ワードの位置を占め、置
き換えられたキヤツシユ・データ・ワードはキヤ
ツシユ・データ・メモリ108に転送される。 読み出し操作期間中、プロセツサ101により
伝送されたアドレスはLRU回路104,105、
および106によつてチエツクされ、アドレス指
定されたワードがキヤツシユ・データ・メモリ1
07,108または109中に夫々含まれている
か否かが決定される。 例えばLRU回路104がアドレス指定された
ワードはキヤツシユ・データ・メモリ107中に
含まれていると判定すると、該回路107はこの
ワードのアドレスをケーブル131を介してキヤ
ツシユ・データ・メモリ107に伝送する。キヤ
ツシユ・データ・メモリ107はこのアドレスに
応動して所望のワードにアクセスし、これをキヤ
ツシユ・データ・ゲート回路110に伝送する。
キヤツシユ・データ・ゲート回路110から所望
のデータ・ワードはデータ・バス111を介して
プロセツサ101に伝送される。LRU回路10
4がアドレス・バス112を介してプロセツサ1
01により伝送されたアドレスと整合しないと判
定すると、該回路104は制御シーケンサ103
に導線114を介して“1”信号を伝送し、不整
合であつたことを指示する。他のLRU回路も同
様な仕方で動作する。 関連するキヤツシユ・データ・メモリが所望の
メモリ・ワードを有しているか否かをチエツクす
ることに加えて、LRU回路は関連するキヤツシ
ユ・データ・メモリ中の各ワードのプライオリテ
イを保持する。このプライオリテイ情報は関連す
るキヤツシユ・データ・メモリにアクセスする毎
にLRU回路によつて自動的に更新され、キヤツ
シユ・メモリ中のどのワードが最も以前に使用さ
れたワードであるかを規定する。 システムの動作を以下に述べる3つの例によつ
て更に説明する。第1の例では所望のワードはキ
ヤツシユ・システム100中には存在せずメイ
ン・メモリ102から読み出さねばならないもの
と仮定している。所望のワードがキヤツシユ・シ
ステム100中に存在しないと、すべてのLRU
回路は整合線路114,115および116を介
して“1”信号を伝送する。これら信号に応動し
て制御シーケンサ103はメイン・メモリ102
にアクセスし所望のワードを入手する。メイン・
メモリ102から読み出されたワードは最も最近
使用されたワードであるので、該ワードはキヤツ
シユ・データ・メモリ107中に加えられ、キヤ
ツシユ・データ・メモリ107からの最も以前に
使用されたワードはキヤツシユ・データ・メモリ
108中に書き込まれ、キヤツシユ・データ・メ
モリ108の最も以前に使用されたワードはキヤ
ツシユ・データ・メモリ109中に書き込まれ
る。キヤツシユ・データ・メモリ109の最も以
前に使用されたワードは前述の動作が完了した時
点においては最早キヤツシユ・メモリ100中に
存在しない。 キヤツシユ・メモリ・システム100の動作の
第2の例にあつては所望のワードはキヤツシユ・
データ・メモリ107中に存在するものと仮定す
る。所望のワードはキヤツシユ・データ・メモリ
107中に存在するので、メイン・メモリ102
中のワードにアクセスしたりキヤツシユ・デー
タ・メモリ107からキヤツシユ・データ・メモ
リ108にメモリ・ワードを転送する必要はな
い。その代りにLRU回路104はデータ・メモ
リ107中のメモリ・ワードの使用順序を適切に
反映するよう回路104の内部に記憶されたプラ
イオリテイ情報を単に更新することになる。 第3の例にあつては、所望のメモリ・ワードは
データ・メモリ108中に存在するものと仮定す
る。この場合、LRU回路105はアドレス・バ
ス112を介してプロセツサ101に伝送された
アドレスと整合し、データ・メモリ108をして
所望のワードにアクセスし、データ・ゲート回路
110に該ワードを伝送される。制御シーケンサ
103は次にこの所望のデータ・ワードをデー
タ・ゲート回路110によりデータ・バス111
を介してプロセツサ101に伝送させる。この所
望のワードが最も最近使用されたワードであるの
で、該ワードはデータ・メモリ107中に書き込
まねばならない。データ・メモリ107の最も以
前に使用されたワードはデータ・メモリ108中
の所望のメモリ・ワードがそれまで使用していた
メモリ・ロケーシヨン中に書き込まれねばならな
い。 LRU回路105が第2および3図に示されて
いるが、LRU回路106も同様な構成を有して
いる。LRU回路104は第4図に示されている。
第2図はアドレス・バス112を介してプロセツ
サ101により伝送されたアドレスをチエツクし
て所望のワードがキヤツシユ・データ・メモリ1
08中に存在するかどうかを判定するのに使用さ
れる回路を示しており、第3図はキヤツシユ・デ
ータ・メモリ108中の最も以前に使用されたワ
ードを追尾するのに使用されるプライオリテイ回
路の詳細を示している。プロセツサ101が1つ
のワードを読み出すとき、プロセツサはまず
CAGO信号およびクロツク信号を制御バス11
3を介して制御シーケンサ103に伝送し、プロ
セツサ101はアドレス・バス112を介してア
ドレスを伝送する。制御シーケンサ103はこれ
ら信号に応動してC信号およびS信号を発生し、
該信号は導線122および123を介してLRU
回路に伝送される。データ・セレクタ202は導
線122上のC信号に応動してアドレス・バス1
12を介して伝送されたアドレス・ビツトを選択
し、これらのアドレス・ビツトを導線216〜2
23を介してコンテント・アドレツサブル・メモ
リ(CAM)201のデータ・イン入力に加える。
CAMは各々8ビツトより成る4つのワードを含
んでいる。CAMは導線123を介して伝送され
た入力およびデータ・イン入力で受信されるアド
レス・ビツトに応動してこれらアドレス・ビツト
と内部に記憶された4つのワードの各々の内容と
を比較する。4つのワードの内の1つがアドレ
ス・ビツトと整合すると、“1”が関連する導線
212,213,214または215を介して伝
送される。整合しない場合には“1”が導線23
6を介して伝送され、T1時刻においてフリツ
プ・フロツプ206中に記憶される。整合した場
合には導線212〜215の状態は導線123を
介して伝送されるS信号の立下りによつてラツチ
204中に記憶される。データ・セレクタ205
はラツチ204の内容を選択し、該選択されたラ
ツチ204の内容は導線224〜227を介して
加えられ、次いで導線228〜231、ケーブル
132を介してキヤツシユ・データ・メモリ10
8に伝送される。キヤツシユ・ワード・メモリ1
08はケーブル132を介して伝送されたアドレ
スに応動して所望のワードにアクセスし、前述の
如くこのワードをデータ・ゲート回路110に伝
送する。所望のワードがデータ・メモリ108中
に記憶されていたと仮定すると、このときそのワ
ードが最も最近使用されたワードとなり、従つて
データ・メモリ107に転送されねばならず、デ
ータ・メモリ107の最も以前に使用されたワー
ドはデータ・メモリ108に転送され、このワー
ドのアドレスはCAM201中に書き込まれる。 第4図はアドレス・バス112を介してプロセ
ツサ101により伝送されたアドレスをチエツク
して所望のワードがキヤツシユ・データ・メモリ
107中に存在するか否かを決定するのに使用さ
れる回路を示しており、第3図はキヤツシユ・デ
ータ・メモリ108中の最も以前に使用されたワ
ードを追尾するのに使用されるプライオリテイ回
路の詳細を示している。第4図の回路は第2図の
データ・セレクタ202と類似したデータ・セレ
クタを含まず、プライオリテイ回路444を含ん
でいる点を除いて第2図の回路と動作は同一であ
る。プライオリテイ回路444は第3図を参照し
て述べるプライオリテイ回路と同一である。デー
タ・セレクタが不要な理由は第4図の回路は常に
アドレス・バス112を介して伝送されるアドレ
スを使用するからである。第4図の回路がデー
タ・セレクタを必要としないのは、この回路はキ
ヤツシユ・メモリ100中の最も最近使用された
ワードと関連しており、従つて第2図に示す回路
のようにアドレス・バス112からのデータを使
用するか、または最も高いプライオリテイを有す
るLRU回路からのデータを使用するか判定する
必要がないためである。この点に関しては以下に
示す例により更に明白となろう。 第2および4図に示す回路の動作を説明するた
め、先に述べた例3を使用する。例3は所望のワ
ードがデータ・メモリ108中に存在するときに
実行すべき動作を与えたものである。この例に関
する更に詳細な説明をここではまずLRU回路1
05の観点から述べ、次いでLRU回路104中
の相応する動作に関して述べることにより行う。
データ・メモリ108中のワード1およびデー
タ・メモリ107中のワード2が最も以前に使用
されたワードであるものと仮定する。これらの異
なる動作を実行するため、制御シーケンサ103
は多数のタイミング信号を発生するが、その中で
最も重要なものはT0〜T4である。T0期間
中、アドレス・バス112上のアドレス・ビツト
はデータ・セレクタ202によつて選択され、
CAM201で整合するかどうか探索するのに使
用される。これらのアドレス・ビツトがCAM2
01中のワード2の内容と整合するものと仮定す
ると、“1”が導線213上に発生されるが、導
線212,214および215は“0”である。
この動作は導線123を介してCAM201に伝
送されたS信号および導線122を介してCAM
201に伝送されたC信号の制御の下で実行され
る。導線212〜215上の情報はS信号の終了
時点においてラツチ204中に記憶される。更に
S信号はまたCAM201の整合出力端子をフリ
ツプ・フロツプ206中に加えるクロツクとして
作用する。フリツプ・フロツプ206の出力のM
2信号は導線115を介して制御シーケンサ10
3に伝送される。 T1期間中、データ・セレクタ203はM2信
号に応動してラツチ204の出力をアドレスとし
て選択し、該アドレスは導線208〜211を介
してCAM201に伝送され、データ・セレクタ
205はM2信号に応動してラツチ204の出力
をアドレスとして選択し、該アドレスはケーブル
132を介してデータ・メモリ108に伝送され
る。導線208〜211上のアドレスに応動し
て、CAM201は第2のワードの内容を読み出
し、これらの内容をラツチ207に伝送し、T1
の終了時点においてこれらの内容は該ラツチ20
7中に記憶される。データ・メモリ108はケー
ブル132を介して伝送されたアドレスに応動し
てその第2のワードの内容を読み出す。これらの
内容はデータ・メモリ108の内部に記憶され、
データ・ゲート回路110に伝送される。T1期
間中、LRU回路104は最も以前に使用された
ワードのアドレスにアクセスし、該アドレスをケ
ーブル117を介してLRU回路105に伝送し、
データ・メモリ107は最も以前に使用されたワ
ードにアクセスし、該ワードをケーブル140を
介してデータ・メモリ108に伝送するが、これ
については以下で述べる。LRU回路104から
のアドレスはCAM201中に書き込まれ、相応
するデータ・ワードはデータ・メモリ108中に
書き込まれる。T2期間中、データ・セレクタ2
03はCAM201に対するアドレスとして使用
されるワード2のアドレスを含むラツチ204の
出力を再び選択する。LRU回路からの最も以前
に使用されたアドレス・ワードはワード2中に記
憶される。T2期間中、制御シーケンサ103は
導線124を介してW信号を、導線120を介し
てRPL2信号を伝送し、それによつてCAM20
1はデータ入力端子上に存在する情報をワード2
中に書き込む。それと同時に、データ・メモリ1
07の最も以前に使用されたワードはデータ・メ
モリ108のワード2中に書き込まれる。このと
きアドレスはデータ・セレクタ205およびケー
ブル132を介してラツチ204の出力により供
給される。以下で述べるように、第3図に示すプ
ライオリテイ回路は、ワード2がLRU回路10
5中の最も以前に使用されたワードでなく最も最
近使用されたワードをあるという事実を反映する
ようT3期間中に更新される。T4期間中にフリ
ツプ・フロツプ206はリセツトされる。 ここで例3を第4図を参照してLRU回路10
4に関して記述する。T0期間中、CAM401
の探索が行われる。しかし整合しないので整合出
力端子は“0”となり、この“0”はフリツプ・
フロツプ406中に記憶され、M1信号は制御シ
ーケンサ103には伝送されない。 T1期間中、M1信号は存在しないので、
CAM401はプライオリテイ回路444からの
アドレスによりアドレス指定される。このアドレ
スは導線432〜435、データ・セレクタ40
3および導線408〜411を介してCAM40
1のアドレス・イン端子に加えられる。このアド
レス・ビツトはCAM401およびデータ・メモ
リ107の最も以前に使用されたワードのアドレ
スである。またT1期間中、データ・メモリ10
7はデータ・セレクタ405およびケーブル13
1を介してプライオリテイ回路444の出力によ
つてアドレス指定される。T1の終了時点におい
て、CAM401の出力データはラツチ407中
に書き込まれる。ラツチ407の内容はケーブル
117を介してLRU回路105に伝送される。 T2期間中制御シーケンサ103は導線119
および124を介してLRU回路104およびデ
ータ・メモリ107にRPL1およびW信号を
夫々伝送する。これらの信号に応動して、アドレ
ス・バス112の内容はCAM401中の導線4
32〜435上のビツトにより決定された最も以
前に使用されたワードのロケーシヨン中に書き込
まれる。それと同時に、データ・バス111上に
存在するワードはケーブル131を介して伝送さ
れたアドレスのデータ・メモリ107中に書き込
まれる。 T3期間中にプライオリテイ回路444は更新
される。ここで述べた例ではLRU回路106ま
たはデータ・メモリ109と関連する情報は変更
する必要がなかつたことに注意されたい。 考察すべき他の例は所望のワードがデータ・メ
モリ107〜109中に含まれておらず、メイ
ン・メモリ102から読み出さねばならない例1
に相応する場合である。この例の場合、LRU回
路はいずれもT0期間中に整合が成立せず、T0
の終了時点において制御シーケンサ103はメイ
ン・メモリ102にアクセスして所望のワードを
入手する。制御シーケンサ103は導線125を
介してメイン・メモリ読み出し信号を伝送するこ
とによりメイン・メモリ102にアクセスする。
メイン・メモリ102が所望のワードにアクセス
すると、該メモリは導線126を介してメイン・
メモリ・レデイ信号を伝送し、所望のメモリ・ワ
ードをデータ・バス111上に加えることにより
応動する。制御シーケンサ103はメイン・メモ
リ・レデイ信号に応動してキヤツシユ・データ・
レデイ信号を発生し、プロセツサ101に対しデ
ータがデータ・バス111上に存在し、LRU回
路およびデータ・メモリを更新するための次のス
テツプを実行すべきことを知らせる。 メイン・メモリ・レデイ信号の受信後、制御シ
ーケンサ103はT1信号を送信する。T1信号
が送信されたことにより生じる結果をまず第2図
を参照して述べる。即ちM2信号は導線115を
介して伝送されず、データ・セレクタ203は
CAM201を読み出すために導線232〜23
5を介して第3図のプライオリテイ回路から伝送
された最も以前に使用されたワードのアドレスを
選択する。CAM201から読み出されたワード
はデータ・メモリ108中に記憶された最も以前
に使用されたデータ・ワードのアドレスである。
それと同時に再び最も以前に使用されたワードの
アドレスであるケーブル132を介して伝送され
たアドレスに基づいてデータ・メモリ108に対
し読み出しが実行される。T1の終了時点におい
て、最も以前に使用されたワードのアドレスはラ
ツチ207中に加えられ、データ・メモリ108
からアクセスされているデータは同様にデータ・
メモリ108中の同様なラツチの組の中に加えら
れる。同じ型の動作がLRU回路104および1
06およびデータ・メモリ107および109中
で実行される。 T2期間中、LRU回路104からケーブル1
17を介して伝送されるアドレスは、第3図のプ
ライオリテイ回路から導線232〜235を介し
て伝送されるアドレスによつて規定される最も以
前に使用されたワードのアドレスに相当する
CAM201のロケーシヨン中に書き込まれる。
同様に、データ・メモリ107からアクセスされ
ていたデータはデータ・メモリ108中に書き込
まれる。 LRU回路104に関しては、アドレス・バス
112上のアドレスは最も以前に使用されたワー
ドのアドレスを指示するプライオリテイ回路44
4から導線432〜435を介して伝送された情報
によりアドレス指定されるCAM401のロケー
シヨン中に書き込まれる。データ・バス111上
に存在するデータは最も以前に使用されたワード
のアドレスにおいて最も以前に使用されたデー
タ・メモリ107のワード中に書き込まれる。同
様の動作がLRU回路106およびデータ・メモ
リ109においても実行される。T3期間中、
LRU回路104,105および106のプライ
オリテイ回路は先の最も以前に使用されたワード
が現在は最も最近に使用されたワードであるとい
う事実を反映するために更新される。 第3図に示すプライオリテイ回路の動作を説明
するため、所望のワードがデータ・メモリ108
中に含まれている場合の動作を記述する例3を参
照する。第3図のプライオリテイ回路の動作は第
4図のプライオリテイ回路444およびLRU回
路106のプライオリテイ回路の動作と類似して
いる。以前の例では最も以前に使用されたワード
はデータ・メモリ108中のワード1であり、
LRU回路105のCAMロケーシヨン1中の相応
するアドレスであつた。T0期間中に実行された
整合操作期間内に、CAM201のワード2が、
プロセツサ101が読み出したいアドレスを含ん
でいることが見出された。T3期間中、第5図に
示すプライオリテイ回路はワード2が現在最も最
近使用されたワードであるという事実を反映する
よう更新されねばならない。しかし、ワード1は
尚最も以前に使用したワードを保持している。フ
リツプ・フロツプ322〜327はCAM201
およびデータ・メモリ108中に含まれているワ
ードの使用順序に関するプライオリテイを保持す
るのに使用される。NORゲート328〜331
はフリツプ・フロツプ322〜327中に含まれ
た情報をデコードしてどのワードが最も以前に使
用されたワードであるかを指示する。例えば、
NORゲート328が導線232を介して“1”
を伝送している場合、これはワード0が最も以前
に使用されたワードであることを指示している。
ORゲート309〜315およびANDゲート31
6〜321はプライオリテイ回路の更新期間中に
フリツプ・フロツプ322〜327の内どれを変
更すべきかを決定するのに使用される。表1はセ
ツトされているこれらフリツプ・フロツプ意味を
表わしている。例えばフリツプ・フロツプ322
がセツトされているとすると、フリツプ・フロツ
プ322は“1”なるM0信号を導線301を介
してNORゲート328に伝送する。フリツプ・
フロツプ322がセツトされているということは
ワード0がワード1よりもより最近使用されたこ
とを意味する。
FIG. 1 is a block diagram of the data processing system of the present invention, and FIGS. 2 and 3 are the LRU circuit 10 of FIG.
Figure 4 shows the LRU of Figure 1 in more detail.
FIG. 5 is a diagram showing the content addressable memory of circuit 104 in more detail. FIG. 5 is a table showing an example of the operation of the priority circuit of FIG. DETAILED DESCRIPTION In the data processing system shown in Figure 1, data and instruction words are
Memory 102 and cache system 100
is stored in the memory location of Processor 101 reads the contents of these memory locations by transmitting addresses over address bus 112 and control signals over control bus 113. Cash system 10
0 is the control sequencer 103, the LRU circuit 104,
105 and 106, cache data memories 107, 108 and 109, and a cache data gate circuit 110.
The LRU circuit and cache data memory are arranged in pairs, each pair forming a cache memory unit. For example, LRU circuit 104
and cache data memory 107 form one cache memory unit. The cache data words stored in cache data memory are divided into groups, with each group containing the cache data words that were last read by processor 101 at the same time.
Contains data words. Each group is stored in one of the cache data memories. For example, the most recently used group of words is stored in cache data memory 107 and the least recently used group of words is stored in cache data memory 109. When processor 101 performs a read, cache data words are transferred between cache data memories to maintain a time history of memory usage. For example, if a word needs to be read from main memory 102, this main memory word occupies the position of the most recently used cache data word in cache data memory 104 and the replaced cache data word occupies the position of the most recently used cache data word in cache data memory 104. - The data word is transferred to cache data memory 108. During a read operation, the address transmitted by processor 101 is sent to LRU circuits 104, 105,
and 106, the addressed word is stored in cache data memory 1.
07, 108, or 109, respectively. For example, if LRU circuit 104 determines that the addressed word is contained in cache data memory 107, circuit 107 transmits the address of this word to cache data memory 107 via cable 131. . In response to this address, cache data memory 107 accesses the desired word and transmits it to cache data gate circuit 110.
From cache data gate circuit 110, the desired data word is transmitted to processor 101 via data bus 111. LRU circuit 10
4 to processor 1 via address bus 112.
If the circuit 104 determines that the address does not match the address transmitted by 01, the control sequencer 103
A "1" signal is transmitted through conductor 114 to indicate that there was a mismatch. Other LRU circuits operate in a similar manner. In addition to checking whether the associated cache data memory has the desired memory word, the LRU circuit maintains the priority of each word in the associated cache data memory. This priority information is automatically updated by the LRU circuitry each time the associated cache data memory is accessed and defines which word in the cache memory is the least recently used word. The operation of the system is further illustrated by three examples described below. The first example assumes that the desired word does not exist in cache system 100 and must be read from main memory 102. If the desired word does not exist in cache system 100, all LRUs
The circuit transmits a "1" signal via matching lines 114, 115 and 116. In response to these signals, the control sequencer 103
and obtain the desired word. Maine·
Since the word read from memory 102 is the most recently used word, it is added into cache data memory 107 and the least recently used word from cache data memory 107 is added to cache data memory 107. - The least recently used word of cache data memory 108 written into data memory 108 is written into cache data memory 109. The most recently used word of cache data memory 109 is no longer present in cache memory 100 upon completion of the operations described above. In a second example of operation of cache memory system 100, the desired word is
Assume that it resides in data memory 107. Since the desired word is in cache data memory 107, main memory 102
There is no need to access or transfer memory words from cache data memory 107 to cache data memory 108. Instead, LRU circuit 104 will simply update the priority information stored within circuit 104 to properly reflect the order of use of memory words in data memory 107. In the third example, assume that the desired memory word resides in data memory 108. In this case, LRU circuit 105 matches the address transmitted to processor 101 via address bus 112, causes data memory 108 to access the desired word, and transmits the word to data gate circuit 110. Ru. Control sequencer 103 then transfers this desired data word to data bus 111 by data gate circuit 110.
The data is transmitted to the processor 101 via the . Since this desired word is the most recently used word, it must be written into data memory 107. The most recently used word of data memory 107 must be written into the memory location previously used by the desired memory word in data memory 108. Although LRU circuit 105 is shown in FIGS. 2 and 3, LRU circuit 106 has a similar configuration. LRU circuit 104 is shown in FIG.
FIG. 2 shows that the address transmitted by processor 101 via address bus 112 is checked to ensure that the desired word is stored in cache data memory 1.
3 shows the circuitry used to determine whether the cache data memory 108 exists in the Showing details of the circuit. When processor 101 reads one word, the processor first reads
Control bus 11 for CAGO signal and clock signal
3 to control sequencer 103, and processor 101 transmits the address via address bus 112. The control sequencer 103 generates a C signal and an S signal in response to these signals,
The signal is routed to the LRU via conductors 122 and 123.
transmitted to the circuit. Data selector 202 selects address bus 1 in response to the C signal on conductor 122.
12 and connect these address bits to conductors 216-2.
23 to the data-in input of content addressable memory (CAM) 201.
CAM contains four words of 8 bits each. The CAM is responsive to the input transmitted via conductor 123 and the address bits received at the data in input and compares these address bits with the contents of each of four internally stored words. When one of the four words matches an address bit, a "1" is transmitted over the associated conductor 212, 213, 214 or 215. If there is no match, “1” is the conductor 23
6 and stored in flip-flop 206 at time T1. If matched, the state of conductors 212-215 is stored in latch 204 by the falling edge of the S signal transmitted through conductor 123. Data selector 205
selects the contents of latch 204, and the contents of the selected latch 204 are applied via conductors 224-227 and then via conductors 228-231 and cable 132 to cache data memory 10.
8. Cash word memory 1
08 accesses the desired word in response to the address transmitted over cable 132 and transmits this word to data gate circuit 110 as described above. Assuming that the desired word has been stored in data memory 108, that word will then be the most recently used word and therefore must be transferred to data memory 107, and will be the most recently used word in data memory 107. The word used is transferred to data memory 108 and the address of this word is written into CAM 201. FIG. 4 shows the circuitry used to check the address transmitted by processor 101 over address bus 112 to determine whether the desired word is present in cache data memory 107. FIG. 3 shows details of the priority circuitry used to track the least recently used word in cache data memory 108. The circuit of FIG. 4 is identical in operation to the circuit of FIG. 2 except that it does not include a data selector similar to data selector 202 of FIG. 2 and includes a priority circuit 444. Priority circuit 444 is the same as the priority circuit described with reference to FIG. A data selector is not required because the circuit of FIG. 4 always uses addresses transmitted over address bus 112. The circuit of FIG. 4 does not require a data selector because it is associated with the most recently used word in cache memory 100 and therefore does not require an address selector like the circuit shown in FIG. This is because there is no need to determine whether to use data from bus 112 or from the LRU circuit with the highest priority. This point will become clearer from the examples given below. To explain the operation of the circuits shown in FIGS. 2 and 4, Example 3, discussed above, will be used. Example 3 provides the operations to be performed when the desired word is present in data memory 108. A more detailed explanation of this example will be provided here, starting with LRU circuit 1.
05 and then discuss the corresponding operation in LRU circuit 104.
Assume that word 1 in data memory 108 and word 2 in data memory 107 are the least recently used words. To perform these different operations, the control sequencer 103
generates a number of timing signals, the most important of which are T0-T4. During period T0, address bits on address bus 112 are selected by data selector 202;
It is used in the CAM 201 to search for a match. These address bits are CAM2
Assuming a match with the contents of word 2 in 01, a "1" is generated on lead 213, but leads 212, 214 and 215 are "0".
This operation is caused by the S signal transmitted to the CAM 201 via the conductor 123 and the CAM 201 via the conductor 122.
201 is executed under the control of the C signal transmitted to 201. The information on conductors 212-215 is stored in latch 204 at the end of the S signal. In addition, the S signal also acts as a clock to clock the matched output terminal of CAM 201 into flip-flop 206. M of the output of flip-flop 206
2 signals are sent to the control sequencer 10 via conductor 115.
3. During period T1, data selector 203 selects the output of latch 204 as an address in response to the M2 signal, which address is transmitted to CAM 201 via conductors 208-211, and data selector 205 responds to the M2 signal. selects the output of latch 204 as the address, which is transmitted to data memory 108 via cable 132. In response to the address on conductors 208-211, CAM 201 reads the contents of the second word, transmits these contents to latch 207, and outputs T1.
At the end of the latch 20, these contents are
It is memorized in 7. Data memory 108 reads the contents of its second word in response to the address transmitted over cable 132. These contents are stored inside the data memory 108,
It is transmitted to data gate circuit 110. During period T1, LRU circuit 104 accesses the address of the most recently used word and transmits the address to LRU circuit 105 via cable 117;
Data memory 107 accesses the most recently used word and transmits that word via cable 140 to data memory 108, as described below. The address from LRU circuit 104 is written into CAM 201 and the corresponding data word is written into data memory 108. During T2 period, data selector 2
03 again selects the output of latch 204 containing the address of word 2 used as the address for CAM 201. The most recently used address word from the LRU circuit is stored in word 2. During the T2 period, the control sequencer 103 transmits the W signal via conductor 124 and the RPL2 signal via conductor 120, thereby transmitting the CAM 20
1 transfers the information present on the data input terminal to word 2
Write inside. At the same time, data memory 1
The 07 most recently used word is written into word 2 of data memory 108. The address is then provided by the output of latch 204 via data selector 205 and cable 132. As described below, the priority circuit shown in FIG.
is updated during T3 to reflect the fact that it is the most recently used word in 5 and not the least recently used word. During T4, flip-flop 206 is reset. Here, Example 3 is explained by referring to FIG.
4 will be described below. During the T0 period, CAM401
A search is carried out. However, since there is no matching, the matching output terminal becomes “0”, and this “0” is the flip
The M1 signal is stored in flop 406 and is not transmitted to control sequencer 103. Since there is no M1 signal during the T1 period,
CAM 401 is addressed by an address from priority circuit 444. This address is connected to conductors 432-435, data selector 40.
3 and conductors 408 to 411 to CAM40.
1 address in terminal. This address bit is the address of the most recently used word of CAM 401 and data memory 107. Also, during the T1 period, data memory 10
7 is data selector 405 and cable 13
1 via the output of priority circuit 444. At the end of T1, the output data of CAM 401 is written into latch 407. The contents of latch 407 are transmitted to LRU circuit 105 via cable 117. During the T2 period, the control sequencer 103 connects the conductor 119.
and 124 to transmit the RPL1 and W signals to the LRU circuit 104 and data memory 107, respectively. In response to these signals, the contents of address bus 112 are transferred to conductor 4 in CAM 401.
It is written into the location of the least recently used word determined by bits above 32-435. At the same time, the word present on data bus 111 is written into data memory 107 at the address transmitted via cable 131. Priority circuit 444 is updated during period T3. Note that in the example described herein, no information associated with LRU circuit 106 or data memory 109 needed to be changed. Another example to consider is Example 1 where the desired word is not contained in data memory 107-109 and must be read from main memory 102.
This is a case corresponding to . In this example, none of the LRU circuits achieves matching during the T0 period, and T0
At the end of , control sequencer 103 accesses main memory 102 to obtain the desired word. Control sequencer 103 accesses main memory 102 by transmitting a main memory read signal over conductor 125.
When main memory 102 accesses the desired word, it is connected to main memory via conductor 126.
It responds by transmitting a memory ready signal and adding the desired memory word onto data bus 111. The control sequencer 103 responds to the main memory ready signal to read the cache data.
A ready signal is generated to inform processor 101 that data is present on data bus 111 and to perform the next step to update the LRU circuitry and data memory. After receiving the main memory ready signal, control sequencer 103 sends a T1 signal. The consequences of transmitting the T1 signal will first be described with reference to FIG. That is, the M2 signal is not transmitted via conductor 115 and data selector 203 is
Lead wires 232 to 23 to read CAM201
5, the address of the least recently used word transmitted from the priority circuit of FIG. The word read from CAM 201 is the address of the most recently used data word stored in data memory 108.
At the same time, a read is again performed on data memory 108 based on the address transmitted via cable 132, which is the address of the most recently used word. At the end of T1, the address of the most recently used word is added into latch 207 and stored in data memory 108.
The data being accessed from
It is added to a similar set of latches in memory 108. The same type of operation occurs in LRU circuits 104 and 1.
06 and data memories 107 and 109. During T2 period, LRU circuit 104 to cable 1
The address transmitted via 17 corresponds to the address of the most recently used word as defined by the address transmitted via conductors 232-235 from the priority circuit of FIG.
Written into the CAM 201 location.
Similarly, data that was being accessed from data memory 107 is written into data memory 108. With respect to the LRU circuit 104, the address on the address bus 112 indicates the address of the least recently used word in the priority circuit 44.
4 via conductors 432-435. Data present on data bus 111 is written into the most recently used word of data memory 107 at the address of the most recently used word. Similar operations are performed in LRU circuit 106 and data memory 109. During the T3 period,
The priority circuits of LRU circuits 104, 105 and 106 are updated to reflect the fact that the previous most recently used word is now the most recently used word. To explain the operation of the priority circuit shown in FIG.
See Example 3, which describes the behavior when the The operation of the priority circuit of FIG. 3 is similar to the operation of the priority circuits of priority circuit 444 and LRU circuit 106 of FIG. In the previous example, the most recently used word was word 1 in data memory 108;
It was the corresponding address in CAM location 1 of LRU circuit 105. During the alignment operation performed during T0, word 2 of CAM 201 is
It has been found that processor 101 contains the address it wishes to read. During T3, the priority circuit shown in FIG. 5 must be updated to reflect the fact that word 2 is now the most recently used word. However, word 1 still holds the most recently used word. Flip flops 322 to 327 are CAM201
and is used to maintain priorities regarding the order of use of words contained in data memory 108. NOR gates 328-331
decodes the information contained in flip-flops 322-327 to indicate which word is the most recently used word. for example,
NOR gate 328 is set to “1” via conductor 232
, this indicates that word 0 is the least recently used word.
OR gates 309-315 and AND gate 31
6-321 are used to determine which of flip-flops 322-327 should be changed during the priority circuit update period. Table 1 shows the meaning of these flip-flops set. For example, flip-flop 322
is set, flip-flop 322 transmits a "1" M0 signal to NOR gate 328 via conductor 301. flip
Flop 322 being set means that word 0 has been used more recently than word 1.

【表】 NORゲート328〜331により実行される
機能は表2に示されている。 表 2 S0=01・02・03 S1=M01・12・13 S2=M02・M12・23 S3=M03・M13・M23 “1”が導線232を介して伝送される場合、
S0信号が伝送されていると呼ぶことにする。フ
リツプ・フロツプ322がセツトされていると表
2のM01の値は“1”であり、01の値は0
である。フリツプ・フロツプ322がリセツトさ
れていると、M01の値は0であり、01の値
は1である。例えばフリツプ・フロツプ322,
323および324がリセツトされていると、S
0信号が導線232を介して伝送されることにな
る。 ORゲート309〜315およびANDゲート3
16〜321の更新時点における動作を表3に示
す。
TABLE The functions performed by NOR gates 328-331 are shown in Table 2. Table 2 S0=01.02.03 S1=M01.12.13 S2=M02.M12.23 S3=M03.M13.M23 When “1” is transmitted via conductor 232,
Let us say that the S0 signal is being transmitted. When flip-flop 322 is set, the value of M01 in Table 2 is "1" and the value of 01 is 0.
It is. When flip-flop 322 is reset, the value of M01 is 0 and the value of 01 is 1. For example, flip-flop 322,
If 323 and 324 are reset, S
A zero signal will be transmitted via conductor 232. OR gates 309-315 and AND gate 3
Table 3 shows the operations at the time of updating 16 to 321.

【表】 更新はRPL2信号が導線120を介して制御
シーケンサ103から伝送される時刻T3におい
て行なわれる。T3およびRPL2のANDゲート
308によつてとられ、これによつてORゲート
309〜315およびANDゲート316〜32
1がエネイブルされる。例えば更新期間中に
“1”が導線231を介して伝送されると、フリ
ツプ・フロツプ324,326および327がリ
セツトされる。導線231を介して伝送される
“1”はワード3が現在最も最近使用されたワー
ドであることを示し、従つて表1によりフリツ
プ・フロツプ324,326および327はセツ
ト出来ない。何故ならばこれらフリツプ・フロツ
プはワード0、ワード1およびワード2が夫々ワ
ード3よりもより最近アクセスされたことを指示
するからである。 第3図に示す回路の動作を更に明解に説明する
ため、時刻T0における動作期間中にワード2の
整合が行われる以前に示した例を第5図を参照し
て記述する。行501はフリツプ・フロツプ32
2〜327の初期状態を示している。ワード2が
所望のワードを含んでいると決定されると、ワー
ド2の内容はCAM201およびデータ・メモリ
108の両方においてアクセスされ、伝送されて
LRU回路104およびデータ・メモリ107中
に記憶される。LRU回路104およびデータ・
メモリ107からの最も以前に使用されたワード
はLRU回路105およびデータ・メモリ108
に伝送され、これらメモリの各々のワード2中に
記憶される。この情報がワード2中に記憶された
後、ワード2は最も最近使用されたワードとな
り、フリツプ・フロツプ322〜327はそれに
応じて更新されねばならない。ワード2が選択さ
れたワードであつたので、第2図のデータ・セレ
クタ205は導線230を介して“1”を伝送す
る。ORゲート309〜315およびANDゲート
316〜321は導線230を介して伝送された
“1”に応動してフリツプ・フロツプ327をセ
ツトし、フリツプ・フロツプ323および325
をリセツトする。これが第5図の行502に示さ
れている。最も以前に使用されたワードは尚行5
02中のワード1であることに注意されたい。次
の探索操作において所望のワードがワード3であ
る場合、フリツプ・フロツプ322〜327は行
503に示す状態を反映するべくT3期間中に更
新される。次の探索操作において、ワード1が所
望の情報を含んでいることが見出されると、フリ
ツプ・フロツプ322〜327が行504に示す
状態を反映するべく更新される。ここで最も以前
に使用されたワードは3回の探索操作期間中(こ
の期間中にワード2,3および1はアクセスされ
ている)にアクセスされなかつたワード0である
ことに注意されたい。 前述の実施例は本発明の原理を例示するもので
あり、本発明の精神および範囲を逸脱することな
く当業者にあつては他の装置を考案し得ることを
理解されたい。
[Table] The update takes place at time T3 when the RPL2 signal is transmitted from control sequencer 103 via conductor 120. T3 and RPL2 by AND gate 308, thereby OR gates 309-315 and AND gates 316-32.
1 is enabled. For example, when a "1" is transmitted on conductor 231 during an update period, flip-flops 324, 326 and 327 are reset. The "1" transmitted over conductor 231 indicates that word 3 is currently the most recently used word, so according to Table 1, flip-flops 324, 326 and 327 cannot be set. This is because these flip-flops indicate that word 0, word 1, and word 2 have each been accessed more recently than word 3. In order to more clearly explain the operation of the circuit shown in FIG. 3, the example shown before the alignment of word 2 takes place during the operation at time T0 will be described with reference to FIG. Row 501 is flip-flop 32
2 to 327 are shown. Once word 2 is determined to contain the desired word, the contents of word 2 are accessed and transmitted in both CAM 201 and data memory 108.
Stored in LRU circuit 104 and data memory 107. LRU circuit 104 and data
The most recently used word from memory 107 is sent to LRU circuit 105 and data memory 108.
and stored in word 2 of each of these memories. After this information is stored in word 2, word 2 becomes the most recently used word and flip-flops 322-327 must be updated accordingly. Since word 2 was the selected word, data selector 205 of FIG. 2 transmits a "1" on conductor 230. OR gates 309-315 and AND gates 316-321 respond to the "1" transmitted via conductor 230 to set flip-flop 327 and set flip-flops 323 and 325.
Reset. This is shown in row 502 of FIG. The word used most recently is Shogyo 5
Note that word 1 in 02. If the desired word in the next search operation is word 3, flip-flops 322-327 are updated during T3 to reflect the state shown in line 503. In the next search operation, if word 1 is found to contain the desired information, flip-flops 322-327 are updated to reflect the state shown in line 504. Note that the most recently used word here is word 0, which was not accessed during three search operations (during which periods words 2, 3, and 1 were accessed). It will be appreciated that the foregoing embodiments are illustrative of the principles of the invention and that other arrangements may be devised by those skilled in the art without departing from the spirit and scope of the invention.

JP50319282A 1981-10-02 1982-09-22 Cache Memory Using Lowest Priority Replacement Circuitry Granted JPS58501645A (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
US307857 1981-10-02
PCT/US1982/001294 WO1983001323A1 (en) 1981-10-02 1982-09-22 Cache memory using a lowest priority replacement circuit

Publications (2)

Publication Number Publication Date
JPS58501645A JPS58501645A (en) 1983-09-29
JPH0354372B2 true JPH0354372B2 (en) 1991-08-20

Family

ID=22168211

Family Applications (1)

Application Number Title Priority Date Filing Date
JP50319282A Granted JPS58501645A (en) 1981-10-02 1982-09-22 Cache Memory Using Lowest Priority Replacement Circuitry

Country Status (1)

Country Link
JP (1) JPS58501645A (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS5226124A (en) * 1975-08-22 1977-02-26 Fujitsu Ltd Buffer memory control unit
JPS55117780A (en) * 1979-03-05 1980-09-10 Nec Corp Buffer memory unit

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS5226124A (en) * 1975-08-22 1977-02-26 Fujitsu Ltd Buffer memory control unit
JPS55117780A (en) * 1979-03-05 1980-09-10 Nec Corp Buffer memory unit

Also Published As

Publication number Publication date
JPS58501645A (en) 1983-09-29

Similar Documents

Publication Publication Date Title
US4458310A (en) Cache memory using a lowest priority replacement circuit
JPS5830319Y2 (en) computer system
KR100190351B1 (en) Apparatus and method for reducing interference in two-level cache memory
US5590379A (en) Method and apparatus for cache memory access with separate fetch and store queues
JPS6118222B2 (en)
US5249284A (en) Method and system for maintaining data coherency between main and cache memories
US6065098A (en) Method for maintaining multi-level cache coherency in a processor with non-inclusive caches and processor implementing the same
JPH0253813B2 (en)
US5619677A (en) Data processing system with an enhanced cache memory control
JPS60138653A (en) Hierarchical memory control system
JP3886189B2 (en) Microprocessor device supporting burstable and non-cacheable memory access
US4658356A (en) Control system for updating a change bit
JPH0354372B2 (en)
JPH03230238A (en) Cache memory control system
EP0352806A2 (en) Cache memory and access controller using such memory
JPS59173828A (en) Data processing system
KR960015583B1 (en) Cache memory filtering apparatus of multi-processor
JPH0115900B2 (en)
JPH01226056A (en) Address converter
JP3219422B2 (en) Cache memory control method
KR960015584B1 (en) Cache memory filtering method of multi-processor
JPH06243045A (en) Cache memory
JPH02136946A (en) Cache memory control circuit
JPH01276348A (en) Secondary cache memory system
JPH04291642A (en) Cache control system