JPH03158944A - Cache control system - Google Patents

Cache control system

Info

Publication number
JPH03158944A
JPH03158944A JP1300272A JP30027289A JPH03158944A JP H03158944 A JPH03158944 A JP H03158944A JP 1300272 A JP1300272 A JP 1300272A JP 30027289 A JP30027289 A JP 30027289A JP H03158944 A JPH03158944 A JP H03158944A
Authority
JP
Japan
Prior art keywords
access
data
cache
cache memory
capacity
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP1300272A
Other languages
Japanese (ja)
Inventor
Naoyuki Nishimura
尚幸 西村
Shigeru Hashimoto
繁 橋本
Yasuyuki Higashiura
康之 東浦
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.)
Fujitsu Ltd
Original Assignee
Fujitsu Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Fujitsu Ltd filed Critical Fujitsu Ltd
Priority to JP1300272A priority Critical patent/JPH03158944A/en
Publication of JPH03158944A publication Critical patent/JPH03158944A/en
Pending legal-status Critical Current

Links

Landscapes

  • Memory System Of A Hierarchy Structure (AREA)

Abstract

PURPOSE:To improve the processing speed by constituting the system so that a control part recognizes an access area corresponding to a storage device designated by an access command, and executes an access to data held in a cache memory. CONSTITUTION:At the time of executing an access to data in a cache memory 2b, a processor 1 issues a command provided with information (information of a capacity ratio) related to how many folds of the capacity of one access block of the cache memory 2b the capacity of an access block of a storage device which becomes a store origin of its data is, to a control part 2a. The control part 2a analyzes the information of the command contents, etc., written in this command. On the other hand, a number recognizing means 2c informs a value of the capacity ratio as the number of times of an access executed to the cache memory by an access means 2d. Subsequently, the access means 2d brings the data of the cache memory 2b to access by the number of blocks corresponding to the capacity of one access block of the storage device being a store origin. In such a way, the processing speed can be improved.

Description

【発明の詳細な説明】 〔概要〕 本発明は、主記憶と記憶装置(磁気ディスク。[Detailed description of the invention] 〔overview〕 The present invention focuses on main memory and storage device (magnetic disk).

磁気ドラム、磁気テープ、光ディスク等)間のアクセス
ギャップを埋めるディスクキャッシュを行うシステムの
制御方式に関し、 キャッシュメモリの管理するアクセスブロックの容量と
異なるアクセスブロックの容量を持つ記憶装置に対して
も共通したキャッシュ制御を働かせることができるよう
にすることにより、高速なデータ転送、強いては処理速
度の向上が可能となるディスクキャッシュ制御方式を提
供することを目的とし、 一回にアクセス可能な最小単位のデータ量が各々異なる
複数の記憶装置と、該記憶装置の各々の最小単位のデー
タ量の公約数に相当する容量の単位格納領域を備え、該
単位の格納領域を使用して該単位のデータ量ごとに該記
憶装置の一部のデータを保持するキャッシュメモリと、
処理装置からの該記憶装置へのアクセスコマンドに応じ
て該キャッシュメモリをアクセスする制御部であって、
該アクセスコマンドから単位データが格納される単位格
納領域の数を認識する数認識手段、及び該数認識手段の
認識した数に応した該キャッシュメモリの領域をアクセ
スするアクセス手段を有する制御部とを備え、制御部は
該アクセスコマンドが指定する記憶装置に応じたアクセ
ス領域を認識して、該キャッシュメモリに保持されたデ
ータをアクセスするように構成する。
Regarding the control method of a system that performs disk caching to fill the access gap between magnetic drums, magnetic tapes, optical disks, etc., it is common for storage devices with access block capacities that are different from the access block capacity managed by cache memory. The purpose is to provide a disk cache control method that enables high-speed data transfer and ultimately improves processing speed by enabling cache control. It is equipped with a plurality of storage devices each having a different amount, and a unit storage area with a capacity corresponding to a common divisor of the minimum unit data amount of each of the storage devices, and uses the unit storage area to store data for each unit data amount. a cache memory that holds some data in the storage device;
A control unit that accesses the cache memory in response to an access command to the storage device from a processing device,
a control unit having a number recognition means for recognizing the number of unit storage areas in which unit data is stored from the access command; and an access means for accessing an area of the cache memory corresponding to the number recognized by the number recognition means. The control unit is configured to recognize an access area according to the storage device specified by the access command and access data held in the cache memory.

〔産業上の利用分野〕[Industrial application field]

本発明は、主記憶と記憶装置(磁気ディスク。 The present invention focuses on main memory and storage device (magnetic disk).

磁気ドラム、光ディスク等)の間のアクセスギャップを
埋めるキャッシュシステムの制御方式に関する。
This invention relates to a control method for a cache system that fills the access gap between magnetic drums, optical disks, etc.

近年のコンピュータの高性能化に伴い、主記憶と記憶装
置との間のアクセスギャップを埋める一つの手法として
ディスク;1−ヤノシュ機能を持つシステムが現れてき
た。
As the performance of computers has increased in recent years, systems having a disk function have appeared as one method for filling the access gap between main memory and storage devices.

