JP7363255B2 - Information processing device, information processing method, and program - Google Patents

Information processing device, information processing method, and program Download PDF

Info

Publication number
JP7363255B2
JP7363255B2 JP2019169294A JP2019169294A JP7363255B2 JP 7363255 B2 JP7363255 B2 JP 7363255B2 JP 2019169294 A JP2019169294 A JP 2019169294A JP 2019169294 A JP2019169294 A JP 2019169294A JP 7363255 B2 JP7363255 B2 JP 7363255B2
Authority
JP
Japan
Prior art keywords
instruction
address
entry
instructions
execution module
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.)
Active
Application number
JP2019169294A
Other languages
Japanese (ja)
Other versions
JP2021047591A (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.)
NEC Corp
Original Assignee
NEC Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by NEC Corp filed Critical NEC Corp
Priority to JP2019169294A priority Critical patent/JP7363255B2/en
Publication of JP2021047591A publication Critical patent/JP2021047591A/en
Application granted granted Critical
Publication of JP7363255B2 publication Critical patent/JP7363255B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Description

本発明は、情報処理装置などに用いられるキャッシュに関し、特に、命令を保存する命令キャッシュに関する。 The present invention relates to a cache used in an information processing device and the like, and particularly to an instruction cache for storing instructions.

情報処理装置は、具体的な命令を実行する実体として、プロセッサを含んでいる。プロセッサにおける命令の実行には、実行する命令とその命令で使用するデータとが、必要である。命令及びデータが供給されない場合、プロセッサは、命令及びデータの待ち状態となる。つまり、プロセッサの実行が停止する。プロセッサの実行効率を高めるためには、プロセッサの実行が停止しないように、命令とデータとをプロセッサに供給することが、重要である。 The information processing device includes a processor as an entity that executes specific instructions. The execution of an instruction in a processor requires the instruction to be executed and the data used by the instruction. If instructions and data are not provided, the processor waits for instructions and data. In other words, the processor stops executing. In order to increase the execution efficiency of a processor, it is important to supply instructions and data to the processor so that the execution of the processor does not stop.

命令に必要なデータについては、あらかじめ、プリフェッチ命令等を用いて、データキャッシュに保存することができる。しかし、命令は、分岐命令等がある。分岐命令は、分岐が発生するか否かに伴い、その命令の後に実行される命令が異なる。そのため、命令を命令キャッシュにプリフェッチすることは、難しい。 Data necessary for an instruction can be stored in a data cache in advance using a prefetch instruction or the like. However, the instructions include branch instructions and the like. The instruction executed after a branch instruction differs depending on whether a branch occurs or not. Therefore, it is difficult to prefetch instructions into the instruction cache.

なお、分岐命令で分岐するかどうかを予測する構成として、分岐予測器がある。しかし、分岐予測器に基づく予測は、あくまでも予測である。そのため、実際のプロセッサの動作は、必ずしも分岐予測器の予測どおり分岐するとは限らない。 Note that there is a branch predictor as a configuration for predicting whether or not a branch will be taken by a branch instruction. However, prediction based on a branch predictor is just a prediction. Therefore, actual processor operations do not necessarily branch as predicted by the branch predictor.

そこで、命令についてのキャッシュを実現するための技術が提案されている(例えば、特許文献1及び2を参照)。 Therefore, techniques for realizing caching of instructions have been proposed (see, for example, Patent Documents 1 and 2).

特許文献1は、コンパイラが生成した命令列の中に、命令をプリフェッチするための命令を挿入する技術を開示している。 Patent Document 1 discloses a technique for inserting an instruction for prefetching instructions into an instruction string generated by a compiler.

特許文献2は、特定のタスクを、キャッシュミスヒット率の低いコアに移動する技術を開示している。 Patent Document 2 discloses a technique for moving a specific task to a core with a low cache miss rate.

特開平11-306028号公報Japanese Patent Application Publication No. 11-306028 特開2014-130644号公報Japanese Patent Application Publication No. 2014-130644

プロセッサが実行する命令には、頻繁に実行される命令が存在する。このような頻繁に実行される命令は、常に、命令キャッシュに配置されることが望ましい。 Among the instructions executed by a processor, there are instructions that are frequently executed. It is desirable that such frequently executed instructions are always placed in the instruction cache.

しかし、特許文献1に記載の技術は、命令キャッシュにおける命令の置き換えにおいて、命令を区別していない。 However, the technique described in Patent Document 1 does not distinguish between instructions when replacing instructions in the instruction cache.

そのため、特許文献1に記載の技術は、頻繁に実行される命令も、他の命令と同様に、命令キャッシュから追い出されてしまうという問題点があった。 Therefore, the technique described in Patent Document 1 has a problem in that frequently executed instructions are also evicted from the instruction cache like other instructions.

特許文献2に記載の技術は、特定のタスクとして、頻繁に実行される命令を含むタスクを用いると、キャッシュミスヒット率の低いコアのキャッシュに、頻繁に実行される命令を置くことができる。 In the technique described in Patent Document 2, when a task including frequently executed instructions is used as a specific task, the frequently executed instructions can be placed in the cache of a core with a low cache miss rate.

しかし、各コアは、動作が固定される場合は少ない。つまり、各コアにおけるキャッシュミスヒット率は、固定ではなく、常に変化する。 However, the operation of each core is rarely fixed. In other words, the cache miss rate in each core is not fixed and constantly changes.

特許文献2に記載の技術は、キャッシュミスヒット率が変化した場合に、コア間においてタスクを移動する動作が必要となる。この動作は、命令の実行とは異なる動作であり、プロセッサの実行効率を低下させる動作である。 The technology described in Patent Document 2 requires an operation to move tasks between cores when the cache miss rate changes. This operation is different from instruction execution, and is an operation that reduces the execution efficiency of the processor.

つまり、特許文献2に記載の技術は、各コアにおけるキャッシュミスヒット率の変化した場合に、プロセッサの実行効率が低下するという問題点があった。 In other words, the technique described in Patent Document 2 has a problem in that the execution efficiency of the processor decreases when the cache miss rate in each core changes.

本発明の目的は、上記問題点を解決し、命令キャッシュにおける所定の命令の置き換えを低減する情報処理装置などを提供することにある。 SUMMARY OF THE INVENTION An object of the present invention is to solve the above-mentioned problems and provide an information processing device that reduces the number of replacements of predetermined instructions in an instruction cache.

本発明の一形態における情報処理装置は、
命令を実行するプロセッサと、
プロセッサが実行する命令を保存する第1の命令記憶手段と、
第1の命令記憶手段において、優先的にキャッシュする命令を保存するアドレスの範囲を保存するアドレス記憶手段と
を含む実行モジュールと、
プロセッサが実行する命令のキャッシュとして、実行モジュールが保存する命令の複製を保存する第2の命令記憶手段と、
第2の命令記憶手段が保存した命令に関連するアドレスとして、実行モジュールにおける命令のアドレスを含むエントリを保存するエントリ記憶手段と、
エントリが保存するアドレスと、実行モジュールが保存するアドレスの範囲とを用いて、複製として保存する命令の中で、新たな命令と置き換える命令を決定するキャッシュ制御手段と
を含む命令キャッシュと
を含む。
An information processing device in one embodiment of the present invention includes:
a processor that executes instructions;
a first instruction storage means for storing instructions to be executed by the processor;
an execution module comprising: an address storage means for storing a range of addresses for storing instructions to be cached preferentially in the first instruction storage means;
a second instruction storage means for storing copies of instructions stored by the execution module as a cache of instructions executed by the processor;
Entry storage means for storing an entry containing an address of the instruction in the execution module as an address related to the instruction stored by the second instruction storage means;
an instruction cache comprising: a cache control means for determining an instruction to be replaced with a new instruction among instructions to be saved as a copy using an address to be saved by the entry and a range of addresses to be saved by the execution module;

本発明の別の形態における情報処理装置は、
上記情報処理装置と、
実行モジュールを生成するときに、
実行モジュールに含まれる命令の中で、優先的に命令キャッシュに保存する命令を指定する命令指定手段と、
実行モジュールにおいて、指定された命令を配置する実行モジュールにおけるアドレスを決定する命令配置決定手段と、
決定したアドレスに指定された命令を埋め込む命令埋め込み手段と
を含むローダをさらに含む。
An information processing device according to another embodiment of the present invention includes:
The above information processing device;
When generating an executable module,
an instruction specifying means for specifying an instruction to be preferentially stored in an instruction cache among instructions included in the execution module;
an instruction placement determining means for determining an address in the execution module to place a specified instruction in the execution module;
The method further includes a loader including an instruction embedding means for embedding the specified instruction at the determined address.

本発明の一形態における情報処理方法は、
命令を実行するプロセッサと、
プロセッサが実行する命令と、優先的にキャッシュする命令を保存するアドレスの範囲を保存する実行モジュールと、
命令キャッシュとを含む情報処理装置において、
命令キャッシュが
プロセッサが実行する命令のキャッシュとして、実行モジュールが保存する命令の複製を保存し、
保存した命令に関連するアドレスとして、実行モジュールにおける命令のアドレスを含むエントリを保存し、
エントリが保存するアドレスと、実行モジュールが保存するアドレスの範囲とを用いて、複製として保存する命令の中で、新たな命令と置き換える命令を決定する。
An information processing method in one form of the present invention includes:
a processor that executes instructions;
an execution module that stores instructions to be executed by the processor and a range of addresses for storing instructions to be cached preferentially;
In an information processing device including an instruction cache,
The instruction cache stores copies of instructions stored by execution modules as a cache for instructions executed by the processor.
saving an entry containing the address of the instruction in the execution module as an address associated with the saved instruction;
Using the address saved by the entry and the range of addresses saved by the execution module, an instruction to be replaced with a new instruction among the instructions saved as a copy is determined.

本発明の一形態におけるプログラムは、
命令を実行するプロセッサを含む情報処理装置に、
プロセッサが実行する命令を保存し、
優先的にキャッシュする命令を保存するアドレスの範囲を保存する
実行モジュールとしての処理と、
プロセッサが実行する命令のキャッシュとして、実行モジュールが保存する命令の複製を保存し、
保存した命令に関連するアドレスとして、実行モジュールにおける命令のアドレスを含むエントリを保存し、
エントリが保存するアドレスと、実行モジュールが保存するアドレスの範囲とを用いて、複製として保存する命令の中で、新たな命令と置き換える命令を決定する
命令キャッシュとしての処理と
を実行させる。
A program in one form of the present invention is
In an information processing device including a processor that executes instructions,
Stores the instructions that the processor executes,
Processing as an execution module that stores a range of addresses that store instructions to be cached with priority,
Stores a copy of the instructions stored by the execution module as a cache of instructions executed by the processor,
saving an entry containing the address of the instruction in the execution module as an address associated with the saved instruction;
Using the address stored by the entry and the range of addresses stored by the execution module, an instruction to be replaced with a new instruction is determined from among the instructions to be stored as a copy. Processing as an instruction cache is executed.

