JPH0855074A - Input/output processing system - Google Patents

Input/output processing system

Info

Publication number
JPH0855074A
JPH0855074A JP18923794A JP18923794A JPH0855074A JP H0855074 A JPH0855074 A JP H0855074A JP 18923794 A JP18923794 A JP 18923794A JP 18923794 A JP18923794 A JP 18923794A JP H0855074 A JPH0855074 A JP H0855074A
Authority
JP
Japan
Prior art keywords
data
transfer
space
input
user
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP18923794A
Other languages
Japanese (ja)
Inventor
Toshiaki Hirata
平田  俊明
Kazuo Matsunaga
和男 松永
Takeshi Kondo
毅 近藤
Osamu Takada
治 高田
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.)
Hitachi Ltd
Original Assignee
Hitachi 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 Hitachi Ltd filed Critical Hitachi Ltd
Priority to JP18923794A priority Critical patent/JPH0855074A/en
Priority to US08/505,144 priority patent/US5860022A/en
Priority to CN95115302.1A priority patent/CN1100295C/en
Publication of JPH0855074A publication Critical patent/JPH0855074A/en
Pending legal-status Critical Current

Links

Abstract

PURPOSE:To optimize the processing efficiency as the whole of the transfer processing by adjusting the storage start position of transfer data on a kernel space in accordance with the length or user data transferred to an input/output device. CONSTITUTION:In the case of data to be copied whose length is shorter than the value preliminarily determined by the computer system, true storage start position or transfer data on the kernel space is set so as to be on the boundary of 32 bytes because transfer in 32-byte units is most efficient with respect to the transfer capability or an input/output bus when data on the memory is transferred from the input device into the input/output device by the direct memory access system. In the case of the data length longer than the preliminarily determined value, the storage start position or transfer data on the kernel space is so set that the data storage start position of the copy source and that of the copy destination match with each other, thus realizing the most efficient data copy processing.

Description

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

【0001】[0001]

【産業上の利用分野】本発明は、計算機システムの入出
力処理方式に係り、利用者データを入出力装置に転送す
る処理効率を最適化する方式に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an input / output processing system for a computer system, and more particularly to a system for optimizing the processing efficiency of transferring user data to an input / output device.

【0002】[0002]

【従来の技術】従来の利用者データを入出力装置に転送
する処理は、「ライティング ア ユニックス デバイ
ス ドライバ(WRITING A UNIX DEVICE DRIVER),John
Wiley& Sons社刊,1988」に記載のように利用者空間か
らカーネル空間へデータ複写を行う処理とカーネル空間
から入出力装置へ転送する処理それぞれについては最適
化する方法が示されている。前者は複写元および複写先
の両方のメモリ上のデータ格納先頭位置に共通の境界値
に対応するできるだけ大きいデータ型を用いて複写処理
を行う方法であり、後者はデータのメモリ上の格納先頭
位置の境界値に応じてできるだけ大きい転送単位で転送
処理を行う方法である。しかし、それぞれを独立な処理
として取り扱っており、両者の間に関連はない。
2. Description of the Related Art Conventional processing for transferring user data to an input / output device is described in "WRITING A UNIX DEVICE DRIVER", John
As described in "Wiley & Sons, 1988", methods for optimizing the process of copying data from the user space to the kernel space and the process of transferring data from the kernel space to the input / output device are shown. The former is a method of performing copy processing by using a data type that is as large as possible corresponding to a common boundary value at the data storage start positions on both the copy source and copy destination memories, and the latter is the data storage start position on the memory. This is a method of performing transfer processing in a transfer unit as large as possible according to the boundary value of. However, they are treated as independent processes, and there is no relation between them.

【0003】[0003]

【発明が解決しようとする課題】前記従来の転送処理方
式では、利用者空間からカーネル空間へデータ複写を行
う処理とカーネル空間から入出力装置へ転送する処理を
独立な処理として取り扱っており、一連の処理として最
適化をはかるように考慮されていない。
In the conventional transfer processing method, the processing of copying data from the user space to the kernel space and the processing of transferring from the kernel space to the input / output device are handled as independent processing. Is not considered to be optimized as the processing of.