このシステムにおいて、従来はディスクキャッシュを動
作させるリートコマンドが発行されると一定量のデータ
をアクセスの単位(以下、最小アクセスコマンク単位と
称する)として、アクセスブロック(例えば、ディスク
においてはセクタに相当する)ごとにデータを格納する
記憶装置からデータを読み込み主記憶へデータを転送す
ると同時にキャッシュメモリにも取り込む。そうするこ
とにより、取り込み後は、同しブ11ン夕へのアクセス
があるとキャッシュメモリから読み出すことによってア
クセスの高速化が図られている。
In this system, conventionally, when a LEET command was issued to operate the disk cache, a certain amount of data was stored in an access block (e.g., equivalent to a sector on a disk) as an access unit (hereinafter referred to as the minimum access command unit). Data is read from the storage device that stores the data each time the data is stored in the main memory, and at the same time the data is transferred to the main memory and also imported into the cache memory. By doing so, after importing, when there is an access to the same block 11, the data is read from the cache memory, thereby speeding up the access.

キャッシュメモリは、データを格納するデータ格納部と
そのデータのアドレスを格納するアドレス格納部により
構成される。キャッシュメモリのデータ格納部と記憶装
置のデータ格納領域は各々記憶容量の等しいブロック単
位に分割されており、かつデータ格納部とアドレス格納
部は一対一に対応している。そして、データ格納部には
、記憶装置中のデータのコピーが置かれる。
The cache memory includes a data storage section that stores data and an address storage section that stores the address of the data. The data storage section of the cache memory and the data storage area of the storage device are each divided into blocks of equal storage capacity, and the data storage section and address storage section have a one-to-one correspondence. A copy of the data in the storage device is then placed in the data storage unit.

このため、1ブロツクの記憶容量が、キャッシュメモリ
のデータ格納部の1ブロツクの記憶容量と異なる記憶装
置についてはキャッシュ制御を行うことができなかった
。よって、このような記憶装置に対してもキャンシュ制
御が可能となるようにする必要がある。
For this reason, cache control cannot be performed for a storage device in which the storage capacity of one block is different from the storage capacity of one block of the data storage section of the cache memory. Therefore, it is necessary to enable cache control for such storage devices as well.

〔従来の技術〕[Conventional technology]

第6図(a)、(b)に従来の技術を示す。以下、図面
を参照しながら説明する。
A conventional technique is shown in FIGS. 6(a) and 6(b). This will be explained below with reference to the drawings.

第6図(a)は、処理装置からリードコマンドが発行さ
れ、キャッシュメモリ中に該当するデータが格納されて
おり、キャッシュメモリから主記憶へデータを転送する
際の説明図である。
FIG. 6(a) is an explanatory diagram when a read command is issued from the processing device, the corresponding data is stored in the cache memory, and the data is transferred from the cache memory to the main memory.

処理装置からリードコマンドが発行されると、先ず、記
憶装置におけるアドレスがアドレス格納部に格納されて
いるかどうかを検索する。検索の結果、存在している場
合には、キャンシュメモリから該当するアドレスのデー
タを主記憶へ転送する。即ち、キャッシュメモリ中の該
当するデータは主記憶へ転送される。
When a read command is issued from the processing device, first, a search is made to see if the address in the storage device is stored in the address storage section. As a result of the search, if the data exists, the data at the corresponding address is transferred from the cache memory to the main memory. That is, the corresponding data in the cache memory is transferred to the main memory.

第6図(b)は、処理装置からにリードコマンドが発行
され、キャッシュメモリ中に該当するデータが格納され
ておらず、記憶装置から主記憶へデータを転送する際の
説明図である。
FIG. 6(b) is an explanatory diagram when a read command is issued from the processing device, the corresponding data is not stored in the cache memory, and the data is transferred from the storage device to the main memory.

処理装置からリードコマンドが発行されると、先ず、記
憶装置におけるアドレスがアドレス格納部に格納されて
いるかどうかを検索する。検索の結果、存在していない
場合には、記憶装置から該当するアドレスのデータを主
記憶へ転送するとともに、キャッシュメモリへも転送す
る。即ち、アドレス格納部に該当するアドレスを登録す
るとともに、このアドレスに対応させてデータ格納部へ
該当データを書き込む。
When a read command is issued from the processing device, first, a search is made to see if the address in the storage device is stored in the address storage section. As a result of the search, if the data does not exist, the data at the corresponding address is transferred from the storage device to the main memory and also transferred to the cache memory. That is, the corresponding address is registered in the address storage section, and the corresponding data is written in the data storage section in correspondence with this address.

通常上述のようなキャッシュ制御を可能にするために、
記憶装置における1ブロツク、データ格納部におけるl
ブロック、主記憶上に設定された1ブロツクのデータ記
憶容量は等しく設定されている。
Typically, to enable cache control as described above,
1 block in the storage device, 1 block in the data storage unit
The data storage capacity of one block set on the block and main memory is set to be equal.

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

