JPH0784845A - Memory effective utilizing device - Google Patents

Memory effective utilizing device

Info

Publication number
JPH0784845A
JPH0784845A JP5231577A JP23157793A JPH0784845A JP H0784845 A JPH0784845 A JP H0784845A JP 5231577 A JP5231577 A JP 5231577A JP 23157793 A JP23157793 A JP 23157793A JP H0784845 A JPH0784845 A JP H0784845A
Authority
JP
Japan
Prior art keywords
file
main memory
memory
cpu
area
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
JP5231577A
Other languages
Japanese (ja)
Inventor
Yukito Sasaki
幸人 佐々木
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.)
Toshiba Corp
Original Assignee
Toshiba Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Toshiba Corp filed Critical Toshiba Corp
Priority to JP5231577A priority Critical patent/JPH0784845A/en
Publication of JPH0784845A publication Critical patent/JPH0784845A/en
Pending legal-status Critical Current

Links

Abstract

PURPOSE:To decrease the frequency of transfer and to improve the processing speed of the whole applied equipment. CONSTITUTION:The memory effective utilizing device is equipped with an effective using process part 13 having a virtual execution means 21 which virtually executes a program of a CPU unless a file requested by the CPU to be transferred is present in the main memory of a device that transfers the necessary file from an auxiliary memory 12 to the main memory 11 unless the file required by the CPU is present in the main memory, a next transfer file name extracting means 22 which extracts the file name of the transfer request when a next file transfer request is made by this virtual execution means, and an area nonusableness determining means 23 which judges whether or not the extracted file name is present in the main memory and disables the use of the file occupation area of the file name when the file name is present in the main memory.

Description

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

【0001】[0001]

【産業上の利用分野】本発明は、主メモリおよび補助メ
モリを有効に利用するメモリ有効利用装置に係わり、特
に補助メモリから主メモリへのファイル転送技術を改良
したメモリ有効利用装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a memory effective utilization apparatus for effectively utilizing a main memory and an auxiliary memory, and more particularly to a memory effective utilization apparatus having an improved file transfer technique from the auxiliary memory to the main memory.

【0002】[0002]

【従来の技術】電子計算機においては、図7に示すよう
にCPU1と、CPU1から直接アクセスできる主メモ
リ2と、多量のプログラムおよびデータファイルを記憶
保持し、ファイルの転送要求があったときに必要なファ
イルを主メモリ2に転送する補助メモリ3とで構成さ
れ、これらCPU1,主メモリ2および補助メモリ3は
オペレーティングシステム(OS)4によって統括管理
されている。
2. Description of the Related Art In an electronic computer, as shown in FIG. 7, a CPU 1, a main memory 2 that can be directly accessed by the CPU 1, a large amount of programs and data files are stored and held, and they are necessary when a file transfer request is made. The auxiliary memory 3 transfers files to the main memory 2. The CPU 1, the main memory 2 and the auxiliary memory 3 are centrally managed by an operating system (OS) 4.

【0003】さらに、具体的に述べると、CPU1は動
作上必要なプログラムおよびデータファイルについて主
メモリ2にアクセス(リード/ライト)するが、必要と
するファイルが必要とする時点で主メモリ2に存在しな
いとか、また常に必要とするファイルが補助メモリ3に
存在する場合がある。
More specifically, the CPU 1 accesses (reads / writes) the main memory 2 for the programs and data files necessary for operation, but the necessary files exist in the main memory 2 when needed. There is a case where the auxiliary memory 3 has a file that is not required or is always needed.

【0004】そこで、この種の電子計算機のオペレーテ
ィングシステム4では、CPU1で必要とするファイル
が主メモリ2に存在するか否かの存在チェック、該当フ
ァイルが補助メモリ3に存在することによる補助メモリ
3への転送指令、補助メモリ3から主メモリ2に転送さ
れたか否かの転送完了確認等について、ソフトウエアま
たはファームウェア的に判断実施し、その判断結果を必
要な構成要素に通知する。CPU1は、転送完了確認の
通知を受けたとき、主メモリ2のファイルに対してアク
セスを開始する。
Therefore, in the operating system 4 of this kind of electronic computer, it is checked whether or not the file required by the CPU 1 exists in the main memory 2, and the auxiliary memory 3 based on the existence of the file in the auxiliary memory 3. A transfer command to the main memory 2, a transfer completion confirmation of whether or not the transfer from the auxiliary memory 3 to the main memory 2 is performed, and the determination result is notified to necessary components by software or firmware. When the CPU 1 receives the notification of the transfer completion confirmation, it starts accessing the file in the main memory 2.

【0005】[0005]

【発明が解決しようとする課題】従って、以上のような
電子計算機においては、次のような問題がある。すなわ
ち、CPU1で必要とするファイルが主メモリ2に存在
しないとき、補助メモリ3に該当ファイルが存在するか
否かをチェックし、存在すれば補助メモリ3から主メモ
リ2に必要とするファイルを転送するが、これら一連の
処理およびファイル転送に多少なりとも時間がかかる。
特に、CPUI側ではプログラムおよびデータのファイ
ルを頻繁に必要とすることから、ファイルの転送回数が
少なければ少ないほどよいが、現実には非常に難しい、
その結果、電子計算機全体の効率低下を招く問題があ
る。
Therefore, the above electronic computer has the following problems. That is, when the file required by the CPU 1 does not exist in the main memory 2, it is checked whether or not the corresponding file exists in the auxiliary memory 3, and if there is, the necessary file is transferred from the auxiliary memory 3 to the main memory 2. However, the series of processes and file transfer take some time.
In particular, since the CPUI side frequently needs files of programs and data, the smaller the number of file transfers, the better, but it is very difficult in reality.
As a result, there is a problem that the efficiency of the entire electronic computer is reduced.

