JPWO2010082529A1 - SIMD type parallel data processing apparatus, data sorting method, and processing element - Google Patents

SIMD type parallel data processing apparatus, data sorting method, and processing element Download PDF

Info

Publication number
JPWO2010082529A1
JPWO2010082529A1 JP2010546611A JP2010546611A JPWO2010082529A1 JP WO2010082529 A1 JPWO2010082529 A1 JP WO2010082529A1 JP 2010546611 A JP2010546611 A JP 2010546611A JP 2010546611 A JP2010546611 A JP 2010546611A JP WO2010082529 A1 JPWO2010082529 A1 JP WO2010082529A1
Authority
JP
Japan
Prior art keywords
control information
data
sort
processing
processing element
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.)
Granted
Application number
JP2010546611A
Other languages
Japanese (ja)
Other versions
JP5445469B2 (en
Inventor
昭倫 京
昭倫 京
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
NEC Corp
Original Assignee
NEC Corp
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 NEC Corp filed Critical NEC Corp
Priority to JP2010546611A priority Critical patent/JP5445469B2/en
Publication of JPWO2010082529A1 publication Critical patent/JPWO2010082529A1/en
Application granted granted Critical
Publication of JP5445469B2 publication Critical patent/JP5445469B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F7/00Methods or arrangements for processing data by operating upon the order or content of the data handled
    • G06F7/22Arrangements for sorting or merging computer data on continuous record carriers, e.g. tape, drum, disc
    • G06F7/24Sorting, i.e. extracting data from one or more carriers, rearranging the data in numerical or other ordered sequence, and rerecording the sorted data on the original carrier or on a different carrier or set of carriers sorting methods in general
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2207/00Indexing scheme relating to methods or arrangements for processing data by operating upon the order or content of the data handled
    • G06F2207/38Indexing scheme relating to groups G06F7/38 - G06F7/575
    • G06F2207/3804Details
    • G06F2207/3808Details concerning the type of numbers or the way they are handled
    • G06F2207/3828Multigauge devices, i.e. capable of handling packed numbers without unpacking them

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Image Processing (AREA)
  • Advance Control (AREA)

Abstract

ソート処理の効率向上等を図る。第1の減算交換命令の実行で生成される交換決定信号が所定の値であるとき、自PE11iのレジスタ12iの数値データと右隣のPE11i+1のレジスタ12i+1の数値データとを交換する。第2の減算交換命令の実行で生成される交換決定信号が所定の値であるとき、自PE11iのレジスタ12iの数値データと左隣のPE11i−1のレジスタ12i−1の数値データとを交換する。Improve sort processing efficiency. When the exchange determination signal generated by the execution of the first subtraction exchange instruction has a predetermined value, the numeric data of the register 12i of the own PE 11i and the numeric data of the register 12i + 1 of the adjacent PE 11i + 1 are exchanged. When the exchange determination signal generated by the execution of the second subtraction exchange instruction has a predetermined value, the numeric data of the register 12i of the own PE 11i and the numeric data of the register 12i-1 of the adjacent PE 11i-1 are exchanged. .

Description

この発明は、SIMD型並列データ処理装置及びSIMD型並列データ処理装置におけるデータソート方法並びにプロセッシングエレメントに関し、詳しくは、ソート処理を改良したSIMD型並列データ処理装置及びSIMD型並列データ処理装置におけるデータソート方法並びにプロセッシングエレメントに関する。   The present invention relates to a SIMD type parallel data processing device, a data sorting method in a SIMD type parallel data processing device, and a processing element, and more particularly, to a data sorting in a SIMD type parallel data processing device and a SIMD type parallel data processing device with improved sort processing. The present invention relates to a method and a processing element.

ビデオ信号等の画像処理においては、従来からSIMD(Single Instruction Multiple Data)型並列計算装置(SIMD型並列プロセッサ)を用いることが知られている。このSIMD型計算装置は、複数のプロセッシングエレメント(Processing Element)PEと制御プロセッサとから概略構成される。その一次元SIMD型並列計算装置の電気的構成をブロック図で示せば図2のようになる。一次元SIMD型並列計算装置の全PEに1つずつ数値データを設定し、それら数値データからなる数値データの集合を昇順又は降順にソートする方法としては、いわゆる「奇偶変換ソート方式」が有効であることが知られている。   In image processing of video signals and the like, it has been conventionally known to use a SIMD (Single Instruction Multiple Data) type parallel computing device (SIMD type parallel processor). This SIMD type computing device is roughly composed of a plurality of processing elements PE and a control processor. The electrical configuration of the one-dimensional SIMD type parallel computing device is shown in a block diagram as shown in FIG. As a method of setting numerical data one by one for all PEs of a one-dimensional SIMD type parallel computing device and sorting a set of numerical data consisting of the numerical data in ascending or descending order, the so-called “even-even transformation sorting method” is effective. It is known that there is.

この奇偶変換ソート方式をSIMD型並列計算装置に適用して数値データの集合のソートを行う場合に、PE数をnとし、入力数値データ列S={x(0),x(1),…,x(n-1)}とし、x(i)がPE(i)に割り付けられているとすると、先ず、第1ステップでは、各偶数番目のPE(i)がその右隣のPE(i+1)からx(i+1)のコピーを受け取り、そしてもしもx(i)>x(i+1) ならば、PE(i)及びPE(i+1)は保持している数値データx(i)とx(i+1)とを交換する。
次に、第2ステップでは、最左端となっている番号0のPEを除く各偶数番目のPE(i)がその左隣のPE(i-1)からx(i-1)を受け取り、x(i-1)>x(i) ならば、PE(i-1)及びPE(i)は保持している数値データx(i)とx(i-1)とを交換する。
When this odd / even transform sort method is applied to a SIMD type parallel computing device to sort a set of numerical data, the number of PEs is n and the input numerical data string S = {x (0), x (1),. , X (n-1)} and x (i) is assigned to PE (i), first, in the first step, each even-numbered PE (i) is the right-hand side PE (i). +1) to x (i + 1), and if x (i)> x (i + 1), PE (i) and PE (i + 1) hold the numeric data x Exchange (i) and x (i + 1).
Next, in the second step, each even-numbered PE (i) excluding the number 0 PE at the leftmost end receives x (i-1) from the PE (i-1) adjacent to the left, and x If (i-1)> x (i), PE (i-1) and PE (i) exchange the held numerical data x (i) and x (i-1).

これらの2ステップを逐次に反復実行することにより、最大(n+1)/2回の反復後に、それ以上数値データの交換は起こらず、入力数値データ列Sのソートは完成する。
図4に、奇偶変換ソート方式を適用したSIMD型並列計算装置でのソート例を示す。このソート例は、PE数を7とし、降順の数値データ7、6、5、4、3、2、1を昇順の数値データにソートする例で、そのソートは、上述した2つのステップを合わせたソート動作を1回の反復とみなした場合に、その反復を繰り返すことで昇順の数値データ1、2、3、4、5、6、7を得るようにしている。
By repeatedly executing these two steps in succession, after the maximum (n + 1) / 2 iterations, no further exchange of numerical data occurs and the sorting of the input numerical data string S is completed.
FIG. 4 shows an example of sorting in the SIMD type parallel computing device to which the odd / even transform sorting method is applied. This sorting example is an example in which the number of PEs is 7, and the numerical data 7, 6, 5, 4, 3, 2, 1 in descending order are sorted into numerical data in ascending order. The sorting is performed by combining the above two steps. When the sorting operation is regarded as one iteration, numerical data 1, 2, 3, 4, 5, 6, 7 in ascending order is obtained by repeating the iteration.

非特許文献1には、上述した2つのステップ(1回の反復)を一次元SIMD型並列計算装置において実現する関連技術が記載されている。この関連技術は、各PEが一般的な命令セットでしか処理を実行し得ない場合において、上述の奇偶変換ソート方式をその装置に実装するため、それぞれ異なる形で相隣り合う2つのPEをペア(対)として取り扱った上、そのペア内で互いに異なる動作を行わせる仕組みを採用している。
すなわち、例えば、昇順にソートする場合には、第1ステップでは偶数PEが小さい値を受け取る一方、当該偶数PEとペアとなる右隣のPE(奇数PE)が大きい値を受け取り、そして第2ステップでは上記偶数PEが大きい値を受け取る一方、当該偶数PEとペアとなる左隣のPE(奇数PE)が大きい値を受け取る、というような動作を生じさせ、所定のソートを得ようとするものである。
Non-Patent Document 1 describes a related technique for realizing the above-described two steps (one iteration) in a one-dimensional SIMD type parallel computing device. In this related technology, when each PE can execute processing only with a general instruction set, in order to implement the above-mentioned odd-even transformation sort method in the apparatus, two adjacent PEs are paired in different forms. In addition to being handled as a (pair), a mechanism that allows different operations to be performed within the pair is adopted.
That is, for example, when sorting in ascending order, the first PE receives a small value in the first step, while the right adjacent PE (odd PE) paired with the even PE receives a large value, and the second step Then, while the even number PE receives a large value, the left adjacent PE (odd number PE) paired with the even number PE receives a large value and tries to obtain a predetermined sort. is there.

しかしながら、PEペア内に、上述したような互いに異なる動作(上述の第1ステップの動作Aと第2ステップの動作B)を行わせようとすると、同一の命令ストリームに従って動作する一次元SIMD型並列計算装置の場合には、一般的に、PEを動作不動作に指定するマスクレジスタ(mr)(以下、mr=1が動作を、また、mr=0が不動作を表すとする)を用いて、動作Aを指定する命令コードが制御プロセッサ(CP)から放送されている間は、一方のPEのmrを1とし他方のPEのmrを0とするのに対して、動作Bを指定する命令コードがCPから放送されている間は、一方のPEのmrを0とし他方のPEのmrを1とするように設定する。
すなわち、mrの値をPE毎にその都度変更し、かつ、動作Aと動作Bとに対応する命令コードをそれぞれCPから放送しなければならない。
However, if different operations as described above (the above-mentioned operation A in the first step and operation B in the second step) are performed in the PE pair, the one-dimensional SIMD type parallel operation that operates according to the same instruction stream. In the case of a computing device, generally, using a mask register (mr) that designates a PE as inoperable (hereinafter, mr = 1 represents an operation, and mr = 0 represents an inoperative). While the instruction code specifying the operation A is broadcast from the control processor (CP), the instruction specifying the operation B while the mr of one PE is 1 and the mr of the other PE is 0 While the code is broadcast from the CP, the mr of one PE is set to 0 and the mr of the other PE is set to 1.
That is, the value of mr must be changed for each PE, and the instruction codes corresponding to the operations A and B must be broadcast from the CP.

このことを非特許文献1に記載される関連技術について、具体的に言えば、上述した第1ステップ及び第2ステップの処理を遂行するのに以下に述べる7つのシーケンスを辿ることになる。この7つのシーケンスは次のようになる。
その第1のシーケンス1)は、全PEが右隣PEの数値データを自PEへ転送する、第2のシーケンス2)は、1)での転送で獲得した数値データと自PE上の数値データとの大小比較(引き算)を行う、第3のシーケンス3)は、偶数PEのみを動作させるようにmrを1に設定する、第4のシーケンス4)は、mr=1のPE(偶数PE)は引き算結果のキャリフラグの値が1ならば、2)にて右隣PEから届いた数値データを自PEの数値データに代入する、第5のシーケンス5)は、全PEが「自PEの数値データ」及び「キャリフラグの値とmrとの論理積の値」を右隣PEへ転送する、第6のシーケンス6)は、全PEでmrを反転させて偶数PEを不動作、奇数PEを動作に設定する、第7のシーケンス7)は、動作の設定となった奇数PEは、今度は上記5)により自PEに転送されて来た論理積の値が1ならば、5)にて転送されて来た数値データを自PEの数値データに代入する。
More specifically, regarding the related technology described in Non-Patent Document 1, the following seven sequences will be followed to perform the processing of the first step and the second step described above. The seven sequences are as follows.
In the first sequence 1), all PEs transfer the numerical data of the right adjacent PE to the own PE, and in the second sequence 2), the numerical data obtained by the transfer in 1) and the numerical data on the own PE. The third sequence 3) sets mr to 1 so that only even PEs are operated. The fourth sequence 4) sets mr = 1 PE (even PE). If the carry flag value of the subtraction result is 1, the numerical data received from the right adjacent PE in 2) is substituted into the numerical data of the own PE. The fifth sequence 5) The sixth sequence 6) of transferring the numerical data and the “logical value of the carry flag value and mr” to the right adjacent PE, inverts mr in all the PEs to inactivate the even PEs, and the odd PEs. The seventh sequence 7) sets the operation and Odd PE was Tsu, in turn if the value of the logical product came transferred to the own PE the above 5) is 1, substitutes the numeric data came transferred at 5) to the self PE numeric data.

上述した1)〜7)のシーケンスを辿ることにより、ようやく奇偶変換ソート方式における第1ステップの処理が実現する。
これと同様に、奇偶変換ソート方式における第2ステップの処理も実現することができる。そのためには、上述した1)〜7)での「右隣」を「左隣」に、また、3)の「偶数PEのみ」を「最左端PEを除く偶数PEのみ」に読み替えた上で、1)〜7)のシーケンスを辿るように構成する必要がある。
By following the above-described sequences 1) to 7), the first step processing in the odd-even conversion sorting method is finally realized.
Similarly, the second step process in the odd-even conversion sort method can also be realized. To do so, replace “right neighbor” in “1) to 7)” with “left neighbor” and “only even PE” in 3) with “even PE excluding the leftmost PE”. It is necessary to configure to follow the sequence of 1) to 7).

