Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
JPH0754497B2 - Method for controlling a shared input/output device - Google Patents
[go: Go Back, main page]

JPH0754497B2 - Method for controlling a shared input/output device - Google Patents

Method for controlling a shared input/output device

Info

Publication number
JPH0754497B2
JPH0754497B2 JP26064987A JP26064987A JPH0754497B2 JP H0754497 B2 JPH0754497 B2 JP H0754497B2 JP 26064987 A JP26064987 A JP 26064987A JP 26064987 A JP26064987 A JP 26064987A JP H0754497 B2 JPH0754497 B2 JP H0754497B2
Authority
JP
Japan
Prior art keywords
request
priority
output
client
input
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 - Lifetime
Application number
JP26064987A
Other languages
Japanese (ja)
Other versions
JPH01102672A (en
Inventor
滋 塩谷
秀樹 樋浦
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.)
Fuji Electric Co Ltd
Original Assignee
Fuji Electric Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Fuji Electric Co Ltd filed Critical Fuji Electric Co Ltd
Priority to JP26064987A priority Critical patent/JPH0754497B2/en
Publication of JPH01102672A publication Critical patent/JPH01102672A/en
Publication of JPH0754497B2 publication Critical patent/JPH0754497B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/14Handling requests for interconnection or transfer

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Bus Control (AREA)

Description

【発明の詳細な説明】 (産業上の利用分野) 本発明は共有入出力装置の制御方法にかかり、詳しく
は、個別かつ一時点では最も優先度の高い唯一の入出力
要求を出力し、その処理完了までは新たな入出力要求を
出力しないマイクロプロセッサ等の複数の独立した装置
(以下、クライアントという)が入出力装置を共有する
システムにおいて、各クライアントからの複数の入出力
要求が競合した場合にこれらの入出力要求を優先順序制
御するための制御方法に関する。
[Detailed Description of the Invention] (Industrial Application Field) The present invention relates to a control method for a shared input/output device, and more particularly to a control method for controlling the priority of input/output requests when multiple input/output requests from each client conflict in a system in which an input/output device is shared by multiple independent devices (hereinafter referred to as clients) such as microprocessors, which individually and at a given time output only one input/output request with the highest priority and do not output a new input/output request until the processing of the previous request is completed.

(従来の技術) 従来、この種の入出力装置の共有システムにおいて、各
クライアントからの複数の入出力要求が短時間のうちに
競合した場合には、これらの要求の優先度に応じて入出
力要求を制御する優先順序制御方式が採用されている。
(Prior Art) Conventionally, in this type of shared input/output device system, when multiple input/output requests from clients conflict within a short period of time, a priority control method has been adopted to control the input/output requests according to the priority of these requests.

すなわち、第3図において、100は共有入出力装置、20
0,300,400は共有入出力装置100に対して個別に、一時点
で唯一の入出力要求を出力し、その要求に対応する処理
が完了するまでは新たな入出力要求を出力しないマイク
ロプロセッサの如きクライアントである。これらのクラ
イアント200,300,400は、共有入出力装置100対して入出
力要求を行う際に、現行の要求201,301,401にその優先
度21,31,41をそれぞれ付加して入出力要求210,310,410
を出力している。
In FIG. 3, 100 is a shared input/output device, 20
Each of the clients 200, 300, and 400 is a microprocessor-like client that individually outputs only one I/O request at a time to the shared I/O device 100 and does not output a new I/O request until the processing corresponding to that request is completed. When making an I/O request to the shared I/O device 100, the clients 200, 300, and 400 add their priorities 21, 31, and 41 to the current request 201, 301, and 401, respectively, and output the I/O requests 210, 310, and 410.
is output.

そして共有入出力装置100内のスケジューラ101は、前記
優先度21,31,41に基いて入出力要求210,310,410のスケ
ジューリングを行っており、仮りに優先度21が最も高
く、以下、31,41の順である場合には、要求201→301→4
01の順のスケジュールに従って入出力媒体500に対する
入出力処理102が実行されるようになっている。
The scheduler 101 in the shared I/O device 100 schedules the I/O requests 210, 310, and 410 based on the priorities 21, 31, and 41. If the priority 21 is the highest, followed by 31 and 41, the following order will be used: requests 201, 301, 410, and 410.
The input/output process 102 for the input/output medium 500 is executed according to the schedule in the order of 01.