一方近年、1ブロツクの記憶容量が異なる種々の記憶装
置が普及しており、これらを単一のシステムで統括的に
制御する方式が切望されている。
On the other hand, in recent years, various storage devices with different storage capacities per block have become popular, and there is a strong need for a system that can centrally control these devices with a single system.

しかしながら、従来のキャッシュ制御方式においては、
キャッシュメモリの1ブロツクの容量は記憶装置の1ブ
ロツクの容量に固定しであるため、1ブロツクの容量が
キャッシュメモリの1ブロツクの容量と異なる記憶装置
についてはキャッシュ制御を働かせるせることかできな
かった。具体的に一例をあげると、1ブロツクの容量が
512Byteである記憶装置を、データ格納部の1ブ
ロツクの容量が256Byteであるキャッシュメモリ
に適用させようとしても、記憶装置の1ブロツクに格納
された全てのデータをキャッシュメモリの1ブロツクに
収めることができないからである。
However, in the conventional cache control method,
Since the capacity of one block of cache memory is fixed to the capacity of one block of storage device, cache control cannot be applied to storage devices where the capacity of one block is different from the capacity of one block of cache memory. . To give a specific example, even if you try to apply a storage device with a capacity of 1 block of 512 Bytes to a cache memory whose capacity of 1 block of data storage is 256 Bytes, the data stored in 1 block of the storage device This is because all data cannot be stored in one block of cache memory.

また、一般にキャッシュメモリは複数の記憶装置のデー
タを格納することが多く、この場合を考えてみても、キ
ャッシュメモリの1ブロツクの容量が異なる記憶装置に
対してキャッシュ制御を働かせることができないため、
様々な記憶装置を統括的にキャッシュ制御を働かせるこ
とができない。
Furthermore, in general, cache memory often stores data from multiple storage devices, and even if we consider this case, cache control cannot be applied to storage devices with different capacities for one block of cache memory.
It is not possible to perform cache control in an integrated manner on various storage devices.

本発明は上記課題に鑑み、キャンシュメモリが管理して
いるアクセスブロックの容量と異なる記憶装置に対して
もキャッシュ制御を働かせることにより、高速なデータ
転送、強いては処理速度の向上が可能となるディスクキ
ャッシュ制御方式を提供することを目的とする。
In view of the above-mentioned problems, the present invention provides a disk that enables high-speed data transfer and ultimately improves processing speed by applying cache control to storage devices that differ in capacity from the access blocks managed by cache memory. The purpose is to provide a cache control method.

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

第1図は本発明の原理説明図である。 FIG. 1 is a diagram explaining the principle of the present invention.

1は処理装置であり、処理内容に応じて該制御部2aに
対して、アクセスするデータの格納元である記憶装置と
キャッシュメモリ2bのアクセスブロックの容量の比を
情報として備えたキャッシュメモリ2bをアクセスする
ためのアクセスコマンドを発行するものである。2aは
制御部であり、処理装置1から発行されたコマンドを解
析するとともに、記憶装置#0〜#Nにアクセスするも
のである。2bはキャッシュメモリであり、記憶装置#
0〜#Nのデータを一定容量ごとに格納するものである
。2cは数認識手段であり、処理装置1から発行された
アクセスコマンドから容量比の情報を認識し、アクセス
手段2dに容量比の値を、アクセス手段2dがキャッシ
ュメモリ2bにアクセスすべき回数として指示するもの
である。ここで、アクセスすべき回数とは、例えば、記
憶装置のアクセスブロックの容量が、キャッシュメモリ
の容量の2倍であれば、アクセス手段2dが2回にわた
り、キャッシュメモリ2bにアクセスすることにより、
記憶装置における1アクセスブロツクにアクセスしたも
のと同等となることを意味する。2dはアクセス手段で
あり、上述のようにキャッシュメモリ2bのデータを格
納元である記憶装置のアクセスブロックの容量に対応す
るブロック数だけアクセスするものである。#0〜#N
は記憶装置であり磁気ディスク、磁気ドラム、光ディス
クのような所謂外部記憶装置である。
Reference numeral 1 denotes a processing device which, depending on the processing content, sends a cache memory 2b to the control unit 2a, which is provided with information about the ratio of the capacity of the storage device that is the storage source of the data to be accessed and the capacity of the access block of the cache memory 2b. It issues an access command for access. 2a is a control unit that analyzes commands issued from the processing device 1 and accesses the storage devices #0 to #N. 2b is a cache memory, storage device #
Data 0 to #N are stored for each fixed capacity. 2c is a number recognition means, which recognizes the capacity ratio information from the access command issued by the processing device 1, and instructs the access means 2d the value of the capacity ratio as the number of times the access means 2d should access the cache memory 2b. It is something to do. Here, the number of times the access should be made is, for example, if the capacity of the access block of the storage device is twice the capacity of the cache memory, the access means 2d accesses the cache memory 2b twice.
This means that it is equivalent to accessing one access block in the storage device. Reference numeral 2d denotes an access means, which accesses the data in the cache memory 2b by the number of blocks corresponding to the capacity of the access block of the storage device that is the storage source, as described above. #0~#N
is a storage device, and is a so-called external storage device such as a magnetic disk, magnetic drum, or optical disk.