【0004】このため、例えば、利用者空間からカーネ
ル空間へデータ複写を行う処理を最適化するため複写元
および複写先のメモリ上のデータ格納先頭位置の境界値
を一致させると、カーネル空間から入出力装置へ転送す
る場合の転送処理に対してメモリ上の格納先頭位置の境
界値が不適切となり、少なくとも適切な境界値に達する
までは小さな単位での転送となり、特にデータ長が短い
場合はオーバヘッドが大きくなる。逆にカーネル空間か
ら入出力装置へ転送する場合の転送処理に対してメモリ
上の格納先頭位置の境界値を最適な値にするように設定
すると、利用者空間からカーネル空間へデータ複写を行
うとき、複写元および複写先のメモリ上のデータ格納先
頭位置の境界値が一致しているとはかぎらず、複写の単
位が小さくなり、特にデータ長が長い場合にオーバヘッ
ドが大きくなる。
Therefore, for example, if the boundary values of the data storage start positions on the memory of the copy source and the copy destination are made coincident with each other in order to optimize the process of copying the data from the user space to the kernel space, the data is transferred from the kernel space. The boundary value of the storage start position on the memory becomes inappropriate for the transfer processing when transferring to the output device, and transfer is performed in small units until at least the appropriate boundary value is reached, especially when the data length is short, overhead Grows larger. Conversely, when the boundary value of the storage start position in the memory is set to an optimum value for the transfer processing when transferring from the kernel space to the I / O device, data is copied from the user space to the kernel space. The boundary values of the data storage head positions on the memory of the copy source and the copy destination do not always match, and the unit of copying becomes small, and the overhead becomes large especially when the data length is long.

【0005】以上のように、転送データ長によっては前
記どちらかの処理がボトルネックとなり一連の処理とし
てみたときの転送性能を向上できない可能性がある。
As described above, depending on the transfer data length, there is a possibility that either of the above processes becomes a bottleneck and the transfer performance cannot be improved as a series of processes.

【0006】本発明の目的は、転送データ長に依存する
ことなく、転送処理全体として処理効率を最適化する方
式を提供することにある。
An object of the present invention is to provide a method for optimizing the processing efficiency of the entire transfer processing without depending on the transfer data length.

【0007】[0007]

【課題を解決するための手段】上記の目的は、それぞれ
独立した動作空間を持つ利用者モード,カーネルモード
の2つのプロセス実行モードを提供するオペレーティン
グシステムの下で動作し、中央処理装置と入出力装置と
の間をダイレクトメモリアクセス方式でデータ転送を行
う計算機システムにおいて、利用者モードで動作するプ
ロセスの動作空間(利用者空間)に存在するデータを入
出力装置に転送するため、前記データを一旦カーネルモ
ードでの動作空間(カーネル空間)に複写する処理にお
いて、複写するデータ長が計算機システムによって予め
決められた長さよりも短いときはカーネル空間上の転送
データの格納先頭位置を入出力装置への転送上最も効率
の良い値に設定する手段と、そうでないときにはカーネ
ル空間上の転送データの格納先頭位置を利用者空間から
カーネル空間へ複写する上で最も効率のよい値に設定す
る手段とを備えることにより達成される。
The above object is to operate under an operating system that provides two process execution modes, a user mode and a kernel mode, each of which has an independent operation space. In a computer system that transfers data to and from a device by the direct memory access method, the data existing in the operation space (user space) of a process operating in the user mode is transferred to the input / output device. In the process of copying to the operating space (kernel space) in kernel mode, if the data length to be copied is shorter than the length predetermined by the computer system, the storage start position of the transfer data in the kernel space is transferred to the input / output device. The means to set the most efficient value for transfer, and the transfer method in kernel space otherwise. It is achieved by providing a means for setting a storage start position of the data from the user space in the most efficient value in order to copy the kernel space.

【0008】また、上記計算機システムにおいて、利用
者空間からカーネル空間へデータ複写を行う処理におい
て、複写するデータ長が計算機システムによって予め決
められた長さよりも長いとき、利用者空間の転送データ
の格納先頭位置と利用者空間の転送データの格納先頭位
置を一致させ、境界値に応じて最大のデータ型に対応す
る転送単位でデータの複写を行う手段を備えることによ
り達成される。
Further, in the above computer system, in the process of copying data from the user space to the kernel space, when the data length to be copied is longer than the length predetermined by the computer system, the transfer data of the user space is stored. This is achieved by providing a means for matching the head position and the head position for storing the transfer data in the user space, and for copying the data in a transfer unit corresponding to the maximum data type according to the boundary value.