(発明が解決しようとする問題点) しかるにこの制御方式によると、各クライアント200,30
0,400においてそれぞれ経時的に順次発生する要求201,2
02,…,301,302,…,401,402,…について、その優先度が
例えば要求201>202>301>……(左側のものほど優先
度が高いとする)である場合、最も優先度の高い要求20
1に対する処理が完了したことをクライアント200が何ら
かの手段により自ら知ってから次の要求202を出力する
までにタイムラグがあると、その間に別のクライアント
300における要求301に対する処理が先行されてしまい、
優先度とは異なる順序、すなわち、要求201→301→202
→…の順で処理が行われてしまうという問題がある。
(Problem to be Solved by the Invention) However, according to this control method, each client 200, 30
0, 400, respectively,
For example, if the priority of requests 201, 202, 301, 302, 401, 402, is 201 > 202 > 301 > ... (the left side has higher priority), the highest priority request 20
If there is a time lag between when the client 200 knows by some means that the processing for 1 has been completed and when it outputs the next request 202, another client
The processing for request 301 in 300 is prioritized,
In a different order than priority, i.e. request 201 → 301 → 202
There is a problem in that the processing is carried out in the order →...

例えば、第5図に示すように、共有入出力装置100にお
ける一つの入出力要求に対応する入出力処理完了のタイ
ミングであるの時点で、cに示すように現行の要求20
1に対応する入出力処理が完了したとすると、この時点
では共有入出力装置100はクライアント200に次の要求20
2が発生していることを認識できず、dに示されるよう
に別のクライアント300の次の要求302を現行の要求301
として対応する処理を開始してしまう。
For example, as shown in FIG. 5, at the time when the I/O processing corresponding to one I/O request in the shared I/O device 100 is completed, the current request 20 is
If the I/O process corresponding to 1 is completed, at this point, the shared I/O device 100 sends the next request 20 to the client 200.
2 occurs, and the next request 302 of another client 300 is not recognized as a current request 301, as shown in d.
and starts the corresponding process.

なお、図において、現行の要求201,301,401及び次の要
求202,302を示す矢印の上に記載された2A(10),3A
(1),4A(3),2B(9),3B(5)という記号や、優
先度21,31,41を示す矢印の上に記載された10,9,1,5,3の
意味するところは図の余白に示した凡例のとおりであ
り、例えば、2A(10)はクライアント200における1番
目の要求であって優先度の値が10であるものを指す。同
様に、3B(5)はクライアント300における2番目の要
求であって優先度の値が5であるものを指し、4A(3)
はクライアント400における1番目の要求であって優先
度の値が3であるものを指す。ここで、優先度の値は大
きいものほど優先度が高いものとする。
In the figure, 2A(10), 3A(11), and 4A(12) are written above the arrows indicating the current requests 201, 301, and 401 and the next requests 202 and 302.
The symbols (1), 4A (3), 2B (9), and 3B (5), as well as the 10, 9, 1, 5, and 3 written above the arrows indicating priorities 21, 31, and 41, have meanings as shown in the legend in the margin of the figure. For example, 2A (10) indicates the first request from client 200, with a priority value of 10. Similarly, 3B (5) indicates the second request from client 300, with a priority value of 5, and 4A (3).
indicates the first request from the client 400, which has a priority value of 3. Here, the higher the priority value, the higher the priority.

上記の結果、第5図の最下段に示すように、入出力処理
時間としてはタイミング〜〜の間で3B(5)→2B
(9)の順で処理が実行される。つまり、優先度から言
えば本来先に処理されるべきクライアント200の要求202
(2B(9))よりも、クライアント300の要求302(3B
(5))が先に処理されることになる。
As a result of the above, as shown in the bottom row of Figure 5, the input/output processing time is 3B(5) → 2B between timings
In other words, the request 202 of the client 200, which should have been processed first in terms of priority, is executed in the order of (9).
(2B(9)) rather than the request 302 of the client 300 (3B
(5)) will be processed first.

このような場合に、クライアント200,300,400間での通
信や排他制御等の処理601(第3図参照)により、シス
テム全体にわたって所期の優先度を満足させる制御を行
わせようとすると、論理が複雑になり、各クライアント
間の独立性が失われると共に、スケジューリングに伴な
う処理が煩雑化してオーバーヘッドの増大を招くという
問題があった。
In such a case, if an attempt is made to control the entire system to satisfy the desired priority by processing 601 (see FIG. 3) such as communication and exclusive control between the clients 200, 300, and 400, the logic becomes complicated, the independence between the clients is lost, and the processing associated with scheduling becomes complicated, resulting in an increase in overhead.

本発明は上記問題点を解決するために提案されたもの
で、その目的とするところは、各クライアントの独立性
を失わせることなく、またオーバーヘッドの増大を招か
ずに、共有入出力装置に対する複数の入出力要求をシス
テム全体にわたって適正に優先順序制御できるようにし
た共有入出力装置の制御方法を提供することにある。
The present invention has been proposed to solve the above problems, and its object is to provide a method for controlling a shared I/O device that can properly control the priority order of multiple I/O requests to the shared I/O device throughout the entire system without losing the independence of each client and without increasing overhead.