【0006】本発明は上記実情に鑑みてなされたもの
で、補助メモリから主メモリへのファイル転送回数を低
減化し、電子計算機全体の効率アップを図るメモリ有効
利用装置を提供することを目的とする。
The present invention has been made in view of the above circumstances, and an object of the present invention is to provide a memory effective utilization apparatus for reducing the number of file transfers from the auxiliary memory to the main memory and improving the efficiency of the entire electronic computer. .

【0007】[0007]

【課題を解決するための手段】上記課題を解決するため
に、請求項1に対応する発明は、CPUで必要とするフ
ァイルが主メモリに存在しないとき、補助メモリから前
記必要とするファイルを前記主メモリに転送するメモリ
有効利用装置において、前記CPUからファイルの転送
要求を受けたとき、当該ファイルが前記主メモリに存在
しないとき、前記CPUのプログラムを仮想実行させて
ステップ命令を読み取っていく仮想実行手段と、この仮
想実行手段によるステップ命令の読み取りによって次の
ファイル転送要求があれば、その転送要求のファイル名
を抽出する次転送ファイル名抽出手段と、この抽出手段
によって抽出されたファイル名が前記主メモリに存在す
るか否かを判断し、当該主メモリに存在するとき当該フ
ァイル名のファイル占有領域を使用不可とする領域使用
不可決定手段とを有する有効利用処理部を設け、領域使
用不可決定手段による使用不可の決定後にCPUのプロ
グラムを実行モードに戻すメモリ有効利用装置である。
In order to solve the above-mentioned problems, the invention according to claim 1 is such that when a file required by the CPU does not exist in the main memory, the required file is stored in the auxiliary memory. In a memory effective utilization device that transfers to a main memory, when a file transfer request is received from the CPU and the file does not exist in the main memory, the program of the CPU is virtually executed to read a step command. If there is a next file transfer request by the execution means and the reading of the step command by the virtual execution means, the next transfer file name extraction means for extracting the file name of the transfer request and the file name extracted by the extraction means are It is determined whether the file name exists in the main memory, and when it exists in the main memory, the file with the file name is The effective utilization processing unit and a region unusable determining means to disable the occupied area is provided, a memory efficient use device that returns the CPU of the program after determining disabled by the area unavailable determining means to execute mode.

【0008】次に、請求項2に対応する発明は、CPU
で必要とするファイルが主メモリに存在しないとき、補
助メモリから前記必要とするファイルを前記主メモリに
転送するメモリ有効利用装置において、前記CPUから
のファイルの転送要求に基づいて前記補助メモリから前
記主メモリに当該ファイルを転送するに際し、前記主メ
モリの空き領域を判断する空き領域判断手段と、この判
断手段によって前記主メモリに空き領域がないとき、所
定の順序で前記主メモリの各ファイルの領域が使用可能
であるか判断する使用可能判断手段と、この使用可能判
断手段によって使用可能であるとき、使用可能なファイ
ルについてファイル使用回数を判断するファイル使用回
数判断手段と、この判断手段によって前記使用可能ファ
イルが他のファイルよりも使用回数が少ないとき、当該
使用可能ファイルの過去の使用日時が前記他のファルの
使用日時よりも遠いときに当該使用可能ファイルを空き
領域と判断するファイル使用日時判断手段とを有する有
効利用処理部を設け、転用要求のあった補助メモリのフ
ァイルを前記主メモリの使用可能ファイルエリアに転送
させるメモリ有効利用装置である。
The invention according to claim 2 is a CPU
In a memory effective utilization device that transfers the required file from the auxiliary memory to the main memory when the file required by the CPU does not exist in the main memory, the auxiliary memory is used to transfer the file from the auxiliary memory to the When transferring the file to the main memory, a free area determining means for determining a free area of the main memory, and when there is no free area in the main memory by this determining means, the files of the main memory are stored in a predetermined order. Availability determining means for determining whether or not the area is available, and file usage count determining means for determining the file usage count of a usable file when the availability is available, and the determining means When the usable file is used less frequently than other files, the usable file An effective use processing unit having a file use date / time determining means for determining the available file as an empty area when the past use date / time is farther than the use date / time of the other file is provided, and A memory effective utilization device for transferring a file to the usable file area of the main memory.

【0009】[0009]

【作用】従って、請求項1に対応する発明は以上のよう
な手段を講じたことにより、CPUからファイルの転送
要求があったとき、当該ファイルが主メモリに存在しな
いとき、CPUのプログラムを仮想実行し、次に必要と
するファイルが主メモリにあるか否かを判断し、主メモ
リにあれば当該ファイル名のファイルを使用不可とし補
助メモリから要求ファイルを転送しないようにするの
で、その分だけ転送回数が少なくなり、ファイル転送時
間を低減化でき、適用機器全体のスループットを向上さ
せることができる。
Therefore, according to the invention corresponding to claim 1, by taking the above means, when the file transfer request is issued from the CPU, when the file does not exist in the main memory, the program of the CPU is virtualized. Execute it and determine whether the next required file exists in main memory.If it exists in main memory, the file with the file name is disabled and the requested file is not transferred from auxiliary memory. Therefore, the number of transfers can be reduced, the file transfer time can be shortened, and the throughput of the entire applicable device can be improved.