【0009】また、上記計算機システムにおいて、利用
者空間からカーネル空間に複写されたデータに転送を制
御するための制御情報を付加して入出力装置に転送する
処理において、制御情報を格納する領域を転送データと
は別に確保し、前記データと関連付け、さらに前記制御
情報を入出力装置への転送上最も効率のよい位置から格
納する手段を備えることにより達成される。
In the above computer system, in the process of adding control information for controlling transfer to the data copied from the user space to the kernel space and transferring the data to the input / output device, an area for storing the control information is set. This is achieved by providing means for securing the transfer data separately from the transfer data, associating with the data, and storing the control information from the most efficient position for transfer to the input / output device.

【0010】[0010]

【作用】前記計算機システムの構成によれば、入出力装
置へ転送する利用者データ長に応じてカーネル空間上の
転送データの格納先頭位置を調整することにより転送処
理全体として処理効率を最適化することができる。
According to the configuration of the computer system, the processing efficiency of the entire transfer process is optimized by adjusting the storage start position of the transfer data in the kernel space according to the user data length transferred to the input / output device. be able to.

【0011】また、前記計算機システムによれば、デー
タの転送を制御するための制御情報を付加した場合で
も、これを別の領域に適切な位置から設定することによ
り転送処理全体として処理効率を最適化することができ
る。
Further, according to the computer system, even when the control information for controlling the data transfer is added, by setting this in another area from an appropriate position, the processing efficiency as a whole can be optimized. Can be converted.

【0012】[0012]

【実施例】【Example】

システム構成:図2に本発明の一実施例の計算機システ
ムの構成を通信回線との入出力を例に説明する。計算機
システムは、まずソフトウェアレベルとハードウェアレ
ベルに分かれ、ソフトウェアレベルは利用者レベルとカ
ーネルレベルに分かれる。
System Configuration: FIG. 2 illustrates the configuration of a computer system according to an embodiment of the present invention, taking input / output with a communication line as an example. The computer system is first divided into a software level and a hardware level, and the software level is divided into a user level and a kernel level.

【0013】利用者レベルは、計算機システムの利用者
が作成したプログラムが動作するレベルで、利用者プロ
グラム3やシステムコールライブラリ4がある。利用者
レベルではプログラムは独立した動作空間(これを利用
者空間とよぶ)を持つプロセスという実行単位で動作す
る。
The user level is a level at which a program created by a user of the computer system operates, and there are a user program 3 and a system call library 4. At the user level, a program operates in an execution unit called a process that has an independent operation space (this is called user space).

【0014】カーネルレベルはオペレーティングシステ
ム等のシステム全体の動きを制御するプログラムが動作
するレベルで、1つの独立した動作空間(これをカーネ
ル空間と呼ぶ)を持つ。カーネルレベルには、次のいく
つかのモジュールが存在する。システムコールインタフ
ェース5は、利用者プログラムがカーネルの機能を利用
するためのモジュールである。通信プロトコル処理部6
は通信回線上のメッセージ形式やデバイスドライバプロ
グラムの管理,識別を行う。デバイスドライバ8は、通
信回線等の入出力装置10の動作を制御するモジュール
である。プロセス制御サブシステム7は、プロセスの生
成実行,スケジューリング,メモリ管理等を行う。ハー
ドウェア制御機構9は、ハードウェアとの通信や割り込
み処理を実行する。
The kernel level is a level at which a program for controlling the movement of the entire system such as an operating system operates, and has one independent operation space (this is called a kernel space). At the kernel level there are several modules: The system call interface 5 is a module for a user program to use the function of the kernel. Communication protocol processing unit 6
Manages and identifies the message format and device driver program on the communication line. The device driver 8 is a module that controls the operation of the input / output device 10 such as a communication line. The process control subsystem 7 performs process generation / execution, scheduling, memory management, and the like. The hardware control mechanism 9 executes communication with hardware and interrupt processing.