本発明に基づけば、命令キャッシュにおける所定の命令の置き換えを低減するとの効果を奏することができる。 According to the present invention, it is possible to reduce the number of replacements of predetermined instructions in the instruction cache.

図1は、第1の実施形態にかかる情報処理装置の構成の一例を示すブロック図である。FIG. 1 is a block diagram showing an example of the configuration of an information processing apparatus according to the first embodiment. 図2は、命令キャッシュの構成の一例を示す図である。FIG. 2 is a diagram illustrating an example of the configuration of an instruction cache. 図3は、エントリの構成の一例を示す図である。FIG. 3 is a diagram showing an example of the structure of an entry. 図4は、4wayに対応したエントリの構成の一例を示す図である。FIG. 4 is a diagram showing an example of the configuration of an entry compatible with 4-way. 図5は、キャッシュ制御部における命令を判定する動作を説明するための図である。FIG. 5 is a diagram for explaining the operation of determining an instruction in the cache control unit. 図6は、キャッシュ制御部における置き換える命令を決める動作の一例を示すフロー図である。FIG. 6 is a flowchart illustrating an example of an operation of determining a replacement instruction in the cache control unit. 図7は、実行モジュールにおける領域の一例を示す図である。FIG. 7 is a diagram showing an example of an area in an execution module. 図8は、第2の実施形態にかかる情報処理装置の構成の一例を示すブロック図である。FIG. 8 is a block diagram showing an example of the configuration of an information processing device according to the second embodiment. 図9は、情報処理装置のハードウェア構成の一例を示すブロック図である。FIG. 9 is a block diagram showing an example of the hardware configuration of the information processing device.

次に、図面を参照して、本発明における実施形態について説明する。
なお、各図面は、本発明の実施形態を説明するためのものである。ただし、本発明は、各図面の記載に限られるわけではない。また、各図面の同様の構成には、同じ番号を付し、その繰り返しの説明を、省略する場合がある。また、以下の説明に用いる図面において、本発明の説明に関係しない部分の構成については、記載を省略し、図示しない場合もある。また、図面中の矢印の方向は、一例を示すものであり、ブロック間の信号の向きを限定するものではない。
Next, embodiments of the present invention will be described with reference to the drawings.
Note that each drawing is for explaining an embodiment of the present invention. However, the present invention is not limited to the description in each drawing. Further, similar configurations in each drawing may be designated by the same numbers, and repeated description thereof may be omitted. In addition, in the drawings used in the following explanation, the configuration of portions that are not related to the explanation of the present invention may be omitted and may not be illustrated. Furthermore, the directions of the arrows in the drawings are for illustrative purposes only, and do not limit the direction of signals between blocks.

なお、以下の説明に用いる命令は、1つの命令でもよく、複数の命令の組合せである命令列でもよい。例えば、各実施形態は、複数の命令用のパイプライン(wayとも呼ぶ)を備えていてもよい。ただし、以下の説明において、命令の構成を区別する必要がない場合は、単に「命令」と呼ぶ。 Note that the instruction used in the following explanation may be a single instruction, or may be an instruction sequence that is a combination of multiple instructions. For example, each embodiment may include a pipeline (also referred to as a way) for multiple instructions. However, in the following description, if there is no need to distinguish the structure of an instruction, it will simply be referred to as an "instruction."

また、以下の説明において、命令キャッシュにおいて置き換えを低減する対象となる命令(所定の命令)、つまり、命令キャッシュに優先的にキャッシュされる命令を、「優先命令」と呼ぶ。また、命令キャッシュおいて優先命令より優先的に置き換えられる命令を「非優先命令」と呼ぶ。 Furthermore, in the following description, an instruction (predetermined instruction) whose replacement is to be reduced in the instruction cache, that is, an instruction that is preferentially cached in the instruction cache is referred to as a "priority instruction." Further, an instruction that is replaced with priority over a priority instruction in the instruction cache is called a "non-priority instruction."

なお、優先命令は、任意である。例えば、優先命令は、所定の頻度より多く実行される命令である。あるいは、優先命令は、所定の間隔で実行される命令である。 Note that the priority command is arbitrary. For example, a priority instruction is an instruction that is executed more often than a predetermined frequency. Alternatively, priority instructions are instructions that are executed at predetermined intervals.

<第1の実施形態>
以下、図面を参照して、第1の実施形態について説明する。
<First embodiment>
The first embodiment will be described below with reference to the drawings.

[構成の説明]
図1は、第1の実施形態にかかる情報処理装置10の構成の一例を示すブロック図である。
[Configuration description]
FIG. 1 is a block diagram showing an example of the configuration of an information processing device 10 according to the first embodiment.

情報処理装置10は、命令キャッシュ100と、ローダ103と、実行モジュール120と、プロセッサ130とを含む。 Information processing device 10 includes an instruction cache 100, a loader 103, an execution module 120, and a processor 130.

実行モジュール120は、情報処理装置10のメモリ(図示せず)の上に生成され、プロセッサ130が実行する命令を含む。実行モジュール120は、その他の情報(例えば、実行に用いられるデータ)を含んでもよい。 The execution module 120 is generated on the memory (not shown) of the information processing device 10 and includes instructions to be executed by the processor 130. Execution module 120 may also include other information (eg, data used for execution).

プロセッサ130は、実行モジュール120に含まれる命令を実行する。その際、プロセッサ130は、命令のキャッシュとして、命令キャッシュ100を用いる。 Processor 130 executes instructions contained in execution module 120. At this time, the processor 130 uses the instruction cache 100 as a cache for instructions.

なお、プロセッサ130は、命令キャッシュ100に加え、他のキャッシュ(例えば、データキャシュ)を用いてもよい。 Note that the processor 130 may use another cache (for example, a data cache) in addition to the instruction cache 100.

ローダ103は、実行モジュール120を生成する。 The loader 103 generates an execution module 120.

命令キャッシュ100は、実行モジュール120の命令の中で、プロセッサ130が実行する命令をキャッシュする。つまり、命令キャッシュ100は、命令のキャッシュとして、実行モジュール120に含まれる命令の複製を保存する。 The instruction cache 100 caches instructions to be executed by the processor 130 among the instructions of the execution module 120. That is, the instruction cache 100 stores copies of instructions included in the execution module 120 as an instruction cache.

そして、命令キャッシュ100は、後ほど説明するように、優先命令の置き換えを削減するように動作する。 The instruction cache 100 then operates to reduce replacement of priority instructions, as will be explained later.

続いて、図面を参照して、各構成の詳細を説明する。 Next, details of each configuration will be explained with reference to the drawings.

なお、プロセッサ130の構成及び動作は、一般的なプロセッサと同様のため、詳細な説明を省略する。 Note that the configuration and operation of the processor 130 are similar to those of a general processor, so a detailed explanation will be omitted.

(実行モジュール120)
実行モジュール120は、アドレス記憶部101と、命令記憶部124とを含む。
(Execution module 120)
Execution module 120 includes an address storage section 101 and an instruction storage section 124.

命令記憶部124は、プロセッサ130が実行する命令を記憶する。図1に示されている命令記憶部124は、命令を記憶する構成の一例として、非優先命令記憶部121と、優先命令記憶部122とを含む。 The instruction storage unit 124 stores instructions to be executed by the processor 130. The instruction storage unit 124 shown in FIG. 1 includes a non-priority instruction storage unit 121 and a priority instruction storage unit 122 as an example of a configuration for storing instructions.

非優先命令記憶部121は、非優先命令を保存する。 The non-priority instruction storage unit 121 stores non-priority instructions.

優先命令記憶部122は、優先命令を保存する。 The priority instruction storage unit 122 stores priority instructions.

アドレス記憶部101は、優先命令記憶部122のアドレスの範囲を保存する。 The address storage unit 101 stores the address range of the priority instruction storage unit 122.

なお、アドレス記憶部101は、非優先命令記憶部121のアドレスの範囲を保存してもよい。この場合、以下の説明において、情報処理装置10は、優先命令のアドレスの範囲として、命令記憶部124のアドレスの範囲の中で、アドレス記憶部101が保存するアドレスの範囲を除いたアドレスの範囲を用いて動作すればよい。 Note that the address storage section 101 may store the address range of the non-priority instruction storage section 121. In this case, in the following description, the information processing device 10 uses the address range of the priority instruction as the address range of the instruction storage unit 124 excluding the address range stored in the address storage unit 101. It should work using .

このように、命令記憶部124は、優先命令と、その他の命令(非優先命令)とを異なるアドレスの範囲に保存する。 In this way, the instruction storage unit 124 stores priority instructions and other instructions (non-priority instructions) in different address ranges.

図7は、実行モジュール120における領域の一例を示す図である。 FIG. 7 is a diagram showing an example of areas in the execution module 120.

図7に示されている実行モジュール120は、下限アドレス700と、上限アドレス701と、非優先命令領域702と、優先命令領域703とを含む。 The execution module 120 shown in FIG. 7 includes a lower limit address 700, an upper limit address 701, a non-priority instruction area 702, and a priority instruction area 703.

なお、図7における領域などの配置は、一例である。実行モジュール120における領域などの配置は、図7に限定されない。例えば、下限アドレス700及び上限アドレス701は、最上位アドレスに配置されてもよい。 Note that the arrangement of regions and the like in FIG. 7 is an example. The arrangement of areas in the execution module 120 is not limited to that shown in FIG. 7. For example, the lower limit address 700 and the upper limit address 701 may be placed at the highest address.

優先命令領域703は、優先命令、つまり、命令キャッシュ100における置き換えを低減する命令を保存する領域である。 The priority instruction area 703 is an area for storing priority instructions, that is, instructions that reduce replacement in the instruction cache 100.

非優先命令領域702は、その他の命令(非優先命令)を保存する領域である。 The non-priority instruction area 702 is an area for storing other instructions (non-priority instructions).