【0010】また、請求項2に対応する発明は、CPU
からファイルの転送要求があったとき、主メモリに空き
領域がなければ、主メモリに使用可能な領域のファイル
があり、かつ、ファイルの使用回数が少なく、しかも過
去の使用日時が古いファイルを特定し、当該特定された
ファイルを空き領域と判断し、補助メモリからCPUで
必要とするファイルを転送するので、請求項1に対応す
る発明と同様な作用を有する。
The invention according to claim 2 is a CPU
If there is no free area in the main memory when a file transfer request is made from a file, there is a file in the available area in the main memory, the number of times the file has been used is small, and the file with the oldest usage date and time is specified. However, since the specified file is determined to be a free area and the file required by the CPU is transferred from the auxiliary memory, it has the same operation as the invention corresponding to claim 1.

【0011】[0011]

【実施例】以下、本発明装置の実施例を説明するに際
し、本発明装置の理解を容易にするために、主メモリと
補助メモリとのファイルの利用関係について図1および
図2を参照して説明する。
DESCRIPTION OF THE PREFERRED EMBODIMENTS In explaining the embodiments of the device of the present invention, in order to facilitate understanding of the device of the present invention, referring to FIG. 1 and FIG. 2 regarding the use relationship of files between a main memory and an auxiliary memory. explain.

【0012】図1に示すごとく、CPUで必要とするフ
ァイルが主メモリ11に存在しないとき、必要なファイ
ルを補助メモリ12から主メモリ11に転送するが、こ
のとき主メモリ11に空き領域があれば、何ら問題なく
転送できるが、空き領域がないときには問題となる。
As shown in FIG. 1, when a file required by the CPU does not exist in the main memory 11, the required file is transferred from the auxiliary memory 12 to the main memory 11. At this time, there is an empty area in the main memory 11. For example, you can transfer without any problems, but it becomes a problem when there is no free space.

【0013】一般に、主メモリ11に空き領域がないと
き、主メモリ11の先頭側から順次ファイルを調べなが
ら転送対象となるファイルより大きな領域を占有し、か
つ、現在利用されていないファイルを探し、その領域の
ファイルを補助メモリ12に転送後、或いは当該利用さ
れていないファイルの上に転送対象のファイルを転送し
書き込むことが考えられる。例えばCPUで必要とする
ファイルが主メモリ11に存在しないとき、補助メモリ
12からファイルを主メモリ11に転送するが、主メモ
リ11の先頭のファイルにファイルxよりも大きな空き
領域がない場合には主メモリ11の先頭側から順次転送
すべき領域のファイルを探し出していく。このとき、フ
ァイルa,bとも使用していない場合、補助メモリ12
のファイルxを主メモリ11の先頭のファイルaからフ
ァイルbにかけてその上に書き込んでいくが、ファイル
bが使用している場合には先頭から書き込めない。
Generally, when there is no free area in the main memory 11, a file that occupies a larger area than the file to be transferred and is currently unused is searched while sequentially examining files from the head side of the main memory 11. It is possible to transfer the file in the area to the auxiliary memory 12 or transfer and write the transfer target file on the unused file. For example, when the file required by the CPU does not exist in the main memory 11, the file is transferred from the auxiliary memory 12 to the main memory 11, but if the head file of the main memory 11 does not have a free area larger than the file x. The files in the area to be transferred are sequentially searched from the head side of the main memory 11. At this time, if the files a and b are not used, the auxiliary memory 12
The file x is written from the top of the main memory 11 to the file a to the file b, but when the file b is used, the file cannot be written from the beginning.

【0014】そこで、ファイルbが使用されている場
合、ファイルc,dが使用されていないことを確認し、
ファイルc,dを補助メモリ12に転送するか、或いは
そのままの状態でファイルxをファイルcからdにかけ
て書き込むことになる。図2はファイルxを書き込んだ
状態を表している。
Therefore, when the file b is used, it is confirmed that the files c and d are not used,
The files c and d are transferred to the auxiliary memory 12, or the file x is written from the file c to the file d as it is. FIG. 2 shows a state in which the file x has been written.

【0015】しかし、ここで問題となるのは、ファイル
xを転送した後、CPUがその後直ちにファイルcまた
はdを必要とする場合が生ずる。この場合には再び補助
メモリ12からファイルcまたはdを主メモリ11に転
送するが、同様に空き領域の検索およびファイル転送動
作が必要となり、それほど転送回数を減らせない。
However, the problem here arises when the CPU needs the file c or d immediately after transferring the file x. In this case, the file c or d is transferred from the auxiliary memory 12 to the main memory 11 again, but similarly, a search for an empty area and a file transfer operation are required, and the transfer count cannot be reduced so much.