特許文献1には、SIMD型マイクロプロセッサについて関連技術が記載されている。この関連技術は、複数のプロセッサエレメントをSIMD型マイクロプロセッサにおいて、各プロセッサエレメントの特定のレジスタに格納されるデータと、オペランド指示されたソースレジスタに格納されるデータとの大小比較を第1のインストラクションで行い、両データのうちの大きいデータを上記特定のレジスタに格納する一方、小さいデータをソースレジスタに格納するか若しくはソースレジスタ以外のオペランド指示されたディスティネーションレジスタに格納し、更に、各プロセッサエレメントの特定のレジスタに格納されるデータと、オペランド指示されたソースレジスタに格納されるデータとの大小比較を第2のインストラクションで行い、両データのうちの小さいデータを上記特定のレジスタに格納する一方、大きいデータをソースレジスタに格納するか若しくはソースレジスタ以外のオペランド指示されたディスティネーションレジスタに格納し、上記格納のためのソースレジスタ及びディスティネーションレジスタとしてプロセッサエレメントのソートバッファレジスタを用いるように構成し、データのソート処理を高速に行う技術に係るものである。   Japanese Patent Application Laid-Open No. 2004-228561 describes related technology regarding a SIMD type microprocessor. In this related technique, in a SIMD type microprocessor having a plurality of processor elements, a first instruction performs a size comparison between data stored in a specific register of each processor element and data stored in an operand-designated source register. The large data of the two data is stored in the specific register, while the small data is stored in the source register or stored in the destination register indicated by the operand other than the source register. The second instruction compares the data stored in the specific register with the data stored in the operand-designated source register, and stores the smaller data of the two data in the specific register. Big de Data is stored in a source register or stored in a destination register indicated by an operand other than the source register, and the sort buffer register of the processor element is used as the source register and destination register for the storage, and the data This relates to a technique for performing the sorting process at a high speed.

特開2007−102799号公報JP 2007-102799 A

京 昭倫著「128個の4ウェイVLIW型RISCコアを集積した車載向け動画認識LSI」電子情報通信学会研究会報告、集積回路研究会(ICD),2003年5月、Vol.103,No.89,pp.19-24Akihiro Kyo, "Automotive Video Recognition LSI with 128 4-way VLIW RISC Cores Integrated" IEICE Technical Report, Integrated Circuits Research Group (ICD), May 2003, Vol.103, No. 89, pp.19-24

ところで、上述した非特許文献1では、一次元結合SIMD型並列計算装置において奇偶変換ソート方式を実行するように構成すれば、n個の数値データを最大(n+1)/2回の反復でソートすることはできる。
しかしながら、1回の反復毎に多くの命令実行でそのソートを行えるに過ぎず、処理時間が長く、効率が悪いという技術的課題がある。
また、特許文献1は、複数のプロセッサエレメントをSIMD型マイクロプロセッサにおける各プロセッサエレメント毎でのソート処理を行う仕組みを取り入れており、複数のプロセッサエレメントの中の他のプロセッサエレメントとの関係については何ら触れるところはない。
したがって、ソート処理の効率化において、なお解決すべき問題がある。
By the way, in Non-Patent Document 1 described above, if the odd-even transformation sort method is executed in the one-dimensional coupled SIMD type parallel computing device, n numerical data are sorted by maximum (n + 1) / 2 iterations. I can.
However, there is a technical problem that the sorting can be performed only by executing many instructions for each iteration, and the processing time is long and the efficiency is low.
Patent Document 1 adopts a mechanism for sorting a plurality of processor elements for each processor element in a SIMD type microprocessor. What is the relationship with other processor elements in the plurality of processor elements? There is no place to touch.
Therefore, there is still a problem to be solved in improving the efficiency of the sorting process.

この発明は、上述の事情に鑑みてなされたもので、ソート対象データの効率良いソートを達成し得るSIMD型並列データ処理装置及びSIMD型並列データ処理装置におけるデータソート方法並びにプロセッシングエレメントを提供することを目的としている。   The present invention has been made in view of the above circumstances, and provides a SIMD type parallel data processing device capable of achieving efficient sorting of data to be sorted, a data sorting method in the SIMD type parallel data processing device, and a processing element. It is an object.

上記課題を解決するために、この発明の第1の構成は、ソート対象データのソートを行うSIMD型並列データ処理装置に係り、ソート対象データを記憶する記憶手段を有し、一次元結合された複数のプロセッシングエレメントと、ソート制御情報を供給する制御情報出力手段と、該制御情報出力手段から入力される上記ソート制御情報に基づいて、上記複数のプロセッシングエレメントのうちの所定の1つのプロセッシングエレメントの上記記憶手段の上記ソート対象データと所定の他のプロセッシングエレメントの上記記憶手段の上記ソート対象データとを交換するプロセッシングエレメント毎のデータ交換手段とを備えることを特徴としている。   In order to solve the above-mentioned problem, a first configuration of the present invention relates to a SIMD type parallel data processing apparatus for sorting sort target data, and has a storage means for storing sort target data, and is one-dimensionally coupled. Based on the plurality of processing elements, the control information output means for supplying sort control information, and the sort control information input from the control information output means, the processing element of a predetermined one of the plurality of processing elements And a data exchange unit for each processing element for exchanging the sort target data of the storage unit and the sort target data of the storage unit of a predetermined other processing element.

この発明の第2の構成は、SIMD型並列データ処理装置におけるデータソート方法に係り、制御情報出力手段からソート制御情報の供給を受け、供給される上記ソート制御情報に基づいて、ソート対象データを記憶する記憶手段を有し、一次元結合された複数のプロセッシングエレメントのうちの所定のプロセッシングエレメント間で両プロセッシングエレメントの上記記憶手段のソート対象データを交換することを特徴としている。   A second configuration of the present invention relates to a data sorting method in a SIMD type parallel data processing apparatus, receives sort control information from control information output means, and sorts data to be sorted based on the supplied sort control information. It has a storage means for storing, and the sort target data of the storage means of both processing elements is exchanged between predetermined processing elements among a plurality of processing elements that are one-dimensionally coupled.

この発明の第3の構成は、SIMD型並列データ処理装置に用いるプロセッシングエレメントに係り、ソート制御情報を受信する制御情報入力手段と、該制御情報入力手段から出力される上記ソート制御情報に基づいて、一次元結合された複数のプロセッシングエレメントのうちの所定の上記プロセッシングエレメントの記憶手段に設定されるソート対象データと自己の上記プロセッシングエレメントの上記記憶手段に設定されるソート対象データとを交換するデータ交換手段とを備えることを特徴としている。   A third configuration of the present invention relates to a processing element used in a SIMD type parallel data processing apparatus, and is based on control information input means for receiving sort control information, and the sort control information output from the control information input means. Data for exchanging sort target data set in the storage means of a predetermined processing element among a plurality of processing elements that are one-dimensionally coupled with sort target data set in the storage means of the processing element of its own And an exchange means.

この発明によれば、減算交換命令を単純な演算の少ない組み合わせで実現させているので、奇偶変換ソート方式の各ステップを単一マシンサイクルで実装することが可能になる。したがって、ハードウェアコストの増加を僅かに抑えつつ、奇偶変換ソート方式に基づくデータのソート処理を効率良く実現することが可能になる。   According to the present invention, since the subtraction exchange instruction is realized by a combination of simple operations with few operations, each step of the odd-even conversion sort method can be implemented in a single machine cycle. Therefore, it is possible to efficiently realize the data sorting process based on the odd / even conversion sorting method while suppressing the increase in hardware cost slightly.

図1は、この発明の実施形態1であるSIMD型並列プロセッサの電気的構成の主要部を示すブロック図である。FIG. 1 is a block diagram showing the main part of the electrical configuration of a SIMD type parallel processor according to Embodiment 1 of the present invention. 同SIMD型並列プロセッサの電気的構成全体を示すブロック図である。It is a block diagram which shows the whole electric structure of the same SIMD type | mold parallel processor. 同SIMD型並列プロセッサのプロセッシングエレメントで用いる減算論理回路のブロック図である。It is a block diagram of a subtraction logic circuit used in the processing element of the SIMD type parallel processor. 同SIMD型並列プロセッサのプロセッシングエレメント数とソート対象データ数が同一である場合の動作説明図である。It is operation | movement explanatory drawing when the number of processing elements of the same SIMD type | mold parallel processor and the number of sort object data are the same. この発明の実施形態2であるSIMD型並列プロセッサのプロセッシングエレメント数がソート対象データ数よりも少ない場合の動作説明図である。It is operation | movement explanatory drawing when the number of processing elements of the SIMD type | mold parallel processor which is Embodiment 2 of this invention is smaller than the number of sort object data.

この出願は、2009年1月13日に出願された日本出願特願2009−004380を基礎とする優先権を主張し、その開示の全てがここに取り込まれている。   This application claims priority based on Japanese Patent Application No. 2009-004380 filed on Jan. 13, 2009, the entire disclosure of which is incorporated herein.

実施形態1Embodiment 1

図1は、この発明の実施形態1であるSIMD型並列プロセッサの電気的構成の主要部を示すブロック図、図2は、同SIMD型並列プロセッサの電気的構成全体を示すブロック図、図3は、同SIMD型並列プロセッサのプロセッシングエレメントで用いる減算論理回路のブロック図、図4は、同SIMD型並列プロセッサのプロセッシングエレメント数とソート対象データ数が同一である場合の動作説明図である。
この実施形態のSIMD型並列プロセッサ10は、奇偶変換ソート方式の第1ステップ及び第2ステップの各各を単一のマシンサイクルで実行し得る装置に係り、その主要部は、図1に示すように、複数のプロセッシングエレメントが一次元結合された(双方向にリング状に接続された)複数のプロセッシングエレメント(以下、PEと略記する)11(i=0、1、2、…、Nのうちの1つ)で構成され、さらに、これらのPEからなるPEアレイに命令をPE間結合線30(図2)を介して放送する制御プロセッサ(CP)40(図2)を有し、制御プロセッサ40で実行される命令セット内に以下に説明する減算交換命令をプログラムしてその減算交換命令の実行でPEアレイを制御して所定のソート処理を達成し得るようにしてその全体が構成されている。
1 is a block diagram showing the main part of the electrical configuration of a SIMD type parallel processor according to Embodiment 1 of the present invention, FIG. 2 is a block diagram showing the entire electrical configuration of the SIMD type parallel processor, and FIG. FIG. 4 is a block diagram of a subtraction logic circuit used in the processing element of the SIMD type parallel processor, and FIG. 4 is an operation explanatory diagram when the number of processing elements and the number of data to be sorted in the SIMD type parallel processor are the same.
The SIMD type parallel processor 10 of this embodiment relates to an apparatus capable of executing each of the first step and the second step of the odd-even conversion sort method in a single machine cycle, and its main part is as shown in FIG. , And a plurality of processing elements (hereinafter abbreviated as PE) 11 i (i = 0, 1, 2,..., N) And a control processor (CP) 40 (FIG. 2) that broadcasts instructions to the PE array of these PEs via the inter-PE coupling line 30 (FIG. 2). A subtraction exchange instruction described below is programmed in an instruction set executed by the processor 40, and the execution of the subtraction exchange instruction controls the PE array so as to achieve a predetermined sorting process. Whole is composed of.

その減算交換命令の機能は、概括的に言えば、次の通りである。上述した偶奇変換ソート方式における第1ステップを実行するのに1つの減算交換命令を用いて該命令の実行で生成される交換決定情報(交換決定ビット)xchg=1なら自PEのソート対象データをその右隣のPEのソート対象データで更新すると同時に、該右隣のPEのソート対象データを上記自PEのソート対象データで更新し、次いで、上述した偶奇変換ソート方式における第2ステップを実行するのにもう1つの減算交換命令を用いて該命令の実行で生成される交換決定ビットxchg=1なら自PEのソート対象データをその左隣のPEのソート対象データで更新すると同時に、左隣のPEのソート対象データを自PEのソート対象データで更新するという動作を生じさせることにある。
上記減算交換命令には、後述する動作指定情報I及び動作モードフラグflgが予め埋め込められている。
The function of the subtraction exchange command is generally as follows. In order to execute the first step in the even-odd conversion sort method described above, if one subtraction exchange instruction is used and exchange decision information (exchange decision bit) xchg = 1 generated by execution of the instruction, the data to be sorted by the own PE is selected. At the same time as updating with the sort target data of the right adjacent PE, the sort target data of the right adjacent PE is updated with the sort target data of the self PE, and then the second step in the even-odd conversion sort method described above is executed. However, if the exchange decision bit xchg = 1 generated by executing another instruction using another subtraction exchange instruction, the data to be sorted by the own PE is updated with the data to be sorted by the PE adjacent to the left, and at the same time, This is to cause an operation of updating the sort target data of the PE with the sort target data of the own PE.
In the subtraction exchange command, operation designation information I and an operation mode flag flg described later are embedded in advance.

次に、今説明した動作を行うPE11の各各の構成について説明する。
PE11のいずれも、レジスタ(src)12、セレクタ14及びセレクタ16を有して構成される。以下の説明では、iは偶数番目を表すものとする。
これに加えて、偶数番目のPE11には、さらに、減算論理回路20、動作モードフラグ(flg)レジスタ22及びマスクレジスタ(mr)24が設けられる一方、奇数番目のPE11i−1及びPE11i+1には、さらに、セレクタ18i−1及びセレクタ18i+1が設けられて構成されている。
Next, each configuration of the PE 11 i that performs the operation just described will be described.
Each of the PEs 11 i includes a register (src) 12 i , a selector 14 i, and a selector 16 i . In the following description, i represents an even number.
In addition, the even-numbered PE11 i is further provided with a subtraction logic circuit 20 i , an operation mode flag (flg) register 22 i, and a mask register (mr) 24 i, while the odd-numbered PE11 i-1. And PE11 i + 1 are further provided with a selector 18 i-1 and a selector 18 i + 1 .

