JPH03147156A - Swap processing system for required physical page - Google Patents

Swap processing system for required physical page

Info

Publication number
JPH03147156A
JPH03147156A JP1284813A JP28481389A JPH03147156A JP H03147156 A JPH03147156 A JP H03147156A JP 1284813 A JP1284813 A JP 1284813A JP 28481389 A JP28481389 A JP 28481389A JP H03147156 A JPH03147156 A JP H03147156A
Authority
JP
Japan
Prior art keywords
swap
swapped
pages
page
physical
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.)
Granted
Application number
JP1284813A
Other languages
Japanese (ja)
Other versions
JPH07120317B2 (en
Inventor
Koji Tanaka
幸二 田中
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
NEC Corp
Original Assignee
NEC Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by NEC Corp filed Critical NEC Corp
Priority to JP1284813A priority Critical patent/JPH07120317B2/en
Publication of JPH03147156A publication Critical patent/JPH03147156A/en
Publication of JPH07120317B2 publication Critical patent/JPH07120317B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Memory System Of A Hierarchy Structure (AREA)

Abstract

PURPOSE:To accelerate a swap processing by limiting the object of swap-out to a physical page, which is required for swapping-in a process, only out of all the physical pages used by the process. CONSTITUTION:A process swap-out means SF3 swaps out only the physical page, which is required for swapping-in the process selected by a swap-in process selecting means SF1, out of the physical pages belonging to the process, which is selected by a swap-out processing selecting means SF2, according to a page swap-out means SOF. The passing time of a process control table is updated to '0' corresponding to the swapped-out process and process state information is updated to 'OUT' to show a swapped-out state, respectively. Then, the number of the swapped-out pages is added to a swap-out page number. Thus, the swap processing is accelerated.

Description

【発明の詳細な説明】 [産業上の利用分野] 本発明は計算機の主記憶装置上にあるイメージを補助記
憶装置上に書き出す、あるいは、補助記憶装置上に書き
出されたイメージを主記憶装置上に読み込むスワップア
ウト、スワップイン処理方式に関する。
Detailed Description of the Invention [Industrial Application Field] The present invention writes an image on the main memory of a computer to an auxiliary memory, or writes an image written on the auxiliary memory to the main memory. Concerning the swap-out and swap-in processing methods.

[従来の技術] 従来、スワップアウトするプロセスは、その全物理ペー
ジをスワップアウトの対象としていた。
[Prior Art] Conventionally, a process to be swapped out has all its physical pages to be swapped out.

そのため、使用されない物理ページもスワップアウトさ
れていた。
Therefore, unused physical pages were also being swapped out.

[発明が解決しようとする課題] 上述した従来の方式は、スワップアウトするプロセスの
全物理ページをスワップアウトするため。
[Problems to be Solved by the Invention] The conventional method described above swaps out all physical pages of the process to be swapped out.

プロセスの全体をスワップアウトするためのスワップ領
域が必要であった。また、そのプロセスを次にスワップ
インする時に、以前の物理ページが残っていても、新た
に全ての物理ページを割り当てる。不必要なデータ転送
を行わなければならず。
Swap space was needed to swap out entire processes. Furthermore, when the process is swapped in next time, all new physical pages are allocated even if the previous physical pages remain. Unnecessary data transfers have to take place.

時間がかかるという欠点があった。The drawback was that it was time consuming.

本発明の目的は、スワップイン時に必要となる物理ペー
ジのみをスワップアウトの対象とすることにより、上述
の課題を解決するスワップ処理方式を提供することにあ
る。
SUMMARY OF THE INVENTION An object of the present invention is to provide a swap processing method that solves the above-mentioned problems by swapping out only physical pages that are required during swap-in.

[課題を解決するための手段] 本発明による必要物理ページのスワップ処理方式は、計
算機の主記憶装置と補助記憶装置間でプロセスイメージ
の入出力を行うスワップ処理方式経過時間、プロセス状
態情報、全ページ数、スワップアウトページ数をプロセ
ス毎に格納するプロセス管理テーブルと。
[Means for Solving the Problems] The swap processing method for necessary physical pages according to the present invention is a swap processing method for inputting and outputting process images between the main storage device and the auxiliary storage device of a computer. A process management table that stores the number of pages and swapout pages for each process.

物理ページのスワップアウトを行うページスワップアウ
ト手段と。
A page swapout means for swapping out physical pages.

物理ページのスワップインを行うページスワップイン手
段と。
A page swap-in means for swapping in physical pages.

スワップ要求に応答して、前記プロセス管理テーブルの
前記プロセス状態情報がスワップアウトとなっているプ
ロセスの経過時間が最も長いプロセスをスワップインす
べきプロセスとして選択し。
In response to the swap request, a process whose elapsed time is the longest among the processes whose process state information in the process management table indicates swap-out is selected as the process to be swapped in.

該選択されたプロセスのスワップアウトページ数を得る
スワップインプロセス選択手段と。
Swap-in process selection means for obtaining the number of swap-out pages of the selected process.

スワップインするプロセスが必要とする物理ページを確
保するために、前記プロセス管理テーブルの前記プロセ
ス状態情報がスワップアウトとなっているプロセスで、
かつそのプロセスのすべての物理ページ数がスワップア
ウトページ数と等しくなく、かつ前記スワップインプロ
セス選択手段によって選択されていないプロセスを探し
、このようなプロセスが存在しない場合には、前記プロ
セス管理テーブルの前記プロセス状態情報がスワップイ
ンとなっているプロセスの経過時間が最も長いプロセス
をスワップアウトすべきプロセスとして選択するスワッ
プアウトプロセス選択手段と。
In order to secure the physical pages required by the swap-in process, the process state information in the process management table indicates swap-out,
and the number of all physical pages of that process is not equal to the number of swap-out pages, and the process is not selected by the swap-in process selection means, and if such a process does not exist, the process management table is Swap-out process selection means for selecting a process whose elapsed time is the longest among the processes whose process state information indicates swap-in as a process to be swapped out.

前記スワップアウトプロセス選択手段で選択されたプロ
セスに属する物理ページのうち、前記スワップインプロ
セス選択手段で選択されたプロセスをスワップインする
のに必要とされる物理ページのみ前記ページスワップア
ウト手段によりスワップアウトし、該スワップアウトし
たプロセスに対応する前記プロセス管理テーブルの前記
経過時間を“0”に、前記プロセス状態情報をスワップ
アウトされていることを示す情報にそれぞれ更新し、前
記スワップアウトページ数にスワップアウトしたページ
数を加算するプロセススワップアウト手段と。
Of the physical pages belonging to the process selected by the swap-out process selection means, only the physical pages required to swap in the process selected by the swap-in process selection means are swapped out by the page swap-out means. Then, the elapsed time in the process management table corresponding to the swapped out process is updated to "0", the process state information is updated to information indicating that it has been swapped out, and the number of swapped out pages is updated. A process swapout means that adds up the number of out pages.

物理ページのスワップアウトが終了したとき。When a physical page has been swapped out.

前記スワップインプロセス選択手段で選択されたプロセ
スのページを前記ページスワップイン手段を用いて物理
ページにスワップインし、該スワップインしたプロセス
に対応する前記プロセス管理テーブルの前記経過時間を
“0”に、前記プロセス状態情報をスワップインされて
いることを示す情報に、前記スワップアウトページ数を
“0”にそれぞれ更新するプロセススワップイン手段と
を有する。
The page of the process selected by the swap-in process selection means is swapped into a physical page using the page swap-in means, and the elapsed time of the process management table corresponding to the swapped-in process is set to "0". , a process swap-in means for updating the number of swap-out pages to "0" in the process state information indicating that the process status information has been swapped in.

[実施例] 次に本発明について図面を参照して説明する。[Example] Next, the present invention will be explained with reference to the drawings.

第1図は本発明の一実施例によるスワップ処理方式が適
用されるシステムの構成を示すブロック図である。
FIG. 1 is a block diagram showing the configuration of a system to which a swap processing method according to an embodiment of the present invention is applied.

本実施例のシステムは1ペ一ジスワツプイン手段SIF
と、ページスワップアウト手段SOFと。
The system of this embodiment has one page swap-in means SIF.
and page swap-out means SOF.

スワップ対象のプロセスを管理するプロセス管理テーブ
ルPTnと、スワップ処理を制御するプロセススワップ
手段SFとから構成されている。さらに、プロセススワ
ップ手段SFはプロセス管理テーブルPTnを用いてス
ワップインするプロセスを選択するスワップインプロセ
ス選択手段SF1と、プロセス管理テーブルPTnを用
いてスワップアウトするプロセスを選択するスワップア
ウトプロセス選択手段SF2と、プロセスのスワップア
ウトを行うプロセススワップアウト手段SF3と、プロ
セスのスワップインを行うプロセススワップイン手段S
F4とを有する。
It is composed of a process management table PTn that manages processes to be swapped, and a process swap means SF that controls swap processing. Further, the process swapping means SF includes a swap-in process selection means SF1 which selects a process to be swapped in using a process management table PTn, and a swap-out process selection means SF2 which selects a process to be swapped out using a process management table PTn. , a process swap-out means SF3 for swapping out processes, and a process swap-in means S for swapping in processes.
F4.

第2図を参照すると、プロセス管理テーブルPTnは、
経過時間Tnと、プロセス状態情報Snと、全ページ数
PTnと、スワップアウトページ数SPnとを有する。
Referring to FIG. 2, the process management table PTn is
It has elapsed time Tn, process state information Sn, total number of pages PTn, and swap-out page number SPn.

次に9本実施例の動作について説明する。Next, the operation of the ninth embodiment will be explained.

まず、第1図によって処理の流れを説明する。First, the flow of processing will be explained with reference to FIG.

スワップ要求が出されると、プロセススワップ手段SF
はスワップインするプロセスの選択をスワップインプロ
セス選択手段SF1に要求する。スワップインプロセス
選択手段SFIはプロセス管理テーブルPTnのプロセ
ス状態情報Snがスワップアウトとなっているプロセス
の経過時間Tnが最も長いプロセスをスワップインすべ
きプロセスとして選択し、そのスワップアウトページ数
SPnを得る。
When a swap request is issued, the process swap means SF
requests the swap-in process selection means SF1 to select a process to be swapped in. The swap-in process selection means SFI selects the process whose elapsed time Tn is the longest among the processes whose process status information Sn in the process management table PTn indicates swap-out as the process to be swap-in, and obtains the number of swap-out pages SPn. .

次に1プロセススワップ手段SFはスワップアウトプロ
セス選択手段SF2によりスワップインするプロセスが
必要とする物理ページを確保するために、プロセス管理
テーブルPTnのプロセス状態情報Snがスワップアウ
トとなっているプロセスで、かつそのプロセスのすべて
の物理ページ数がスワップアウトページ数と等しくなく
、かつ上述のスワップインプロセス選択手段SFIによ
って選択されていないプロセスを探す。このようなプロ
セスが存在しない場合には、スワップアウトプロセス選
択手段SF2は1プロセス管理テーブルPTnのプロセ
ス状態情報Snがスワップインとなっているプロセスの
経過時間Tnが最も長いプロセスをスワップアウトすべ
きプロセスとして選択する。
Next, the 1-process swap means SF is a process whose process state information Sn in the process management table PTn is set to swap out, in order to secure the physical page required by the process to be swapped in by the swap-out process selection means SF2. A search is made for a process in which the number of all physical pages of that process is not equal to the number of swap-out pages, and which has not been selected by the above-mentioned swap-in process selection means SFI. If such a process does not exist, the swap-out process selection means SF2 selects the process that should be swapped out by selecting the process whose elapsed time Tn is the longest among the processes whose process state information Sn in the process management table PTn indicates swap-in. Select as.

次に、プロセススワップアウト手段SF3は。Next, the process swapout means SF3.

スワップアウトプロセス選択手段SF2で選択されたプ
ロセスに属する物理ページのうち、スワップインプロセ
ス選択手段SFIで選択されたプロセスをスワップイン
するのに必要とされる物理ページのみをページスワップ
アウト手段SOFによりスワップアウトし、スワップア
ウトしたプロセスに対応するプロセス管理テーブルの経
過時間を“0′に、プロセス状態情報をスワップアウト
されていることを示す”OU T’にそれぞれ更新し。
Of the physical pages belonging to the process selected by the swap-out process selection means SF2, only the physical pages required to swap in the process selected by the swap-in process selection means SFI are swapped by the page swap-out means SOF. The elapsed time in the process management table corresponding to the swapped out process is updated to "0", and the process status information is updated to "OUT" indicating that the process has been swapped out.

スワップアウトページ数にスワップアウトしたペジ数を
加算する。
Add the number of swapped out pages to the number of swapped out pages.

物理ページのスワップアウトが終了すると2次にプロセ
ススワップイン手段SF4は、スワップインプロセス選
択手段SF1で選択されたプロセスのページをページス
ワップイン手段SIFを用いて物理ページにスワップイ
ンし、スワ・ツブインしたプロセスに対応するプロセス
管理テーブルの経過時間を“0″に、プロセス状態情報
をスワ・ノブインされていることを示す”IN’に1 
スワップアウトページ数を“0゛にそれぞれ更新する。
When the swap-out of the physical page is completed, the secondary process swap-in means SF4 swaps in the page of the process selected by the swap-in process selection means SF1 to the physical page using the page swap-in means SIF, and swaps in the page of the process selected by the swap-in process selection means SF1. The elapsed time of the process management table corresponding to the process that has been updated is set to "0", and the process status information is set to "IN", which indicates that the process has been updated.
Update the number of swap out pages to "0".

次に1本実施例の動作を具体例にそって説明する。具体
例の説明においては、対象とするプロセス管理テーブル
を2個とし、それぞれPTl、PT2とする。
Next, the operation of this embodiment will be explained using a specific example. In the description of a specific example, two target process management tables are assumed to be PTl and PT2, respectively.

第3図は本実施例の初期状態を示す。プロセス管理テー
ブルPTIで示されるプロセスのプロセス状態情報S1
はスワップインされてζ)ることを示す“IN”であり
、スワ・ツブインされて力九らの経過時間T1は“5°
であり、全ページ数TPIは“20“であり、スワ・ノ
ブアウトページ数SP1は0”である。また、プロセス
管理テーブルPT2で示されるプロセスのプロセス状態
情報S2はスワップアウトされていることを示す“OU
T″であり、スワップアウトされてからの経過時間T2
は“9゛であり、全ページ数TP2は“5”であり、ス
ワップアウトページ数SP2は“5@である。
FIG. 3 shows the initial state of this embodiment. Process status information S1 of the process indicated in the process management table PTI
is “IN” indicating that the swap has been swapped in (ζ), and the elapsed time T1 of Rikiku and others after being swapped in is “5°”.
, the total number of pages TPI is "20", and the swapped out page number SP1 is 0". Also, the process state information S2 of the process shown in the process management table PT2 indicates that it has been swapped out. “OU”
T'', and the elapsed time T2 since being swapped out
is "9", the total page number TP2 is "5", and the swap-out page number SP2 is "5@".