【0016】そこで、本発明装置は、以上のような不都
合な点を回避しつつ実現したものであり、以下、その実
施例について説明する。図3は本発明に係わるメモリ有
効利用装置の第1の実施例を示す構成図である。なお、
このメモリ有効利用装置は、一般的な電子計算機に限ら
ず、デジタルコントローラ、プロセスコンピュータ、汎
用のパーソナルコンピュータの何れにも適用可能なもの
である。
Therefore, the device of the present invention has been realized while avoiding the inconveniences described above, and its embodiment will be described below. FIG. 3 is a block diagram showing a first embodiment of a memory effective utilization apparatus according to the present invention. In addition,
The memory effective utilization device is applicable not only to a general electronic computer, but also to any of a digital controller, a process computer, and a general-purpose personal computer.

【0017】このメモリ有効利用装置は、CPU10,
主メモリ11,補助メモリ12を有する他、新たに有効
利用処理部13が設けられている。この有効利用処理部
13は、CPU10からファイルの転送要求を受けたと
き、そのファイルが主メモリ11に存在しないとき、C
PU10のプログラムを仮想実行させてステップ命令を
読み取っていく仮想実行手段21と、この仮想実行手段
21によるステップ命令の読み取りによって次のファイ
ル転送要求があれば、その転送要求のファイル名を抽出
する次転送ファイル名抽出手段22と、この抽出手段2
2によって抽出されたファイル名が主メモリ11に存在
するか否かを判断し、主メモリ11に存在するとき当該
ファイル名のファイル占有領域を使用不可とする領域使
用不可決定手段23とによって構成されている。そし
て、この領域使用不可決定手段23による使用不可の決
定後にCPU10のプログラムを実行モードに戻すもの
である。
This memory effective utilization apparatus is composed of a CPU 10,
In addition to having a main memory 11 and an auxiliary memory 12, an effective utilization processing unit 13 is newly provided. When the file transfer request is received from the CPU 10 and the file does not exist in the main memory 11, the effective use processing unit 13 C
If there is a next file transfer request by reading the step command by the virtual execution means 21 that virtually executes the program of the PU 10 and reads the step command, the file name of the transfer request is extracted. Transfer file name extraction means 22 and this extraction means 2
And an area unusable determination unit 23 that determines whether or not the file name extracted by 2 exists in the main memory 11 and disables the file occupied area of the file name when it exists in the main memory 11. ing. The program of the CPU 10 is returned to the execution mode after the area unusability determination means 23 determines that the area is unusable.

【0018】次に、以上のように構成された装置の動作
について図4を参照して説明する。先ず、有効利用処理
部13の仮想実行手段21は、CPU10からファイル
転送要求を受けると(S1)、CPU10に対して次の
ファイル転送要求まで仮想実行させる(S2)。ここ
で、CPU10が仮想実行されると、そのプログラム命
令を1ステップずつ読んでいく(S3)。S4に示すよ
うに、次のファイルの転送要求が検知されまで順次プロ
グラムのステップ命令を読んでいく。
Next, the operation of the apparatus configured as described above will be described with reference to FIG. First, when the virtual execution means 21 of the effective use processing unit 13 receives a file transfer request from the CPU 10 (S1), it causes the CPU 10 to virtually execute the next file transfer request (S2). Here, when the CPU 10 is virtually executed, the program instructions are read step by step (S3). As shown in S4, the step instructions of the program are sequentially read until the transfer request for the next file is detected.

【0019】引き続き、有効利用処理部13の次転送フ
ァイル名抽出手段22を実行する。この次転送ファイル
名抽出手段22は、次のファイルの転送要求があるか否
かを判断し(S4)、次のファイルの転送要求を検知し
たとき、その転送要求時に転送しようとするファイル名
を抽出する(S5)。
Subsequently, the next transfer file name extracting means 22 of the effective use processing section 13 is executed. The next transfer file name extraction means 22 determines whether or not there is a transfer request for the next file (S4). When the transfer request for the next file is detected, the file name to be transferred at the time of the transfer request is determined. Extract (S5).

【0020】次に、領域使用不可決定手段23を実行す
る。この領域使用不可決定手段23は、ステップS5に
おいてファイル名が抽出されたならば、そのファイル名
のファイルが主メモリ11に存在するか否かをチェック
し(S6)、主メモリ11に当該ファイルが存在する場
合には主メモリ11の該当ファイルの占有領域を使用不
可とした後(S7)、CPU10のプログラムの本来の
実行モードに戻し処理を行う(S8,S9)。ここで、
CPU10は、プログラム動作を実行し、次の命令ステ
ップへと進んでいく。
Next, the area unusability determination means 23 is executed. When the file name is extracted in step S5, the area unusability determination means 23 checks whether or not the file with the file name exists in the main memory 11 (S6), and the file is stored in the main memory 11. If it exists, the occupied area of the corresponding file in the main memory 11 is disabled (S7), and then the original execution mode of the program of the CPU 10 is restored (S8, S9). here,
The CPU 10 executes the program operation and proceeds to the next instruction step.