下限アドレス700は、優先命令領域703の下限のアドレスを保存する。 The lower limit address 700 stores the lower limit address of the priority instruction area 703.

上限アドレス701は、優先命令領域703の上限のアドレスを保存する。 The upper limit address 701 stores the upper limit address of the priority instruction area 703.

下限アドレス700及び上限アドレス701が、アドレス記憶部101の一例である。 The lower limit address 700 and the upper limit address 701 are examples of the address storage section 101.

非優先命令領域702及び優先命令領域703が、命令記憶部124の一例である。 The non-priority instruction area 702 and the priority instruction area 703 are examples of the instruction storage section 124.

なお、命令記憶部124は、複数の非優先命令領域702及び優先命令領域703を含んでもよい。 Note that the instruction storage unit 124 may include a plurality of non-priority instruction areas 702 and a plurality of priority instruction areas 703.

あるいは、非優先命令領域702及び優先命令領域703は、連続せずに、実行モジュール120において、離れたアドレスに配置されてもよい。 Alternatively, the non-priority instruction area 702 and the priority instruction area 703 may be placed at separate addresses in the execution module 120 without being consecutive.

このように、実行モジュール120は、実行モジュール120における所定のアドレスの範囲を、非優先命令領域702及び優先命令領域703として用いればよい。 In this way, the execution module 120 may use a predetermined address range in the execution module 120 as the non-priority instruction area 702 and the priority instruction area 703.

なお、命令記憶部124は、その他の領域を含んでもよい。 Note that the instruction storage unit 124 may include other areas.

また、アドレス記憶部101が保存するアドレスの範囲を示す情報は、アドレスの上限及び下限の組合せに限定されない。例えば、アドレス記憶部101は、アドレスの範囲として、アドレスの上限又は下限と、範囲の長さ又は容量とを保存してもよい。 Further, the information indicating the range of addresses stored in the address storage unit 101 is not limited to the combination of upper and lower limits of addresses. For example, the address storage unit 101 may store the upper or lower limit of the address and the length or capacity of the range as the address range.

(ローダ103)
ローダ103は、所定のやり方に沿って、実行モジュール120を生成する。実行モジュール120の生成のやり方は、一般的なローダと同様のため、詳細な説明を省略する。
(Loader 103)
The loader 103 generates the execution module 120 according to a predetermined method. The method of generating the execution module 120 is similar to that of a general loader, so a detailed explanation will be omitted.

ただし、ローダ103は、実行モジュール120の生成の際に、実行モジュール120の所定のアドレスの範囲に、優先命令を配置する。 However, when generating the execution module 120, the loader 103 places priority instructions in a predetermined address range of the execution module 120.

なお、ローダ103がアドレスの範囲を取得するやり方は、任意である。例えば、ローダ103は、利用者から、所定のアドレスの範囲を取得してもよい。あるいは、ローダ103は、所定の規則に沿ってアドレスの範囲を生成してもよい。例えば、ローダ103は、実行モジュール120の容量の所定の比率の範囲を、アドレスの範囲として用いてもよい。 Note that the method by which the loader 103 acquires the address range is arbitrary. For example, the loader 103 may acquire a predetermined address range from the user. Alternatively, the loader 103 may generate the address range according to predetermined rules. For example, the loader 103 may use a range of a predetermined ratio of the capacity of the execution module 120 as the address range.

ローダ103は、アドレスの範囲を、実行モジュール120のアドレス記憶部101に保存する。 The loader 103 stores the address range in the address storage unit 101 of the execution module 120.

以下、優先命令に関連する構成を説明する。 The configuration related to priority instructions will be explained below.

ローダ103は、命令指定部104と、命令配置決定部105と、命令埋め込み部106とを含む。 The loader 103 includes an instruction specifying section 104, an instruction placement determining section 105, and an instruction embedding section 106.

命令指定部104は、優先命令を指定する。 The instruction specifying unit 104 specifies a priority instruction.

命令指定部104において、優先命令を指定するやり方は、限定されない。例えば、命令指定部104は、図示しない利用者が操作する装置から、優先命令に関する指定を取得してもよい。あるいは、命令指定部104は、所定の規則、情報処理装置10の構成、又は、実行モジュール120における実行内容を基に、優先命令を指定してもよい。 The method of specifying a priority instruction in the instruction specifying unit 104 is not limited. For example, the command designation unit 104 may acquire a designation regarding a priority command from a device (not shown) operated by a user. Alternatively, the command designation unit 104 may designate a priority command based on a predetermined rule, the configuration of the information processing device 10, or the content of execution in the execution module 120.

命令配置決定部105は、実行モジュール120に含まれる命令を配置するアドレスを決定する。より詳細には、例えば、命令配置決定部105は、優先命令については、実行モジュール120の優先命令記憶部122に配置されるように、アドレスを決定する。また、命令配置決定部105は、非優先命令については、実行モジュール120の非優先命令記憶部121に配置されるようにアドレスを決定する。例えば、命令配置決定部105は、図7に示されている下限アドレス700及び上限アドレス701を用いて、命令を配置するアドレスを決定する。 The instruction placement determining unit 105 determines an address at which an instruction included in the execution module 120 is placed. More specifically, for example, the instruction placement determining unit 105 determines the address of the priority instruction so that it is placed in the priority instruction storage unit 122 of the execution module 120. Furthermore, the instruction placement determining unit 105 determines addresses for non-priority instructions so that they are placed in the non-priority instruction storage unit 121 of the execution module 120. For example, the instruction placement determining unit 105 uses the lower limit address 700 and upper limit address 701 shown in FIG. 7 to determine the address where the instruction is placed.

命令埋め込み部106は、命令配置決定部105が決定した実行モジュール120のアドレスに、命令を埋め込む。 The instruction embedding unit 106 embeds the instruction in the address of the execution module 120 determined by the instruction placement determining unit 105.

上記のように構成されたローダ103は、優先命令を、実行モジュール120における優先命令記憶部122のアドレスの範囲に埋め込む。 The loader 103 configured as described above embeds the priority instruction in the address range of the priority instruction storage section 122 in the execution module 120.

上記のようなローダ103の動作の結果、命令キャッシュ100は、後ほど説明するように、実行モジュール120における命令のアドレスを用いて、優先命令であるか否かを判定できる。そして、命令キャッシュ100は、判定の結果を用いて、優先命令を命令キャッシュ100に残すような動作を実現できる。 As a result of the above-described operation of the loader 103, the instruction cache 100 can determine whether the instruction is a priority instruction using the address of the instruction in the execution module 120, as will be explained later. Then, the instruction cache 100 can implement an operation such as leaving the priority instruction in the instruction cache 100 using the result of the determination.

(命令キャッシュ100)
命令キャッシュ100は、キャッシュ制御部102と、命令記憶部111と、エントリ記憶部112とを含む。
(Instruction cache 100)
Instruction cache 100 includes a cache control section 102, an instruction storage section 111, and an entry storage section 112.

キャッシュ制御部102は、命令キャッシュ100における各構成を制御して、プロセッサ130が実行する命令のキャッシュを実現する。 The cache control unit 102 controls each component in the instruction cache 100 to realize caching of instructions executed by the processor 130.

命令記憶部111は、キャッシュ制御部102に制御されて、キャッシュとして、実行モジュール120に含まれる命令の中で、プロセッサ130が実行する命令を保存する。 The instruction storage unit 111 is controlled by the cache control unit 102 and stores, as a cache, instructions to be executed by the processor 130 among the instructions included in the execution module 120.

なお、命令キャッシュ100が保存する命令は、実行モジュール120に保存されている命令である。そのため、命令キャッシュ100が保存する命令は、実行モジュール120が保存する命令の複製でもある。 Note that the instructions stored in the instruction cache 100 are the instructions stored in the execution module 120. Therefore, the instructions stored by the instruction cache 100 are also copies of the instructions stored by the execution module 120.

エントリ記憶部112は、命令記憶部111が保存している命令(キャッシュしている命令)のアドレスに関連する情報(以下、「エントリ」と呼ぶ)を保存する。エントリについては、後ほど説明する。 The entry storage unit 112 stores information (hereinafter referred to as “entry”) related to the address of the instruction (cached instruction) stored in the instruction storage unit 111. Entries will be explained later.

以下の説明において、命令キャッシュ100は、複数の命令を保存しているとする。 In the following description, it is assumed that the instruction cache 100 stores a plurality of instructions.

なお、命令キャッシュ100は、キャッシュとして、複数の命令を含む命令列(コマンド・アレイ)を保存してもよい。 Note that the instruction cache 100 may store, as a cache, an instruction string (command array) including a plurality of instructions.

図2は、命令キャッシュ100の構成の一例を示す図である。なお、図2は、命令として命令列(コマンド・アレイ)を用いている場合の一例である。 FIG. 2 is a diagram showing an example of the configuration of the instruction cache 100. Note that FIG. 2 is an example in which an instruction string (command array) is used as the instruction.

図2に示されている命令キャッシュ100は、キャッシュ制御部200と、アドレスアレイ201と、データアレイ202とを含む。 Instruction cache 100 shown in FIG. 2 includes a cache controller 200, an address array 201, and a data array 202.

キャッシュ制御部200は、図1におけるキャッシュ制御部102に相当する。 The cache control unit 200 corresponds to the cache control unit 102 in FIG.

アドレスアレイ201は、エントリ記憶部112の一例であり、命令キャッシュ100に保存されている命令のアドレスに関連する情報(エントリ)を保存する。 The address array 201 is an example of the entry storage unit 112 and stores information (entries) related to addresses of instructions stored in the instruction cache 100.

データアレイ202は、命令記憶部111の一例であり、キャッシュとして、プロセッサ130が実行する命令を保存する。 The data array 202 is an example of the instruction storage unit 111, and serves as a cache for storing instructions to be executed by the processor 130.

図3は、エントリ310の構成の一例を示す図である。 FIG. 3 is a diagram showing an example of the configuration of the entry 310.

エントリ310は、アドレス300と、Validビット301と、Priorityビット302とを含む。 Entry 310 includes address 300, Valid bit 301, and Priority bit 302.

アドレス300は、エントリ310に対応する命令のアドレス(実行モジュール120において配置されているアドレス)を保存する。なお、アドレス300は、その他のアドレス(例えば、対応する命令のデータアレイ202におけるアドレス)を、保存してもよい。 Address 300 stores the address of the instruction corresponding to entry 310 (the address located in execution module 120). Note that the address 300 may store other addresses (eg, the address of the corresponding instruction in the data array 202).