スワップ要求が出されると、プロセススワップ手段SF
は、スワップインプロセス選択手段SF1を用いてスワ
ップアウトするプロセスを選択する。スワップインプロ
セス選択手段SFIは、プロセス管理テーブルを参照し
て、プロセス状態情報Snがスワップアウトされている
ことを示す“OUT”のプロセスから次にスワップイン
すべきプロセスとして、プロセス管理テーブルPT2で
示されるプロセスを選ぶ。
When a swap request is issued, the process swap means SF
selects a process to be swapped out using the swap-in process selection means SF1. The swap-in process selection means SFI refers to the process management table and selects the process indicated in the process management table PT2 as the next process to be swapped in from the "OUT" process whose process state information Sn indicates that it has been swapped out. Select the process that will be used.

次に、プロセス管理テーブルPT2で示されるプロセス
をスワップインするために必要な物理メモリを確保する
ために、スワップアウトプロセス選択手段SF2を用い
てスワップアウトするプロセスを選ぶ。スワップアウト
プロセス選択手段SF2は、プロセス管理テーブルを参
照して、スワップアウトするプロセスを選択する。この
例では唯一のスワップイン中のプロセスであるプロセス
管理テーブルPTIで示されるプロセスを選ぶ。
Next, in order to secure the physical memory necessary for swapping in the processes indicated in the process management table PT2, the swap-out process selection means SF2 is used to select a process to be swapped out. The swap-out process selection means SF2 refers to the process management table and selects a process to be swapped out. In this example, the process indicated in the process management table PTI, which is the only swap-in process, is selected.

