JPH0421900B2 - - Google Patents
Info
- Publication number
- JPH0421900B2 JPH0421900B2 JP59034450A JP3445084A JPH0421900B2 JP H0421900 B2 JPH0421900 B2 JP H0421900B2 JP 59034450 A JP59034450 A JP 59034450A JP 3445084 A JP3445084 A JP 3445084A JP H0421900 B2 JPH0421900 B2 JP H0421900B2
- Authority
- JP
- Japan
- Prior art keywords
- data
- processing
- input
- pes
- vector data
- 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
Links
Landscapes
- Multi Processors (AREA)
- Complex Calculations (AREA)
- Image Processing (AREA)
- Character Discrimination (AREA)
Description
【発明の詳細な説明】
〔発明の技術分野〕
本発明は、例えば音声認識や文字認識において
パターンのマツチングをとる際などに利用される
ダイナミツクプログラミングに基づくマツチング
演算に代表されるような、2種類の変数間のあら
ゆる組合せに対する演算およびその演算結果を用
いたデータの局部的依存性をもつ漸化式の演算の
実行に使用するアレイプロセツサに関する。[Detailed Description of the Invention] [Technical Field of the Invention] The present invention relates to a matching operation based on dynamic programming, which is used, for example, when matching patterns in speech recognition or character recognition. The present invention relates to an array processor used to perform operations on all combinations of variables of different types, and to perform operations on recurrence formulas with local data dependence using the results of the operations.
代表例として、2種類のベクトル変数間の演算
とその演算結果を用いた累積演算の漸化式からな
るダイナミツクプログラミングに基づくマツチン
グ演算の一例を以下に示す。
As a representative example, an example of a matching operation based on dynamic programming, which consists of an operation between two types of vector variables and a recurrence formula of an accumulation operation using the operation results, will be shown below.
Dij=|ci−rj|2=n
〓k=1
|cKi−rKj|2 …(1)
Sij=Dij+mmSi,j-1
Si-1,j-1
Si-1,j …(2)
Spj=∞,Sip=∞,Spp=O …(3)
ここで、ci,rjは、それぞれI個のベクトル列
C={c1,c2,……,c1}、N個のベクトルR=
{r1,r2,……,rN}のi番目、j番目の要素で
ある。また、mは各ベクトルの次数を表わし、ci
=(c1 i,c2 i,……,cn i),rj=(r1 j,r2 j,……,r
n
j)である。Dij,Sijは、それぞれベクトル間距
離,累積距離を表わす。(3)式は、漸化式(2)の初期
条件である。D ij =|c i −r j | 2 = n 〓 k=1 |c K i−r K |j| 2 …(1) S ij =D ij +mmS i,j-1 S i-1,j-1 S i-1,j …(2) S pj =∞, S ip =∞, S pp =O …(3) Here, c i and r j are I vector sequences C = {c 1 , c 2 , ..., c 1 }, N vectors R=
These are the i-th and j-th elements of {r 1 , r 2 , ..., r N }. Also, m represents the order of each vector, and c i
= (c 1 i , c 2 i , ..., c n i ), r j = (r 1 j , r 2 j , ..., r
n
j ). D ij and S ij represent the distance between vectors and the cumulative distance, respectively. Equation (3) is the initial condition of recurrence equation (2).
この種の演算を並列に処理できるアレイプロセ
ツサとして、従来、2種類のベクトル列のデータ
の個数がそれぞれI,Nの場合には(I×N)個
の処理要素(プロセシングエレメント;以下PE
と略記する)を2次元に配列した構成がある。こ
の構成を第1図に、その動作例を第2図〜第5図
に示す。第1図において、100はPE、200
はデータバス、300はコントロールバスを示
す。また400は入力端子を示し、500は出力
端子を示す。 Conventionally, as an array processor that can process this type of operation in parallel, when the number of data of two types of vector strings is I and N, respectively, (I × N) processing elements (processing elements; hereinafter referred to as PE
) are arranged in two dimensions. This configuration is shown in FIG. 1, and examples of its operation are shown in FIGS. 2 to 5. In Figure 1, 100 is PE, 200
indicates a data bus, and 300 indicates a control bus. Further, 400 indicates an input terminal, and 500 indicates an output terminal.
各PE100は、積和演算からなるベクトル間
距離演算(1)式と比較・累積演算(2)式を実行する手
段および隣接するPEとの間で比較演算結果や累
積結果Sij、ベクトルデータci,rjの授受を行なう
手段を有する。なお、各PEに2次元配列上での
位置を表す番号を付記し、i行j行のPEをPEij
と表わすと次のような動作で上記(1),(2),(3)を実
行することができる。 Each PE 100 has means for executing vector distance calculation (1) and comparison/accumulation calculation (2) consisting of product-sum calculations, as well as means for executing comparison calculation results, cumulative results S ij , and vector data c between adjacent PEs. It has means for sending and receiving i and r j . Note that each PE is given a number indicating its position on the two-dimensional array, and the PE in row i and j is PE ij
Expressed as , the above (1), (2), and (3) can be executed by the following operations.
左隣接のPEi-1,jおよび下隣接のPEi,j-1(ま
たは、左端の入力端子および下端の入力端子)
から2種類のベクトルデータci,rjを入力し、
そのベクトル間距離を(1)式を実行することによ
り求める。 Left-adjacent PEs i-1 , j and lower-adjacent PEs i , j-1 (or the leftmost input terminal and the bottommost input terminal)
Input two types of vector data c i and r j from
The distance between the vectors is determined by executing equation (1).
右隣接のPEi+1,jおよび上隣接のPEi,j+1に、
それぞれベクトルデータci,rjを転送する。 To the right neighboring PE i+1 , j and the upper neighboring PE i , j+1 ,
Transfer vector data c i and r j respectively.
左隣接のPEi-1,jから累積演算結果Si-1,jを、
下隣接のPEi,j-1からmm(Si,j-1,Si-1,j-i)の比
較演算結果をそれぞれ入力し、これらの比較演
算mm〔Si-1,j,mm(Si,j-1,Si-1,j-1)〕を実行
し、この結果にで求めたDijを加えてSijを求
める。 The cumulative operation result S i -1 , j from the left adjacent PE i- 1 , j is
Input the comparison operation results of mm (S i , j -1 , S i-1 , ji ) from the lower adjacent PE i , j-1 , respectively, and calculate these comparison operations mm [S i-1 , j , mm ( S i , j-1 , S i-1 , j-1 )] and add D ij obtained in to this result to obtain S ij .
比較演算mm(Sii,Si-1,j)を実行し、その演
算結果を上隣接のPEi,j+1へ、累積演算結果Sij
を右隣接のPEi+1,jへ転送する。 Execute the comparison operation mm (S ii , S i-1 , j ), transfer the operation result to the upper neighboring PE i , j+1 , and apply the cumulative operation result S ij
is transferred to the right-adjacent PEs i+1 and j .
ここで、,は、比較・累積演算(2)式を実行
する過程を示している。すなわち、PEijにおいて
累積演算(2)式を実行するために必要な3種類の累
積結果Si,j-1,Si-1,j,Si-1,j-1のうち、Si,j-1,
Si-1,jはそれぞれ転送すべきPEijの下隣接のPEi,j
−1および左隣接のPEi-1,jに存在するのに対し、
Si-1,j-1はPEijに対して対角方向に隣接した
PEi-1,j-1に存在する。このため、前者の2つの
データは1回の転送、後者はPEi,j-1を経由して
2回の転送を必要とする。しかし、Si-1,j-1の転
送に介在するPEi,j-1においてあらかじめSi,j-1と
Si-1,j-1)とを比較してその結果をPEijに転送し、
このデータとPEi-1,jからの転送データSi-1,jとの
比較演算を実行するようにすれば、PEijにおいて
(2)式通りの3つのデータの比較演算を実行するこ
とと等価になる。 Here, , indicates the process of executing the comparison/accumulation operation (2). That is, among the three types of cumulative results S i , j-1 , S i-1 , j , S i-1 , j-1 necessary to execute cumulative operation (2) in PE ij , S i , j-1 ,
S i-1 , j are PE i , j below the PE ij to be transferred, respectively
−1 and the left adjacent PE i-1 , j , whereas
S i-1 , j-1 are diagonally adjacent to PE ij
Exists in PE i-1 , j-1 . Therefore, the former two data require one transfer, and the latter requires two transfers via PE i and j-1 . However, in PE i , j-1 that intervenes in the transfer of S i-1 , j-1, S i , j-1 and
S i-1 , j-1 ) and transfer the result to PE ij ,
If a comparison operation is performed between this data and the transfer data S i -1 , j from PE i-1 , j , then at PE ij ,
(2) This is equivalent to performing a comparison operation on three data as shown in formula (2).
これらの各動作を、第1図の実線で示す各対角
線上の全PEに対して〜の動作をPEの並列処
理単位として実行する方法、あるいは、と、
との2種類の動作を並列処理単位としてこれ
を隣接する対角線上のPEで交互に実行する方法
により、ベクトル間距離Dij,累積結果Sijを計算
しながら最終的な累積結果SI,Nを求めることがで
きる。このうち、後者の実行方法の場合は、2つ
の並列処理単位間の有効なダイナミツクステツプ
数が異なるため、(ノー・オペレーシヨン)NOP
命令によつて実行ステツプ数を調整しなければな
らないが、ここでは詳細な説明は省略する。第2
図〜第5図は、この後者の場合の2次元配列アレ
イ上での動作を、時刻tから時刻t+3にわたつ
て示したものである。ここで、時刻は、各PEが
とおよびとの全処理を実行するのに要す
る時間を単位としており、各図a,bはそれぞれ
各PEにおいて上記単位時間中に矩形で囲まれた
データが算出された状態を示している。 A method of performing each of these operations as a parallel processing unit of PEs for all PEs on each diagonal line shown by the solid line in FIG. 1, or,
The final cumulative result S I , N is computed while calculating the inter-vector distance D ij and the cumulative result S ij by using two types of operations as parallel processing units and executing them alternately on adjacent diagonal PEs. can be found. In the case of the latter execution method, the effective number of dynamic steps between the two parallel processing units is different, so (no operation) NOP
Although the number of execution steps must be adjusted depending on the instruction, detailed explanation will be omitted here. Second
5 to 5 show the operation on the two-dimensional array in this latter case from time t to time t+3. Here, the time is the time required for each PE to execute all the processes of and, and each figure a and b shows the data enclosed in the rectangle calculated in each PE during the above unit time. It shows the state that has been applied.
このような2次元配列構成では、一応演算の局
所性・規則性が生かされて並列処理を実行でき
る。しかし、例えば上記のダイナミツクプログラ
ミングに基づくマツチング演算式(2)式が(4)式に示
すような複雑な演算式である場合には、(4)式の累
積結果Si-1,j-1,Si-1,j-2,Si-2,j-1の転送と比較
演
算の対象となる3つのデータを生成する演算につ
いて2個のPEを介して実行しなければならず、
PEijでの比較演算はこれらの3つのデータをPEij
内に入力してから実行する方法をとるなど各PE
が並列に実行すべき処理単位の内容が複雑になる
ばかりでなく、全PEを十分効率良く使用した並
列処理は実行できない。 In such a two-dimensional array configuration, parallel processing can be executed by taking advantage of the locality and regularity of operations. However, for example, if the matching calculation formula (2) based on the dynamic programming described above is a complex calculation formula as shown in formula (4), the cumulative results of formula (4) S i-1 , j- 1 , S i-1 , j-2 , S i-2 , j-1 , operations that generate three data to be subjected to the transfer and comparison operations must be performed via two PEs,
The comparison operation in PE ij converts these three data into PE ij
Each PE
Not only does the content of the processing unit that should be executed in parallel become complicated, but it is also impossible to execute parallel processing using all PEs efficiently.
Sij=DijmmSi-2,j-1+2Di-1,j
Si-1,j-1+Dij
Si-1,j-2+2Di,1-j …(4)
また、対象とするダイナミツクプログラミング
に基づくマツチング演算で処理すべき2種類のベ
クトル列のデータの個数を表わす正整数N及びI
の両方に依存してPEの個数を決定しなければな
らないので、多種のベクトル列Cu(Cu={c1 u,c2
u,……,c1u u};u=1,2……,lc)と多種の
ベクトル列Rv(Rv={r1 v,r2 v……,rNv v};v=
1,2……,lr)とのダイナミツクプログラミン
グに基づくマツチング演算を実行するためには、
正整数N,Iとして
Nmax=(
max
1≦v≦lrNv),
Imax=(
max
1≦v≦lrIu)
を選ばなければならず、PEの個数は(Nmax×
Imax)個必要とする。したがつて、ベクトル列
Cu,Rvに対する処理を行なう場合は、Cmax,
Rmaxの組合せ以外のすべてのベクトル列の組合
せに対して、ダイナミツクプログラミングに基づ
くマツチング演算処理の動作を実行する必要のな
いPEが多数存在することとなり、ハードウエア
の有効利用が図れない。S ij =D ij mmS i-2,j-1 +2D i-1,j S i-1,j-1 +D ij S i-1,j-2 +2D i,1-j …(4) Also, the target positive integers N and I that represent the number of data of two types of vector sequences to be processed in a matching operation based on dynamic programming.
Since the number of PEs must be determined depending on both of
u , ..., c 1u u }; u=1, 2..., l c ) and various vector sequences R v (R v = {r 1 v , r 2 v ..., r Nv v }; v=
In order to perform a matching operation based on dynamic programming with 1, 2..., l r ),
As positive integers N and I, Nmax=( max 1≦v≦lrNv), Imax=( max 1≦v≦lrIu) must be selected, and the number of PEs is (Nmax×
Imax) pieces are required. Therefore, the vector sequence
When processing C u and R v , Cmax,
For all combinations of vector sequences other than the Rmax combination, there are many PEs that do not need to perform matching calculation processing based on dynamic programming, making it impossible to use hardware effectively.
また、必要なPEの個数を処理すべきデータの
個数の最大値から決定しなければならないこと
は、LSI技術により小形化を図る場合に大きな支
障となる。1個のLSIに搭載できるPEの個数は
PEの機能により異なるが、例えば、1個のLSI
に4個程度のPEを搭載できるとともに、Nmax
60,Imax60の場合には900個ものLSIを2次
元に配列・接続しなければならない。 Furthermore, the fact that the number of required PEs must be determined from the maximum number of data to be processed is a major hindrance when attempting to downsize using LSI technology. The number of PEs that can be mounted on one LSI is
It depends on the PE function, but for example, one LSI
About 4 PEs can be installed in the Nmax
60. In the case of Imax60, as many as 900 LSIs must be arranged and connected in two dimensions.
そこで、本発明の目的は、ダイナミツクプログ
ラミングに基づくマツチング演算に代表される2
種類の変数間のあらゆる組合せに対する演算とそ
の演算結果を用いたデータの局所的依存性をもつ
漸化式の演算を、対象とする演算量に適応した
PE数からなるアレイ構成で、各PEを有効に動作
させながら、高効率の並列処理で実現することが
可能なアレイプロセツサを提供することにある。
Therefore, an object of the present invention is to perform two-way matching operations based on dynamic programming.
The calculations for all combinations of variables of different types and the calculation of recurrence formulas with local data dependence using the calculation results are adapted to the target amount of calculations.
The object of the present invention is to provide an array processor that can realize highly efficient parallel processing while effectively operating each PE in an array configuration consisting of a number of PEs.
このような目的を達成するために、本発明は、
それぞれ外部からの2種類の入力データ列C=
{ci}(i=1,2,……,I)およびR={rj}
(j=1,2,……,N)の各データci,rjを入力
する手段と、2種類のデータ間の加減算、比較演
算および積和演算の各所望の演算を行ないその結
果を蓄える手段と、入力データciおよび演算結果
を隣接処理要素との間で送受する手段と、最終的
な演算結果を外部に出力する手段とを備えた処理
要素をn個環状に配列するとともに、各処理要素
間を、隣接処理要素とのデータ授受を行なうため
のデータ転送パスと外部入力パスとを切り換える
マルチプレクサを介して環状に接続し、かつ全処
理要素がその処理結果を隣接処理要素へ、入力デ
ータ列Cの中の連続するn個分ずつの入力データ
の入れ換えごとに、(m
on
dN)回転送する処理を
各処理要素における通常の処理単位と並列に実行
する手段ならびにこれら各処理要素を制御する手
段を備えたものである。 In order to achieve such an objective, the present invention
Two types of input data strings C = each from the outside
{c i }(i=1,2,...,I) and R={r j }
Means for inputting each data c i , r j of (j=1, 2, ..., N), performing each desired operation such as addition/subtraction, comparison operation, and product-sum operation between two types of data and outputting the results. N processing elements each having storage means, means for transmitting and receiving input data c i and operation results between adjacent processing elements, and means for outputting the final operation results to the outside are arranged in a ring, and Each processing element is connected in a circular manner via a multiplexer that switches between a data transfer path and an external input path for exchanging data with adjacent processing elements, and all processing elements transmit their processing results to adjacent processing elements. Means for executing the process of transferring (m o n dN) times in parallel with the normal processing unit in each processing element every time n consecutive pieces of input data in the input data string C are replaced, and each of these processes It is equipped with means for controlling the elements.
ここで、modNはNをnで割つた場合の剰余を
表わす。なお、IおよびNならびにnは任意の正
整数であるが、実際上はNとnとの関係はm
on
dNが成立する範囲で規定される。以下、実施例
を用いて本発明を詳細に説明する。 Here, modN represents the remainder when N is divided by n. Note that I, N, and n are arbitrary positive integers, but in reality, the relationship between N and n is m o n
It is defined within the range where dN holds true. Hereinafter, the present invention will be explained in detail using Examples.
ダイナミツクプログラミングに基づくマツチン
グ演算の一例である上記の演算式(1),(2),(3)を2
種類のベクトル列Cu,Rv(u=1,2,……,lc,
v=1,2,……,lr)について実行する場合に
ついて示す。第6図に、本発明の一実施例の構成
を示す。
The above equations (1), (2), and (3), which are examples of matching operations based on dynamic programming, can be transformed into 2
vector sequences C u , R v (u=1, 2,..., l c ,
The case of execution for v=1, 2, . . . , l r ) will be described. FIG. 6 shows the configuration of an embodiment of the present invention.
第6図は、PEの個数がnの場合を示し、1は
この処理要素PEで、ダイナミツクプログラミン
グに基づくマツチング演算式(1),(2),(3)を実行す
るための加減算、比較演算や積和演算を実行する
演算器を内蔵し、隣接するPEとのデータ授受や
外部とのデータ授受を実行するためのレジスタお
よび演算結果や転送データを蓄積するメモリを有
する。2−1〜2−nは外部からの入力データci
u(i=1,2,……,Iu)をn個分(PEの個数
分)ずつアレイに入力する場合と隣接PEからの
循環転送される入力データci u(i=1,2,…
…,Iu)の転送の場合とを切り換えるためのマル
チプレクサである。例えばアレイの各PEのn個
の入力データ列c1 u,c2 u,……,co uをPE1から
入力する場合、2−1のマルチプレクサだけが外
部からの入力データバス3を選択し、これを外部
からの入力データ列c1 u,c2 u……,co uの入力口と
し、PE1を起点として入力されたデータci uは隣
接PEへ順々に転送する方法でn個分のデータc1
u,c2 u,……,co uを各PEに1個ずつ割付ける。
それ以外の場合は2−1〜2−nのすべてのマル
チプレクサがPE間のデータ転送バス5を選択し、
入力データ列c1 u,c2 u,……,co uをPE間で循環
転送する。また、各PEは、後述するように上記
n個分ずつの入力データパターンの入れ換えごと
に、modN回、通常の処理単位と並列に、それぞ
れの処理結果を隣接PEへ同時に転送することが
できる構成となつている。4は他方の入力ベクト
ルデータ列RV={r1 V,r2 V,……rNV V}(k=1,
2,……lr)の各ベクトルデータを各PEに順次入
力するとともに最終的な演算結果SI1,N1,SI1,N2
……SIu,NV……SIlc,Nlrを外部に出力するための
I/Oバスである。上記5は、PE間でのベクト
ルデータci uの循環転送ならびに累積演算結果Sij
の転送を実行するためのデータ転送バスである。
6はI/Oバスに接続される各PEのI/O端子
である。また、7,8,9は、それぞれ入力ベク
トルデータci u,r1 V(i=1,2,……Iu;j=
1,2,……,Nv;u=1,2,……lc;v=
1,2,……lr)および最終的な演算結果SI1,N1,
SI1,N2……SIuNV……SIlc,Nlrを示す。さらに10
は上記入力データの入れ換えのタイミングの判断
や処理結果の転送回数の計数をはじめ、システム
全体の制御動作を行なうコントロールユニツトで
ある。 Figure 6 shows the case where the number of PEs is n, and 1 is this processing element PE, which performs addition, subtraction, and comparison to execute matching calculation formulas (1), (2), and (3) based on dynamic programming. It has a built-in arithmetic unit that performs arithmetic operations and sum-of-products operations, registers for exchanging data with adjacent PEs and external devices, and memory that stores operational results and transferred data. 2-1 to 2-n are external input data c i
When u (i=1, 2, ..., I u ) are input to the array n pieces (for the number of PEs), and when input data c i u (i=1, 2) are transferred cyclically from adjacent PEs. ,…
..., I u ). For example, when n input data strings c 1 u , c 2 u , ..., c o u of each PE in the array are input from PE 1, only the multiplexer 2-1 selects input data bus 3 from the outside. , this is used as the input port for the external input data string c 1 u , c 2 u . Individual data c 1
Assign one u , c 2 u , ..., c o u to each PE.
Otherwise, all multiplexers 2-1 to 2-n select the inter-PE data transfer bus 5,
The input data strings c 1 u , c 2 u , ..., c o u are transferred cyclically between PEs. In addition, as described later, each PE is configured to be able to simultaneously transfer each processing result to the adjacent PE in parallel with the normal processing unit modN times for each exchange of the above n input data patterns. It is becoming. 4 is the other input vector data string R V = {r 1 V , r 2 V , ... r NV V } (k = 1,
2,...l r ) are input sequentially to each PE, and the final calculation results S I1 , N1 , S I1 , N2
...S Iu , NV ...S Ilc , Nlr are I/O buses for outputting them to the outside. 5 above involves the circular transfer of vector data c i u between PEs and the cumulative operation result S ij
This is a data transfer bus for executing transfers.
6 is an I/O terminal of each PE connected to the I/O bus. In addition, 7, 8, and 9 are input vector data c i u , r 1 V (i=1, 2,...I u ; j=
1,2,...,N v ;u=1,2,...l c ;v=
1, 2, ... l r ) and the final calculation results S I1 , N1 ,
S I1 , N2 ... S IuNV ... S Ilc , N lr are shown. 10 more
is a control unit that performs control operations for the entire system, including determining the timing of exchanging the input data and counting the number of transfers of processing results.
第7図に、各PEの構成例を示す。図において、
1点鎖線で囲んだ部分が1個のPE1を示し、1
1は各PEへのベクトルデータrj V(j=1,2,
……,NV)の入力および最終的な演算結果SIuNv
の出力を行なうための外部I/Oバス、12はこ
の外部I/Oバス11とのデータ授受を行なうた
めのI/O端子を示す。また13は左隣接PEか
らのデータ転送バス端子、14は右隣接PEへの
データ転送バス端子を示す。15は外部I/Oバ
ス11からベクトルデータrjを入力するためのバ
ツフアレジスタ、16は外部I/Oバス11へ最
終的な演算結果SIu,NVを出力するためのバツフ
アレジスタ、17は隣接PEからベクトルデータ
ci u(i=1,2,……Iu)の入力および後述する
処理動作b○,c○で実行される累積演算Sijの計算
に必要なデータの入力を行なうためのレジスタ、
18は隣接PEへベクトルデータci uおよび累積演
算Sijの計算に必要なデータの転送を行なうため
のレジスタ、19は内部バスである。20,21
は、それぞれこのPEに入力されるベクトルデー
タr1 V,ci uの全成分rk vj,ck ui(k=1,2,……,
m)を蓄えるバツフアメモリ、22は(1),(2)式の
演算を実行するための加減算・比較演算・積和演
算機能を有する演算ユニツトであり、23は(2),
(3)式を実行する際に必要なデータを保持しておく
ためのワークメモリである。ワークメモリ23
は、その保持するデータの性格上、2種類の領域
23−1と23−2とに分かれる。すなわち、2
3−1は後述する入力ベクトルデータci uの循環
転送時での処理動作a○,b○,c○の実行において必
要なデータを保持する領域であり、23−2はベ
クトル列C1,C2,……Clcのうちのn個のベクト
ル列の入れ換え直後の処理動作b○,c○の実行時に
必要となるデータの保持領域である。24は制御
ユニツトであり、内蔵のマイクロプログラムある
いは外部からの命令に従つて制御を行なう。25
が第6図のコントロールユニツト10からの制御
信号に入力端である。26,27はワークメモリ
へのアドレス線を示す。そのうち、26はカウン
タ28が演算途中結果を保持する領域23−2を
アクセスするものであるのに対し、27は例えば
マイクロプログラムからの直接アドレスに相当
し、上記処理動作b○,c○の個々の処理に必要なデ
ータの蓄積領域23−1をアクセスする。 FIG. 7 shows an example of the configuration of each PE. In the figure,
The part surrounded by the dashed line indicates one PE1,
1 is the vector data r j V (j=1, 2,
..., N V ) and the final calculation result S Iu N v
An external I/O bus 12 indicates an I/O terminal for exchanging data with the external I/O bus 11. Further, 13 indicates a data transfer bus terminal from the left adjacent PE, and 14 indicates a data transfer bus terminal to the right adjacent PE. 15 is a buffer register for inputting vector data r j from the external I/O bus 11; 16 is a buffer register for outputting the final calculation results S Iu , N V to the external I/O bus 11; 17 is vector data from adjacent PE
A register for inputting data necessary for inputting c i u (i = 1, 2, ... I u ) and calculating the cumulative operation S ij executed in processing operations b○, c○ described later;
18 is a register for transferring vector data c i u and data necessary for calculating the cumulative operation S ij to an adjacent PE, and 19 is an internal bus. 20, 21
are all components r k vj , c k ui ( k = 1 , 2 , ...,
22 is an arithmetic unit having addition/subtraction, comparison, and product-sum operation functions for executing the operations of formulas (1) and (2); 23 is a buffer memory for storing (2),
(3) This is a work memory for holding the data required when executing the formula. Work memory 23
is divided into two types of areas 23-1 and 23-2 due to the nature of the data it holds. That is, 2
3-1 is an area for holding data necessary for executing processing operations a○, b○, c○ during circular transfer of input vector data c i u , which will be described later ; C 2 , . . . Cl This is a storage area for data required when executing processing operations b○ and c○ immediately after exchanging n vector sequences of c . 24 is a control unit, which performs control according to a built-in microprogram or external instructions. 25
is the input terminal for the control signal from the control unit 10 in FIG. 26 and 27 indicate address lines to the work memory. Of these, 26 is for accessing the area 23-2 in which the counter 28 holds the intermediate results of calculations, while 27 corresponds to, for example, a direct address from the microprogram, and is used to access each of the above processing operations b○ and c○. The storage area 23-1 for data necessary for processing is accessed.
上述したように、演算ユニツト22における演
算結果はワークメモリ23に保持されるが、隣接
PE間でのデータ転送用にレジスタ17,18を
備えており、上記演算結果をワークメモリ23か
らレジスタ18に取り込んでそこから隣接PEの
レジスタ17に転送している間に、演算ユニツト
22においては次の演算が行なえるような構成と
なつている。したがつて、後述するa○,b○,c○か
らなる入力データciの転送を行なつてDij,Sijを演
算し結果を転送するという通常の処理単位と並行
して、つまり通常の処理の流れを全く乱すことな
く、入力データパターンの入れ換えの際には、各
PEが上記演算を実行している間を利用して、後
述するようなm
on
dN回の処理結果の隣接PEへの
同時転送を行なうことが可能である。 As mentioned above, the calculation results in the calculation unit 22 are held in the work memory 23, but the
It is equipped with registers 17 and 18 for data transfer between PEs, and while the above calculation result is fetched from the work memory 23 into the register 18 and transferred from there to the register 17 of the adjacent PE, the calculation unit 22 The configuration is such that the following calculations can be performed. Therefore, in parallel with the normal processing unit of transferring input data c i consisting of a○, b○, c○, calculating D ij and S ij , and transferring the results, that is, normal When replacing input data patterns, each
It is possible to simultaneously transfer m o n dN processing results to adjacent PEs, as will be described later, while the PE is executing the above calculation.
次に、本構成で上記の演算式(1),(2),(3)で示さ
れるダイナミツクプログラミングに基づくマツチ
ング演算を実行する方法を説明する。ダイナミツ
クプログラミングに基づくマツチング演算は、2
種類のベクトルデータ列Cu,Rvの作るそれぞれ
の2次元格子平面上の各格子点に対して式(1),(2)
の演算を実行することに相当する。第8図は、本
構成にて2種類のベクトルデータ列、すなわちlc
個のベクトルデータ列Cu={c1 u,c2 u,……,cIu
u}(u=1,2,……lc)とlr個のベクトルデー
タ列Rv={r1 V,r2 V,……yNv v}(v=1,2,…
…lr)に対するダイナミツクプログラミングに基
づくマツチング演算(1),(2),(3)式を連続的に実行
する様子を示している。図において、格子平面上
の各対角破線、対角実線はPEの処理単位を時間
単位とした場合の時刻を表わし、矢印Aが時刻の
進行方向を示す。つまり、同一破線,実線上の格
子点は同時に処理されることを意味する。PEの
個数はn個であるから、処理実行中は常に対角線
上のn個の格子点が同時に処理される。 Next, a method of executing the matching operation based on dynamic programming shown by the above-mentioned arithmetic expressions (1), (2), and (3) with this configuration will be explained. The matching operation based on dynamic programming consists of 2
Equations (1) and (2) are used for each grid point on each two-dimensional grid plane created by the different vector data sequences C u and R v .
This corresponds to executing the calculation. Figure 8 shows two types of vector data strings in this configuration, namely l c
vector data string C u = {c 1 u , c 2 u , ..., c Iu
u } (u = 1, 2, ...l c ) and l r vector data string R v = {r 1 V , r 2 V , ... y Nv v } (v = 1, 2, ...
It shows how matching operations (1), (2), and (3) based on dynamic programming for (... l r ) are executed continuously. In the figure, each diagonal broken line and diagonal solid line on the lattice plane represent time when the PE processing unit is a time unit, and arrow A indicates the direction in which time progresses. This means that grid points on the same broken line and solid line are processed simultaneously. Since the number of PEs is n, n grid points on the diagonal are always processed simultaneously during processing.
本構成でのデータの入力動作の様子を第9図に
示す。第9図はn=6の場合を示し、31はPE、
32はベクトルデータci(i=1,2,……,I)
および累積結果Sijを隣接するPEへ転送するため
のデータ転送バス、33は各処理時刻におけるデ
ータ転送バス上のベクトルデータci(i=1,2,
……,I)の流れ、34は各処理時刻において各
PEに入力すべきI/Oバス上のベクトルデータ
rj(i=1,2,……,N)を示す。PEの個数
分、すなわち6個のベクトルデータ列c1,c2,…
…,c6がPE1から順に入力され、各ベクトルデー
タは各PEでの処理が終了するごとに右隣接のPE
へ順次転送され、第1番目のデータc1がPE1に戻
つてくるまでは処理時刻が進むにつれてデータci
(i=1,2,……,6)が現われるデータ転送
バスが1つずつ増えるが、データciがPE6から
PE1に転送される時刻以後は、各PEに存在する
データc1〜c6は各時刻ごとに同時に隣接するPE
へ転送される。一方、データrj(j=1,2,…
…,N)はこの各PE間のデータci(i=1,2,
……,6)の転送動作に同期して各PEに順々に
入力される。そして、各PE間で規制的なデータ
授受を行ないながら、全格子点に対して演算式
(1),(2),(3)を実行する。 FIG. 9 shows the data input operation in this configuration. Figure 9 shows the case where n=6, 31 is PE,
32 is vector data c i (i=1, 2, ..., I)
and a data transfer bus for transferring the cumulative result S ij to the adjacent PE; 33 is vector data c i (i=1, 2,
..., I) flow, 34 is each processing time at each processing time.
Vector data on the I/O bus to be input to PE
Indicates r j (i=1, 2, ..., N). The number of PEs, that is, 6 vector data sequences c 1 , c 2 ,...
..., c 6 are input sequentially from PE 1 , and each vector data is input to the right adjacent PE each time the processing in each PE is completed.
Until the first data c 1 returns to PE 1 , the data c i
The number of data transfer buses where (i = 1, 2, ..., 6) appears increases one by one, but when data c i is transferred from PE 6
After the time when data is transferred to PE 1 , the data c 1 to c 6 existing in each PE is simultaneously transferred to the adjacent PE at each time.
will be forwarded to. On the other hand, data r j (j=1, 2,...
..., N) is the data c i (i=1, 2,
..., 6) are input to each PE in turn in synchronization with the transfer operation. Then, while performing regulatory data exchange between each PE, calculation formulas are calculated for all grid points.
Execute (1), (2), and (3).
第8図の破線群は、マルチプレクサ2−1だ
けを外部からの入力データバスの選択モードに
し、PEの個数n個の入力ベクトルデータ列c1/1,
c1/2,……,c1/nを順に入力し、PE2〜PEoは処理
単位を終了するごとに隣接するPEとのベクトル
データc1/x(x=1,2,……,n−1)のデータ
授受を同時に行なうことを示す。この破線群1に
続く実線群は、PEoにデータc1/1が入力された後
は全マルチプレクサ2−1〜2−nがPE間のデ
ータ転送バスの選択モードとなり、入力ベクトル
データ列c1/1,c1/2,……,c1/nを各PE間で循環転
送しながら演算式(1),(2),(3)を実行することを示
している。そして、続く破線群は、入力ベクト
ルデータ列c1/1,c1/2,……,c1/nを次のn個分の
ベクトルデータ列c1/n+1,……c1/I1,……ci uと入
れ換えながら演算を続行する過程を示している。 The group of broken lines in FIG. 8 indicates that only the multiplexer 2-1 is set to the selection mode of the input data bus from the outside, and the input vector data string c 1/1 of the number of PEs is n.
c 1/2 , ..., c 1/n are input in order, and each time PE 2 to PE o completes a processing unit, vector data c 1/x (x = 1, 2, ...) with the adjacent PE is input. , n-1) are transferred simultaneously. The solid line group following this broken line group 1 indicates that after data c 1/1 is input to PE o , all multiplexers 2-1 to 2-n are in the selection mode of the data transfer bus between PEs, and the input vector data string c This shows that equations ( 1 ), (2), and (3) are executed while cyclically transferring 1/1, c 1/2 , ..., c 1/n between each PE. The following group of broken lines indicates that the input vector data strings c 1/1 , c 1/2 , ..., c 1/n are converted into the next n vector data strings c 1/n+1 , ... c 1/ It shows the process of continuing the calculation while exchanging I1 , ... c i u .
ところで、各PEには処理単位ごとに2種類の
ベクトルデータci u.rj vが入力されるので、演算
式(1)は各PEで独立に並列実行されるが、演算式
(2)は隣接PEとのデータ授受を行ないながら実行
する。例えば、第10図は、PEの個数n=5と
して、ベクトルデータ列C1、C2,とベクトルデ
ータ列R1,R2のすべての組合せについて連続的
に処理を行なう場合の各PEの処理手順および各
PEが担当する格子点の分布を示したもので、図
中⊂⊃で囲まれた格子点群は同一のPEにおいて処
理されることを意味し、左肩に示した数字がその
PE番号を示しているが、同図において例えばS7,8
を求める場合、時刻t1におけるS7,8の計算に必要
なデータは時刻t2,t3においてPE4,PE5で求めら
れるS6,7、S7,7、S6,8である。時刻t2,t3は時刻t1に
対して過去であるので、データS6,8はS7,8を計算
するPE5内に存在し、データS6,7、S7,7はPE4に存
在する。すなわち、必要なデータは常に隣接する
PE内に存在するので、S7,8に対する演算式(2)の比
較演算を実行する場合は、PE4においてmm(S6,7、
S7,7)を実行し、その結果をPE5に転送してPE5
においてmm〔S6,8mm(S6,7、S7,7)〕を実行する。 By the way, each PE has two types of vector data c i u . Since r j v is input, calculation formula (1) is executed independently and in parallel on each PE, but calculation formula
(2) is executed while exchanging data with neighboring PEs. For example, FIG. 10 shows the processing of each PE when all combinations of vector data sequences C 1 , C 2 , and vector data sequences R 1 , R 2 are sequentially processed with the number of PEs n=5. Steps and each
This shows the distribution of grid points handled by a PE. In the figure, grid points surrounded by ⊂⊃ mean that they are processed by the same PE, and the number on the left side indicates the number.
The PE number is shown, but in the same figure, for example, S 7,8
When calculating S 7,8 at time t 1 , the data required to calculate S 7,8 at time t 1 is S 6,7 , S 7,7 , S 6,8 determined by PE 4 and PE 5 at times t 2 and t 3 . . Since times t 2 and t 3 are in the past with respect to time t 1 , data S 6,8 exists in PE 5 that calculates S 7,8 , and data S 6,7 and S 7,7 exist in PE 5. Present in 4 . That is, the required data is always contiguous.
Since it exists in PE, when performing the comparison operation of equation ( 2 ) for S 7,8 , mm(S 6,7 ,
S 7,7 ) and transfer the result to PE 5
Perform mm [S 6,8 mm (S 6,7 , S 7,7 )] at
この場合、前述したように入力ベクトルデータ
列C1,C2……ClcをPEの個数分(n個)ごとに区
切つてアレイに入力し処理を行なうため、第10
図に示すように斜線で示した格子点に対応する
Sijは、入力ベクトルデータの入れ換えが始まる
までに、所定のPEへ転送しておかなければなら
ない。例えば、PE1に存在するS5,1はPE3へ、PE2
に存在するS5,2はPE4へ、PE3に存在するS5,3は
PE5へ、PE4に存在するS5,4はPE1へ、PE5に存在
するS5,5はPE2へそれぞれ転送しなければならな
い。一般に、n個のベクトルデータ列の入れ換え
が始まる(modlr
〓v=1
Nv)時刻前の時刻から、すな
わち第10図の例ではm
o5
d17=2時刻前の時刻
から全PEは、各時刻ごとにそれぞれ蓄えている
累積結果Spo,j(p=1,2,……)を隣接するPE
へ同時に転送する動作を開始し、これらのデータ
の転送を後述するa○,b○,c○の通常の処理動作と
並列に、前述したようにPEが演算処理のみを行
なつている間を利用してPEの各処理単位に1回
ずつ行なうことにより、n個の入力ベクトルデー
タ列の入れ換え直前までに必要なデータSpo,jを所
定のPEに転送しておくことができる。第10図
に示す例では、PE1の格子点(c1/1,r2/6)に対す
る処理と並列に、PE1,PE2,PE3,PE4,PE5の
各ワークメモリ23−2の同一アドレスに存在す
るデータS5,1,S5,2,S5,3,S5,4,S5,5は隣接する
PEへ転送されてPE2,PE3,PE4,PE5,PE1に
配置され、PE1の格子点(c1/2,r2/5に対する処理
では同様にしてPE3,PE4,PE5,PE1,PE2に配
置されて転送が完了し、PE1の次の格子点(c1/3,
r2/6)に対する処理時刻での次の入力ベクトルデ
ータ列c1/5,c1/6,c1/1,c2/1との入れ換え直後の処
理では、PE3,PE4,PE5,PE1,PE2が上記の2
回の転送により得られたデータS5,1,S5,2,S5,3,
S5,4,S5,5を使つて処理動作a○,b○,c○を実行す
る。このような処理を繰り返し実行することによ
り各PEはダイナミツクプログラミングに基づく
マツチング演算式(1),(2),(3)を規則的かつ連続的
に実行することができる。 In this case, as mentioned above, the input vector data strings C 1 , C 2 . . .
Corresponding to the hatched grid points as shown in the figure
S ij must be transferred to a predetermined PE before the exchange of input vector data begins. For example, S 5,1 present in PE 1 goes to PE 3 , PE 2
S 5,2 present in PE 4 goes to PE 4 , S 5,3 present in PE 3 goes to
S 5,4 existing in PE 4 must be transferred to PE 1 , and S 5,5 existing in PE 5 must be transferred to PE 2 . Generally, from the time before the start of the replacement of n vector data strings (mod lr 〓 v=1 N v ), that is, from the time before m o 5 d17 = 2 times in the example of Fig. 10, the total PE is as follows. The accumulated results S po,j (p = 1, 2, ...) stored at each time are calculated by the adjacent PEs.
At the same time, data transfer is started in parallel with the normal processing operations of a○, b○, and c○, which will be described later. By performing this once for each processing unit of the PE, the necessary data S po,j can be transferred to a predetermined PE immediately before the n input vector data strings are replaced. In the example shown in FIG. 10 , in parallel with the processing for the grid points ( c 1/1 , r 2/6 ) of PE 1 , the work memories 23- Data S 5,1 , S 5,2 , S 5,3 , S 5,4 , S 5,5 existing at the same address of 2 are adjacent
It is transferred to PE and placed at PE 2 , PE 3 , PE 4 , PE 5 , PE 1 , and in the processing for PE 1 's grid points (c 1/2 , r 2/5 , PE 3 , PE 4 , The transfer is completed by placing it at PE 5 , PE 1 , PE 2 , and the next grid point of PE 1 (c 1/3 ,
In the process immediately after replacing the next input vector data sequence c 1/5 , c 1/6 , c 1/1 , c 2/1 at the processing time for r 2/6 ), PE 3 , PE 4 , PE 5 , PE 1 , PE 2 are the above 2
Data obtained by transfer times S 5,1 , S 5,2 , S 5,3 ,
Processing operations a○, b○, and c○ are executed using S 5,4 and S 5,5 . By repeatedly executing such processing, each PE can regularly and continuously execute matching calculation formulas (1), (2), and (3) based on dynamic programming.
以上のように入力ベクトル列Cu(u=1,2,
……,lc)のn個のベクトルデータ列の入力また
は入れ換えと循環転送とを交互に繰り返し、かつ
上記ベクトルデータci u(i=1,2,……Iu)の
入力および循環転送に同期してベクトルデータrj
v(j=1,2,……,Nv)を各PEに入力しなが
ら、各PEが各格子点に対して演算式(1),(2),(3)
を繰り返し実行することにより全格子点に対する
処理を完了する。 As described above, the input vector sequence C u (u=1, 2,
..., l c ) and cyclic transfer of n vector data strings, and input and cyclic transfer of the vector data c i u (i=1, 2, . . . I u ). vector data r j in sync with
While inputting v (j = 1, 2, ..., N v ) to each PE, each PE calculates calculation formulas (1), (2), (3) for each grid point.
By repeatedly executing , the processing for all grid points is completed.
以上をまとめ、式(1),(2)を実行する場合のPE
の一般的な処理動作(通常の処理単位)は次のよ
うになる。 Summarizing the above, PE when executing equations (1) and (2) is
The general processing operation (normal processing unit) is as follows.
a○ 左隣接のPEまたは外部からの入力データバ
スよりベクトルデータci(i=1,2,……,
I)を入力すると同時に右隣接のPEへベクト
ルデータci-1を転送し、これらのベクトルデー
タの転送に同期してI/Oバスからベクトルデ
ータrj(j=1,2,……N)を入力し、上記
の演算式(1)を実行しDijを求める。a○ Vector data c i (i=1, 2, ...,
At the same time as I) is input, vector data c i-1 is transferred to the right-adjacent PE, and in synchronization with the transfer of these vector data, vector data r j (j = 1, 2, ... N ) and execute the above equation (1) to find D ij .
b○ 比較演算mm〔Si-1,j,mm(Sj-1,j-1,Si,j-1
)〕
を実行し、この結果にDijを加算してSijを求め
る。b○ Comparison operation mm [S i-1 , j , mm (S j-1 , j-1 , S i , j-1
)〕
Execute and add D ij to this result to find S ij .
c○ 比較演算mm〔Si-1,j,Sij)を実行してその演
算結果を右隣接のPEへ転送すると同時に、比
較演算結果mm(Si,j-1,Si+1,j-1)を左隣接の
PEから入力する。c○ Execute the comparison operation mm [S i-1 , j , S ij ) and transfer the operation result to the right adjacent PE, and at the same time, the comparison operation result mm (S i , j-1 , S i+1 , j-1 ) of the left neighbor
Input from PE.
a○は演算式(1)の実行に相当し、b○,c○は演算
式
(2),(3)の実行に相当する。各PEは、a○,b○,c○
の順に同時に、すなわちa○を行なうときには全
PEがa○を、b○を行なうときには全PEがb○を、と
いうように処理動作を行なう。 a○ corresponds to the execution of calculation formula (1), b○ and c○ are calculation formulas
This corresponds to executing (2) and (3). Each PE is a○, b○, c○
When performing a○ simultaneously in the order of
When a PE performs a○ and b○, all PEs perform b○, and so on.
本動作と2次元配列構成の動作の根本的な差異
は、式(2)を実行する場合のデータ転送動作にあ
る。2次元配列構成の動作では、累積結果Si-1,j-
1を左隣接のPEへ転送してから比較演算mm(Si,j-
1,Si-1,j-1)を行なうのに対し、本動作ではSi-1,
j-1は次の時刻に求められるSi,j-1と同一のPE内に
あるためデータ転送は実行しなくても比較演算が
実行できる。 The fundamental difference between this operation and the operation of the two-dimensional array configuration lies in the data transfer operation when executing equation (2). In the operation of the two-dimensional array configuration, the cumulative results S i-1 , j-
1 to the left-adjacent PE and then performs the comparison operation mm(S i , j-
1 , S i-1 , j-1 ), in this operation, S i-1 ,
Since j-1 is in the same PE as S i and j-1 to be determined at the next time, the comparison operation can be performed without performing data transfer.
なお、式(4)を実行する場合は、各PEにおいて、
「d○隣接するPEから累積結果を入力して、これに
そのPE内で実行されるベクトル間距離の2倍の
値を加えて隣接するPEへ出力する」1回の入出
力動作と「e○隣接するPEから累積結果を入力し、
ベクトル間距離を加えて保持する」動作の2種類
の簡単な動作を実行することにより、上述したと
同様に規則的に累積結果を求めることができる。 Note that when executing equation (4), at each PE,
``d○ Input the cumulative result from the adjacent PE, add twice the value of the distance between vectors executed within that PE, and output it to the adjacent PE'' one input/output operation and ``e ○ Enter cumulative results from adjacent PEs,
By performing two types of simple operations: ``adding and holding distances between vectors,'' cumulative results can be obtained regularly in the same way as described above.
以上説明したように、本発明によれば、PEの
個数は処理対象となる各ベクトルデータの個数を
表わす正整数Iu,Nvに全く依存せず、予測され
るデータ処理量に応じて適当な値に設定でき、
PEを規則的な処理動作の繰り返しでフル稼動し
てハードウエアを量大限有効利用したパイプライ
ン並列処理によりダイナミツクプログラミングに
基づくマツチング演算を実行できる。したがつ
て、LSIで実現する場合は、従来の正整数Iu,Nv
nに依存してPEの個数を決定しなければならな
い2次元配列構成に比べて実装規模が非常に小さ
くなるだけでなくハードウエアの有効利用を図る
ことができる。また、PEの個数をいくつに設定
しても任意のNv,Iuの個数をもつベクトルデー
タ列に対して処理を実行できるというPE数の拡
張性を有する。 As explained above, according to the present invention, the number of PEs does not depend at all on the positive integers I u and N v representing the number of each vector data to be processed, and is determined appropriately according to the expected amount of data processing. can be set to a value that
Matching calculations based on dynamic programming can be executed through pipeline parallel processing, which utilizes the hardware to the maximum extent possible by operating the PE at full capacity by repeating regular processing operations. Therefore, when realized on LSI, conventional positive integers I u , N v
Compared to a two-dimensional array configuration in which the number of PEs must be determined depending on n, the implementation scale is much smaller and the hardware can be used more effectively. In addition, the number of PEs is expandable in that no matter how many PEs are set, processing can be executed on vector data strings with arbitrary numbers of Nv and Iu .
次に、2次元配列構成と本構成との効率を、
PEの平均稼動率を考慮したPE1個当り・単位時
間当りのスループツトで比較してみる。 Next, the efficiency of the two-dimensional array configuration and this configuration is
Let's compare the throughput per PE/unit time considering the average operating rate of PE.
2次元配列構成において前記の処理動作,
と,の2種類の処理単位のうち大きい方のス
テツプ数をUsquare、本構成の処理動作a○,b○,
c○からなる処理単位のダイナミツクステツプ数を
Uringとする。2次元配列構成では、1組のベク
トルデータに対するダイナミツクプログラミング
に基づくマツチング演算を完了するには、,
および,の2種類の処理単位を交互に実行す
る方法をとると2Usquareステツプ必要である。
ここで対象としているダイナミツクプログラミン
グに基づくマツチング演算では、1つのベクトル
データ列Rに対してPEijが演算式(1),(2),(3)を実
行し累積結果Sijを求めてしまえば、PEi′j′(i′>
i,j′>j)が上記演算式を実行しているときに
はPEijはこのベクトルデータ列Rに対する処理を
実行する必要性がない。そこで、あるベクトルデ
ータ列Rvに対して処理を実行している時に処理
に寄与していないPEを別のベクトルデータ列
Rv′に対する処理に割り当てることができる。つ
まり、第1番目のベクトルデータ列R1の累積結
果Sijを計算しながら、2Usquareステツプの位相
差をもつて第2番目のベクトルデータ列R2に対
しても累積結果Sijの計算を実行することができ
る。ベクトルデータ列Iuとベクトルデータ列Rvと
の最終的な演算結果SIu,Nvを得るまでに、Sijを求
めるために必要なダイナミツクステツプ数
2Usquareを単位として(Nmax+Imax)ステツ
プを要するので、この(Nmax+Imax)ステツ
プの時間内に(Nmax+Imax)種類の最終累積
結果SIu,Nvを得ることができる。一方、本発明に
よる構成においては、入力ベクトルデータ列C1,
C2,……Clcのn個分のベクトルデータ列ごとに
入力ベクトルデータ列R1,R2……,Rlrとの処理
を繰り返しながら、最終累積結果SIo,Nvを得るこ
とができる。 The above processing operation in a two-dimensional array configuration,
The larger number of steps among the two processing units of and is Usquare, and the processing operations of this configuration are a○, b○,
The number of dynamic steps in the processing unit consisting of c○ is
Let's call it Uring. In a two-dimensional array configuration, to complete a matching operation based on dynamic programming on a set of vector data,
If we take the method of executing two types of processing units alternately, 2Usquare steps are required.
In the matching operation based on dynamic programming targeted here, PE ij executes calculation formulas (1), (2), and (3) for one vector data string R to obtain the cumulative result S ij . For example, PE i ′ j ′(i′>
i, j'>j) is executing the above arithmetic expression, PE ij does not need to execute processing on this vector data string R. Therefore, when processing is executed on a certain vector data string R v , PEs that do not contribute to the processing are added to another vector data string.
It can be assigned to processing for R v ′. In other words, while calculating the cumulative result S ij for the first vector data sequence R 1 , the cumulative result S ij is also calculated for the second vector data sequence R 2 with a phase difference of 2Usquare steps. can do. The number of dynamic steps required to obtain S ij before obtaining the final operation results S Iu and Nv between the vector data sequence I u and the vector data sequence R v
Since (Nmax+Imax) steps are required in units of 2Usquare, (Nmax+Imax) types of final cumulative results S Iu and Nv can be obtained within the time of this (Nmax+Imax) step. On the other hand, in the configuration according to the present invention, the input vector data string C 1 ,
By repeating the processing with the input vector data strings R 1 , R 2 ..., Rl r for every n vector data strings of C 2 , ...Cl c , the final cumulative results S Io , Nv can be obtained. .
以上のようなアレイ全体での処理動作に基づい
て、ベクトルデータC1,C2,……Clcとベクトル
データ列R1,R2……Rlrのすべての組合せに対し
て処理を実行する場合のPEの効率を求めると、
以下のようになる。 Based on the processing operations for the entire array as described above, processing is executed for all combinations of vector data C 1 , C 2 , ...Cl c and vector data sequences R 1 , R 2 ...Rl r . If we find the efficiency of PE in the case,
It will look like this:
2次元配列構成の場合;
lr・lc個の最終結果を得るには、2Usquareを単
位として(Nmax+Imax+lr・lc)ステツプを必
要とする。PE数はNmax・Imax個であるから、
PEの効率nsqは,
ηsq=lr・lc/(Nmax+Imax+lr・lc)・2Usquare/Nm
ax・Imax…(5)
本発明の場合;
Uringを単位として、n個分の入力ベクトルデ
ータ列の入れ換え動作時の処理はnステツプ、入
力ベクトルデータを循環転送しながら実行する処
理は(lr
〓v=1
Nv-o)ステツプである。入力ベクトル
データ列C1,C2,……Clcを1つの入力ベクトル
データ列と考えて処理を実行することと等価なの
で、lr,lc個の最終結果を得るには、
ステツプ必要である。式(6)の第1項は循環転送
時のステツプ数、第2項はデータ入れ換え時のス
テツプ数、第3項は処理開始及び終了時のステツ
プ数である。また、rI=m
on
dlc
〓u=1
Iuである。PE
数はn個であるから、PEの効率ηringは、
ここで、N1,N2,……,Nlrの平均値をNav、
I1,I2,……,Ilcの平均値をIavとして式(7)を書き
換えると、lr
〓v=1
Nv=lr・Nav,lc
〓u=1
Iu=le・Iavである
から、
ηring/ηsq=Nmax/Nav・Imax/Iav;
(1+Nmax+Imax/lrlc)/(1+n−rI/leIav+n
2/lcIav)・2Usquare/Uring…(8)
式(8)の第3項の分母・分子の1以外の項は、各
構成での処理開始及び終了に対する効率にかかわ
るものである。したがつて、処理実行中における
PEの効率の比は、
ηring/ηsqNmax/Nav・Imax/Iav・2Usquare/Urin
g……(9)
で表わされる。 In the case of a two-dimensional array configuration: To obtain l r ·l c final results, (Nmax+Imax+l r ·l c ) steps are required in units of 2Usquare. Since the number of PEs is Nmax・Imax,
PE efficiency n sq is η sq = l r・l c / (Nmax + Imax + l r・l c )・2Usquare/Nm
ax・Imax…(5) In the case of the present invention; The process of exchanging n input vector data strings using Uring as a unit is n steps, and the process executed while circularly transferring input vector data is ( lr 〓 v=1 N vo ) step. This is equivalent to processing the input vector data strings C 1 , C 2 , ... C lc as one input vector data string, so to obtain l r , l c final results, Steps are required. The first term in equation (6) is the number of steps during circular transfer, the second term is the number of steps when exchanging data, and the third term is the number of steps at the start and end of processing. Moreover, rI= mon d lc 〓 u=1 I u . P.E.
Since the number is n, the efficiency ηring of PE is Here, the average value of N 1 , N 2 , ..., N lr is N av ,
Rewriting equation (7) by setting the average value of I 1 , I 2 , ..., I lc as I av , lr 〓 v=1 N v = lr・N av , lc 〓 u=1 I u =le・I av , ηring/η sq = Nmax/N av・Imax/I av ; (1+Nmax+Imax/lrlc)/(1+n−rI/leIav+n
2 /lcIav)・2Usquare/Uring...(8) The terms other than 1 in the denominator and numerator of the third term in equation (8) are related to the efficiency of starting and ending processing in each configuration. Therefore, during processing
The PE efficiency ratio is ηring/η sq Nmax/N av・Imax/I av・2Usquare/Urin
It is expressed as g...(9).
2次元配列構成における各PEが入出力動作を
同時に実行できる手段をもつとすると2Usquare
Uring、またNmax>Nav,Imax>Iavであるこ
とより、本発明の構成は2次元配列構成に対して
常に効率が良く、例えばNav=3/4Nmax,Iav=
3/4Imaxの場合は約1.8倍の効率となる。また、
各PEが入力・出力の動作を各処理単位ごとに交
互に実行する手段しかもたない場合には、
2Usquare<Uringであり、2次元配列構成に対
する本発明の効率比はさらに大きくなる。 Assuming that each PE in a two-dimensional array configuration has a means to perform input/output operations simultaneously, 2Usquare
Since Nmax>Nav and Imax> Iav , the configuration of the present invention is always efficient for two-dimensional array configurations, for example, when Nav = 3/4Nmax, Iav = 3/4Imax. is approximately 1.8 times more efficient. Additionally, if each PE only has a means to alternately execute input/output operations for each processing unit,
2Usquare<Uring, and the efficiency ratio of the present invention for a two-dimensional array configuration is even greater.
2次元配列構成の場合は最低限(Nmax×
Imax)個のPEを配列・接続しなければならない
ため、その実装規模が非常に大きくなるので、従
来は、各PEの入出力をビツトシリアルで実行す
る方法をとることにより各PEの規模をコンパク
トにすることが行なわれていた。しかし、ここで
対象としているようなダイナミツクプログラミン
グに基づくマツチング演算におけるデータは、(1)
式に示すようにある次元数のデータ列を1つのデ
ータとして取扱うベクトルデータであるので、ビ
ツトシリアルでデータの入出力を実行すると、
PE間での転送ステツプ数が非常に多くなり、全
体の演算に非常に多くの時間を要する。これに対
し、本構成ではPEの個数を大幅に減少すること
ができるので、PE間のデータ転送をパラレル転
送で実現しても実装規模に対する問題を生じるこ
とがなく、ここで対象としているダイナミツクプ
ログラミングに基づくマツチング演算のようなベ
クトルデータに対する処理に敵している。 In the case of a two-dimensional array configuration, the minimum (Nmax ×
Imax) PEs must be arranged and connected, resulting in a very large implementation scale. Conventionally, the scale of each PE was reduced by executing input/output of each PE in bit serial format. things were being done. However, the data in the matching operation based on dynamic programming, which is the target here, is (1)
As shown in the formula, it is vector data that treats a data string of a certain number of dimensions as one piece of data, so when inputting and outputting data in bit serial format,
The number of transfer steps between PEs becomes very large, and the entire calculation takes a very long time. On the other hand, in this configuration, the number of PEs can be significantly reduced, so even if data transfer between PEs is realized using parallel transfer, there will be no problem with the implementation scale, and the dynamic It is unsuitable for processing vector data such as matching operations based on programming.
以上、(1),(2),(3)式に示すダイナミツクプログ
ラミング演算の場合を中心に説明したが、本発明
はこれに限定されるものではなく、前述したよう
に例えば(2)式が(4)式である場合、その他、2種類
の変数間のあらゆる組合せに対する演算とその演
算結果を用いたデータの局所依存性をもつ漸化式
の演算の実行に同様に適用可能である。 Although the above description has focused on the case of dynamic programming operations shown in equations (1), (2), and (3), the present invention is not limited thereto. When is Equation (4), it is similarly applicable to the execution of operations on all combinations of two types of variables and recurrence expressions with local dependence of data using the results of the operations.
以上説明したように、本発明によれば、それぞ
れ所定の入出力手段および演算手段を備えた処理
要素を、隣接する処理要素とのデータ授受を行な
うためのデータ転送バスと外部入力バスとを切り
換えるマルチプレクサを介して環状に接続し、か
つ全処理要素がそれぞれの処理結果を隣接処理要
素へ同時に転送する処理を、各処理要素における
通常の処理単位と並列に所定回実行することがで
きる構成としたことにより、ダイナミツクプログ
ラミングに基づくマツチング演算に代表される2
種類の変数間のあらゆる組合せに対する演算とそ
の演算結果を用いたデータの局所依存性をもつ漸
化式の演算を、対象とする演算量に応じた適正な
PE数からなるアレイ構成で、各処理要素を有効
に動作させながら高効率の並列処理で実現するこ
とができる。
As explained above, according to the present invention, processing elements each having a predetermined input/output means and calculation means are switched between a data transfer bus and an external input bus for exchanging data with adjacent processing elements. The system is connected in a ring via a multiplexer, and all processing elements simultaneously transfer their processing results to adjacent processing elements, which can be executed a predetermined number of times in parallel with the normal processing unit of each processing element. As a result, two methods, represented by matching operations based on dynamic programming,
Calculate calculations for all combinations of variables of different types and calculations of recurrence formulas with local data dependence using the calculation results in an appropriate manner according to the amount of calculations to be performed.
With an array configuration consisting of a number of PEs, it is possible to achieve highly efficient parallel processing while effectively operating each processing element.
第1図は従来の2次元配列アレイプロセツサの
構成例を示す図、第2図a,b〜第5図a,bは
その処理動作の一例を説明するための図、第6図
は本発明の一実施例を示す構成図、第7図は各処
理要素の構成例を示すブロツク図、第8図は第6
図の構成における処理動作の一例を説明するため
の図、第9図は同じく外部からのデータ入力と処
理要素間でのデータ転送の様子を説明するための
図、第10図は各処理要素の処理動作の一例を説
明するための図である。
1,31……処理要素、2−1〜2−n……マ
ルチプレクサ、3……外部入力データバス、4,
11……外部I/Oバス、5,32……データ転
送バス、6,12……I/O端子、7,8,3
3,34……入力ベクトルデータ、9……最終演
算結果、10……コントロールユニツト、13,
14……データ転送バス端子、15,16……バ
ツフアレジスタ、17,18……レジスタ、2
0,21……バツフアメモリ、22……演算ユニ
ツト、23……ワークメモリ、24……制御ユニ
ツト、26,27……アドレス線、28……カウ
ンタ。
FIG. 1 is a diagram showing an example of the configuration of a conventional two-dimensional array processor; FIGS. 2a, b to 5 a, b are diagrams for explaining an example of its processing operation; FIG. 7 is a block diagram showing an example of the structure of each processing element, and FIG. 8 is a block diagram showing an example of the structure of each processing element.
FIG. 9 is a diagram for explaining an example of processing operation in the configuration shown in the figure. FIG. 9 is also a diagram for explaining data input from the outside and data transfer between processing elements. FIG. FIG. 3 is a diagram for explaining an example of a processing operation. 1, 31... Processing element, 2-1 to 2-n... Multiplexer, 3... External input data bus, 4,
11... External I/O bus, 5, 32... Data transfer bus, 6, 12... I/O terminal, 7, 8, 3
3, 34...Input vector data, 9...Final calculation result, 10...Control unit, 13,
14... Data transfer bus terminal, 15, 16... Buffer register, 17, 18... Register, 2
0, 21... Buffer memory, 22... Arithmetic unit, 23... Work memory, 24... Control unit, 26, 27... Address line, 28... Counter.
Claims (1)
要素は、外部からの2種類の入力データ列C=
{ci}(i=1,2,……,I)およびR={rj}
(j=1,2,……,N)の各データci,rjを入
力する手段と、2種類のデータ間の加減算、比較
演算および積和演算の各所望の演算を行ないその
結果を蓄える手段と、入力データci(i=1,2
……,I)および演算結果を隣接する処理要素と
の間で送受する手段と、最終的な演算結果を外部
に出力する手段とを備えるとともに、各処理要素
間は、外部からの入力データciをどの処理要素か
らでも入力できるように隣接する処理要素とのデ
ータ授受を行なうためのデータ転送パスと外部入
力パスとを切換えるマルチプレクサを介して環状
に接続され、かつ全処理要素がそれぞれの処理結
果を隣接する処理要素へ、入力データ列Cの中の
連続するn個分ずつの入力データの入れ換えごと
に、(m on dN)回転送する処理を、各処理要素に
おける処理単位と並列に実行する手段を備えると
ともに、これら各処理要素を制御する手段を備え
たことを特徴とするアレイプロセツサ。[Claims] 1 n processing elements PE are arranged in a ring, and each processing element receives two types of external input data strings C=
{ci} (i=1,2,...,I) and R={rj}
Means for inputting each data ci, rj of (j=1, 2, ..., N), and means for performing desired operations such as addition/subtraction, comparison operation, and product-sum operation between two types of data and storing the results. and input data ci (i=1,2
..., I), means for transmitting and receiving calculation results between adjacent processing elements, and means for outputting the final calculation results to the outside, and between each processing element, input data ci from the outside is provided. is connected in a ring via a multiplexer that switches between a data transfer path and an external input path for exchanging data with adjacent processing elements so that the data can be input from any processing element, and all processing elements can input their respective processing results. is transferred to the adjacent processing element (m o n dN) times for each replacement of n consecutive pieces of input data in the input data string C, in parallel with the processing unit in each processing element. What is claimed is: 1. An array processor comprising means for controlling each of these processing elements.
Priority Applications (4)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP59034450A JPS60179871A (en) | 1984-02-27 | 1984-02-27 | Array processor |
| DE19853506749 DE3506749A1 (en) | 1984-02-27 | 1985-02-26 | Matrix processor and control method therefor |
| NL8500537A NL192637C (en) | 1984-02-27 | 1985-02-26 | System processor. |
| US07/220,970 US4905143A (en) | 1984-02-27 | 1988-06-14 | Array processor and control method thereof |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP59034450A JPS60179871A (en) | 1984-02-27 | 1984-02-27 | Array processor |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JPS60179871A JPS60179871A (en) | 1985-09-13 |
| JPH0421900B2 true JPH0421900B2 (en) | 1992-04-14 |
Family
ID=12414582
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP59034450A Granted JPS60179871A (en) | 1984-02-27 | 1984-02-27 | Array processor |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPS60179871A (en) |
Families Citing this family (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JPH11143847A (en) | 1997-11-10 | 1999-05-28 | Fujitsu Ltd | Data processing device |
| JP4202146B2 (en) * | 2001-03-13 | 2008-12-24 | 株式会社エッチャンデス | Visual equipment |
-
1984
- 1984-02-27 JP JP59034450A patent/JPS60179871A/en active Granted
Also Published As
| Publication number | Publication date |
|---|---|
| JPS60179871A (en) | 1985-09-13 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US11907726B2 (en) | Systems and methods for virtually partitioning a machine perception and dense algorithm integrated circuit | |
| US12327114B2 (en) | Processing cores and information transfer circuits arranged in matrix | |
| CN108920413B (en) | Convolutional neural network multi-core parallel computing method facing GPDSP | |
| US4905143A (en) | Array processor and control method thereof | |
| US20190212982A1 (en) | Processor, information processing apparatus and operation method for processor | |
| US10356385B2 (en) | Method and device for stereo images processing | |
| JP7387017B2 (en) | Address generation method and unit, deep learning processor, chip, electronic equipment and computer program | |
| US11086574B2 (en) | Machine perception and dense algorithm integrated circuit | |
| JP2003517649A (en) | Data processing system for logically close data sample such as image data in machine vision system | |
| CN114503126A (en) | Matrix operation circuit, device and method | |
| US20200257467A1 (en) | Systems and methods for implementing a random access augmented machine perception and dense algorithm integrated circuit | |
| US20200174965A1 (en) | Processor Core Design Optimized for Machine Learning Applications | |
| JP2005209207A (en) | Method for managing data in array processor, and array processor | |
| JP2002007359A (en) | SIMD control parallel processing method and apparatus | |
| JPH0421900B2 (en) | ||
| JP3684579B2 (en) | Processor element of distributed parallel computer | |
| JP7136343B2 (en) | Data processing system, method and program | |
| RU168781U1 (en) | STEREO IMAGE PROCESSING DEVICE | |
| JP3332310B2 (en) | Method and apparatus for extracting three-dimensional information of feature points | |
| Amouyal et al. | A novel framework for unstructured meshes with optimized cell ordering using Hamiltonian paths | |
| JPH04184535A (en) | Parallel arithmetic units | |
| JP2785939B2 (en) | Continuous speech recognition device | |
| Souravlas et al. | Verification and Performance Evaluation of Parallel Pipelined Communications Using Petri Nets | |
| JPH1166033A (en) | PE array device and associative memory block | |
| CN118798274A (en) | A multi-channel convolution optimization method and system for DSP |