偶数番目のPE11のセレクタ14及び減算論理回路20のセレクタ203(後述)、並びに奇数番目のPE11i−1及びPE11i+1のセレクタ14i−1、セレクタ14i+1、セレクタ18i−1及びセレクタ18i+1の各選択制御入力に、制御プロセッサ40からPE間結合線30を介して動作指定信号(動作指定ビットともいう)Iが供給される。Even-numbered PE11 i selector 14 i and subtractor logic circuit 20 i selector 203 i (described later), odd-numbered PE11 i-1 and PE11 i + 1 selector 14 i-1 , selector 14 i + 1 , selector 18 i-1 An operation designation signal (also referred to as an operation designation bit) I is supplied from the control processor 40 via the PE connection line 30 to each selection control input of the selector 18 i + 1 .

偶数番目のPE11のレジスタ12には、セレクタ16の出力が接続されている。セレクタ14には、左隣のPE11i−1の出力(レジスタ12i−1の出力)及び右隣のPE11i+1の出力(レジスタ12i+1の出力)が接続されてそのいずれか一方がそこに入力される動作指定信号Iの値に応じて選択的に出力されるように構成されている。偶数番目のPE11のセレクタ16には、レジスタ12及びセレクタ14の出力が接続され、セレクタ16の選択制御入力に減算論理回路20のから出力される交換決定信号(交換決定ビットともいう)xchgが選択制御信号21として入力され、選択制御信号21の値に応じてレジスタ12又はセレクタ14の数値データが選択されて出力されるように構成されている。The output of the selector 16 i is connected to the register 12 i of the even-numbered PE 11 i . The selector 14 i is connected to the output of the left adjacent PE11 i-1 (the output of the register 12 i-1 ) and the output of the right adjacent PE11 i + 1 (the output of the register 12 i + 1 ). It is configured to be selectively output according to the value of the input operation designation signal I. The selector 16 i of the even-numbered PE11 i, register 12 outputs i and the selector 14 i is connected, exchange determination signal (exchange decision bit output from the selection control input of the selector 16 i of the subtraction logic 20 i also referred) xchg is input as a selection control signal 21 i, and is configured to measure the register 12 i or selector 14 i according to the value of the selection control signal 21 i is selected and output.

奇数番目のPE11i−1及びPE11i+1のレジスタ12i−1及びレジスタ12i+1には、それぞれ、セレクタ16i−1及びレジスタ16i+1の出力が接続されている。セレクタ14i−1には、左隣のPE11i−2の出力(レジスタ12i−2の出力)及び右隣のPE11の出力(レジスタ12の出力)が接続されてそのいずれか一方がそこに入力される動作指定信号Iの値に応じて選択的に出力されるように構成されている。また、セレクタ14i+1には、左隣のPE11の出力(レジスタ12の出力)及び右隣のPE11i+2の出力(レジスタ12i+2の出力)が接続されてそのいずれか一方がそこに入力される動作指定信号Iの値に応じて選択的に出力されるように構成されている。The outputs of the selector 16 i-1 and the register 16 i + 1 are connected to the registers 12 i-1 and 12 i + 1 of the odd-numbered PE11 i-1 and PE11 i + 1 , respectively. The selector 14 i-1 is connected to the output of the left adjacent PE11 i-2 (the output of the register 12 i-2 ) and the output of the right adjacent PE11 i (the output of the register 12 i ). It is configured to be selectively output according to the value of the operation designation signal I input thereto. The selector 14 i + 1 is connected to the output of the left adjacent PE11 i (output of the register 12 i ) and the output of the right adjacent PE11 i + 2 (output of the register 12 i + 2 ), and one of them is input thereto. The operation designation signal I is selectively output according to the value of the operation designation signal I.

また、奇数番目のPE11i−1及びPE11i+1のセレクタ16i−1及びセレクタ16i+1の選択制御入力には、セレクタ18i−1及びセレクタ18i+1から出力される交換決定信号が選択制御信号19i−1及び選択制御信号19i+1として供給される。
ここで、レジスタ12i−1から出力される数値データをsrc-left12Lで表し、レジスタ12i+1から出力される数値データをsrc-right12Rで表すのに用いるが、また、src-left12L及びsrc-right12Rなる表記は、着目しているPEを基準として左側のPEのレジスタの数値データにもsrc-left12Lを、また、右側のPEのレジスタの数値データにもsrc-right12Rを用いることとする。
Further, the selection control input of the selectors 16 i-1 and the selectors 16 i + 1 of the odd-numbered PE11 i-1 and PE11 i + 1 is an exchange decision signal output from the selectors 18 i-1 and 18 i + 1. i-1 and selection control signal 19 are supplied as i + 1 .
Here, the numerical data output from the register 12 i-1 is represented by src-left 12L, and the numerical data output from the register 12 i + 1 is used to represent by src-right 12R. Also, src-left 12L and src-right 12R are used. In this notation, src-left12L is used for the numerical data of the left PE register and src-right12R is used for the numerical data of the right PE register with reference to the PE of interest.

偶数番目のPE11のセレクタ14及びセレクタ16の選択動作は次の通りである。
セレクタ14は、例えば、動作指定ビットIの値が1ならば、src-right12Rを、また、動作指定ビットIの値が0ならば、src-left12Lを選択して出力する。
セレクタ16は、例えば、選択制御信号21の値が0ならば、セレクタ14の数値データをレジスタ12へ選択して出力してレジスタ12の更新を行い、また、選択制御信号21の値が1ならば、レジスタ12の数値データをレジスタ12へ選択出力する、つまり更新は行わない。
偶数番目のPE11のセレクタ14及びセレクタ16の選択動作について説明したところは、奇数番目のセレクタ14i−1、セレクタ14i+1及びセレクタ16i−1、セレクタ16i+1にも同等に当て嵌まる。
The selection operation of the selector 14 i and the selector 16 i of the even-numbered PE 11 i is as follows.
For example, if the value of the operation designation bit I is 1, the selector 14 i selects and outputs the src-right 12R, and if the value of the operation designation bit I is 0, selects the src-left 12L.
The selector 16 i, for example, if the value of the selection control signal 21 i is 0, updates the register 12 i selects and outputs the numerical data of the selector 14 i to the register 12 i, also, the selection control signal 21 the value of i is 1, then selectively outputs the numerical data of the register 12 i to the register 12 i, i.e. the update is not performed.
The selection operation of the selector 14 i and the selector 16 i of the even-numbered PE 11 i applies equally to the odd-numbered selector 14 i−1 , selector 14 i + 1, selector 16 i−1 , and selector 16 i + 1. .

PE11i−1及びPE11i+1のセレクタ18i−1及びセレクタ18i+の選択動作は次の通りである。
セレクタ18i−1及びセレクタ18i+1には、両隣の偶数PEの減算論理回路、すなわち、減算論理回路20i−2及び減算論理回路20i+2の出力に接続され、動作指定ビットIの値に応じて上記2つの減算論理回路20i−2及び20i+2から出力される交換決定ビットxchg-left20L及びxchg-right20Rのいずれか一方を選択して選択制御信号19i−1及び選択制御信号19i+1として出力するように構成されている。セレクタ18i−1及びセレクタ18i+1は、例えば、動作指定ビットIの値が0ならば、xchg-right20Rを、また、動作指定ビットIの値が1ならば、xchg-left20Lを選択して出力する。
セレクタ18i−1及びセレクタ18i+1から選択して出力される信号は、各別に、当該奇数番目のPEに設けられるセレクタ16i−1及びセレクタ16i+1の選択制御入力に選択制御信号19i−1及び選択制御信号19i+1として供給される。
The selection operation of the selector 18 i-1 and the selector 18 i + of the PE11 i-1 and PE11 i + 1 is as follows.
The selector 18 i-1 and the selector 18 i + 1 are connected to the output of the subtraction logic circuit of the adjacent PEs on both sides, that is, the subtraction logic circuit 20 i-2 and the subtraction logic circuit 20 i + 2 , and according to the value of the operation designation bit I Thus, one of the exchange decision bits xchg-left 20L and xchg-right 20R output from the two subtraction logic circuits 20 i-2 and 20 i + 2 is selected as a selection control signal 19 i-1 and a selection control signal 19 i + 1. It is configured to output. For example, if the value of the operation designation bit I is 0, the selector 18 i-1 and the selector 18 i + 1 select and output xchg-right 20R if the value of the operation designation bit I is 1, and select xchg-left 20L if the value of the operation designation bit I is 1, for example. To do.
The selector 18 i-1 and signal output selected from the selector 18 i + 1 are each different, the odd selector 16 provided in the PE of i-1 and the selector 16 i + 1 of the selection control input to the selection control signal 19 i- 1 and selection control signal 19 i + 1 .

減算論理回路20は、レジスタ12及びセレクタ14からの数値データと、動作指定ビットIと、動作モードフラグ(flg)レジスタ22からの動作モードフラグ(flg)及びマスクレジスタ(mr)24からのマスク値とに基づいて交換決定信号(ビット)xchgを生成する回路であり、図3に示すように、減算回路(SUB)201、反転回路(NOT)202、セレクタ203、排他的論理和回路(XOR)204及び論理積回路(AND)205から構成される。交換決定信号xchgは自PE11のセレクタ16の選択制御入力に供給される選択制御信号21として用いられる。The subtraction logic circuit 20 i includes numerical data from the register 12 i and the selector 14 i , an operation designation bit I, an operation mode flag (flg) and a mask register (mr) 24 from the operation mode flag (flg) register 22 i. 3 is a circuit that generates an exchange decision signal (bit) xchg based on the mask value from i . As shown in FIG. 3, a subtraction circuit (SUB) 201 i , an inverting circuit (NOT) 202 i , a selector 203 i , It consists of an exclusive OR circuit (XOR) 204 i and an AND circuit (AND) 205 i . The exchange determination signal xchg is used as a selection control signal 21 i supplied to the selection control input of the selector 16 i of the own PE 11 i .

減算回路201には、レジスタ12及びセレクタ14の出力が接続され、セレクタ203には、減算回路201及び反転回路202の出力が接続されてそのいずれか一方がそこに入力される動作指定ビットIの値に応じて選択的に出力されるように構成されている。例えば、セレクタ203への動作指定ビットIが1のとき、減算回路201からの出力信号(キャリーフラグcf)を選択し、また、動作指定信号Iが0のとき、反転回路202からの出力信号を選択する。排他的論理和回路204には、セレクタ203及び動作モードフラグ(flg)レジスタ22の出力が接続され、論理積回路205には、排他的論理和回路204及びマスクレジスタ(mr)24の出力が接続されている。論理積回路205からの出力信号が、PE11で生成される交換決定信号xchgとなる。The subtraction circuit 201 i, the output of the register 12 i and the selector 14 i is connected to the selector 203 i, either one thereof is inputted thereto the output of the subtraction circuit 201 i and the inversion circuit 202 i is connected Are configured to be selectively output according to the value of the operation designation bit I. For example, when the operation designation bit I to the selector 203 i is 1, the output signal (carry flag cf) from the subtraction circuit 201 i is selected, and when the operation designation signal I is 0, the output from the inverting circuit 202 i Select the output signal. To the exclusive OR circuit 204 i, the output of the selector 203 i and the operation mode flag (flg) register 22 i is connected to the AND circuit 205 i, the exclusive OR circuit 204 i and the mask register (mr) 24 i outputs are connected. The output signal from the AND circuit 205 i becomes the exchange determination signal xchg generated by the PE 11 i .

動作モードフラグ(flg)レジスタ22は、動作モードフラグ(flg)を記憶するレジスタであり、動作モードフラグはソートの種別を表すフラグである。動作モードフラグ(flg)は、減算交換命令が制御プロセッサ40で実行されるときにPE間結合線30を介して偶数PEに放送されて動作モードフラグ(flg)レジスタ22にセットされる。
マスクレジスタ(mr)24は、減算交換命令が制御プロセッサ40で実行されるときにPE間結合線30を介して偶数PEに放送される動作指定ビットIの値に応じて設定される。例えば、動作指定信号Iの値が1ならば、偶数PEのマスクレジスタ(mr)24に1が自動的にセットされるのに対して、動作指定信号Iの値が0ならば、最左端のPE110のマスクレジスタ24に0が自動的にセットされ、また、そのほかの偶数PEのマスクレジスタ24には1が自動的にセットされる。マスク値は、PEの動作不動作を指定する情報である。
The operation mode flag (flg) register 22 i is a register for storing the operation mode flag (flg), and the operation mode flag is a flag indicating a sort type. The operation mode flag (flg) is broadcast to an even number of PEs via the inter-PE coupling line 30 and set in the operation mode flag (flg) register 22 i when the subtraction exchange command is executed by the control processor 40.
The mask register (mr) 24 i is set according to the value of the operation designation bit I broadcasted to the even number of PEs via the inter-PE coupling line 30 when the subtraction exchange instruction is executed by the control processor 40. For example, if the value of the operation designation signal I is 1, 1 is automatically set in the mask register (mr) 24 i of the even PE, whereas if the value of the operation designation signal I is 0, the leftmost mask register 24 0 0 of PE11 0 is automatically set, also 1 is automatically set in the mask register 24 i of other even-PE. The mask value is information for designating the operation / non-operation of the PE.