【0021】従って、以上のような実施例の構成によれ
ば、予めプログラムに基づいて所定の順序で順次処理す
るリアルタイム処理を行う場合、当該プログラムによっ
てファイル転送が決定されるので、ファイル転送要求の
あった時点で前記プログラムを先取り(仮想実行)し、
次のファイル転送要求を検知し、次に転送が予想される
ファイル名を解読する。そして、転送が予想されるファ
イル名のファイルが既に主メモリ12に存在する場合に
は、少くとも転送が予想されるファイルの占有領域を利
用不可とすることにより、当該ファイルは主メモリ12
上で保護され、プログラムの実行段階でファイルが必要
となったとき、再転送せずに当該ファイルをそのまま利
用することができる。
Therefore, according to the configuration of the above embodiment, when performing the real-time processing in which the program is sequentially processed in a predetermined order based on the program, the file transfer is determined by the program. If there is, the program is preempted (virtual execution),
Detects the next file transfer request and then decodes the file name expected to be transferred. If a file having a file name to be transferred is already present in the main memory 12, the file is transferred to the main memory 12 by disabling at least the occupied area of the file to be transferred.
Protected above, when a file is needed during the execution of the program, it can be used as is without retransfer.

【0022】次に、本発明装置の第2の実施例について
図5を参照して説明する。このメモリ有効利用装置は、
図3と同様にCPU10,主メモリ11,補助メモリ1
2を有する他、新たに有効利用処理部13が設けられて
いる。このCPU10(または主メモリ11,有効利用
処理部13等)には主メモリ11の各ファイルごとのフ
ァイル使用回数データを格納する使用回数格納部31お
よび主メモリ11の各ファイルごとに使用日時データを
格納する使用日時格納部32が設けられている。
Next, a second embodiment of the device of the present invention will be described with reference to FIG. This memory effective utilization device,
Similar to FIG. 3, CPU 10, main memory 11, auxiliary memory 1
In addition to 2, the effective use processing unit 13 is newly provided. The CPU 10 (or the main memory 11, the effective use processing unit 13 and the like) stores usage date storage data for each file in the main memory 11 and usage date / time data for each file in the main memory 11. A use date / time storage unit 32 for storing is provided.

【0023】前記有効利用処理部13は、CPU10か
らのファイルの転送要求に基づいて前記補助メモリ12
から主メモリ11に転送するとき、主メモリ12に空き
領域があるか否かを判断する空き領域判断手段35と、
この判断手段35によって主メモリ11に空き領域がな
いとき、所定の順序で順次ファイルを特定し、主メモリ
11のファイルの領域が転送ファイルとして使用可能か
否かを判断する使用可能判断手段36と、この使用可能
判断手段36によって使用可能である判断したとき、そ
の使用可能と判断されたファイルについてファイル使用
回数を判断するファイル使用回数判断手段37と、この
判断手段37によって使用可能ファイルが他のファイル
よりも使用回数が少ないとき、当該使用可能ファイルの
過去の使用日時が前記他のファルの使用日時よりも古い
ときに当該使用可能ファイルを空き領域と判断するファ
イル使用日時判断手段38とが設けられている。そし
て、ファイル使用日時判断手段38によって空き領域と
判断されたファイルに転送要求のあった前記補助メモリ
のファイルを転送するものである。
The effective use processing unit 13 is responsive to the file transfer request from the CPU 10 to send the auxiliary memory 12 to the auxiliary memory 12.
From the main memory 11 to the main memory 11 to determine whether there is a free area in the main memory 12,
When there is no free area in the main memory 11 by the judging means 35, files are sequentially specified in a predetermined order, and the availability judging means 36 judges whether the file area of the main memory 11 can be used as a transfer file. When the availability determining unit 36 determines that the file is usable, the file usage number determining unit 37 that determines the number of times the file is used for the file that is determined to be usable, and the determining unit 37 determines that the usable file is other When the number of times of use of the file is smaller than that of the file, and when the date and time of past use of the available file is older than the date and time of use of the other file, the file use date and time determining means 38 is provided to determine the available file as a free area. Has been. Then, the file in the auxiliary memory for which the transfer request is made is transferred to the file judged to be an empty area by the file use date / time judging means 38.

【0024】次に、以上のような構成の第2の実施例の
動作について図6を参照して説明する。CPU10から
ファイル転送要求を受けると、そのファイルが主メモリ
11に存在するか否かを判断する。ここで、主メモリ1
1で必要とするファイルが存在しない場合、補助メモリ
12から主メモリ11にファイル転送を行うべき指令を
出力するが、この転送指令に先立って次のような処理を
実行する。
Next, the operation of the second embodiment having the above configuration will be described with reference to FIG. When a file transfer request is received from the CPU 10, it is determined whether the file exists in the main memory 11. Where main memory 1
If the file required by 1 does not exist, the auxiliary memory 12 outputs a command for file transfer to the main memory 11, but the following process is executed prior to this transfer command.

【0025】先ず、有効利用処理部13の空き領域判断
手段35は、主メモリ11で必要とするファイルに相当
する空き領域が存在するか否かを判断する(S11)。
主メモリ11に空き領域がなければ、使用可能判断手段
36を実行する。
First, the free space determination means 35 of the effective use processing unit 13 determines whether or not there is a free space corresponding to a file required in the main memory 11 (S11).
If there is no free area in the main memory 11, the availability determining means 36 is executed.

