JP2000227865A - Device and method for recording and reproducing information for segment cache system - Google Patents

Device and method for recording and reproducing information for segment cache system

Info

Publication number
JP2000227865A
JP2000227865A JP11123098A JP12309899A JP2000227865A JP 2000227865 A JP2000227865 A JP 2000227865A JP 11123098 A JP11123098 A JP 11123098A JP 12309899 A JP12309899 A JP 12309899A JP 2000227865 A JP2000227865 A JP 2000227865A
Authority
JP
Japan
Prior art keywords
segment
size
cache memory
cache
data
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
Application number
JP11123098A
Other languages
Japanese (ja)
Inventor
Yuji Horie
裕司 堀江
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.)
Olympus Corp
Original Assignee
Olympus Optical Co 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 Olympus Optical Co Ltd filed Critical Olympus Optical Co Ltd
Priority to JP11123098A priority Critical patent/JP2000227865A/en
Publication of JP2000227865A publication Critical patent/JP2000227865A/en
Withdrawn legal-status Critical Current

Links

Abstract

PROBLEM TO BE SOLVED: To accelerate a processing speed at the time of read and write by improving the use efficiency of a cache memory by setting a cache area to a segment of optimum segment size reflected with logical features at the time of actual reading/writing from a host computer to a disk. SOLUTION: A CPU 7 sends an instruction to a read/write control part on the basis of respective managing data, for example, and during the idle time of processing, data are read out of a cache memory and written onto a disk. Besides, the CPU 7 has the functions of a disk analytic part 7a for analyzing the logical format of the disk and a cache setting part 7b for setting the segment of the cache memory on the basis of the logical format of the disk.

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】本発明はセグメントキャッシ
ュ方式の情報記録再生装置及びセグメントキャッシュ方
式の情報記録再生方法、更に詳しくはキャッシュメモリ
の各セグメントの構造設定部分に特徴のあるセグメント
キャッシュ方式の情報記録再生装置及びセグメントキャ
ッシュ方式の情報記録再生方法に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a segment cache type information recording / reproducing apparatus and a segment cache type information recording / reproducing method, and more particularly, to a segment cache type information recording characteristic in a structure setting portion of each segment of a cache memory. The present invention relates to a reproducing apparatus and an information recording / reproducing method of a segment cache system.

【0002】[0002]

【従来の技術】一般に光ディスク装置などの情報記録再
生装置は、情報処理装置におけるホストコンピュータの
外部記録装置として用いられているが、記録媒体に対す
るデータの書き込み処理及び読み出し処理はホストコン
ピュータとの間でのデータ転送処理速度よりも遅いた
め、近年では中間にキャッシュメモリを設け、このキャ
ッシュメモリを介してデータ転送を行うことにより、デ
ータの記録処理や再生処理の高速化を図ったものが用い
られてきている。特に、光ディスクを記録媒体として用
いる光ディスク装置では、記録媒体への書き込み処理に
多くの時間がかかるため、記録データや再生データを一
時格納するディスクキャッシュメモリを設けたものが一
般的である。
2. Description of the Related Art Generally, an information recording / reproducing device such as an optical disk device is used as an external recording device of a host computer in an information processing device. In recent years, a cache memory is provided in the middle, and data transfer is performed via the cache memory to speed up data recording and reproduction. ing. In particular, in an optical disk apparatus using an optical disk as a recording medium, since writing to the recording medium takes a lot of time, a disk cache memory for temporarily storing recording data and reproduction data is generally provided.

【0003】このようなキャッシュメモリを備えた装置
として、例えば特開平2−122345号公報に開示さ
れている記憶制御装置では、データの読み出し要求があ
った場合に、ホストコンピュータから要求されたデータ
と共に、さらに先のブロックのデータをあらかじめ先読
みするようにした、いわゆるリードアヘッド方式のキャ
ッシュメモリ装置が提案されている。この構成によれ
ば、ホストコンピュータから要求されたデータにおい
て、キャッシュメモリに格納されているデータについて
は記録媒体から読み出さずにキャッシュメモリよりホス
トコンピュータに転送することによって、読み出し処理
時のアクセスタイムを短縮でき、さらに、先読み処理に
よって読み出し時のキャッシュメモリのヒット率を向上
させることが可能である。
As a device provided with such a cache memory, for example, in a storage control device disclosed in Japanese Patent Application Laid-Open No. 2-122345, when a data read request is made, the data is sent together with the data requested by the host computer. A so-called read-ahead type cache memory device has been proposed in which data of a further block is pre-read in advance. According to this configuration, in the data requested by the host computer, the data stored in the cache memory is transferred from the cache memory to the host computer without being read from the recording medium, thereby shortening the access time in the read processing. It is possible to further improve the hit rate of the cache memory at the time of reading by the pre-reading process.

【0004】また、書き込み処理時のアクセスタイムを
向上させるため、データをキャッシュメモリに一旦書き
込んだ後、CPUの処理の空き時間に記録媒体にデータ
を書き込むライトバック方式のキャッシュメモリを備え
た装置が提案されている。
Further, in order to improve the access time at the time of write processing, an apparatus having a write-back type cache memory which writes data to a cache memory and then writes the data to a recording medium during an idle time of processing by a CPU has been proposed. Proposed.

【0005】このような情報記録再生装置では、一般に
キャッシュメモリには記憶領域を連続的に繰り返して使
用するリングバッファ方式のものを用いているため、書
き込み処理時及び読み出し処理時においてキャッシュメ
モリに格納されているデータの検索を行うことができな
い。従って、場合によってはキャッシュの効果を十分発
揮できないという問題点があった。
In such an information recording / reproducing apparatus, a ring buffer system in which a storage area is used continuously and repeatedly is generally used as a cache memory, so that the data is stored in the cache memory during a write process and a read process. Cannot search for the data that is being saved. Therefore, in some cases, there is a problem that the effect of the cache cannot be sufficiently exhibited.

【0006】そこで、特開平3−176726号公報等
において、キャッシュメモリの記憶領域を複数のセグメ
ントに分割して使用するセグメントキャッシュ方式のキ
ャッシュメモリを備えた装置が提案されている。このよ
うなセグメントキャッシュ方式のキャッシュメモリを用
いることにより、例えば読み出し処理時において以前の
書き込み処理時にキャッシュメモリに格納したデータを
検索することができ、該当するデータが存在する場合に
キャッシュメモリから読み出してホストコンピュータへ
転送することによって処理速度を向上できる。
In view of this, Japanese Patent Application Laid-Open No. 3-176726 proposes a device provided with a segment cache type cache memory which divides a storage area of the cache memory into a plurality of segments for use. By using such a segment cache type cache memory, for example, at the time of read processing, data stored in the cache memory at the time of previous write processing can be searched, and when there is applicable data, the data is read from the cache memory. The processing speed can be improved by transferring the data to the host computer.

【0007】この特開平3−176726号公報のセグ
メントキャッシュ方式のキャッシュメモリでは、セグメ
ントの分割を記録媒体のトラックにより決定しており、
分割するセグメント数や各セグメントの大きさなどにつ
いてあまり考慮されておらず、ランダムなライトコマン
ドを連続して受信した場合など、場合によっては十分な
パフォーマンスが得られないという問題点があった。
In the cache memory of the segment cache system disclosed in Japanese Patent Application Laid-Open No. 3-176726, segment division is determined by tracks of a recording medium.
The number of segments to be divided, the size of each segment, and the like are not considered so much, and there is a problem that sufficient performance cannot be obtained in some cases, such as when random write commands are continuously received.

【0008】そこで、特開平10−63578号公報で
は、ディスクに対して読み書きを行うデータを一時格納
するキャッシュメモリを有し、キャッシュメモリには複
数のセグメントに分割されたセグメントキャッシュ方式
のキャッシュメモリ領域であるセグメントキャッシュ領
域が設けられ、処理速度の向上を図る情報記録再生装置
が提案されている。上記セグメントキャッシュ領域は、
CPUのメインメモリの容量などの条件に応じて決定さ
れる最適なセグメント数となるようセグメント数を設定
して一定とし、該セグメントキャッシュ領域の容量に対
応させて各セグメントの大きさが設定されて分割され、
ランダムのライトコマンドなどに対して十分なパフォー
マンスが得られるようになっている。
Japanese Patent Laid-Open Publication No. Hei 10-63578 has a cache memory for temporarily storing data to be read from or written to a disk. The cache memory has a segment cache type cache memory area divided into a plurality of segments. An information recording / reproducing apparatus has been proposed in which a segment cache area is provided to improve the processing speed. The segment cache area is
The number of segments is set so as to be an optimum number of segments determined according to conditions such as the capacity of the main memory of the CPU, and is fixed. The size of each segment is set according to the capacity of the segment cache area. Split,
Sufficient performance is obtained for random write commands.