〔作用〕[Effect]

処理装置1は、制御部2aに対して、キャッシュメモリ
2b中のデータにアクセスする際、そのデータの格納元
となる記憶装置のアクセスブロックの容量がキャッシュ
メモリ2bの1アクセスブロツクの容量の何倍であるか
の情報(容量比の情報)を備えたコマンドを発行する。
When accessing data in the cache memory 2b, the processing device 1 instructs the control unit 2a to determine how many times the capacity of the access block of the storage device that is the storage source of that data is compared to the capacity of one access block in the cache memory 2b. Issue a command with information on whether the capacity ratio is the same (capacity ratio information).

制御部2aはこのコマンドに書き込まれたコマンド内容
等の情報を解析する。一方、数認識手段2cは容量比の
値を、アクセス手段2dがキャンシュメモリにアクセス
すべき回数として通知する。この通知を受けてアクセス
手段2dは、キャッシュメモリ2bのデータを格納元で
ある記憶装置の1アクセスブロツクの容量に対応するブ
ロック数だけアクセスすることになる。先にも述べたよ
うに、例えば、記憶装置の1アクセスブロツクの容量が
キャッシュメモリ2bの1アクセスブロツクの容量の2
倍0 であれば、アクセス手段2dはキャッシュメモリ2bの
二つのアクセスブロックを繰り返してアクセスすること
により、この2ブロツクがあたかも1ブロツクであるか
のように動作する。即ち、処理装置Iの要求するデータ
がキャッシュメモリ2b中に存在する場合には上記の如
くアクセス可能となる。また、処理装置Iの要求するデ
ータがキャッシュメモリ2b中に存在しない場合にも同
様にアクセスすることにより(この場合、ライトコマン
ド)、記憶装置における同一ブロックであることを示す
情報を書込み、以降のアクセスが可能となる。
The control unit 2a analyzes information such as command contents written in this command. On the other hand, the number recognition means 2c notifies the value of the capacity ratio as the number of times the access means 2d should access the cache memory. Upon receiving this notification, the access means 2d accesses the data in the cache memory 2b by the number of blocks corresponding to the capacity of one access block of the storage device that is the storage source. As mentioned earlier, for example, the capacity of one access block of the storage device is twice the capacity of one access block of the cache memory 2b.
If the number is 0, the access means 2d repeatedly accesses the two access blocks of the cache memory 2b, thereby operating as if these two blocks were one block. That is, if the data requested by the processing device I exists in the cache memory 2b, it can be accessed as described above. Furthermore, even if the data requested by the processing device I does not exist in the cache memory 2b, by similarly accessing it (in this case, using a write command), information indicating that the data is the same block in the storage device is written, and subsequent Access is possible.

〔実施例〕〔Example〕

第2図に本発明の対象となるシステムの一例をあげ、以
下同システムの構成及び動作について詳細に説明する。
FIG. 2 shows an example of a system to which the present invention is applied, and the configuration and operation of the system will be described in detail below.

同図において、1は処理装置であり、少なくともキャッ
シュメモリ202.記憶装置#0−#Nをアクセスする
ためのコマンドを発行するものである。2はテ′イスク
キャンシュf#J?卸部であり、マクロな意味でディス
クキャンシュ制御を行うものである。201はMPUで
あり、実際にディスクキャンシュ制御を実行するもので
ある。202はキャッシュメモリであり、キャッシュエ
ントリRAM202aとキャッシュバッファRAM20
2bにより構成される。2.02aはキャッシュエント
リRAMであり、キャッシュバッファRAM202bに
格納したデータを検索するためのものである。202b
はキャッシュバッファRAMであり、記憶装置に書き込
んだデータ、或いは記憶装置から読み出したデータを保
持するだめのものである。本実施例においては、キャッ
シュバッファRAMの1アクセスブロツクの容量は25
6Byteとする。203はROMであり、MP[J2
01の制御プログラムを格納するものである。204は
RAMであり、キャッシュ制御を実行する際のワークエ
リアとなるものである。205は共通ハス制御部であり
、共通バスを介して処理装置1、或いは主記憶3との間
でデータの授受を行うもの冊 2 である。206は入出力バス制御部であり、各種記憶装
置をアクセス制御するものである。3は主記憶であり、
キャッシュメモリ202、或いは記憶装置#0〜#2の
データを格納するものである。
In the figure, reference numeral 1 denotes a processing device, which includes at least a cache memory 202. It issues commands to access storage devices #0-#N. 2 is Te'isk Canche f#J? It is a wholesaler and performs disk cache control in a macro sense. 201 is an MPU that actually executes disk cache control. A cache memory 202 includes a cache entry RAM 202a and a cache buffer RAM 20.
2b. 2.02a is a cache entry RAM, which is used to retrieve data stored in the cache buffer RAM 202b. 202b
A cache buffer RAM is used to hold data written to the storage device or data read from the storage device. In this embodiment, the capacity of one access block of the cache buffer RAM is 25
It is assumed to be 6 bytes. 203 is a ROM, MP[J2
01 control program is stored therein. A RAM 204 serves as a work area when cache control is executed. Reference numeral 205 denotes a common bus control unit, which exchanges data with the processing device 1 or the main memory 3 via the common bus. 206 is an input/output bus control unit that controls access to various storage devices. 3 is main memory,
It stores data in the cache memory 202 or storage devices #0 to #2.

また、処理装置1はこの主記憶3ヘアクセスして実際の
処理を行う。#0〜#2は記憶装置であり、具体的には
、磁気ディスク、磁気ドラム、光ディスク等の所謂外部
記憶装置であり、本例においては、その各々の1アクセ
スブロツクの容量は以下のとおりとする。
Furthermore, the processing device 1 accesses this main memory 3 to perform actual processing. #0 to #2 are storage devices, specifically so-called external storage devices such as magnetic disks, magnetic drums, optical disks, etc. In this example, the capacity of one access block of each is as follows. do.

記憶装置# 0−m−・−256B y t e記憶装
置# 1−−−−一−−−−512B y t e記憶
装置# 2−−−1024 B y t e以上により
構成されたシステムにおいて、その動作は次のものとな
る。
Storage device #0-m--256 Byte Storage device #1----1----512 Byte Storage device #2---1024 Byte In a system configured with or more, Its operation is as follows.

(1)リード制御 1)処理装置1は記憶装置からの読み出し要求が発生す
ると、ディスクキャンシュ制御部2ヘリ−トコマントを
発行する。
(1) Read control 1) When a read request from a storage device occurs, the processing device 1 issues a command to the disk cache control unit 2.