(問題点を解決するための手段) 上記問題点を解決するため、本発明は、個別にかつ一時
点では最も優先度の高い唯一の入出力要求を出力し、そ
の処理完了までは新たな入出力要求を出力しない複数の
独立したクライアントによって共有される共有入出力装
置の制御方法において、前記各クライアントは、現在発
生しているすべての要求のうち優先度が最高のものを現
行の要求として前記共有入出力装置に出力する際に、そ
の要求についての優先度と、当該クライアントにおいて
次に入出力要求の出力が予定される要求についての優先
度とを前記現行の要求に付加して共有入出力装置内に設
定し、前記共有入出力装置は、各クライアントからの要
求に付加されて設定されたすべての優先度を参照し、現
行の要求の優先度及びに次の出力が予定される要求の優
先度の中で、最も優先度が高いものに対応した現行の要
求に対応する入出力処理を実行し、更に、入出力処理が
完了した後、完了した入出力要求についての優先度を除
いて再度各クライアントからの要求に付加されて設定さ
れているすべての優先度を参照し、最も優先度の高いも
のが、前記完了した入出力要求に付加されたところの、
入出力要求の出力が予定された要求の優先度であれば、
対応するクライアントからの次の入出力要求の出力を待
ってその要求に対応する入出力処理を実行することによ
り、優先度の高い要求から順に対応する入出力処理を実
行するものである。
(Means for solving the problem) In order to solve the above problem, the present invention provides a method for controlling a shared input/output device shared by a plurality of independent clients, each of which individually and at a given time outputs only one input/output request with the highest priority and does not output a new input/output request until processing of the highest priority request is completed, wherein, when each of the clients outputs the highest priority request of all currently occurring requests to the shared input/output device as a current request, the client adds the priority of the current request and the priority of the request for which output of the next input/output request is scheduled in the client to the current request and sets them in the shared input/output device, the shared input/output device refers to all the priorities added to and set on requests from each client, and executes input/output processing corresponding to the current request that has the highest priority among the priority of the current request and the priority of the request for which output is scheduled to be next, and after the input/output processing is completed, refers again to all the priorities added to and set on requests from each client, excluding the priority of the completed input/output request, and executes the processing corresponding to the current request that has the highest priority.
If the output of an I/O request is the priority of the scheduled request,
The I/O processing corresponding to the next I/O request is executed in the order of priority, by waiting for the output of the next I/O request from the corresponding client and then executing the I/O processing corresponding to that request.

なお、共有入出力装置がある要求に対応する入出力処理
を実行中に、あるクライアントにおいて発生した次に入
出力要求の出力が予定される要求の変更により、既に共
有入出力装置内に設定されている優先度の優先順位を変
更する必要が生じた場合に、次の要求の優先度を共有入
出力装置に再設定可能とすることが望ましい。
When a need arises to change the priority order of the priority already set in the shared input/output device due to a change in a request scheduled to be next output from a client while the shared input/output device is executing input/output processing corresponding to a certain request, it is desirable to be able to reset the priority of the next request in the shared input/output device.

(作用) (1)本発明において、各クライアントからは、当該ク
ライアントの現行の要求と、この要求の優先度と、次の
要求が既に発生している場合にその要求の優先度とが共
有入出力装置に渡される。
(Function) (1) In the present invention, each client passes to the shared input/output device its current request, the priority of this request, and, if a next request has already occurred, the priority of that request.

(2)そして、共有入出力装置側では、すべてのクライ
アントから渡された上記(1)の情報のうち、「現行の
要求の優先度」と「次の要求の優先度」とを比較して最
高の優先度のものを決定し、最高の優先度のものが「現
行の要求の優先度」であるか「次の要求の優先度」であ
るかに関わらず、それを出力したクライアントからの入
出力要求に含まれる現行の要求を入出力媒体に出力して
処理を行なわせる。
(2) Then, on the shared I/O device side, among the information (1) passed from all the clients, the "priority of the current request" is compared with the "priority of the next request" to determine the one with the highest priority. Regardless of whether the one with the highest priority is the "priority of the current request" or the "priority of the next request," the current request included in the I/O request from the client that output it is output to the I/O medium for processing.

この段階で、仮りに、「次の要求の優先度」>「現行の
要求の優先度」で(次の要求の優先度が現行の要求の優
先度よりも高い)であれば、現行の要求が「次の要求の
優先度」により押し出されて入出力が行なわれる。ま
た、入出力が完了した時点で、「次の要求の優先度」に
ついても他のクライアントが出力した「現行の要求の優
先度」及び「次の要求の優先度」の何れよりも高い場合
には、現行の要求の入出力処理の完了後、クライアント
からの次の要求にかかる入出力要求が出力されるのを待
ってそれを入出力媒体に対し入出力する。
At this stage, if "priority of next request">"priority of current request" (priority of next request is higher than priority of current request), the current request is pushed aside by "priority of next request" and input/output is performed. Also, when input/output is completed, if "priority of next request" is also higher than both "priority of current request" and "priority of next request" output by other clients, after input/output processing of the current request is completed, the I/O request for the next request from the client is output and it is input/output to the I/O medium.