【0009】[0009]

【発明が解決しようとする課題】しかしながら、上記特
開平10−63578号公報等では、セグメント数を予
め所定の整数に設定するため、キャッシュメモリに設定
されるセグメントのサイズが単にキャッシュメモリのサ
イズを上記所定の整数で割った一定のサイズとなってお
り、セグメントの構造が実際にホストコンピュータがデ
ィスクに読み書きを行う際の論理的な特徴を備えていな
いため、読み書きを行うデータに対して適切なセグメン
トのサイズとなっておらず、キャッシュメモリの容量を
有効に使うことができず、十分なキャッシュメモリの効
果が得られないという問題点がある。
However, in Japanese Patent Laid-Open Publication No. Hei 10-63578, the number of segments is set to a predetermined integer in advance, so that the size of the segment set in the cache memory is simply the size of the cache memory. It is a fixed size divided by the above predetermined integer, and since the structure of the segment does not have logical characteristics when the host computer actually reads and writes to the disk, it is appropriate for the data to be read and written. There is a problem that the size of the segment is not used, the capacity of the cache memory cannot be used effectively, and a sufficient effect of the cache memory cannot be obtained.

【0010】本発明は、上記事情に鑑みてなされたもの
であり、セグメントキャッシュ方式のキャッシュメモリ
を用いる場合に、実際にホストコンピュータがディスク
に読み書きを行う際の論理的な特徴を反映させた最適な
セグメントサイズのセグメントにキャッシュ領域を設定
してキャッシュメモリの使用効率を上げ、リード時及び
ライト時の処理速度を向上させることのできる情報記録
再生装置を提供することを目的としている。
The present invention has been made in view of the above circumstances, and has been made in consideration of the above circumstances. When a cache memory of a segment cache system is used, the optimum characteristics which reflect the logical characteristics when a host computer actually reads and writes data on a disk are used. It is an object of the present invention to provide an information recording / reproducing apparatus capable of setting a cache area in a segment having a large segment size, increasing the use efficiency of a cache memory, and improving the processing speed at the time of reading and writing.

【0011】[0011]

【課題を解決するための手段】本発明のセグメントキャ
ッシュ方式の情報記録再生装置は、記憶領域が複数のセ
グメントに分割され、各セグメントに上位のホストコン
ピュータと記録媒体との間で転送されるデータを一時格
納するセグメントキャッシュ方式のキャッシュメモリ
と、前記キャッシュメモリに対するデータの読み書き制
御、前記キャッシュメモリに格納されたデータの管理及
び検索を行うキャッシュメモリ管理手段とを備え、前記
記録媒体に対して情報の記録再生を行うセグメントキャ
ッシュ方式の情報記録再生装置において、前記キャッシ
ュメモリ管理手段は、前記記録媒体の論理フォーマット
を解析する解析手段と、前記解析手段の解析結果に基づ
き前記キャッシュメモリの各セグメントの構造を設定す
る設定手段とを備えて構成される。
According to the present invention, there is provided an information recording / reproducing apparatus of a segment cache system in which a storage area is divided into a plurality of segments, and data transferred between an upper host computer and a recording medium in each segment. A cache memory of a segment cache system for temporarily storing data, and cache memory management means for controlling reading and writing of data from and to the cache memory, and managing and searching for data stored in the cache memory. In the information recording / reproducing apparatus of the segment cache system for performing recording / reproducing of data, the cache memory management means comprises: an analyzing means for analyzing a logical format of the recording medium; Setting means for setting the structure Constructed.

【0012】本発明のセグメントキャッシュ方式の情報
記録再生装置では、前記解析手段が前記記録媒体の論理
フォーマットを解析し、前記設定手段が前記解析手段の
解析結果に基づき前記キャッシュメモリの各セグメント
の構造を設定することで、セグメントキャッシュ方式の
キャッシュメモリを用いる場合に、実際にホストコンピ
ュータがディスクに読み書きを行う際の論理的な特徴を
反映させた最適なセグメントサイズのセグメントにキャ
ッシュ領域を設定してキャッシュメモリの使用効率を上
げ、リード時及びライト時の処理速度を向上させること
を可能とする。
In the information recording / reproducing apparatus of the segment cache system according to the present invention, the analyzing means analyzes a logical format of the recording medium, and the setting means sets the structure of each segment of the cache memory based on an analysis result of the analyzing means. When using a segment cache cache memory, the cache area is set to a segment with the optimal segment size that reflects the logical characteristics when the host computer actually reads from and writes to the disk. It is possible to increase the use efficiency of the cache memory and improve the processing speed at the time of reading and writing.

【0013】本発明のセグメントキャッシュ方式の情報
記録再生方法は、記憶領域が複数のセグメントに分割さ
れ、各セグメントに上位のホストコンピュータと記録媒
体との間で転送されるデータを一時格納するセグメント
キャッシュ方式のキャッシュメモリに対するデータの読
み書き制御、前記キャッシュメモリに格納されたデータ
の管理及び検索を行い、前記記録媒体に対して情報の記
録再生を行う情報記録再生方法において、前記記録媒体
の論理フォーマットを解析する解析工程と、前記解析手
段の解析結果に基づき前記キャッシュメモリの各セグメ
ントの構造を設定する設定工程とを備えて構成される。
According to the information recording / reproducing method of the segment cache system of the present invention, a storage area is divided into a plurality of segments, and each segment temporarily stores data transferred between a host computer and a recording medium in each segment. In the information recording / reproducing method of reading / writing data from / to the cache memory, managing and retrieving data stored in the cache memory, and recording / reproducing information on / from the recording medium, the logical format of the recording medium is An analysis step for analyzing and a setting step for setting the structure of each segment of the cache memory based on the analysis result of the analysis means are provided.

【0014】本発明のセグメントキャッシュ方式の情報
記録再生方法では、前記解析工程が前記記録媒体の論理
フォーマットを解析し、前記設定工程が前記解析工程の
解析結果に基づき前記キャッシュメモリの各セグメント
の構造を設定することで、セグメントキャッシュ方式の
キャッシュメモリを用いる場合に、実際にホストコンピ
ュータがディスクに読み書きを行う際の論理的な特徴を
反映させた最適なセグメントサイズのセグメントにキャ
ッシュ領域を設定してキャッシュメモリの使用効率を上
げ、リード時及びライト時の処理速度を向上させること
を可能とする。
In the information recording / reproducing method of the segment cache system according to the present invention, the analyzing step analyzes a logical format of the recording medium, and the setting step performs a structure of each segment of the cache memory based on an analysis result of the analyzing step. When using a segment cache cache memory, the cache area is set to a segment with the optimal segment size that reflects the logical characteristics when the host computer actually reads from and writes to the disk. It is possible to increase the use efficiency of the cache memory and improve the processing speed at the time of reading and writing.

【0015】[0015]

【発明の実施の形態】以下、図面を参照しながら本発明
の実施の形態について述べる。
Embodiments of the present invention will be described below with reference to the drawings.

