Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
JP3445873B2 - Data prefetch method and information processing apparatus therefor - Google Patents
[go: Go Back, main page]

JP3445873B2 - Data prefetch method and information processing apparatus therefor - Google Patents

Data prefetch method and information processing apparatus therefor

Info

Publication number
JP3445873B2
JP3445873B2 JP13694495A JP13694495A JP3445873B2 JP 3445873 B2 JP3445873 B2 JP 3445873B2 JP 13694495 A JP13694495 A JP 13694495A JP 13694495 A JP13694495 A JP 13694495A JP 3445873 B2 JP3445873 B2 JP 3445873B2
Authority
JP
Japan
Prior art keywords
data
memory
read
cache
instruction
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP13694495A
Other languages
Japanese (ja)
Other versions
JPH0855025A (en
Inventor
哲彦 岡田
修 西井
博 武田
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hitachi Ltd
Original Assignee
Hitachi 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 filed Critical Hitachi Ltd
Priority to JP13694495A priority Critical patent/JP3445873B2/en
Publication of JPH0855025A publication Critical patent/JPH0855025A/en
Application granted granted Critical
Publication of JP3445873B2 publication Critical patent/JP3445873B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/08Addressing or allocation; Relocation in hierarchically structured memory systems, e.g. virtual memory systems
    • G06F12/0802Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches
    • G06F12/0862Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches with prefetch
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/30Arrangements for executing machine instructions, e.g. instruction decode
    • G06F9/38Concurrent instruction execution, e.g. pipeline or look ahead
    • G06F9/3824Operand accessing
    • G06F9/383Operand prefetching
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/10Providing a specific technical effect
    • G06F2212/1016Performance improvement
    • G06F2212/1024Latency reduction
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/60Details of cache memory
    • G06F2212/6028Prefetching based on hints or prefetch instructions

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Memory System Of A Hierarchy Structure (AREA)
  • Advance Control (AREA)
  • Executing Machine-Instructions (AREA)
  • Memory System (AREA)

Description

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

【0001】[0001]

【産業上の利用分野】本発明は、データと他のデータの
アドレスをそれぞれ含む複数の要素データからなる、い
わゆるポインタ型のデータ構造に含まれるデータをプリ
フェッチする方法およびそのための情報処理装置に関す
る。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a method of prefetching data contained in a so-called pointer type data structure, which is composed of a plurality of element data each containing data and addresses of other data, and an information processing apparatus therefor.

【0002】[0002]

【従来の技術】プロセッサの高性能化に対しメモリの高
速化が追従できないため、キャッシュメモリを用いて情
報処理装置の高性能化を図る方法が良く用いられる。し
かし、キャッシュメモリはメインメモリの一部のコピー
を保持するだけであり、読み出したいデータがキャッシ
ュメモリに存在しないことがある(キャッシュミス)。こ
のときメインメモリからデータを読み出すまでプロセッ
サは次の動作を開始することができず、オーバヘッドサ
イクルを生じる。このオーバヘッドをなくすためにいろ
いろな方法が考案されており、その一つにデータプリフ
ェッチ方法がある。これはキャッシュミスを起こしそう
なデータを、そのデータを使う前に予めキャッシュに読
み込んでおくというアイデアである。この際、メインメ
モリからキャッシュへのデータのプリフェッチを他の処
理を並行して実行することにより情報処理装置の高性能
化を図ることができる。
2. Description of the Related Art Since the speeding up of memory cannot keep up with the high performance of a processor, a method of improving the performance of an information processing apparatus using a cache memory is often used. However, the cache memory only holds a part of the main memory copy, and the data to be read may not exist in the cache memory (cache miss). At this time, the processor cannot start the next operation until the data is read from the main memory, resulting in an overhead cycle. Various methods have been devised to eliminate this overhead, and one of them is the data prefetch method. The idea is to read the data that is likely to cause a cache miss into the cache before using the data. At this time, the performance of the information processing apparatus can be improved by prefetching data from the main memory to the cache and executing other processing in parallel.

【0003】このデータプリフェッチ方法に関しては、
文献1:キャラハン他著「ソフトウエアプリフェッチン
グ」(ASPLOS-IVプロシーディング、1991年、40-52頁(D
avidCallahan, et. al., "Software Prefetching," ASP
LOS-IV Proceedings, April1991, pp.40-52)は、過去
にすでに知られているハードウエアプリフェッチングを
説明した上で、それより優れものとしてソフトウエア
によるプリフェッチングを提案している。例えば、ハー
ドウエアプリフェッチングとしてすでに知られているも
のは、例えば、キャッシュ内にいずれかのラインの最後
のアドレスがアクセスされたときに、次のラインをプリ
フェッチする回路を使用することである。これに対し
て、ソフトウエアによるプリフェッチングは、後にソフ
トウエアによりアクセスされることが予想されるデータ
をそのアクセスがなされる前に、プリフェッチしてキャ
ッシュに格納する命令を実行する。
Regarding this data prefetch method,
Reference 1: Callahan et al., "Software Prefetching" (ASPLOS-IV Proceedings, 1991, pp. 40-52 (D
avidCallahan, et. al., "Software Prefetching," ASP
LOS-IV Proc ee dings, April1991 , pp.40-52) is on describing the hardware prefetching known already in the past, we have proposed prefetching by software as being superior to that . For example, what is already known as hardware prefetching is the use of circuitry to prefetch the next line, for example, when the last address of any line is accessed in the cache. On the other hand, prefetching by software executes an instruction for prefetching and storing the data in the cache before the data that is expected to be accessed by software later is accessed.

【0004】上記文献1は、このようなソフトウエアに
よるプリフェッチングを、例えば、配列型のデータ構造
に適用できることを示している。配列型のデータ構造
は、連続した、あるいは一定のアドレス間隔で隔たった
複数のアドレスの記憶位置に保持されたデータからな
る。このため、次にフェッチすべきデータのアドレス
を、その配列型のデータ構造の先頭のデータのアドレス
と、上記アドレス間隔を用いて、配列型のデータ構造を
現に読み出す前に決定することが出来る。このため、次
に読み出すべきデータを予めソフトウエアから指示する
ことが出来ることによってキャッシュに読み込んでおく
ことが可能になる。
The above-mentioned document 1 shows that such prefetching by software can be applied to, for example, an array type data structure. The array-type data structure is composed of data held in storage locations of a plurality of addresses which are continuous or are separated by a constant address interval. Therefore, the address of the data to be fetched next can be determined by using the address of the head data of the array-type data structure and the address interval before actually reading the array-type data structure. Therefore, it is possible to keep read into cache by to be able to direct the data to be read next in advance from the software.

【0005】このような配列型のデータ構造をプリフェ
チするためのハードウエアも別に提案されている。例
えば、文献2:「お茶の水1号の構成と評価」、情報処
理学会研究報告、計算機アーキテクチャ101−8、19
93.8.20、pp.57-64では、プロセッサが配列型のデータ構
造を使用するタイミングより前に、その配列型のデータ
構造をメインメモリから読み出し、キャッシュとは別に
設けたプリフェッチ用のバッファメモりに格納し、後に
そのプロセッサが、その配列型のデータ構造内のいずれ
かの要素データを処理するときに、その要素をそのプリ
フェッチ用のバッファから読み出す。これによりプロセ
ッサが主記憶からこの配列データを読み出す時間がその
プロセッサには見えないようにしている。
The array-type data structure as described above is used as a reference.
Hardware for the pitch has also been proposed separately. For example, Reference 2: “Structure and Evaluation of Ochanomizu No. 1,” Information Processing Society of Japan, Research Report, Computer Architecture 101-8, 19
In 93.8.20, pp.57-64, before the timing when the processor uses the array type data structure, the array type data structure is read from the main memory, and a buffer memory for prefetch provided separately from the cache is provided. When the processor processes any element data in the array type data structure, the element is read from the prefetch buffer. This prevents the processor from seeing the time when the array data is read from the main memory.

【0006】配列型のデータ構造と同様にソフトウエア
でよく用いられる他のデータ構造として、ポインタで連
結された構造を有するポインタ型のデータ構造がある。
このデータ構造の、ソフトウエアから見た構成を図6に
示し、メインメモリ上に配置されたこの型のデータ構造
の例を図7に示す。このようなデータ構造を構成する各
要素データ10、20、30は、それぞれ複数のエント
リ11から14、21から24、31から34を含み、
各要素データは、一つのエントリ、例えば、11,21
または31に、後続の要素データを指定するポインタを
含んでいる。このポインタは、図7の例では、後続の要
素データのアドレスそのものである。
As another data structure often used in software similar to the array type data structure, there is a pointer type data structure having a structure connected by pointers.
The software structure of this data structure is shown in FIG. 6, and an example of this type of data structure arranged in the main memory is shown in FIG. Each element data 10, 20, 30 constituting such a data structure includes a plurality of entries 11 to 14, 21 to 24, 31 to 34, respectively.
Each element data has one entry, for example, 11,21.
Alternatively, 31 includes a pointer for designating subsequent element data. In the example of FIG. 7, this pointer is the address itself of the subsequent element data.

【0007】このような、ポインタ型データ構造に属す
る複数の要素データをメモリ90から読み出す場合、ま
ず、先頭の要素データ、例えば、10をメモリ90から
読み出すロード命令を先ず実行し、それにより、この先
頭の要素データをメモリから読み出す。次に、その要素
データのエントリ12から14に含まれたデータを処理
する複数の命令を実行する。さらに、先頭のエントリ1
1に含まれる、第2番目の要素データのアドレスを有す
る記憶位置から、次の要素データをフェッチするための
ロード命令を発行する。したがって、先頭の要素データ
以外の要素データのアドレスは、直前の要素データをメ
モリからフェッチして初めて判明する。
When reading a plurality of element data belonging to such a pointer type data structure from the memory 90, first, a load instruction for reading the first element data, for example, 10 from the memory 90 is first executed, whereby The top element data is read from the memory. Next, a plurality of instructions for processing the data included in the entries 12 to 14 of the element data are executed. Furthermore, the first entry 1
A load instruction for fetching the next element data is issued from the storage location having the address of the second element data included in 1. Therefore, the address of the element data other than the element data at the head is not known until the immediately preceding element data is fetched from the memory.

【0008】[0008]

【発明が解決しようとする課題】このため、上記文献1
に示されたソフトウエアプリフェッチングの方法では、
ポインタ型のデータ構造に対してはプリフェッチの効果
はあまり期待できない。また、上記文献2は、ハードウ
エアプリフェッチングを配列データに対して実行する方
法を説明しているが、ポインタ型データ構造あるいは他
のデータ構造に対してハードウエアフェッチングをどの
ように実行できるかを示していない。結局、従来技術で
は、ポインタ型データ構造をプリフェッチする技術は知
られていなかった。
Therefore, the above-mentioned document 1
The software prefetching method shown in
The effect of prefetching cannot be expected so much for pointer type data structures. Further, the above-mentioned Document 2 describes a method of executing hardware prefetching on array data, but how can hardware fetching be executed on a pointer type data structure or another data structure? Not shown. After all, in the related art, the technique of prefetching the pointer type data structure has not been known.

【0009】ポインタ型データ構造は、リスト処理言語
で記述されたプログラムにより頻繁に使用されるだけで
なく、OSによってもよく使用される。したがって、O
Sの実行速度を増大するには、このポインタ型データ構
造をフェッチするのに要する時間を改善することが望ま
しい。
Pointer type data structures are not only frequently used by programs written in the list processing language, but also often by the OS. Therefore, O
To increase the execution speed of S, it is desirable to improve the time required to fetch this pointer type data structure.

【0010】本発明の目的は、ポインタ型データ構造を
プリフェッチする方法およびそのための情報処理装置を
提供することである。
An object of the present invention is to provide a method of prefetching a pointer type data structure and an information processing apparatus therefor.

【0011】[0011]

【課題を解決するための手段】 本発明によるデータプリ
フェッチ方法では、データを保持するメモリから第1の
データの読み出しを要求する第1の命令が処理装置で実
行されたとき、該メモリの第1の記憶位置から該第1の
データを読み出し、読み出された第1のデータを該処理
装置に供給し、該第1の命令が、上記第1のデータが該
メモリに保持された第2のデータのアドレス情報を含む
ときに含まれるべき特定の情報が該第1の命令に含まれ
ているとき、上記読み出された第1のデータにて定ま
る、該メモリの第2の記憶位置から該第2のデータをプ
リフェッチし、該プリフェッチされた第2のデータを一
時的に保持し、該第2のデータが該メモリから読み出さ
れた後に該処理装置で実行された第2の命令が該メモリ
からの該第2のデータの読み出しを要求したとき、その
保持された第2のデータを該処理装置に供給する。
In a data prefetch method according to the present invention, when a first instruction requesting reading of first data from a memory holding data is executed by a processing device, the first prefetch of the memory is performed. Read the first data from the storage location, supply the read first data to the processing device, and the first instruction causes the second data in which the first data is held in the memory. When the specific information to be included when including the address information of the data is included in the first instruction, the first instruction read from the second storage position of the memory, which is determined by the first data read, Prefetching the second data, temporarily holding the prefetched second data, and executing a second instruction executed by the processing device after the second data is read from the memory. The second day from memory When requesting the read, and supplies the second data that is held in the processing apparatus.

【0012】より具体的には、上記第1の命令がロード
命令であり、上記プリフェッチでは、その命令の中の特
定のフィールドに含まれたポインタヒント情報が、その
命令でロードするデータが、他のデータをロードするた
めのポインタを含むことを示すときに、そのロード命令
でロードされるデータを用いて、他のデータをプリフェ
ッチする。
More specifically, the first instruction is a load instruction, and in the prefetch, the pointer hint information contained in a specific field in the instruction is the data to be loaded by the instruction. Other data is prefetched using the data loaded by the load instruction when indicating that it includes a pointer for loading the other data.

【0013】[0013]

【作用】メモリからデータを読み出すことを要求する命
令が実行されたときに、そのデータが他のデータのアド
レス情報を含む場合に、その命令の要求に従ってメモリ
から読み出されたデータを使用して他のデータを読み出
すことが出来る。もともと、この命令を含むプログラム
は、いずれの命令によりメモリから読み出されるデータ
が他のデータに対するポインタであるか否かを知ってい
る。したがって、本発明によれば、ポインタを指定する
ロード命令の実行を契機として、そのポインタが指定す
る他のデータをプリフェッチするので、プリフェッチす
るタイミングを簡単に決めることが出来る。しかも、こ
のような一つの命令を実行する毎に、その命令の後続の
命令が使用するデータをプリフェッチするので、プリフ
ェッチに必要な回路が簡単になる。さらに、プリフェッ
チされたデータは使用されることが多くの場合確実であ
るので、プリフェッチされた後使用されることがないと
いうことが起こる可能性は高くはないので、プリフェッ
チ処理が無駄になる可能性は少ない。
When the instruction that requests to read the data from the memory is executed and the data includes the address information of other data, the data read from the memory according to the request of the instruction is used. Other data can be read. Originally, the program including the instruction is read out from the memory Lud over data knows whether pointers to other data by any instructions. Therefore, according to the present invention, the execution of the load instruction designating the pointer is used to prefetch other data designated by the pointer, so that the timing of prefetching can be easily determined. Moreover, each time such one instruction is executed, the data used by the instruction subsequent to the instruction is prefetched, so that the circuit required for prefetching becomes simple. In addition, because prefetched data is often certain to be used, it is unlikely that it will never be used after it has been prefetched, so prefetching can be wasted. Is few.

【0014】[0014]

【実施例】以下、本発明に係るデータプリフェッチ方法
を図面に示したいくつかの実施例を参照してさらに詳細
に説明する。なお、以下においては、同じ参照番号は同
じものもしくは類似のものを表わすものとする。
DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS The data prefetch method according to the present invention will be described in more detail below with reference to some embodiments shown in the drawings. In the following, the same reference numbers represent the same or similar items.

【0015】<実施例1> 図1において、600はプロセッサであり、700は、
メインメモリ、100はメモリインタフェース回路であ
る。
<First Embodiment> In FIG. 1, 600 is a processor, and 700 is
A main memory, 100 is a memory interface circuit.

【0016】プロセッサ600は、CPU610と、キ
ャッシュ620と、キャッシュ制御回路630を有す
る。CPU610は、後に説明するように、データのプ
リフェッチのためにポインタヒント情報を含むロード命
令を実行可能になっていて、線609を介してこのポイ
ンタヒント情報をメモリインタフェース回路100に供
給するようになっている。
The processor 600 has a CPU 610, a cache 620, and a cache control circuit 630. As will be described later, the CPU 610 can execute a load instruction including pointer hint information for prefetching data, and supplies the pointer hint information to the memory interface circuit 100 via the line 609. ing.

【0017】メモリインタフェース回路(100)は、
プロセッサインタフェース回路200、I/Oバスイン
タフェース回路400、プリフェッチ回路300および
メモリアクセス調停回路500を有する。プロセッサイ
ンタフェース回路200は、バス601、制御信号線6
03、ヒント信号線609を介してプロセッサ600に
接続され、プロセッサ600からのメインメモリ700
に対するアクセス要求を受け付け、メモリアクセス調停
回路500に供給する。I/Oバスインタフェース回路
400は、バス801を介してI/O制御回路800、
810に接続され、I/O制御回路800、810から
メインメモリアクセス要求を受け付け、メモリアクセス
調停回路500に供給する。プリフェッチ回路300
は、本実施例に特徴的な回路で、メモリインタフェース
回路200で受け付けられたロード命令が要求するデー
タが、他のデータに対するポインタであるときに、この
ロード命令が要求するデータがメインメモリ700から
読み出された時点で、その読み出されたデータを利用し
て、他のデータをプリフェッチする回路である。メモリ
アクセス調停回路500は、アドレスバス701、デー
タバス702、制御信号線703を介してメインメモリ
700に接続され、プロセッサインタフェース回路20
0、プリフェッチ回路300から与えられるメモリアク
セス要求の一つを選択してメインメモリ700に供給す
る。メインメモリに対するリード/ライト処理は通常ブ
ロック単位に行われるため、以下では、メモリリードと
メモリライトはメインメモリに対してはブロック単位に
行われるものとする。
The memory interface circuit (100) is
It has a processor interface circuit 200, an I / O bus interface circuit 400, a prefetch circuit 300, and a memory access arbitration circuit 500. The processor interface circuit 200 includes a bus 601, a control signal line 6
03, the main memory 700 connected to the processor 600 via the hint signal line 609.
To the memory access arbitration circuit 500. The I / O bus interface circuit 400 is connected to the I / O control circuit 800,
Is connected to 810, Installing receives main memory access requests from the I / O control circuit 800 and 810, and supplies to the memory access arbitration circuit 500. Prefetch circuit 300
Is a circuit characteristic of this embodiment. When the data requested by the load instruction accepted by the memory interface circuit 200 is a pointer to other data, the data requested by the load instruction is transferred from the main memory 700. It is a circuit for prefetching other data using the read data at the time of reading. The memory access arbitration circuit 500 is connected to the main memory 700 via an address bus 701, a data bus 702, and a control signal line 703, and the processor interface circuit 20.
0, one of the memory access requests given from the prefetch circuit 300 is selected and supplied to the main memory 700. Since the read / write processing for the main memory is normally performed in block units, memory read and memory write are hereinafter performed in block units for the main memory.

【0018】(CPU) 本実施例では、CPU610で実行する命令としては、
例えば、ヒユーレットパッカード社発行のマニュアル"P
A-RISC 1.1 Architecture and Instruction Set Refere
nce Manual, Third Edition," Hewlet-Packard, Feb. 1
994 に記載の命令を使用できる。とくに、本実施例で
は、メモリデータをロードする命令として、上のマニュ
アルの第5−42頁に記載のロードワードショート(L
DWS)命令を使用できる。この命令40は、図8に示
すフォーマットを有し、フィールド50から59を有し
ている。フィールド50は命令コードを保持し、この命
令は、フィールド52に保持された5ビットのイミディ
エイトデータIM5をサイン拡張した値とフィールド5
1に保持される汎用レジスタ(図示せず)の内容との和
をメモリアドレスとして有するデータをメインメモリか
ら読み込み、フィールド59により示される汎用レジス
タに格納することを要求する。上記マニュアルの第5−
17頁から5−18頁によれば、フィールド56のcc
はキャッシュコントロールヒントビットと呼ばれる2ビ
ットからなり、その値が2のときには、空間局在(Spat
ial Locality)のヒントとして使用されているが、その
値が1あるいは3のときの用途はまだ定義されていな
い。このヒントビットの値が0の時には、ヒントがない
ものとして扱われる。したがって、本実施例では、従来
のロード命令として、このフォーマットの命令を使用す
るときには、このヒントの値を0にする。しかし、この
フォーマットの命令を本実施例で特徴的なプリフェッチ
も行うロード命令に使用するときには、このヒントの値
を、例えば、1にする。したがって、CPU610はこ
の命令を実行したときには、このヒントの値を線609
を介してメモリインタフェース回路100に出力するよ
うに構成されている。すなわち、ロード命令がロードし
ようとするデータがポインタ、すなわち、他のデータの
アドレスに関連するデータであり、当該他のデータをア
ドレスとしてプリフェッチすることを要求するときに
は、このヒントの値を1にする。以下では、命令のこの
ヒントをポインタヒント呼び、このようなプリフェッチ
を要求するポインタヒントを有するロード命令をポイン
タヒント付ロード命令と呼び、このようなプリフェッチ
を要求しないポインタヒントを有するロード命令をポイ
ンタヒントなしロード命令と呼ぶことがある。
(CPU) In this embodiment, the instructions executed by the CPU 610 are:
For example, the manual "P published by Hewlett Packard
A-RISC 1.1 Architecture and Instruction Set Refere
nce Manual, Third Edition, "Hewlet-Packard, Feb. 1
You can use the instructions listed in 994. In particular, in this embodiment, the load word short (L) described on page 5-42 of the above manual is used as the instruction to load the memory data.
DWS) instruction can be used. This instruction 40 has the format shown in FIG. 8 and has fields 50 to 59. The field 50 holds an instruction code, and this instruction is a value obtained by sign-extending the 5-bit immediate data IM5 held in the field 52 and the field 5
Requests that data having a sum of the contents of a general-purpose register (not shown) held in 1 as a memory address be read from the main memory and stored in the general-purpose register indicated by the field 59. 5th of the above manual
According to pages 17 to 5-18, cc of field 56
Consists of 2 bits called cache control hint bits. When the value is 2, spatial localization (Spat
It is used as a hint of (ial Locality), but when the value is 1 or 3, its use is not yet defined. When the value of this hint bit is 0, it is treated as having no hint. Therefore, in this embodiment, when the instruction of this format is used as the conventional load instruction, the value of this hint is set to 0. However, when an instruction of this format is used as a load instruction that also performs prefetch characteristic of this embodiment, the value of this hint is set to 1, for example. Therefore, when the CPU 610 executes this instruction, it outputs the value of this hint to the line 609.
It is configured to output to the memory interface circuit 100 via the. That is, when the data to be loaded by the load instruction is a pointer, that is, data related to the address of other data, and the prefetching of the other data is requested as an address, the value of this hint is set to 1. . In the following, this hint of an instruction is called a pointer hint, a load instruction with a pointer hint that requires such prefetch is called a load instruction with a pointer hint, and a load instruction with a pointer hint that does not require such prefetch is a pointer hint. None Sometimes called load instruction.

【0019】なお、CPU610は、従来技術と同様
に、メモリから読み出すべきデータのアドレスを計算
し、このアドレスとリード要求をキャッシュ制御回路6
30に供給する。本実施例では、CPUがキャッシュ制
御回路630に供給するメモリアドレスは、メインメモ
リ700の実アドレスを指し、また、いずれかのロード
命令でメインメモリ700から読みだされたデータが他
のデータのアドレスであるとき、そのデータは当該他の
データの実アドレスを指すと仮定する。また、CPUは
同様なフォーマットを有するストア命令も実行するがそ
の説明は省略する。
The CPU 610 calculates the address of the data to be read from the memory and outputs this address and the read request, as in the prior art.
Supply to 30. In the present embodiment, the memory address supplied by the CPU to the cache control circuit 630 indicates the real address of the main memory 700, and the data read from the main memory 700 by any load instruction is the address of other data. , It is assumed that the data points to the real address of the other data. The CPU also executes a store instruction having a similar format, but its description is omitted.

【0020】(キャッシュ制御回路630) キャッシュ制御回路630は、それ自体公知のものと同
様に動作する。すなわち、CPU610がメインメモリ
700内のいずれかのアドレスにあるデータに対するロ
ード命令あるいはストア命令のごとくメインメモリへの
アクセスを要求する命令を実行したときに、そのデータ
に関するリード要求あるいはライト要求をキャッシュ制
御回路630に供給する。キャッシュ制御回路630
は、その命令が指定するデータに関して、キャッシュ6
20についてヒットチェックを行い、このデータに関し
てキャッシュ620がヒットすれば、その命令がロード
命令であるときには、その命令により要求されたデータ
をキャッシュ620から読み出し、CPU610に供給
し、その命令がストア命令のとき、キャッシュ620に
その命令が指定するデータを書き込む。上記ヒットチェ
ックの結果、キャッシュがミスしたときには、キャッシ
ュ制御回路620は、その実行された命令がロード命令
のときには、制御線603とバス601を介して、ロー
ドすべきメモリアドレスを含むリード要求をメモリイン
タフェース回路100に供給する。後に、このリード要
求に対する応答として、メモリインタフェース回路10
0から要求したデータを含むブロックが供給されたとき
には、そのブロック内の、要求したデータをCPU61
0に転送するとともに、そのブロックをキャッシュ62
0に書き込む。実行された命令がストア命令の場合に
は、CPU610から送られてきた書き込みデータとス
トアアドレスを含むライト要求をメモリインタフェース
回路100に供給する。
(Cache Control Circuit 630) The cache control circuit 630 operates in the same manner as that known per se. That is, when the CPU 610 executes an instruction requesting access to the main memory, such as a load instruction or a store instruction for data at any address in the main memory 700, cache control of a read request or a write request for the data is executed. Supply to the circuit 630. Cache control circuit 630
Cache 6 for the data specified by the instruction.
20 is hit-checked, and if the cache 620 hits for this data, if the instruction is a load instruction, the data requested by the instruction is read from the cache 620 and supplied to the CPU 610. At this time, the data specified by the instruction is written in the cache 620. As a result of the hit check, when the cache miss occurs, the cache control circuit 620 issues a read request including a memory address to be loaded to the memory via the control line 603 and the bus 601 when the executed instruction is a load instruction. It is supplied to the interface circuit 100. Later, as a response to the read request, the memory interface circuit 10
When a block containing the requested data is supplied from 0, the requested data in the block is transferred to the CPU 61.
0 and transfers the block to the cache 62
Write to 0. When the executed instruction is the store instruction, the write request including the write data and the store address sent from the CPU 610 is supplied to the memory interface circuit 100.

【0021】(メモリインタフェース回路100) 以下では、プロセッサ600から供給されたリード要求
に対するメモリインタフェース回路100の動作を説明
する。ライト要求に対する処理はこれから類推が容易な
ので、本実施例の理解に必要な範囲で説明するに止め
る。
(Memory Interface Circuit 100) The operation of the memory interface circuit 100 in response to a read request supplied from the processor 600 will be described below. Since the process for the write request can be easily analogized from now on, the description will be limited to the range necessary for understanding the present embodiment.

【0022】(メモリリード動作) メモリインタフェース回路100は、メモリリードを行
うときには、メインメモリ700を制御信号線703を
介して制御し、メインメモリ700からデータを読み出
し、読み出したデータをリード要求元に返す。
(Memory Read Operation) When performing a memory read, the memory interface circuit 100 controls the main memory 700 via the control signal line 703 to read data from the main memory 700 and use the read data as a read request source. return.

【0023】メモリインタフェース回路100は、プロ
セッサ600からのリード要求を受けるとリード要求信
号p−rd201をハイにすることによってメモリアク
セス調停回路500に対し内部バス105、106のバ
ス権を要求する。メモリアクセス調停回路500は調停
を行い、バス権獲得信号p−gntを線203に出力す
ることによって、バス権をプロセッサインタフェース回
路200に渡す。プロセッサインタフェース回路200
は、線203を介してバス権獲得信号p−gntを受け
ると次のサイクルでアドレスバス105を介して、プロ
セッサ600から与えられた読み出しアドレスをメモリ
アクセス調停回路500に渡す。メモリアクセス調停回
路500は、このアドレスでメインメモリ700を読み
出し、データバス106を介してプロセッサインタフェ
ース回路200に転送する。この時、メモリアクセス調
停回路500は、データ有効信号p−vldを線504
に出力する。この信号はさらにORゲート260、線2
04を介してプロセッサインタフェース回路200に供
給され、それにより、データバス106上のデータが有
効であることをこの回路200に通知する。プロセッサ
インタフェース回路200は、このデータ有効信号p−
vldに応答して、データバス106上のデータを取り
込み、プロセッサ600に転送する。メモリアクセス調
停回路500とプロセッサインタフェース回路200と
は、この読み出しアドレスを有するデータが属するブロ
ックの他の複数のデータ、本実施例では3つのデータを
さらに読み出すように、上と同じ動作を繰り返す。こう
して、メモリアクセス調停回路500とプロセッサイン
タフェース回路200との間では、4つのデータが順次
転送され、それらに対して合計4つのデータ有効信号が
前者から後者に与えられることになる。こうして、プロ
セッサインタフェース回路200とメモリアクセス調停
回路500はリード処理を終了する。この動作は基本的
には、従来のメモリインタフェース回路あるいはメモリ
アクセス調停回路500と同じである。
Upon receiving a read request from the processor 600, the memory interface circuit 100 requests the memory access arbitration circuit 500 for the bus right of the internal buses 105 and 106 by setting the read request signal p-rd201 to high. The memory access arbitration circuit 500 performs arbitration and outputs the bus right acquisition signal p-gnt to the line 203, thereby passing the bus right to the processor interface circuit 200. Processor interface circuit 200
When the bus right acquisition signal p-gnt is received via the line 203, it transfers the read address given from the processor 600 to the memory access arbitration circuit 500 via the address bus 105 in the next cycle. The memory access arbitration circuit 500 reads the main memory 700 at this address and transfers it to the processor interface circuit 200 via the data bus 106. At this time, the memory access arbitration circuit 500 sends the data valid signal p-vld to the line 504.
Output to. This signal is also OR gate 260, line 2
Is supplied to the processor interface circuit 200 via 04, thereby informing the circuit 200 that the data on the data bus 106 is valid. The processor interface circuit 200 receives the data valid signal p-
In response to vld, the data on the data bus 106 is fetched and transferred to the processor 600. The memory access arbitration circuit 500 and the processor interface circuit 200 repeat the same operation as above so as to further read a plurality of other data in the block to which the data having this read address belongs, that is, three data in this embodiment. In this way, four data are sequentially transferred between the memory access arbitration circuit 500 and the processor interface circuit 200, and a total of four data valid signals are given to them from the former to the latter. In this way, the processor interface circuit 200 and the memory access arbitration circuit 500 complete the read process. This operation is basically the same as the conventional memory interface circuit or memory access arbitration circuit 500.

【0024】(メモリライト動作) ライト処理ではメモリインタフェース回路100はメイ
ンメモリ700を制御信号線703を介して制御し、ラ
イト要求元から渡されるデータをメインメモリ700に
書き込む。すなわち、ライト処理ではプロセッサインタ
フェース回路200は、リード要求信号p−rdの代わ
りにライト要求信号p−wrをハイにし、バス権獲得信
号p−gntを受けると次のサイクルでアドレスバス1
05を介してアドレスを転送し、続く4サイクルにデー
タバス106を介してデータをメモリアクセス調停回路
500に転送することでライト処理を終了する。
(Memory Write Operation) In the write processing, the memory interface circuit 100 controls the main memory 700 via the control signal line 703 to write the data passed from the write request source in the main memory 700. That is, in the write processing, the processor interface circuit 200 makes the write request signal p-wr high instead of the read request signal p-rd, and when the bus right acquisition signal p-gnt is received, the address bus 1 in the next cycle.
The address is transferred via 05, and the data is transferred to the memory access arbitration circuit 500 via the data bus 106 in the following 4 cycles, thereby ending the write processing.

【0025】プロセッサインタフェース回路200は、
後に述べる遅延回路250に制御信号を与えるように構
成されている点でのみ従来技術のものと異なるのみであ
る。また、メモリアクセス調停回路500の機能は、従
来技術で使用されているものと基本的に同じであるが、
本実施例では、プロセッサインタフェース回路200、
I/Oバスインタフェース回路400からのメモリアク
セス要求に加えて、プリフェッチ回路300からのメモ
リアクセス要求を調停するように構成されている点、お
よび後に説明するように、プロセッサインタフェース回
路200からのメモリリード要求によりメモリをアクセ
スした後に、プリフェッチ回路300から、プリフェッ
チヒット信号pf−hitが線302より与えられたと
きに、このメモリリード動作を無効とするように構成さ
れている点で、従来技術のメモリ調停回路と異なる。
The processor interface circuit 200 includes
It differs from the prior art only in that it is configured to provide a control signal to a delay circuit 250 described later. The function of the memory access arbitration circuit 500 is basically the same as that used in the prior art,
In this embodiment, the processor interface circuit 200,
It is configured to arbitrate the memory access request from the prefetch circuit 300 in addition to the memory access request from the I / O bus interface circuit 400, and, as will be described later, a memory read from the processor interface circuit 200. after access to memory by request from the prefetch circuit 300, when the prefetch hit signal p f-h it is given from the line 302, in that it is configured to invalidate the memory read operation, the prior art Different from the memory arbitration circuit.

【0026】(プリフェッチ回路300) 本実施例のメモリインタフェース回路100が従来のメ
モリインタフェース回路と主に異なっている点は、プロ
セッサ600とヒント信号線609で接続され、このヒ
ント信号線609上のポインタヒント情報を基にプリフ
ェッチを行うプリフェッチ回路300を持つ点である。
(Prefetch Circuit 300) The memory interface circuit 100 of the present embodiment is mainly different from the conventional memory interface circuit in that it is connected to the processor 600 by a hint signal line 609, and a pointer on this hint signal line 609. The point is to have a prefetch circuit 300 that performs prefetch based on hint information.

【0027】プロセッサインタフェース回路200は、
ディレイ回路250を信号線208を介して制御し、メ
モリアクセス調停回路500にリード要求信号p−rd
201を出すのと同じタイミングでヒント信号線609
のヒント信号を線209を介してプリフェッチ回路30
0に伝える。
The processor interface circuit 200 is
The delay circuit 250 is controlled via the signal line 208, and the read request signal p-rd is sent to the memory access arbitration circuit 500.
Hint signal line 609 at the same timing as issuing 201
The hint signal of the prefetch circuit 30 via the line 209.
Tell 0.

【0028】プリフェッチ回路300はこのヒント信号
209がポインタ付きヒントのとき、すなわち、その信
号の1のときに、後に詳述するようにプロセッサインタ
フェース回路200のリード処理により読み出されたデ
ータをアドレスとして使用して、メインメモリ700に
リード要求を出し、そのアドレスのデータを含むブロッ
クをプリフェッチし、プリフェッチ回路300内に一時
的に保持するようになっている。その後、プリフェッチ
回路300、CPU600によりその後実行された後続
のロード命令あるいはストア命令に起因して、リード要
求p−rdあるいはライト要求p−wrがプロセッサイ
ンタフェース回路200により出力されたか否かを監視
する。このリード要求p−rdあるいはライト要求p−
wrが出力されたときに、その時アドレスバス105に
出力された読み出しアドレスもしくは書き込みアドレス
の内、ブロックアドレス部分が、プリフェッチしたブロ
ックのアドレスと一致するかを判別する。もし、一致が
検出された場合に、その要求がリード要求のときには、
プリフェッチ回路200内に保持されたプリフェッチさ
れたブロックをプロセッサインタフェース回路200を
介してプロセッサに供給する。これにより、そのリード
要求により要求されたデータがメインメモリ700より
読み出されるより前に、そのデータに代えて、プリフェ
ッチされたデータを、プロセッサ600に供給可能にし
ている。また、その要求がライト要求の場合には、プリ
フェッチされたブロックを無効とする。この場合には、
メインメモリ上のデータが書き換えられるので、プリフ
ェッチされたブロックは、書き換え前の古いブロックに
なるからである。
When the hint signal 209 is a hint with a pointer, that is, when the hint signal 209 is 1, the prefetch circuit 300 uses the data read by the read process of the processor interface circuit 200 as an address as described later in detail. It is configured to issue a read request to the main memory 700, prefetch a block including the data of the address, and temporarily hold it in the prefetch circuit 300. Thereafter, it is monitored whether the read request p-rd or the write request p-wr is output by the processor interface circuit 200 due to the subsequent load or store instruction executed by the prefetch circuit 300 or the CPU 600. This read request p-rd or write request p-rd
When wr is output, it is determined whether the block address portion of the read address or write address output to the address bus 105 at that time matches the address of the prefetched block. If a match is detected and the request is a read request,
The prefetched block held in the prefetch circuit 200 is supplied to the processor via the processor interface circuit 200. As a result, before the data requested by the read request is read from the main memory 700, the prefetched data can be supplied to the processor 600 instead of the data. If the request is a write request, the prefetched block is invalidated. In this case,
This is because the data on the main memory is rewritten, and the prefetched block becomes the old block before rewriting.

【0029】以下図2から図5を用いてプリフェッチ回
路300およびその動作を詳細に説明する。図2はプリ
フェッチ回路300のブロック図である。
The prefetch circuit 300 and its operation will be described in detail below with reference to FIGS. FIG. 2 is a block diagram of the prefetch circuit 300.

【0030】(起動回路380) 起動回路380は、プロセッサインタフェース回路20
0から出力される、リード要求p−rd、ライト要求p
−wr、プロセッサ600からディレイ回路250(図
1)を経由して与えられるポインタヒントp−hin
t、およびメモリアクセス調停回路500から与えられ
るバス権獲得信号p−gnt、io−gntおよびI/
Oインタフェース回路400から与えられるライト要求
o−wrを監視して、書き込み制御回路回路350,
読み出し制御回路340,無効化制御回路360を選択
的に起動する。
(Starting Circuit 380) The starting circuit 380 is the processor interface circuit 20.
Read request p-rd and write request p output from 0
-Wr, pointer hint p-hin given from the processor 600 via the delay circuit 250 (FIG. 1)
t, and bus right acquisition signals p-gnt, i o-g nt and I / I provided from the memory access arbitration circuit 500.
By monitoring the write request i o-wr provided from the O interface circuit 400, the write control circuit circuit 350,
The read control circuit 340 and the invalidation control circuit 360 are selectively activated.

【0031】書き込み起動信号355は、プロセッサ6
00からのリード要求に対してプロセッサインタフェー
ス回路からリード要求p−rdが出力されている状態
で、さらに、プロセッサ600から与えられたポインタ
ヒント信号p−hintの値が1であり、かつ、メモリ
アクセス調停回路500がバス権獲得信号p−gntが
出力されたときに、すなわち、ポインタヒント付きロー
ド命令に起因するリード要求に対して、メモリアクセス
調停回路700がバス権をプロセッサインタフェース回
路200に与えたときに、ANDゲート385から出力
される。
The write start signal 355 is sent to the processor 6
00 in response to the read request p-rd from the processor interface circuit, the pointer hint signal p-hint given by the processor 600 has a value of 1, and the memory access The memory access arbitration circuit 700 gives the bus right to the processor interface circuit 200 when the arbitration circuit 500 outputs the bus right acquisition signal p-gnt, that is, in response to a read request caused by a load instruction with a pointer hint. Sometimes, it is output from the AND gate 385.

【0032】読み出し起動信号345は、プロセッサイ
ンタフェース回路200からのリード要求がバス権を獲
得したときにだけアンドゲート381から与えられる。
The read start signal 345 is given from the AND gate 381 only when the read request from the processor interface circuit 200 acquires the bus right.

【0033】無効化起動信号365は、プロセッサイン
タフェース回路200またはI/Oバスインタフェース
回路400からのライト要求がバス権を獲得したときに
だけ、ANDゲート382、384、ORゲート383
の組みにより与えられる。
The invalidation start signal 365 is output to the AND gates 382 and 384 and the OR gate 383 only when the write request from the processor interface circuit 200 or the I / O bus interface circuit 400 acquires the bus right.
Given by the set of.

【0034】(書き込み制御回路350) 図において、書き込み制御回路350は、プロセッサ6
00によりポインタヒント付きロード命令が実行された
ときに、このロード命令により読み出されたデートをメ
モリアドレスとして用いて、メインメモリ700からそ
のアドレスのデータが属するブロックをプリフェッチ
し、プリフェッチバッファ320に書き込む回路であ
る。
(Write Control Circuit 350) In the figure, the write control circuit 350 is the processor 6
When a load instruction with a pointer hint is executed by 00, the date read by this load instruction is used as a memory address to prefetch the block to which the data at that address belongs from the main memory 700 and write it in the prefetch buffer 320. Circuit.

【0035】すでに、メモリリード動作に関して説明し
たように、プロセッサインタフェース回路200は、プ
ロセッサ600からのリード要求に応答してメモリアク
セス調停回路500にリード要求p−rdおよびメモリ
アドレスを送り、この回路500はこのリード要求に応
答して、バス権獲得信号p−gntを返送するととも
に、メインメモリ700をアクセスして、複数、例え
ば、4つのデータおよそれぞれのデータに対するデータ
有効信号p−vldを返送する。
As described above with respect to the memory read operation, the processor interface circuit 200 sends the read request p-rd and the memory address to the memory access arbitration circuit 500 in response to the read request from the processor 600, and this circuit 500. Responds to the read request, returns a bus right acquisition signal p-gnt, accesses the main memory 700, and returns a plurality of data, for example, four data and a data valid signal p-vld for each data. To do.

【0036】同様に、書き込み制御回路350は、上記
プロセッサインタフェース回路200によりリード要求
p−rdが出力されたときに、プリフェッチをするため
のリード要求pf−rdをメモリアクセス調停回路50
0に線301を介して送るように構成されている。この
回路500は、このリード要求に応答して、上に述べた
リード要求p−rdに対すると同様に、バス権獲得信号
pf−gntを線303を介して返送するとともに、メ
インメモリ700をアクセスして、複数のデータをデー
タバス105に送出し、それぞれのデータに対するデー
タ有効信号pf−vldを線304を介して返送するよ
うに構成されている。
Similarly, the write control circuit 350 issues a read request pf-rd for prefetching to the memory access arbitration circuit 50 when the processor interface circuit 200 outputs the read request p-rd.
0 to line 0 through line 301. In response to the read request, the circuit 500 returns the bus right acquisition signal pf-gnt via the line 303 and accesses the main memory 700 in the same manner as the read request p-rd described above. Then, a plurality of data are sent to the data bus 105, and the data valid signal pf-vld for each data is sent back via the line 304.

【0037】より具体的には、書き込み制御回路350
では、書き込み起動信号355は、タイミング合わせの
ための1ビットラッチ3540が取り込まれた後、フリ
ップフロップ3570をセットする。このフリップフロ
ップ3570は、その出力を線357を介してレジスタ
310(図1)にセット信号として供給する。このフリ
ップフロップ3570は、後に、現在実行中のポインタ
ヒント付きロード命令に対してプロセッサインタフェー
ス回路200により出力されたリード要求に対して、メ
モリアクセス調停回路500からデータ有効信号p−v
ldが最初に線504に供給されたときに、この信号が
ORゲート3595を介してフリップフロップ3570
をリセットする。この信号は、その後も繰返し供給され
るが、フリップフロップ3570のリセットには影響し
ない。このフリップフロップ3570の出力信号357
がハイの間、レジスタ310は、データバス106上の
データを毎クロック取り込むようになっている。従っ
て、レジスタ310は、データ有効信号p−vldが最
初にメモリアクセス調停回路500により与えられた時
点でデータバス106に出力されていたデータ、すなわ
ち、今実行中のポインタヒント付きロード命令が要求し
たデータを最終的に取込み、その後このデータを保持す
ることになる。こうして、現在実行中のポインタ付きロ
ード命令により要求されたデータ、すなわち、他のデー
タのアドレスを示すポインタが、レジスタ310に取り
込まれる。
More specifically, the write control circuit 350.
Then, the write start signal 355 sets the flip-flop 3570 after the 1-bit latch 3540 for timing adjustment is fetched. This flip-flop 3570 supplies its output via line 357 to register 310 (FIG. 1) as a set signal. The flip-flop 3570 subsequently receives a data valid signal pv from the memory access arbitration circuit 500 in response to a read request output by the processor interface circuit 200 for a pointer instruction load instruction currently being executed.
When Id is first applied to line 504, this signal is passed through OR gate 3595 to flip-flop 3570.
To reset. This signal is repeatedly supplied thereafter, but does not affect the reset of the flip-flop 3570. Output signal 357 of this flip-flop 3570
While the signal is high, the register 310 takes in the data on the data bus 106 every clock. Therefore, the register 310 requests the data output to the data bus 106 at the time when the data valid signal p-vld is first given by the memory access arbitration circuit 500, that is, the load instruction with pointer hint currently being executed. You will eventually capture the data and then retain this data. In this way, the data requested by the load instruction with pointer currently being executed, that is, the pointer indicating the address of other data is fetched into the register 310.

【0038】このフリップフロップ3570の出力は、
次のサイクルでフリップフロップ3580をセットす
る。このフリップフロップ3580は、その出力を、プ
リフェッチを行うためのリード要求信号pf−rdとし
てメモリアクセス調停回路500に線301を介して供
給する。
The output of this flip-flop 3570 is
The flip-flop 3580 is set in the next cycle. The flip-flop 3580 supplies its output to the memory access arbitration circuit 500 via the line 301 as a read request signal pf-rd for performing prefetch.

【0039】このリード要求pf−rdに対してメモリ
アクセス調停回路500から線303を介してバス権獲
得信号pf−gntが返されると、このバス権利獲得信
号pf−gntは、タイミング調整用のラッチにセット
され、このラッチ3550は、その出力を線354を介
して、トライステートバッファ390(図2)に供給す
る。このバッファ390は、この線354上の信号に応
答して、レジスタ310(図2)に保持されているポイ
ンタをプリフェッチアドレスとして、アドレスバス10
5を介してメモリアクセス調停回路500に供給する。
こうして、このアドレスを有するデータのプリフェッチ
が開始される。このデータはメインメモリ700から読
み出されると、データバス106を介してプリフェッチ
バッファ320(図2)に供給される。
[0039] Once returned bus right acquisition signal pf-gnt via line 303 from the memory access arbitration circuit 500 with respect to the read request p f-r d, the bus right acquisition signal p f-g nt, the timing Set to the adjust latch, this latch 3550 provides its output on line 354 to tristate buffer 390 (FIG. 2). In response to the signal on this line 354, this buffer 390 uses the pointer held in the register 310 (FIG. 2) as a prefetch address and sets the address bus 10
5 to the memory access arbitration circuit 500.
Thus, prefetching of data having this address is started. When this data is read from the main memory 700, it is supplied to the prefetch buffer 320 (FIG. 2) via the data bus 106.

【0040】本実施例では、メインメモリ700からの
リードとライトは、ブロック単位に行われると仮定して
いる。従って、データのプリフェッチも、上のアドレス
のデータが属するブロックの他の複数のデータ、本実施
例では例えば、3つのデータも引き続いて順次メインメ
モリ700からデータバス106に読み出される。この
ことは、プロセッサインタフェース回路200からのメ
モリリード要求の場合と同じである。なお、先にアクセ
ス調停回路500から線303上に与えられたバス権獲
得信号pf−gntは、この信号がラッチ3550に到
着した時点で、フリップフロップ3580をリセット
し、このフリップフロップは、すでに出力しているリー
ド要求pf−rdの出力を停止する。
In the present embodiment, it is assumed that reading and writing from the main memory 700 are performed in block units. Therefore, also in the data prefetch, a plurality of other data in the block to which the data of the above address belongs, for example, three data in this embodiment are successively read from the main memory 700 to the data bus 106 in sequence. This is the same as the case of the memory read request from the processor interface circuit 200. Note that the bus right acquisition signal pf - gnt given on the line 303 from the access arbitration circuit 500 resets the flip-flop 3580 at the time when this signal arrives at the latch 3550, and this flip-flop The output of the read request pf-rd that has already been output is stopped.

【0041】メインメモリ700から読み出されたデー
タは、以下のようにして、プリフェッチバッファ320
に格納される。
The data read from the main memory 700 is stored in the prefetch buffer 320 as follows.
Stored in.

【0042】プリフェッチバッファ320は、同一のブ
ロックに属する複数のデータ、本実施例では4つのデー
タを保持するために、4つのレジスタからなる。これら
のレジスタにデータを書き込むための書き込みレジスタ
番号は、次のように生成される。セレクタ3520に
は、レジスタ310が保持するプリフェッチアドレスの
下位2ビットが、線346を介して、書き込みレジスタ
番号の初期値として供給される。セレクタ3520は、
ラッチ3550から供給される、トライステートバッフ
ァ390(図2)に対する出力指示信号354がハイの
ときには、この初期値346を選択し、この出力指示信
号がローのときには、ラッチ3560の出力を選択する
ように構成されている。このセレクタの出力359は、
2ビットインクリメンタ3510にも供給される。メイ
ンメモリアクセス調停回路500はメインメモリ700
より4つのデータの各々をデータバス160に送出する
毎に、線304を介して、データ有効信号pf−vld
を供給するように構成されている。
The prefetch buffer 320 is composed of four registers in order to hold a plurality of data belonging to the same block, that is, four data in this embodiment. Write register numbers for writing data to these registers are generated as follows. The lower 2 bits of the prefetch address held by the register 310 is supplied to the selector 3520 via the line 346 as the initial value of the write register number. The selector 3520 is
When the output instruction signal 354 supplied from the latch 3550 to the tri-state buffer 390 (FIG. 2) is high, this initial value 346 is selected, and when this output instruction signal is low, the output of the latch 3560 is selected. Is configured. The output 359 of this selector is
It is also supplied to the 2-bit incrementer 3510. The main memory access arbitration circuit 500 includes a main memory 700.
Each time four of the four pieces of data are sent to the data bus 160, the data valid signal pf -v ld is sent via the line 304.
Is configured to supply.

【0043】2ビットインクリメンタ3510は、デー
タ有効信号pf−vld304がハイのときセレクタ3
520から出力された書き込みレジスタ番号359を1
インクリメントし、ローのときはこの書き込みレジスタ
番号359をそのまま出力するように、構成されてい
る。セレクタ359の出力は、2ビットラッチ3560
に一度保持された後に、セレクタ3520に再度供給さ
れる。したがって、セレクタ3520は、先ず、バス権
獲得信号pf−gntがハイになり、それによりラッチ
3550の出力がハイになったときに、線346上の初
期レジスタ番号を選択する。この選択されたレジスタ番
号の初期値は、プリフェッチバッファ320に供給さ
れ、さらに2ビットインクリメンタ3510に供給され
る。この時点ではデータ有効信号pf−vldがまだロ
ーであるため、2ビットインクリメンタ3510は、こ
のレジスタ番号の初期値をそのままラッチ3520にセ
ットする。この時点では、ラッチ3550の出力はすで
にローになっているため、セレクタ3520は、ラッチ
3560の出力を書き込みレジスタ番号として選択し、
プリフェッチバッファ320に供給する。その後、デー
タ有効信号pf−vldがハイになるまで、セレクタ3
520は、この初期値を繰返しプリフェッチバッファに
供給する。その後データ有効信号pf−vldが有効に
なるごとに、インクリメンタ3510は、このセレクタ
3520の出力を1づつアップする。更新後のレジスタ
番号は、ラッチ3560を経由して、セレクタ3520
により選択され、プリフェッチバッファ320に供給さ
れる。こうして、順次4つのレジスタ番号が生成され
る。
The 2-bit incrementer 3510 is provided for the selector 3 when the data valid signal pf-vld 304 is high.
Write register number 359 output from 520 to 1
When it is incremented and low, the write register number 359 is output as it is. The output of the selector 359 is the 2-bit latch 3560.
Once, and then supplied again to the selector 3520. Therefore, the selector 3520 first selects the initial register number on line 346 when the bus mastership acquisition signal pf - gnt goes high, which causes the output of the latch 3550 to go high. The initial value of the selected register number is supplied to the prefetch buffer 320 and further to the 2-bit incrementer 3510. Since the data valid signal pf -v ld is still low at this point, the 2-bit incrementer 3510 sets the initial value of this register number in the latch 3520 as it is. At this point, the output of the latch 3550 is already low, so the selector 3520 selects the output of the latch 3560 as the write register number,
It is supplied to the prefetch buffer 320. After that, the selector 3 continues until the data valid signal pf -v ld becomes high.
520 repeatedly supplies this initial value to the prefetch buffer. Then, each time the data valid signal pf-vld becomes valid, the incrementer 3510 increments the output of the selector 3520 by one. The updated register number is transferred to the selector 3520 via the latch 3560.
And is supplied to the prefetch buffer 320. In this way, four register numbers are sequentially generated.

【0044】プリフェッチバッファ320への書き込み
信号は以下のようにして生成される。バス権獲得信号p
f−gntは、ラッチ3550にセットされたタイミン
グのさらに1サイクル後に、フリップフロップ3590
をセットする。このフリップフロップ3590のセット
出力は、メインメモリ700からプリフェッチされたデ
ータの書き込み信号としてプリフェッチバッファ320
に線358を介して供給される。プリフェッチバッファ
320は、この信号358がハイの間、毎クロック、線
359で与えられるレジスタ番号のレジスタに、データ
バス106上のデータを取り込むように構成されてい
る。したがって、プリフェッチバッファ320内のレジ
スタ番号の初期値を有するレジスタには、データ有効信
号pf−vldが最初に有効となったときにデータバス
106に存在していたデータを取込み保持することにな
る。他のレジスタも、新にデータ有効信号pf−vld
が出力される毎に、そのときデータバス106上に存在
していたデータを保持することになる。
The write signal to the prefetch buffer 320 is generated as follows. Bus right acquisition signal p
f-g nt is flip-flop 3590 one cycle after the timing set in the latch 3550.
Set. The set output of the flip-flop 3590 is used as a write signal of the data prefetched from the main memory 700, and is output to the prefetch buffer 320.
To line 358. The prefetch buffer 320 is configured to fetch the data on the data bus 106 into the register of the register number given by the line 359 every clock while this signal 358 is high. Therefore, the register having the initial value of the register number in the prefetch buffer 320 takes in and holds the data existing on the data bus 106 when the data valid signal pf-vld becomes valid first. The other registers are also newly provided with the data valid signal pf-vld.
Every time is output, the data existing on the data bus 106 at that time is held.

【0045】4カウンタ3530は、トライステートバ
ッファ390に送付された出力指示信号354によって
0にリセットされ、線304上のデータ有効信号pf−
vldがハイである回数をカウントし、4になると信号
3531をハイにしてフリップフロップ3590をリセ
ットする。こうして、4つのデータに対して、書き込み
信号が生成される。
The 4 counter 3530 is reset to 0 by the output instruction signal 354 sent to the tri-state buffer 390, and the data valid signal pf− on the line 304 is reset.
The number of times vld is high is counted, and when it becomes 4, the signal 3531 is made high and the flip-flop 3590 is reset. In this way, the write signal is generated for the four data.

【0046】とくに注意すべきは、以上の動作は、後続
のロード命令が、ポインタヒント付きのロード命令であ
り、しかも、この命令に対するヒットチェック回路37
0でのヒットチェックがヒットした場合にも以下の相違
点を除いて同様に当てはまることである。この場合に
は、後述するように、プリフェッチバッファ320にそ
の時に保持されていたデータが、データバス106に出
力され、そのデータがプロセッサインタフェース回路2
00に送られるだけでなく、アドレスレジスタ310に
もセットされ、この後続のロード命令に対するプリフェ
ッチに使用される点で、以上の動作と異なる。さらに、
この場合には、後述するように、読み出し制御回路34
0よりプリフェッチヒット信号pf−hitが線302
に出力される。この信号が、上に述べたデータ有効信号
p−vldに代えて、フリップフロップ3570にOR
ゲート3595を経由して与えられ、このフリップフロ
ップ3570のリセットに使用される点でも以上の動作
と異なる。
It should be particularly noted that in the above operation, the subsequent load instruction is a load instruction with a pointer hint, and the hit check circuit 37 for this instruction is present.
The same applies when the hit check at 0 is hit, except for the following differences. In this case, as will be described later, the data held in the prefetch buffer 320 at that time is output to the data bus 106, and the data is transferred to the processor interface circuit 2.
Not only is it sent to 00, but it is also set in the address register 310 and used for prefetching for this subsequent load instruction, which is different from the above operation. further,
In this case, as will be described later, the read control circuit 34
From 0, the prefetch hit signal pf-hit is line 302
Is output to. This signal is OR'd into the flip-flop 3570 in place of the data valid signal p-vld described above.
The operation is also different in that it is given through the gate 3595 and is used to reset the flip-flop 3570.

【0047】(ヒットチェック回路370) ヒットチェック回路370は、その後プロセッサインタ
フェース回路200あるいはI/Oインタフェース回路
400により発行されたリード要求あるいはライト要求
に付随してアドレスバス105に供給されたアドレス
が、レジスタ310に保持された、ポインタに一致する
か否かを判定する比較器330を有する。この回路の判
定結果331は、読み出し制御回路340と無効化制御
回路360により利用される。
(Hit Check Circuit 370) In the hit check circuit 370, the address supplied to the address bus 105 in association with the read request or the write request subsequently issued by the processor interface circuit 200 or the I / O interface circuit 400 is It has a comparator 330 held in the register 310 for judging whether or not it matches the pointer. The determination result 331 of this circuit is used by the read control circuit 340 and the invalidation control circuit 360.

【0048】(読み出し制御回路340) 読み出し制御回路340は、上記プリフェッチが実行さ
れた後に、このプリフェッチされたブロック内のデータ
を後続のロード命令が要求したときに、プリフェッチさ
れたブロックをプリフェッチバッファ320からプロセ
ッサインタフェース回路200を介してプロセッサ60
0に供給するための回路である。すなわち、プリフェッ
チの後にCPUにより実行された命令がロード命令であ
る場合において、ヒットチェック回路370によりヒッ
トが検出されたときに、プリフェッチバッファ320に
保持されたブロックを読み出し、プロセッサインタフェ
ース回路200を介してプロセッサ600に供給する。
(Read Control Circuit 340) The read control circuit 340 reads the prefetched block from the prefetch buffer 320 when the subsequent load instruction requests the data in the prefetched block after the prefetch is executed. From the processor 60 via the processor interface circuit 200
It is a circuit for supplying 0. That is, in the case where the instruction executed by the CPU after the prefetch is the load instruction, when the hit is detected by the hit check circuit 370, the block held in the prefetch buffer 320 is read out, and the block is held via the processor interface circuit 200. Supply to the processor 600.

【0049】より具体的には、キャッシュ制御回路63
0は、キャッシュ620にこの後続のロード命令が要求
するデータが存在しない場合、プロセッサインタフェー
ス回路200にリード要求を出力する。この回路200
は、すでに述べたように、このリード要求に応答して、
リード要求p−rdを発行する。読み出し制御回路34
0は、このリード要求に応答するようになっている。す
なわち、読み出し制御回路340は、起動回路380か
ら読み出し起動信号345が与えられたときに起動さ
れ、そのときに、ヒットチェック回路から一致信号33
1が与えられ、無効化制御回路360からプリフェッチ
バッファ有効信号366が入力されている場合、プリフ
ェッチバッファ内のブロック内のデータを順次後述の方
法により読み出すともに、ヒット信号pf−hitを線
302を介してトライステートバッファ395(図2)
とORゲート260(図2)およびメモリアクセス調停
回路500に供給する。トライステートバッファ395
は、このプリフェッチヒット信号pf−hitが与えら
れたときに、プリフェッチバッファ320から読み出さ
れたデータをデータバス106に転送する。ORゲート
260は、このプリフェッチヒット信号pf−hit
を、プロセッサインタフェース回路200に、メモリア
クセス調停回路500が与えるべきデータ有効信号p−
vldの代わりに与え、データバス106上のデータの
取込みを指示する。こうして、プロセッサインタフェー
ス回路200は、データバス106上のデータが、メモ
リアクセス調停回路500から与えられる場合と全く同
様にして、これらのデータを取り込み、プロセッサ60
0に送る。こうして、プリフェッチバッファ320に保
持されたブロックを、メインメモリ700から読み出す
よりも早く、プロセッサ600に供給することが出来
る。なお、メモリアクセス調停回路500は、プロセッ
サインタフェース回路200からすでに与えられたリー
ド要求p−rdに応答してメインメモリ700からのデ
ータ読み出しを開始しているが、この書き込み制御回路
350からプリフェッチヒット信号pf−hitが与え
られると、この読み出し動作を無効にするように構成さ
れている。具体的には、このデータを読み出したときで
も、このデータをデータバス106には供給せず、ま
た、データ有効信号p−vldを線504に出力しな
い。
More specifically, the cache control circuit 63
0 outputs a read request to the processor interface circuit 200 when the cache 620 does not have the data requested by the subsequent load instruction. This circuit 200
Responded to this read request, as already mentioned,
A read request p-rd is issued. Read control circuit 34
0 responds to this read request. That is, the read control circuit 340 is activated when the read activation signal 345 is given from the activation circuit 380, and at that time, the hit check circuit outputs the match signal 33.
When 1 is given and the prefetch buffer valid signal 366 is input from the invalidation control circuit 360, the data in the blocks in the prefetch buffer are sequentially read by the method described later, and the hit signal pf-hit is sent via the line 302. Tristate buffer 395 (Fig. 2)
And OR gate 260 (FIG. 2) and memory access arbitration circuit 500. Tri-state buffer 395
Transfers the data read from the prefetch buffer 320 to the data bus 106 when the prefetch hit signal pf-hit is applied. The OR gate 260 receives the prefetch hit signal pf-hit.
To the processor interface circuit 200 by the memory access arbitration circuit 500.
It is given instead of vld to instruct the acquisition of data on the data bus 106. In this way, the processor interface circuit 200 takes in the data on the data bus 106 in exactly the same way as when the data is provided from the memory access arbitration circuit 500, and the processor 60 receives the data.
Send to 0. In this way, the block held in the prefetch buffer 320 can be supplied to the processor 600 faster than reading from the main memory 700. The memory access arbitration circuit 500 starts data reading from the main memory 700 in response to the read request p-rd already given from the processor interface circuit 200. It is configured to invalidate this read operation when pf-hit is given. Specifically, even when this data is read, this data is not supplied to the data bus 106, and the data valid signal p-vld is not output to the line 504.

【0050】プリフェッチバッファ320の読み出しは
以下のようにして行われる。読み出しレジスタ番号34
9は、レジスタ301が保持するメモリアドレスの下位
2ビット346を、読み出しレジスタ番号の初期値とし
て用いて生成する。
Reading of the prefetch buffer 320 is performed as follows. Read register number 34
9 generates by using the lower 2 bits 346 of the memory address held by the register 301 as the initial value of the read register number.

【0051】より具体的には、読み出し制御回路340
は、プリフェッチバッファ320の読み出しアドレス3
49を生成する2ビットインクリメンタ3410と、セ
レクタ3420、データ転送サイクル数をカウントする
3カウンタ3430と、ヒット信号pf−hit302
を生成するフリップフロップ3480、タイミング合わ
せのための1ビットラッチ3440、3450、347
0、2ビットラッチ3460およびアンドゲート349
0から構成される。2ビットインクリメンタ3410
は、線302上のヒット信号pf−hitがハイのとき
プリフェッチバッファ320の読み出しレジスタ番号3
49を1インクリメントし、ローのときは読み出しレジ
スタ番号349をそのまま出力する。3カウンタ343
0は、信号3455によって0にリセットされ、線30
2上のヒット信号pf−hitがハイである回数をカウ
ントし、3になると信号3435をハイにしてヒット信
号pf−hit302を生成するフリップフロップ34
80をリセットする。セレクタ3420は、信号345
5がハイのときラッチ3470によって1サイクル遅ら
された初期レジスタ番号346を選択し、ローのときは
2ビットインクリメンタ3410の出力を選択してプリ
フェッチバッファ320の読み出しレジスタ番号349
とする。アンドゲート3490は、読み出し起動信号3
45、一致信号331、プリフェッチバッファ有効信号
366の全てがハイのとき、フリップフロップ3480
をセットすると共に1サイクル後に信号3455をハイ
にして3カウンタ3430をリセットし、セレクタ34
20に初期番号346を選択させる。
More specifically, the read control circuit 340.
Is the read address 3 of the prefetch buffer 320.
2-bit incrementer 3410 for generating 49, selector 3420, 3 counter 3430 for counting the number of data transfer cycles, and hit signal pf-hit 302
For generating a 1-bit latch 3440, 3450, 347 for timing adjustment
0 and 2 bit latch 3460 and AND gate 349
It consists of zero. 2-bit incrementer 3410
Is the read register number 3 of the prefetch buffer 320 when the hit signal pf-hit on the line 302 is high.
49 is incremented by 1, and when it is low, the read register number 349 is output as it is. 3 counter 343
The 0 is reset to 0 by the signal 3455 and the line 30
The flip-flop 34 which counts the number of times the hit signal pf-hit on 2 is high, and when the hit signal pf-hit reaches 3 sets the signal 3435 to high to generate the hit signal pf-hit 302.
Reset 80. The selector 3420 outputs the signal 345.
When 5 is high, the initial register number 346 delayed by one cycle by the latch 3470 is selected, and when it is low, the output of the 2-bit incrementer 3410 is selected and the read register number 349 of the prefetch buffer 320 is selected.
And The AND gate 3490 uses the read start signal 3
45, the match signal 331, and the prefetch buffer valid signal 366 are all high, the flip-flop 3480
And the signal 3455 is set high after one cycle to reset the 3 counter 3430, and the selector 34
Let 20 select the initial number 346.

【0052】(無効化制御回路360) 無効化制御回路360は、プリフェッチの後にプロセッ
サ600により実行された命令がストア命令である場合
あるいはI/O制御回路800、810からライト要求
が発行された場合において、ヒットチェック回路370
によりヒットが検出された場合にこのプリフェッチされ
たブロックを無効とする。すなわち、無効化制御回路3
60は、先に、データのプリフェッチにおいて、プリフ
ェッチアドレスを保持するレジスタ310(図2)にセ
ット信号357を与えたときに、この信号によりプリフ
ェッチバッファ有効信号366を生成し、その後、プリ
フェッチされたブロック内のデータを書き換えるライト
要求が実行されたときに、無効化起動信号365により
起動され、一致信号331を用いて、このプリフェファ
有効信号366をリセットする。
(Invalidation Control Circuit 360) The invalidation control circuit 360 is used when the instruction executed by the processor 600 after prefetching is a store instruction or when a write request is issued from the I / O control circuits 800 and 810. In the hit check circuit 370
Invalidates this prefetched block if a hit is detected by. That is, the invalidation control circuit 3
When the set signal 357 is given to the register 310 (FIG. 2) holding the prefetch address in the data prefetch, the signal 60 generates the prefetch buffer valid signal 366 by this signal, and then the prefetched block. When a write request for rewriting the data inside is executed, it is started by the invalidation start signal 365, and the pre-feffer valid signal 366 is reset using the coincidence signal 331.

【0053】より具体的には、図5において、無効化制
御回路360は、プリフェッチバッファ有効信号366
を生成するフリップフロップ3620、タイミング合わ
せのための1ビットラッチ3610、およびアンドゲー
ト3630から構成される。フリップフロップ3620
は、レジスタ310のセット信号357によってセット
され、無効化起動信号365を1サイクル遅らせた信号
と一致信号331が共にハイであるときリセットされ
る。
More specifically, in FIG. 5, the invalidation control circuit 360 uses the prefetch buffer valid signal 366.
, A 1-bit latch 3610 for timing adjustment, and an AND gate 3630. Flip-flop 3620
Is set by the set signal 357 of the register 310, and is reset when the signal obtained by delaying the invalidation start signal 365 by one cycle and the match signal 331 are both high.

【0054】(I/Oバスインタフェース回路400) I/Oバスインタフェース回路400は、基本的には公
知の回路と同じであり、I/O制御回路800、810
からI/Oバス801を介して要求されるメモリのリー
ド/ライト要求に対し、リード要求信号io−rd、ラ
イト要求信号io−wrをそれぞれ線401、402を
用いてアクセス調停回路500に供給し、バス権獲得信
号io−gnt、データ有効信号io−vldをそれぞ
れ線403、404を介してその回路500から受取
り、プロセッサインタフェース回路200と同一のプロ
トコルでアドレスバス105、データバス106を介し
てデータの転送を行う。
(I / O Bus Interface Circuit 400) The I / O bus interface circuit 400 is basically the same as a known circuit, and the I / O control circuits 800 and 810.
The read request signal io-rd and the write request signal io-wr are supplied to the access arbitration circuit 500 in response to the read / write request of the memory requested from the I / O bus 801 by the lines 401 and 402, respectively. , The bus right acquisition signal io-gnt and the data valid signal io-vld are received from the circuit 500 via the lines 403 and 404, respectively, and the data is transmitted via the address bus 105 and the data bus 106 by the same protocol as the processor interface circuit 200. Transfer.

【0055】<実施例2> 図9は本発明によるプリフェッチ回路をプロセッサ内に
設けた実施例である。本実施例でも、実施例1と同様
に、プロセッサ1600は、メモリインタフェース回路
100を介してメインメモリ700、I/O制御回路8
00に接続されている。プロセッサ1600は、実施例
異なり、CPU1610、データキャッシュ162
0、データキャッシュ制御回路1630、メモリアクセ
ス制御回路1640の他に本実施例の特長であるプリフ
ェッチ制御回路1300から構成されている。さらに、
本実施例では、プリフェッチ回路をプロセッサ内に設
け、データキャッシュ1620内にプリフェッチしたブ
ロックを格納するようになっている。このため、本実施
例では、実施例1のプリフェッチバッファ320は不要
である。実施例1でのヒットチェック回路370による
ヒットチェックは、本実施例では、データキャッシュ自
体が有するヒットチェック機能を利用して実現する。こ
のため、本実施例では、実施例1でのアドレス比較器3
30は不要である。本実施例でのプリフェッチ制御回路
1300を、実施例1のプリフェッチ回路300(図
2)と比べると分かるように、本実施例では、実施例1
の読み出し制御回路340、無効化制御回路360の機
能は、データキャッシュ制御回路1630がデータキャ
ッシュ1620に対して本来持っている読み出し機能と
データ無効機能を利用して実現するため、本実施例のプ
リフェッチ回路1300はこのような回路340、36
0を要しない。なお、本実施例では、命令を保持する命
令キャッシュとそれを制御する命令キャッシュ制御回路
もあるが、簡単化のために図示していない。また、以下
でも説明しない。
<Embodiment 2> FIG. 9 shows an embodiment in which a prefetch circuit according to the present invention is provided in a processor. In the present embodiment as well, as in the case of the first embodiment, the processor 1600 has the main memory 700 and the I / O control circuit 8 via the memory interface circuit 100.
Connected to 00. Processor 1600 is different from that of Example 1, CPU 1610, data cache 162
0, a data cache control circuit 1630, a memory access control circuit 1640, and a prefetch control circuit 1300 which is a feature of this embodiment. further,
In this embodiment, a prefetch circuit is provided in the processor and the prefetched block is stored in the data cache 1620. Therefore, in this embodiment, the prefetch buffer 320 of the first embodiment is unnecessary. The hit check by the hit check circuit 370 in the first embodiment is realized by using the hit check function of the data cache itself in the present embodiment. Therefore, in this embodiment, the address comparator 3 in the first embodiment is
30 is unnecessary. As can be seen by comparing the prefetch control circuit 1300 in the present embodiment with the prefetch circuit 300 in the first embodiment (FIG. 2), in the present embodiment,
Since the functions of the read control circuit 340 and the invalidation control circuit 360 are realized by using the read function and the data invalid function that the data cache control circuit 1630 originally has for the data cache 1620, the prefetch of this embodiment is performed. Circuit 1300 is such a circuit 340, 36.
0 is not required. In the present embodiment, there is an instruction cache that holds an instruction and an instruction cache control circuit that controls the instruction cache, but they are not shown for simplification. Nor will it be described below.

【0056】まず、本実施例における従来のロード/ス
トア命令の実行を簡単に説明する。このときのプロセッ
サの動作は基本的には、従来技術におけるものと類似で
ある。CPU1610はロード命令を実行すると、リー
ド要求信号rd1301をハイにすると共にロードした
いデータのアドレスをアドレスバスaddr1105に
載せデータキャッシュ制御回路1630にリード処理を
要求する。データキャッシュ制御回路1630はまずキ
ャッシュ検索指示信号chk1634をハイにしてデー
タキャッシュ1620を検索し、ヒット信号hit16
35によって結果を受けとる。ヒットしていればデータ
キャッシュ制御回路1630はキャッシュリード信号c
rd1632を用いてデータキャッシュ1620からデ
ータを読み出し、データをデータバスdata1106
に載せ、データ有効信号vld1634をハイにしてC
PU1610にデータを返す。ミスした場合、データキ
ャッシュ制御回路1630は制御信号1639を用いて
メモリアクセス制御回路1640にメインメモリ70
0からのブロックリードを要求し、メインメモリ700
からのデータをキャッシュ書き込み信号cwr1633
を用いてデータキャッシュ1620に書き込むと共にC
PU1610にデータを返す。
First, the execution of the conventional load / store instruction in this embodiment will be briefly described. The operation of the processor at this time is basically similar to that in the conventional technique. When the CPU 1610 executes the load instruction, it sets the read request signal rd1301 to high, puts the address of the data to be loaded on the address bus addr1105, and requests the data cache control circuit 1630 for read processing. The data cache control circuit 1630 first sets the cache search instruction signal chk1634 to high to search the data cache 1620, and hits the hit signal hit16.
Receive results by 35. If there is a hit, the data cache control circuit 1630 outputs the cache read signal c.
The data is read from the data cache 1620 using the rd1632, and the data is transferred to the data bus data1106.
And set the data valid signal vld1634 to high to C
The data is returned to the PU 1610. In the case of a miss, the data cache control circuit 1630 uses the control signal 1639 to inform the memory access control circuit 1640 of the main memory 70.
Request block read from 0, main memory 700
Data from the cache write signal cwr1633
Write to the data cache 1620 using
The data is returned to the PU 1610.

【0057】CPU1610がストア命令を実行する
と、ライト要求信号wr1302をハイにすると共にア
ドレスをアドレスバスaddr1105、ストアするデ
ータをデータバスdata1106に載せデータキャッ
シュ制御回路1630にライト処理を要求する。データ
キャッシュ制御回路1630は、まずキャッシュ検索指
示信号chk1634をハイにしてデータキャッシュ1
620を検索し、ヒットしていればデータキャッシュ1
620に書き込み、ミスしていればメインメモリ700
からブロックリードした後に、ストアするデータをデー
タキャッシュ1620に書き込む。
When the CPU 1610 executes the store instruction, the write request signal wr1302 is set to high, an address is placed on the address bus addr1105, and data to be stored is placed on the data bus data1106 to request the write processing to the data cache control circuit 1630. The data cache control circuit 1630 first sets the cache search instruction signal chk1634 to high, and the data cache 1
Search 620 and if there is a hit, data cache 1
Write to 620, main memory 700 if missed
After reading the block from, the data to be stored is written in the data cache 1620.

【0058】CPU1610は、本実施例でも、実施例
1と同様にポインタヒント付きロード命令を実行する。
CPU1610は、ポインタヒント付ロード命令をデコ
ードするとヒント信号hintをハイにして線1209
を介してプリフェッチ制御回路1300に通知する。プ
リフェッチ制御回路1300は、プリフェッチアドレス
レジスタ1310、アドレスセレクタ1320、タイミ
ング制御回路1350、タイミング合わせのためのディ
レイ回路1370、1380、およびデータキャッシュ
制御回路1630の制御信号を修正するためのゲート1
330、1340、1360から構成されている。プリ
フェッチ回路1300はポインタヒント付きのリード要
求を検出すると、データ有効信号1634がハイのタイ
ミングでアドレスレジスタ1310にデータバス110
6の値を取り込む。この後、セレクタ1320でアドレ
スレジスタ1310を選択し、プリフェッチ要求信号1
351をハイにし、データキャッシュ制御回路1630
にリード要求を出す。
Also in this embodiment, the CPU 1610 executes the load instruction with pointer hint as in the first embodiment.
When the CPU 1610 decodes the load instruction with pointer hint, it sets the hint signal hint to high, and the line 1209
To the prefetch control circuit 1300. The prefetch control circuit 1300 includes a prefetch address register 1310, an address selector 1320, a timing control circuit 1350, delay circuits 1370 and 1380 for timing adjustment, and a gate 1 for correcting control signals of the data cache control circuit 1630.
It is composed of 330, 1340 and 1360. When the prefetch circuit 1300 detects a read request with a pointer hint, the data bus 110 is sent to the address register 1310 when the data valid signal 1634 is high.
Take in the value of 6. Thereafter, the selector 1320 selects the address register 1310, and the prefetch request signal 1
351 is set high, and the data cache control circuit 1630
Issue a read request to.

【0059】データキャッシュ制御回路1630はデー
タキャッシュ1620を検索し、ミスしていればメイン
メモリ700からデータをデータキャッシュ1620に
読み込む。即ちデータがプリフェッチされる。
The data cache control circuit 1630 searches the data cache 1620, and if there is a miss, reads the data from the main memory 700 into the data cache 1620. That is, the data is prefetched.

【0060】データキャッシュ制御回路1630はヒッ
トしていればキャッシュから、ミスした場合はメインメ
モリ700からのデータをCPU1610に返そうとす
る。しかし、プリフェッチしたデータはCPU1610
に返す必要がないため、プリフェッチ制御回路1300
はキャッシュリード要求信号1361およびデータ有効
信号1304をハイにしないように制御し、データキャ
ッシュ1620のリード処理およびCPU1610にデ
ータを返す処理を抑止する。
The data cache control circuit 1630 attempts to return the data from the cache if there is a hit, and the data from the main memory 700 to the CPU 1610 if there is a miss. However, the prefetched data is returned to the CPU 1610.
Prefetch control circuit 1300 since it does not need to be returned to
Controls the cache read request signal 1361 and the data valid signal 1304 so as not to be high, and suppresses the read processing of the data cache 1620 and the processing of returning data to the CPU 1610.

【0061】このプリフェッチされたブロックは、通常
のロード要求でメインメモリ700からフェッチされた
ブロックと同様に、後続のロード命令により利用可能に
なる。
This prefetched block becomes available for subsequent load instructions, like the block fetched from main memory 700 with a normal load request.

【0062】この実施例では、実施例1と異なり、キャ
ッシュとは別のプリフェッチバッファを必要とせず、ま
た、実施例1で使用した、無効化制御回路、読み出し制
御回路などを要しないので、回路が簡単である。さら
に、ポインタヒント付きロード命令が要求したデータを
含むブロックが、すでにデータキャッシュに保持されて
いる場合には、プリフェッチを開始しないようになって
いるので、実施例1では起こり得るこのようなブロック
をプリフェッチするという無駄な動作は起こらない。
Unlike the first embodiment, this embodiment does not require a prefetch buffer different from the cache, and does not require the invalidation control circuit and the read control circuit used in the first embodiment. Is easy. Further, when the block including the data requested by the load instruction with pointer hint is already held in the data cache, prefetch is not started, so that such a block that may occur in the first embodiment is The useless operation of prefetching does not occur.

【0063】<実施例3> 実施例1、2では、プロセッサ600からのアドレスと
メインメモリ700から読み出されたブロックに含まれ
る別のブロックを指すアドレスは共にメインメモリ70
0の読み出しに使われるアドレスと仮定して説明をして
きた。しかし、OSなどを除く通常のプログラムではプ
ログラムから見えるアドレス(論理アドレス)とメイン
メモリのアドレス(物理アドレス)は異なっており、プ
ロセッサ内ではTLBによって論理アドレスを物理アド
レスに変換している。
Third Embodiment In the first and second embodiments, the address from the processor 600 and the address indicating another block included in the block read from the main memory 700 are both in the main memory 70.
The description has been given assuming that the address is used for reading 0. However, an address (logical address) seen by the program is different from an address (physical address) of the main memory in a normal program other than the OS, and the logical address is converted into a physical address by the TLB in the processor.

【0064】OSでは物理アドレスでメモリアクセスす
る場合もあり、また論理アドレスと物理アドレスが等し
くなるように対応づけられた領域にメモリアクセスする
場合もある。このような領域に対するメモリアクセスの
時だけポインタヒント付ロード命令を用いることでOS
の性能を向上させることもできる。
In the OS, the memory may be accessed by the physical address, and the memory may be accessed in the area where the logical address and the physical address are associated with each other. The OS can be used by using the load instruction with pointer hint only when the memory is accessed to such an area.
The performance of can also be improved.

【0065】図10は論理アドレスで動作する通常のプ
ログラムに本発明を適用するため、図2のプリフェッチ
回路300にアドレス変換の処理をする回路を付加した
プリフェッチ回路2300である。
FIG. 10 shows a prefetch circuit 2300 in which a circuit for performing address conversion processing is added to the prefetch circuit 300 of FIG. 2 in order to apply the present invention to a normal program which operates at a logical address.

【0066】本実施例ではプロセッサ600はポインタ
プリフェッチのためアドレス変換に関する情報を含め2
ビットのヒント情報p−hint1(信号2208)と
p−hint0 (信号2209)を出力するものとす
る。例えばヒント情報p−hint1とp−hint0
が00の場合プリフェッチヒントなし、01の場合4K
バイトページ内のポインタプリフェッチ、10の場合1
Mバイトページ内のポインタプリフェッチ、11の場合
物理アドレスによるポインタプリフェッチとする。
In this embodiment, the processor 600 includes the information about the address conversion for the pointer prefetch.
Bit hint information p-hint1 (signal 2208) and p-hint0 (signal 2209) are output. For example, hint information p-hint1 and p-hint0
If 00 is no prefetch hint, if 01 is 4K
Prefetch pointer within byte page, 1 for 10
Mbyte page pointer prefetch, 11 means pointer prefetch by physical address.

【0067】ヒント情報p−hint1とp−hint
0が00の場合と11の場合の動作は、本プリフェッチ
回路2300でも実施例1で説明したポインタヒントな
しのリード処理とポインタヒント付きリード処理と全く
同一に動作する。異なっているのはヒント情報p−hi
nt1とp−hint0が01または10の場合で、こ
の時はロードされたデータをそのままプリフェッチアド
レスとして用いるのではなく、ページサイズに従ってペ
ージアドレスとして前のロードに用いた物理アドレスを
用いる。以下、この時のプリフェッチ動作を説明する。
Hint information p-hint1 and p-hint
The operations when 0 is 00 and when 11 are the same in the prefetch circuit 2300 as the read processing without pointer hint and the read processing with pointer hint described in the first embodiment. The difference is the hint information p-hi
When nt1 and p-hint0 are 01 or 10, at this time, the loaded data is not used as a prefetch address as it is, but the physical address used for the previous load is used as a page address according to the page size. The prefetch operation at this time will be described below.

【0068】プリフェッチ回路2300は、図2のプリ
フェッチ回路230に比べて、プリフェッチヒント情報
として2ビットを受取ること、レジスタ2310、セレ
クタ2320、2330、ディレイ2340、235
0、EOR回路2360、OR回路2370が追加され
ていることと、書き込み制御回路350にディレイ23
30、2350を制御するための信号2357を生成す
る回路が追加されている点が異なっている。他は図2の
プリフェッチ回路230と同様に動作するため説明は省
略する。
Compared to the prefetch circuit 230 of FIG. 2, the prefetch circuit 2300 receives 2 bits as prefetch hint information, the register 2310, the selectors 2320 and 2330, and the delays 2340 and 235.
0, an EOR circuit 2360 and an OR circuit 2370 are added, and the delay 23 is added to the write control circuit 350.
The difference is that a circuit for generating a signal 2357 for controlling 30, 2350 is added. Others operate in the same manner as the prefetch circuit 230 of FIG.

【0069】OR回路2370はポインタヒント付ロー
ド命令であることを起動回路380に通知する。レジス
タ2310はプリフェッチ処理のときにレジスタ310
のアドレスがアドレスバス105に出力されるタイミン
グで、そのアドレスをラッチする。このアドレスはメイ
ンメモリ700をアクセスする物理アドレスである。デ
ィレイ2330、2350は信号2357を介して書き
込み制御回路350に制御され、レジスタ310のセッ
ト信号357と同じタイミングにヒント情報p−hin
t1とp−hint0を信号2341、2351に出力
する。セレクタ2320、2330は、ポインタヒント
付ロード命令によって読み出されたブロックから次にプ
リフェッチするアドレスをレジスタ310へ書き込むと
きに、読み出されたブロック内のアドレス(論理アドレ
ス)とレジスタ2310の保持する物理アドレスの一方
の上位を、制御信号2351、2361に従って選択す
る。すなわち、本実施例ではEOR回路2360によっ
て、ヒント情報p−hint1とp−hint0が01
の場合、32ビットアドレスの下位12ビットはデータ
バス106からセットされるが、上位20ビットはレジ
スタ2310内の物理アドレスの上位20ビットがセレ
クタ2320を介してセットされ、ヒント情報p−hi
nt1とp−hintが10の場合、下位20ビットは
データバス106からセットされるが、上位12ビット
はレジスタ2310内の物理アドレスの上位12ビット
がセレクタ2330を介してセットされるように制御信
号2351、2361が生成されている。
The OR circuit 2370 notifies the activation circuit 380 that the load instruction is a pointer hint. The register 2310 is the register 310 during the prefetch process.
The address is latched at the timing when the address is output to the address bus 105. This address is a physical address for accessing the main memory 700. The delays 2330 and 2350 are controlled by the write control circuit 350 via the signal 2357, and the hint information p-hin is set at the same timing as the set signal 357 of the register 310.
It outputs t1 and p-hint0 to signals 2341 and 2351. When writing the address to be prefetched next from the block read by the load instruction with pointer hint to the register 310, the selectors 2320 and 2330 store the address (logical address) in the read block and the physical value held by the register 2310. One of the upper addresses is selected according to the control signals 2351 and 2361. That is, in this embodiment, the EOR circuit 2360 causes the hint information p-hint1 and p-hint0 to be 01.
In the case of, the lower 12 bits of the 32-bit address are set from the data bus 106, but the upper 20 bits of the higher 20 bits of the physical address in the register 2310 are set via the selector 2320, and the hint information p-hi.
When nt1 and p-hint are 10, the lower 20 bits are set from the data bus 106, but the upper 12 bits are control signals so that the upper 12 bits of the physical address in the register 2310 are set via the selector 2330. 2351 and 2361 are generated.

【0070】したがって、ヒント情報p−hint1と
p−hint0が01の場合、ヒント付きロード命令が
指定したアドレスが属する4Kバイトページに属するデ
ータの中から、この命令で読み出されたポインタにより
決まるアドレスのデータをプリフェッチし、ヒント情報
p−hint1とp−hint0が10の場合、ヒント
付きロード命令が指定したアドレスが属する1Mバイト
のページから、この命令により読み出されたポインタで
決まるアドレスのブロックをプリフェッチする。
Therefore, when the hint information p-hint1 and p-hint0 are 01, the address determined by the pointer read by this instruction from the data belonging to the 4 Kbyte page to which the address designated by the load instruction with hint belongs When the hint information p-hint1 and p-hint0 are 10, the block of the address determined by the pointer read by this instruction is read from the 1 Mbyte page to which the address specified by the hinted load instruction belongs. Prefetch.

【0071】[0071]

【発明の効果】本発明によれば、メモリからデータを読
み出すことを要求する命令が実行されたときに、そのデ
ータが他のデータのアドレス情報を含む場合に、その命
令の要求に従ってメモリから読み出されたデータを使用
して他のデータを読み出すことが出来る。もともと、こ
の命令を含むプログラムは、いずれの命令によりメモリ
から読み出されるデータが他のデータに対するポインタ
であるか否かを知っている。したがって、本発明によれ
ば、ポインタを指定するロード命令の実行を契機とし
て、そのポインタが指定する他のデータをプリフェッチ
するので、プリフェッチするタイミングを簡単に決める
ことが出来る。しかも、このような一つの命令を実行す
る毎に、その命令の後続の命令が使用するデータをプリ
フェッチするので、プリフェッチに必要な回路が簡単に
なる。さらに、プリフェッチされたデータは使用される
ことが多くの場合確実であるので、プリフェッチされた
後使用されることがないということが起こる可能性は高
くはないので、プリフェッチ処理が無駄になる可能性は
少ない。
According to the present invention, when an instruction for reading data from a memory is executed, if the data includes address information of other data, the instruction is read from the memory according to the request of the instruction. The issued data can be used to read other data. Originally, the program including the instruction is read out from the memory Lud over data knows whether pointers to other data by any instructions. Therefore, according to the present invention, the execution of the load instruction designating the pointer is used to prefetch other data designated by the pointer, so that the timing of prefetching can be easily determined. Moreover, each time such one instruction is executed, the data used by the instruction subsequent to the instruction is prefetched, so that the circuit required for prefetching becomes simple. In addition, because prefetched data is often certain to be used, it is unlikely that it will never be used after it has been prefetched, so prefetching can be wasted. Is few.

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

【図1】本発明による情報処理装置の第1の実施例を示
す図。
FIG. 1 is a diagram showing a first embodiment of an information processing apparatus according to the present invention.

【図2】図1の装置に使用されるプリフェッチ回路の概
略回路構成図。
2 is a schematic circuit configuration diagram of a prefetch circuit used in the device of FIG.

【図3】図2の装置に使用される読み出し制御回路の概
略回路構成図。
3 is a schematic circuit configuration diagram of a read control circuit used in the device of FIG.

【図4】図2の装置に使用される書き込み制御回路の概
略回路構成図。
4 is a schematic circuit configuration diagram of a write control circuit used in the device of FIG.

【図5】図2の装置に使用される無効化制御回路の概略
回路構成図。
5 is a schematic circuit configuration diagram of an invalidation control circuit used in the device of FIG.

【図6】従来のポインタ型データ構造の例を示す図。FIG. 6 is a diagram showing an example of a conventional pointer type data structure.

【図7】図6のポインタ型データ構造が保持されてい
る、メモリ内の記憶位置の例を示す図。
FIG. 7 is a diagram showing an example of storage locations in a memory in which the pointer type data structure of FIG. 6 is held.

【図8】図1の装置に使用する命令のフォーマットの例
を示す図。
8 is a diagram showing an example of a format of an instruction used in the apparatus of FIG.

【図9】本発明による情報処理装置の第2の実施例を示
す図。
FIG. 9 is a diagram showing a second embodiment of the information processing apparatus according to the present invention.

【図10】本発明による情報処理装置の第3の実施例を
示す図。
FIG. 10 is a diagram showing a third embodiment of the information processing apparatus according to the present invention.

【符号の説明】[Explanation of symbols] 100…メモリインタフェース回路、200…プロセッ100 ... Memory interface circuit, 200 ... Processor
サインタフェース回路、250…ディレイ回路、300Interface circuit, 250 ... Delay circuit, 300
…プリフェッチ回路、400…I/Oバスインタフェー... prefetch circuit, 400 ... I / O bus interface
ス回路、500…メモリアクセス調停回路、600…プCircuit, 500 ... Memory access arbitration circuit, 600 ...
ロセッサ、610…CPU、620…キャッシュ、63Processor, 610 ... CPU, 620 ... Cache, 63
0…キャッシュ制御回路、700…メインメモリ、800 ... Cache control circuit, 700 ... Main memory, 80
0…I/O制御回路、810…I/O制御回路。0 ... I / O control circuit, 810 ... I / O control circuit.

───────────────────────────────────────────────────── フロントページの続き (56)参考文献 特開 平4−44139(JP,A) 特開 平7−56755(JP,A) (58)調査した分野(Int.Cl.7,DB名) G06F 9/30 - 9/42 G06F 12/02 - 12/12 ─────────────────────────────────────────────────── ─── Continuation of the front page (56) References JP-A-4-44139 (JP, A) JP-A-7-56755 (JP, A) (58) Fields investigated (Int.Cl. 7 , DB name) G06F 9/30-9/42 G06F 12/02-12/12

Claims (9)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】データを保持するメモリと、命令を実行す
る処理装置とを有する情報処理装置において、 該メモリからの第1のデータの読み出しを要求する第1
データ読み出し命令の実行に応答して、該メモリの第
1の記憶位置から該第1のデータを読み出し、 読み出された第1のデータを該処理装置に供給し、更に該第2のデータのプリフェッチを要求する該第1の
データ読み出し命令に応答して読み出された上記第1の
データに依存して選択される 該メモリの第2の記憶位置
から該第2のデータをプリフェッチし、 該プリフェッチされた第2のデータを一時的に保持し、該メモリから該第2のデータの読み出しを要求する後続
の第2のデータ読み出し命令の、該処理装置による実行
に応答して、上記一時的に 保持された第2のデータを該
処理装置に供給するデータプリフェッチ方法。
1. An information processing apparatus having a memory for holding data and a processing device for executing an instruction, wherein a first request for reading first data from the memory is made.
In response to execution of the data read instruction, reads the data of the first from the first storage location of the memory, the first data read is supplied to the processing unit, further said second data Requesting a prefetch of the first
The first data read in response to the data read command
Prefetching the second data from a second storage location of the memory that is selected depending on the data, temporarily holding the prefetched second data, and storing the second data of the second data from the memory. Subsequent read request
Execution of the second data read instruction of
In response to the above , the data prefetch method of supplying the temporarily held second data to the processing device.
【請求項2】該情報処理装置は、該メモリに保持された
データの一部を保持するキャッシュをさらに有し、 上記方法は、 該第1の命令の実行に応答して、該第1のデータが該キ
ャッシュに保持されているか否かを検出し、 該第1のデータが該キャッシュに保持されているときに
は、該第1のデータを該キャッシュから該処理装置に供
給し、 該第1のデータが該キャッシュに保持されていないとき
には、該第1のデータを該メモリから読み出す上記読み
出しを起動するステップをさらに有し、 上記第2のデータを一時的に保持する上記ステップは、
プリフェッチされた該第2のデータを該キャッシュに
するステップを有し、 上記方法は、 該第2の命令の実行に応答して、該第2のデータが該キ
ャッシュに保持されているか否かを検出し、 該第2のデータが該キャッシュに保持されているときに
は、該第2のデータを該キャッシュから該処理装置に供
給すべく、該第2のデータの供給ステップを起動し、 該第2のデータが該キャッシュに保持されていないとき
には、該メモリに対して該第2のデータの読み出し要求
を発行するステップをさらに有する請求項1記載のデー
タプリフェッチ方法。
2. The information processing apparatus further comprises a cache for holding a part of the data held in the memory, and the method is responsive to the execution of the first instruction, Detecting whether or not data is held in the cache, and supplying the first data from the cache to the processing device when the first data is held in the cache, The method further comprises activating the read to read the first data from the memory when the data is not held in the cache, and the step of temporarily holding the second data comprises:
Holding prefetched said second data to said cache
Comprising the step of lifting, the method, in response to execution of the instruction of the second, the second data is detected whether or not it is held in the cache, the second data is the cache When the second data is not held in the cache, the step of supplying the second data is started to supply the second data from the cache to the processing device when the second data is not held in the cache. 2. The data prefetch method according to claim 1, further comprising the step of issuing a read request for the second data to the memory.
【請求項3】上記第1のデータの読み出しステップは、 該第1のデータを含む第1のブロックを該メモリから読
み出し、 読み出された第1のブロックを該キャッシュに書き込む
ステップを有し、 該第1のデータ供給する上記ステップは、読み出され
た第1のブロックから該第1のデータを選択して該処理
装置に供給するステップを有し、 該第2のデータをプリフェッチする上記ステップは、該
第2のデータを含む第2のブロックを該メモリからプリ
フェッチするステップを有し、 該プリフェッチされた第2のデータを一時的に保持する
上記ステップは、該プリフェッチされた第2のブロック
キャッシュに書き込むステップを有し、 該第2のデータを供給する上記ステップは、該キャッシ
に書き込まれた該第2のブロックから該第2のデータ
を選択して該処理装置に供給するステップを有する請求
項2記載のデータプリフェッチ方法。
3. The step of reading the first data comprises the step of reading a first block containing the first data from the memory and writing the read first block to the cache. said step of supplying the first data read from the first block to select said first data includes a step of supplying to the processing apparatus, the prefetching the second data The step comprises prefetching a second block containing the second data from the memory, and the step of temporarily holding the prefetched second data comprises the prefetching the second prefetched second data . block
The has a step of writing to said cache, said step of providing data of said second, said cache
Data prefetching method according to claim 2, wherein the written second blocks in Interview by selecting said second data having a step of supplying to the processing apparatus.
【請求項4】上記第2のデータをプリフェッチするステ
ップは、 上記第1のデータが保持されている該メモリの該第1の
記憶位置のアドレスを保持し、 上記第1のデータが該メモリから読み出されたときに、
該第1の記憶位置の保持されたアドレスと、該第1のデ
ータを合成して、該第2のデータがプリフェッチされる
べき該メモリの第2の記憶位置のアドレスを生成し、 生成されたアドレスに基づいて、該メモリから上記第2
のデータをプリフェッチするステップを有する請求項1
記載のデータプリフェッチ方法。
4. The step of prefetching the second data retains an address of the first storage location of the memory in which the first data is retained, and the first data is stored in the memory. When read,
A generated address is generated by combining the held address of the first storage location and the first data to generate an address of a second storage location of the memory where the second data is to be prefetched. The second from the memory based on the address
1. Pre-fetching the data of
Data prefetch method described.
【請求項5】第1及び第2のデータを保持するメモリ
と、 命令を実行する処理装置と、 該メモリからの第1のデータの読み出しを要求するデー
タ読み出し命令が該処理装置で実行されたことに応答し
て、そのデータ読み出し命令が指定する、該メモリの記
憶位置に保持された該第1のデータの読み出しを要求す
る読み出し要求を該メモリに供給し、該読み出し要求に
対して該メモリから読み出された第1のデータを該処理
装置に供給する、該メモリと該処理装置に接続された第
1のデータ読み出し回路と、 上記第1のデータに依存して選択される該メモリの第2
の記憶位置に保持された第2のデータのプリフェッチを
さらに要求する上記データ読み出し命令に応答して、第
2のデータの読み出しを要求する読み出し要求を該メモ
リに供給する、該メモリと該処理装置に接続された第2
のデータ読み出し回路と、 該第2のデータ読み出し回路から供給された該読み出し
要求に対して該メモリから読み出された該第2のデータ
を一時的に保持するため該メモリに接続された一時的デ
ータ記憶装置と、 該メモリから該第2のデータの読み出しを要求する、該
処理装置での他のデータ読み出し命令の実行に応答し
て、該一時的データ記憶装置から該第2のデータを読み
出し、該処理装置に供給するデータ供給回路とを有す
る、該一時的データ記憶装置と該処理装置に接続された
情報処理装置。
5. A memory for holding first and second data, a processing device for executing an instruction, and a data read instruction for requesting reading of the first data from the memory are executed by the processing device. In response to the request, a read request that requests reading of the first data held in the storage location of the memory designated by the data read command is supplied to the memory, and the memory is responsive to the read request. A first data read circuit connected to the memory and the memory for supplying the first data read from the memory to the processor, and the memory selected according to the first data. Second
The memory and the processing unit, in response to the data read command that further requests prefetching of the second data held in the memory location, supplying a read request that requests reading of the second data to the memory. Second connected to
And a temporary read circuit connected to the memory for temporarily holding the second data read from the memory in response to the read request supplied from the second data read circuit. A data storage device and reading the second data from the temporary data storage device in response to execution of another data read instruction in the processing device that requests reading of the second data from the memory. An information processing device connected to the temporary data storage device and the processing device, the information processing device having a data supply circuit for supplying the processing device.
【請求項6】上記処理装置は、 命令を実行する処理ユニットと、 該メモリに保持されたデータの一部を保持するキャッシ
ュと、 データ読み出し命令が該処理ユニットで実行されたと
き、そのデータ読み出し命令が要求する上記データが該
キャッシュに保持されているか否かを検出し、該データ
読み出し命令が要求するデータが該キャッシュに保持さ
れているときに、該データを該キャッシュから該処理ユ
ニットに供給する、該処理ユニットと該キャッシュと該
メモリとに接続されたキャッシュ制御回路とをさらに有
し、 上記第1の読み出し回路は、該データ読み出し命令が要
求する該データが該キャッシュに保持されていないとき
に、該メモリに対して、該データ読み出し命令を該メモ
リに供給する、該キャッシュ制御回路に含まれた読み出
し要求回路を有し、 該キャッシュが、該一時的データ記憶装置として使用さ
れ、 該キャッシュ制御回路が、該データ供給回路を含む請求
項5記載の情報処理装置。
6. The processing device comprises: a processing unit for executing an instruction; a cache for holding a part of the data held in the memory; and a data read instruction when a data read instruction is executed by the processing unit. Detecting whether or not the data requested by the instruction is held in the cache, and supplying the data from the cache to the processing unit when the data requested by the data read instruction is held in the cache Further, a cache control circuit connected to the processing unit, the cache, and the memory, wherein the first read circuit does not hold the data requested by the data read instruction in the cache. Sometimes, the read command included in the cache control circuit that supplies the data read command to the memory is read. 6. The information processing apparatus according to claim 5, further comprising a read request circuit, wherein the cache is used as the temporary data storage device, and the cache control circuit includes the data supply circuit.
【請求項7】該メモリから該データの読み出しを要求す
る上記データ読み出し命令は、該データ読み出し命令が
該他のデータの読み出し要求をさらに含むか否かを示す
フィールドを含み、 上記第2のデータ読み出し回路は該データ読み出し命令
の該フィールドに応答する請求項5記載の情報処理装
置。
7. The data read command requesting to read the data from the memory includes a field indicating whether the data read command further includes a read request for the other data, and the second data. The information processing apparatus according to claim 5, wherein the read circuit responds to the field of the data read command.
【請求項8】上記第2のデータを保持する該第2の記憶
位置を指示するために上記第1のデータを使用するポイ
ンタをさらに含む請求項5記載の情報処理装置。
8. The information processing apparatus according to claim 5, further comprising a pointer that uses the first data to point to the second storage location that holds the second data.
【請求項9】データを保持するメモリと、命令を実行す
る処理装置とを有する情報処理装置において、 該メモリからの第1のデータの読み出しを要求する第1
のデータ読み出し命令の実行に応答して、該メモリの第
1の記憶位置から該第1のデータを読み出し、 読み出された第1のデータを該処理装置に供給し、 該第1のデータ読み出し命令が第2のデータのプリフェ
ッチを示すときには、該第1のデータが指示する該メモ
リの該第2の記憶位置から該第2のデータをプリフェッ
チし、 該プリフェッチされた第2のデータを一時的に保持し、 該メモリから該第2のデータの読み出しを要求する、該
処理装置による後続の第2のデータ読み出し命令の実行
に応答して、上記一時的に保持された第2のデータを該
処理装置に供給する請求項5記載の情報処理装置。
9. An information processing device having a memory for holding data and a processing device for executing instructions, wherein a first request for reading first data from the memory is made.
Reading the first data from the first storage location of the memory, supplying the read first data to the processing device, and reading the first data. When the instruction indicates prefetching of the second data, the second data is prefetched from the second storage location of the memory indicated by the first data, and the second prefetched data is temporarily fetched. And temporarily storing the second data in response to execution of a subsequent second data read command by the processing device, the second data being stored in the memory and requesting the second data to be read from the memory. The information processing apparatus according to claim 5, wherein the information processing apparatus supplies the information to a processing device.
JP13694495A 1994-06-06 1995-06-02 Data prefetch method and information processing apparatus therefor Expired - Fee Related JP3445873B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP13694495A JP3445873B2 (en) 1994-06-06 1995-06-02 Data prefetch method and information processing apparatus therefor

Applications Claiming Priority (3)

Application Number Priority Date Filing Date Title
JP12347594 1994-06-06
JP6-123475 1994-06-06
JP13694495A JP3445873B2 (en) 1994-06-06 1995-06-02 Data prefetch method and information processing apparatus therefor

Publications (2)

Publication Number Publication Date
JPH0855025A JPH0855025A (en) 1996-02-27
JP3445873B2 true JP3445873B2 (en) 2003-09-08

Family

ID=26460390

Family Applications (1)

Application Number Title Priority Date Filing Date
JP13694495A Expired - Fee Related JP3445873B2 (en) 1994-06-06 1995-06-02 Data prefetch method and information processing apparatus therefor

Country Status (1)

Country Link
JP (1) JP3445873B2 (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7238218B2 (en) 2004-04-06 2007-07-03 International Business Machines Corporation Memory prefetch method and system
US20070186050A1 (en) * 2006-02-03 2007-08-09 International Business Machines Corporation Self prefetching L2 cache mechanism for data lines
JP5091548B2 (en) * 2007-06-06 2012-12-05 川崎マイクロエレクトロニクス株式会社 Memory system
WO2008155812A1 (en) 2007-06-18 2008-12-24 Fujitsu Limited Processor and prefetch support program

Also Published As

Publication number Publication date
JPH0855025A (en) 1996-02-27

Similar Documents

Publication Publication Date Title
US5652858A (en) Method for prefetching pointer-type data structure and information processing apparatus therefor
US4701844A (en) Dual cache for independent prefetch and execution units
JP3016575B2 (en) Multiple cache memory access methods
US6401192B1 (en) Apparatus for software initiated prefetch and method therefor
US8725987B2 (en) Cache memory system including selectively accessible pre-fetch memory for pre-fetch of variable size data
US6247107B1 (en) Chipset configured to perform data-directed prefetching
JP3218317B2 (en) Integrated cache unit and configuration method thereof
KR100228940B1 (en) How to keep memory consistent
CN101558391B (en) Configurable cache for a microprocessor
US5671231A (en) Method and apparatus for performing cache snoop testing on a cache system
KR100335744B1 (en) Load/load detection and reorder method
EP2092429A1 (en) Configurable cache for a microprocessor
JPH0997230A (en) Method and system for data transfer
US20080147979A1 (en) Configurable cache for a microprocessor
US6922753B2 (en) Cache prefetching
JP3431878B2 (en) Instruction cache for multithreaded processors
US5367657A (en) Method and apparatus for efficient read prefetching of instruction code data in computer memory subsystems
US7310712B1 (en) Virtual copy system and method
JP3445873B2 (en) Data prefetch method and information processing apparatus therefor
US4648033A (en) Look-aside buffer LRU marker controller
EP0726524A2 (en) Protocol and system for performing line-fill addressing during copy-back operation
JPH07121443A (en) Information process system and its operating method
EP0156307A2 (en) Pipelined processor having dual cache memories
CN100410898C (en) Accessible buffer used in parallel with filling cache line and control method thereof
JP2002108702A (en) Microcomputer and data processing device

Legal Events

Date Code Title Description
FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20080627

Year of fee payment: 5

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20080627

Year of fee payment: 5

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090627

Year of fee payment: 6

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20100627

Year of fee payment: 7

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20100627

Year of fee payment: 7

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110627

Year of fee payment: 8

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110627

Year of fee payment: 8

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120627

Year of fee payment: 9

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120627

Year of fee payment: 9

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130627

Year of fee payment: 10

LAPS Cancellation because of no payment of annual fees