(2−1)特定のクライアント内で一つの要求(すなわ
ち現行の要求のみ)しか発生していない場合には、共有
入出力装置には「次の要求の優先度」は渡らないため、
特許請求の範囲第1項において、現行の要求がそれ自身
の「現行の要求の優先度」により他のクライアントから
の優先度と比較され、上述した押し出し動作や次の要求
にかかる入出力要求の出力待ちは発生しない。
(2-1) If only one request (i.e., only the current request) has occurred within a particular client, the "priority of the next request" is not passed to the shared I/O device.
In claim 1, the current request is compared with priorities from other clients by its own "current request priority", and the above-mentioned pushing operation and waiting for the output of the I/O request for the next request do not occur.

(2−2)特定のクライアント内で既に複数の要求が発
生している場合の入出力要求では、クライアント内で要
求が優先度順に並べられているので、「現行の要求の優
先度」>「次の要求の優先度」(現行の要求の優先度が
次のっ要求の優先度よりも高い)となり、特許請求の範
囲第1項において、押し出し動作は起こらないが次の要
求にかかる入出力要求の出力待ちは起こる場合がある。
但し、この待ち状態では既に現行の要求の入出力が完了
しており、対応するクライアントが必ず次の要求を新た
な入出力要求として出力してくるため、永久的な待ち状
態となることはない。
(2-2) In the case of an I/O request when multiple requests have already occurred within a particular client, the requests are arranged in order of priority within the client, so that "priority of current request">"priority of next request" (the priority of the current request is higher than the priority of the next request), and in accordance with claim 1, a push-out operation does not occur, but there may be a wait for the output of the I/O request for the next request.
However, in this waiting state, the I/O for the current request has already been completed, and the corresponding client will surely output the next request as a new I/O request, so the waiting state will not continue forever.

(2−3)上述した(2−1)または(2−2)で既に
入出力要求を共有入出力装置に出力して共有入出力装置
側でその処理を完了する以前に、新たに「現行の要求の
優先度」よりも高い優先度を持つ要求が発生した場合に
は、クライアント内での要求の優先度順への並び替えに
より、その要求が「次の要求」となる。これは、現行の
要求は既に共有入出力装置側に出力されており、いつそ
の優先度が最大になって入出力処理が始まるかは一般的
に不明であって、これを正確に認識しようとするとクラ
イアントと共有入出力装置との間で排他制御等が必要に
なり、処理の複雑化や性能の低下を招くことになるの
で、処理を単純化させるための方法である。
(2-3) If a new request with a higher priority than the "priority of the current request" occurs before an I/O request has already been output to the shared I/O device in the above (2-1) or (2-2) and the processing is completed on the shared I/O device side, the request is rearranged in the client's priority order, and the new request becomes the "next request." This is a method for simplifying the processing because the current request has already been output to the shared I/O device side, and it is generally unknown when the priority will reach its maximum and I/O processing will begin, and attempting to accurately recognize this would require exclusive control between the client and the shared I/O device, which would complicate processing and reduce performance.

なお、「次の要求」の優先度は特許請求の範囲第2項の
再設定処理によって共有入出力装置に渡り、その優先度
が他のクライアントからの優先度よりも高くなった時点
で前述の押し出し動作が発生する。
The priority of the "next request" is passed to the shared input/output device by the reset process of claim 2, and when that priority becomes higher than the priorities of other clients, the above-mentioned push-out operation occurs.

押し出し動作が発生してその入出力要求に対応する入出
力処理が完了した場合、その入出力要求を発生させたク
ライアントがそれまでの「次の要求」を「現行の要求」
として新たに入出力要求を出力して来るが、押し出しが
発生したこと自体は、そのクライアントのそれまでの
「次の要求の優先度」すなわち新たな「現行の要求の優
先度」がすべてのクライアントが出力した優先度の中で
最高のものであることを示しているので、共有入出力装
置ではその入出力要求を待って入出力媒体に対し入出力
する。また、この待ち状態も既に現行の要求の入出力が
完了しており、対応するクライアントが必ず次の要求を
新たな入出力要求として出力してくるため、永久的な待
ち状態になることはない。
When a push operation occurs and the I/O processing corresponding to that I/O request is completed, the client that generated the I/O request marks the previous "next request" as the "current request."
However, the fact that a client is pushed out indicates that the "next request priority" of that client, i.e., the new "current request priority" is the highest priority among all the clients, so the shared I/O device waits for that I/O request and performs I/O on the I/O medium. Also, this waiting state does not become a permanent waiting state because the I/O of the current request has already been completed and the corresponding client will always output the next request as a new I/O request.

(実施例) 以下、図に沿って本発明の実施例を説明する。(Embodiments) Hereinafter, embodiments of the present invention will be described with reference to the drawings.