2)ディスクキャッシュ制御部2は、リードコマンドを
受けると、MPU201が該当するデータをキャンシュ
バッファRAM202 b内に持っているかを、キャッ
シュエントリRAM202aで検索する。
2) Upon receiving the read command, the disk cache control unit 2 searches the cache entry RAM 202a to see if the MPU 201 has the corresponding data in the cache buffer RAM 202b.

◎リードヒツト時 キャンシュバッファRAM202 b内に該当するデー
タを持っている場合、MPU201はキャッシュバッフ
ァRAM202 bから主記憶3ヘデータを転送する。
◎When there is a read hit, if the cache buffer RAM 202b has the corresponding data, the MPU 201 transfers the data from the cache buffer RAM 202b to the main memory 3.

◎リードミスヒツト時 MPU201は、10バス制御部206を介して記憶装
置#0〜#2をアクセスし、該当するデータを記憶装置
から主記憶3へ転送する。
◎When a read miss occurs, the MPU 201 accesses the storage devices #0 to #2 via the 10 bus control unit 206, and transfers the corresponding data from the storage device to the main memory 3.

この場合、MPU201は主記憶3ヘデータを転送する
際に、1O−Bus制御部206を介して、キャッシュ
バッファRAM202 bヘデータを取り込むとともに
、キャッシュエントリRAM202aにそのデータに対
応するアドレスを書き込み、以降のリード処理の高速化
を図る 3 4 3)ディスクキャッシュ制御部2は、処理装置1ヘリー
ド処理が終了したことを共通バス制御部205を介して
通知し、次のコマンドを待つ。
In this case, when transferring data to the main memory 3, the MPU 201 takes in the data to the cache buffer RAM 202b via the 1O-Bus control unit 206, writes an address corresponding to the data in the cache entry RAM 202a, and writes the address corresponding to the data to the cache entry RAM 202a, and then reads 3) The disk cache control unit 2 notifies the processing device 1 via the common bus control unit 205 that the read process has ended, and waits for the next command.

(2)ライト制御 1)処理装置1は記憶装置に対して書き込み要求が発生
すると、共通バス制御部205を介してディスクキャッ
シュ制御部2ヘライトコマンドを発行する。
(2) Write control 1) When a write request is issued to the storage device, the processing device 1 issues a write command to the disk cache control unit 2 via the common bus control unit 205.

2)ディスクキャッシュ制御部2では、ライトコマンド
を受けると、MPU201が該当する空間をキャッシュ
バッファRAM202 b内に持っているかどうかを、
キャッシュエントリRAM202aを使って検索する。
2) When the disk cache control unit 2 receives a write command, it determines whether the MPU 201 has the corresponding space in the cache buffer RAM 202b.
Search using cache entry RAM 202a.

◎ヒツト時 キャッシュバッファRAM202 b内に該当する空間
を持っている場合、MPU201はデバイスとキャッシ
ュメモリ202の該当する空間に主記憶3から読み出し
たデータを書き込む。
When the MPU 201 has a corresponding space in the cache buffer RAM 202b, the MPU 201 writes the data read from the main memory 3 into the corresponding space in the device and cache memory 202.

◎ミスヒツト時 キャッシュメモリ202内に該当する空間がない場合に
は、MPU201はLRU論理等によりキャッシュメモ
リ202内に新規な空間を取り出し、記憶装置と新規に
取り出した空間に主記憶3から読み出したデータを書き
込む。
◎If there is no corresponding space in the cache memory 202 at the time of a miss, the MPU 201 takes out a new space in the cache memory 202 using LRU logic, etc., and transfers the data read from the main memory 3 to the storage device and the newly taken out space. Write.