次に、プロセス管理テーブルPT2で示されるプロセス
をスワップインするために必要なスワ・ノブアウトペー
ジ数SP2の物理ページを確保するために プロセスス
ワップアウト手段SF3を用いてプロセス管理テーブル
PTIで示されるプロセスが使用している物理ページの
中から、スワ・ツブアウトページ数SP2の物理ページ
をスワ・ツブアウトし プロセス管理テーブルPTIの
経過時間T 1を“0”、プロセス状態情報S1を“O
UT” スワップアウトベージ数SPIをスワップアウ
トページ数SP2にそれぞれ更新する。
Next, in order to secure the physical pages of the swap-knob-out page number SP2 necessary for swapping in the process shown in the process management table PT2, the process swap-out means SF3 is used to process the process shown in the process management table PTI. Swap out physical pages with swap out page number SP2 from among the physical pages used by
UT” The number of swap out pages SPI is updated to the number of swap out pages SP2.

次に、プロセススワップイン手段SF4を用いて、プロ
セススワップアウト手段SF3でスワ・ノブアウトした
物理ページにプロセス管理テーブルPT2で示されるプ
ロセスのスワ・ノブアウトしているページをスワップイ
ンし1プロセス管理テーブルPT2の経過時間T2を“
0”、プロセス状態情報S2を’IN’、スワップアウ
トベージ数SP2を“0”にそれぞれ更新する。この状
態を第4図に示す。
Next, the process swap-in means SF4 is used to swap in the swapped-out page of the process indicated in the process management table PT2 to the physical page swapped out by the process swap-out means SF3. The elapsed time T2 of “
0'', the process state information S2 is updated to ``IN'', and the swap out page number SP2 is updated to ``0''. This state is shown in FIG.