Validビット301は、エントリ310が有効であるか否かを示す情報である。 Valid bit 301 is information indicating whether or not entry 310 is valid.

エントリ310が有効とは、エントリ310が実際の命令と関連付けられていることである。この場合、アドレス300は、有効なアドレスを保存している。エントリ310が無効とは、エントリ310が命令と関連付けられていないことである。 Entry 310 is valid if entry 310 is associated with an actual instruction. In this case, address 300 stores a valid address. Entry 310 being invalid means that entry 310 is not associated with an instruction.

例えば、Validビット301が「1」の場合、エントリ310は有効である。Validビット301が「0」の場合、エントリ310は、有効ではない。なお、Validビット301は、1ビットの情報に限定されない。例えば、Validビット301は、1Byteの情報でもよい。 For example, if Valid bit 301 is "1", entry 310 is valid. If Valid bit 301 is "0", entry 310 is not valid. Note that the Valid bit 301 is not limited to 1-bit information. For example, the Valid bit 301 may be 1 byte of information.

キャッシュ制御部102は、エントリ310に対応した命令を命令記憶部111に保存した場合に、Validビット301を「有効(例えば、「1」)」に変更する。また、キャッシュ制御部102は、エントリ310を開放した場合に、Validビット301を「無効(例えば、「0」)」に変更する。 When the cache control unit 102 stores the instruction corresponding to the entry 310 in the instruction storage unit 111, the cache control unit 102 changes the Valid bit 301 to “valid (for example, “1”). Further, when the entry 310 is released, the cache control unit 102 changes the Valid bit 301 to "invalid (for example, "0")".

Priorityビット302は、そのエントリ310に対応する命令が優先命令であるか否かを示す情報である。Priorityビット302も、1ビットに限られず、例えが、1Byteの情報でもよい。 The Priority bit 302 is information indicating whether the instruction corresponding to the entry 310 is a priority instruction. The Priority bit 302 is also not limited to 1 bit, and may be 1 Byte of information, for example.

キャッシュ制御部102は、命令をキャッシュする場合に、命令の実行モジュール120におけるアドレスと、アドレス記憶部101とを用いて、その命令が優先命令であるか否かを判定して、Priorityビット302を設定する。そして、キャッシュ制御部102は、命令を置き換える場合において、エントリ310に対応する命令が優先命令であるか否かの判定に、Priorityビット302を用いる。 When caching an instruction, the cache control unit 102 uses the address in the instruction execution module 120 and the address storage unit 101 to determine whether the instruction is a priority instruction and sets the Priority bit 302. Set. When replacing an instruction, the cache control unit 102 uses the Priority bit 302 to determine whether the instruction corresponding to the entry 310 is a priority instruction.

ただし、キャッシュ制御部102は、命令を置き換える場合における命令が優先命令であるか否かの判定において、Priorityビット302を用いなくてもよい。例えば、キャッシュ制御部102は、命令を置き換える場合に、エントリに対応する命令の実行モジュール120におけるアドレス及びアドレス記憶部101を用いて、置き換える命令を判定してもよい。この場合、エントリ310は、Priorityビット302を含まなくてもよい。 However, the cache control unit 102 does not need to use the Priority bit 302 in determining whether an instruction is a priority instruction when replacing an instruction. For example, when replacing an instruction, the cache control unit 102 may determine the instruction to be replaced using the address in the execution module 120 of the instruction corresponding to the entry and the address storage unit 101. In this case, entry 310 may not include Priority bit 302.

なお、図3は、Validビット301を「V」、Priorityビット302を「P」を用いて表している。 Note that in FIG. 3, the Valid bit 301 is represented by "V", and the Priority bit 302 is represented by "P".

アドレスアレイ201(つまり、エントリ記憶部112)は、複数のwayに対応した命令を保存してもよい。 The address array 201 (that is, the entry storage unit 112) may store instructions corresponding to a plurality of ways.

図4は、4wayに対応したエントリ414の構成の一例を示す図である。 FIG. 4 is a diagram showing an example of the configuration of an entry 414 that supports 4-way.

図4は、一例として、4wayの命令を示している。ただし、本実施形態におけるwayの数は、4に限られず、4未満でもよく、5以上でもよい。 FIG. 4 shows a 4-way instruction as an example. However, the number of ways in this embodiment is not limited to four, and may be less than four, or may be five or more.

図4に示されているエントリ414は、図3に示されたエントリ310に相当するエントリを4つ含む。 Entry 414 shown in FIG. 4 includes four entries that correspond to entry 310 shown in FIG.

1つ目のエントリは、way0のエントリであり、アドレス400と、Validビット401と、Priorityビット402とを含む。 The first entry is a way0 entry and includes an address 400, a Valid bit 401, and a Priority bit 402.

2つ目のエントリは、way1のエントリであり、アドレス403、Validビット404と、Priorityビット405とを含む。 The second entry is a way 1 entry, and includes an address 403, a Valid bit 404, and a Priority bit 405.

3つ目のエントリは、way2のエントリであり、アドレス406と、Validビット407と、Priorityビット408とを含む。 The third entry is a way2 entry and includes an address 406, a Valid bit 407, and a Priority bit 408.

4つ目のエントリは、way3のエントリであり、アドレス409と、Validビット410と、Priorityビット411とを含む。 The fourth entry is a way3 entry and includes an address 409, a Valid bit 410, and a Priority bit 411.

さらに、図4に示されているエントリ414は、非優先エントリ412と、優先エントリ413とを含む。 Additionally, the entries 414 shown in FIG. 4 include non-priority entries 412 and priority entries 413.

非優先エントリ412は、非優先命令に関連するエントリを示す情報(例えば、非優先命令に関連するエントリのwayの値)を保存する。 The non-priority entry 412 stores information indicating an entry related to the non-priority instruction (for example, the value of the way of the entry related to the non-priority instruction).

優先エントリ413は、優先命令に関連するエントリを示す情報(例えば、優先命令に関連するwayの値)を保存する。 The priority entry 413 stores information indicating an entry related to the priority instruction (for example, the value of a way related to the priority instruction).

なお、エントリ414は、その他の情報を含んでもよい。また、エントリ414は、上記の一部を含まなくてもよい。 Note that the entry 414 may include other information. Furthermore, the entry 414 may not include some of the above.

エントリ414が非優先エントリ412を含む場合、キャッシュ制御部102は、非優先エントリ412を用いて、非優先命令に対応するエントリがあるか否かの判定できる。なお、キャッシュ制御部102は、優先エントリ413に含まれないエントリを、非優先命令に対応するエントリを判定してもよい。 If the entry 414 includes a non-priority entry 412, the cache control unit 102 can use the non-priority entry 412 to determine whether there is an entry corresponding to the non-priority instruction. Note that the cache control unit 102 may determine an entry not included in the priority entry 413 as an entry corresponding to a non-priority instruction.

このように、キャッシュ制御部102は、非優先エントリ412及び優先エントリ413のいずれかを用いて動作してもよい。そのため、エントリ414は、非優先エントリ412及び優先エントリ413のどちらかを含まなくてもよい。 In this way, the cache control unit 102 may operate using either the non-priority entry 412 or the priority entry 413. Therefore, the entry 414 does not have to include either the non-priority entry 412 or the priority entry 413.

なお、非優先エントリ412及び優先エントリ413のどちらにも含まれないエントリは、空エントリである。そこで、キャッシュ制御部102は、非優先エントリ412及び優先エントリ413を用いて空エントリを判定してもよい。この場合、エントリ414は、Validビット401、404、407及び410を含まなくてもよい。 Note that an entry that is not included in either the non-priority entry 412 or the priority entry 413 is an empty entry. Therefore, the cache control unit 102 may use the non-priority entry 412 and the priority entry 413 to determine an empty entry. In this case, entry 414 may not include Valid bits 401, 404, 407, and 410.

なお、キャッシュ制御部102は、Priorityビット402、405、408及び411を用いて、非優先エントリ412及び優先エントリ413に情報を設定すればよい。 Note that the cache control unit 102 may use the Priority bits 402, 405, 408, and 411 to set information in the non-priority entry 412 and the priority entry 413.

ただし、キャッシュ制御部102は、各エントリに対応する命令の実行モジュール120におけるアドレスと、アドレス記憶部101とを用いて、非優先エントリ412及び優先エントリ413を設定してもよい。この場合、エントリ414は、Priorityビット402、405、408及び411を含まなくてもよい。 However, the cache control unit 102 may set the non-priority entry 412 and the priority entry 413 using the address in the execution module 120 of the instruction corresponding to each entry and the address storage unit 101. In this case, entry 414 may not include Priority bits 402, 405, 408, and 411.

図5は、キャッシュ制御部102における命令を判定する動作を説明するための図である。 FIG. 5 is a diagram for explaining the operation of determining an instruction in the cache control unit 102.

図5に示されているキャッシュ制御部102の動作は、図7に示されている実行モジュール120を用いる場合、より詳細には、下限アドレス500及び上限アドレス501を用いる場合の動作の一例である。 The operation of the cache control unit 102 shown in FIG. 5 is an example of the operation when using the execution module 120 shown in FIG. 7, more specifically, when using the lower limit address 500 and the upper limit address 501. .

なお、キャッシュ制御部102は、下限アドレス500及び上限アドレス501として、実行モジュール120が保存する下限アドレス700及び上限アドレス701を用いてもよい。あるいは、キャッシュ制御部102は、キャッシュ制御部102内に、実行モジュール120が保存する下限アドレス700及び上限アドレス701の複製を保存してもよい。 Note that the cache control unit 102 may use the lower limit address 700 and upper limit address 701 stored by the execution module 120 as the lower limit address 500 and the upper limit address 501. Alternatively, the cache control unit 102 may store copies of the lower limit address 700 and the upper limit address 701 stored by the execution module 120 in the cache control unit 102.

まず、キャッシュ制御部102は、命令のアドレス(詳細には、命令に対応するエントリに含まれるアドレス)と、下限アドレス500及び上限アドレス501を比較する。 First, the cache control unit 102 compares the address of the instruction (specifically, the address included in the entry corresponding to the instruction) with the lower limit address 500 and the upper limit address 501.