次に、図1乃至図4を参照して、この実施形態の動作について説明する。
SIMD型並列プロセッサ10は、そのPEの数が7で構成され、SIMD型並列プロセッサ10におけるデータ処理において、これらのPE11(i=0,1,…,6のうちの1つ)のレジスタ(src)12に図4に示すような降順の数値データ7、6、5、4、3、2、1が設定されるものとし、これらの数値データを昇順の数値データにソートする場合について説明する。以下においては、便宜上、PE11乃至PE11をPE0乃至PE6として表すことにする。
そして、上記データ処理を行うプログラムの中で上記ソート処理の第1ステップを行う第1の減算交換命令には、動作指定信号Iの値として1が、また、動作モードフラグflgの値として0が予め設定されている。また、上記ソート処理の第2ステップを行う第2の減算交換命令には、動作指定信号Iの値として0が、また、動作モードフラグflgの値として0が予め設定されている。
なお、この第1ステップでは、その第1の減算交換命令に動作指定信号Iの値として1を予め設定するとしているが、動作指定信号Iの値として0を予め設定しても、同様の結果が得られる。
Next, the operation of this embodiment will be described with reference to FIGS.
The SIMD type parallel processor 10 is configured with 7 PEs, and in the data processing in the SIMD type parallel processor 10, the registers (one of these PEs 11 i (one of i = 0, 1,..., 6)) ( src) 12 i It is assumed that numerical data 7, 6, 5, 4, 3, 2, 1 in descending order as shown in FIG. To do. In the following, for convenience, it will be representative of the PE11 0 to PE11 6 as PE0 to PE6.
In the first subtraction / exchange instruction for performing the first step of the sorting process in the program for performing the data processing, 1 is set as the value of the operation designation signal I, and 0 is set as the value of the operation mode flag flg. It is set in advance. In the second subtraction / exchange instruction for performing the second step of the sorting process, 0 is set in advance as the value of the operation designation signal I, and 0 is set as the value of the operation mode flag flg.
In this first step, 1 is set in advance as the value of the operation designation signal I in the first subtraction / exchange instruction. However, even if 0 is preset as the value of the operation designation signal I, the same result is obtained. Is obtained.

上記第1の減算交換命令が実行されると、各PEには1の動作指定信号Iが供給され、偶数PEの動作モードフラグレジスタ22には0の動作モードフラグflgが設定される。
そして、動作指定信号Iの値は1であるから、偶数PEのマスクレジスタ(mr)24に1が自動的にセットされる。
When the first subtraction / exchange instruction is executed, the operation designation signal I of 1 is supplied to each PE, and the operation mode flag flg of 0 is set in the operation mode flag register 22 i of the even PE i .
Since the value of the operation designation signal I is 1, 1 is automatically set in the mask register (mr) 24 i of the even PE.

上述のステップ1の処理において、PE0のレジスタ12に設定されている数値データは7である一方、動作指定信号の値は1であるから、セレクタ14から出力される数値データは、src-right(=6)となる。したがって、減算論理回路20の減算回路201から1のキャリーフラグcfが出力される。
このステップ1では、動作モードフラグレジスタ22には、既に、0の動作モードフラグflgtが設定されており、セレクタ203は、1の動作指定信号Iにより1のキャリーフラグcfを選択して出力しているから、排他的論理和回路204から1の信号が出力される。また、このステップ1では、マスクレジスタ24には、既に、1のマスク情報mrが設定されているから、論理積回路205から1の交換決定信号xchgを出力する。
In the process of Step 1 above, while the numerical data set in the register 12 0 PE0 is 7, the value of the operation designating signal is 1, the numerical data output from the selector 14 0, src- right (= 6) Accordingly, the carry flag cf the subtraction logic 20 0 of the subtraction circuit 201 0-1 are output.
In step 1, the operation mode flag register 22 0, already have been set operation mode flag flgt of 0, the selector 203 0 selects one of the carry flag cf the first operation designation signal I output because it has to, first signal from the exclusive OR circuit 204 0 is output. Further, in the step 1, the mask register 24 0, already from the first mask information mr is set, it outputs the exchange determination signal xchg of 1 from the AND circuit 205 0.

減算論理回路20から出力される1の交換決定信号xchgは、PE0では1の選択制御信号21としてPE0のセレクタ16へ供給される。そのセレクタ16はセレクタ14から出力されている数値データ、このステップ1では6を選択して出力する。この数値データ(=6)は、レジスタ12に書き込まれる。Subtraction logic circuit 20 0 1 exchange determination signal xchg output from is supplied as a selection control signal 21 0 of 1, PE0 to the selector 16 0 PE0. Numerical data that selector 16 0 which is outputted from the selector 14 0, and selects and outputs the 6 In this step 1. The numerical data (= 6) is written to the register 12 0.

一方、PE0の右隣のPE1では、PE0からの1の交換決定信号xchgがセレクタ18へ入力されるが、このステップ1ではそこに供給される動作指定信号Iの値も1であるから、セレクタ18で選択する交換決定信号xchgは、xchg-rightではなく、xchg-leftを選択するから、PE1での選択制御信号19も1となる。この1の選択制御信号19がセレクタ16に供給される。セレクタ16に入力される2つの数値データは、セレクタ14から出力されるsrc-left(すなわち、レジスタ12に設定されている数値データ7)とレジスタ12の数値データである。セレクタ16は、1の選択制御信号19により、src-left12L、すなわち、数値データ7を選択する。その数値データ7がレジスタ12に書き込まれる。On the other hand, the PE1 to the right of the PE0, although the first replacement determination signal xchg from PE0 is input to the selector 18 1, the value of the operation designating signal I supplied thereto in step 1 is also 1, exchange determination signal xchg be selected by the selector 18 1, rather than xchg-. right, because selecting xchg-left, a 1 also selection control signal 19 1 in PE1. This one selection control signal 19 1 is supplied to the selector 16 1 . Two numerical data input to the selector 16 1, the selector 14 src-left output from 1 (i.e., the numerical data 7 that is set in the register 12 0) as the numerical data of the register 12 1. The selector 16 1, the first selection control signal 19 1, src-left12L, i.e., selects a numerical data 7. The numerical data 7 is written to the register 12 1.

他方、PE0の左隣となる最右端のPE(この設例ではPE6)では、PE0で生成された1の交換決定信号xchgは、最右端のPE6ではxchg-rightとなるが、PE6の動作指定信号Iの値も1であるから、PE6のセレクタ18ではxchg-rightは選択されず、したがって最右端のPE6のレジスタ12への書き込み値は、PE0から出力される交換決定信号xchgの値によっては影響されない。On the other hand, in the rightmost PE (PE6 in this example) adjacent to the left of PE0, the 1 exchange decision signal xchg generated in PE0 is xchg-right in the rightmost PE6, but the PE6 operation designation signal since the value of I is also a 1, the selector 18 6 in xchg-. right of PE6 is not selected, therefore the value written to the register 12 6 PE6 rightmost, depending on the value of the replacement determination signal xchg output from PE0 Is not affected.

このステップ1におけるPE2での動作を説明すると次のようになる。
PE2のレジスタ12に設定されている数値データは5である一方、動作指定信号Iの値は1であるから、セレクタ14から出力される数値データは、PE3から出力されるsrc-right(=4)となる。したがって、減算論理回路20の減算回路201から1のキャリーフラグcfが出力される。
このステップ1では、動作モードフラグレジスタ22には、既に、0の動作モードフラグflgtが設定されており、セレクタ203は、動作指定信号Iが1であることにより、1のキャリーフラグcfを選択して出力しているから、排他的論理和回路204から1の信号が出力される。このステップ1では、マスクレジスタ24には、既に、1のマスク情報mrが設定されているから、論理積回路205から1の交換決定信号xchgを出力する。
The operation of PE2 in step 1 will be described as follows.
One measure is 5 which is set in the register 12 2 of PE2, the value of the operation designation signal I is 1, the numerical data output from the selector 14 2, src-. Right output from PE3 ( = 4). Accordingly, the carry flag cf from the subtraction logic circuit 20 2 of the subtracting circuit 201 2 1 is output.
In step 1, the operation mode flag register 22 2, already, the operation mode flag flgt is set to 0, the selector 203 2, by operation designation signal I is 1, 1 of the carry flag cf since selected and is output, the first signal from the exclusive OR circuit 204 2 is outputted. In step 1, the mask register 24 2, already from the first mask information mr is set, it outputs the exchange determination signal xchg from the AND circuit 205 2 1.

減算論理回路20から出力される1の交換決定信号xchgは、PE2では1の選択制御信号21としてPE2のセレクタ16へ供給される。そのセレクタ16は、選択制御信号21が1であることにより、セレクタ14から出力されている数値データ、このステップ1ではPE3のレジスタ12の数値データ(すなわち、src-right12R)4を選択して出力する。この数値データ(=4)は、レジスタ12に書き込まれる。Subtraction exchange determination signal xchg of 1 output from the logic circuit 20 2 is supplied as a selection control signal 21 2 1, PE2 PE2 to the selector 16 2. That selector 16 2, by the selection control signal 21 2 is 1, the numerical data output from the selector 14 2, numerical data of the register 12 3 in step 1 PE3 (i.e., src-right12R) 4 Select and output. The numerical data (= 4) is written to the register 12 2.

一方、PE2の右隣のPE3では、このステップ1ではそこに供給される動作指定信号Iの値も1であるから、セレクタ18で選択する交換決定信号xchgは、xchg-rightではなく、xchg-leftを選択するから、PE3での選択制御信号19も1となる。この1の選択制御信号19がセレクタ16に供給される。このとき、セレクタ14は動作指定信号Iが1であることにより、そこに入力されるsrc-left、すなわち、レジスタ12に設定されている数値データ5を選択して出力する。そして、セレクタ16は、選択制御信号19が1であることにより、セレクタ14から出力される数値データ5を選択して出力する。その数値データ5がレジスタ12に書き込まれる。On the other hand, the PE3 the right of PE2, the value of the operation designating signal I supplied thereto in step 1 is also a 1, exchange determination signal xchg be selected by the selector 18 3, rather than xchg-. Right, xchg to choose from the -left, it becomes also 1 and selection control signal 19 3 in PE3. The first selection control signal 19 3 is supplied to the selector 16 3. At this time, the selector 14 3 by the operation designation signal I is 1, src-left input thereto, i.e., selects and outputs the numerical data 5 which is set in the register 12 2. The selector 16 3 selects and outputs the numerical data 5 output from the selector 14 3 when the selection control signal 19 3 is 1. The numerical data 5 is written in the register 12 3.

他方、PE2の左隣のPE1では、PE2で生成された交換決定信号xchgは、PE1ではxchg-rightとなるが、PE1の動作指定信号Iの値も1であるから、PE1のセレクタ18ではxchg-rightは選択されず、したがってPE1のレジスタ12への書き込み値は、PE2から出力される交換決定信号xchgの値によっては影響されない。On the other hand, the PE1 to the left of the PE2, exchange determination signal xchg generated by the PE2, although the PE1 in xchg-. Right, because it is 1 the value of the operation designating signal I of PE1, the selector 18 1 of PE1 xchg-. right is not selected, therefore the value written to the register 12 1 of PE1 is not affected by the value of the exchange determination signal xchg output from PE2.

そして、PE0及びPE2とこれら左右隣のPEについて説明した動作が、PE4とこの左右隣のPEに対しても、同様にして、ステップ1の処理のためにプログラムされた第1の減算交換命令の実行の中で同時的に生ぜしめられる。したがって、その逐一の説明は省略する。
また、PE6においては、交換決定信号xchgは、PE0及びPE2について説明したところに従うと1になり、したがって、セレクタ16への選択制御信号21は1になるから、セレクタ16でレジスタ12の数値データ、ここでは1が選択されてその数値データがレジスタ12に書き込まれる。レジスタ12の数値データは変更されない。
第1回目の反復におけるステップ1の処理が完了したときの状態を図4に示す。そのソート状態は、図4では、第1回目の反復(1st iteration)の中の第1のステップ(Step1)を示す横欄に示すようになる。すなわち、PE0、PE1、PE2、PE3、PE4、PE5及びPE6に保持される数値データは、それぞれ、6、7、4、5、2、3及び1となる。
The operations described for PE0 and PE2 and the left and right adjacent PEs are similarly applied to PE4 and the left and right adjacent PEs in the first subtraction exchange instruction programmed for the processing of step 1. It is generated at the same time in the execution. Therefore, the explanation of each step is omitted.
In the PE6, exchange determination signal xchg will become 1 According to was described PE0 and PE2, therefore, since the selection control signal 21 6 to the selector 16 6 becomes 1, the register 12 6 by the selector 16 6 numerical data, where the numerical data 1 is selected is written to the register 12 6. Numerical data of the register 12 6 is not changed.
FIG. 4 shows a state when the process of step 1 in the first iteration is completed. In FIG. 4, the sorting state is shown in the horizontal column indicating the first step (Step 1) in the first iteration (1st iteration). That is, the numerical data held in PE0, PE1, PE2, PE3, PE4, PE5, and PE6 are 6, 7, 4, 5, 2, 3, and 1, respectively.