次に、一定時間経過後にスワップ要求が出されると プ
ロセススワップ手段SFはスワ・ツブインプロセス選択
手段SFIにスワップインすべきプロセスの選択を要求
する。スワップインプロセス選択手段SFIは、プロセ
ス管理テーブルPTnを参照して、プロセス状態情報S
nがスワ・ノブアウトされていることを示す“OUT”
のプロセスから次にスワップインすべきプロセスとして
、プロセス管理テーブルPTIで示されるプロセスを選
ぶ。
Next, when a swap request is issued after a certain period of time has elapsed, the process swap means SF requests the swap-in process selection means SFI to select a process to be swapped in. The swap-in process selection means SFI refers to the process management table PTn and selects the process state information S.
“OUT” indicating that n is switched out
The process indicated in the process management table PTI is selected as the next process to be swapped in from among the processes in .

次に、プロセス管理テーブルPTIで示されるプロセス
をスワップインするために必要な物理メモリを確保する
ために、スワップアウトプロセス選択手段SF2を用い
てスワップアウトすべきプロセスを選ぶ。スワップアウ
トプロセス選択手段SF2は、プロセス管理テーブルを
参照して、スワップアウトすべきプロセスを選択する。
Next, in order to secure the physical memory necessary for swapping in the process indicated in the process management table PTI, the swap-out process selection means SF2 is used to select the process to be swapped out. The swap-out process selection means SF2 refers to the process management table and selects a process to be swapped out.