なお、キャッシュ制御部102は、比較器503を含み、比較器503を用いてアドレスを比較してもよい。あるいは、キャッシュ制御部102は、ソフトウェアの処理として、アドレスを比較してもよい。 Note that the cache control unit 102 may include a comparator 503, and use the comparator 503 to compare addresses. Alternatively, the cache control unit 102 may compare the addresses as a software process.

命令のアドレスが下限アドレス500及び上限アドレス501の範囲に含まれる場合、キャッシュ制御部102は、その命令を、優先命令(優先的に命令キャッシュ100に残す命令)と判定する。 If the address of the instruction is included in the range of the lower limit address 500 and the upper limit address 501, the cache control unit 102 determines that the instruction is a priority instruction (an instruction to be preferentially left in the instruction cache 100).

命令のアドレスが下限アドレス500及び上限アドレス501の範囲に含まれない場合、キャッシュ制御部102は、その命令を、非優先命令(優先的には命令キャッシュ100に残さない命令)と判定する。 If the address of the instruction is not included in the range of the lower limit address 500 and the upper limit address 501, the cache control unit 102 determines that the instruction is a non-priority instruction (an instruction that is not preferentially left in the instruction cache 100).

図6は、キャッシュ制御部102における置き換える命令に決める動作の一例を示すフロー図である。命令の置き換えは、プロセッサ130が実行する命令が命令キャッシュ100にない場合(キャッシュミスの場合)に発生する。なお、キャッシュミスの判定などは、一般的なキャッシュと同様のため、詳細な説明を省略する。 FIG. 6 is a flow diagram illustrating an example of an operation in which the cache control unit 102 determines an instruction to be replaced. Instruction replacement occurs when the instruction to be executed by the processor 130 is not in the instruction cache 100 (in the case of a cache miss). Note that determination of a cache miss and the like are similar to those of a general cache, so a detailed explanation will be omitted.

キャッシュミスの命令など新たな命令をキャッシュに追加する場合に、キャッシュ制御部102は、以下で説明する動作を実行する。 When adding a new instruction such as a cache miss instruction to the cache, the cache control unit 102 performs the operations described below.

まず、キャッシュ制御部102は、空エントリ(未使用のエントリ)があるか否かを判定する(ステップS801)。例えば、キャッシュ制御部102は、図3に示したValidビット301、又は、図4に示したValidビット401、404、407、及び410を用いて、空エントリを判定すればよい。 First, the cache control unit 102 determines whether there is an empty entry (unused entry) (step S801). For example, the cache control unit 102 may use the Valid bit 301 shown in FIG. 3 or the Valid bits 401, 404, 407, and 410 shown in FIG. 4 to determine an empty entry.

空エントリがある場合(ステップS801でYes)、キャッシュ制御部102は、新しい命令用のエントリとして、その空エントリを使用する(ステップS803)。つまり、キャッシュ制御部102は、空エントリを用いて、新しい命令をキャッシュする。 If there is an empty entry (Yes in step S801), the cache control unit 102 uses the empty entry as an entry for a new instruction (step S803). In other words, the cache control unit 102 caches new instructions using empty entries.

空エントリがない場合(ステップS801でNo)、キャッシュ制御部102は、非優先命令に対応するエントリがあるか否かを判定する(ステップS805)。例えば、キャッシュ制御部102は、図3に示されているPriorityビット302、又は、図4に示されている非優先エントリ412を用いて、判定すればよい。 If there is no empty entry (No in step S801), the cache control unit 102 determines whether there is an entry corresponding to a non-priority instruction (step S805). For example, the cache control unit 102 may make the determination using the Priority bit 302 shown in FIG. 3 or the non-priority entry 412 shown in FIG. 4.

例えば、非優先エントリ412がway番号を保存している場合、キャッシュ制御部102は、非優先命令に対応するエントリがあると判定する。非優先エントリ412が、way番号を保存していない、又は、存在しないway番号を保存している場合、キャッシュ制御部102は、非優先命令に対応するエントリがないと判定する。 For example, if the non-priority entry 412 stores a way number, the cache control unit 102 determines that there is an entry corresponding to the non-priority instruction. If the non-priority entry 412 does not store a way number or stores a non-existent way number, the cache control unit 102 determines that there is no entry corresponding to the non-priority instruction.

非優先命令に対応するエントリがある場合(ステップS805でYes)、キャッシュ制御部102は、そのエントリの中からいずれかのエントリを選択し、選択したエントリに対応する命令と新しい命令とを置き換える(ステップS807)。例えば、キャッシュ制御部102は、非優先エントリ412が保存しているway番号のエントリに対応する命令と新しい命令とを置き換える。なお、複数の非優先のエントリがある場合、キャッシュ制御部102は、所定の規則に沿って、エントリを選択する。 If there is an entry corresponding to a non-priority instruction (Yes in step S805), the cache control unit 102 selects one of the entries and replaces the instruction corresponding to the selected entry with a new instruction ( Step S807). For example, the cache control unit 102 replaces the instruction corresponding to the entry with the way number stored in the non-priority entry 412 with the new instruction. Note that if there are multiple non-priority entries, the cache control unit 102 selects an entry according to a predetermined rule.

非優先命令に関連するエントリがない場合(ステップS805でNo)、キャッシュ制御部102は、優先命令に関連するエントリから、所定の規則に沿って、置き換えるエントリを選択する。そして、キャッシュ制御部102は、選択したエントリに関連する命令と新しい命令とを置き換える(ステップS809)。例えば、キャッシュ制御部102は、優先エントリ413が保存するway番号のエントリから1つのエントリを選択する。 If there is no entry related to the non-priority instruction (No in step S805), the cache control unit 102 selects a replacement entry from the entries related to the priority instruction according to a predetermined rule. Then, the cache control unit 102 replaces the instruction related to the selected entry with the new instruction (step S809). For example, the cache control unit 102 selects one entry from the entries with the way number stored in the priority entry 413.

なお、エントリの選択に用いられる所定の規則は、任意である。例えば、所定の規則は、Least Recently Used(LRU)、又は、Least Frequency Used(LFU)でもよい。 Note that the predetermined rule used for selecting entries is arbitrary. For example, the predetermined rule may be Least Recently Used (LRU) or Least Frequency Used (LFU).

このように、空エントリがある場合には、情報処理装置10は、新しい命令のエントリとして、空エントリを用いる。空エントリがなく、優先命令に対応するエントリと、非優先命令に対応するエントリとがある場合、情報処理装置10は、上記の動作を基に、新しい命令のエントリとして、非優先命令に対応するエントリを選択する。そのため、情報処理装置10は、上記の動作を基に、優先命令を、非優先命令より命令キャッシュ100に残すことができる。 In this way, if there is an empty entry, the information processing device 10 uses the empty entry as the entry for the new command. If there is no empty entry and there are entries corresponding to the priority instruction and entries corresponding to the non-priority instruction, the information processing device 10 responds to the non-priority instruction as a new instruction entry based on the above operation. Select an entry. Therefore, based on the above operation, the information processing device 10 can leave priority instructions in the instruction cache 100 more than non-priority instructions.

このような動作に基づいて、情報処理装置10は、命令キャッシュ100における、所定の命令(例えば、利用頻度が多い命令)の置き換えを低減する。 Based on such operations, the information processing device 10 reduces the number of replacements of predetermined instructions (for example, frequently used instructions) in the instruction cache 100.

[効果の説明]
次に第1の実施形態にかかる情報処理装置10の効果について説明する。
[Explanation of effects]
Next, the effects of the information processing device 10 according to the first embodiment will be explained.

第1の実施形態かかる情報処理装置10は、命令キャッシュ100における所定の命令(例えば、優先命令)の置き換えを低減するとの効果を得ることができる。 The information processing device 10 according to the first embodiment can obtain the effect of reducing replacement of a predetermined instruction (for example, a priority instruction) in the instruction cache 100.

その理由は、次のとおりである。 The reason is as follows.

情報処理装置10は、プロセッサ130と、命令キャッシュ100と、実行モジュール120とを含む。プロセッサ130は、命令を実行する。実行モジュール120は、命令記憶部124(第1の命令記憶部)と、アドレス記憶部101とを含む。命令記憶部124は、プロセッサ130が実行する命令を保存する。アドレス記憶部101は、命令記憶部124において、優先的にキャッシュする命令を保存するアドレスの範囲を保存する。命令キャッシュ100は、命令記憶部111(第2の命令記憶部)と、エントリ記憶部112と、キャッシュ制御部102とを含む。命令記憶部111は、プロセッサ130が実行する命令のキャッシュとして、実行モジュール120が保存する命令の複製を保存する。エントリ記憶部112は、命令記憶部111が保存した命令に関連するアドレスとして、実行モジュール120における命令のアドレスを含むエントリ310を保存する。キャッシュ制御部102は、エントリ310が保存するアドレスと、実行モジュール120が保存するアドレスの範囲とを用いて、複製として保存する命令の中で、新たな命令と置き換える命令を決定する。 Information processing device 10 includes a processor 130, an instruction cache 100, and an execution module 120. Processor 130 executes instructions. The execution module 120 includes an instruction storage section 124 (first instruction storage section) and an address storage section 101. The instruction storage unit 124 stores instructions to be executed by the processor 130. The address storage unit 101 stores a range of addresses in which instructions to be cached preferentially are stored in the instruction storage unit 124 . The instruction cache 100 includes an instruction storage section 111 (second instruction storage section), an entry storage section 112, and a cache control section 102. The instruction storage unit 111 stores copies of instructions stored by the execution module 120 as a cache of instructions executed by the processor 130. The entry storage unit 112 stores an entry 310 that includes the address of the instruction in the execution module 120 as an address related to the instruction stored in the instruction storage unit 111. The cache control unit 102 uses the address stored in the entry 310 and the range of addresses stored in the execution module 120 to determine which instruction to be replaced with a new instruction among the instructions stored as copies.

上記のように、実行モジュール120は、優先的にキャッシュに保存する命令を、アドレス記憶部101が記憶するアドレスの範囲に保存している。 As described above, the execution module 120 stores instructions to be preferentially stored in the cache in the address range stored in the address storage unit 101.

そのため、命令キャッシュ100は、命令の実行モジュール120におけるアドレスを用いて、キャッシュしている命令が優先的にキャッシュする命令であるか否かを判定できる。そして、命令キャッシュ100は、判定結果を用いて、優先的にキャッシュする命令を残すように、命令の置き換えを実行する。 Therefore, the instruction cache 100 can use the address of the instruction in the execution module 120 to determine whether the instruction being cached is an instruction to be cached preferentially. Then, the instruction cache 100 uses the determination result to perform instruction replacement so as to leave instructions to be cached preferentially.