【0026】この使用可能判断手段36は、メモリカウ
ンタのカウント値n=0にn=n+1(図1のファイル
a)を設定し(S12)、主メモリ11のファイルn
(=a)の領域が転送すべきファイルの領域よりも大き
いか、つまり使用可能か否かを判断する(S13)。仮
に、ファイルn(=a)が使用不可能であれば、次のス
テップS14に移行し、全ファイルを検索したか否かを
調べる。全ファイルについて検索していない場合には、
引き続き、S12に戻ってメモリカウンタのカウント値
をインクリメントする。
The availability determining means 36 sets n = n + 1 (file a in FIG. 1) to the count value n = 0 of the memory counter (S12), and the file n in the main memory 11 is set.
It is determined whether the area of (= a) is larger than the area of the file to be transferred, that is, it is usable (S13). If the file n (= a) cannot be used, the process proceeds to the next step S14, and it is checked whether or not all the files have been searched. If you have not searched for all files,
Then, it returns to S12 and increments the count value of the memory counter.

【0027】ステップS13においてファイルnが使用
可能であるとき、ファイル使用回数判断手段37を実行
する。このファイル使用回数判断手段37は、当該ファ
イルについて主メモリ11の使用回数格納部31から該
当ファイルの使用回数を取り出し、この使用回数が他の
ファイルの使用回数よりも多いか否かを判断する(S1
5)。他のファイルよりも使用回数が多いとき、当該フ
ァイルが使用頻度が高いと判断し、ステップS12に戻
り、次のファイルn=n+1(図1のファイルb)につ
いて同一の処理を繰り返し行なう。ステップS15にお
いて該当ファイルの使用回数が他のファイルも少ない場
合には次のステップS16に移行し、ファイル使用日時
判断手段38を実行する。
When the file n is available in step S13, the file use count judging means 37 is executed. The file usage count determination unit 37 retrieves the usage count of the corresponding file from the usage count storage unit 31 of the main memory 11 for the file, and determines whether the usage count is greater than the usage count of another file ( S1
5). When the file is used more frequently than other files, it is determined that the file is used more frequently, the process returns to step S12, and the same process is repeated for the next file n = n + 1 (file b in FIG. 1). If the number of times the file is used is small in other files in step S15, the process proceeds to the next step S16, and the file use date / time determining means 38 is executed.

【0028】このファイル使用日時判断手段38は、同
じく当該ファイルについて主メモリ11の使用日時格納
部32から該当ファイルの使用日時データを取り出し、
この使用日時データが他のファイルの使用日時よりも古
いか否かを判断する。他のファイルよりも使用日時が新
しいとき、当該ファイルが使用頻度が高いと判断し、ス
テップS12に戻り、次のファイルn=n+1(図1の
ファイルb)について同一の処理を繰り返し行なう。ス
テップS16において該当ファイルの使用日時が他のフ
ァイルも古い場合にはファイルn(=a)の領域が空き
と決定し(S17)、補助メモリ12に要求ファイルの
転送要求を行なう。
The file use date / time determining means 38 also retrieves the use date / time data of the file from the use date / time storage 32 of the main memory 11 for the file.
It is determined whether or not this usage date / time data is older than the usage date / time of another file. When the date and time of use is newer than the other file, it is determined that the file is used more frequently, the process returns to step S12, and the same process is repeated for the next file n = n + 1 (file b in FIG. 1). In step S16, if the date and time of use of the file is old, the area of file n (= a) is determined to be empty (S17), and a request file transfer request is made to the auxiliary memory 12.

【0029】一方、ステップS14において全部のファ
イル領域が使用可能でないとき、ステップS15〜S1
6と同様な処理を行う。つまり、別のメモリカウンタの
カウント値n=n+1を設定し(S21)、当該ファイ
ルの使用回数が他のファイルよりも少ないか否かを判断
し(S22)、さらに当該ファイルの過去の使用日時が
他のファイルよりも古いかを調べ、これら条件を満足す
るファイルがあれば、そのファイルの領域と転送すべき
ファイルの領域とを比較し、領域が不足する場合には、
選択したファイル名を登録後、引き続き、次のファイル
を特定し、同様の処理を繰り返し、転送すべきファイル
の領域に相当する領域を確保する(S24)。そして、
1つまたは2つ以上のファイルを探し出したならば、こ
れらファイルを補助メモリ12に退避させた後、その主
メモリ12の退避されたファイル部分に補助メモリ12
から必要とするファイルを転送する。
On the other hand, when the entire file area is not usable in step S14, steps S15 to S1.
The same process as 6 is performed. That is, the count value n = n + 1 of another memory counter is set (S21), it is determined whether or not the number of times of use of the file is smaller than that of the other file (S22), and the past use date and time of the file is Check if it is older than other files, and if there is a file that satisfies these conditions, compare the area of that file with the area of the file to be transferred, and if the area is insufficient,
After registering the selected file name, the next file is continuously specified, and the same process is repeated to secure an area corresponding to the area of the file to be transferred (S24). And
If one or more files are found, these files are saved in the auxiliary memory 12 and then the auxiliary memory 12 is stored in the saved file portion of the main memory 12.
Transfer the files you need from.