この例ではスワップアウト中でかつ全物理ページがスワ
ップアウトされていないプロセスがスワップインプロセ
ス選択手段SFIによりスワップインの対象プロセスと
して選択されているので、唯一のスワップイン中のプロ
セスであるプロセス管理テーブルPT2で示されるプロ
セスを選ぶ。
In this example, the process that is currently being swapped out and for which all physical pages have not been swapped out is selected by the swap-in process selection means SFI as the process to be swapped in, so the process management table is the only process that is being swapped in. Select the process indicated by PT2.

次に、プロセス管理テーブルPTIで示されるプロセス
をスワップインするために必要なスワップアウトページ
数SPIの物理ページを確保するために、プロセススワ
ップアウト手段SF3を用いてプロセス管理テーブルP
T2で示されるプロセスが使用している物理ページの中
から、スワップアウトページ数SP1の物理ページをス
ワップアウトし、プロセス管理テーブルPT2の経過時
間T2を“0゛、プロセス状態情報S2を“OUT” 
 スワップアウトページ数SP2をスワップアウトペー
ジ数SPIにそれぞれ更新する。
Next, in order to secure the physical pages of the swap-out page number SPI necessary for swapping in the process indicated by the process management table PTI, the process swap-out means SF3 is used to secure the physical pages of the process management table PTI.
From among the physical pages used by the process indicated by T2, swap out the physical pages with the swap-out page number SP1, set the elapsed time T2 of the process management table PT2 to "0", and set the process state information S2 to "OUT".
The number of swap-out pages SP2 is updated to the number of swap-out pages SPI.