そのため、このように構成された情報処理装置10は、命令キャッシュ100及び実行モジュール120の構成を用いて、命令キャッシュ100における所定の命令の置き換えを低減するとの効果を奏することができる。 Therefore, the information processing device 10 configured in this manner can have the effect of reducing replacement of a predetermined instruction in the instruction cache 100 by using the configuration of the instruction cache 100 and the execution module 120.

さらに、情報処理装置10は、ローダ103を含む。 Furthermore, the information processing device 10 includes a loader 103.

ローダ103は、命令指定部104と、命令配置決定部105と、命令埋め込み部106とを含む。命令指定部104は、実行モジュール120を生成するときに、実行モジュール120に含まれる命令の中で、優先的に命令キャッシュ100に保存する命令(優先命令)を指定する。命令配置決定部105は、実行モジュール120において、指定された命令を配置する実行モジュール120におけるアドレスを決定する。命令埋め込み部106は、決定したアドレスに指定された命令を埋め込む。 The loader 103 includes an instruction specifying section 104, an instruction placement determining section 105, and an instruction embedding section 106. When generating the execution module 120, the instruction specifying unit 104 specifies an instruction (priority instruction) to be preferentially stored in the instruction cache 100 among the instructions included in the execution module 120. The instruction placement determining unit 105 determines an address in the execution module 120 at which the designated instruction is placed in the execution module 120. The instruction embedding unit 106 embeds the specified instruction in the determined address.

このように構成されたローダ103は、命令キャッシュ100が上記動作を実現できるように実行モジュール120を生成することができる。 The loader 103 configured in this manner can generate the execution module 120 so that the instruction cache 100 can realize the above operations.

このように、第1の実施形態にかかる情報処理装置10は、所定の命令(例えば、頻繁に実行される命令)の命令キャッシュ100における置き換えを低減する。つまり、第1の実施形態にかかる情報処理装置10は、特許文献1における問題点を解決できる。 In this way, the information processing device 10 according to the first embodiment reduces the number of replacements of predetermined instructions (for example, frequently executed instructions) in the instruction cache 100. In other words, the information processing device 10 according to the first embodiment can solve the problems in Patent Document 1.

また、第1の実施形態にかかる情報処理装置10は、コア間での移動なども必要としない。したがって、第1の実施形態にかかる情報処理装置10は、特許文献2に記載された技術における問題点を解決し、プロセッサ130の実行効率の低下を低減するとの効果も奏することができる。 Further, the information processing device 10 according to the first embodiment does not require movement between cores. Therefore, the information processing device 10 according to the first embodiment can solve the problems in the technique described in Patent Document 2, and can also have the effect of reducing the decrease in execution efficiency of the processor 130.

<第2の実施形態>
なお、命令キャッシュ100、ローダ103及び、実行モジュール120は、同じ装置に含まれなくてもよい。例えば、ローダ103は、情報処理装置10とは異なる装置に設けられてもよい。
<Second embodiment>
Note that the instruction cache 100, loader 103, and execution module 120 do not need to be included in the same device. For example, the loader 103 may be provided in a device different from the information processing device 10.

あるいは、実行モジュール120の生成後、ローダ103は、削除されてもよい。 Alternatively, after generating the execution module 120, the loader 103 may be deleted.

次に、図面を参照して、第2の実施形態について説明する。 Next, a second embodiment will be described with reference to the drawings.

[構成の説明]
図8は、第2の実施形態にかかる情報処理装置11の構成の一例を示すブロック図である。
[Configuration description]
FIG. 8 is a block diagram showing an example of the configuration of the information processing device 11 according to the second embodiment.

情報処理装置11は、プロセッサ130と、命令キャッシュ100と、実行モジュール120とを含む。 Information processing device 11 includes a processor 130, an instruction cache 100, and an execution module 120.

プロセッサ130は、命令を実行する。 Processor 130 executes instructions.

実行モジュール120は、図示しないローダ103と同様の構成を用いて生成される。 The execution module 120 is generated using a configuration similar to that of the loader 103 (not shown).

実行モジュール120は、アドレス記憶部101と、命令記憶部124(第1の命令記憶部)とを含む。 The execution module 120 includes an address storage section 101 and an instruction storage section 124 (first instruction storage section).

命令記憶部124は、命令を保存する。 The instruction storage unit 124 stores instructions.

アドレス記憶部101は、命令記憶部124が保存する命令の中で、優先命令が保存されているアドレスの範囲を保存する。 The address storage unit 101 stores a range of addresses in which priority instructions are stored among the instructions stored in the instruction storage unit 124.

命令キャッシュ100は、命令記憶部111と、エントリ記憶部112と、キャッシュ制御部102とを含む。 Instruction cache 100 includes an instruction storage section 111, an entry storage section 112, and a cache control section 102.

命令記憶部111は、命令のキャッシュとして、命令の複製を保存する。 The instruction storage unit 111 stores copies of instructions as a cache of instructions.

エントリ記憶部112は、命令記憶部111に保存された命令のアドレスを含むエントリ310を保存する。 The entry storage unit 112 stores an entry 310 that includes the address of the instruction stored in the instruction storage unit 111.

キャッシュ制御部102は、アドレス記憶部101を用いて、命令記憶部124に保存されている命令が優先命令か否かを判定できる。 The cache control unit 102 can use the address storage unit 101 to determine whether the instruction stored in the instruction storage unit 124 is a priority instruction.

さらに、命令キャッシュ100が命令を置き換える場合においても、キャッシュ制御部102は、アドレス記憶部101及びエントリ記憶部112を用いて、置き換える命令として、非優先命令を選択できる。 Further, even when the instruction cache 100 replaces an instruction, the cache control unit 102 can use the address storage unit 101 and the entry storage unit 112 to select a non-priority instruction as the instruction to be replaced.

[効果の説明]
このように構成された第2の実施形態にかかる情報処理装置11は、第1の実施形態にかかる情報処理装置11と同様の効果を実現できる。
[Explanation of effects]
The information processing device 11 according to the second embodiment configured in this way can achieve the same effects as the information processing device 11 according to the first embodiment.

その理由は、次のとおりである。 The reason is as follows.

情報処理装置11は、プロセッサ130と、命令キャッシュ100と、実行モジュール120とを含む。プロセッサ130は、命令を実行する。実行モジュール120は、命令記憶部124(第1の命令記憶部)と、アドレス記憶部101とを含む。命令記憶部124は、プロセッサ130が実行する命令を保存する。アドレス記憶部101は、命令記憶部124において、優先的にキャッシュする命令を保存するアドレスの範囲を保存する。命令キャッシュ100は、命令記憶部111(第2の命令記憶部)と、エントリ記憶部112と、キャッシュ制御部102とを含む。命令記憶部111は、プロセッサ130が実行する命令のキャッシュとして、実行モジュール120が保存する命令の複製を保存する。エントリ記憶部112は、命令記憶部111が保存した命令に関連するアドレスとして、実行モジュール120における命令のアドレスを含むエントリ310を保存する。キャッシュ制御部102は、エントリ310が保存するアドレスと、実行モジュール120が保存するアドレスの範囲とを用いて、複製として保存する命令の中で、新たな命令と置き換える命令を決定する。 Information processing device 11 includes a processor 130, an instruction cache 100, and an execution module 120. Processor 130 executes instructions. The execution module 120 includes an instruction storage section 124 (first instruction storage section) and an address storage section 101. The instruction storage unit 124 stores instructions to be executed by the processor 130. The address storage unit 101 stores a range of addresses in which instructions to be cached preferentially are stored in the instruction storage unit 124 . The instruction cache 100 includes an instruction storage section 111 (second instruction storage section), an entry storage section 112, and a cache control section 102. The instruction storage unit 111 stores copies of instructions stored by the execution module 120 as a cache of instructions executed by the processor 130. The entry storage unit 112 stores an entry 310 that includes the address of the instruction in the execution module 120 as an address related to the instruction stored in the instruction storage unit 111. The cache control unit 102 uses the address stored in the entry 310 and the range of addresses stored in the execution module 120 to determine which instruction to be replaced with a new instruction among the instructions stored as copies.

このように、情報処理装置11に含まれる命令キャッシュ100及び実行モジュール120に含まれ構成は、第1の実施形態における対応する構成と同様の機能を実現する。そのため、第2の実施形態にかかる情報処理装置11は、第1の実施形態にかかる情報処理装置10と同様の効果を実現できる。 In this way, the configurations included in the instruction cache 100 and execution module 120 included in the information processing device 11 realize the same functions as the corresponding configurations in the first embodiment. Therefore, the information processing device 11 according to the second embodiment can achieve the same effects as the information processing device 10 according to the first embodiment.

なお、情報処理装置11は、第1の実施形態における最小構成でもある。 Note that the information processing device 11 is also the minimum configuration in the first embodiment.

[ハードウェア構成]
次に、情報処理装置10及び11のハードウェア構成について、情報処理装置10を用いて説明する。
[Hardware configuration]
Next, the hardware configurations of the information processing devices 10 and 11 will be explained using the information processing device 10.

情報処理装置10の各構成部は、ハードウェア回路で構成されてもよい。 Each component of the information processing device 10 may be configured with a hardware circuit.

あるいは、情報処理装置10において、各構成部は、ネットワークを介して接続した複数の装置を用いて、構成されてもよい。 Alternatively, in the information processing device 10, each component may be configured using a plurality of devices connected via a network.

あるいは、情報処理装置10において、複数の構成部は、1つのハードウェアで構成されてもよい。 Alternatively, in the information processing device 10, the plurality of components may be configured by one piece of hardware.

あるいは、情報処理装置10は、CPU(Central Processing Unit)と、ROM(Read Only Memory)と、RAM(Random Access Memory)とを含むコンピュータ装置として実現されてもよい。情報処理装置10は、上記構成に加え、さらに、入出力接続回路(IOC:Input and Output Circuit)を含むコンピュータ装置として実現されてもよい。情報処理装置10は、上記構成に加え、さらに、ネットワークインターフェース回路(NIC:Network Interface Circuit)を含むコンピュータ装置として実現されてもよい。 Alternatively, the information processing device 10 may be realized as a computer device including a CPU (Central Processing Unit), a ROM (Read Only Memory), and a RAM (Random Access Memory). In addition to the above configuration, the information processing device 10 may be realized as a computer device that further includes an input and output connection circuit (IOC). In addition to the above configuration, the information processing device 10 may be realized as a computer device that further includes a network interface circuit (NIC).

