JPH0132539B2 - - Google Patents
Info
- Publication number
- JPH0132539B2 JPH0132539B2 JP59167144A JP16714484A JPH0132539B2 JP H0132539 B2 JPH0132539 B2 JP H0132539B2 JP 59167144 A JP59167144 A JP 59167144A JP 16714484 A JP16714484 A JP 16714484A JP H0132539 B2 JPH0132539 B2 JP H0132539B2
- Authority
- JP
- Japan
- Prior art keywords
- session
- transaction
- time
- swap
- terminal
- 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.)
- Expired
Links
Landscapes
- Memory System Of A Hierarchy Structure (AREA)
Description
【発明の詳細な説明】
(技術分野)
本発明はタイムシエアリングシステムにおける
端末のセツシヨンのスワツピング制御方式に関す
る。DETAILED DESCRIPTION OF THE INVENTION (Technical Field) The present invention relates to a terminal session swapping control method in a time sharing system.
(従来技術)
タイムシエアリングシステム(以下TSSと略
する)においては典型的な場合としては次のよう
に処理が進行する。即ち、端末からユーザがコマ
ンドあるいはデータを投入し、これをセンタのプ
ロセツサに送信する。センタのプロセツサはこれ
をうけて送信されたコマンドあるいはデータに対
する処理を行い、結果を端末に送信する。端末に
表示された結果を端末ユーザが見て次に入力すべ
きコマンド、データを考え、これをキイボードか
ら入力するという処理がくりかえされる。(Prior Art) In a time sharing system (hereinafter abbreviated as TSS), processing typically proceeds as follows. That is, a user inputs a command or data from a terminal and sends it to the processor at the center. The processor at the center processes the transmitted command or data and transmits the results to the terminal. The terminal user looks at the results displayed on the terminal, thinks about the command and data to input next, and inputs this from the keyboard, and the process is repeated.
ここで、センタのプロセツサにコマンド、デー
タが入力され処理を行い、結果の端末への出力を
行うまでをトランザクシヨンと呼ぶ。また、トラ
ンザクシヨンとトランザクシヨンの間、即ち、端
末からの入力待ちの時間をウエイト時間を呼ぶ。
また、一個の端末におけるトランザクシヨンの実
行の実体となるものをセツシヨンと呼ぶ。これは
バツチシステムにおけるジヨブに相当するもので
ある。 Here, the process from inputting commands and data to the processor at the center, processing them, and outputting the results to a terminal is called a transaction. Furthermore, the time between transactions, that is, the time spent waiting for input from the terminal, is called wait time.
Furthermore, the substance of transaction execution at one terminal is called a session. This is equivalent to a job in the batch system.
一個のセツシヨンについてみると前述のように
端末のユーザがセンタのプロセツサからの端末へ
の表示結果を見て、次に入力すべきデータあるい
はコマンドを考えキイボードから入力するまでに
は通常数十秒のオーダの時間がかかるのに対し、
端末から入力されたコマンドに対するセンタのプ
ロセツサの処理は通常数秒以内に完了し、結果が
端末に出力され次の端末からの入力を待つ。従つ
て、センタのプロセツサからみればセツシヨンの
大部分の時間は、端末ユーザによる思考時間およ
びキイボードからの入力のための時間即ちウエイ
ト時間であり、この間、プロセツサの主記憶にセ
ツシヨンのプログラムを存在させることは、計算
機システムの資源を浪費することになるので、一
般にはスワツピングという手法が用いられてい
る。これは、プロセツサでの処理が完了し端末に
結果を表示し、次の入力を待つ状態(以下端末入
力待ち状態とよぶ)になつた時点(以下これをト
ランザクシヨン終了とよぶ)でこのセツシヨンに
属するプログラムを主記憶から二次記憶に追出し
(以下これをスワツプアウトと呼ぶ)端末ユーザ
からの入力が完了し、プロセツサでの処理が可能
になつた時点(以下これをトランザクシヨンの開
始とよぶ)でセツシヨンのプログラムを主記憶に
取込む(以下これをスワツプインと呼ぶ)もので
ある。これにより、各セツシヨンのプログラム
は、プロセツサでの処理を必要とする場合にのみ
主記憶を割当てればよいことになり、主記憶に同
時に割当てることのできる端末数(セツシヨン
数)よりも多くの端末を同時にサポートすること
が可能となる。 Regarding a single session, as mentioned above, it usually takes several tens of seconds for the terminal user to look at the results displayed on the terminal from the center processor, think about the next data or command to input, and input it from the keyboard. While ordering takes time,
Processing by the center processor in response to commands input from the terminal is normally completed within a few seconds, the result is output to the terminal, and the next input from the terminal is awaited. Therefore, from the perspective of the center processor, most of the session time is wait time for the terminal user to think and input from the keyboard, and during this time the session program is kept in the main memory of the processor. This wastes the resources of the computer system, so a technique called swapping is generally used. This is done when the processing in the processor is completed, the result is displayed on the terminal, and the state is waiting for the next input (hereinafter referred to as the terminal input waiting state) (hereinafter referred to as the end of the transaction). The program to which it belongs is expelled from main memory to secondary memory (hereinafter referred to as swapout), and when the input from the terminal user is completed and processing by the processor is possible (hereinafter referred to as the start of a transaction). The session program is taken into main memory (hereinafter referred to as a swap-in). As a result, programs in each session only need to allocate main memory when they require processing by the processor. It is possible to support both at the same time.
このようにトランザクシヨンの開始を契機とし
てスワツプインを行い、トランザクシヨンの終了
を契機としてスワツプアウトを行うことにより主
記憶を効率的に使用し、多数の端末をサポートす
ることはTSSにおいて通常行われている。 In this way, it is common practice in TSS to use main memory efficiently and support a large number of terminals by performing swap-in when a transaction starts and swap-out when the transaction ends. .
しかしながら、キイボードから入力する通常の
端末を使用している場合には、トランザクシヨン
の終了から開始までに思考およびこれに続くキイ
ボード操作による入力が必要であるのでセツシヨ
ンがスワツプアウトされてから再びスワツプイン
するまでの間に一般的には充分他のセツシヨンを
実行するだけの時間的余祐があるのに対して、た
とえば端末側のフロツピイデイスクから連続的に
データをセンタ側に入力するような場合には、プ
ロセツサが入力要求を出してから(トランザクシ
ヨン終了)実際に端末からデータが入つてくるま
で(トランザクシヨンの開始)の時間が非常に短
かいために従来のスワツピング制御方式ではトラ
ンザクシヨンの終了でスワツプアウトを行うと直
ちに再びスワツプインが必要となり、これは、主
記憶の空きスペースを生み出さないだけでなく二
次記憶用のデイスクの使用率を上昇させこれがシ
ステム全体のスループツトを低下させる要因とな
るという欠点がある。 However, if you are using a normal terminal that inputs input from the keyboard, thinking and subsequent keyboard input are required between the end of the transaction and the start of the transaction. In general, there is enough time to execute other sessions during this time, but for example, when data is continuously input to the center from a floppy disk on the terminal side, Because the time from when the processor issues an input request (transaction end) until data actually comes in from the terminal (transaction start) is very short, conventional swapping control methods do not allow the transaction to end. If you swap out, you will immediately need to swap in again, which not only does not free up space in main memory, but also increases the usage rate of the secondary storage disk, which reduces the throughput of the entire system. There are drawbacks.
このため、たとえば各セツシヨンのウエイト時
間を測定し、これがあるしきい値よりも小さい場
合には、これに続くウエイト時間も短いものと予
想して、トランザクシヨン終了時のスワツプアウ
トを行わないようにすればよい。しかしながら、
たとえばフロツピイデイスク7から入力している
間に操作者が端末を離れて、入力が完了した後長
時間端末の操作を行わないようなケースが発生す
ると、このセツシヨンは長時間実行すべき処理が
ないにもかかわらず主記憶の一部を専有し、この
ために全体のスループツトを下げるとともに他の
セツシヨンの応答時間を引延ばす原因ともなると
いう欠点がある。 For this reason, for example, you can measure the wait time of each session, and if it is smaller than a certain threshold, you can assume that the subsequent wait time will be short and avoid swapping out at the end of the transaction. Bye. however,
For example, if a case occurs where the operator leaves the terminal while inputting data from the floppy disk 7 and does not operate the terminal for a long time after completing the input, this session is a process that should be executed for a long time. Although it is not available, it occupies a part of the main memory, which has the disadvantage of lowering the overall throughput and prolonging the response time of other sessions.
(発明の目的)
本発明は、トランザクシヨンの終了から開始ま
での待ち時間を各セツシヨン毎に測定し、測定さ
れた時間が設定された閾値と比較して小さい場合
にはこれに続くトランザクシヨンにおいてもウエ
イト時間が短いものとみなし、このセツシヨンス
ワツプアウトの要求を出さないようにすることに
より、端末からの連続データ入力時の場合には不
要なスワツピングを省きスワツピングオーバヘツ
ドを減らさせるようにするとともに、一定周期毎
に、その周期におけるセツシヨンで使用したプロ
セツサ時間を調べ、一周期にわたつて全く処理の
行われていないセツシヨンに関しては、ウエイト
時間の予測の誤りとしてこのセツシヨンをスワツ
プアウトすることにより、主記憶の有効利用をは
かろうとするものである。(Objective of the Invention) The present invention measures the waiting time from the end to the start of a transaction for each session, and if the measured time is smaller than a set threshold value, the wait time from the end to the start of the transaction is By assuming that the wait time is short and not issuing a request for swapping out this session, unnecessary swapping can be omitted and swapping overhead can be reduced when continuous data is input from the terminal. At the same time, at regular intervals, the processor time used by the sessions in that cycle is checked, and if a session has not been processed at all in one cycle, this session is swapped out as an error in the wait time prediction. This aims to make effective use of main memory.
従つて本発明の第1の目的は連続入力における
不要なスワツピングの省略による連続入力速度の
向上にあり本発明の第2の目的は、スワツピング
のオーバーヘツドの減少によりTSS全体として
高いスループツトを可能とすることにあり、本発
明の第3の目的は前記のウエイト時間の予測によ
るスワツピングの省略を行う場合において、予測
がはずれた場合においてもこれがシステムのスル
ープツト、応答時間に影響を与えないような改善
されたTSSのスワツピング制御方式を提供する
ことにある。 Therefore, the first object of the present invention is to improve the continuous input speed by omitting unnecessary swapping in continuous input, and the second object of the present invention is to increase the throughput of the TSS as a whole by reducing the swapping overhead. A third object of the present invention is to provide an improvement in which when swapping is omitted by predicting the wait time, even if the prediction is incorrect, this does not affect system throughput and response time. The purpose of the present invention is to provide a swapping control method for TSS.
(発明の構成)
本発明の方式は端末からの入力待ちを契機とし
て前記端末に対応するセツシヨンのスワツプアウ
トを行ない、前記端末からのデータ入力を契機と
して前記端末に対応するセツシヨンのスワツプイ
ンを行なうタイムシエアリングシステムのスワツ
ピング制御方式において、セツシヨンにおける先
行する第1のトランザクシヨンの終了から前記第
1のトランザクシヨンに続く第2のトランザクシ
ヨンの開始までのウエイト時間を測定するウエイ
ト時間測定手段と、前記測定されたウエイト時間
と予め定めた値とを比較し結果を保持する比較手
段と、前記比較手段の比較結果が前記測定された
ウエイト時間が前記予め定めた値より小さいとき
には前記第2のトランザクシヨンの終了時にスワ
ツプアウトを禁止するスワツプアウト禁止手段
と、一定周期毎にスワツプイン状態にある各セツ
シヨンの前記定周期内でのプロセツサ使用時間を
調べ前記使用時間が0で前記スワツプアウト禁止
手段によりスワツプアウトが禁止されているセツ
シヨンについてはスワツプアウトを指示するプロ
セツサ使用時間チエツクスワツプアウト指示手段
とを含んで構成される。(Structure of the Invention) The method of the present invention is a time sharing system in which a session corresponding to the terminal is swapped out when waiting for an input from the terminal, and a session corresponding to the terminal is swapped in when data input from the terminal is triggered. In a swapping control method for a ring system, a wait time measuring means for measuring a wait time from the end of a preceding first transaction in a session to the start of a second transaction following the first transaction; comparing means for comparing the measured wait time with a predetermined value and holding the result; and when the comparison result of the comparison means is smaller than the predetermined value, the second transaction is Swap-out prohibition means for prohibiting swap-out upon termination, and checking the processor usage time within the fixed cycle of each session in the swap-in state at regular intervals, and if the usage time is 0, swap-out is prohibited by the swap-out prohibition means. The session includes processor usage time check swap-out instructing means for instructing swap-out.
(実施例)
次に本発明の実施例について図面を参照して説
明する。(Example) Next, an example of the present invention will be described with reference to the drawings.
第1図は本発明の一実施例を示すブロツク図で
ある。第1図のスワツピング制御方式はスワツピ
ング制御テーブル1と、セツシヨン番号レジスタ
2と、タイマ3と、減算回路4と、比較回路5
と、しきい値レジスタ6と、トランザクシヨン制
御部7と、スワツピング実行制御部8と、セツシ
ヨン監視部9と、割込タイマ10と、比較回路1
1とから構成される。 FIG. 1 is a block diagram showing one embodiment of the present invention. The swapping control system shown in FIG. 1 includes a swapping control table 1, a session number register 2, a timer 3, a subtraction circuit 4, and a comparison circuit 5.
, a threshold register 6 , a transaction control section 7 , a swapping execution control section 8 , a session monitoring section 9 , an interrupt timer 10 , and a comparison circuit 1
1.
スワツピング制御テーブル1は各セツシヨンに
対してスワツピングを行うか否かを制御するため
のものである。このテーブルは各セツシヨンに対
して1エントリをもち各エントリは前回のトラン
ザクシヨンの終了した時刻を記憶するための時刻
フイールドXTIMEおよびこのセツシヨンでスワ
ツプアウトを行うか否かを示すフラグフイールド
Fおよび前回のチエツク周期におけるセツシヨン
のプロセツサ使用時間を保持する時間フイールド
PTIMEをもつ。このスワツピング制御テーブル
1は、トランザクシヨン開始/終了の発生したセ
ツシヨンの番号jおよびセツシヨン監視部9の発
生するセツシヨン番号jによりアドレスされる。
セツシヨン番号レジスタ2はトランザクシヨン開
始/終了の発生したセツシヨン番号jを保持す
る。 Swapping control table 1 is for controlling whether or not swapping is performed for each session. This table has one entry for each session, and each entry contains a time field XTIME to remember the time the previous transaction ended, a flag field F to indicate whether or not to swap out for this session, and a previous check field. A time field that holds the session's processor usage time in a cycle.
Has PTIME. This swapping control table 1 is addressed by the session number j in which a transaction start/end occurs and the session number j generated by the session monitoring section 9.
The session number register 2 holds the session number j where the transaction start/end occurred.
現在の時刻を保持するタイマ3の値は減算回路
4の一方の入力に印加されるとともにスワツピン
グ制御テーブル1の時刻フイールドXTIMEにも
印加されている。同じく時刻フイールドXTIME
の出力は前記減算回路4のもう一方の入力に印加
されこの出力は、比較回路5の一方の入力に印加
されている。しきい値レジスタ6は、ウエイト時
間のしきい値を保持するレジスタで、その出力は
比較回路5のもう一方の入力に印加されている。
比較回路5の出力はトランザクシヨン制御部7に
印加されている。スワツピング制御テーブル1の
時間フイールドPTIMEの出力は比較回路11の
一方の入力に印加されている。比較回路11の他
の入力には、各セツシヨンの現時点でのプロセツ
サ時間が印加される。このプロセツサ時間は、プ
ロセツサで実用中の全セツシヨンの状態を管理す
るセツシヨン制御テーブル(図示せず)から読み
出される。セツシヨン制御テーブルの各エントリ
には対応するセツシヨンがスワツプインされてい
る状態か否かを示す情報、および対応するセツシ
ヨンが現在までに使用したプロセツサ時間の累積
CTIMEが格納されている。トランザクシヨン制
御部7は、各セツシヨンにおけるトランザクシヨ
ンの開始、終了のイベント通知XS,XTを受け、
各セツシヨンにおけるウエイト時間を測定し、し
きい値との比較を行うことにより、トランザクシ
ヨン終了時でのスワツプアウト開始でのスワツプ
インを行うか否かを決定するための制御部であ
る。スワツピング実行制御部8はトランザクシヨ
ン制御部7からの指令により、実際のスワツプイ
ン、スワツプアウトを行うための制御部である。
割込みタイマ10は、一定時間(ここでは30秒と
する)毎にセツシヨン監視部9を起動するための
タイマである。セツシヨン監視部9は、一定時間
毎に、各セツシヨンについてその状態およびプロ
セツサ使用時間を調べ、ウエイト時間の測定の誤
りを検出するための制御部である。 The value of the timer 3, which holds the current time, is applied to one input of the subtraction circuit 4, and is also applied to the time field XTIME of the swapping control table 1. Also the time field XTIME
The output of is applied to the other input of the subtraction circuit 4, and this output is applied to one input of the comparison circuit 5. The threshold register 6 is a register that holds the threshold value of the wait time, and its output is applied to the other input of the comparator circuit 5.
The output of the comparison circuit 5 is applied to the transaction control section 7. The output of the time field PTIME of the swapping control table 1 is applied to one input of the comparison circuit 11. The other input of comparison circuit 11 receives the current processor time of each session. This processor time is read from a session control table (not shown) that manages the status of all sessions in use by the processor. Each entry in the session control table contains information indicating whether the corresponding session is swapped in or not, and the cumulative amount of processor time used by the corresponding session to date.
CTIME is stored. The transaction control unit 7 receives event notifications X S and X T of transaction start and end in each session,
This is a control unit that measures the wait time in each session and compares it with a threshold value to determine whether or not to perform swap-in at the start of swap-out at the end of a transaction. The swapping execution control unit 8 is a control unit that performs actual swap-in and swap-out according to commands from the transaction control unit 7.
The interrupt timer 10 is a timer for activating the session monitoring section 9 at fixed intervals (here, 30 seconds). The session monitoring unit 9 is a control unit that checks the status and processor usage time of each session at regular intervals to detect errors in wait time measurement.
第2図は第1図の動作フローチヤートである。
第2図aはトランザクシヨン開始時の動作を、第
2図bはトランザクシヨン終了時の動作を、第2
図cは周期的なトランザクシヨン監視の動作を示
す。 FIG. 2 is an operational flowchart of FIG. 1.
Figure 2a shows the operation at the start of a transaction, Figure 2b shows the operation at the end of the transaction, and Figure 2b shows the operation at the end of the transaction.
Figure c shows the operation of periodic transaction monitoring.
次に第1図および第2図により本実施例の動作
を説明する。あるセツシヨンjにおいて端末入力
が完了しプロセツサが処理を行える状態になつた
時点、即ち、トランザクシヨン開始時には、ま
ず、この通知XSがトランザクシヨン制御部7に
印加されるとともに、セツシヨンの番号jがセツ
シヨン番号レジスタ2に印加される。トランザク
シヨン制御部7はこの通知をうけて以下の処理を
行う。即ち、まず、セツシヨン番号jをセツシヨ
ン番号レジスタ2に格納しこのあと、スワツピン
グ制御テーブル1のセツシヨン番号jに対応する
エントリおよびタイマ3を読出す。このとき読出
された時刻フイールドXTIMEの値およびタイマ
3の値は減算回路4に印加され、結果が比較回路
5に印加される。この比較回路5によりしきい値
レジスタ6の値と比較される。なお、フラグフイ
ールドFjの値は、一時的に退避される(退避場所
は図示せず)。比較の結果しきい値の方が大のと
き、即ち、トランザクシヨンの終了から開始まで
のウエイト時間がしきい値よりも短い場合には次
のトランザクシヨン終了時にスワツプアウトを禁
止すべきであることを示すためにスワツピング制
御テーブル1のセツシヨンjに対応するフラグフ
イールドFjに“1”をセツトする。そうでない場
合には値“0”をセツトする。 Next, the operation of this embodiment will be explained with reference to FIGS. 1 and 2. When terminal input is completed in a certain session j and the processor is ready for processing, that is, at the start of a transaction, this notification X S is first applied to the transaction control unit 7, and the session number j is Applied to session number register 2. The transaction control unit 7 receives this notification and performs the following processing. That is, first, the session number j is stored in the session number register 2, and then the entry corresponding to the session number j in the swapping control table 1 and the timer 3 are read out. The value of the time field XTIME and the value of the timer 3 read at this time are applied to a subtraction circuit 4, and the result is applied to a comparison circuit 5. Comparison circuit 5 compares the value with threshold value register 6 . Note that the value of the flag field Fj is temporarily saved (the save location is not shown). As a result of the comparison, if the threshold is larger, that is, if the wait time from the end of the transaction to the start is shorter than the threshold, swap out should be prohibited at the end of the next transaction. In order to indicate this, "1" is set in the flag field Fj corresponding to the session j of the swapping control table 1. Otherwise, the value "0" is set.
このあと、先に読出しておいたフラグフイール
ドFjの値を調べ、これが“0”即ち、前回のトラ
ンザクシヨン終了でスワツプアウトが行われてい
る場合にはこのセツシヨンのスワツプインを行
う。このスワツプインはスワツピング実行制御部
8に指令を出すことにより行われる。先に読出し
ておいたフラグフイールドFjの値が“1”の場
合、即ち、スワツプアウトが行なわれていない場
合にはスワツプインは不要であるので、トランザ
クシヨン制御のための処理を終了する。 After this, the value of the flag field Fj that was read earlier is checked, and if this is "0", that is, swap-out has been performed at the end of the previous transaction, swap-in of this session is performed. This swap-in is performed by issuing a command to the swapping execution control section 8. If the value of the previously read flag field Fj is "1", that is, if swap-out has not been performed, swap-in is not necessary, and the processing for transaction control ends.
トランザクシヨン終了時には開始時と同様にト
ランザクシヨン終了通知XTがトランザクシヨン
制御部7に印加されセツシヨン番号jがセツシヨ
ン番号レジスタ2にセツトされ次にタイマ3の値
を読出し、これをスワツピング制御テーブル1の
対応する時刻フイールドXTIMEjに格納する。 At the end of the transaction, a transaction end notification X T is applied to the transaction control unit 7, the session number j is set in the session number register 2, and the value of the timer 3 is read out and stored in the swapping control table 1. is stored in the corresponding time field XTIMEj.
このあとフラグフイールドFjを読出し、“1”
であるならば、即ち、前回のウエイト時間がしき
い値よりも小である場合にはスワツプアウトは行
わずにトランザクシヨン制御処理を終了する。Fj
の値が“0”である場合には対応するセツシヨン
のスワツプアウトを行う。 After this, read the flag field Fj and set it to “1”
If so, that is, if the previous wait time is smaller than the threshold value, the transaction control processing is ended without swapping out. Fj
If the value of is "0", the corresponding session is swapped out.
次にウエイト時間の予測の誤りの検出のための
処理を説明する。 Next, a process for detecting errors in waiting time prediction will be explained.
割込みタイマ10により一定時間おきにセツシ
ヨン監視部9に通知が来ると、セツシヨン監視部
9は次の動作を行う。 When the interrupt timer 10 sends a notification to the session monitoring section 9 at regular intervals, the session monitoring section 9 performs the following operations.
まず、現在端末接続中であるすべてのセツシヨ
ンについて次の処理を行う。即ち、セツシヨン制
御テーブルの対応するエントリを読みこのセツシ
ヨンがスワツプインされている状態であるかどう
かを調べる。スワツプインの状態である場合に
は、スワツピング制御テーブル1の対応するエン
トリを読出し、読出された時間フイールド
PTIMEjの値、即ち、前回の割込みの時点におけ
るプロセツサ時間と前記セツシヨン制御テーブル
の蓄積時間のフイールドCTIMEの値即ち現時点
でのプロセツサ時間を比較回路11により比較す
る。このとき時間フイールドPTIMEの値が無効
であるかどうかを調べ、無効である場合には不一
致とみなす。 First, the following processing is performed for all sessions that are currently connected to terminals. That is, it reads the corresponding entry in the session control table to determine whether this session is swapped in. If it is in the swap-in state, read the corresponding entry in swapping control table 1 and set the read time field.
A comparison circuit 11 compares the value of PTIMEj, that is, the processor time at the time of the previous interrupt, and the value of the field CTIME of the accumulation time of the session control table, that is, the processor time at the present time. At this time, it is checked whether the value of the time field PTIME is invalid, and if it is invalid, it is regarded as a mismatch.
値が一致した場合、即ち、前回の割込み時から
このセツシヨンに関する処理がプロセツサにおい
て実行されていない場合には、スワツピング制御
テーブル1のフラグフイールドFを調べこれが
“1”である場合、即ち、ウエイト時間が短いと
の予想により、スワツプアウトが省略された場合
には、こ予想が誤りであつたと判断し、このセツ
シヨンのスワツプアウトをスワツピング実行制御
部8に指令するとともに、スワツピング制御テー
ブル1の時間フイールドに、蓄積時間フイールド
CTIMEの値をセツトし、更新する。不一致の場
合には、PTIMEの更新を行う。スワツプイン状
態でない場合には時間フイールドPTIMEの値が
次のチエツクにおいて無効であることを示すため
のフラグを時間フイールドPTIMEにセツトす
る。 If the values match, that is, if no processing related to this session has been executed in the processor since the previous interrupt, check the flag field F of the swapping control table 1. If it is "1", that is, the wait time is If the swap-out is omitted due to the prediction that the session will be short, it is determined that this prediction was wrong, and the swapping execution control unit 8 is instructed to swap out this session, and the time field of the swapping control table 1 is written as follows. Accumulation time field
Set and update the value of CTIME. If there is a mismatch, update PTIME. If the swap-in state is not established, a flag is set in the time field PTIME to indicate that the value of the time field PTIME is invalid at the next check.
本実施例の説明においては説明を簡単にするた
めに本発明の主旨と直接関係のな部分については
説明を省略してある。また、トランザクシヨン制
御部あるいはスワツピング制御部セツシヨン監視
部、セツシヨン制御テーブルについても、その詳
細な実現方法については説明を省略しているが、
これらについては、従来知られている方法で実現
可能である。 In the description of this embodiment, in order to simplify the explanation, descriptions of parts that are not directly related to the gist of the present invention are omitted. Furthermore, detailed explanations of how to implement the transaction control unit, swapping control unit, session monitoring unit, and session control table are omitted;
These can be realized by conventionally known methods.
また、本発明が実施例の構成に制限されるもの
でないことは明らかであり、たとえばセツシヨン
番号レジスタ2、しきい値レジスタ6等は必ずし
もレジスタとして特別のハードウエアを用意する
必要はなく、主記憶上に格納エリアをとることも
可能である。減算回路4、比較回路5等について
も同様であり、上記のスワツピングの制御のため
の専用ハードウエアを必ずしも設ける必要のない
ことは明らかであろう。 It is clear that the present invention is not limited to the configuration of the embodiment. For example, the session number register 2, the threshold register 6, etc. do not necessarily need to be provided with special hardware as registers, and are stored in the main memory. It is also possible to have a storage area above. The same applies to the subtraction circuit 4, the comparison circuit 5, etc., and it is clear that it is not necessarily necessary to provide dedicated hardware for controlling the above-mentioned swapping.
(発明の効果)
本発明にはウエイト時間を各セツシヨン毎に測
定し、このウエイト時間が設定されたしきい値よ
り小さい場合にはこのセツシヨンのスワツプアウ
トを禁止するとともに、前記スワツプアウト禁止
が誤りの場合においても一定周期毎にセツシヨン
で使用したプロセツサ時間を調べることにより前
記誤りを修正し、システムのスループツトを格段
に向上できるという効果がある。(Effects of the Invention) The present invention measures the wait time for each session, and if the wait time is smaller than a set threshold value, the swap-out of this session is prohibited, and if the swap-out prohibition is erroneous, the swap-out of this session is prohibited. Also, by checking the processor time used in a session at regular intervals, the errors can be corrected and the throughput of the system can be significantly improved.
第1図は本発明の一実施例を示すブロツク図、
第2図a,bおよびcは第1図の動作を示すフロ
ーチヤートである。
1……スワツピング制御テーブル、2……セツ
シヨン番号レジスタ、3……タイマ、4……減算
回路、5……比較回路、6……しきい値レジス
タ、7……トランザクシヨン制御部、8……スワ
ツピング実行制御部、9……セツシヨン監視部、
10……割込みタイマ。
FIG. 1 is a block diagram showing one embodiment of the present invention;
2a, b and c are flowcharts showing the operation of FIG. 1. DESCRIPTION OF SYMBOLS 1... Swapping control table, 2... Session number register, 3... Timer, 4... Subtraction circuit, 5... Comparison circuit, 6... Threshold register, 7... Transaction control section, 8... Swapping execution control unit, 9... session monitoring unit,
10...Interrupt timer.
Claims (1)
対応するセツシヨンのスワツプアウトを行い同じ
く前記端末からのデータ入力を契機として前記端
末に対応するセツシヨンのスワツプインを行なう
タイムシエアリングシステムのスワツピング制御
方式において、セツシヨンにおける先行する第1
のトランザクシヨンの終了から前記第1のトラン
ザクシヨンに続く第2のトランザクシヨンの開始
までのウエイト時間を測定するウエイト時間測定
手段と、前記測定されたウエイト時間と予め定め
た値とを比較し結果を保持する比較手段と、前記
比較手段の比較結果が前記測定されたウエイト時
間が前記予め定めた値より小さいときには前記第
2のトランザクシヨンの終了時にスワツプアウト
を禁止するスワツプアウト禁止手段と、一定周期
毎にスワツプイン状態にある各セツシヨンの前記
定周期内でのプロセツサ使用時間を調べ前記使用
時間が0で前記スワツプアウト禁止手段によりス
ワツプアウトが禁止されているセツシヨンについ
てはスワツプアウトを指定するプロセツサ使用時
間チエツクスワツプアウト指示手段とを含むこと
を特徴とするスワツピング制御方式。1 In a swapping control method of a time sharing system, a session corresponding to the terminal is swapped out when waiting for an input from the terminal, and a session corresponding to the terminal is swapped in when data input from the terminal is triggered. the first preceding in
a wait time measuring means for measuring a wait time from the end of a transaction to the start of a second transaction following the first transaction; and a result of comparing the measured wait time with a predetermined value. swap-out prohibition means for inhibiting swap-out at the end of the second transaction if the comparison result of the comparison means is smaller than the predetermined value; Checks the processor usage time within the fixed cycle for each session in the swap-in state and specifies swap-out for sessions whose usage time is 0 and swap-out is prohibited by the swap-out prohibition means. 1. A swapping control method comprising: out instruction means.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP59167144A JPS6145345A (en) | 1984-08-09 | 1984-08-09 | Swapping control system |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP59167144A JPS6145345A (en) | 1984-08-09 | 1984-08-09 | Swapping control system |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JPS6145345A JPS6145345A (en) | 1986-03-05 |
| JPH0132539B2 true JPH0132539B2 (en) | 1989-07-05 |
Family
ID=15844234
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP59167144A Granted JPS6145345A (en) | 1984-08-09 | 1984-08-09 | Swapping control system |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPS6145345A (en) |
Families Citing this family (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US6038571A (en) * | 1996-01-31 | 2000-03-14 | Kabushiki Kaisha Toshiba | Resource management method and apparatus for information processing system of multitasking facility |
Family Cites Families (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JPS58188381A (en) * | 1982-04-26 | 1983-11-02 | Fujitsu Ltd | Controlling system of logical roll-in/out |
-
1984
- 1984-08-09 JP JP59167144A patent/JPS6145345A/en active Granted
Also Published As
| Publication number | Publication date |
|---|---|
| JPS6145345A (en) | 1986-03-05 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| JPS6145345A (en) | Swapping control system | |
| JPS58181160A (en) | Controlling system of emergency operation | |
| JPS6158054A (en) | Run away detection of program | |
| JPS6336023B2 (en) | ||
| JPH0120455B2 (en) | ||
| JP2617984B2 (en) | Central processing unit test method | |
| JP2871429B2 (en) | Processor with runaway monitoring function | |
| JPS61208549A (en) | Time-out monitor system | |
| JPS6128144A (en) | Executing device of tracing | |
| JPS62278642A (en) | Retrial control system | |
| JP2684966B2 (en) | I/O processor debug unit | |
| JPS61216051A (en) | Control system for storage device access | |
| JPH05233359A (en) | Debugging device | |
| JPS6259818B2 (en) | ||
| JPS61241843A (en) | Information processor | |
| JPH05257749A (en) | Program-runaway detector | |
| JPS6148044A (en) | Diagnosis method for processing equipment | |
| JPH05216701A (en) | Recovery time adjusting circuit for input/output instruction | |
| JPH05197593A (en) | Loop/stall monitor device for application program | |
| JPS5935250A (en) | Program controller | |
| JPH0635757A (en) | CPU abnormality detection device | |
| JPS6362773B2 (en) | ||
| JPH0628218A (en) | Microcomputer program development support device | |
| JPH05274173A (en) | Pseudo fault setting system | |
| JPH04347729A (en) | Interruption waiting processing system in information processor |