次に、プロセススワップイン手段SF4を用いて、プロ
セススワップアウト手段SF3でスワップアウトした物
理ページにプロセス管理テーブルPTIで示されるプロ
セスのスワップアウトしているページをスワップインし
、プロセス管理テーブルPTIの経過時間T1を′0”
、プロセス状態情報S1を“IN”、スワップアウトペ
ージ数SPIを°0”にそれぞれ更新する。この状態を
第5図に示す。
Next, using the process swap-in means SF4, the swapped-out page of the process indicated in the process management table PTI is swapped in to the physical page swapped out by the process swap-out means SF3, and the progress of the process management table PTI is swapped in. Time T1 is '0''
, the process state information S1 is updated to "IN", and the number of swap-out pages SPI is updated to "0". This state is shown in FIG.

以上のようにして1本実施例によりプロセスのスワップ
インに必要な物理ページのみを処理の対象として、スワ
ップ処理を行うことができた。
As described above, according to this embodiment, it was possible to perform swap processing by targeting only the physical pages required for swap-in of a process.

[発明の効果] 以上の説明から明らかなように1本発明は、スワップア
ウトの対象をプロセスが使用している全物理ページから
プロセスのスワップインに必要な物理ページのみとする
ことにより、余分なスワップ領域を使用することがなく
、スワップ領域を有効に利用することができる。また、
不必要なデータ転送が行われないため、スワップ処理を
高速化することができる。
[Effects of the Invention] As is clear from the above description, the present invention can swap out only the physical pages necessary for swapping in a process from all the physical pages used by the process, thereby reducing unnecessary The swap area can be used effectively without using the swap area. Also,
Swap processing can be sped up because unnecessary data transfer is not performed.

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