図9は、情報処理装置10のハードウェア構成の一例を示すブロック図である。なお、図9は、情報処理装置10のハードウェアの一例として、情報処理装置600を示す。 FIG. 9 is a block diagram showing an example of the hardware configuration of the information processing device 10. As shown in FIG. Note that FIG. 9 shows an information processing device 600 as an example of hardware of the information processing device 10.

情報処理装置600は、CPU610と、ROM620と、RAM630と、内部記憶装置640と、IOC650と、NIC680とを含み、コンピュータ装置を構成している。 The information processing device 600 includes a CPU 610, a ROM 620, a RAM 630, an internal storage device 640, an IOC 650, and an NIC 680, and constitutes a computer device.

CPU610は、ROM620及び/又は内部記憶装置640からプログラムを読み込む。そして、CPU610は、読み込んだプログラムに基づいて、RAM630と、内部記憶装置640と、IOC650と、NIC680とを制御する。そして、CPU610を含むコンピュータは、これらの構成を制御し、図1に示されている、プロセッサ130、命令キャッシュ100、ローダ103、及び実行モジュール120としての各機能を実現する。 CPU 610 reads programs from ROM 620 and/or internal storage device 640. Then, the CPU 610 controls the RAM 630, internal storage device 640, IOC 650, and NIC 680 based on the read program. The computer including the CPU 610 controls these configurations and realizes the functions of the processor 130, instruction cache 100, loader 103, and execution module 120 shown in FIG.

CPU610は、プロセッサ130の一例である。 CPU 610 is an example of processor 130.

CPU610は、各機能を実現する際に、RAM630又は内部記憶装置640を、プログラムの一時記憶媒体として使用してもよい。 The CPU 610 may use the RAM 630 or the internal storage device 640 as a temporary storage medium for programs when implementing each function.

また、CPU610は、コンピュータで読み取り可能にプログラムを記憶した記憶媒体690が含むプログラムを、図示しない記憶媒体読み取り装置を用いて読み込んでもよい。あるいは、CPU610は、NIC680を介して、図示しない外部の装置からプログラムを受け取り、RAM630又は内部記憶装置640に保存して、保存したプログラムを基に動作してもよい。 Further, the CPU 610 may read a program included in a storage medium 690 that stores the program in a computer-readable manner using a storage medium reading device (not shown). Alternatively, the CPU 610 may receive a program from an external device (not shown) via the NIC 680, store it in the RAM 630 or the internal storage device 640, and operate based on the stored program.

なお、図示していないが、CPU610は、内蔵メモリを含んでもよい。この場合、内蔵メモリが、命令キャッシュ100として動作してもよい。 Although not shown, the CPU 610 may include a built-in memory. In this case, the built-in memory may operate as the instruction cache 100.

ROM620は、CPU610が実行するプログラム及び固定的なデータを記憶する。ROM620は、例えば、P-ROM(Programmable-ROM)又はフラッシュROMである。 The ROM 620 stores programs executed by the CPU 610 and fixed data. The ROM 620 is, for example, a P-ROM (Programmable-ROM) or a flash ROM.

RAM630は、CPU610が実行するプログラム及びデータを一時的に記憶する。RAM630は、例えば、D-RAM(Dynamic-RAM)である。 The RAM 630 temporarily stores programs and data executed by the CPU 610. The RAM 630 is, for example, D-RAM (Dynamic-RAM).

なお、RAM630が、実行モジュール120を保存してもよい。 Note that the RAM 630 may store the execution module 120.

さらに、RAM630は、アクセス性能が異なる複数のメモリを含んでもよい。この場合、アクセス性能が高いメモリが、命令キャッシュ100として動作してもよい。 Furthermore, RAM 630 may include multiple memories with different access performance. In this case, a memory with high access performance may operate as the instruction cache 100.

内部記憶装置640は、情報処理装置600が長期的に保存するデータ及びプログラムを記憶する。また、内部記憶装置640は、CPU610の一時記憶装置として動作してもよい。内部記憶装置640は、例えば、ハードディスク装置、光磁気ディスク装置、SSD(Solid State Drive)又はディスクアレイ装置である。 The internal storage device 640 stores data and programs that the information processing device 600 stores for a long time. Further, the internal storage device 640 may operate as a temporary storage device for the CPU 610. The internal storage device 640 is, for example, a hard disk device, a magneto-optical disk device, an SSD (Solid State Drive), or a disk array device.

なお、内部記憶装置640は、実行モジュール120を保存してもよい。 Note that the internal storage device 640 may store the execution module 120.

ROM620と内部記憶装置640とは、不揮発性(non-transitory)の記憶媒体である。一方、RAM630は、揮発性(transitory)の記憶媒体である。そして、CPU610は、ROM620、内部記憶装置640、又は、RAM630に記憶されているプログラムを基に動作可能である。つまり、CPU610は、不揮発性記憶媒体又は揮発性記憶媒体を用いて動作可能である。 The ROM 620 and the internal storage device 640 are non-transitory storage media. On the other hand, the RAM 630 is a volatile storage medium. The CPU 610 can operate based on programs stored in the ROM 620, internal storage device 640, or RAM 630. That is, the CPU 610 can operate using a nonvolatile storage medium or a volatile storage medium.

IOC650は、CPU610と、外部の装置とのデータを仲介する。図9は、外部の装置の一例として、入力機器660及び表示機器670を示す。IOC650は、例えば、IOインターフェースカード又はUSB(Universal Serial Bus)カードである。さらに、IOC650は、USBのような有線に限らず、無線を用いてもよい。 The IOC 650 mediates data between the CPU 610 and external devices. FIG. 9 shows an input device 660 and a display device 670 as an example of an external device. The IOC 650 is, for example, an IO interface card or a USB (Universal Serial Bus) card. Furthermore, the IOC 650 is not limited to a wired one such as a USB, but may also be a wireless one.

入力機器660は、情報処理装置600の操作者からの入力指示を受け取る機器である。入力機器660は、例えば、キーボード、マウス又はタッチパネルである。 The input device 660 is a device that receives input instructions from the operator of the information processing device 600. Input device 660 is, for example, a keyboard, a mouse, or a touch panel.

表示機器670は、情報処理装置600の操作者に情報を表示する機器である。表示機器670は、例えば、液晶ディスプレイ、有機エレクトロルミネッセンス・ディスプレイ、又は、電子ペーパーである。 The display device 670 is a device that displays information to the operator of the information processing device 600. Display device 670 is, for example, a liquid crystal display, an organic electroluminescent display, or electronic paper.

NIC680は、ネットワークを介した図示しない外部の装置とのデータのやり取りを中継する。NIC680は、例えば、LAN(Local Area Network)カードである。さらに、NIC680は、有線に限らず、無線を用いてもよい。 The NIC 680 relays data exchange with an external device (not shown) via the network. The NIC 680 is, for example, a LAN (Local Area Network) card. Furthermore, the NIC 680 is not limited to a wired one, and may be a wireless one.

このように構成された情報処理装置600は、情報処理装置10と同様の効果を得ることができる。 The information processing device 600 configured in this manner can obtain the same effects as the information processing device 10.

その理由は、情報処理装置600のCPU610が、プログラムに基づいて情報処理装置10と同様の機能を実現できるためである。 The reason is that the CPU 610 of the information processing device 600 can implement the same functions as the information processing device 10 based on the program.

以上、実施形態を参照して本願発明を説明したが、本願発明は上記実施形態に限定されるものではない。本願発明の構成及び詳細には、本願発明のスコープ内で当業者が理解し得る様々な変更をすることができる。 Although the present invention has been described above with reference to the embodiments, the present invention is not limited to the above embodiments. The configuration and details of the present invention can be modified in various ways that can be understood by those skilled in the art within the scope of the present invention.

10 情報処理装置
11 情報処理装置
100 命令キャッシュ
101 アドレス記憶部
102 キャッシュ制御部
103 ローダ
104 命令指定部
105 命令配置決定部
106 命令埋め込み部
111 命令記憶部
112 エントリ記憶部
120 実行モジュール
121 非優先命令記憶部
122 優先命令記憶部
124 命令記憶部
130 プロセッサ
200 キャッシュ制御部
201 アドレスアレイ
202 データアレイ
300 アドレス
301 Validビット
302 Priorityビット
310 エントリ
400 アドレス
401 Validビット
402 Priorityビット
403 アドレス
404 Validビット
405 Priorityビット
406 アドレス
407 Validビット
408 Priorityビット
409 アドレス
410 Validビット
411 Priorityビット
412 非優先エントリ
413 優先エントリ
414 エントリ
500 下限アドレス
501 上限アドレス
503 比較器
600 情報処理装置
610 CPU
620 ROM
630 RAM
640 内部記憶装置
650 IOC
660 入力機器
670 表示機器
680 NIC
690 記憶媒体
700 下限アドレス
701 上限アドレス
702 非優先命令領域
703 優先命令領域
10 Information processing device 11 Information processing device 100 Instruction cache 101 Address storage unit 102 Cache control unit 103 Loader 104 Instruction specification unit 105 Instruction placement determination unit 106 Instruction embedding unit 111 Instruction storage unit 112 Entry storage unit 120 Execution module 121 Non-priority instruction storage Section 122 Priority instruction storage section 124 Instruction storage section 130 Processor 200 Cache control section 201 Address array 202 Data array 300 Address 301 Valid bit 302 Priority bit 310 Entry 400 Address 401 Valid bit 402 Priority bit 403 Address 404 V alid bit 405 Priority bit 406 Address 407 Valid bit 408 Priority bit 409 Address 410 Valid bit 411 Priority bit 412 Non-priority entry 413 Priority entry 414 Entry 500 Lower limit address 501 Upper limit address 503 Comparator 600 Information processing device 610 CPU
620 ROM
630 RAM
640 Internal storage device 650 IOC
660 Input device 670 Display device 680 NIC
690 Storage medium 700 Lower limit address 701 Upper limit address 702 Non-priority instruction area 703 Priority instruction area

Claims (8)

