JPH04237337A - Information processor - Google Patents
Information processorInfo
- Publication number
- JPH04237337A JPH04237337A JP3005678A JP567891A JPH04237337A JP H04237337 A JPH04237337 A JP H04237337A JP 3005678 A JP3005678 A JP 3005678A JP 567891 A JP567891 A JP 567891A JP H04237337 A JPH04237337 A JP H04237337A
- Authority
- JP
- Japan
- Prior art keywords
- bit
- register
- wait
- input
- value
- 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
Links
Abstract
Description
【産業上の利用分野】本発明は並列及び並行実行可能な
情報処理装置に関するものである。BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an information processing apparatus capable of parallel execution.
【従来の技術】近年、情報処理装置は、1つの処理を複
数の細かい処理単位であるプロセスに分割し、これらを
並列及び並行に実行することにより全体の処理能力の向
上を行っている。その際プロセス間の同期処理は、計算
機の操作環境を制御するオペレーティングシステム上で
制御を行っている。以下、図面を参照しながら従来の情
報処理装置の一例について説明する。図6は、2つのプ
ロセス、すなわちWAIT命令を必要とするプロセスW
と、POST命令を必要とするプロセスPとが同期をと
る様子を示す。ここでWAIT命令とは並列に処理して
いるプロセスPが同期点に到達するのを待つ命令である
。WAIT命令がなされた場合、WAIT命令の実行中
を示すWAITビットがセットされる。POST命令と
はプロセスPを終了し、もしプロセスWが同期点に到着
しWAIT命令により待ち状態になっていれば、プロセ
スWのWAIT命令を解除する命令である。POST命
令がなされた場合、POST命令が実行された状態を示
すPOSTビットがセットされる。以降プロセスWとプ
ロセスPの並列処理を説明する。プロセスWが同期点に
到達すれば、まずプロセスPにPOSTビットがセット
されているかどうかを調べる。もし、POSTビットが
セットされていればプロセスWは処理を続行し、POS
TビットがセットされていなければプロセスWはWAI
T命令により処理を中断され、WAITビットをセット
する。プロセスPが同期点に到達すれば、プロセスWに
WAITビットがセットされているかどうかを調べる。
もし、WAITビットがセットされていればプロセスP
はプロセスWのWAIT命令を解除し、プロセスWの実
行を開始させプロセスPの処理は終了される。WAIT
ビットがセットされていなければ、プロセスPはPOS
T命令により処理が終了されPOSTビットをセットす
る。図7は複数のプロセスが結合命令信号であるJOI
Nを出力し同期をとり、一つのプロセスとなる処理を示
す。この同期をとる際に、予め定められた一つの既定プ
ロセス51以外はJOINを出力し、終了する。そして
、前記既定プロセス51は、他の全てのプロセスがJO
INを出力するまで待ち処理を行い、全てのプロセスの
JOINが出力された後に、前記既定プロセス51の残
りの処理を続行する。この時既定プロセス51以外のプ
ロセスが続行されたとしても同じ処理結果を得る。2. Description of the Related Art In recent years, information processing apparatuses have improved their overall processing power by dividing one process into a plurality of processes, which are small processing units, and executing these processes in parallel. At this time, synchronization processing between processes is controlled by an operating system that controls the operating environment of the computer. An example of a conventional information processing device will be described below with reference to the drawings. FIG. 6 shows two processes, a process W that requires a WAIT instruction.
This shows how the process P and the process P that require the POST command are synchronized. Here, the WAIT instruction is an instruction to wait for the processes P being processed in parallel to reach a synchronization point. When a WAIT instruction is issued, a WAIT bit is set indicating that the WAIT instruction is being executed. The POST instruction is an instruction that terminates process P and, if process W arrives at a synchronization point and is in a waiting state due to a WAIT instruction, releases the WAIT instruction of process W. When a POST instruction is issued, a POST bit is set indicating the state in which the POST instruction has been executed. Parallel processing of process W and process P will be described below. When process W reaches the synchronization point, it first checks whether process P has its POST bit set. If the POST bit is set, process W continues processing and the POS
If the T bit is not set, process W is WAI
Processing is interrupted by the T command and the WAIT bit is set. When process P reaches the synchronization point, it checks whether process W has its WAIT bit set. If the WAIT bit is set, then process P
cancels the WAIT command of process W, starts execution of process W, and ends processing of process P. WAIT
If the bit is not set, process P
The process is terminated by the T command and the POST bit is set. Figure 7 shows a JOI in which multiple processes have a joint instruction signal.
This shows processing that outputs N, synchronizes, and becomes one process. When this synchronization is established, all processes other than one predetermined default process 51 output JOIN and terminate. Then, the default process 51 is set to JO by all other processes.
A wait process is performed until the IN is output, and after the JOIN of all processes is output, the remaining processing of the default process 51 is continued. At this time, even if a process other than the default process 51 is continued, the same processing result will be obtained.
【発明が解決しようとする課題】しかしながら、上記の
情報処理装置では、WAIT命令とPOST命令の処理
や、あるいはJOIN命令の処理をオペレーティングシ
ステムで行っていたために、図8に示すようにWAIT
命令とPOST命令の処理の最初と最後に割り込み禁止
、解除処理が必要であった。また、WAIT命令を必要
とするプロセスは、POST命令を必要とするプロセス
の終了を待っていなければならず、WAIT命令を必要
とするプロセスの停止及び再起動処理が同期をとるため
オーバーヘッドとなる。また、全てのJOIN命令が実
行されたときに、予め定められたプロセスの残りの処理
の再実行を行う際のプロセス再起動処理もオーバーヘッ
ドとなる。さらに、プログラムのステップ数も大きくな
るために、処理時間もかかるといった課題があった。
本発明は、上記課題を解決するために従来オペレーティ
ングシステムが行っていた処理をレジスタと演算器の組
合せにより実行することにより、割り込み禁止、解除処
理を不要とし、またJOIN命令の後の再起動されるプ
ロセスも予め定められたプロセスである必要はなく、そ
のために、従来よりも高速に処理が行える情報処理装置
を提供するものである。[Problems to be Solved by the Invention] However, in the above-mentioned information processing apparatus, since the processing of WAIT and POST commands, or the processing of JOIN commands is performed by the operating system, WAIT
It was necessary to disable and release interrupts at the beginning and end of instruction and POST instruction processing. Furthermore, a process that requires a WAIT command must wait for the end of a process that requires a POST command, which causes overhead because the stopping and restarting processes of processes that require a WAIT command are synchronized. Further, when all JOIN instructions have been executed, process restart processing when re-executing the remaining processing of a predetermined process also becomes overhead. Furthermore, since the number of steps in the program increases, there is a problem in that it takes a long processing time. In order to solve the above problems, the present invention eliminates the need for interrupt disabling and canceling processing by executing the processing conventionally performed by an operating system using a combination of registers and arithmetic units, and also eliminates the need for interrupt disabling and canceling processing. The process to be executed does not need to be a predetermined process, and for this reason, the present invention provides an information processing device that can perform processing faster than before.
【課題を解決するための手段】上記課題を解決するため
に本発明の情報処理装置は、待ち状態にあるプロセスの
存在と終了状態にあるプロセスの存在を表すレジスタと
、前記レジスタの内容と入力信号から出力信号を定める
論理演算部と、同期をとるべき複数のプロセスの数を保
持するレジスタと、前記プロセスの数を保持するレジス
タの値から1を減算し再格納する減算部と、前記プロセ
スの数を保持するレジスタの値が零でないときに終了命
令信号を出力する零判定部を備えたものである。[Means for Solving the Problems] In order to solve the above problems, an information processing apparatus of the present invention includes a register indicating the existence of a process in a waiting state and a process in a termination state, and the contents and input of the register. a logical operation unit that determines an output signal from a signal; a register that holds the number of a plurality of processes to be synchronized; a subtraction unit that subtracts 1 from the value of the register that holds the number of processes and stores it again; and the process The device is equipped with a zero determination unit that outputs a termination command signal when the value of the register holding the number of is not zero.
【作用】本発明は、従来オペレーティングシステムで行
っていた処理をレジスタと演算器の組み合せで実現する
ことにより、割込み禁止、解除処理が不要となる。また
、大きくなっていたプログラムのステップ数も減少でき
、高速化をはかれる。さらに、同期のために行っていた
プロセスの停止処理、及び再実行処理を除くことができ
る。[Operation] The present invention eliminates the need for interrupt prohibition and release processing by realizing the processing conventionally performed by an operating system using a combination of registers and arithmetic units. In addition, the number of steps in the program, which had become large, can be reduced, resulting in faster speed. Furthermore, it is possible to eliminate process stop processing and re-execution processing that were performed for synchronization.
【実施例】以下、本発明の第1の実施例を図を参照しな
がら説明する。図2は、本発明の一実施例における情報
処理装置のブロック図である。図4は、レジスタの状態
と入力信号出力信号の関係図である。図2に示すように
、1はレジスタ、2は演算部、3は論理演算部である。
レジスタ1は、待ち状態にあるプロセスが存在するか否
かを示すWAITビットと、終了状態にあるプロセスが
存在するか否かを示すPOSTビットの2ビットを少な
くとも記憶する。各ビットがセットされた時に、それぞ
れのプロセスが存在することを表し、リセットされた時
には、それぞれのプロセスが存在しないことを表す。論
理演算部3では、レジスタの各ビットの状態と入力信号
の状態から出力信号を定める。本実施例では、ビットの
セットを「1」で表し、ビットのリセットを「0」で表
す正論理で説明するが、ビットの状態が逆となる負論理
でも実施可能である。 図4に、レジスタの状態と入
力信号出力信号の関係を示している。図4で示されてい
ないレジスタの状態は正常に動作している時は存在しな
い。また、「X」で示されている部分は、「0」および
「1」のいずれでもよい。論理演算部3にプロセスWが
待ち状態であることを示す待ち命令信号が入力されたと
き、プロセスPが終了状態でない場合に、論理演算部3
はWAITビットをセットしプロセスWが待ち状態であ
ることを示す待ち信号を出力する。また、既にプロセス
Pが終了状態であった場合、つまりPOSTビットがセ
ットされていた場合には、プロセスWの継続実行を行わ
せる。入力後のWAITビット、POSTビットの値は
いずれの値であってもよい。論理演算部3にプロセスP
が終了状態であることを示す終了命令信号が入力された
とき、論理演算部3はWAITビットおよびPOSTビ
ットが「0」であるとき、POSTビットをセットする
。また、既にWAITビットがセットされていれば、論
理演算部3は待ち状態となっているプロセスWの再起動
を行わせるための再起動信号を出力する。
以上のように本実施例によれば、従来オペレーティング
システムで行っていた処理の一部をレジスタと論理演算
部の組み合わせで行うため、割込み禁止、解除の処理が
不要となる。また、レジスタと論理演算部で処理を行う
ため、大きくなっていたプログラムのステップ数も小さ
くでき、高速に実行することができる。以下、本発明の
第2の実施例について説明する。図3に示すように、1
はレジスタ、2は演算部、4は減算部、5は零判定部で
ある。レジスタ1は、同期をとるべきプロセスの数から
1を減じた数を初期値として持つ。演算部2は減算部4
および零判定部5とを有している。減算部4は、結合命
令信号が入力されるたびにレジスタ1の値から1を減じ
、それをレジスタ1に再格納し、零判定部5は結合命令
信号が入力されるごとに、レジスタ1の値の零判定を実
行する。レジスタ1の値と入力信号出力信号の関係は図
5に示している。図5で「X」で示されている部分は、
いずれの値を取ってもよい。同期をとるべきプロセスが
同期点に到達したことを示す結合命令信号が入力される
たびレジスタ1の値から1を減じ、再格納する。零判定
部5で、結合命令信号が入力されるごとに、レジスタ1
の値が零であるかを判定し、レジスタ1の値が零でない
場合は、プロセスの終了を示す終了信号を出力する。終
了信号を出力されたプロセスは、その時点で処理を終了
する。レジスタ1の値が「0」になった時点で終了信号
を出力されないプロセスが発生し、そのプロセスが引き
続き残りの手続きを行う。以上のように本実施例によれ
ば、同期をとるべきプロセスの待ち状態をなくすことが
でき、停止、再起動に要する時間が短縮され、高速化が
はかれる。図1は、第1、第2の実施例を組み合わせた
第3の実施例を示すブロック図である。図において、1
はレジスタ、2は演算部、3は論理演算部、4は減算部
、5は零判定部である。その動作は第1、第2の実施例
と同様である。なお、本発明は上記実施例に限定される
物でなく、本発明の主旨に基づいて種々の変形が可能で
あり、これらを本発明の範囲から排除するものではない
。DESCRIPTION OF THE PREFERRED EMBODIMENTS A first embodiment of the present invention will be described below with reference to the drawings. FIG. 2 is a block diagram of an information processing device according to an embodiment of the present invention. FIG. 4 is a diagram showing the relationship between register states and input signals and output signals. As shown in FIG. 2, 1 is a register, 2 is an arithmetic unit, and 3 is a logical arithmetic unit. Register 1 stores at least two bits: a WAIT bit indicating whether or not there is a process in the waiting state, and a POST bit indicating whether or not there is a process in the termination state. When each bit is set, it indicates that the respective process exists; when reset, it indicates that the respective process does not exist. The logic operation unit 3 determines the output signal from the state of each bit of the register and the state of the input signal. In this embodiment, the explanation will be made using positive logic in which a bit set is represented by "1" and a bit reset is represented by "0", but it is also possible to implement negative logic in which the states of the bits are reversed. FIG. 4 shows the relationship between register states and input signals and output signals. The states of registers not shown in FIG. 4 do not exist during normal operation. Further, the portion indicated by "X" may be either "0" or "1". When the wait command signal indicating that the process W is in the waiting state is input to the logic operation unit 3, if the process P is not in the end state, the logic operation unit 3
sets the WAIT bit and outputs a wait signal indicating that process W is in a wait state. Further, if the process P is already in the finished state, that is, if the POST bit is set, the process W is caused to continue execution. The values of the WAIT bit and POST bit after input may be any value. A process P is added to the logic operation unit 3.
When a termination command signal indicating that the terminal is in the termination state is input, the logic operation unit 3 sets the POST bit when the WAIT bit and the POST bit are "0". Furthermore, if the WAIT bit has already been set, the logic operation unit 3 outputs a restart signal for restarting the process W in the waiting state. As described above, according to this embodiment, a part of the processing conventionally performed by an operating system is performed by a combination of registers and a logic operation section, so that processing for inhibiting and canceling interrupts is not necessary. Additionally, since processing is performed using registers and a logic operation section, the number of steps in a previously large program can be reduced, allowing for faster execution. A second embodiment of the present invention will be described below. As shown in Figure 3, 1
2 is a register, 2 is an arithmetic unit, 4 is a subtraction unit, and 5 is a zero determination unit. Register 1 has as an initial value the number of processes to be synchronized minus 1. Arithmetic unit 2 is subtraction unit 4
and a zero determination section 5. The subtraction unit 4 subtracts 1 from the value of register 1 every time a combination command signal is input, and stores it again in register 1, and the zero determination unit 5 subtracts 1 from the value of register 1 every time a combination command signal is input. Executes zero judgment of value. The relationship between the value of register 1 and the input signal and output signal is shown in FIG. The part indicated by “X” in Figure 5 is
It can take either value. Each time a combination command signal indicating that a process to be synchronized has reached a synchronization point is input, 1 is subtracted from the value of register 1 and the value is re-stored. In the zero determination unit 5, every time the combination command signal is input, the register 1 is
It is determined whether the value of register 1 is zero, and if the value of register 1 is not zero, an end signal indicating the end of the process is output. The process to which the termination signal has been output terminates its processing at that point. When the value of register 1 becomes "0", a process to which no end signal is output is generated, and that process continues to perform the remaining procedures. As described above, according to this embodiment, it is possible to eliminate the waiting state of processes to be synchronized, and the time required for stopping and restarting is shortened, thereby increasing speed. FIG. 1 is a block diagram showing a third embodiment which is a combination of the first and second embodiments. In the figure, 1
2 is a register, 2 is a calculation section, 3 is a logic operation section, 4 is a subtraction section, and 5 is a zero determination section. Its operation is similar to the first and second embodiments. Note that the present invention is not limited to the above-mentioned embodiments, and various modifications can be made based on the gist of the present invention, and these are not excluded from the scope of the present invention.
【発明の効果】本発明は、以上説明したような装置であ
るので、以下に記載されるような効果を奏する。レジス
タと論理演算部の組み合わせにより、プロセスの同期処
理を行うため、割込みの禁止、解除の処理が不要となり
、また、高速化をはかることができる。さらに、同期待
ちをしていたプロセスがなくなるため、プロセスの停止
、再起動に要する時間もなくなり、高速化がはかれる。[Effects of the Invention] Since the present invention is a device as described above, it produces the effects as described below. Since the combination of registers and logical operation units performs process synchronization processing, processing for inhibiting and canceling interrupts is not necessary, and speeding up can be achieved. Furthermore, since there are no processes waiting for synchronization, the time required to stop and restart processes is also eliminated, increasing speed.
【図1】本発明の一実施例の情報処理装置の構成図であ
る。FIG. 1 is a configuration diagram of an information processing apparatus according to an embodiment of the present invention.
【図2】本発明の一実施例の情報処理装置の構成図であ
る。FIG. 2 is a configuration diagram of an information processing device according to an embodiment of the present invention.
【図3】本発明の一実施例の情報処理装置の構成図であ
る。FIG. 3 is a configuration diagram of an information processing device according to an embodiment of the present invention.
【図4】レジスタの状態と入出力信号の関係図である。FIG. 4 is a diagram showing the relationship between register states and input/output signals.
【図5】レジスタの状態と入出力信号の関係図である。FIG. 5 is a diagram showing the relationship between register states and input/output signals.
【図6】従来例における一情報処理方式図である。FIG. 6 is a diagram of one information processing method in a conventional example.
【図7】従来例における一情報処理方式図である。FIG. 7 is a diagram of one information processing method in a conventional example.
【図8】従来例における処理の流れ図である。FIG. 8 is a flowchart of processing in a conventional example.
1 レジスタ 2 演算部 3 論理演算部 4 減算部 5 零判定部 51 既定プロセス 1 Register 2 Arithmetic unit 3 Logic operation section 4 Subtraction section 5 Zero judgment section 51 Default process
Claims (3)
るプロセスが存在することを表し、第2のビットのセッ
トで終了状態にあるプロセスが存在することを表す読み
書き可能なレジスタと、待ち命令信号が入力されたとき
前記第1のビット及び前記第2のビットが共にセットさ
れていないと前記第1のビットをセットし、待ち命令信
号が入力されたとき前記第2のビットがセットされてい
れば待ち信号を出力し、終了命令信号が入力されたとき
前記第1のビット及び前記第2のビットが共にセットさ
れていないと前記第2のビットをセットし、終了命令信
号が入力されたとき前記第1のビットがセットされてい
ると再起動信号を出力する論理演算部とを具備すること
を特徴とした情報処理装置。1. A readable/writable register whose first bit is set to indicate the existence of a process in a waiting state and whose second bit is set to indicate the presence of a terminated process, and a wait instruction. If the first bit and the second bit are not both set when a signal is input, the first bit is set, and when the wait command signal is input, the second bit is set. If the first bit and the second bit are not both set when the end command signal is input, the second bit is set, and when the end command signal is input, the second bit is set. An information processing device comprising: a logic operation unit that outputs a restart signal when the first bit is set.
スタと、結合命令信号が入力されたときに前記レジスタ
の値から1を減算する減算部と、前記レジスタの値が零
であるか否かを判定し零でないときに終了信号を出力す
る零判定部とを具備することを特徴とした情報処理装置
。2. A readable and writable register that holds a certain value, a subtractor that subtracts 1 from the value of the register when a combination command signal is input, and a subtractor that subtracts 1 from the value of the register, and a subtractor that subtracts 1 from the value of the register when a combination command signal is input. An information processing device comprising: a zero determination unit that outputs an end signal when the result is determined to be non-zero.
スタと、結合命令信号が入力されたときに前記レジスタ
の値から1を減算する減算部と、前記レジスタの値が零
であるか否かを判定し零でないときに終了信号を出力す
る零判定部とを具備することを特徴とした請求項1記載
の情報処理装置。3. A readable and writable register that holds a certain value, a subtraction unit that subtracts 1 from the value of the register when a combination command signal is input, and a subtractor that subtracts 1 from the value of the register, and a subtractor that subtracts 1 from the value of the register when a combination command signal is input. 2. The information processing apparatus according to claim 1, further comprising a zero determination section that outputs an end signal when the determination result is not zero.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP3005678A JPH04237337A (en) | 1991-01-22 | 1991-01-22 | Information processor |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP3005678A JPH04237337A (en) | 1991-01-22 | 1991-01-22 | Information processor |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JPH04237337A true JPH04237337A (en) | 1992-08-25 |
Family
ID=11617756
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP3005678A Pending JPH04237337A (en) | 1991-01-22 | 1991-01-22 | Information processor |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPH04237337A (en) |
-
1991
- 1991-01-22 JP JP3005678A patent/JPH04237337A/en active Pending
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| JPS63238630A (en) | Interruption controller for microprocessor | |
| EP0335990B1 (en) | Processor-processor synchronization | |
| JPS60118977A (en) | Pipeline control system | |
| JPH0414376B2 (en) | ||
| JPH0485630A (en) | Interruption controller | |
| JPH01243167A (en) | data processing equipment | |
| JPS5868162A (en) | Retry processing system | |
| JPH05250161A (en) | Microcomputer device | |
| JPH0418655A (en) | Data processor | |
| JPS6265134A (en) | Interruption processing system | |
| JP2001350633A (en) | Signal processor | |
| JPH0495153A (en) | Synchronizing system for asynchronous processing in data processor | |
| JP2000305782A (en) | Arithmetic unit | |
| JPS6252900B2 (en) | ||
| JPH03119429A (en) | Interruption control system for data processor | |
| JPH03263128A (en) | Microprocessor | |
| JPH04280326A (en) | Information processor | |
| JPS61211745A (en) | Microcomputer | |
| JPH0553831A (en) | Computer unit with interrupting function | |
| JPS60247743A (en) | Pipeline arithmetic controller | |
| JPH03255529A (en) | Pipeline processor | |
| JPH0125099B2 (en) | ||
| JPS60147845A (en) | System for controlling load of circulating pipeline type data flow computer | |
| JPH05324349A (en) | Interruption processor | |
| JPH11120004A (en) | Signal processor |