第1図は本発明の一実施例によるスワップ処理方式が適
用されるシステムの構成を示すブロック図、第2図は第
1図中のプロセス管理テーブルの構成を示す図、第3図
から第5図は本実施例において成る時点の状況を示す図
である。 PTn・・・プロセス管理テーブル、Tn・・・経過時
間、Sn・・・プロセス状態情報、TPn・・・全ペー
ジ数、SPn・・・スワップアウトページ数、SOF・
・・ページスワップアウト手段、SIF・・・ページス
ワップイン手段、SF・・・プロセススワップ手段、S
Fl・・・スワップインプロセス選択手段、SF2・・
スワップアウトプロセス選択手段、SF3・・・プロセ
ススワップアウト手段、SF4・・・プロセススワップ
イン手段。 第1図 第2図
FIG. 1 is a block diagram showing the configuration of a system to which a swap processing method according to an embodiment of the present invention is applied, FIG. 2 is a diagram showing the configuration of the process management table in FIG. 1, and FIGS. The figure is a diagram showing the situation at a point in time in this embodiment. PTn...Process management table, Tn...Elapsed time, Sn...Process status information, TPn...Total number of pages, SPn...Number of swap-out pages, SOF.
...Page swap out means, SIF...Page swap in means, SF...Process swap means, S
Fl... Swap-in process selection means, SF2...
Swap-out process selection means, SF3: process swap-out means, SF4: process swap-in means. Figure 1 Figure 2

Claims (1)

【特許請求の範囲】 1、計算機の主記憶装置と補助記憶装置間でプロセスイ
メージの入出力を行うスワップ処理方式において、 経過時間、プロセス状態情報、全ページ数、スワップア
ウトページ数をプロセス毎に格納するプロセス管理テー
ブルと、 物理ページのスワップアウトを行うページスワップアウ
ト手段と、 物理ページのスワップインを行うページスワップイン手
段と、 スワップ要求に応答して、前記プロセス管理テーブルの
前記プロセス状態情報がスワップアウトとなっているプ
ロセスの経過時間が最も長いプロセスをスワップインす
べきプロセスとして選択し、該選択されたプロセスのス
ワップアウトページ数を得るスワップインプロセス選択
手段と、 スワップインするプロセスが必要とする物理ページを確
保するために、前記プロセス管理テーブルの前記プロセ
ス状態情報がスワップアウトとなっているプロセスで、
かつそのプロセスのすべての物理ページ数がスワップア
ウトページ数と等しくなく、かつ前記スワップインプロ
セス選択手段によって選択されていないプロセスを探し
、このようなプロセスが存在しない場合には、前記プロ
セス管理テーブルの前記プロセス状態情報がスワップイ
ンとなっているプロセスの経過時間が最も長いプロセス
をスワップアウトすべきプロセスとして選択するスワッ
プアウトプロセス選択手段と、前記スワップアウトプロ
セス選択手段で選択されたプロセスに属する物理ページ
のうち、前記スワップインプロセス選択手段で選択され
たプロセスをスワップインするのに必要とされる物理ペ
ージのみ前記ページスワップアウト手段によりスワップ
アウトし、該スワップアウトしたプロセスに対応する前
記プロセス管理テーブルの前記経過時間を“0”に、前
記プロセス状態情報をスワップアウトされていることを
示す情報にそれぞれ更新し、前記スワップアウトページ
数にスワップアウトしたページ数を加算するプロセスス
ワップアウト手段と。 物理ページのスワップアウトが終了したとき、前記スワ
ップインプロセス選択手段で選択されたプロセスのペー
ジを前記ページスワップイン手段を用いて物理ページに
スワップインし、該スワップインしたプロセスに対応す
る前記プロセス管理テーブルの前記経過時間を“0”に
、前記プロセス状態情報をスワップインされていること
を示す情報に、前記スワップアウトページ数を“0”に
それぞれ更新するプロセススワップイン手段とを有する
ことを特徴とする必要物理ページのスワップ処理方式。
[Claims] 1. In a swap processing method that inputs and outputs process images between the main memory and auxiliary memory of a computer, elapsed time, process status information, total number of pages, and number of swapped out pages are recorded for each process. a process management table to store; a page swap-out means for swapping out physical pages; a page swap-in means for swapping in physical pages; and in response to a swap request, the process state information in the process management table is A swap-in process selection means for selecting a process that has the longest elapsed time among swap-out processes as a process to be swapped in, and obtaining the number of swap-out pages of the selected process; and a process to be swapped in. In order to secure a physical page for
and the number of all physical pages of that process is not equal to the number of swap-out pages, and the process is not selected by the swap-in process selection means, and if such a process does not exist, the process management table is swap-out process selection means for selecting a process whose elapsed time is the longest among the processes whose process state information indicates swap-in as a process to be swapped out; and a physical page belonging to the process selected by the swap-out process selection means. Of these, only the physical pages required to swap in the process selected by the swap-in process selection means are swapped out by the page swap-out means, and the process management table corresponding to the swapped-out process is swapped out. Process swap-out means for updating the elapsed time to "0", updating the process state information to information indicating that the process has been swapped out, and adding the number of swapped out pages to the number of swapped out pages. When the swap-out of the physical page is completed, the page of the process selected by the swap-in process selection means is swapped in to the physical page using the page swap-in means, and the process management corresponding to the swapped-in process is performed. and process swap-in means for updating the elapsed time in the table to "0", the process state information to information indicating that the process has been swapped in, and the number of swap-out pages to "0". and the required physical page swapping method.
JP1284813A 1989-11-02 1989-11-02 Swap processing method for required physical pages Expired - Fee Related JPH07120317B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP1284813A JPH07120317B2 (en) 1989-11-02 1989-11-02 Swap processing method for required physical pages

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP1284813A JPH07120317B2 (en) 1989-11-02 1989-11-02 Swap processing method for required physical pages