【0016】図1ないし図11は本発明の第1の実施の
形態に係わり、図1は情報記録再生装置の構成を示す構
成図、図2は図1のCPUの機能ブロックを示す機能ブ
ロック図、図3は図1のディスクの論理フォーマットを
示す図、図4は図1のCPUのメイン処理の流れを示す
フローチャート、図5は図4のセグメントサイズの更新
処理の詳細な流れを示すフローチャート、図6は図1の
情報記録再生装置の作用を説明する第1の説明図、図7
は図1の情報記録再生装置の作用を説明する第2の説明
図、図8は図4のセグメントサイズの更新処理の変形例
の詳細な流れを示す第1のフローチャート、図9は図4
のセグメントサイズの更新処理の変形例の詳細な流れを
示す第2のフローチャート、図10は図8及び図9のセ
グメントサイズの更新処理の変形例による情報記録再生
装置の作用を説明する説明図、図11は図1のキャッシ
ュメモリの構成の変形例を示す図である。
FIGS. 1 to 11 relate to a first embodiment of the present invention. FIG. 1 is a block diagram showing a configuration of an information recording / reproducing apparatus, and FIG. 2 is a functional block diagram showing functional blocks of a CPU in FIG. FIG. 3 is a diagram showing a logical format of the disk of FIG. 1, FIG. 4 is a flowchart showing a flow of a main process of the CPU of FIG. 1, FIG. 5 is a flowchart showing a detailed flow of a segment size updating process of FIG. FIG. 6 is a first explanatory view for explaining the operation of the information recording / reproducing apparatus of FIG. 1, and FIG.
FIG. 8 is a second explanatory diagram for explaining the operation of the information recording / reproducing apparatus of FIG. 1, FIG. 8 is a first flowchart showing a detailed flow of a modification of the segment size updating process of FIG. 4, and FIG.
FIG. 10 is a second flowchart showing a detailed flow of a modified example of the segment size updating process. FIG. 10 is an explanatory diagram for explaining the operation of the information recording / reproducing apparatus according to the modified example of the segment size updating process of FIGS. FIG. 11 is a diagram showing a modification of the configuration of the cache memory of FIG.

【0017】本実施の形態では、情報記録再生装置の一
例として光磁気ディスクを用いて記録再生を行う光磁気
ディスクドライブ装置の構成例を示すが、これに限ら
ず、ハードディスク装置、相変化型光ディスク装置、フ
ロッピーディスク装置、あるいは光カード装置等の情報
記録再生装置にも適用できる。
In the present embodiment, an example of the configuration of a magneto-optical disk drive device that performs recording and reproduction using a magneto-optical disk is shown as an example of an information recording / reproducing device. The present invention can also be applied to an information recording / reproducing device such as a device, a floppy disk device, or an optical card device.

【0018】(構成)光磁気ディスクドライブ装置であ
る情報記録再生装置1は、図1に示すように、ホストコ
ンピュータとインターフェースケーブルを介して接続さ
れSCSIによるコマンドやデータのやり取りを制御
(プロトコル制御)するSCSI制御部2と、SCSI
制御部2に接続されスピンドルモータ3により回転され
る記録媒体としてのディスク4に対するデータのやり取
りを制御するディスク制御部5と、ディスク4に対して
読み書きを行うデータを一時格納するキャッシュメモリ
6と、装置各部の動作を制御するCPU7と、CPU7
の動作プログラムを格納したファームウェアプログラム
格納部9と、CPU7の動作時のデータ等を格納する作
業エリアとなるメインメモリ10と、ディスク4に対す
るデータの記録/再生を行う記録再生ヘッド11を制御
するリード/ライト制御部12とを有して構成されてい
る。
(Construction) As shown in FIG. 1, an information recording / reproducing device 1 which is a magneto-optical disk drive device is connected to a host computer via an interface cable and controls the exchange of commands and data by SCSI (protocol control). A SCSI control unit 2 that performs
A disk control unit 5 connected to the control unit 2 for controlling data exchange with a disk 4 serving as a recording medium rotated by a spindle motor 3, a cache memory 6 for temporarily storing data to be read from and written to the disk 4, A CPU 7 for controlling the operation of each part of the apparatus;
And a main memory 10 serving as a work area for storing data during operation of the CPU 7, and a read / write head 11 for controlling a recording / reproducing head 11 for recording / reproducing data on / from the disk 4. / Write control unit 12.

【0019】キャッシュメモリ6の容量は例えば1MB
=800H Blook(=Sector)で、キャッ
シュメモリとしてのデータ領域全体が大きさの等しい複
数の部屋である複数のセグメントに分割されてディスク
4に対して読み書きを行うデータが一時格納されるセグ
メントキャッシュ方式のキャッシュメモリ領域(セグメ
ントキャッシュ領域)24として使用される。
The capacity of the cache memory 6 is, for example, 1 MB.
= 800H Block (= Sector), a segment cache system in which the entire data area as a cache memory is divided into a plurality of segments, each of which is a plurality of rooms having the same size, and data to be read from and written to the disk 4 is temporarily stored. Is used as a cache memory area (segment cache area) 24 of the.

【0020】メインメモリ10は、CPU7の動作プロ
グラム実行時の各変数(スタック領域,グローバル変数
等)が格納されるドライブ管理データ領域、セグメント
キャッシュ領域の管理データ(タグテーブル,セグメン
ト情報等)が格納されるセグメントキャッシュ管理デー
タ領域、リード/ライトコマンドに関するリード/ライ
トパラメータキューが格納されるリード/ライト管理デ
ータ領域の各領域が設けられて構成されている。
The main memory 10 stores a drive management data area in which variables (stack area, global variables, etc.) are stored when the operation program of the CPU 7 is executed, and management data (tag table, segment information, etc.) in the segment cache area. And a read / write management data area for storing a read / write parameter queue related to a read / write command.

【0021】上記構成において、図示しないホストコン
ピュータから転送されてくるコマンドは、SCSI制御
部2を介してCPU7へ送られる。例えばコマンドがラ
イトコマンドである場合、CPU7は書き込みデータを
キャッシュメモリ6のセグメントキャッシュ領域24に
格納し、この書き込みデータに関する管理データをメイ
ンメモリ10のセグメントキャッシュ管理データ領域に
格納する。また、ライトコマンドに関する管理データを
メインメモリ10のリード/ライト管理データ領域に格
納する。
In the above configuration, a command transferred from a host computer (not shown) is sent to the CPU 7 via the SCSI controller 2. For example, when the command is a write command, the CPU 7 stores the write data in the segment cache area 24 of the cache memory 6 and stores management data related to the write data in the segment cache management data area of the main memory 10. Further, the management data relating to the write command is stored in the read / write management data area of the main memory 10.

【0022】CPU7は、全てのデータを受け取ると、
SCSI制御部2を介してホストコンピュータへライト
コマンド処理の完了を返送すると共に、前記各管理デー
タに基づいてディスク制御部5,リード/ライト制御部
12に指示を送り、処理の空き時間にキャッシュメモリ
6からデータを読み出してディスク4に対してデータの
書き込みを行う。
When the CPU 7 receives all the data,
The completion of the write command processing is returned to the host computer via the SCSI control unit 2, and an instruction is sent to the disk control unit 5 and the read / write control unit 12 based on the management data. Data is read from the disk 6 and data is written to the disk 4.

【0023】CPU7は、図2に示すように、ディスク
4の論理フォーマットを解析するディスク解析部7a及
びディスク4の論理フォーマットに基づいてキャッシュ
メモリ6のセグメントを設定するキャッシュ設定部7b
という機能を有している。
As shown in FIG. 2, the CPU 7 analyzes a logical format of the disk 4 by a disk analyzing unit 7a and a cache setting unit 7b that sets a segment of the cache memory 6 based on the logical format of the disk 4.
It has the function of

【0024】ここで、ディスク4は、図3に示すよう
に、例えばFAT16で物理フォーマットされた230
MBのディスクであり、ホストコンピュータが扱うデー
タのクラスタ(1論理ブロック:FAT16ではクラス
タ)サイズが例えば8セクタとなっている。また、ディ
スク4は、FATモードで論理フォーマットされてお
り、Boot Sector,FAT1,FAT2,R
oot DirectoryからなるDファイル管理領
域21とユーザエリア22の各領域が設けられて構成さ
れる(図1参照)。
Here, as shown in FIG. 3, the disk 4 has a physical format of, for example, FAT 16
This is an MB disk, and the size of a cluster (1 logical block: cluster in FAT16) of data handled by the host computer is, for example, 8 sectors. The disk 4 is logically formatted in the FAT mode, and has a Boot Sector, FAT1, FAT2, and RAT.
Each of a D file management area 21 composed of an auto directory and a user area 22 is provided (see FIG. 1).