上述したステップ1の処理に続いて第1回目の反復におけるステップ2の処理が開始される。このステップ2のための第2の減算交換命令が、上述したプログラムの中で第1の減算交換命令に続いて置かれている。この第2の減算交換命令に設定される動作指定信号Iは0に設定される。動作モードフラグflgの値は、第1の減算交換命令と同様、0に設定される。   Subsequent to the process of step 1 described above, the process of step 2 in the first iteration is started. The second subtraction exchange instruction for this step 2 is placed following the first subtraction exchange instruction in the above-described program. The operation designation signal I set in the second subtraction exchange command is set to 0. The value of the operation mode flag flg is set to 0 like the first subtraction exchange instruction.

ステップ2の処理に入り、第2の減算交換命令が制御プロセッサ40で実行されるときの、PE0のレジスタ12に既に設定されている数値データは6である一方、動作指定信号Iの値は0であるから、セレクタ14から出力される数値データは、最右端のPE(PE6)から出力されるsrc-left(=1)となる。したがって、減算論理回路20の減算回路201から1のキャリーフラグcfが出力される。Enters step 2 of the process, when the second subtraction replacement instruction is executed by the control processor 40, while numerical data are 6 that has already been set in the register 12 0 PE0, the value of the operation specifying signal I since 0, the numerical data output from the selector 14 0 becomes src-left output from the rightmost PE (PE6) (= 1) . Accordingly, the carry flag cf the subtraction logic 20 0 of the subtraction circuit 201 0-1 are output.

第2の減算交換命令でも、動作モードフラグレジスタ22には、既に、0の動作モードフラグflgが設定されており、動作指定信号Iの値は0であるから、セレクタ203は1のキャリーフラグcfを反転して出力する反転回路203の出力信号値0を選択して出力するので、排他的論理和回路204から0の信号(0の排他的論理和)が出力される。In the second subtraction replacement instruction, the operation mode flag register 22 0, already have been set operation mode flag flg of 0, because the value of the operation designating signal I is 0, the selector 203 0 1 carry since selects and outputs an output signal value 0 the inverter circuit 203 0 for inverting and outputting the flag cf, exclusive OR circuits 204 0 0 signal (exclusive of 0) is output.

そして、動作指定信号Iの値が0である場合には、偶数PEのうち、最左端のPEであるPE0に限り、マスクレジスタ24には、既に、0のマスク情報mrが設定されているから、キャリーフラグcfと動作モードフラグflgとの排他的論理和の値が1となったとしても、排他的論理和とマスク情報mrとの論理積は必ず0となる。したがって、減算論理回路20が出力する交換決定信号xchgは、常に0となる。Then, if the value of the operation designating signal I is 0, among the even PE, only PE0 a leftmost PE, the mask register 24 0, is already set to 0 in the mask information mr Therefore, even if the value of the exclusive OR of the carry flag cf and the operation mode flag flg is 1, the logical product of the exclusive OR and the mask information mr is always 0. Therefore, exchange determination signal xchg subtraction logic circuit 20 0 outputs will always be zero.

その0の交換決定信号xchgが、選択制御信号21としてPE0のセレクタ16へ供給される。そのセレクタ16はレジスタ(src)12から出力されている数値データ、ここでは6を選択して出力する。この数値データ(=6)がレジスタ12に書き込まれるので、レジスタ12の数値データは変更されない。Exchange determination signal xchg of 0 is supplied to the selector 16 0 select control signal 21 0 as PE0. That selector 16 0 register (src) 12 0 numeric is output from the data, wherein selects and outputs 6. Since the numerical data (= 6) is written into the register 12 0, the numerical data of the register 12 0 is not changed.

一方、PE0の右隣のPE1では、第2のステップではそこに供給される動作指定信号Iの値も0であるから、セレクタ18で選択する交換決定信号xchgは、xchg-leftではなく、xchg-rightを選択するから、PE1での選択制御信号21も1となる。この1の選択制御信号21の生成も、ステップ1で説明したところに準じて行われる。
この1の選択制御信号21がセレクタ16に供給されるから、セレクタ16は、セレクタ14からの数値データを選択して出力する。セレクタ14で選択される数値データは、ステップ1の処理でPE2のレジスタ16に設定された数値データ、ここでは4である。この数値データ4がレジスタ12に書き込まれる。
On the other hand, the PE1 to the right of the PE0, because in the second step is 0 the value of the operation designating signal I supplied thereto, exchange determination signal xchg be selected by the selector 18 1, rather than xchg-left, since selecting xchg-. right, a 1 also select control signals 21 1 in PE1. Generation of the selection control signal 21 1 This 1 is also performed in accordance with the place described in step 1.
Since the selection control signal 21 1 of 1 is supplied to the selector 16 1, the selector 16 1 selects and outputs the numerical data from the selector 14 1. Numerical data selected by the selector 14 1 is set numeric data in the register 16 2 of PE2 in the process of step 1, wherein is 4. The numerical data 4 is written to the register 12 1.

他方、PE0の左隣となる最右端のPE(この設例ではPE6)では、PE0で生成された0の交換決定信号xchgは、最右端のPE6ではxchg-rightとなり、PE6の動作指定信号Iの値も0であるから、PE6のセレクタ18から0のxchg-rightが選択され、その0の選択制御信号21がセレクタ16へ供給される。このとき、セレクタ14は、src-left、すなわち、レジスタ12の数値データ3を選択して出力する。したがって、最右端のPE6では、セレクタ16でレジスタ12の数値データ、ここでは3が選択されてレジスタ12へ供給されてそこに書き込まれる。On the other hand, in the rightmost PE (PE6 in this example) adjacent to the left of PE0, the 0 exchange decision signal xchg generated in PE0 becomes xchg-right in the rightmost PE6, and the operation designation signal I of PE6 is since the value is also 0, xchg-. right of 0 from the selector 18 6 PE6 is selected, the selection control signal 21 6 of the 0 is supplied to the selector 16 6. At this time, the selector 14 6, src-left, i.e., selects and outputs the numerical data 3 in the register 12 5. Therefore, the PE6 rightmost, numerical data of the register 12 5 by the selector 16 6, where the written therein is supplied 3 is selected and the register 12 6.

第1回目の反復におけるステップ2の中で生ずるPE2での動作を説明すると次のようになる。
PE2のレジスタ12に設定されている数値データは4である一方、動作指定信号Iの値は0であるから、セレクタ14から出力される数値データは、PE1から出力されるsrc-left(=7)となる。したがって、減算論理回路20の減算回路201から0のキャリーフラグcfが出力される。
このステップ2においても、動作モードフラグレジスタ22には、既に、0の動作モードフラグflgが設定されており、セレクタ203が0のキャリーフラグcfを反転回路202で反転した1の信号を選択して出力しているから、排他的論理和回路204から1の信号が出力される。このステップ2でも、マスクレジスタ24には、既に、1のマスク情報mrが設定されているから、論理積回路205から1の交換決定信号xchgを出力する。
The operation at PE2 occurring in step 2 in the first iteration is described as follows.
While numerical data set in the register 12 2 of PE2 is 4, since the value of the operation designating signal I is 0, the numerical data output from the selector 14 2, src-left output from PE1 ( = 7). Accordingly, the carry flag cf from the subtraction logic circuit 20 2 of the subtracting circuit 201 2 0 is output.
In this step 2, the operation mode flag register 22 2, already, the operation mode flag flg is set to 0, the first signal obtained by inverting the carry flag cf selector 203 2 0 inversion circuit 202 2 since selected and is output, the first signal from the exclusive OR circuit 204 2 is outputted. In this step 2, the mask register 24 2, already from the first mask information mr is set, it outputs the exchange determination signal xchg from the AND circuit 205 2 1.

減算論理回路20から出力される1の交換決定信号xchgは、PE2では1の選択制御信号21としてPE2のセレクタ16へ供給される。また、上述したように動作指定信号Iとして0がセレクタ14に供給されているから、セレクタ14は、src-leftの数値データであるPE1のレジスタ12に設定されている数値データ、すなわち、7を選択して出力する。
したがって、セレクタ16はセレクタ14から出力されている数値データ(=7)を選択して出力する。この数値データ(=7)は、レジスタ12に書き込まれる。
Subtraction exchange determination signal xchg of 1 output from the logic circuit 20 2 is supplied as a selection control signal 21 2 1, PE2 PE2 to the selector 16 2. Also, because there is 0 as an operation designation signal I as described above are supplied to the selector 14 2, the selector 14 2, numerical are set in the registers 12 1 of PE1 is numeric data src-left data, i.e. , 7 are selected and output.
Therefore, the selector 16 2 selects and outputs the numerical data (= 7) which is outputted from the selector 14 2. The numerical data (= 7) is written to the register 12 2.

一方、PE2の右隣のPE3では、このステップ2ではそこに供給される動作指定信号Iの値も0であるから、セレクタ18で選択する交換決定信号xchgは、xchg-leftではなく、xchg-rightを選択するから、PE3の動作は、PE2から出力される交換決定信号xchgには影響されない。
PE3で用いられる選択制御信号としは、上述のようにして選択されたxchg-right、すなわち、上述のところに準じて処理されて出力される0の交換決定信号が用いられる。このとき、セレクタ14が選択するのは、src-rightである。そして、0の選択制御信号がセレクタ16に供給されるから、セレクタ16から選択出力する数値データは、セレクタ14から出力されるsrc-right、すなわち、レジスタ12に設定されている数値データ2である。この数値データ2がレジスタ12に書き込まれる。
On the other hand, the PE3 the right of PE2, the value of the operation designating signal I supplied thereto in step 2 is also zero, exchange determination signal xchg be selected by the selector 18 3, rather than xchg-left, xchg Since -right is selected, the operation of PE3 is not affected by the exchange decision signal xchg output from PE2.
As the selection control signal used in PE3, the xchg-right selected as described above, that is, the 0 exchange decision signal processed and output in accordance with the above description is used. At this time, the selector 14 3 to choose is a src-. Right. Then, since 0 selection control signal is supplied to the selector 16 3, numerical data selectively output from the selector 16 3, src-. Right output from the selector 14 3, i.e., the numerical values set in the register 12 4 Data 2. The numerical data 2 is written to the register 12 3.

他方、PE2の左隣のPE1では、PE2で生成された交換決定信号xchgは、PE1ではxchg-rightとなるが、PE1の動作指定信号Iの値も0であるから、PE1のセレクタ18では1のxchg-rightが選択されると共に、セレクタ14でもsrc-right、すなわち、PE2のレジスタ12に設定されている数値データ(=4)を選択する。
したがって、PE1のレジスタ12の書き込み値は、数値データ(=4)となり、レジスタ12の数値データは、4に書き換わる。
On the other hand, the PE1 to the left of the PE2, exchange determination signal xchg generated by the PE2, although the PE1 in xchg-. Right, because the value of the operation designating signal I of PE1 is 0, the selector 18 1 of PE1 with 1 of xchg-. right is selected, even the selector 14 1 src-. right, i.e., selects a numerical data set in the register 12 2 of PE2 (= 4).
Accordingly, the write value of the register 12 1 of the PE1, numerical data (= 4), and the numerical data of the register 12 1 is rewritten to 4.

そして、PE0、PE1、PE2及びPE3について説明した動作が、PE4、PE5及びPE6でも、同様にして、ステップ2の処理のためにプログラムされた第2の減算交換命令の実行の中で同時的に生ぜしめられる。したがって、それらの逐一の説明は省略する。
第1回目の反復の中のステップ2の処理が完了したときの状態を図4に示す。そのソート状態は、図4では、第1回目の反復の中の第2のステップ(Step2)を示す横欄に示すようになる。すなわち、PE0、PE1、PE2、PE3、PE4、PE5及びPE6に保持される数値データは、それぞれ、6、4、7、2、5、1及び3となる。
The operations described for PE0, PE1, PE2, and PE3 are also performed simultaneously in the execution of the second subtraction exchange instruction programmed for the processing of step 2 in PE4, PE5, and PE6. Be born. Therefore, the explanation of each one is omitted.
FIG. 4 shows a state when the process of step 2 in the first iteration is completed. The sort state is as shown in the horizontal column in FIG. 4 indicating the second step (Step 2) in the first iteration. That is, the numerical data held in PE0, PE1, PE2, PE3, PE4, PE5, and PE6 are 6, 4, 7, 2, 5, 1, and 3, respectively.

上述した第1回目の反復の実行により、各PEに初期的に設定保持される数値データの入れ替え(交換)がPE間で行われる。
同様の数値データの入れ替えが、第2回目の反復以降でも行われる。それらの反復により、上述した数値データ例の場合には、図4に示すように、4回の反復で昇順のソート処理が完了する、すなわち、それ以上の数値データの入れ替え動作は発生しないことが判る。
このソート状態、すなわち、全PEのレジスタ(src)の数値データが変化しなくなったことを、制御プロセッサ40が検知して減算交換命令の発行ループから抜け出して実行中のプログラムの次の処理に進むようにすればよい。
By executing the first iteration described above, the numerical data initially set and held in each PE is exchanged between the PEs.
The same numerical data replacement is performed after the second iteration. As a result of these iterations, in the case of the numerical data example described above, ascending order sort processing is completed in four iterations as shown in FIG. 4, that is, no further numerical data replacement operation may occur. I understand.
The control processor 40 detects this sort state, that is, the numerical data in the registers (src) of all PEs is not changed, and exits from the subtraction exchange instruction issue loop to proceed to the next process of the program being executed. What should I do?

なお、上記実施形態では、動作モードフラグ(flg)が0である、すなわち、昇順で数値データをソートする例について説明したが、動作モードフラグ(flg)が1である、すなわち、降順で数値データをソートし得ることは、上記の説明から自明となるところであるので、その逐一の説明は省略する。   In the above embodiment, the operation mode flag (flg) is 0, that is, the numerical data is sorted in ascending order. However, the operation mode flag (flg) is 1, that is, the numerical data is in descending order. Since it is obvious from the above description that the data can be sorted, the detailed description thereof will be omitted.

