JPH09259039A - Method and device for controlling initialization for electronic computer system - Google Patents
Method and device for controlling initialization for electronic computer systemInfo
- Publication number
- JPH09259039A JPH09259039A JP8066044A JP6604496A JPH09259039A JP H09259039 A JPH09259039 A JP H09259039A JP 8066044 A JP8066044 A JP 8066044A JP 6604496 A JP6604496 A JP 6604496A JP H09259039 A JPH09259039 A JP H09259039A
- Authority
- JP
- Japan
- Prior art keywords
- data
- cache memory
- line
- writing
- address
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Withdrawn
Links
Abstract
Description
【0001】[0001]
【発明の属する技術分野】本発明は電子計算機システム
の初期化制御装置、特にキャッシュメモリの初期化制御
に関するものである。BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an initialization control device for an electronic computer system, and more particularly to a cache memory initialization control.
【0002】[0002]
【従来の技術】従来キャッシュメモリを備えた電子計算
機システム内において、主記憶手段であるメインメモリ
からキャッシュメモリへのデータの転送方式としてコピ
ーバック方式がある。コピーバック方式とは、キャッシ
ュメモリの1ライン単位でメインメモリからデータを読
み出し(ラインフィル)、キャッシュメモリにそのデー
タを書き込む方式である。また、キャッシュメモリ内に
格納されているデータが有効であるか、それとも無効で
あるかという情報を得るために、ライン毎に有効(va
lid)ビットを設定し、有効ビットがセットされてい
るラインのデータは有効であるとみなされる。2. Description of the Related Art In a conventional computer system having a cache memory, there is a copy-back method as a method of transferring data from a main memory which is a main storage means to a cache memory. The copy-back method is a method of reading data (line fill) from the main memory in units of one line of the cache memory and writing the data in the cache memory. Further, in order to obtain information as to whether the data stored in the cache memory is valid or invalid, it is valid (va
The data of the line in which the lid) bit is set and the valid bit is set is considered to be valid.
【0003】初期化を行う際に、処理手段であるプロセ
ッサとメインメモリが同時にリセット(POW ON
リセット)されると、キャッシュメモリは全ラインの有
効ビットを1度無効にする。そこにラインフィルが行わ
れ、メインメモリのデータが書き込まれても、そのデー
タは無効なものであるため、ライトミスとなる。そこで
再度ラインフィルが行われ、有効ビットをセットした
後、データがキャッシュメモリに書き込まれる。そのデ
ータが書き込まれたラインには有効ビットがセットされ
ているのでデータは有効なものとして扱われる。At the time of initialization, the processor as the processing means and the main memory are simultaneously reset (POW ON
When reset), the cache memory invalidates the valid bits of all lines once. Even if the line fill is performed there and the data in the main memory is written, the data is invalid and a write miss occurs. Then, line filling is performed again, the valid bit is set, and then the data is written to the cache memory. Since the valid bit is set in the line in which the data is written, the data is treated as valid.
【0004】[0004]
【発明が解決しようとする課題】上記のような従来のキ
ャッシュメモリの制御では、POW ON リセット後
に、メインメモリから読み出され、キャッシュメモリに
書き込まれるデータは、有効ビットがセットされていな
いため無効なものとなる。そこで有効ビットがセットさ
れた後に書き込まなくてはならない。しかもキャッシュ
メモリに書き込まれたデータは、メインメモリに設定さ
れたデータが書き込まれて安定する前の不定なデータで
ある。以上より処理手段に不要な仕事をさせることにな
り、効率が悪い。In the conventional control of the cache memory as described above, the data read from the main memory and written to the cache memory after the POW ON reset is invalid because the valid bit is not set. It will be It must be written there after the valid bit is set. Moreover, the data written in the cache memory is indefinite data before the data set in the main memory is written and stabilized. As a result, the processing means is caused to perform unnecessary work, resulting in poor efficiency.
【0005】そこで、処理手段に負担をかけずにキャッ
シュメモリの初期化を効率よくできる電子計算機システ
ムの初期化制御方法及び装置が望まれていた。Therefore, there has been a demand for an initialization control method and apparatus for an electronic computer system which can efficiently initialize the cache memory without imposing a burden on the processing means.
【0006】[0006]
【課題を解決するための手段】本発明に係る電子計算機
システムの初期化制御方法は、キャッシュメモリの各ラ
インにアドレスタグの値を設定する工程と、キャッシュ
メモリが格納するデータの有効性を示す有効ビットをあ
らかじめ各ラインにセットする工程と、あらかじめ設定
されたデータを主記憶手段に書き込む工程と、アドレス
タグの値を読み出し、主記憶手段の対応するアドレスの
設定されたデータを読み出して、読み出されたデータを
前記キャッシュメモリの該当するラインに書き込む工程
とを有している。キャッシュメモリの初期化を行う際、
キャッシュメモリの各ラインにアドレスタグの値を設定
しておく。また有効ビットをあらかじめ全ラインにセッ
トしておく。主記憶手段にあらかじめ設定されたデータ
が書き込まれた後、アドレスタグの値を読み出す。その
アドレスタグに対応する主記憶手段のアドレスから設定
されたデータを読みだし、アドレスタグと対になってい
るラインに設定されたデータを書き込む。有効ビットが
あらかじめ各ラインにセットされているので、キャッシ
ュメモリに書き込まれたデータは有効なデータとして扱
われる。An initialization control method for an electronic computer system according to the present invention shows a step of setting an address tag value in each line of a cache memory and the validity of data stored in the cache memory. The step of setting the effective bit in each line in advance, the step of writing the preset data in the main storage means, the value of the address tag is read, and the data in which the corresponding address in the main storage means is set is read and read. Writing the issued data to the corresponding line of the cache memory. When initializing the cache memory,
The value of the address tag is set in each line of the cache memory. In addition, the effective bit is set in advance for all lines. After the preset data is written in the main storage means, the value of the address tag is read. The set data is read from the address of the main storage means corresponding to the address tag, and the set data is written in the line paired with the address tag. Since the valid bit is set in each line in advance, the data written in the cache memory is treated as valid data.
【0007】また本発明に係る電子計算機システムの初
期化制御装置は、初期化の際に、あらかじめ設定された
データが書き込まれる主記憶手段と、各ラインにアドレ
スタグの値を設定し、またデータの有効性を示す有効ビ
ットをあらかじめ各ラインにセットするキャッシュメモ
リと、主記憶手段に設定されたデータを書き込んだ後、
アドレスタグの値を読み出し、アドレスタグの値に対応
する主記憶手段のアドレスの前記設定されたデータを読
み出して、キャッシュメモリのラインに設定されたデー
タを書き込む処理手段とを備えている。キャッシュメモ
リを初期化する際、主記憶手段にあらかじめ設定された
データを書き込んでおき、キャッシュメモリのアドレス
タグの値に対応する主記憶手段のアドレスの設定された
データを処理手段が読み出して、アドレスタグの値と対
になっているキャッシュメモリのラインにその設定され
たデータを書き込む。有効ビットがあらかじめ各ライン
にセットされているので、キャッシュメモリに書き込ま
れたデータは有効なデータとして扱われる。Further, the initialization control device for the electronic computer system according to the present invention sets the value of the address tag to each main line and the main storage means in which preset data is written at the time of initialization, and After writing the data set in the main memory means and the cache memory that sets the valid bit indicating the validity of each line in advance,
And a processing unit for reading the value of the address tag, reading the set data at the address of the main storage unit corresponding to the value of the address tag, and writing the data set in the line of the cache memory. When initializing the cache memory, the preset data is written in the main storage means, and the processing means reads out the data in which the address of the main storage means corresponding to the value of the address tag of the cache memory is set, The set data is written in the line of the cache memory which is paired with the tag value. Since the valid bit is set in each line in advance, the data written in the cache memory is treated as valid data.
【0008】[0008]
【発明の実施の形態】図1は本発明の実施の形態に係る
電子計算機システムの初期化制御装置のブロック図であ
る。図において1はメインメモリ、2はキャッシュメモ
リ、3はCPUである。キャッシュメモリ2には有効ビ
ットをクリアする回路を排除し、常に有効ビットがセッ
トされるようにしておく。CPU3は、ライト命令(4
ワード・ライト命令を除く)を出し、メインメモリから
データを読み出し、キャッシュメモリにそのデータを書
き込むように指示するところである。本実施の形態で
は、1ワード・ライト命令を行うものとする。1 is a block diagram of an initialization control device for an electronic computer system according to an embodiment of the present invention. In the figure, 1 is a main memory, 2 is a cache memory, and 3 is a CPU. A circuit for clearing the valid bit is excluded from the cache memory 2 so that the valid bit is always set. The CPU 3 writes the write command (4
(Except the word write command), read the data from the main memory, and instruct the cache memory to write the data. In this embodiment, a 1-word write instruction is performed.
【0009】図2はキャッシュメモリ2の1ラインの構
成図である。TAGは21ビットのアドレスタグ、Vは
有効ビット、Dはダーティビット、LWn(n=1〜
4)は32ビットのロングワードデータを表す。FIG. 2 is a block diagram of one line of the cache memory 2. TAG is a 21-bit address tag, V is a valid bit, D is a dirty bit, LWn (n = 1 to 1)
4) represents 32-bit longword data.
【0010】図3は電子計算機システムの初期化制御装
置の動作フローチャートである。なお、本実施の形態に
おいては、読み込まれるアドレスタグTAGに対応する
メインメモリ1のアドレスは1000番地であるとす
る。POW ON リセットされると(S31)、キャ
ッシュメモリ2上のアドレスタグTAGに初期値が設定
され(S32)、全ラインに有効ビットがセットされる
(S33)。不定となっていたメインメモリ1内にあら
かじめ設定されたデータが書き込まれ、データが安定す
ると(S34)、CPU3が1ワード・ライト命令の処
理を開始する(S35)。書き込みを行うラインのアド
レスタグTAGを読みだし(S36)、そのアドレスタ
グTAGに対応するメインメモリ1のアドレス(100
0番地)から1ライン分のデータ(1000番地〜10
0F番地)を読み出す(S37)。そのデータをワード
単位でキャッシュメモリ2の32ビットロングワードデ
ータLW1〜4のいずれかに書き込む(S38)。キャ
ッシュメモリ2には全てのラインに有効ビットVがセッ
トされているので、キャッシュメモリ2内の全てのデー
タは有効なものとして扱われる。したがってライトミス
とはならず、書き込まれたデータも有効なものとして扱
われる。データが書き込まれたら、そのラインにダーテ
ィビットDをセットする(S39)。他に1ワード・ラ
イト命令を行わなければ(S40)、終了する。FIG. 3 is an operation flowchart of the initialization control device of the electronic computer system. In this embodiment, the address of the main memory 1 corresponding to the read address tag TAG is 1000. When POW ON is reset (S31), an initial value is set in the address tag TAG on the cache memory 2 (S32), and valid bits are set in all lines (S33). When preset data is written in the indeterminate main memory 1 and the data becomes stable (S34), the CPU 3 starts the processing of the 1-word write instruction (S35). The address tag TAG of the line to be written is read (S36), and the address of the main memory 1 corresponding to the address tag TAG (100
Data for 1 line from address 0 (addresses 1000 to 10)
Address 0F) is read (S37). The data is written word by word into any of the 32-bit long word data LW1 to LW4 of the cache memory 2 (S38). Since the valid bit V is set in all the lines in the cache memory 2, all the data in the cache memory 2 are treated as valid. Therefore, a write miss does not occur and the written data is treated as valid data. When the data is written, the dirty bit D is set to that line (S39). If another 1-word write command is not issued (S40), the process ends.
【0011】キャッシュメモリ2への書き込みが終了
し、CPU3がキャッシュメモリ2からデータを読み出
す際に、メインメモリ1から読み出し、キャッシュメモ
リ2に書き込んだデータのみを読み出すように設定して
おく。したがって、たとえ全てのラインに有効ビットが
セットされていたとしても、他のラインから不定なデー
タを読み出すことはない。When the CPU 3 reads the data from the cache memory 2 after the writing to the cache memory 2 is completed, the CPU 3 is set to read only the data read from the main memory 1 and written in the cache memory 2. Therefore, even if the valid bit is set in all lines, undefined data is not read from other lines.
【0012】上記のような電子計算機システムの初期化
制御装置では、キャッシュメモリ2の全ラインの有効ビ
ットVをあらかじめセットしておくことにより、初期化
の際、ライト命令が出された時にライトミスを起こすこ
とがなく、再度ラインフィルを行わなくてもよいので、
処理手段に負荷をかけなくてすむ。またそれによってシ
ステム全体としての時間短縮を計れる。In the initialization control device for an electronic computer system as described above, the valid bits V of all the lines of the cache memory 2 are set in advance, so that a write miss occurs when a write command is issued during initialization. Since there is no need to refill the line,
No load on the processing means. In addition, the time required for the system as a whole can be reduced.
【0013】[0013]
【発明の効果】以上のように本発明によれば、キャッシ
ュメモリの全ラインに有効ビットをセットしておき、あ
らかじめ設定されたデータがキャッシュメモリに書き込
まれるのでライトミスは起きず、キャッシュメモリに書
き込まれたデータは有効なものとして扱われる。したが
ってキャッシュメモリへのデータの書き込みは1度でよ
く、処理手段に負荷をかけなくてすむ。As described above, according to the present invention, since the valid bit is set in all the lines of the cache memory and the preset data is written in the cache memory, a write miss does not occur in the cache memory. The written data is treated as valid. Therefore, the writing of data to the cache memory only needs to be done once, and the load on the processing means is not required.
【図1】本発明の実施の形態に係る電子計算機システム
の初期化制御装置のブロック図である。FIG. 1 is a block diagram of an initialization control device of an electronic computer system according to an embodiment of the present invention.
【図2】キャッシュメモリ2の1ラインの構成図であ
る。FIG. 2 is a configuration diagram of one line of a cache memory 2.
【図3】電子計算機システムの初期化制御装置の動作フ
ローチャートである。FIG. 3 is an operation flowchart of an initialization control device of an electronic computer system.
1 メインメモリ 2 キャッシュメモリ 3 CPU TAG アドレスタグ V 有効ビット D ダーティビット LW1〜LW4 32ビットロングワードデータ 1 main memory 2 cache memory 3 CPU TAG address tag V valid bit D dirty bit LW1 to LW4 32 bit long word data
Claims (2)
タグの値を設定する工程と、 前記キャッシュメモリが格納するデータの有効性を示す
有効ビットをあらかじめ各ラインにセットする工程と、 あらかじめ設定されたデータを主記憶手段に書き込む工
程と、 前記アドレスタグの値を読み出し、前記主記憶手段の対
応するアドレスの前記設定されたデータを読み出して、
前記読み出されたデータを前記キャッシュメモリの該当
するラインに書き込む工程とを有することを特徴とする
電子計算機システムの初期化制御方法。1. A step of setting an address tag value in each line of the cache memory, a step of setting a valid bit indicating the validity of data stored in the cache memory in each line in advance, and data set in advance Writing in the main memory means, reading the value of the address tag, reading the set data at the corresponding address of the main memory means,
Writing the read data to a corresponding line of the cache memory, the initialization control method of the electronic computer system.
ータが書き込まれる主記憶手段と、 各ラインにアドレスタグの値を設定し、またデータの有
効性を示す有効ビットをあらかじめ各ラインにセットす
るキャッシュメモリと、 前記主記憶手段に前記設定されたデータを書き込んだ
後、前記アドレスタグの値を読み出し、前記アドレスタ
グの値に対応する前記主記憶手段のアドレスの前記設定
されたデータを読み出して、前記キャッシュメモリのラ
インに前記設定されたデータを書き込む処理手段とを備
えたことを特徴とする電子計算機システムの初期化制御
装置。2. At the time of initialization, a main storage unit in which preset data is written and an address tag value is set in each line, and a valid bit indicating the validity of data is set in each line in advance. After writing the set data in the cache memory and the main storage unit, the value of the address tag is read, and the set data of the address of the main storage unit corresponding to the value of the address tag is read. And a processing means for writing the set data in a line of the cache memory.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP8066044A JPH09259039A (en) | 1996-03-22 | 1996-03-22 | Method and device for controlling initialization for electronic computer system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP8066044A JPH09259039A (en) | 1996-03-22 | 1996-03-22 | Method and device for controlling initialization for electronic computer system |
Publications (1)
Publication Number | Publication Date |
---|---|
JPH09259039A true JPH09259039A (en) | 1997-10-03 |
Family
ID=13304493
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP8066044A Withdrawn JPH09259039A (en) | 1996-03-22 | 1996-03-22 | Method and device for controlling initialization for electronic computer system |
Country Status (1)
Country | Link |
---|---|
JP (1) | JPH09259039A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2009169706A (en) * | 2008-01-17 | 2009-07-30 | Nec Corp | Memory control device |
-
1996
- 1996-03-22 JP JP8066044A patent/JPH09259039A/en not_active Withdrawn
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2009169706A (en) * | 2008-01-17 | 2009-07-30 | Nec Corp | Memory control device |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP3289661B2 (en) | Cache memory system | |
JP3519954B2 (en) | Chip enable signal generation circuit and memory device | |
JP2695017B2 (en) | Data transfer method | |
US7356647B1 (en) | Cache with integrated capability to write out entire cache | |
JPH09259039A (en) | Method and device for controlling initialization for electronic computer system | |
CA1299767C (en) | Cache memory control system | |
JP2004318877A (en) | Intelligent waiting method | |
JPH06348504A (en) | Microprocessor system | |
JPH0210446A (en) | Buffer storage device | |
JP3190847B2 (en) | Data transfer control device | |
JP2002366433A (en) | Cache memory controller and processor | |
JPS6132144A (en) | Exclusive data processing system by microprogram control | |
JPH04195563A (en) | Controller for memory system | |
JP2006146817A (en) | Memory control system and memory controller | |
JP2791319B2 (en) | Data processing device | |
JPH11328089A (en) | Id information write circuit in device for pci bus interface | |
JP2000020397A (en) | Cache memory control device | |
JPH07152650A (en) | Cache control unit | |
JP2964504B2 (en) | Document processing device | |
JP2002182939A (en) | Memory writing method and memory writer | |
JPH0863396A (en) | Disk cache device | |
JPH036642A (en) | Cache memory control method | |
JP3097083B2 (en) | Data processing device | |
JPH06274416A (en) | Cache memory device | |
JPS6341931A (en) | Microprogram controller |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A300 | Withdrawal of application because of no request for examination |
Free format text: JAPANESE INTERMEDIATE CODE: A300 Effective date: 20030603 |