【0025】(作用)CPU7は、ファームウェアプロ
グラム格納部9に格納されている動作プログラムに従
い、図4に示すように、まず、ステップS1で制御に用
いる各パラーメータ値の初期設定を行い、ステップS2
で装置のイニシャライズを行う(スピンドルモータ3を
回転駆動し、ヘッド11によりディスク4への記録/再
生が可能な状態にする)。
(Operation) In accordance with the operation program stored in the firmware program storage section 9, the CPU 7 first performs initial setting of each parameter value used for control in step S1, as shown in FIG.
To initialize the apparatus (by rotating the spindle motor 3 so that the recording / reproduction to / from the disk 4 can be performed by the head 11).

【0026】そして、ステップS3でキャッシュメモリ
6のセグメントサイズの更新を行う。
Then, in step S3, the segment size of the cache memory 6 is updated.

【0027】その後、ステップS4でセグメントキャッ
シュ24に未書き込みのライトキャッシュデータがある
かどうか確認し、未書き込みのライトキャッシュデータ
があればステップS5でディスク4への書き込み処理
(Write_Cache)を行う。
Thereafter, it is checked in step S4 whether there is any unwritten write cache data in the segment cache 24, and if there is unwritten write cache data, a write process (Write_Cache) to the disk 4 is performed in step S5.

【0028】ステップS4において未書き込みのライト
キャッシュデータがなければ、ステップS6でコマンド
受信があるかどうか(フラグcmd=1かどうか)を確
認し、コマンド受信し実行すべきコマンドがあればステ
ップS7でコマンド実行処理(CMD_Exe)を行っ
た後、ステップS8でコマンドを終了しフラグをクリア
し(cmd=0)、ステップS4に戻り処理を繰り返
す。
If there is no unwritten write cache data in step S4, it is checked in step S6 whether a command has been received (whether or not the flag cmd = 1). If there is a command to be received and executed, in step S7 After performing the command execution process (CMD_Exe), the command is terminated in step S8, the flag is cleared (cmd = 0), and the process returns to step S4 to repeat the process.

【0029】次に、前記ステップS3におけるキャッシ
ュメモリ6のセグメントサイズの更新について説明す
る。図5に示すように、ステップS11でディスク4よ
りBoot Sectorをリードし、ディスク解析部
7aがディスク4のクラスタサイズを確認する。
Next, the updating of the segment size of the cache memory 6 in step S3 will be described. As shown in FIG. 5, a Boot Sector is read from the disk 4 in step S11, and the disk analyzer 7a checks the cluster size of the disk 4.

【0030】そして、ステップS12において、キャッ
シュ設定部7bがステップS11で確認したディスク4
のクラスタサイズをキャッシュメモリ6の1セグメント
サイズとし、この1セグメントサイズでキャッシュメモ
リ6のメモリサイズを割ることで、セグメント個数を算
出する。
Then, in step S12, the cache setting unit 7b checks the disk 4
Is set as one segment size of the cache memory 6, and the number of segments is calculated by dividing the memory size of the cache memory 6 by the one segment size.

【0031】ステップS13では、算出したセグメント
個数が所定の最大数Maxと比較し、セグメント個数が
所定の最大数Maxより大きい場合は、セグメント管理
処理の負担が増大するため、ステップS14で1セグメ
ントサイズをディスク4のクラスタサイズの整数N倍
(例えば2倍)とし、この1セグメントサイズでキャッ
シュメモリ6のメモリサイズを割ることで、セグメント
個数を算出して図4のステップS4に進む。
In step S13, the calculated number of segments is compared with a predetermined maximum number Max. If the number of segments is larger than the predetermined maximum number Max, the load of the segment management process increases. Is set to an integer N times (for example, twice) the cluster size of the disk 4, and the memory size of the cache memory 6 is divided by the one segment size to calculate the number of segments, and the process proceeds to step S4 in FIG.

【0032】また、ステップS13でセグメント個数が
所定の最大数Max以下ならば、ステップS15でセグ
メント個数を所定の最小数Minと比較し、セグメント
個数が所定の最小数Min以上なら図4のステップS4
に進み、セグメント個数が所定の最小数Min未満なら
ば、1セグメントサイズが大きくなりキャッシュメモリ
6を効率的に利用できない恐れがあるため、ステップS
16で1セグメントサイズをディスク4のクラスタサイ
ズを整数Nで割ったサイズとし、この1セグメントサイ
ズでキャッシュメモリ6のメモリサイズを割ることで、
セグメント個数を算出して図4のステップS4に進む。
If the number of segments is equal to or smaller than the predetermined maximum number Max in step S13, the number of segments is compared with the predetermined minimum number Min in step S15. If the number of segments is equal to or larger than the predetermined minimum number Min, step S4 in FIG.
If the number of segments is smaller than the predetermined minimum number Min, the size of one segment may be large and the cache memory 6 may not be used efficiently.
By dividing one cluster size by 16 into a size obtained by dividing the cluster size of the disk 4 by an integer N, and dividing the memory size of the cache memory 6 by this one segment size,
After calculating the number of segments, the process proceeds to step S4 in FIG.

【0033】つまり、本実施の形態では、まず、キャッ
シュメモリのセグメントの大きさは、このクラスタの大
きさと等しくする。キャッシユメモリの大きさのうちセ
グメントキャッシユに割り当てられている容量を、この
セグメントの大きさで割ることによりセグメントの数を
決定する。
That is, in this embodiment, first, the size of the segment of the cache memory is made equal to the size of this cluster. The number of segments is determined by dividing the capacity allocated to the segment cache in the size of the cache memory by the size of the segment.

【0034】このとき、セグメントの数が多くなりすぎ
て、セグメントキャッシュの管理・使用に不都合が発生
する場合(セグメントキャッシュを管理するためのメモ
リ不足や、セグメントの管理・検索に時間がかかりすぎ
るようになる場合)は、セグメントの数を任意の値に制
限する。この場合、セグメントの大きさをクラスタの大
きさの整数倍にすることで、セグメントの数が任意の値
以下になるように調整する。
At this time, if the number of segments becomes too large, which causes inconvenience in the management and use of the segment cache (for example, a shortage of memory for managing the segment cache and an excessively long time for management and search of the segment). ), The number of segments is limited to an arbitrary value. In this case, by adjusting the size of the segment to an integral multiple of the size of the cluster, the number of segments is adjusted to be equal to or less than an arbitrary value.

【0035】また、クラスタの大きさが大きすぎセグメ
ントの数が十分な数を確保できない場合(ランダムW/
Rが遅くなる可能性がある)や、実際に読み書きされる
データの大きさがクラスタの大きさよりも小さいときが
多い場合(キャッシュ(セグメント)メモリの使用効率
が下がる場合(データはクラスタの先頭からデータの大
きさ分だけ使用される))は、セグメントの大きさをク
ラスタの大きさのl/整数に設定する。なお、この時セ
グメントの数を整数倍にしても、または任意の値に増や
しても良い。
When the size of the cluster is too large and the number of segments is not sufficient (random W /
R may be slower), or the size of data that is actually read or written is often smaller than the size of the cluster (the use efficiency of the cache (segment) memory is reduced (data starts from the beginning of the cluster). Is used for the size of the data)) sets the segment size to 1 / integer of the cluster size. At this time, the number of segments may be multiplied by an integer or may be increased to an arbitrary value.

【0036】これによりセグメントの大きさ、または数
を、ディスクの論理フォーマットに最適化することがで
きる。また最適化されることにより、セグメントの使用
効率が上がり、データの読み書きを高速化することがで
きる。
Thus, the size or number of segments can be optimized for the logical format of the disk. In addition, by the optimization, the use efficiency of the segment increases, and the speed of reading and writing data can be increased.

【0037】なお、ファイル管理領域のBoot Se
ctor、FAT1、FAT2、Root Direc
toryは、各々の大きさに一致、または各々の大きさ
の1/整数の大きさのセグメントとして別に管理・使用
し、ユーザエリアは、セグメントキャッシュ容量からフ
ァイル管理領域に必要なセグメント容量を引いた残りの
容量を、本実施の形態に従った方法に決定したセグメン
トの大きさと数で管理・使用するようにしても良い。こ
れにより、ディスク全体に渡ってより最適化したセグメ
ントの大きさと数とすることができる。
The file management area Boot Se
ctor, FAT1, FAT2, Root Direct
Tory is separately managed and used as a segment that matches each size or is 1 / integer size of each size, and the user area is obtained by subtracting the segment capacity required for the file management area from the segment cache capacity. The remaining capacity may be managed and used based on the size and number of segments determined by the method according to the present embodiment. As a result, the size and number of segments can be optimized over the entire disk.