【0015】また本発明では、プログラムの実行単位で
あるプロセスの動作モードとして利用者モード(前記利
用者レベルに対応)及びカーネルモード(前記カーネル
レベルに対応)の2つのモードが存在することを前提と
する。利用者モードでは、プロセス単位に存在する利用
者空間のデータにのみアクセスでき、他のプロセスと時
分割による並行動作が可能である。カーネルモードで
は、カーネル及び利用者両方の空間にアクセス可能であ
り、他の利用者モードおよびカーネルモードのプロセス
と並行に動作することはなく、一連の処理が終了するま
で走りきる。
Further, in the present invention, it is premised that there are two modes, a user mode (corresponding to the user level) and a kernel mode (corresponding to the kernel level), as an operation mode of a process which is a program execution unit. And In the user mode, it is possible to access only the user space data that exists in the process unit, and it is possible to operate in parallel with other processes by time sharing. In the kernel mode, the space of both the kernel and the user can be accessed, it does not operate in parallel with other user mode and kernel mode processes, and it runs until the series of processing ends.

【0016】データ転送処理の流れ:次に利用者プログ
ラムが利用者空間上のデータを通信回線へ転送する処理
の流れの一例を図3に従い説明する。
Flow of data transfer processing: Next, an example of the flow of processing in which the user program transfers data in the user space to the communication line will be described with reference to FIG.

【0017】(1)利用者プログラムがカーネルにデー
タ転送を要求するためのシステムコールを発行する
()。
(1) A user program issues a system call for requesting data transfer to the kernel ().

【0018】(2)利用者モードからカーネルモードに
切り替わり、対応するカーネルレベルの処理エントリ
(システムコールインタフェース)を呼び出す。このと
き、カーネルレベルの処理はシステムコールを発行した
利用者プログラムのプロセスとして動作する。
(2) Switch from the user mode to the kernel mode and call the corresponding kernel-level processing entry (system call interface). At this time, the processing at the kernel level operates as the process of the user program that issued the system call.

【0019】(3)システムコールインタフェースは入
出力装置に転送するためのデータを利用者空間から複写
する()。次に通信プロトコル処理部にて転送要求を
渡すためのメッセージ形式作成等の処理を行った後
()、デバイスドライバおよびハードウェア制御機構
により入出力装置の動作を開始させ()、その後、転
送動作の完了を待つため、当該プロセスは中断する(wa
it)()。このとき、制御は他のプロセスに渡る。
(3) The system call interface copies data to be transferred to the input / output device from the user space (). Next, after the communication protocol processing unit performs processing such as creating a message format for passing the transfer request (), the device driver and the hardware control mechanism start the operation of the input / output device (), and then the transfer operation. Process is suspended (wa
it) (). At this time, control passes to another process.

【0020】(4)転送動作が完了すると入出力装置は
ソフトウェアに対して割込みを発行する。この割り込み
を契機に、ハードウェア制御機構の割り込みルーチンを
呼び出す()。
(4) When the transfer operation is completed, the input / output device issues an interrupt to the software. This interrupt is used to call the interrupt routine of the hardware control mechanism ().

【0021】(5)割り込みルーチンは、呼出しプロセ
スを起動し再開させる(post)()。
(5) The interrupt routine activates and restarts the calling process (post) ().

【0022】(6)カーネルモードから利用者モードに
切り替え、転送結果を伴って制御を利用者プログラムに
戻す()。
(6) The kernel mode is switched to the user mode, and control is returned to the user program with the transfer result ().

【0023】データ転送処理方式の詳細:転送データ
(1,2)を利用者空間からカーネル空間へ複写する処
理の一例を図1に従って説明する。利用者プログラムの
システムコール発行に対して利用者レベルからカーネル
レベルに切り替わったとき、システムコールインタフェ
ース部は以下の手順に従って転送データを利用者空間か
らカーネル空間へ複写する。
Details of data transfer processing method: An example of processing for copying the transfer data (1, 2) from the user space to the kernel space will be described with reference to FIG. When the user level is switched to the kernel level in response to the system call issued by the user program, the system call interface unit copies the transfer data from the user space to the kernel space according to the following procedure.