【0030】従って、以上のような実施例の構成によれ
ば、主メモリ11の各ファイルの利用回数(積算)、前
回使用日時などを記憶させておき、CPU10が必要と
するファイルの転送要求があったとき、主メモリ11に
空き領域があるか否かを調べ、空き領域がないとき例え
ば主メモリ11の先頭から順次各ファイルの使用可能領
域、使用回数および前回使用日時を検索することによ
り、使用確立および使用頻度の低いファイル領域を空き
領域とし、この空き領域とするファイル領域に補助メモ
リからのファイルを転送するので、使用確立および使用
頻度の高いファイルが主メモリ11上に残ることにな
る。このことは、補助メモリ12から主メモリ11への
ファイルの転送回数が少なくなり、CPU10における
ビット率が向上する。なお、本発明はその要旨を逸脱し
ない範囲で種々変形して実施できる。
Therefore, according to the configuration of the above embodiment, the number of times each file is used in the main memory 11 (cumulative), the date and time of the last use, etc. are stored, and the file transfer request required by the CPU 10 is made. If there is, the main memory 11 is checked whether or not there is a free area, and when there is no free area, for example, the available area, the number of times of use, and the last use date and time of each file are sequentially searched from the beginning of the main memory 11. Since the file area from the auxiliary memory is transferred to the file area which is used and established and used less frequently, the file area which is used and used frequently remains in the main memory 11. . This reduces the number of file transfers from the auxiliary memory 12 to the main memory 11 and improves the bit rate in the CPU 10. The present invention can be variously modified and implemented without departing from the scope of the invention.

【0031】[0031]

【発明の効果】以上説明したように本発明によれば、次
のような効果を奏する。請求項1においては、補助メモ
リからファイル転送が必要になったとき、CPUのプロ
グラムを仮想実行させて次のファイル転送に基づくファ
イル名を抽出し、そのファイル名のファイルが主メモリ
にあれば、ファイル占有領域の使用不可とするので、そ
の分だけ転送回数が削減され、適用機器全体の処理速度
を上げることができる。
As described above, the present invention has the following effects. In claim 1, when a file transfer is required from the auxiliary memory, the program of the CPU is virtually executed to extract the file name based on the next file transfer, and if the file with the file name exists in the main memory, Since the file occupied area is disabled, the number of transfers can be reduced by that amount, and the processing speed of the entire applicable device can be increased.

【0032】次に、請求項2によれば、ファイルの使用
回数および使用日時から使用頻度の高いファイルを残
し、使用頻度の低いファイルを空き領域とし、補助メモ
リからファイルを転送するので、転送回数の削減、CP
Uのヒット率の向上に大きく貢献できる。
Next, according to the second aspect, the files that are frequently used are left according to the number of times of use and the date and time of use, and the files that are less frequently used are made free areas, and the files are transferred from the auxiliary memory. Reduction, CP
It can greatly contribute to the improvement of U's hit rate.

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

【図1】本発明に係わるメモリ有効利用装置の理解を容
易にするために説明する主メモリと補助メモリとのファ
イル関係図。
FIG. 1 is a file relationship diagram of a main memory and an auxiliary memory, which is described to facilitate understanding of a memory effective utilization apparatus according to the present invention.

【図2】補助メモリから主メモリにファイルを転送させ
た後の主メモリのファイル状態図。
FIG. 2 is a file state diagram of the main memory after transferring a file from the auxiliary memory to the main memory.

【図3】本発明に係わるメモリ有効利用装置の第1の実
施例を示す構成図。
FIG. 3 is a configuration diagram showing a first embodiment of a memory effective utilization device according to the present invention.

【図4】第1の実施例の動作を説明するフローチャー
ト。
FIG. 4 is a flowchart illustrating the operation of the first embodiment.

【図5】本発明に係わるメモリ有効利用装置の第2の実
施例を示す構成図。
FIG. 5 is a configuration diagram showing a second embodiment of a memory effective utilization device according to the present invention.

【図6】第2の実施例の動作を説明するフローチャー
ト。
FIG. 6 is a flowchart illustrating the operation of the second embodiment.

【図7】従来装置を示す構成図。FIG. 7 is a configuration diagram showing a conventional device.

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

10…CPU、11…主メモリ、12…補助メモリ、1
3…有効利用処理部、21…仮想実行手段、22…次転
送ファイル抽出手段、23…領域使用不可決定手段、3
1…使用回数格納部、32…使用日時格納部、35…空
き領域判断手段、36…使用可能判断手段、37…ファ
イル使用回数判断手段、38…ファイル使用日時判断手
段。
10 ... CPU, 11 ... Main memory, 12 ... Auxiliary memory, 1
3 ... Effective use processing section, 21 ... Virtual execution means, 22 ... Next transfer file extraction means, 23 ... Area unusable determination means, 3
DESCRIPTION OF SYMBOLS 1 ... Use count storage unit, 32 ... Use date storage unit, 35 ... Free space determination means, 36 ... Usability determination means, 37 ... File use number determination means, 38 ... File use date / time determination means.

Claims (2)