【0038】なお、実際に読み書きされるデータの大き
さがクラスタの大きさよりも大きいときが多い場合(セ
グメントの管理に無駄・オーバヘッドが生じる)は、セ
グメントの大きさをクラスタの大きさの整数倍に設定し
ても良い。この時セグメントの数は減ることになる。
If the size of the data actually read or written is often larger than the size of the cluster (whether the segment management is wasteful or overhead), the size of the segment is made an integral multiple of the size of the cluster. May be set. At this time, the number of segments is reduced.

【0039】(効果)図6(b)に示すように、従来は
例えばトラックを基準にセグメントサイズを決定する場
合、例えば キャッシュメモリサイズ=256KB=512セクタ 1トラック=25論理ブロック=12.5KB セグメント数=256KB/12.5KB=20 1データ(ファイルサイズ)=5論理ブロック=2.5
KB とすると、ランダムリード/ライト時に使用するキャッ
シュメモリ6の有効分は、 2.5KB×20=50KB となり、 256KB−50KB=206KB が無駄領域となる。
(Effect) As shown in FIG. 6B, conventionally, for example, when the segment size is determined on the basis of a track, for example, cache memory size = 256 KB = 512 sectors 1 track = 25 logical blocks = 12.5 KB segments Number = 256 KB / 12.5 KB = 201 1 data (file size) = 5 logical blocks = 2.5
If KB, the effective part of the cache memory 6 used at the time of random read / write is 2.5 KB × 20 = 50 KB, and 256 KB−50 KB = 206 KB is a waste area.

【0040】本実施の形態では、同じ条件でかつ、 1セグメントサイズ=8論理ブロック=4KB セグメント数=256KB/4KB=64 とすると、 2.5KB×64=160KB となり、 256KB−160KB=96KB が無駄領域となる。In this embodiment, under the same conditions and 1 segment size = 8 logical blocks = 4 KB, the number of segments = 256 KB / 4 KB = 64, 2.5 KB × 64 = 160 KB, and 256 KB−160 KB = 96 KB is wasteful. Area.

【0041】本実施の形態のようにディスク4の論理フ
ォーマット(クラスタサイズ)によりキャッシュメモリ
6の1セグメントサイズを設定することで、上記の算出
例では 206KB−96KB=110KB の領域をより有効に使用することができる。
By setting one segment size of the cache memory 6 according to the logical format (cluster size) of the disk 4 as in the present embodiment, in the above calculation example, the area of 206 KB-96 KB = 110 KB is used more effectively. can do.

【0042】また、データサイズが大きい場合でも、本
実施の形態のように1セグメントサイズをクラスタサイ
ズに基づいて決定しているので、上記の場合、最大でも
セグメント単位での無駄領域は7論理ブロックに留まる
が、従来の方法(例えばトラックに基づいて1セグメン
トサイズを決定する場合)では最大24論理ブロックの
無駄領域が発生する恐れがある。従って、本実施の形態
では、より有効にキャッシュメモリを使用することがで
きる。
Even when the data size is large, the size of one segment is determined based on the cluster size as in the present embodiment. However, in the conventional method (for example, when one segment size is determined based on the track), there is a possibility that a waste area of a maximum of 24 logical blocks is generated. Therefore, in this embodiment, the cache memory can be used more effectively.

【0043】さらに、近年、ディスクの高容量化に伴
い、ホストコンピュータが扱うデータの1論理ブロック
(クラスタ)のサイズも変化するが、本実施の形態で
は、1セグメントサイズをクラスタサイズに基づいて決
定しているので、容量の異なるディスクに対してもキャ
ッシュメモリの使用効率を上げることができる。
Further, in recent years, the size of one logical block (cluster) of data handled by the host computer changes as the capacity of the disk increases, but in the present embodiment, one segment size is determined based on the cluster size. Therefore, the use efficiency of the cache memory can be improved even for disks having different capacities.

【0044】なお、図7(a)に示すように、ディスク
4においては、ファイル管理領域やユーザエリアを含め
たホストコンピュータが読み書きすることができる最初
のセクタをLBA=0とすると、ホストコンピュータが
読み書きできない領域やセグメントが作成されないクラ
スタの大きさ未満の余り領域が発生する。また、セグメ
ント論理ブロックアドレス(セグメントLBA:セグメ
ントの最初のLBA)は、0及びセグメントの大きさ
(=1セグメントあたりのセクタ数)の整数倍となって
いる。
As shown in FIG. 7A, in the disk 4, if the first sector including the file management area and the user area which can be read and written by the host computer is LBA = 0, the host computer An unreadable / writable area or a surplus area smaller than the size of a cluster in which no segment is created occurs. The segment logical block address (segment LBA: first LBA of the segment) is 0 and an integral multiple of the segment size (= the number of sectors per segment).

【0045】このため、例えば図7(b)のように、
(セグメントの大きさ)=(クラスタの大きさ)とした
場合で、6セクタの小容量ファイル(クラスタ=8セク
タの大きさ未満のデータ)のランダム書き込み(書き込
みはクラスタの先頭から6ブロック)を行った場合、キ
ャッシュメモリ6においては1ファイル=2セグメント
となる可能性があり、キャッシュメモリ6が無駄に使わ
れる恐れがある。
For this reason, for example, as shown in FIG.
When (segment size) = (cluster size), random writing (clustering is performed for 6 blocks from the beginning of the cluster) of a small capacity file of 6 sectors (cluster = data smaller than 8 sectors) is performed. If so, there is a possibility that 1 file = 2 segments in the cache memory 6, and the cache memory 6 may be used wastefully.

【0046】そこで、第1の実施の形態の変形例とし
て、図8に示すような処理、ユーザエリア22の先頭L
BA(最初のクラスタのLBA)に合わせて、セグメン
トLBAの設定の仕方を決める処理によりセグメントサ
イズを設定する例を説明する。すなわち、この変形例で
はセグメントLBAは(ユーザエリアの先頭LBA)±
(セグメントの大きさ)で設置されるようになる。
Therefore, as a modification of the first embodiment, the processing shown in FIG.
An example will be described in which a segment size is set by a process of determining how to set a segment LBA according to a BA (LBA of the first cluster). That is, in this modification, the segment LBA is (the head LBA of the user area) ±
(Segment size).

【0047】図8に示すように、第1の実施の形態の変
形例でも、図5のステップS11〜S16までと同じよ
うな処理を行う。なお、この変形例においてはステップ
S11では、ディスク4よりBoot Sectorを
リードし、ディスク解析部7aがディスク4のクラスタ
サイズを確認すると共に、ユーザエリア22の先頭LB
Aの確認を行う。またステップS12では、キャッシュ
設定部7bがステップS11で確認したディスク4のク
ラスタサイズをキャッシュメモリ6のセグメントの1セ
グメントサイズとし、この1セグメントサイズでキャッ
シュメモリ6のメモリサイズを割ることで、セグメント
個数を算出すると共に、ユーザエリアの先頭LBAを基
準LBAに設定する。
As shown in FIG. 8, the same processing as steps S11 to S16 in FIG. 5 is performed in the modification of the first embodiment. In this modification, in step S11, a Boot Sector is read from the disk 4, the disk analysis unit 7a checks the cluster size of the disk 4, and checks the start LB of the user area 22.
Check A. In step S12, the cache setting unit 7b sets the cluster size of the disk 4 confirmed in step S11 as one segment size of the segment of the cache memory 6, and divides the memory size of the cache memory 6 by the one segment size to obtain the number of segments. Is calculated, and the first LBA of the user area is set as the reference LBA.