前述の減算交換命令の発行ループから抜け出すプログラム処理を以下に説明する。
上述のSIMD型並列プロセッサ10で使用可能な命令セットには、減算交換命令以外に、PE上で第1オペランドが指定するレジスタ値を第2オペランドが指定するレジスタへ転送する命令MVと、PE上で第1オペランドが指定するレジスタ値と第2オペランドが指定するレジスタ値とを減算しその結果を第3オペランドが指定するレジスタに格納すると共に、減算結果が0ならゼロフラグに1を設定する命令SUBと、第1オペランドが指定する種類のPE上の条件フラグの値の全PEに渡る論理和として得られる1ビット情報を制御プロセッサ(CP)上のマスクレジスタに格納する動作を指定する命令STSと、制御プロセッサ上のマスクレジスタの値が1ならば分岐せず0ならば分岐する動作を指定する条件分岐命令BRNMとが存在することを必要とする。
A program process for exiting from the above-described subtraction exchange instruction issue loop will be described below.
The instruction set that can be used in the above SIMD type parallel processor 10 includes an instruction MV for transferring a register value specified by the first operand on the PE to a register specified by the second operand, on the PE, in addition to the subtraction exchange instruction. Instruction SUB which subtracts the register value specified by the first operand and the register value specified by the second operand and stores the result in the register specified by the third operand, and sets the zero flag to 1 if the subtraction result is 0. And an instruction STS for designating an operation for storing 1-bit information obtained as a logical sum over all PEs of condition flag values on the type of PE designated by the first operand in a mask register on the control processor (CP), If the value of the mask register on the control processor is 1, a conditional branch instruction BRNM for specifying an operation for branching if it is 0 and not branching; To require the presence.

これらの条件に加えて、プログラムの記述の中での“..”なる記述は、その両隣の命令が同一サイクルに動作することを指定することを意味し、/*/*で囲まれた部分や//以降行末までをコメントとする。また、:で終る文字列は、当該文字列の出現位置の番地を示し、分岐命令のオペランドとして同ラベルを指定した場合は、同番地を意味するものとする。
また、src,origは、PE上でデータを格納するレジスタの識別子とし、ソート対象となるPE数に等しい個数のデータが1個ずつ各PEのレジスタ(src)に格納されており、かつ制御プロセッサPC上のマスクレジスタの値は前もって0にセットされているとする。その他、減算交換命令(SUBXCHG命令)に対する第1オペランドとして動作指定信号Iの値を、第2オペランドとしてソート対象データを格納するデータレジスタの識別子srcを指定するものとする。また、この例では、ソート対象データを昇順でソートすることを想定しているので、動作モードフラグ(flg)レジスタに0が設定されているとする。
In addition to these conditions, the description “..” in the program description means that the instructions on both sides operate in the same cycle, and the part enclosed in / * / * /// Comment after the end of the line. A character string ending with: indicates the address of the occurrence position of the character string. When the same label is designated as an operand of a branch instruction, it means the same address.
Src, orig is an identifier of a register for storing data on the PE, and data equal to the number of PEs to be sorted is stored one by one in the register (src) of each PE, and the control processor Assume that the value of the mask register on the PC is set to 0 in advance. In addition, the value of the operation designation signal I is designated as the first operand for the subtraction exchange instruction (SUBXCHG instruction), and the identifier src of the data register storing the sort target data is designated as the second operand. In this example, since it is assumed that the data to be sorted is sorted in ascending order, it is assumed that 0 is set in the operation mode flag (flg) register.

次に、上記条件に従うプログラムの例を記述する。
AGAIN:
/*番地A+0*/SUBXCHG命令 1,src../*番地A+1*/MV src,orig//step1を実行すると共にsrcの元の値を退避する
/*番地A+2*/SUBXCHG命令 0,src//step2を実行する
/*番地A+3*/SUBXCHG命令 1,src../*番地A+4*/SUB src,orig//step1を実行すると共にsrcの値と元の値とを比較する
/*番地A+5*/SUBXCHG命令 0,src../*番地A+6*/STS %Z//step2を実行すると共に、比較結果のゼロフラグをCPへ送付する
/*番地A+7*/SUBXCHG命令 1,src//step1を実行する
/*番地A+8*/BRNM
AGAIN../*番地A+9*/SUBXCHG命令
0,src//step2を実行すると共に、比較結果のゼロフラグをCPへ送付する
/*番地A+10*/
Next, the example of the program according to the said conditions is described.
AGAIN:
/ * Address A + 0 * / SUBXCHG instruction 1, src. . / * Address A + 1 * / MV src, orig // step1 is executed and the original value of src is saved / * address A + 2 * / SUBXCHG instruction 0, src // step2 is executed / * address A + 3 * / SUBXCHG instruction 1, src. . / * Address A + 4 * / SUB src, orig // step1 is executed and the value of src is compared with the original value / * address A + 5 * / SUBXCHG instruction 0, src. . / * Address A + 6 * / STS% Z // Step 2 is executed and the zero flag of the comparison result is sent to the CP./* Address A + 7 * / SUBXCHG instruction 1, src // step 1 is executed / * Address A + 8 * / BRNM
AGAIN. . / * Address A + 9 * / Execute SUBXCHG instruction 0, src // step2 and send the comparison result zero flag to CP / * Address A + 10 * /

このプログラムコードの場合、/*番地A+1*/のMV命令により srcの値がレジスタ(orig)にコピーされる。/*番地A+3*/〜/*番地A+9*/のループでは、繰り返し毎にSUBXCHG命令を計6回発行し、ソート処理の反復回数としては3反復を実施している中で、同時に各PE上でSUB命令を発行することでsrc値とorig値とが同一、すなわち、反復を一度実施しても、srcの値に変化が現れなかったかどうかの判定が行われ、かつ、STS命令を用いることで当該判定結果を表す条件フラグZの値の全PEに渡る論理和がCP上のマスクレジスタに格納され、論理和が0、すなわち、srcの値に変化が現れた場合、/*番地A+8*/BRNMの実行に際し分岐が成立し、次サイクルには/*番地A+10*/ではなく/*番地A+0*/へ飛ぶように動作する。   In the case of this program code, the value of src is copied to the register (orig) by the MV instruction at / * address A + 1 * /. In the loop of / * address A + 3 * / to / * address A + 9 * /, a SUBXCHG instruction is issued 6 times for each iteration, and the number of sort processing iterations is 3 iterations. When the SUB instruction is issued in step 1, the src value and the orig value are the same, that is, whether or not the src value has changed even after one iteration is performed, and the STS instruction is used. When the logical sum over all PEs of the value of the condition flag Z representing the determination result is stored in the mask register on the CP, and the logical sum is 0, that is, when a change occurs in the value of src, / * address A + 8 * When / BRNM is executed, a branch is established, and in the next cycle, the operation jumps to / * address A + 0 * / instead of / * address A + 10 * /.

一方、論理和が1、すなわち、srcの値に変化が現れなかった場合は、分岐を行わずに/*番地A+10*/へ進み、ループから抜け出す。
このようにループ終了判定を行う間でも、毎サイクルで減算交換命令を発行することができるため、減算交換命令を繰り返すループを抜けるためのCPによる終了判定処理は、全体の処理サイクル数に最小限の影響のみしか与えないようにすることができる。
On the other hand, when the logical sum is 1, that is, when there is no change in the value of src, the process proceeds to / * address A + 10 * / without branching and exits from the loop.
In this way, even during the loop end determination, the subtraction exchange instruction can be issued every cycle. Therefore, the CP end determination process for exiting the loop that repeats the subtraction exchange instruction is minimized to the total number of processing cycles. It can be made to give only the influence of.

このように、この実施形態によれば、減算交換命令を単純な演算の少ない組み合わせで実現させているので、減算交換命令を持たない、例えば、上述の「非特許文献」に記載されているSIMD型並列計算装置において減算交換命令相当の処理を行うのに7程度のマシンサイクルが掛かるのに対して、上記実施形態では奇偶変換ソート方式の各ステップを単一マシンサイクルで実装することが可能になる。したがって、減算交換命令を有するSIMD型並列計算装置では、ハードウェアコストの増加を僅かに抑えつつ、奇偶変換ソート方式に基づくデータのソート処理を効率良く実現することが可能になる。   Thus, according to this embodiment, since the subtraction exchange instruction is realized with a simple combination with few operations, the subtraction exchange instruction is not provided. For example, the SIMD described in the above-mentioned “non-patent document” In the above embodiment, each step of the odd / even transform sort method can be implemented in a single machine cycle, while it takes about 7 machine cycles to perform the processing equivalent to the subtraction exchange instruction in the type parallel computing device. Become. Therefore, in the SIMD type parallel computing device having the subtraction / exchange instruction, it is possible to efficiently realize the data sorting process based on the odd-even conversion sorting method while suppressing the increase in hardware cost slightly.

実施形態2Embodiment 2

図5は、この発明の実施形態2であるSIMD型並列プロセッサのプロセッシングエレメント数がソート対象データ数よりも少ない場合の動作説明図である。
この実施形態の構成が、実施形態1のそれと大きく異なる点は、ソート対象となるデータ数がPE数よりも多くてもソート処理全体を高速化し得るようにした点である。
この実施形態のSIMD型並列プロセッサは、その各PEに2つ以上のソート対象データを割り当てた上で、それらソート対象データについてのソート処理を「PE内での」奇偶変換ソート処理と「PE間での」奇偶変換ソート処理とに分け、後者の奇偶変換ソート処理について実施形態1で説明した奇偶変換ソート処理を実施してソート処理全体の高速化を達成するようにして構成される。
FIG. 5 is an operation explanatory diagram when the number of processing elements of the SIMD type parallel processor according to the second embodiment of the present invention is smaller than the number of data to be sorted.
The configuration of this embodiment is greatly different from that of the first embodiment in that the entire sorting process can be accelerated even if the number of data to be sorted is larger than the number of PEs.
The SIMD type parallel processor of this embodiment assigns two or more sort target data to each PE, and performs sort processing for the sort target data “within PE” and “between PEs”. The odd-even conversion sort process is divided into “even-odd conversion sort process”, and the odd-even conversion sort process described in the first embodiment is executed for the latter odd-even conversion sort process so as to achieve high speed of the entire sort process.

例えば、図5の動作説明図では、PE数を7とし、そのPE数の倍に当たる14個の数値データのソートを行う例を示している。図5中の(1)のマークでは同一PE内(PEinternal)でのデータ交換では、従来のPEアレイが有する命令セットを利用して実現する一方、図5中の(2)及び(3)のマークでは、PE間のデータ交換を実施形態1で説明したデータ交換を利用して実現する。なお、図5中の(2)及び(3)のマークで示すデータ交換は、順次的でも、また、同時的で実施してもよい。   For example, the operation explanatory diagram of FIG. 5 shows an example in which the number of PEs is 7, and 14 pieces of numerical data corresponding to twice the number of PEs are sorted. In the mark (1) in FIG. 5, the data exchange within the same PE (PEinternal) is realized by using the instruction set of the conventional PE array, while (2) and (3) in FIG. In the mark, data exchange between PEs is realized using the data exchange described in the first embodiment. The data exchange indicated by the marks (2) and (3) in FIG. 5 may be performed sequentially or simultaneously.

上述したデータ交換によれば、PE間のデータ交換を効率良く実現できない従来のSIMD型並列計算装置に比して、奇偶変換方式に基づくソート処理をより高速に行うことができる。   According to the data exchange described above, the sort processing based on the odd-even conversion method can be performed at a higher speed than the conventional SIMD type parallel computing device that cannot efficiently exchange data between PEs.

以上、この発明の実施形態を、図面を参照して詳述してきたが、この発明の具体的な構成は、これらの実施形態に限られるものではなく、この発明の要旨を逸脱しない範囲の設計の変更等があってもそれらはこの発明に含まれる。
例えば、実施形態1及び実施形態2では、ソート対象データとして、数値データを例にして説明したが、これに限らず、データの順序性を有するその他のデータについてのソートにも、この発明を適用し得る。
また、実施形態1及び実施形態2では、動作指定情報I及び動作モードフラグflgは、減算交換命令に予め埋め込められている例について説明したが、減算交換命令より前に実行される所要の命令の実行時に設定保持しておき、減算交換命令の実行時に保持されている各情報を対応する記憶保持手段、例えば、レジスタにセットしてこの発明のソート処理に用いるようにしてこの発明を実施することも可能である。
また、実施形態1及び実施形態2では、動作指定情報I、動作モードフラグflg及びマスク値mrの値を1又は0とする例について説明したが、その他の所定の値としてもよい。
Although the embodiments of the present invention have been described in detail with reference to the drawings, the specific configuration of the present invention is not limited to these embodiments, and the design does not depart from the gist of the present invention. These changes are included in the present invention.
For example, in the first and second embodiments, numerical data has been described as an example of sort target data. However, the present invention is not limited to this, and the present invention is also applied to sorting on other data having data order. Can do.
In the first embodiment and the second embodiment, the example in which the operation designation information I and the operation mode flag flg are embedded in the subtraction exchange instruction in advance has been described. However, a necessary instruction executed before the subtraction exchange instruction is described. The present invention is implemented by holding the setting at the time of execution and setting each information held at the time of execution of the subtraction / exchange instruction to a corresponding storage holding means, for example, a register and using it for the sort processing of the present invention. Is also possible.
In the first and second embodiments, the example in which the operation designation information I, the operation mode flag flg, and the mask value mr are set to 1 or 0 has been described. However, other predetermined values may be used.