【0024】まず、複写するデータ長を参照する(これ
は例えば図4に示すようにバッファ12の実体を管理す
るバッファ管理テーブル11上に記録してある)。この
データ長が計算機システムによって予め決められた値よ
りも短いときはカーネル空間上の転送データの格納先頭
位置を入出力装置への転送上最も効率の良い値に設定す
る。
First, the length of data to be copied is referred (this is recorded in the buffer management table 11 for managing the substance of the buffer 12 as shown in FIG. 4, for example). When this data length is shorter than a value predetermined by the computer system, the storage start position of the transfer data in the kernel space is set to the most efficient value for transfer to the input / output device.

【0025】例えば、入出力装置がダイレクトメモリア
クセス方式(以下、DMAと略記)によりメモリ上のデ
ータを入出力装置内に転送する場合で、32バイト単位
での転送が入出力バスの転送能力上最も効率が良く、そ
のためには転送データの格納先頭位置を32バイト境界
に設定することが必要であるとする。この場合はカーネ
ル空間上の転送データの格納先頭位置を32バイト境界
になるように設定する。
For example, in the case where the input / output device transfers data on the memory to the inside of the input / output device by the direct memory access method (hereinafter abbreviated as DMA), the transfer in units of 32 bytes depends on the transfer capability of the input / output bus. It is most efficient, and for that purpose, it is necessary to set the storage start position of the transfer data on a 32-byte boundary. In this case, the storage start position of the transfer data in the kernel space is set to be on a 32-byte boundary.

【0026】一方、前記データ長が計算機システムによ
って予め決められた値よりも長いときは、カーネル空間
上の転送データの格納先頭位置を利用者空間からカーネ
ル空間へ複写する上で最も効率の良い値に設定する。
On the other hand, when the data length is longer than the value predetermined by the computer system, the most efficient value for copying the storage start position of the transfer data in the kernel space from the user space to the kernel space. Set to.

【0027】例えば、計算機システムのメモリ内のデー
タ複写ではロングワード(4バイト単位),ワード(2
バイト単位),バイト(1バイト)単位が可能であり、
それぞれのデータ単位での複写では複写元のデータ格納
先頭位置と複写先のデータ格納先頭位置が前記それぞれ
の境界に配置されている必要があるとする。この場合
は、複写元のデータ格納先頭位置と複写先のデータ格納
先頭位置の境界が一致するようにカーネル空間上の転送
データの格納先頭位置を設定することにより、最も効率
の良いデータ複写処理が実現できる。
For example, in copying data in the memory of a computer system, longword (4 byte unit), word (2
Byte unit), byte (1 byte) unit,
In copying in each data unit, it is assumed that the data storage start position of the copy source and the data storage start position of the copy destination need to be arranged at the respective boundaries. In this case, the most efficient data copy process can be performed by setting the transfer data storage start position in the kernel space so that the boundary between the copy source data storage start position and the copy destination data storage start position matches. realizable.

【0028】この理由は、図5に示すように複写元のデ
ータ格納先頭位置と複写先のデータ格納先頭位置が一致
していればロングワード境界に至るまでの半端分以外は
ロングワード単位での複写が可能なためである。
The reason for this is that, as shown in FIG. 5, if the data storage start position of the copy source and the data storage start position of the copy destination are the same, a longword unit is used except for half-length until reaching the longword boundary. This is because copying is possible.

【0029】次に上記データ複写処理の判定条件である
「計算機システムによって予め決められた値」の一例を
示す。まず、利用者空間からカーネル空間へのデータ複
写を最適化した場合のトータルの転送時間を求める。利
用者空間の転送データの格納先頭位置を13バイト境
界,転送データ長xバイト,1回のデータ複写またはD
MA転送に要する単価はそれぞれ1μs/バイト,10
μs/バイトとする。また、データ複写および転送処理
は前述の方式により実施されるものとする。このとき、
トータルの転送時間は以下の数1のようになる。
Next, an example of "a value predetermined by the computer system" which is a judgment condition of the data copying process will be shown. First, the total transfer time is calculated when the data copy from the user space to the kernel space is optimized. User space transfer data storage start position is 13-byte boundary, transfer data length x bytes, data copy once or D
Unit prices required for MA transfer are 1 μs / byte and 10 respectively.
μs / byte. Further, the data copying and transfer processing shall be carried out by the above-mentioned method. At this time,
The total transfer time is as shown in the following formula 1.