命令を実行するプロセッサと、
ローダによりメモリに生成され、
生成されるときに、
前記プロセッサが実行する命令を保存する第1の命令記憶手段と、
前記第1の命令記憶手段において、優先的にキャッシュする命令を保存するアドレスの範囲を保存するアドレス記憶手段と
含むように生成される実行モジュールと、
前記プロセッサが実行する命令のキャッシュとして、前記実行モジュールが保存する命令の複製を保存する第2の命令記憶手段と、
前記第2の命令記憶手段が保存した命令に関連するアドレスとして、前記実行モジュールにおける命令のアドレスを含むエントリを保存するエントリ記憶手段と、
エントリが保存するアドレスと、前記実行モジュールが保存するアドレスの範囲とを用いて、複製として保存する命令の中で、新たな命令と置き換える命令を決定するキャッシュ制御手段と
を含む命令キャッシュと
を含む情報処理装置。
a processor that executes instructions;
generated in memory by the loader,
When generated,
a first instruction storage means for storing instructions to be executed by the processor;
an execution module generated to include, in the first instruction storage means, an address storage means for storing a range of addresses for storing instructions to be preferentially cached;
a second instruction storage means for storing copies of instructions stored by the execution module as a cache of instructions executed by the processor;
Entry storage means for storing an entry including an address of the instruction in the execution module as an address related to the instruction stored by the second instruction storage means;
an instruction cache comprising: a cache control means for determining an instruction to be replaced with a new instruction among instructions to be saved as a copy using an address to be saved by an entry and a range of addresses to be saved by the execution module; Information processing device.
前記キャッシュ制御手段が、
前記エントリ記憶手段が保存するエントリにおいて、命令に関連しないエントリがある場合、命令に関連しないエントリを新たな命令のエントリとして決定し、
命令に関連しないエントリがない場合、前記アドレス記憶手段が保存するアドレスの範囲に含まれないアドレスを含むエントリに関連する命令を、新たな命令と置き換える命令と決定する
請求項1に記載の情報処理装置。
The cache control means,
If there is an entry unrelated to the instruction among the entries stored by the entry storage means, the entry unrelated to the instruction is determined as an entry of a new instruction;
Information processing according to claim 1, wherein if there is no entry unrelated to the instruction, an instruction related to an entry including an address that is not included in the range of addresses stored by the address storage means is determined to be an instruction to be replaced with a new instruction. Device.
エントリが、
エントリが有効であるか否かを示す情報を含み、
前記キャッシュ制御手段が、エントリが有効であるか否かの情報を用いてエントリが命令に関連するか否かを判定する
請求項2に記載の情報処理装置。
The entry is
Contains information indicating whether the entry is valid or not,
The information processing apparatus according to claim 2, wherein the cache control means determines whether an entry is related to an instruction using information as to whether the entry is valid or not.
前記キャッシュ制御手段が
前記第2の命令記憶手段に命令を複製するときに、前記実行モジュールにおける命令のアドレスと、前記アドレス記憶手段が保存するアドレスの範囲とを用いて、複製する命令が優先的にキャッシュする命令であるか否かを判定し、
エントリに判定の結果を保存し、
エントリに保存された判定の結果を用いて、置き換える命令を決定する
請求項1ないし3のいずれか1項に記載の情報処理装置。
When the cache control means copies an instruction to the second instruction storage means, the instruction to be copied is given priority by using the address of the instruction in the execution module and the range of addresses stored in the address storage means. Determine whether the instruction is to be cached in
Save the judgment result in the entry,
The information processing apparatus according to any one of claims 1 to 3, wherein a replacement instruction is determined using a determination result stored in an entry.
前記アドレス記憶手段が、
アドレスの範囲として、アドレスの範囲の下限アドレス及び上限アドレスを保存する
請求項1ないし4のいずれか1項に記載の情報処理装置。
The address storage means,
The information processing apparatus according to any one of claims 1 to 4, wherein a lower limit address and an upper limit address of the address range are stored as the address range.
前記ローダをさらに含み、
前記ローダは、
前記実行モジュールを生成するときに、
前記実行モジュールに含まれる命令の中で、優先的に前記命令キャッシュに保存する命令を指定する命令指定手段と、
前記実行モジュールにおいて、指定された命令を配置する前記実行モジュールの前記第1の命令記憶手段におけるアドレスを決定し、決定したアドレスを前記アドレス記憶手段に記憶する命令配置決定手段と、
決定した前記第1の命令記憶手段のアドレスに指定された命令を埋め込む命令埋め込み手段と
を含む
請求項1ないし5のいずれか1項に記載の情報処理装置。
further comprising the loader;
The loader is
When generating the execution module,
an instruction specifying means for specifying an instruction to be preferentially stored in the instruction cache among instructions included in the execution module;
In the execution module, an instruction placement determining unit that determines an address in the first instruction storage unit of the execution module where a designated instruction is to be placed, and stores the determined address in the address storage unit ;
an instruction embedding means for embedding a specified instruction in the determined address of the first instruction storage means;
including
The information processing device according to any one of claims 1 to 5 .
命令を実行するプロセッサと、
ローダによりメモリに生成され、生成されるときに、前記プロセッサが実行する命令と、優先的にキャッシュする命令を保存するアドレスの範囲を保存するように生成される実行モジュールと、
命令キャッシュとを含む情報処理装置において、
前記命令キャッシュが
前記プロセッサが実行する命令のキャッシュとして、前記実行モジュールが保存する命令の複製を保存し、
保存した命令に関連するアドレスとして、前記実行モジュールにおける命令のアドレスを含むエントリを保存し、
エントリが保存するアドレスと、前記実行モジュールが保存するアドレスの範囲とを用いて、複製として保存する命令の中で、新たな命令と置き換える命令を決定する
情報処理方法。
a processor that executes instructions;
an execution module that is generated in a memory by a loader and that, when generated, stores instructions to be executed by the processor and a range of addresses that store instructions to be cached preferentially;
In an information processing device including an instruction cache,
the instruction cache stores copies of instructions stored by the execution module as a cache for instructions executed by the processor;
saving an entry containing an address of the instruction in the execution module as an address associated with the saved instruction;
An information processing method in which an instruction to be replaced with a new instruction among instructions to be saved as a copy is determined using an address saved by an entry and a range of addresses saved by the execution module.
命令を実行するプロセッサを含む情報処理装置に、
ローダによりメモリに生成され、
生成されるときに、
前記プロセッサが実行する命令を保存し、
優先的にキャッシュする命令を保存するアドレスの範囲を保存するように
実行モジュールを生成する処理と、
前記プロセッサが実行する命令のキャッシュとして、前記実行モジュールが保存する命令の複製を保存し、
保存した命令に関連するアドレスとして、前記実行モジュールにおける命令のアドレスを含むエントリを保存し、
エントリが保存するアドレスと、前記実行モジュールが保存するアドレスの範囲とを用いて、複製として保存する命令の中で、新たな命令と置き換える命令を決定する
命令キャッシュとしての処理と
を実行させるプログラム。
In an information processing device including a processor that executes instructions,
generated in memory by the loader,
When generated,
storing instructions to be executed by the processor;
Now saves a range of addresses for saving instructions to be cached preferentially
Processing to generate an executable module,
storing a copy of the instructions stored by the execution module as a cache of instructions executed by the processor;
saving an entry containing an address of the instruction in the execution module as an address associated with the saved instruction;
A program that executes processing as an instruction cache: determining an instruction to be replaced with a new instruction among instructions to be saved as a copy, using an address saved by an entry and a range of addresses saved by the execution module.
JP2019169294A 2019-09-18 2019-09-18 Information processing device, information processing method, and program Active JP7363255B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2019169294A JP7363255B2 (en) 2019-09-18 2019-09-18 Information processing device, information processing method, and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2019169294A JP7363255B2 (en) 2019-09-18 2019-09-18 Information processing device, information processing method, and program

Publications (2)

Publication Number Publication Date
JP2021047591A JP2021047591A (en) 2021-03-25
JP7363255B2 true JP7363255B2 (en) 2023-10-18

Family

ID=74878481

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2019169294A Active JP7363255B2 (en) 2019-09-18 2019-09-18 Information processing device, information processing method, and program

Country Status (1)

Country Link
JP (1) JP7363255B2 (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002163151A (en) 2000-10-17 2002-06-07 Arm Ltd Data processor, lockdown controller in the same, and method for locking data value

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002163151A (en) 2000-10-17 2002-06-07 Arm Ltd Data processor, lockdown controller in the same, and method for locking data value

Also Published As

Publication number Publication date
JP2021047591A (en) 2021-03-25

Similar Documents

Publication Publication Date Title
US8812817B2 (en) Non-blocking data transfer via memory cache manipulation
US5829025A (en) Computer system and method of allocating cache memories in a multilevel cache hierarchy utilizing a locality hint within an instruction
JP5528554B2 (en) Block-based non-transparent cache
US20060143396A1 (en) Method for programmer-controlled cache line eviction policy
KR101639943B1 (en) Shared memory control method for facilitating shared memory of general purpose graphic processor as cache and general purpose graphic processor using same
US9195605B2 (en) Data bus efficiency via cache line usurpation
JP5536655B2 (en) Cache memory, memory system, and data copy method
JP5422652B2 (en) Avoiding self-eviction due to dynamic memory allocation in flash memory storage
JP2005276199A (en) Method to provide cache management command for dma controller
JP2006092169A (en) Memory controller, memory device and control method for memory controller
JP2014203405A (en) Information processing device, memory control device, data transfer control method, and data transfer control program
US9483400B2 (en) Multiplexed memory for segments and pages
KR100505695B1 (en) Cache memory device having dynamically-allocated or deallocated buffers, digital data processing system comprising it and method thereof
KR101168364B1 (en) Coherent caching of local memory data
JP7363255B2 (en) Information processing device, information processing method, and program
CN110347614B (en) Storage space mapping algorithm, cache state machine, storage device, and storage medium
JP2011186558A (en) Memory management device and method
JP2007304747A (en) Computer system and memory access method
JP2009093559A (en) Processor, information processing device and cache control method of processor
JPH07129464A (en) Information processor
JP4792065B2 (en) Data storage method
JP2011141754A (en) Cache memory
JP4008946B2 (en) Cache memory and control method thereof
JP2013109404A (en) Information processing device
JPH11143774A (en) Cache control mechanism

Legal Events

Date Code Title Description
RD01 Notification of change of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7421

Effective date: 20211015

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20220815

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20230620

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20230711

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20230824

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20230905

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20230918

R151 Written notification of patent or utility model registration

Ref document number: 7363255

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151