3)ディスクキャッシュ制御部2は、処理装置lヘライ
ト処理が終了したことを共通ハス制御部205を介して
通知し、処理装置1からの次のコマンドを待つ。
3) The disk cache control unit 2 notifies via the common lotus control unit 205 that the processing device 1 write process has ended, and waits for the next command from the processing device 1.

第3図は本発明に用いるコマンドのフォーマット例を示
す図である。
FIG. 3 is a diagram showing an example of the format of commands used in the present invention.

図中、aはコマンドコードであり、コマンド内の一領域
に書き込まれたコマンドの種別を制御部2aに通知する
ための情報である。bはデバイスIDであり、同様にコ
マンド内の一領域に書き込まれたコマンドの対象となる
データの格納元の記憶装置に対応したキャッシュメモリ
中のデータを制御部2aに通知するための情報である。
In the figure, a is a command code, which is information for notifying the control unit 2a of the type of command written in one area within the command. b is a device ID, which is also information for notifying the control unit 2a of the data in the cache memory corresponding to the storage device of the storage source of the data targeted by the command written in one area within the command. .

Cは本発明を特徴づける識別コードであり、アクセスす
るキャッシュメモリ2b中の最小アクセスブロックごと
に、記憶装置#0〜#Nにおける最小アク5 6 セスプロッタと対応させるための情報が書き込まれてい
る。例えば、キャッシュバッファRAM202bの1ブ
ロツクの容量が256Byteであるシステムに、最小
アクセスブロック単位の容量がそれぞれ256Byte
、512Byte、1024Byteの記憶装置#0〜
#2のデータを格納する場合を考える。この場合、コマ
ンドの一領域に2ビツトの特定領域を設けておき、リー
ド/ライト等のアクセス要求の対象となる記憶装置の1
ブロツクのデータ容量に対応するキャッシュメモリのブ
ロック数が、256Byteのときは1ブロツクとなる
ため、0→00 (21を対応させる。512B・yt
eの時は2ブロツクとなるため、1=01+z+ を対
応させる。1024Byteの時は3ブロツクとなるた
め、2→10 +z+ を対応させる。この情報に従っ
てMPU201は各々該当するブロック数を1ブロツク
と見なして処理する。或いは、MPU201が該当する
ブロック数を確保するとともにこの情報をキャッシュエ
ンド’JRAM202a中の確保した1エントリ内に各
々書き込む。dはアクセスブロックアドレスコードであ
り、データをリード/ライトしようとするアクセスブロ
ックのアト°レスを示すものである。
C is an identification code that characterizes the present invention, and information for making each minimum access block in the cache memory 2b to be accessed correspond to the minimum access plotter in the storage devices #0 to #N is written. For example, in a system where the capacity of one block of the cache buffer RAM 202b is 256 Bytes, the capacity of each minimum access block unit is 256 Bytes.
, 512 Byte, 1024 Byte storage device #0 ~
Consider the case where data #2 is stored. In this case, a 2-bit specific area is provided in one area of the command, and one area of the storage device that is the target of access requests such as read/write is set.
When the number of cache memory blocks corresponding to the data capacity of a block is 256 Bytes, it becomes one block, so 0 → 00 (corresponding to 21.512B・yt
In the case of e, there are two blocks, so 1=01+z+ is made to correspond. When it is 1024 bytes, there are 3 blocks, so 2→10 +z+ is made to correspond. According to this information, the MPU 201 processes each corresponding block number as one block. Alternatively, the MPU 201 secures the corresponding number of blocks and writes this information into each secured entry in the cache end JRAM 202a. d is an access block address code, which indicates the address of the access block from which data is to be read/written.

eは主記憶アドレスコードであり、主記憶3のアドレス
を示す。
e is a main memory address code and indicates the address of the main memory 3.

第4図は本発明におけるキャッシュエントリRAM20
2 aとキャッシュバッファRAM202bの接続形態
を示す図である。
FIG. 4 shows the cache entry RAM 20 in the present invention.
2a and a cache buffer RAM 202b. FIG.

コマンドの内容を解析したMPU201は、キャッシュ
メモリ202から検索のため、RAM204中のキャッ
シュ検索用テーブルにキャッシュエントリRAM202
 bを接続する。そして、キャッシュエントリRAM2
02 a内部の領域に識別コードにより、(キャッシュ
メモリ中のデータの格納下である記憶装置のセクタ容量
)/(キャシュバッファRAM202 bの1ブロツク
の容量)個のキャシュバッファRAM202 bのブロ
ックにこの旨を書き込み、以降のアクセス要求に対して
キャッシュ制御可能とする。
After analyzing the contents of the command, the MPU 201 writes a cache entry RAM 202 in the cache search table in the RAM 204 in order to search from the cache memory 202.
Connect b. And cache entry RAM2
02 An identification code is written in the internal area of the cache buffer RAM 202b to (sector capacity of the storage device where the data in the cache memory is stored)/(capacity of 1 block of the cache buffer RAM 202b) blocks of the cache buffer RAM 202b. is written to enable cache control for subsequent access requests.

第5図に本発明の実施例のフローチャートを示 7− 8 す。以下、同図を用いて、1エントリが256Byte
に合わせであるキャッシュメモリ202に対して、セク
タ容量が1024Byteである光4ディスク(記憶装
置#2)から主記憶へのデータ転送要求が発生した際の
流れを示すフローチャートである。
FIG. 5 shows a flowchart of an embodiment of the present invention. Below, using the same figure, one entry is 256 Bytes.
12 is a flowchart showing the flow when a data transfer request is issued to the cache memory 202 from the optical 4 disk (storage device #2) with a sector capacity of 1024 bytes to the main memory.

◇3tepl 処理装置lからキャッシュバッファRAM202b、或
いは光ディスクに対するリード要求が発生する。
◇3tepl A read request to the cache buffer RAM 202b or optical disk is generated from the processing device 1.

◇5tep2 光ディスクは1024Byte/1セクタのため、第3
図における識別コード2をコマンドにセットする。
◇5tep2 Since the optical disc is 1024 Bytes/1 sector, the third
Set identification code 2 in the figure to the command.

◇5tep3 処理装置1はIOスタート命令により、主記憶3より該
当するコマンドを読み出し、共通バス制御部205を介
してMPU201へ転送する。
◇5tep3 In response to the IO start command, the processing device 1 reads the corresponding command from the main memory 3 and transfers it to the MPU 201 via the common bus control unit 205.

◇Step4 MPU201は第3図に示したコマンドコード。◇Step 4 The MPU 201 has the command code shown in FIG.

デバイスID、識別コード、アクセスプロ・ツクアドレ
ス、システムメモリアドレス等を解析する。
Analyze device ID, identification code, access protocol address, system memory address, etc.

◇Step5 MPU201は解析結果に応じて、キャッシュエントリ
RAM202 aを使って、キャッシュバッファRAM
202 b中に該当するデータを検索する。即ち、第4
図を用いて説明したようにMPU201はRAM204
中のキャッシュ検索用テーブルにキャッシュエントリR
AM202 bを接続して該当するデータのアドレスが
存在するかどうかを検索する。
◇Step 5 The MPU 201 uses the cache entry RAM 202a to store the cache buffer RAM according to the analysis result.
202 Search for corresponding data in b. That is, the fourth
As explained using the diagram, the MPU 201 uses the RAM 204
Cache entry R in the cache search table inside
AM202b is connected to search for the existence of the address of the corresponding data.

◇5tep6 検索の結果、該当するデータがキャッシュバッファ20
2b中にあったか(ヒツトしたか)どうかを判断する。
◇5step6 As a result of the search, the corresponding data is in cache buffer 20
Determine whether it was in 2b (hit).

◇5tep7 ヒツトした場合には該当するアドレスのデータがキャッ
シュバッファRAM202 bがら主記憶3へDMA転
送される。
◇5tep7 If there is a hit, the data at the corresponding address is DMA transferred from the cache buffer RAM 202b to the main memory 3.

◇5tep8 9 20 転送処理が終了すると、MPU201は共通ハス制御部
205を閉じる。
◇5tep8 9 20 When the transfer process is completed, the MPU 201 closes the common lotus control unit 205.

◇5tep9 処理装置1へ処理終了を割り込み通知する。◇5tep9 An interrupt notification is sent to the processing device 1 that the processing has ended.

◇5teplO 処理装置1は処理終了後の状態をチエツクする。◇5teplO The processing device 1 checks the status after the processing is completed.

一方、5tep6においてヒツトしなかった場合には以
下の流れとなる。
On the other hand, if there is no hit in 5tep6, the flow will be as follows.

◇5tepl 1 該当するアドレスのデータが光ディスクから主記憶3へ
DMA転送される。
◇5tepl 1 Data at the corresponding address is transferred from the optical disk to the main memory 3 by DMA.

以下、5tep8,5tep9,5teplOの流れと
なる。
The following flow is 5tep8, 5tep9, and 5teplO.

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

本発明によれば、1ブロツクのデータ記憶容量が、デー
タ格納部(キャッシュバッファRAM)の1ブロツクの
設定容量の整数倍である記憶装置について、キャッシュ
制御が可能となる。
According to the present invention, cache control is possible for a storage device in which the data storage capacity of one block is an integral multiple of the set capacity of one block of the data storage section (cache buffer RAM).

また、1ブロツクのデータ記憶容量の異なる複数の記憶
装置に統括的にキャッシュ制御をはたらかせることもで
きる。
Further, cache control can be performed in an integrated manner on a plurality of storage devices having different data storage capacities for one block.

このため、キャッシュ系システムの拡張が容易となり、
強いてはシステムにおける処理速度の高速化が図られる
This makes it easy to expand the cache system,
In the end, the processing speed of the system can be increased.

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

第1図は本発明の原理説明図、 第2図は1実施例の構成図、 第3図は本発明に用いるコマンドのフォーマット例を示
す図、 第4図は本発明におけるキャッシュエントリRAMとキ
ャッシュバッファRAMの接続形態を示す図、 第5図は本発明の実施例のフローチャート、第6図は従
来の技術である。 第1図中、符号を付したものは次の通りである。 1 −−−−−−−−−−−−一−−処理装置2 a−
−−−−〜−〜−−−−−−−−制御部2 b  −−
−−−−=−−−−−−−−−−−−−キャッシュメモ
リ1 〜22 2c 数認識手段 d アクセス手段 #0〜#N 記憶装置 3 〉く 寸 役せ
Fig. 1 is a diagram explaining the principle of the present invention, Fig. 2 is a configuration diagram of one embodiment, Fig. 3 is a diagram showing an example of the format of commands used in the present invention, and Fig. 4 is a cache entry RAM and cache in the present invention. FIG. 5 is a flowchart of an embodiment of the present invention, and FIG. 6 is a diagram showing a conventional technique. In FIG. 1, the reference numerals are as follows. 1 -----------1-- Processing device 2 a-
---------------Control unit 2 b ---
−−−−=−−−−−−−−−−−−Cache memory 1 to 22 2c Number recognition means d Access means #0 to #N Storage device 3

Claims (1)

【特許請求の範囲】 一回にアクセス可能な最小単位のデータ量が各々異なる
複数の記憶装置(#0〜#N)と、該記憶装置(#0〜
#N)の各々の最小単位のデータ量の公約数に相当する
容量の単位格納領域を備え、該単位の格納領域を使用し
て該単位のデータ量ごとに該記憶装置(#0〜#N)の
一部のデータを保持するキャッシュメモリ(2b)と、 処理装置(1)からの該記憶装置(#0〜#N)へのア
クセスコマンドに応じて該キャッシュメモリ(2b)を
アクセスする制御部(2a)であって、 該アクセスコマンドから単位データが格納される単位格
納領域の数を認識する数認識手段(2c)、及び該数認
識手段(2c)の認識した数に応じた該キャッシュメモ
リ(2b)の領域をアクセスするアクセス手段(2d)
を有する制御部(2a)とを備え、制御部(2a)は該
アクセスコマンドが指定する記憶装置に応じたアクセス
領域を認識して、該キャッシュメモリ(2b)に保持さ
れたデータをアクセスすることを特徴とするキャッシュ
制御方式。
[Scope of Claims] A plurality of storage devices (#0 to #N) each having a different amount of data in the smallest unit that can be accessed at one time;
A unit storage area of a capacity corresponding to a common divisor of the minimum unit data amount of each of the storage devices (#0 to #N) is provided. ); and control for accessing the cache memory (2b) in response to an access command from the processing device (1) to the storage device (#0 to #N). part (2a), a number recognition means (2c) for recognizing the number of unit storage areas in which unit data is stored from the access command; and the cache according to the number recognized by the number recognition means (2c). Access means (2d) for accessing an area of memory (2b)
and a control unit (2a) having a control unit (2a), the control unit (2a) recognizing an access area according to the storage device specified by the access command and accessing the data held in the cache memory (2b). A cache control method featuring:
JP1300272A 1989-11-16 1989-11-16 Cache control system Pending JPH03158944A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP1300272A JPH03158944A (en) 1989-11-16 1989-11-16 Cache control system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP1300272A JPH03158944A (en) 1989-11-16 1989-11-16 Cache control system

Publications (1)

Publication Number Publication Date
JPH03158944A true JPH03158944A (en) 1991-07-08

Family

ID=17882796

Family Applications (1)

Application Number Title Priority Date Filing Date
JP1300272A Pending JPH03158944A (en) 1989-11-16 1989-11-16 Cache control system

Country Status (1)

Country Link
JP (1) JPH03158944A (en)

Similar Documents

Publication Publication Date Title
US7228399B2 (en) Control method for storage device controller system, and storage device controller system
US7640375B2 (en) DMA controller, method, information processing system, and program for transferring information blocks comprising data and descriptors
JP3753598B2 (en) Computer, computer system and data transfer method
JP7131053B2 (en) Storage device, information processing program and information processing system
JP4461089B2 (en) Storage control apparatus and storage control method
KR100843199B1 (en) High speed IDE interface device and method for the same
US20060277326A1 (en) Data transfer system and method
JP4664077B2 (en) Improved transfer performance of optical storage
JPH03158944A (en) Cache control system
JPH01159746A (en) Disk cache control system
JPH11327802A (en) Disk system
US7430634B2 (en) Data transfer apparatus and data transfer method
JPH05289818A (en) Disk array control system
CN110968537B (en) PCIE SSD-based FPGA searching and matching method
US6298437B1 (en) Method for vectoring pread/pwrite system calls
JP2994917B2 (en) Storage system
WO1994022134A1 (en) Buffer control for data transfer within hard disk during idle periods
JP2005346426A (en) Data sharing disk device
JP2004086985A (en) Disk storage device
JPH09237224A (en) Disk array device
JPH0477916A (en) Magnetic disk device
JPH04113432A (en) Virtual storage control method
JPH02165247A (en) Memory device
JPH03176749A (en) Control system for buffer storage system
JPS5985563A (en) Disk controller