【0030】[0030]

【数1】 {(x−1)/4+1}+{13+(x−16)/32}×10 (数1) 次に同じ条件で入出力装置への転送を最適化した場合の
トータルの転送時間を求めると以下の数2のようにな
る。
[Formula 1] {(x-1) / 4 + 1} + {13+ (x-16) / 32} × 10 (Formula 1) Next, total transfer when transfer to the input / output device is optimized under the same conditions When the time is obtained, it becomes the following formula 2.

【0031】[0031]

【数2】 x+{x/32×10} (数2) (数1),(数2)とも第1項は利用者空間からカーネ
ル空間へのデータ複写に要する時間、第2項は入出力装
置への転送時間である。図6にこれらをグラフで示す。
この例では168バイトが境界値であることがわかる。
X + {x / 32 × 10} (Equation 2) In both (Equation 1) and (Equation 2), the first term is the time required to copy data from the user space to the kernel space, and the second term is input / output. This is the transfer time to the device. These are shown graphically in FIG.
In this example, it can be seen that 168 bytes is the boundary value.

【0032】制御情報の付加方法:入出力制御装置に対
するデータ転送時には一般に転送データに対して制御情
報を付加する場合が多い。例えば、通信回線とのデータ
送受信では転送データに対しプロトコルヘッダを付加す
る。制御情報はカーネルレベルで付加する。図7に制御
情報の付加方法の一例を示す。本例では通信回線とのデ
ータ送受信の場合で転送データに対して別領域のバッフ
ァを確保しプロトコルヘッダを付加する。プロトコルヘ
ッダの格納先頭位置は入出力装置への転送上最も効率の
良い位置とする。前記の例では32バイト境界である。
Control information addition method: When data is transferred to the input / output control device, control information is generally added to the transfer data in many cases. For example, in data transmission / reception with a communication line, a protocol header is added to transfer data. Control information is added at the kernel level. FIG. 7 shows an example of a method of adding control information. In this example, in the case of data transmission / reception with a communication line, a buffer in another area is secured for transfer data and a protocol header is added. The storage header position of the protocol header is the most efficient position for transfer to the input / output device. In the above example, it is a 32-byte boundary.

【0033】入出力制御装置からのデータ入力方法:入
出力制御装置からデータを入力する方法の一例として、
以下の方法がある。利用者プログラムは入力バッファを
利用者空間上に用意したうえでシステムコールを発行す
る。これに対してカーネルレベルのプログラムはカーネ
ル空間上に入力バッファを予め用意したうえで入出力制
御装置に対して入力要求を発行する。
Data input method from input / output control device: As an example of a method of inputting data from the input / output control device,
There are the following methods. The user program prepares an input buffer in the user space and then issues a system call. On the other hand, the kernel-level program prepares an input buffer in the kernel space in advance and issues an input request to the input / output control device.

【0034】このとき、カーネル空間上の入力バッファ
の転送データ格納先頭位置を出力の場合と同様に入出力
装置からの転送上最も効率の良い位置とする。前記例で
は32バイト境界である。一方、入出力制御装置から入
力したデータはカーネル空間に存在し、これを利用者空
間に転送する必要がある。このとき、利用者プログラム
が用意するバッファの転送データ格納位置の境界をカー
ネル空間の転送データ格納位置の境界(上記例ではロン
グワード境界)に一致させることにより効率の良い複写
処理を行うことができる。
At this time, the transfer data storage start position of the input buffer in the kernel space is set to the most efficient position for transfer from the input / output device as in the case of output. In the above example, it is a 32-byte boundary. On the other hand, the data input from the input / output control device exists in the kernel space and needs to be transferred to the user space. At this time, an efficient copy process can be performed by matching the boundary of the transfer data storage position of the buffer prepared by the user program with the boundary of the transfer data storage position of the kernel space (longword boundary in the above example). .

【0035】[0035]

【発明の効果】本発明によれば、入出力装置へ転送する
利用者データ長に応じてカーネル空間上の転送データの
格納先頭位置を調整することにより転送処理全体として
処理効率を最適化することができる。
According to the present invention, the storage efficiency of the entire transfer process is optimized by adjusting the storage start position of the transfer data in the kernel space according to the user data length transferred to the input / output device. You can