ここに開示しているSIMD型並列データ処理装置及びSIMD型並列データ処理装置におけるデータソート方法並びにプロセッシングエレメントは、データのソートを必要とする各種のデータ処理装置に利用し得る。   The SIMD type parallel data processing device and the data sorting method and processing element in the SIMD type parallel data processing device disclosed herein can be used for various data processing devices that require data sorting.

10 SIMD型並列プロセッサ(SIMD型並列データ処理装置)
11〜11 プロセッシングエレメント
14〜14 セレクタ(データ交換手段の一部、第1のデータ選択手段)
16〜16 セレクタ(データ交換手段の残部、第2のデータ選択手段)
20、20、…、20 減算論理回路(制御情報出力手段の一部、第2の制御情報供給手段)
30 PE間結合線(制御情報入力手段、第1の制御情報供給手段)
40 制御プロセッサ(制御情報出力手段の残部)
10 SIMD type parallel processor (SIMD type parallel data processing device)
11 0 to 11 6 processing element 14 0 to 14 6 selector (part of data exchange means, first data selection means)
16 0 to 16 6 selector (remainder of data exchange means, second data selection means)
20 0 , 20 2 ,..., 20 6 subtraction logic circuit (part of control information output means, second control information supply means)
30 PE connection line (control information input means, first control information supply means)
40 Control processor (the remainder of the control information output means)

Claims (27)

ソート対象データを記憶する記憶手段を有し、一次元結合された複数のプロセッシングエレメントと、
ソート制御情報を供給する制御情報出力手段と、
該制御情報出力手段から入力される前記ソート制御情報に基づいて、前記複数のプロセッシングエレメントのうちの、所定の1つの前記プロセッシングエレメントの前記記憶手段の前記ソート対象データと所定の他の前記プロセッシングエレメントの前記記憶手段の前記ソート対象データとを交換する前記プロセッシングエレメント毎のデータ交換手段とを備えることを特徴とするSIMD型並列データ処理装置。
A plurality of processing elements having a storage means for storing data to be sorted and one-dimensionally coupled;
Control information output means for supplying sort control information;
Based on the sort control information input from the control information output means, among the plurality of processing elements, the sort target data in the storage means of the predetermined one processing element and the predetermined other processing element A SIMD type parallel data processing apparatus comprising: a data exchanging unit for each processing element that exchanges the sort target data of the storage unit.
ソート対象データを記憶する記憶手段を有し、一次元結合された複数のプロセッシングエレメントと、
ソート制御情報を供給する制御情報出力手段と、
該制御情報出力手段から入力される前記ソート制御情報に基づいて、前記複数のプロセッシングエレメントのうちの、ペアとなる一方の前記プロセッシングエレメントの前記記憶手段の前記ソート対象データと前記ペアとなる他方の前記プロセッシングエレメントの前記記憶手段のソート対象データとを交換する前記プロセッシングエレメント毎のデータ交換手段とを備えることを特徴とするSIMD型並列データ処理装置。
A plurality of processing elements having a storage means for storing data to be sorted and one-dimensionally coupled;
Control information output means for supplying sort control information;
Based on the sort control information input from the control information output means, among the plurality of processing elements, the other data to be paired with the data to be sorted in the storage means of the one processing element to be paired. A SIMD type parallel data processing apparatus comprising: a data exchanging unit for each processing element that exchanges data to be sorted in the storage unit of the processing element.
前記制御情報出力手段は、第1のソート制御情報を供給する第1の制御情報出力手段及び第2のソート制御情報を供給する第2の制御情報出力手段を有し、前記データ交換手段は、第1のデータ選択手段及び第2のデータ選択手段を有し、前記第1のデータ選択手段は、前記第1のソート制御情報に基づいて前記ペアとなる前記プロセッシングエレメントの前記記憶手段のうちのいずれか一方の前記ソート対象データを選択して出力する手段であり、前記第2のデータ選択手段は、前記第2のソート制御情報に基づいて前記第1のデータ選択手段及び自己の前記プロセッシングエレメントの前記記憶手段ののうちのいずれか一方の前記ソート対象データを選択して自己の前記プロセッシングエレメントの前記記憶手段に供給する手段であることを特徴とする請求項2記載のSIMD型並列データ処理装置。   The control information output means includes first control information output means for supplying first sort control information and second control information output means for supplying second sort control information, and the data exchange means includes: A first data selecting unit and a second data selecting unit, wherein the first data selecting unit is a storage unit of the processing element that is paired based on the first sort control information. A means for selecting and outputting any one of the data to be sorted, wherein the second data selection means is configured to select the first data selection means and the processing element of itself based on the second sort control information. A means for selecting the data to be sorted of one of the storage means and supplying the selected data to the storage means of the processing element of its own. SIMD type parallel data processing apparatus according to claim 2, wherein. 前記第1の制御情報出力手段は、前記複数のプロセッシングエレメントに接続される制御装置で実行される命令に基づいて前記第1のソート制御情報を生成して出力することを特徴とする請求項3記載のSIMD型並列データ処理装置。   4. The first control information output means generates and outputs the first sort control information based on an instruction executed by a control device connected to the plurality of processing elements. The SIMD type parallel data processing device described. 前記複数のプロセッシングエレメントのうちの偶数プロセッシングエレメントの前記第2の制御情報出力手段は、自己の前記プロセッシングエレメントの前記記憶手段から出力される前記ソート対象データと、前記第1のデータ選択手段から出力される前記ソート対象データと、前記第1のソート制御情報と、前記第1のソート制御情報の生成と共に生成される第3のソート制御情報とに基づいて前記第2のソート制御情報を生成して出力することを特徴とする請求項3記載のSIMD型並列データ処理装置。   The second control information output means of the even number processing element of the plurality of processing elements outputs the sort target data output from the storage means of its own processing element and the first data selection means. The second sort control information is generated based on the sort target data, the first sort control information, and the third sort control information generated together with the generation of the first sort control information. 4. The SIMD type parallel data processing apparatus according to claim 3, wherein the SIMD type parallel data processing apparatus outputs the data. 前記複数のプロセッシングエレメントのうちの奇数プロセッシングエレメントの前記第2の制御情報出力手段は、該奇数プロセッシングエレメントの両隣の前記プロセッシングエレメントで生成される前記第2のソート制御情報に基づいて第2のソート制御情報を生成して出力することを特徴とする請求項3記載のSIMD型並列データ処理装置。   The second control information output means of the odd number processing element of the plurality of processing elements is configured to output a second sort based on the second sort control information generated by the processing elements adjacent to the odd number processing element. 4. The SIMD type parallel data processing apparatus according to claim 3, wherein the control information is generated and output. 前記第1のソート制御情報は、前記複数のプロセッシングエレメントを制御する制御プロセッサで実行される減算交換命令に予め埋め込められている動作指定情報であり、前記第3のソート制御情報は、前記減算交換命令に予め埋め込められている動作モードフラグ及び前記動作指定情報に基づいて設定されるマスク情報であることを特徴とする請求項5記載のSIMD型並列データ処理装置。   The first sort control information is operation designation information embedded in advance in a subtraction exchange instruction executed by a control processor that controls the plurality of processing elements, and the third sort control information is the subtraction exchange 6. The SIMD type parallel data processing apparatus according to claim 5, wherein the SIMD type parallel data processing apparatus is an operation mode flag embedded in an instruction in advance and mask information set based on the operation designation information. 前記第2の制御情報出力手段は、減算論理回路と、動作モードフラグレジスタと、マスクレジスタとからなり、前記減算論理回路は、前記第1のデータ選択手段から出力される前記ソート対象データと、自己の前記プロセッシングエレメントの前記記憶手段の前記ソート対象データと、前記動作指定情報と、前記動作モードフラグレジスタの動作モードフラグと、前記マスクレジスタのマスク情報とに基づいて前記第2のソート制御情報を生成して出力する手段であることを特徴とする請求項7記載のSIMD型並列データ処理装置。   The second control information output means includes a subtraction logic circuit, an operation mode flag register, and a mask register. The subtraction logic circuit includes the sort target data output from the first data selection means, The second sort control information based on the data to be sorted in the storage means of the processing element of itself, the operation designation information, the operation mode flag of the operation mode flag register, and the mask information of the mask register 8. The SIMD type parallel data processing apparatus according to claim 7, wherein the SIMD type parallel data processing apparatus is a means for generating and outputting the data. 前記偶数プロセッシングエレメントのうちの、最初の偶数プロセッシングエレメントを除く前記偶数プロセッシングエレメントにおける前記マスク情報は、前記動作指定情報の如何に関係なしに第1の所定の情報として設定されるが、前記動作指定情報が予め決められる情報であるとき前記偶数プロセッシングエレメントのうちの、最初の偶数プロセッシングエレメントにおける前記マスク情報は、前記第1の所定の情報とは異なる情報として設定されることを特徴とする請求項8記載のSIMD型並列データ処理装置。   The mask information in the even number processing elements other than the first even number processing element among the even number processing elements is set as the first predetermined information regardless of the action designation information. The mask information in the first even-numbered processing element among the even-numbered processing elements when the information is predetermined information is set as information different from the first predetermined information. 8. The SIMD type parallel data processing device according to 8. 制御情報出力手段からソート制御情報の供給を受け、
供給される前記ソート制御情報に基づいて、ソート対象データを記憶する記憶手段を有し、一次元結合された複数のプロセッシングエレメントのうちの所定のプロセッシングエレメント間で両プロセッシングエレメントの前記記憶手段のソート対象データを交換することを特徴とするSIMD型並列データ処理装置におけるデータソート方法。
Received the supply of sort control information from the control information output means,
Sorting of the storage means of both processing elements between predetermined processing elements among a plurality of one-dimensionally connected processing elements, having storage means for storing data to be sorted based on the supplied sort control information A data sorting method in a SIMD type parallel data processing device, wherein target data is exchanged.
制御情報出力手段からソート制御情報の供給を受け、
供給される前記ソート制御情報に基づいて、ソート対象データを記憶する記憶手段を有し、一次元結合された複数のプロセッシングエレメントのうちのペアとなる一方のプロセッシングエレメントと前記ペアとなる他方のプロセッシングエレメントとの間で両プロセッシングエレメントの前記記憶手段の前記ソート対象データを交換することを特徴とするSIMD型並列データ処理装置におけるデータソート方法。
Received the supply of sort control information from the control information output means,
Based on the supplied sort control information, it has a storage means for storing data to be sorted, and one processing element that forms a pair among a plurality of processing elements that are one-dimensionally coupled and the other processing that forms the pair A data sorting method in a SIMD type parallel data processing apparatus, wherein the sort target data in the storage means of both processing elements is exchanged with an element.
前記制御情報出力手段は、第1及び第2のソート制御情報を出力し、前記第1のソート制御情報に基づいて前記ペアとなる前記プロセッシングエレメントの前記記憶手段ののうちのいずれか一方の前記ソート対象データを選択して出力し、前記第2のソート制御情報に基づいて選択出力された前記一方のソート対象データ及び前記ペアのうちの、自己の前記プロセッシングエレメントの前記記憶手段の前記ソート対象データのいずれか一方を選択して自己の前記プロセッシングエレメントの前記記憶手段に供給することを特徴とする請求項11記載のSIMD型並列データ処理装置におけるデータソート方法。   The control information output means outputs first and second sort control information, and the one of the storage means of the processing elements that are paired based on the first sort control information. Sort target data is selected and output, and the one sort target data selected and output based on the second sort control information and the pair of the sort means of the storage means of the processing element of its own processing element 12. The data sorting method in the SIMD type parallel data processing apparatus according to claim 11, wherein any one of the data is selected and supplied to the storage means of the processing element of its own. 前記第1のソート制御情報は、前記複数のプロセッシングエレメントに接続される制御装置で実行される命令に基づいて生成されることを特徴とする請求項11記載のSIMD型並列データ処理装置におけるデータソート方法。   12. The data sort in the SIMD type parallel data processing device according to claim 11, wherein the first sort control information is generated based on an instruction executed by a control device connected to the plurality of processing elements. Method. 前記複数のプロセッシングエレメントのうちの偶数プロセッシングエレメントのための前記第2のソート制御情報は、自己の前記プロセッシングエレメントの前記記憶手段から出力される前記ソート対象データと、前記第1のソート制御情報に基づいて出力される前記ソート対象データと、前記第1のソート制御情報と、前記第1のソート制御情報の生成と共に生成される第3のソート制御情報とに基づいて生成されることを特徴とする請求項12記載のSIMD型並列データ処理装置におけるデータソート方法。   The second sort control information for an even-numbered processing element of the plurality of processing elements includes the sort target data output from the storage unit of the processing element of the self and the first sort control information. Generated based on the sort target data output based on the first sort control information, and the third sort control information generated together with the generation of the first sort control information. The data sorting method in the SIMD type parallel data processing device according to claim 12. 前記複数のプロセッシングエレメントのうちの奇数プロセッシングエレメントのための前記第2のソート制御情報は、該奇数プロセッシングエレメントの両隣の前記プロセッシングエレメントで生成される前記第2のソート制御情報に基づいて生成されることを特徴とする請求項12記載のSIMD型並列データ処理装置におけるデータソート方法。   The second sort control information for an odd-numbered processing element among the plurality of processing elements is generated based on the second sort control information generated by the processing elements adjacent to the odd-numbered processing element. The data sorting method in the SIMD type parallel data processing device according to claim 12. 前記第1のソート制御情報は、前記複数のプロセッシングエレメントを制御する制御プロセッサで実行される減算交換命令に予め埋め込められている動作指定情報であり、前記第3のソート制御情報は、前記減算交換命令に予め埋め込められている動作モードフラグ及び前記動作指定情報に基づいて設定されるマスク情報であることを特徴とする請求項14記載のSIMD型並列データ処理装置におけるデータソート方法。   The first sort control information is operation designation information embedded in advance in a subtraction exchange instruction executed by a control processor that controls the plurality of processing elements, and the third sort control information is the subtraction exchange 15. The data sorting method in the SIMD type parallel data processing device according to claim 14, wherein the data is a mask information set based on an operation mode flag embedded in an instruction in advance and the operation designation information. 前記第2のソート制御情報は、前記第1のソート制御情報に基づいて出力される前記ソート対象データと、自己の前記プロセッシングエレメントの前記記憶手段の前記ソート対象データと、前記動作指定情報と、動作モードフラグと、マスク情報とに基づいて生成されることを特徴とする請求項16記載のSIMD型並列データ処理装置におけるデータソート方法。   The second sort control information includes the sort target data output based on the first sort control information, the sort target data of the storage unit of the processing element of itself, the operation designation information, The data sort method in the SIMD type parallel data processing device according to claim 16, wherein the data sort method is generated based on an operation mode flag and mask information. 前記偶数プロセッシングエレメントのうちの最初の偶数プロセッシングエレメントを除く前記偶数プロセッシングエレメントにおける前記マスク情報は、前記動作指定情報の如何に関係なく第1の所定の情報として設定されるが、前記動作指定情報が予め決められる情報であるとき前記偶数プロセッシングエレメントのうちの、最初の偶数プロセッシングエレメントにおける前記マスク情報は、前記第1の所定の情報とは異なる情報として設定されることを特徴とする請求項17記載のSIMD型並列データ処理装置におけるデータソート方法。   The mask information in the even number processing elements other than the first even number processing element among the even number processing elements is set as the first predetermined information regardless of the action designation information. 18. The mask information in the first even-numbered processing element among the even-numbered processing elements when the information is predetermined is set as information different from the first predetermined information. Sorting method in the SIMD type parallel data processing apparatus. ソート制御情報を受信する制御情報入力手段と、
該制御情報入力手段から出力される前記ソート制御情報に基づいて、一次元結合された複数のプロセッシングエレメントのうちの、所定の前記プロセッシングエレメントの記憶手段に設定されるソート対象データと自己の前記プロセッシングエレメントの前記記憶手段に設定されるソート対象データとを交換するデータ交換手段とを備えることを特徴とするプロセッシングエレメント。
Control information input means for receiving sort control information;
Based on the sort control information output from the control information input means, the sort target data set in the storage means of the predetermined processing element among the plurality of processing elements that are one-dimensionally coupled, and the processing of the processing apparatus itself. A processing element comprising data exchange means for exchanging data to be sorted set in the storage means of the element.
ソート制御情報を受信する制御情報入力手段と、
該制御情報入力手段から出力される前記ソート制御情報に基づいて、一次元結合された複数のプロセッシングエレメントのうちの、ペアとなる一方の前記プロセッシングエレメントの記憶手段に設定されるソート対象データと前記ペアとなる他方の前記プロセッシングエレメントの前記記憶手段に設定されるソート対象データとを交換するデータ交換手段とを備えることを特徴とするプロセッシングエレメント。
Control information input means for receiving sort control information;
Based on the sort control information output from the control information input means, the sort target data set in the storage means of one of the processing elements that form a pair among the plurality of processing elements that are one-dimensionally combined, and A processing element comprising: data exchange means for exchanging data to be sorted set in the storage means of the other processing element of the pair.
前記制御情報入力手段は、第1のソート制御情報を供給する第1の制御情報供給手段及び第2のソート制御情報を供給する第2の制御情報供給手段を有し、前記データ交換手段は、第1のデータ選択手段及び第2のデータ選択手段を有し、前記第1のデータ選択手段は、前記第1のソート制御情報に基づいて前記ペアとなる前記プロセッシングエレメントの前記記憶手段のうちの、いずれか一方の前記ソート対象データを選択して出力する手段であり、前記第2のデータ選択手段は、前記第2のソート制御情報に基づいて前記第1のデータ選択手段及び自己の前記プロセッシングエレメントの前記記憶手段のうちのいずれか一方の前記ソート対象データを選択して自己の前記プロセッシングエレメントの前記記憶手段に供給する手段であることを特徴とする請求項20記載のプロセッシングエレメント。   The control information input means includes first control information supply means for supplying first sort control information and second control information supply means for supplying second sort control information, and the data exchange means includes: A first data selecting unit and a second data selecting unit, wherein the first data selecting unit is a storage unit of the processing element that is paired based on the first sort control information. , A means for selecting and outputting any one of the sort target data, wherein the second data selection means is configured to select the first data selection means and the processing of its own based on the second sort control information. A means for selecting the data to be sorted of any one of the storage means of an element and supplying the selected data to the storage means of the processing element of its own; Processing element of claim 20, wherein. 前記第1の制御情報入力手段は、前記複数のプロセッシングエレメントに接続される制御装置で実行される命令に基づいて生成される前記第1のソート制御情報を受信することを特徴とする請求項20記載のプロセッシングエレメント。   21. The first control information input unit receives the first sort control information generated based on a command executed by a control device connected to the plurality of processing elements. The processing element described. 前記プロセッシングエレメントが、前記複数のプロセッシングエレメントのうちの偶数プロセッシングエレメントであるとき、該偶数プロセッシングエレメントの前記第2の制御情報供給手段は、自己の前記プロセッシングエレメントの前記記憶手段から出力される前記ソート対象データと、前記第1のデータ選択手段から出力される前記ソート対象データと、前記第1のソート制御情報と、前記第1のソート制御情報の生成と共に生成される第3のソート制御情報とに基づいて前記第2のソート制御情報を生成して出力することを特徴とする請求項21記載のプロセッシングエレメント。   When the processing element is an even-numbered processing element among the plurality of processing elements, the second control information supply means of the even-numbered processing element is configured to output the sort output from the storage means of its own processing element. Target data, the sort target data output from the first data selection means, the first sort control information, and the third sort control information generated together with the generation of the first sort control information; 23. The processing element according to claim 21, wherein the second sort control information is generated and output based on the information. 前記プロセッシングエレメントが前記複数のプロセッシングエレメントのうちの、奇数プロセッシングエレメントであるとき、該奇数プロセッシングエレメントの前記第2の制御情報供給手段は、該奇数プロセッシングエレメントの両隣の前記プロセッシングエレメントで生成される前記第2のソート制御情報に基づいて第2のソート制御情報を生成して出力することを特徴とする請求項21記載のプロセッシングエレメント。   When the processing element is an odd processing element of the plurality of processing elements, the second control information supply means of the odd processing element is generated by the processing element on both sides of the odd processing element. The processing element according to claim 21, wherein the second sort control information is generated and output based on the second sort control information. 前記第1のソート制御情報は、前記複数のプロセッシングエレメントを制御する制御プロセッサで実行される減算交換命令に予め埋め込められている動作指定情報であり、前記第3のソート制御情報は、前記減算交換命令に予め埋め込められている動作モードフラグ及び前記動作指定情報に基づいて設定されるマスク情報であることを特徴とする請求項23記載のプロセッシングエレメント。   The first sort control information is operation designation information embedded in advance in a subtraction exchange instruction executed by a control processor that controls the plurality of processing elements, and the third sort control information is the subtraction exchange 24. The processing element according to claim 23, wherein the processing element is mask information set based on an operation mode flag embedded in an instruction in advance and the operation designation information. 前記第2の制御情報供給手段は、減算論理回路と、動作モードフラグレジスタと、マスクレジスタとからなり、前記減算論理回路は、前記第1のデータ選択手段から出力される前記ソート対象データと、自己の前記プロセッシングエレメントの前記記憶手段の前記ソート対象データと、前記動作指定情報と、前記動作モードフラグレジスタの動作モードフラグと、前記マスクレジスタのマスク情報とに基づいて前記第2のソート制御情報を生成して出力する手段であることを特徴とする請求項25記載のプロセッシングエレメント。   The second control information supply unit includes a subtraction logic circuit, an operation mode flag register, and a mask register. The subtraction logic circuit includes the sort target data output from the first data selection unit, The second sort control information based on the data to be sorted in the storage means of the processing element of itself, the operation designation information, the operation mode flag of the operation mode flag register, and the mask information of the mask register 26. The processing element according to claim 25, wherein the processing element is a means for generating and outputting the data. 前記偶数プロセッシングエレメントのうちの、最初の偶数プロセッシングエレメントを除く前記偶数プロセッシングエレメントにおける前記マスク情報は、前記動作指定情報の如何に関係なしに第1の所定の情報として設定されるが、前記動作指定情報が予め決められる情報であるとき前記偶数プロセッシングエレメントのうちの最初の偶数プロセッシングエレメントにおける前記マスク情報は、前記第1の所定の情報とは異なる情報として設定されることを特徴とする請求項26記載のプロセッシングエレメント。   The mask information in the even number processing elements other than the first even number processing element among the even number processing elements is set as the first predetermined information regardless of the action designation information. 27. The mask information in the first even processing element among the even processing elements when the information is predetermined information is set as information different from the first predetermined information. The processing element described.
JP2010546611A 2009-01-13 2010-01-07 SIMD type parallel data processing apparatus, data sorting method, and processing element Active JP5445469B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2010546611A JP5445469B2 (en) 2009-01-13 2010-01-07 SIMD type parallel data processing apparatus, data sorting method, and processing element