第1図はこの実施例の構成を示すもので、前記同様に10
0は共有入出力装置、200,300,400はマイクロプロセッサ
等のクライアント、500は共有入出力装置100の入出力媒
体である。そして、各クライアント200,300,400におい
ては現行の要求201,301,401が発生し、以後、要求202,3
02,402の発生がそれぞれ予定されているものとし、これ
らの要求は入出力要求210,310,410として共有入出力装
置100に出力されるようになっている。ここで、前記要
求201,301,401,202,302,402の優先度は、要求201>202
>401>402>301>302である(左側のものほど優先度が
高い)とする。
FIG. 1 shows the configuration of this embodiment.
Reference numeral 200, 300, and 400 denote a shared I/O device, 200, 300, and 400 denote clients such as microprocessors, and 500 denotes an I/O medium of the shared I/O device 100. In each of the clients 200, 300, and 400, a current request 201, 301, or 401 occurs, and thereafter, requests 202, 303, and 404 occur.
Assume that occurrence of requests 201, 301, 401, 202, 302, and 402 is scheduled, respectively, and these requests are output to the shared I/O device 100 as I/O requests 210, 310, and 410. Here, the priority of the requests 201, 301, 401, 202, 302, and 402 is as follows: request 201>202
> 401 > 402 > 301 > 302 (the ones on the left have higher priority).

しかして、クライアント200は、共有入出力装置100に対
して現行の要求201を行う際、この要求201にかかる優先
度21を付加すると共に、クライアント200内で次の要求2
02が既に発生している場合には、要求201に次いで優先
度の高いその要求202にかかる優先度22をも付加する。
この処理は他のクライアント300,400についても同様で
あり、各クライアント300,400における要求301,401の出
力時に優先度31,32及び41,42を付加する。
Thus, when a client 200 makes a current request 201 to the shared I/O device 100, it adds a priority 21 to the current request 201 and also schedules the next request 201 within the client 200.
If request 02 has already occurred, then a priority of 22 is also added to request 202, which has the next highest priority after request 201.
This process is similar for the other clients 300, 400, and priorities 31, 32 and 41, 42 are added when the requests 301, 401 are output from the respective clients 300, 400.

この場合の共有入出力装置100における処理は、まず要
求201,301,401,202,302,402についての優先度21,31,41,
22,32,42を比較し、このうち最も優先度の高い現行の要
求201をスケジューラ101により選択して実行する。すな
わち、要求201に従って入出力媒体500に対する入出力装
置102を実行する。
In this case, the shared I/O device 100 first processes the requests 201, 301, 401, 202, 302, and 402 with priorities 21, 31, 41,
22, 32, and 42 are compared, and the current request 201 having the highest priority is selected and executed by the scheduler 101. That is, the I/O device 102 for the I/O medium 500 is executed according to the request 201.

次に、要求201の実行が完了して再スケジュールを行う
場合には、まず残りの要求301,401,202,302,402につい
ての優先度31,41,22,32,42を比較する。そして、このう
ちで最も優先度の高いものが、前記完了した要求201に
付加されたところの、入出力要求の出力が予定されてい
る要求202の優先度22であれば、対応するクライアント2
00から次の要求202が出力されるのを待って、その要求2
02に対応する入出力処理を実行する。
Next, when the execution of the request 201 is completed and rescheduling is to be performed, first the priorities 31, 41, 22, 32, and 42 of the remaining requests 301, 401, 202, 302, and 402 are compared. Then, if the highest priority among them is the priority 22 of the request 202 that is scheduled to output an I/O request and that was added to the completed request 201, the corresponding client 2
Wait for the next request 202 to be output from 00, and then
Execute the input/output process corresponding to 02.