【0036】また、データの入出力を制御するための制
御情報を付加した場合でも、これを別の領域に適切な位
置から設定することにより転送処理全体として処理効率
を最適化することができる。
Further, even if control information for controlling data input / output is added, by setting this in another area from an appropriate position, the processing efficiency as a whole of the transfer processing can be optimized.

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

【図1】本発明の一実施例の入出力処理方式の構成を表
す図。
FIG. 1 is a diagram showing a configuration of an input / output processing system according to an embodiment of the present invention.

【図2】本発明の一実施例の入出力処理方式が対象とす
る計算機システムの構成を表す図。
FIG. 2 is a diagram showing a configuration of a computer system targeted by an input / output processing system according to an embodiment of the present invention.

【図3】本発明の一実施例の入出力処理方式における入
出力処理の流れを表す図。
FIG. 3 is a diagram showing a flow of input / output processing in the input / output processing method according to the embodiment of the present invention.

【図4】本発明の一実施例の入出力処理方式におけるバ
ッファ構造の一例を表す図。
FIG. 4 is a diagram showing an example of a buffer structure in an input / output processing system according to an embodiment of the present invention.

【図5】本発明の一実施例の入出力処理方式におけるメ
モリ上のデータ複写方式を表す図。
FIG. 5 is a diagram showing a data copying method on a memory in an input / output processing method according to an embodiment of the present invention.

【図6】本発明の一実施例の入出力処理方式における入
出力処理時間の一例を示す図。
FIG. 6 is a diagram showing an example of input / output processing time in the input / output processing method according to the embodiment of the present invention.

【図7】本発明の一実施例の入出力処理方式における制
御情報の付加方法を示す図。
FIG. 7 is a diagram showing a method of adding control information in the input / output processing system according to the embodiment of the present invention.

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

1…転送データ、2…転送データ、3…利用者プログラ
ム、4…システムコールライブラリ、5…システムコー
ルインタフェース、6…通信プロトコル処理部、7…プ
ロセス制御サブシステム、8…デバイスドライバ、9…
ハードウェア制御機構、10…入出力装置、11…バッ
ファ管理テーブル、12…バッファ。
1 ... Transfer data, 2 ... Transfer data, 3 ... User program, 4 ... System call library, 5 ... System call interface, 6 ... Communication protocol processing unit, 7 ... Process control subsystem, 8 ... Device driver, 9 ...
Hardware control mechanism, 10 ... I / O device, 11 ... Buffer management table, 12 ... Buffer.

───────────────────────────────────────────────────── フロントページの続き (72)発明者 高田 治 神奈川県川崎市麻生区王禅寺1099番地 株 式会社日立製作所システム開発研究所内 ─────────────────────────────────────────────────── ─── Continuation of the front page (72) Inventor Osamu Takada 1099, Ozenji, Aso-ku, Kawasaki-shi, Kanagawa Ltd. System Development Laboratory, Hitachi, Ltd.

Claims (3)