Applications Claiming Priority (4)

Application Number Priority Date Filing Date Title
JP2009004380 2009-01-13
JP2009004380 2009-01-13
JP2010546611A JP5445469B2 (en) 2009-01-13 2010-01-07 SIMD type parallel data processing apparatus, data sorting method, and processing element
PCT/JP2010/050119 WO2010082529A1 (en) 2009-01-13 2010-01-07 Simd type parallel data processor, data sort method and processing element

Publications (2)

Publication Number Publication Date
JPWO2010082529A1 true JPWO2010082529A1 (en) 2012-07-05
JP5445469B2 JP5445469B2 (en) 2014-03-19

Family

ID=42339782

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2010546611A Active JP5445469B2 (en) 2009-01-13 2010-01-07 SIMD type parallel data processing apparatus, data sorting method, and processing element

Country Status (2)

Country Link
JP (1) JP5445469B2 (en)
WO (1) WO2010082529A1 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR102235803B1 (en) 2017-03-31 2021-04-06 삼성전자주식회사 Semiconductor device
US10649771B2 (en) 2017-03-31 2020-05-12 Samsung Electronics Co., Ltd. Semiconductor device
KR102343652B1 (en) 2017-05-25 2021-12-24 삼성전자주식회사 Method for aligning sequence for vector processor

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3152466B2 (en) * 1991-04-04 2001-04-03 三菱電機株式会社 Sorting device and sorting method
JPH05189202A (en) * 1992-01-10 1993-07-30 Fujitsu Ltd Parallel sorting system
JPH10149276A (en) * 1996-11-21 1998-06-02 Nippon Telegr & Teleph Corp <Ntt> Sorting circuit and its method
JP3955741B2 (en) * 2001-04-02 2007-08-08 株式会社リコー SIMD type microprocessor having sort function
JP2007102799A (en) * 2006-10-30 2007-04-19 Ricoh Co Ltd Simd (single instruction-stream multiple data-stream) type microprocessor having sorting function

Also Published As

Publication number Publication date
JP5445469B2 (en) 2014-03-19
WO2010082529A1 (en) 2010-07-22

Similar Documents

Publication Publication Date Title
EP2569694B1 (en) Conditional compare instruction
EP0450658B1 (en) Parallel pipelined instruction processing system for very long instruction word
JP5145809B2 (en) Branch prediction device, hybrid branch prediction device, processor, branch prediction method, and branch prediction control program
US11068265B2 (en) Sequence alignment method of vector processor
EP3326060B1 (en) Mixed-width simd operations having even-element and odd-element operations using register pair for wide data elements
WO2009131007A1 (en) Simd parallel computer system, simd parallel computing method, and control program
EP2352082B1 (en) Data processing device for performing a plurality of calculation processes in parallel
CN107851016B (en) Vector arithmetic instructions
JP5445469B2 (en) SIMD type parallel data processing apparatus, data sorting method, and processing element
US20110055647A1 (en) Processor
JP2009230338A (en) Processor and information processing apparatus
JP6428488B2 (en) Adder / Subtractor and Control Method of Adder / Subtractor
JP2009037291A (en) Semiconductor device
CN113032011B (en) Method and system for executing cyclic program in data flow architecture
JP2793342B2 (en) Arithmetic processing unit
JP4444305B2 (en) Semiconductor device
US9317474B2 (en) Semiconductor device
JP3707729B2 (en) Address generation interlock detection method and system
Luk et al. A systolic LRU processor and its top-down development
US9250898B2 (en) VLIW processor, instruction structure, and instruction execution method
US20240118891A1 (en) Processor
JP3895267B2 (en) SIMD processor
JP4516495B2 (en) Data processing method in SIMD type microprocessor
JP3771682B2 (en) Vector processing equipment
JP2012099004A (en) Data transfer unit, arithmetic unit, device equipped with the same, and data transfer method

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20121205

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20131126

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20131209

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

Ref document number: 5445469

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150