Publications (2)

Publication Number Publication Date
JPH03147156A true JPH03147156A (en) 1991-06-24
JPH07120317B2 JPH07120317B2 (en) 1995-12-20

Family

ID=17683344

Family Applications (1)

Application Number Title Priority Date Filing Date
JP1284813A Expired - Fee Related JPH07120317B2 (en) 1989-11-02 1989-11-02 Swap processing method for required physical pages

Country Status (1)

Country Link
JP (1) JPH07120317B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112363971A (en) * 2020-11-10 2021-02-12 王志平 Super computer architecture implementation method

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112363971A (en) * 2020-11-10 2021-02-12 王志平 Super computer architecture implementation method

Also Published As

Publication number Publication date
JPH07120317B2 (en) 1995-12-20

Similar Documents

Publication Publication Date Title
US3705388A (en) Memory control system which enables access requests during block transfer
KR950012256A (en) Computer system for processing vector data and method thereof
JPH11505653A (en) Operating system for use with protection domains in a single address space
JPS60501824A (en) Demand paging method for a storage processing system that shares multiple address translation buffer storage devices
US5717916A (en) Method for providing an improved fully associative cache memory having a finite state machine and linked list structure
EP0533427A1 (en) Computer memory control system
JPH03147156A (en) Swap processing system for required physical page
US3513446A (en) Data processing system wherein the instruction word contains plural data word addresses
JP3317819B2 (en) Control method for two-port access of single-port RAM
JPH0337748A (en) External storage accessing system utilizing main storage
JPH0216651A (en) Disk cache control system
JP2864496B2 (en) Multi-processing computer
JPS62105586A (en) Provision system for display information
JPH02190968A (en) Vector processor
JP3013993B2 (en) Vector processing method
JPS61112260A (en) Swapping controller for multi-hierarchy memory system
JPH03282756A (en) Asynchronous input/output system
JP3259095B2 (en) Data transfer method
JPS6134643A (en) Buffer control system
JPH03269650A (en) Buffer storage
JPS59165176A (en) Image processor
JPS58220289A (en) Data processor
JPH03129547A (en) Data transfer control system
JPS6367662A (en) Virtual space managing system
JPH01108652A (en) Address conversion system

Legal Events

Date Code Title Description
LAPS Cancellation because of no payment of annual fees