【特許請求の範囲】[Claims] 【請求項1】それぞれ独立した動作空間を持つ利用者モ
ード,カーネルモードの2つのプロセス実行モードを提
供するオペレーティングシステムの下で動作し、中央処
理装置と入出力装置との間をダイレクトメモリアクセス
方式でデータ転送を行う計算機システムで、利用者モー
ドで動作するプロセスの動作空間(利用者空間)に存在
するデータを入出力装置に転送する処理において、前記
転送のため前記データを一旦カーネルモードの動作空間
(カーネル空間)に複写するとき、データ長が計算機シ
ステムによって予め決められた長さよりも短いときはカ
ーネル空間上の転送データの格納先頭位置を入出力装置
への転送上最も効率の良い値に設定し、そうでないとき
にはカーネル空間上の転送データの格納先頭位置を利用
者空間からカーネル空間へ複写する上で最も効率のよい
値に設定することを特徴とする入出力処理方式。
1. A direct memory access system that operates under an operating system that provides two process execution modes, a user mode and a kernel mode, each of which has an independent operating space, and a central processing unit and an input / output unit. In a computer system that transfers data in the above-mentioned manner, in the process of transferring the data existing in the operation space (user space) of the process operating in the user mode to the input / output device, the data is temporarily operated in the kernel mode for the transfer. When copying to the space (kernel space), if the data length is shorter than the length predetermined by the computer system, the storage data start position in the kernel space is set to the most efficient value for transfer to the I / O device. If not set, the storage data start position in the kernel space from the user space Output processing method and setting the most efficient value in order to replicate the space.
【請求項2】利用者空間からカーネル空間へデータ複写
を行う処理において、複写するデータ長が計算機システ
ムによって予め決められた長さよりも長いとき、利用者
空間の転送データの格納先頭位置と利用者空間の転送デ
ータの格納先頭位置を一致させ、境界値に応じて最大の
データ型に対応する転送単位でデータの複写を行うこと
を特徴とする請求項1記載の入出力処理方式。
2. In the process of copying data from the user space to the kernel space, when the data length to be copied is longer than the length predetermined by the computer system, the storage start position of the transfer data in the user space and the user. 2. The input / output processing method according to claim 1, wherein the storage start positions of the transfer data in the spaces are made to coincide with each other, and the data is copied in a transfer unit corresponding to the maximum data type according to the boundary value.
【請求項3】利用者空間からカーネル空間に複写された
データに転送を制御するための制御情報を付加して入出
力装置に転送する処理において、制御情報を格納する領
域を転送データとは別に確保し、前記データと関連付
け、さらに前記制御情報を入出力装置への転送上最も効
率のよい位置から格納することを特徴とする請求項1ま
たは2記載の入出力処理方式。
3. In a process of adding control information for controlling transfer to data copied from a user space to a kernel space and transferring the data to an input / output device, an area for storing the control information is separated from the transfer data. 3. The input / output processing method according to claim 1, wherein the control information is secured and associated with the data, and the control information is stored from the most efficient position for transfer to the input / output device.
JP18923794A 1994-07-26 1994-08-11 Input/output processing system Pending JPH0855074A (en)

Priority Applications (3)

Application Number Priority Date Filing Date Title
JP18923794A JPH0855074A (en) 1994-08-11 1994-08-11 Input/output processing system
US08/505,144 US5860022A (en) 1994-07-26 1995-07-21 Computer system and method of issuing input/output commands therefrom
CN95115302.1A CN1100295C (en) 1994-07-26 1995-07-25 Computer system and method of issuing input/output commands therefrom

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP18923794A JPH0855074A (en) 1994-08-11 1994-08-11 Input/output processing system

Publications (1)

Publication Number Publication Date
JPH0855074A true JPH0855074A (en) 1996-02-27

Family

ID=16237909

Family Applications (1)

Application Number Title Priority Date Filing Date
JP18923794A Pending JPH0855074A (en) 1994-07-26 1994-08-11 Input/output processing system

Country Status (1)

Country Link
JP (1) JPH0855074A (en)

Similar Documents

Publication Publication Date Title
US6338095B1 (en) Data transfer method for reduced number of messages by message passing library and direct intermemory data transfer library and computer system suitable therefor
JP2829091B2 (en) Data processing system
JPH08235092A (en) Data transfer controller
JPH0855074A (en) Input/output processing system
US5561818A (en) Microprocessor and data processing system for data transfer using a register file
JPH0844652A (en) Computer system and method for issuing input/output instruction
JP2963696B2 (en) Data transfer control system
JP2687716B2 (en) Information processing device
JPH05113888A (en) Microprocessor unit
JPH056333A (en) Multi-processor system
JPH10507548A (en) Data processing systems and methods and communication systems with such systems
JPS59146346A (en) Communication system between processes
JPH06301607A (en) Multiaccess i/o control system
JP2856709B2 (en) Bus coupling system
JPS6240565A (en) Memory control system
JPH02123453A (en) Data transfer system for network system
JPH07200506A (en) Message communication controller
JPS58114223A (en) Data transfer controlling system
JPH03158943A (en) Buffer storage/transfer system
JPH05265925A (en) Data transfer controller
JPH04107634A (en) Memory data bypass control system
JPH10177493A (en) Graphic processing system
JPH0685154B2 (en) Intermediate buffer control method
JPH04153875A (en) Document storage system
JPH0689254A (en) Information processor