【0048】第1の実施の形態の変形例では、図4のス
テップS3以降にホストコンピュータからのW/Rコマ
ンドを受信すると、図9に示すように、W/Rコマンド
の要求LBAを確認し、ステップS21でこの要求LB
Aと基準LBAとを比較し要求LBAが基準LBA以上
ならば、ステップS22でセグメントLBAを セグメントLBA=基準LBA+{(要求LBA−基準
LBA)/1セグメントサイズ}×1セグメントサイズ とし、図4のステップS4に進む(ただし、上式の下線
部は小数点以下切り捨て)。
In the modification of the first embodiment, when a W / R command is received from the host computer after step S3 in FIG. 4, the request LBA of the W / R command is confirmed as shown in FIG. In step S21, the request LB
A is compared with the reference LBA, and if the required LBA is equal to or greater than the reference LBA, the segment LBA is determined in step S22 as: segment LBA = reference LBA + { (request LBA− reference
LBA) / one segment size } × one segment size, and the process proceeds to step S4 in FIG. 4 (however, the underlined portion of the above expression is truncated to the decimal point).

【0049】また、ステップS21で要求LBAが基準
LBA未満ならば、ステップS23でセグメントLBA
を セグメントLBA=基準LBA−{(基準LBA−要求
LBA)/1セグメントサイズ}×1セグメントサイズ とし、図4のステップS4に進む(ただし、上式の下線
部は小数点以下切り上げ)。
If the required LBA is smaller than the reference LBA in step S21, the segment LBA is determined in step S23.
Segment LBA = reference LBA- { (reference LBA- request
(LBA) / 1 segment size } × 1 segment size, and the process proceeds to step S4 in FIG. 4 (however, the underlined portion of the above expression is rounded up to the decimal point).

【0050】図9のような処理を行うことで、図10
(図10(a)はディスクを示し、図10(b)はキャ
ッシュメモリを示す)に示すように、例えば6セクタの
小容量ファイル(クラスタ=8セクタの大きさ未満のデ
ータ)のランダム書き込み(書き込みはクラスタの先頭
から6ブロック)を行った場合、キャッシュメモリ6で
はlファイル=1セグメントとなり、図7と比べ2倍の
ファイルをキャッシュに保存することができ、書き込み
をより高速にすることができる。つまり、クラスタとセ
グメントLBAの関係を一致させることで最適化して、
セグメントの使用効率を上げ、データの読み書きを高速
化に行うことができる。
By performing the processing shown in FIG. 9, the processing shown in FIG.
As shown in FIG. 10 (a) showing a disk and FIG. 10 (b) showing a cache memory, for example, random writing of a small capacity file of 6 sectors (cluster = data smaller than 8 sectors) ( When writing is performed for 6 blocks from the beginning of the cluster), 1 file = 1 segment in the cache memory 6, and twice as many files as in FIG. 7 can be stored in the cache, so that writing can be performed at higher speed. it can. In other words, optimization is performed by matching the relationship between the cluster and the segment LBA,
It is possible to increase the use efficiency of the segment and read / write data at high speed.

【0051】なお、この変形例では、LBA=0を含む
セグメントでは、セグメントの先頭部分は未使用(=ホ
ストコンピュータが読み書きできない)領域となる場合
がある。
In this modification, in the segment including LBA = 0, the head of the segment may be an unused area (= cannot be read / written by the host computer).

【0052】また、キャッシュメモリ6にCファイル管
理領域23を設け(図1参照)、このキャッシュメモリ
6のCファイル管理領域23にBoot Secto
r、FAT1、FAT2、Root Director
yを設け、FAT管理を行う場合、図11に示すよう
に、Boot SectorはBoot Sector
サイズ分でセグメントを1つ確保し、FAT1/FAT
2はFAT1/FAT2サイズ分でセグメントを1つ確
保し(FAT1/FAT2は同じデータがライトされる
ため同じセグメントを使用)、Root Direct
oryはRootDirectoryサイズ分でセグメ
ントを1つ確保し、残りセグメントキャッシュ24では
クラスタサイズでセグメントを確保するようにしても良
い。こうすることで、FAT管理が容易で、ディスク4
の論理フォーマットとキャッシュメモリ6の関係を最適
化することができる。
Further, a C file management area 23 is provided in the cache memory 6 (see FIG. 1), and a Boot Secto is stored in the C file management area 23 of the cache memory 6.
r, FAT1, FAT2, Root Director
y and FAT management is performed, as shown in FIG. 11, Boot Sector is set to Boot Sector.
One segment is secured for the size, and FAT1 / FAT
No. 2 secures one segment for FAT1 / FAT2 size (FAT1 / FAT2 uses the same segment because the same data is written), and Root Direct
The ory may secure one segment for the size of the Root Directory, and the remaining segment cache 24 may secure a segment for the cluster size. By doing so, the FAT management is easy and the disk 4
The relationship between the logical format and the cache memory 6 can be optimized.

【0053】図12は本発明の第2の実施の形態に係る
セグメントサイズの更新処理の詳細な流れを示すフロー
チャートである。
FIG. 12 is a flowchart showing a detailed flow of the segment size updating process according to the second embodiment of the present invention.

【0054】第2の実施の形態は、第1の実施の形態と
ほとんど同じであるので、異なる点のみ説明し、同一の
構成には同じ符号をつけ説明は省略する。
Since the second embodiment is almost the same as the first embodiment, only different points will be described, and the same components will be denoted by the same reference numerals and description thereof will be omitted.

【0055】本実施の形態は、ホストコンピュータが読
み書きするファイルのデータの大きさを監視して、その
データの大きさの傾向により、随時セグメントの大きさ
と数を変更するようにした実施の形態である。
This embodiment is an embodiment in which the size of the data of the file read and written by the host computer is monitored, and the size and number of the segments are changed at any time according to the tendency of the data size. is there.

【0056】本実施の形態では、図4のステップS4〜
S8と並行して実行され、W/R時の書き込みファイル
のサイズの傾向をチェックし、セグメントの構造設定を
動的に変更する。すなわち、図12に示すように、ステ
ップS31で継続してリード/ライト命令(W/Rコマ
ンド)のファイルのデータの大きさを監視する。
In the present embodiment, steps S4 to S4 in FIG.
It is executed in parallel with S8, checks the size tendency of the write file at the time of W / R, and dynamically changes the structure setting of the segment. That is, as shown in FIG. 12, the size of the data of the file of the read / write command (W / R command) is continuously monitored in step S31.

【0057】そして、ステップS32でファイルのデー
タの大きさがクラスタサイズの1/2以下に偏っている
かどうか判断し、ファイルのデータの大きさがクラスタ
サイズの1/2以下に偏っている場合は、ステップS3
3でセグメントの大きさを1クラスタサイズ時の1/2
としセグメントの数を1クラスタサイズ時の2倍に設定
し図4のステップS4からS6の割り込みを受け付けた
ところに戻り、そうでない場合はステップS34に進
む。
Then, in step S32, it is determined whether or not the size of the data of the file is less than 1/2 of the cluster size. If the size of the data of the file is less than 1/2 of the cluster size, , Step S3
3 = 1/2 the size of one cluster size
The number of segments is set to twice the size of one cluster size, and the process returns to the point where the interrupt from step S4 to step S6 in FIG. 4 is accepted. If not, the process proceeds to step S34.

【0058】ステップS34では、ファイルのデータの
大きさがクラスタサイズの2倍か4倍程度に偏っている
かどうか判断し、ファイルのデータの大きさがクラスタ
サイズの2倍か4倍程度に偏っている場合は、ステップ
S35でセグメントの大きさを1クラスタサイズ時の2
倍としセグメントの数を1クラスタサイズ時のl/2に
設定し図4のステップS4からS6の割り込みを受け付
けたところに戻り、そうでない場合はステップS36に
進む。
In step S34, it is determined whether the size of the file data is biased to about twice or four times the cluster size, and the size of the file data is biased to about twice or four times the cluster size. If there is, the size of the segment is set to 2
4 and the number of segments is set to l / 2 of the size of one cluster, and the process returns to the point where the interrupt from step S4 to step S6 in FIG. 4 is accepted. Otherwise, the process proceeds to step S36.

【0059】ステップS36では、ファイルのデータの
大きさがクラスタサイズの1倍か3倍程度に偏っている
かどうか判断し、ファイルのデータの大きさがクラスタ
サイズの1倍か3倍程度に偏っている場合は、ステップ
S37でセグメントの大きさと個数を1クラスタサイズ
時の値に戻し図4のステップS4からS6の割り込みを
受け付けたところに戻り、そうでない場合はデータサイ
ズ(ファイルサイズ)がランダムであるのでセグメント
の大きさと個数は現状値を保持して図4のステップS4
からS6の割り込みを受け付けたところに戻る。
In step S36, it is determined whether the size of the file data is biased to about one or three times the cluster size, and the size of the file data is biased to about one or three times the cluster size. If so, the size and number of the segments are returned to the values at the time of one cluster size in step S37, and the process returns to the place where the interruption from step S4 to S6 in FIG. 4 is accepted. Otherwise, the data size (file size) is random. Therefore, the size and the number of the segments are kept at the current values, and the values are stored in step S4 in FIG.
Then, the process returns to the point where the interrupt of S6 is accepted.

【0060】これにより、ホストコンピュータの読み書
きの傾向に最適化したセグメントの大きさと個数に常時
設定することができる。
Thus, it is possible to always set the size and the number of segments that are optimized for the read / write tendency of the host computer.

【0061】なお、本実施の形態では、セグメントの大
きさと数を1/2倍、1倍、2倍のいづれかに設定した
が、1/4倍、4倍などに設定しても良く、判断条件は
本実施の形態以外の方法をとってもよい。
In this embodiment, the size and number of the segments are set to 1/2 times, 1 times, or 2 times, but may be set to 1/4 times, 4 times, or the like. The condition may be a method other than this embodiment.

【0062】本発明の各実施の形態は、FAT32、N
TFS、HFS等の他のフォーマットに関しても同様に
適用することができる。また、ディスクの論理フォーマ
ットの確認はホストコンピユータ側で行い、ホストコン
ピュータがディスクキャッシュ装置に論理フォーマット
を指示することにより行っても良い。
Each embodiment of the present invention uses FAT32, N
The same applies to other formats such as TFS and HFS. The confirmation of the logical format of the disk may be performed on the host computer side, and the host computer may instruct the disk cache device to instruct the logical format.

【0063】[0063]

【発明の効果】以上説明したように本発明のセグメント
キャッシュ方式の情報記録再生装置によれば、解析手段
が記録媒体の論理フォーマットを解析し、設定手段が解
析手段の解析結果に基づきキャッシュメモリの各セグメ
ントの構造を設定するので、セグメントキャッシュ方式
のキャッシュメモリを用いる場合に、実際にホストコン
ピュータがディスクに読み書きを行う際の論理的な特徴
を反映させた最適なセグメントサイズのセグメントにキ
ャッシュ領域を設定してキャッシュメモリの使用効率を
上げ、リード時及びライト時の処理速度を向上させるこ
とができるという効果がある。
As described above, according to the information recording / reproducing apparatus of the segment cache system of the present invention, the analyzing means analyzes the logical format of the recording medium, and the setting means analyzes the logical format of the cache memory based on the analysis result of the analyzing means. Because the structure of each segment is set, when using a cache memory of the segment cache system, the cache area is allocated to a segment of the optimal segment size that reflects the logical characteristics when the host computer actually reads and writes to the disk. This setting has the effect of increasing the use efficiency of the cache memory and improving the processing speed during reading and writing.

【0064】以上説明したように本発明のセグメントキ
ャッシュ方式の情報記録再生方法によれば、解析工程が
記録媒体の論理フォーマットを解析し、設定工程が解析
工程の解析結果に基づきキャッシュメモリの各セグメン
トの構造を設定するので、セグメントキャッシュ方式の
キャッシュメモリを用いる場合に、実際にホストコンピ
ュータがディスクに読み書きを行う際の論理的な特徴を
反映させた最適なセグメントサイズのセグメントにキャ
ッシュ領域を設定してキャッシュメモリの使用効率を上
げ、リード時及びライト時の処理速度を向上させること
ができるという効果がある。
As described above, according to the information recording / reproducing method of the segment cache system of the present invention, the analyzing step analyzes the logical format of the recording medium, and the setting step performs each segment of the cache memory based on the analysis result of the analyzing step. When using a cache memory of the segment cache method, the cache area is set to a segment having an optimal segment size that reflects the logical characteristics when the host computer actually reads from and writes to the disk. Thus, the use efficiency of the cache memory can be improved, and the processing speed at the time of reading and writing can be improved.

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

【図1】本発明の第1の実施の形態に係る情報記録再生
装置の構成を示す構成図
FIG. 1 is a configuration diagram showing a configuration of an information recording / reproducing device according to a first embodiment of the present invention.

【図2】図1のCPUの機能ブロックを示す機能ブロッ
ク図
FIG. 2 is a functional block diagram showing functional blocks of a CPU in FIG. 1;

【図3】図1のディスクの論理フォーマットを示す図FIG. 3 is a diagram showing a logical format of the disk shown in FIG. 1;

【図4】図1のCPUのメイン処理の流れを示すフロー
チャート
FIG. 4 is a flowchart showing a flow of a main process of a CPU in FIG. 1;

【図5】図4のセグメントサイズの更新処理の詳細な流
れを示すフローチャート
FIG. 5 is a flowchart showing a detailed flow of a segment size update process in FIG. 4;

【図6】図1の情報記録再生装置の作用を説明する第1
の説明図
FIG. 6 is a first diagram illustrating the operation of the information recording / reproducing apparatus of FIG. 1;
Illustration of

【図7】図1の情報記録再生装置の作用を説明する第2
の説明図
FIG. 7 is a second diagram illustrating the operation of the information recording / reproducing apparatus of FIG. 1;
Illustration of

【図8】図4のセグメントサイズの更新処理の変形例の
詳細な流れを示す第1のフローチャート
FIG. 8 is a first flowchart showing a detailed flow of a modification of the segment size updating process of FIG. 4;

【図9】図4のセグメントサイズの更新処理の変形例の
詳細な流れを示す第2のフローチャート
FIG. 9 is a second flowchart showing a detailed flow of a modification of the segment size updating process of FIG. 4;

【図10】図8及び図9のセグメントサイズの更新処理
の変形例による情報記録再生装置の作用を説明する説明
FIG. 10 is an explanatory diagram illustrating the operation of an information recording / reproducing apparatus according to a modification of the segment size updating process of FIGS. 8 and 9;

【図11】図1のキャッシュメモリの構成の変形例を示
す図
FIG. 11 is a diagram showing a modification of the configuration of the cache memory of FIG. 1;

【図12】本発明の第2の実施の形態に係るセグメント
サイズの更新処理の詳細な流れを示すフローチャート
FIG. 12 is a flowchart showing a detailed flow of a segment size update process according to the second embodiment of the present invention;

【符号の説明】[Explanation of symbols]

1…情報記録再生装置 2…SCSI制御部 3…スピンドルモータ 4…ディスク 5…ディスク制御部 6…キャッシュメモリ 7…CPU 7a…ディスク解析部 7b…キャッシュ設定部 9…ファームウェアプログラム格納部 10…記録再生ヘッド 11…リード/ライト制御部 21…Dファイル管理領域 22…ユーザエリア 24…セグメントキャッシュ DESCRIPTION OF SYMBOLS 1 ... Information recording / reproducing apparatus 2 ... SCSI control part 3 ... Spindle motor 4 ... Disk 5 ... Disk control part 6 ... Cache memory 7 ... CPU 7a ... Disk analysis part 7b ... Cache setting part 9 ... Firmware program storage part 10 ... Recording / reproduction Head 11: Read / write control unit 21: D file management area 22: User area 24: Segment cache

Claims (8)

【特許請求の範囲】[Claims] 【請求項1】 記憶領域が複数のセグメントに分割さ
れ、各セグメントに上位のホストコンピュータと記録媒
体との間で転送されるデータを一時格納するセグメント
キャッシュ方式のキャッシュメモリと、 前記キャッシュメモリに対するデータの読み書き制御、
前記キャッシュメモリに格納されたデータの管理及び検
索を行うキャッシュメモリ管理手段とを備え、前記記録
媒体に対して情報の記録再生を行うセグメントキャッシ
ュ方式の情報記録再生装置において、 前記キャッシュメモリ管理手段は、 前記記録媒体の論理フォーマットを解析する解析手段
と、 前記解析手段の解析結果に基づき前記キャッシュメモリ
の各セグメントの構造を設定する設定手段とを備えたこ
とを特徴とするセグメントキャッシュ方式の情報記録再
生装置。
1. A segment cache type cache memory for dividing a storage area into a plurality of segments, and temporarily storing data transferred between a host computer and a recording medium in each segment, and data for the cache memory. Read and write control,
A cache memory management unit that manages and searches data stored in the cache memory; and a segment cache type information recording / reproducing apparatus that records / reproduces information on / from the recording medium. An information storage device for analyzing the logical format of the recording medium; and a setting device for setting a structure of each segment of the cache memory based on an analysis result of the analysis device. Playback device.
【請求項2】 前記設定手段は、前記解析手段の解析結
果に基づき前記キャッシュメモリの各セグメントのサイ
ズを設定することを特徴とする請求項1に記載のセグメ
ントキャッシュ方式の情報記録再生装置。
2. The information recording / reproducing apparatus according to claim 1, wherein the setting unit sets the size of each segment of the cache memory based on an analysis result of the analysis unit.
【請求項3】 前記設定手段は、前記解析手段の解析結
果に基づき前記キャッシュメモリの各セグメントと論理
ブロックアドレスの関係を設定することを特徴とする請
求項1に記載のセグメントキャッシュ方式の情報記録再
生装置。
3. The information recording of the segment cache system according to claim 1, wherein said setting means sets a relationship between each segment of said cache memory and a logical block address based on an analysis result of said analyzing means. Playback device.
【請求項4】 前記設定手段は、前記記録媒体に読み書
きされるデータの大きさを監視し、読み書きされる前記
データの大きさの傾向から前記キャッシュメモリの各セ
グメントのサイズ、または前記キャッシュメモリの各セ
グメントのサイズと個数を設定することを特徴とする請
求項1に記載のセグメントキャッシュ方式の情報記録再
生装置。
4. The setting unit monitors the size of data read / written to / from the recording medium, and determines the size of each segment of the cache memory or the size of the cache memory based on the tendency of the size of the data read / written. 2. The information recording / reproducing apparatus according to claim 1, wherein the size and the number of each segment are set.
【請求項5】 記憶領域が複数のセグメントに分割さ
れ、各セグメントに上位のホストコンピュータと記録媒
体との間で転送されるデータを一時格納するセグメント
キャッシュ方式のキャッシュメモリに対するデータの読
み書き制御、前記キャッシュメモリに格納されたデータ
の管理及び検索を行い、前記記録媒体に対して情報の記
録再生を行う情報記録再生方法において、 前記記録媒体の論理フォーマットを解析する解析工程
と、 前記解析手段の解析結果に基づき前記キャッシュメモリ
の各セグメントの構造を設定する設定工程とを備えたこ
とを特徴とするセグメントキャッシュ方式の情報記録再
生方法。
5. A read / write control of data to / from a segment cache type cache memory in which a storage area is divided into a plurality of segments and each segment temporarily stores data transferred between a host computer and a recording medium. An information recording / reproducing method for managing and retrieving data stored in a cache memory and recording / reproducing information on / from the recording medium, comprising: an analyzing step of analyzing a logical format of the recording medium; A setting step of setting the structure of each segment of the cache memory based on the result.
【請求項6】 前記設定工程は、前記解析工程の解析結
果に基づき前記キャッシュメモリの各セグメントのサイ
ズを設定することを特徴とする請求項5に記載のセグメ
ントキャッシュ方式の情報記録再生方法。
6. The information recording / reproducing method according to claim 5, wherein the setting step sets a size of each segment of the cache memory based on an analysis result of the analysis step.
【請求項7】 前記設定工程は、前記解析工程の解析結
果に基づき前記キャッシュメモリの各セグメントと論理
ブロックアドレスの関係を設定することを特徴とする請
求項5に記載のセグメントキャッシュ方式の情報記録再
生方法。
7. The information recording according to claim 5, wherein the setting step sets a relationship between each segment of the cache memory and a logical block address based on an analysis result of the analysis step. Playback method.
【請求項8】 前記設定工程は、前記記録媒体に読み書
きされるデータの大きさを監視し、読み書きされる前記
データの大きさの傾向から前記キャッシュメモリの各セ
グメントのサイズ、または前記キャッシュメモリの各セ
グメントのサイズと個数を設定することを特徴とする請
求項5に記載のセグメントキャッシュ方式の情報記録再
生方法。
8. The setting step monitors a size of data read / written to / from the recording medium, and determines a size of each segment of the cache memory or a size of the cache memory based on a tendency of the size of the data read / written. 6. The information recording / reproducing method according to claim 5, wherein the size and the number of each segment are set.
JP11123098A 1998-12-03 1999-04-28 Device and method for recording and reproducing information for segment cache system Withdrawn JP2000227865A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP11123098A JP2000227865A (en) 1998-12-03 1999-04-28 Device and method for recording and reproducing information for segment cache system

Applications Claiming Priority (3)

Application Number Priority Date Filing Date Title
JP34466398 1998-12-03
JP10-344663 1998-12-03
JP11123098A JP2000227865A (en) 1998-12-03 1999-04-28 Device and method for recording and reproducing information for segment cache system

Publications (1)

Publication Number Publication Date
JP2000227865A true JP2000227865A (en) 2000-08-15

Family

ID=26460099

Family Applications (1)

Application Number Title Priority Date Filing Date
JP11123098A Withdrawn JP2000227865A (en) 1998-12-03 1999-04-28 Device and method for recording and reproducing information for segment cache system

Country Status (1)

Country Link
JP (1) JP2000227865A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7421536B2 (en) 2004-08-24 2008-09-02 Fujitsu Limited Access control method, disk control unit and storage apparatus
US7930480B2 (en) * 2004-03-22 2011-04-19 Hitachi Global Storage Technologies Netherlands B.V. Data storage device, control method thereof, and magnetic disk storage device
JP2011141657A (en) * 2010-01-06 2011-07-21 Yokogawa Electric Corp Data processor

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7930480B2 (en) * 2004-03-22 2011-04-19 Hitachi Global Storage Technologies Netherlands B.V. Data storage device, control method thereof, and magnetic disk storage device
US7421536B2 (en) 2004-08-24 2008-09-02 Fujitsu Limited Access control method, disk control unit and storage apparatus
JP2011141657A (en) * 2010-01-06 2011-07-21 Yokogawa Electric Corp Data processor

Similar Documents

Publication Publication Date Title
JP3898782B2 (en) Information recording / reproducing device
US6092154A (en) Method of pre-caching or pre-fetching data utilizing thread lists and multimedia editing systems using such pre-caching
US5584012A (en) Cache control method and rotary storage device having cache control
US5987479A (en) Large block allocation for disk-based file systems
JP4736593B2 (en) Data storage device, data recording method, recording and / or reproducing system, and electronic device
US20010047451A1 (en) Method and apparatus for disc drive defragmentation
US7529971B2 (en) Composite memory device, data wiring method and program
WO2005015406A1 (en) Semiconductor memory card, and accessing device and method
JP4160139B2 (en) Information recording / reproducing device
JPH08263335A (en) Data storage
JP4106702B2 (en) Information processing apparatus, data recording / reproducing method, program for data recording / reproducing method, and recording medium recording program for data recording / reproducing method
JPH04259048A (en) Pre-read data control system using statistic information
JPH11161527A (en) Data storage system
JP2000227865A (en) Device and method for recording and reproducing information for segment cache system
JP4496790B2 (en) Data storage device and method, and recording / reproducing system
KR20030061948A (en) : Apparatus storing information and method for controlling the File using its
JP2665180B2 (en) Disk cache buffer allocation method
JP3539802B2 (en) Information storage device
JP2000227866A (en) Information recording and reproducing device
JPH10240450A (en) Storage device system
JP3028706B2 (en) Disk controller
JPH11328029A (en) Information recording and reproducing device
JP3089683B2 (en) Information processing device
JPH08278906A (en) Device and method for file management of storage medium
JP2000339202A (en) Disk controller, control method therefor and disk storage medium

Legal Events

Date Code Title Description
A300 Application deemed to be withdrawn because no request for examination was validly filed

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20060704