なお、特定のクライアント、例えば200内で一つの要求
(すなわち現行の要求201のみしか発生していない場
合、共有入出力装置100には「次の要求の優先度」は送
られない。従って、共有入出力装置100では現行の要求2
01がそれ自身の優先度21により他のクライアントからの
優先度と比較されることになり、上述した押し出し動作
や次の要求にかかる入出力要求の出力待ちは発生しな
い。
In addition, when only one request (i.e., the current request 201) has occurred in a particular client, for example 200, the "priority of the next request" is not sent to the shared I/O device 100. Therefore, the shared I/O device 100 does not receive the current request 201.
01 will be compared with the priorities of other clients with its own priority of 21, and the above-mentioned pushing operation or waiting for the output of the I/O request for the next request will not occur.

実施例のように、特定のクライアント、例えば200内で
既に複数の要求201,22が発生している場合の入出力要求
では、クライアント200内で要求が優先度順に並べられ
ているので、現行の要求201の優先度21が次の要求202の
優先度22よりも高く、前述の押し出し動作は起こらない
が、現行の要求201に対応する処理を完了した時点で、
次の要求202にかかる入出力要求の出力待ちは起こり得
る。但し、この待ち状態では既に現行の要求201の入出
力が完了しており、クライアント200が必ず次の要求202
を新たな入出力要求として出力してくるため、永久的な
待ち状態となることはない。
In the embodiment, in the case of an I/O request when multiple requests 201 and 22 have already occurred in a particular client, for example 200, the requests are arranged in order of priority in the client 200, so the priority 21 of the current request 201 is higher than the priority 22 of the next request 202, and the above-mentioned pushing operation does not occur. However, when the processing corresponding to the current request 201 is completed,
Waiting for the output of an I/O request for the next request 202 may occur. However, in this waiting state, the I/O for the current request 201 has already been completed, and the client 200 is not necessarily waiting for the next request 202.
is output as a new I/O request, so the waiting state does not last forever.

以下、同様にして、ある要求が実行される度に共有入出
力装置100内の残りの優先度を比較して最も優先度の高
い要求に着目し、その要求が出力されるのを待って上述
した処理を繰り返していく。
Similarly, each time a request is executed, the remaining priorities in the shared input/output device 100 are compared, attention is paid to the request with the highest priority, and the above-mentioned process is repeated while waiting for that request to be output.

これにより、最も優先度の高い要求を実行した後、次位
の優先度を有する別の要求が出力されるまでにタイムラ
グがある場合でも、これにより更に低い優先度の要求が
先行して実行される不都合がなく、すべてのクライアン
ト200,300,400を通じて適正な優先順序制御を行うこと
ができる。上述した本実施例における処理を第4図を参
照しつつ説明すると、第4図のの時点でaとして示す
ごとく、共有入出力装置100はクライアント200に優先度
の値が9である次の要求202であることを認識でき、こ
の要求202である2B(9)がクライアント200の現行の要
求201となって出力されることを予想でき、その要求の
出力を待って、bにおけるクライアント300の次の要求3
02である3B(5)に先立って前記要求202についての入
出力処理を行なうことができる。これにより、入出力処
理時間の〜〜の間では優先度の値に従って2B
(9)→3B(5)の順で処理が実行されることになる。
なお、第5図に示した凡例は第4図にも共通している。
As a result, even if there is a time lag between the execution of a request with the highest priority and the output of another request with the next highest priority, there is no inconvenience of a request with a lower priority being executed first, and proper priority control can be performed through all of the clients 200, 300, 400. To explain the processing in this embodiment described above with reference to Fig. 4, as shown as a at time point a in Fig. 4, the shared input/output device 100 can recognize that the next request 202 from the client 200 has a priority value of 9, and can predict that this request 202, 2B(9), will be output as the current request 201 of the client 200, and wait for the output of that request before processing the next request 3 of the client 300 at b.
This allows the I/O processing for the request 202 to be performed prior to the I/O processing for 3B(5) which is 02. This allows the I/O processing for 2B(5) to be performed according to the priority value during the I/O processing time between .
The processing will be executed in the order of (9) → 3B(5).
The legend shown in FIG. 5 is also used in FIG.

次に、第1図において、共有入力装置100に対するクラ
イアント200,300,400の要求201,202,301,302,401,402に
ついての優先順位が201>301>401>202>302>402(優
先度21>31>41>22>32>42)であり、各クライアント
200,300,400が前例と同様に要求を行い、共有入出力装
置100が要求201に対する処理を実行中に、クライアント
200内で新たに優先度23の要求が予定されて残存要求全
体の優先順位が203>301>401>202>302>402(優先度
23>31>41>22>32>42)に変化した場合の処理を以下
に説明する。
Next, in FIG. 1, the priority order of requests 201, 202, 301, 302, 401, 402 of clients 200, 300, 400 to the shared input device 100 is 201>301>401>202>302>402 (priority 21>31>41>22>32>42), and each client
200, 300, and 400 make requests as in the previous example, and while the shared I/O device 100 is processing the request 201,
A new request with priority 23 is scheduled in 200, and the priority of all remaining requests becomes 203 > 301 > 401 > 202 > 302 > 402 (priority
The processing when the order changes to 23>31>41>22>32>42 is explained below.

この場合、第2図に示すように、クライアント200は、
共有入出力装置100に対して要求201に次いで優先度の高
い要求203につき優先度の再設定220を行う。すなわち、
それまでの次位の要求202にかかる優先度22を、要求203
にかかる優先度23に変更する。
In this case, as shown in FIG. 2, the client 200:
A priority reset 220 is performed for the request 203, which has the second highest priority after the request 201, for the shared input/output device 100. That is,
Priority 22 for the previous next highest requirement 202 has been changed to requirement 203.
The priority level for this item will be changed to 23.

つまり、クライアント200内での要求の優先度順への並
び替えにより、要求203が「次の要求」になると共に、
「次の要求の優先度」の再設定処理により、要求203に
ついての優先度23が他のクライアントの要求の優先度
(例えば要求301の優先度31)よりも高くなった時点で
前記押し出し状態が発生する。
That is, by rearranging the requests in the client 200 in order of priority, the request 203 becomes the "next request" and
The push-out condition occurs when the "next request priority" reset process causes the priority 23 for request 203 to be higher than the priority of other client requests (eg, priority 31 for request 301).

押し出し状態が発生して入出力要求201に対応する入出
力処理が完了した場合、その入出力要求201を発生させ
たクライアント200がそれまでの「次の要求」を「現行
の要求」として新たに入出力要求203を出力して来る
が、押し出しが発生したこと自体は、そのクライアント
200のそれまでの「次の要求の優先度」すなわち新たな
「現行の要求の優先度」がすべてのクライアントが出力
した優先度の中で最高のものであることを示しているの
で、共有入出力装置100ではその入出力要求203が出力さ
れるのを待って入出力媒体500に対し入出力する。ま
た、この入出力要求203の出力の待ち状態においても、
既に現行の要求201の入出力が完了しており、対応する
クライアント200が必ず次の要求203を新たな入出力要求
として出力してくるため、永久的な待ち状態になること
はない。こうすることにより、クライアント個々の事情
の変化に拘らず、各要求の優先度に基づいた正当なスケ
ジューリングが可能となる。
When a push-out state occurs and the I/O processing corresponding to the I/O request 201 is completed, the client 200 that generated the I/O request 201 outputs a new I/O request 203, with the previous "next request" as the "current request". However, the occurrence of the push-out itself is not recognized by the client.
Since the "next request priority" of 200, i.e., the new "current request priority" is the highest priority among the priorities output by all clients, the shared I/O device 100 waits for the I/O request 203 to be output and then performs I/O on the I/O medium 500. Also, even while waiting for the output of this I/O request 203,
Since the I/O of the current request 201 has already been completed, and the corresponding client 200 will always output the next request 203 as a new I/O request, there will be no perpetual waiting state. This makes it possible to perform proper scheduling based on the priority of each request, regardless of changes in the circumstances of each client.

なお、本発明は、共通のバスを有するマルチプロセッサ
システム等のほか、通信回線を介して互いに独立した複
数のマイクロプロセッサが接続されているようなシステ
ムに対しても勿論適用可能である。
Incidentally, the present invention is of course applicable to a multiprocessor system having a common bus, as well as to a system in which a plurality of independent microprocessors are connected via a communication line.

(発明の効果) 以上のように本発明によれば、共有入出力装置が、各ク
ライアントから発生する現行要求及び次位要求のすべて
の優先度を参照してスケジューリングを行い、また、必
要に応じて優先度の再設定を可能としたため、システム
全体にわたる正当な優先順序制御を従来のような各クラ
イアント間の通信や排他制御等を要すことなく単純に実
現することができる。
(Effects of the Invention) As described above, according to the present invention, the shared input/output device performs scheduling by referring to the priorities of all current requests and subsequent requests generated by each client, and also makes it possible to reset priorities as necessary, so that proper priority control across the entire system can be simply realized without requiring communication between clients or exclusive control as in the conventional method.

従って、各クライアント間の独立性が失われる心配がな
く、共有入出力制御のオーバーヘッドを減少させること
ができる等の効果がある。
Therefore, there is no need to worry about losing the independence of each client, and there are other advantages such as the ability to reduce the overhead of shared input/output control.

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

第1図は本発明の一実施例が適用される入出力装置共有
システムの構成図、第2図はクライアント内で新たな要
求が発生した場合の説明図、第3図は従来例を示す入出
力装置共有システムの構成図、第4図は本発明の実施例
における処理の説明図、第5図は従来例における処理の
説明図である。 100……共有入出力装置 200,300,400……クライアント 201,202,203,301,302,401,402……要求 210,310,410……入出力要求 21,22,23,31,32,41,42……優先度
Fig. 1 is a diagram of an input/output device sharing system to which an embodiment of the present invention is applied, Fig. 2 is an explanatory diagram of a case where a new request occurs in a client, Fig. 3 is a diagram of an input/output device sharing system showing a conventional example, Fig. 4 is an explanatory diagram of processing in the embodiment of the present invention, and Fig. 5 is an explanatory diagram of processing in the conventional example. 100... Shared input/output device 200, 300, 400... Clients 201, 202, 203, 301, 302, 401, 402... Requests 210, 310, 410... Input/output requests 21, 22, 23, 31, 32, 41, 42... Priority

Claims (2)

【特許請求の範囲】[Claims] 【請求項1】個別にかつ一時点では最も優先度の高い唯
一の入出力要求を出力し、その処理完了までは新たな入
出力要求を出力しない複数の独立した装置(以下、クラ
イアントという)によって共有される共有入出力装置の
制御方法において、 前記各クライアントは、現在発生しているすべての要求
のうち優先度が最高のものを現行の要求として前記共有
入出力装置に出力する際に、その要求についての優先度
と、当該クライアントにおいて次に入出力要求の出力が
予定される要求についての優先度とを前記現行の要求に
付加して共有入出力装置内に設定し、前記共有入出力装
置は、各クライアントからの要求に付加されて設定され
たすべての優先度を参照し、現行の要求の優先度及び次
に出力が予定される要求の優先度の中で、最も優先度が
高いものに対応した現行の要求に対応する入出力処理を
実行し、更に、入出力処理が完了した後、完了した入出
力要求についての優先度を除いて再度各クライアントか
らの要求に付加されて設定されているすべての優先度を
参照し、最も優先度の高いものが、前記完了した入出力
要求に付加されたところの、入出力要求の出力が予定さ
れた要求の優先度であれば、対応するクライアントから
の次の入出力要求の出力を待ってその要求に対応する入
出力処理を実行することにより、優先度の高い要求から
順に対応する入出力処理を実行することを特徴とする共
有入出力装置の制御方法。」
[Claim 1] A method for controlling a shared input/output device shared by a plurality of independent devices (hereinafter referred to as clients), each of which individually and at a given time outputs only one input/output request with the highest priority and does not output a new input/output request until processing of the highest priority request is completed, wherein, when each of the clients outputs the highest priority request of all currently occurring requests to the shared input/output device as a current request, the client adds the priority of that request and the priority of a request for which the client is scheduled to next output an I/O request to the current request and sets them in the shared input/output device, the shared input/output device refers to all the priorities added to and set on requests from each client, and executes I/O processing corresponding to the current request that has the highest priority among the priority of the current request and the priority of the request for which the next output is scheduled, and after the I/O processing is completed, the shared input/output device again refers to all the priorities added to and set on requests from each client excluding the priority of the completed I/O request, and if the highest priority is the priority of a request for which the output of an I/O request was scheduled that was added to the completed I/O request, waits for the output of the next I/O request from the corresponding client and executes the I/O processing corresponding to that request, thereby executing I/O processing corresponding to the requests in order from highest priority. "
【請求項2】共有入出力装置がある要求に対応する入出
力処理を実行中に、あるクライアントにおいて発生した
次に入出力要求の出力が予定される要求の変更により、
既に共有入出力装置内に設定されている優先度の優先順
位を変更する必要が生じた場合に、次の要求の優先度を
共有入出力装置に再設定可能とした特許請求の範囲第1
項記載の共有入出力装置の制御方法。
2. While a shared input/output device is executing an input/output process corresponding to a certain request, a change in a request scheduled for output of the next input/output request that occurs in a certain client causes:
When it becomes necessary to change the priority order of the priority already set in the shared input/output device, the priority order of the next request can be reset in the shared input/output device.
A method for controlling the shared input/output device according to claim 1.
JP26064987A 1987-10-15 1987-10-15 Method for controlling a shared input/output device Expired - Lifetime JPH0754497B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP26064987A JPH0754497B2 (en) 1987-10-15 1987-10-15 Method for controlling a shared input/output device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP26064987A JPH0754497B2 (en) 1987-10-15 1987-10-15 Method for controlling a shared input/output device

Publications (2)

Publication Number Publication Date
JPH01102672A JPH01102672A (en) 1989-04-20
JPH0754497B2 true JPH0754497B2 (en) 1995-06-07

Family

ID=17350850

Family Applications (1)

Application Number Title Priority Date Filing Date
JP26064987A Expired - Lifetime JPH0754497B2 (en) 1987-10-15 1987-10-15 Method for controlling a shared input/output device

Country Status (1)

Country Link
JP (1) JPH0754497B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5371893A (en) * 1991-12-27 1994-12-06 International Business Machines Corporation Look-ahead priority arbitration system and method
JP7464386B2 (en) * 2019-12-20 2024-04-09 ファナック株式会社 Control device and control method

Also Published As

Publication number Publication date
JPH01102672A (en) 1989-04-20

Similar Documents

Publication Publication Date Title
JP3922070B2 (en) Distributed control method and apparatus
EP0442615B1 (en) A communications adapter and method for operating it
JPH08171526A (en) Input/output interface device and its control method
US11115232B2 (en) Method and device for operating a control unit
CN112579271A (en) Real-time task scheduling method, module, terminal and storage medium for non-real-time operating system
JPH0754497B2 (en) Method for controlling a shared input/output device
JP2693916B2 (en) Task scheduling method
JP2002099434A (en) Control device
JP2667575B2 (en) Task scheduling method
JPH0644234B2 (en) Task management device
Kim et al. Multicore ECU task-load distribution (balancing) and dynamic scheduling
JPS63636A (en) Task control system
US8694999B2 (en) Cooperative scheduling of multiple partitions in a single time window
JPH0895805A (en) Task management device
JP2000132409A (en) Stack sharing system for task having no wait state
JPS6125249A (en) Exclusive control system
JP2002222161A (en) Semiconductor device and data transfer method
JPS62249262A (en) Bus acquisition system
JPH06149594A (en) Multitask execution device
JP2555580B2 (en) Storage device control system
JPH04209031A (en) Resources control method for computer system
JPH0782444B2 (en) Task schedule method
JPH0462093B2 (en)
JPH04209030A (en) Resources control method for computer system
JPH06309290A (en) Parallel processing system