【特許請求の範囲】[Claims] 【請求項1】 中央演算処理装置(以下、CPUと呼
ぶ)で必要とするファイルが主メモリに存在しないと
き、補助メモリから前記必要とするファイルを前記主メ
モリに転送するメモリ有効利用装置において、 前記CPUからファイルの転送要求を受けたとき、当該
ファイルが前記主メモリに存在しないとき、前記CPU
のプログラムを仮想実行させてステップ命令を読み取っ
ていく仮想実行手段と、この仮想実行手段によるステッ
プ命令の読み取りによって次のファイル転送要求があれ
ば、その転送要求のファイル名を抽出する次転送ファイ
ル名抽出手段と、この抽出手段によって抽出されたファ
イル名が前記主メモリに存在するか否かを判断し、当該
主メモリに存在するとき当該ファイル名のファイル占有
領域を使用不可とする領域使用不可決定手段とを有する
有効利用処理部を備え、 前記領域使用不可決定手段による使用不可の決定後に前
記CPUのプログラムを実行モードに戻すことを特徴と
するメモリ有効利用装置。
1. A memory effective utilization apparatus for transferring a required file from an auxiliary memory to the main memory when a file required by a central processing unit (hereinafter referred to as CPU) is not present in the main memory, When a file transfer request is received from the CPU and the file does not exist in the main memory, the CPU
If the next file transfer request is made by reading the step command by this virtual execution means, the virtual execution means for virtually executing the program of step 1 to read the step command, and the next transfer file name for extracting the file name of the transfer request Extraction means and a judgment as to whether or not the file name extracted by this extraction means exists in the main memory, and when it exists in the main memory, an area unusable determination that makes the file occupied area of the file name unusable A memory effective utilization apparatus comprising: an effective utilization processing unit having means, and returning the program of the CPU to an execution mode after the area unusability determination unit determines that the area is unusable.
【請求項2】 CPUで必要とするファイルが主メモリ
に存在しないとき、補助メモリから前記必要とするファ
イルを前記主メモリに転送するメモリ有効利用装置にお
いて、 前記CPUからのファイルの転送要求に基づいて前記補
助メモリから前記主メモリに当該ファイルを転送するに
際し、前記主メモリの空き領域を判断する空き領域判断
手段と、この判断手段によって前記主メモリに空き領域
がないとき、所定の順序で前記主メモリの各ファイルの
領域が使用可能であるか判断する使用可能判断手段と、
この使用可能判断手段によって使用可能であるとき、使
用可能なファイルについてファイル使用回数を判断する
ファイル使用回数判断手段と、この判断手段によって前
記使用可能ファイルが他のファイルよりも使用回数が少
ないとき、当該使用可能ファイルの過去の使用日時が前
記他のファルの使用日時よりも遠いときに当該使用可能
ファイルを空き領域と判断するファイル使用日時判断手
段とを有する有効利用処理部を備え、 転用要求のあった補助メモリのファイルを前記主メモリ
の使用可能ファイルエリアに転送させることを特徴とす
るメモリ有効利用装置。
2. A memory effective utilization apparatus for transferring the required file from the auxiliary memory to the main memory when the file required by the CPU does not exist in the main memory, based on a file transfer request from the CPU. When transferring the file from the auxiliary memory to the main memory, the free area determining means for determining the free area of the main memory, and when the main memory has no free area by the determining means, the free area determining means Availability determination means for determining whether each file area in the main memory is available,
When it is usable by this availability determining means, a file usage count determining means for determining the file usage count of a usable file; and when the usage count of the available file is smaller than other files by this determining means, When the past use date and time of the usable file is farther than the use date and time of the other file, the effective use processing unit having a file use date and time determining unit that determines the usable file as a free area is provided, A memory effective utilization apparatus, characterized in that a file of the existing auxiliary memory is transferred to an available file area of the main memory.
JP5231577A 1993-09-17 1993-09-17 Memory effective utilizing device Pending JPH0784845A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP5231577A JPH0784845A (en) 1993-09-17 1993-09-17 Memory effective utilizing device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP5231577A JPH0784845A (en) 1993-09-17 1993-09-17 Memory effective utilizing device

Publications (1)

Publication Number Publication Date
JPH0784845A true JPH0784845A (en) 1995-03-31

Family

ID=16925705

Family Applications (1)

Application Number Title Priority Date Filing Date
JP5231577A Pending JPH0784845A (en) 1993-09-17 1993-09-17 Memory effective utilizing device

Country Status (1)

Country Link
JP (1) JPH0784845A (en)

Similar Documents

Publication Publication Date Title
EP0710375B1 (en) File backup system
US5696989A (en) Microcomputer equipped with DMA controller allowed to continue to perform data transfer operations even after completion of a current data transfer operation
US7831857B2 (en) Method and system for recovering from operating system crash or failure
JPH02267634A (en) Interrupt system
US5363502A (en) Hot stand-by method and computer system for implementing hot stand-by method
JPH04211838A (en) Method and apparatus for preventing returning risk
EP1730655B1 (en) Optimizing database access for record linkage by tiling the space of record pairs
US20080320176A1 (en) Prd (physical region descriptor) pre-fetch methods for dma (direct memory access) units
TW200417859A (en) Storage system and method with snapshot backup function
JPH0784845A (en) Memory effective utilizing device
US8095784B2 (en) Computer system and method for activating basic program therein
JPS6342294B2 (en)
JP2009230479A (en) Microprocessor
JP3130798B2 (en) Bus transfer device
JP2562838B2 (en) Processor and store buffer control method
JPH07152574A (en) Program loading system
JP2007156702A (en) Operating system
JP2825589B2 (en) Bus control method
JP2501393B2 (en) Direct memory access device
JPS59172044A (en) Instruction control system
JP3116819B2 (en) Microprogram retry control method
JPH07141120A (en) Processing method for fault in information storage medium
CA2153508C (en) A method of operating a computer system
CN114443276A (en) Local storage engine IO aggregation method and device and storage medium
JPH11134202A (en) Task switching device