JP7393519B2 - Arithmetic device and method - Google Patents
Arithmetic device and method Download PDFInfo
- Publication number
- JP7393519B2 JP7393519B2 JP2022505966A JP2022505966A JP7393519B2 JP 7393519 B2 JP7393519 B2 JP 7393519B2 JP 2022505966 A JP2022505966 A JP 2022505966A JP 2022505966 A JP2022505966 A JP 2022505966A JP 7393519 B2 JP7393519 B2 JP 7393519B2
- Authority
- JP
- Japan
- Prior art keywords
- instruction
- executing
- functional unit
- pipeline
- functional units
- 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.)
- Active
Links
- 238000000034 method Methods 0.000 title claims description 19
- 230000006870 function Effects 0.000 claims description 30
- 238000004364 calculation method Methods 0.000 claims description 28
- 230000008569 process Effects 0.000 description 13
- 238000010586 diagram Methods 0.000 description 4
- 230000008901 benefit Effects 0.000 description 2
- 201000006054 Mulibrey nanism Diseases 0.000 description 1
- 230000001419 dependent effect Effects 0.000 description 1
- 230000004044 response Effects 0.000 description 1
- 230000007704 transition Effects 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F15/00—Digital computers in general; Data processing equipment in general
- G06F15/16—Combinations of two or more digital computers each having at least an arithmetic unit, a program unit and a register, e.g. for a simultaneous processing of several programs
- G06F15/163—Interprocessor communication
- G06F15/173—Interprocessor communication using an interconnection network, e.g. matrix, shuffle, pyramid, star, snowflake
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F17/00—Digital computing or data processing equipment or methods, specially adapted for specific functions
- G06F17/10—Complex mathematical operations
- G06F17/16—Matrix or vector computation, e.g. matrix-matrix or matrix-vector multiplication, matrix factorization
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/30—Arrangements for executing machine instructions, e.g. instruction decode
- G06F9/38—Concurrent instruction execution, e.g. pipeline, look ahead
-
- H—ELECTRICITY
- H03—ELECTRONIC CIRCUITRY
- H03K—PULSE TECHNIQUE
- H03K19/00—Logic circuits, i.e. having at least two inputs acting on one output; Inverting circuits
- H03K19/02—Logic circuits, i.e. having at least two inputs acting on one output; Inverting circuits using specified components
- H03K19/173—Logic circuits, i.e. having at least two inputs acting on one output; Inverting circuits using specified components using elementary logic circuits as components
- H03K19/177—Logic circuits, i.e. having at least two inputs acting on one output; Inverting circuits using specified components using elementary logic circuits as components arranged in matrix form
Description
本出願は、2020年3月11日に出願された特許出願番号2020-042169号に基づくものであって、その優先権の利益を主張するものであり、その特許出願のすべての内容が、参照により本明細書に組み入れられる。 This application is based on patent application No. 2020-042169 filed on March 11, 2020, and claims the benefit of priority thereto, and all contents of that patent application are referred to , incorporated herein by reference.
本開示は、演算装置及び演算方法に関する。 The present disclosure relates to an arithmetic device and an arithmetic method.
従来から、命令を処理する演算器である機能ユニットを複数備え、入力される一連の命令に対して複数の機能ユニットでパイプライン処理(以下「多段演算パイプライン」ともいう。)を行なう演算装置が用いられている。 Conventionally, an arithmetic device is equipped with a plurality of functional units that are arithmetic units that process instructions, and performs pipeline processing (hereinafter also referred to as "multi-stage arithmetic pipeline") with the plurality of functional units for a series of input instructions. is used.
例えば特許文献1には、乗算器MULと加算機ADD等の複数の機能ユニットによってパイプライン処理を行う構成が開示されている。特許文献1に記載の構成は、乗算器MULは同時に入力された値「a」「b」の対応する要素の組の各データを乗算して加算器ADDに順次出力し、加算器ADDは出力された乗算値と、前回の加算器ADDの出力とを順次加算している。
For example,
ここで、多段演算パイプラインを用いたチェイニングによって命令(演算)を行う演算装置は、パイプラインの立ち上げや立ち下がりのオーバーヘッドを要し、加算や乗算等が組み合わさった複雑な演算を実行する際に、パイプラインの立ち上げ立ち下げを複数回行う場合があった。また、複雑な演算を実行する場合には、他の機能ユニットによる演算の終了を待ってから演算を行う機能ユニットが存在する場合があった。すなわち、パイプラインを用いたチェイニングでは効率的な演算を行えない場合があった。 Here, an arithmetic unit that performs instructions (operations) by chaining using a multi-stage arithmetic pipeline requires overhead for starting and falling of the pipeline, and performs complex operations that combine addition, multiplication, etc. When doing so, there were cases where the pipeline was started and stopped multiple times. Furthermore, when executing a complex calculation, there may be a functional unit that waits for the completion of calculations by other functional units before performing the calculation. That is, chaining using a pipeline may not be able to perform efficient calculations.
本開示は、パイプラインを用いたチェイニングによる演算をより効率的に行える、演算装置及び演算方法を提供することを目的とする。 An object of the present disclosure is to provide an arithmetic device and an arithmetic method that can more efficiently perform chaining operations using a pipeline.
本開示の一態様の演算装置は、同じ機能を有する複数の機能ユニットを含むパイプラインを具備し、チェイニングによって演算を行う演算装置であって、命令を実行中でない前記機能ユニットの有無を判定する判定部と、前記何れかの機能ユニットが命令を実行している際に、前記命令を実行中でない前記機能ユニットに対して、前記何れかの機能ユニットによる命令実行と並行して実行可能な前記命令を実行させる制御部と、を備える。 An arithmetic device according to an aspect of the present disclosure is an arithmetic device that includes a pipeline including a plurality of functional units having the same function and performs arithmetic operations by chaining, and determines whether or not there is a functional unit that is not executing an instruction. and a determination unit that is capable of being executed in parallel with the execution of an instruction by any of the functional units for the functional unit that is not executing the instruction when any of the functional units is executing the instruction. and a control unit that executes the instructions.
本発明によれば、パイプラインを用いたチェイニングによる演算をより効率的に行える。 According to the present invention, calculations by chaining using a pipeline can be performed more efficiently.
本開示についての上記目的およびその他の目的、特徴や利点は、添付の図面を参照しながら下記の詳細な記述により、より明確になる。その図面は、
以下、図面を参照して本開示の実施形態を説明する。なお、以下に説明する実施形態は、本開示を実施する場合の一例を示すものであって、本開示を以下に説明する具体的構成に限定するものではない。本開示の実施にあたっては、実施形態に応じた具体的構成が適宜採用されてよい。 Embodiments of the present disclosure will be described below with reference to the drawings. Note that the embodiment described below shows an example of implementing the present disclosure, and the present disclosure is not limited to the specific configuration described below. In implementing the present disclosure, specific configurations depending on the embodiments may be adopted as appropriate.
図1は、本実施形態の演算装置10の概略構成図である。本実施形態の演算装置10は、複数の機能ユニット12を含むパイプラインを具備し、チェイニングによって演算を行うものである。
FIG. 1 is a schematic configuration diagram of an
機能ユニット12は、例えば、メモリからレジスタへデータをコピーするLD、レジスタからメモリにデータをコピーするST、加算機能を有するADD(加算器)、乗算機能を有するMUL(乗算器)、除算機能を有するDIV(除算器)等の演算器である。これら複数の機能ユニット12は、パイプライン処理を実行するマルチパイプベクトル演算器(以下「ベクトル演算器」という。)20に備えられる。
The
次に、本実施形態の演算装置10によるパイプライン処理について説明する。
Next, pipeline processing by the
まず、一例として、パイプラインの段数(以下「パイプライン段数」という。)を4段とし、機能ユニット12の数を5つ(LD、ST、ADD、MUL、DIV)で構成されるベクトル演算器20を想定する。以下の説明では、パイプライン段数を4段とするベクトル演算器20のハードウエア状態をディフォルトモードという。
First, as an example, the number of pipeline stages (hereinafter referred to as "pipeline stage number") is four stages, and the number of
このディフォルトモードは、パイプライン段数をより少なくしたモード1とモード2に再構成することが可能である。モード1は、パイプライン段数が2段であり、機能ユニット12の数が8つ(LD、ST、2つのADD、2つのMUL、2つのDIV)である。モード2は、パイプライン段数が1段であり、機能ユニット12の数が14個(LD、ST、4つのADD、4つのMUL、4つのDIV)である。このように、ディフォルトモードよりも段数を少なくしたモード1やモード2では、ADD、MUL、DIV等の同じ機能を有する機能ユニット12が複数存在する。
This default mode can be reconfigured into
なお、本実施形態の演算装置10は、一例として、ハードウエアのモード(パイプライン段数と機能ユニット12の数の組み合わせ)の全バリエーションが予め定義されており、現在のハードウエアのモードはフラグ値として専用のレジスタ(モードレジスタ)に保持される。そして、ハードウエアのモードは専用の制御命令により設定される。
Note that in the
このように、本実施形態の演算装置10は、ディフォルトモードから、同じ機能を有する複数の機能ユニット12を含んでパイプラインを再構成可能とされている。そして、本実施形態の演算装置10は、機能ユニット12が命令を実行している場合に、命令を実行中でない他の機能ユニット12に対して並行して実行可能な命令を実行させる。このため、本実施形態の演算装置10は、ある機能ユニット12が命令を実行している場合に、他の機能ユニット12が命令を実行しているか否かを判定する機能(Out-of-Order機能)を有している。
In this way, the
Out-of-Order機能を実現するために、本実施形態の機能ユニット12は、命令の実行中であるか否かを識別する識別子を保持するステートレジスタを有している。演算装置10は、このステートレジスタに基づいて、命令を実行中でない機能ユニット12を判定し、機能ユニット12毎に命令の割り当てを行う。本実施形態では、一例として、命令を実行中である機能ユニット12のステートレジスタは“1”であり、命令を実行中でない機能ユニット12のステートレジスタは“0”である。
In order to implement the Out-of-Order function, the
なお、演算に寄与する機能ユニット12の総数(パイプライン段数と対応する機能ユニット12の数との積)が一定であるので、ステートレジスタは、機能ユニット12の総数を保持するために十分なbit数があればよい。上記例では、パイプライン段数が最大で4段であり、同じ機能を有する機能ユニット12が3種類(ADD、MUL、DIV)であるので、ステートレジスタは3×4=12bitでよい。なお、Out-of-Order機能を実行するためには、LD及びSTの機能ユニット12が実行中か否かを判定する必要があるのでLD及びSTも1bitずつのステートレジスタを有する。但し、LD及びSTのステートレジスタは、パイプライン段数には関係なく1bitずつであればよい。
Note that since the total number of
次に、一例として、図2を参照して、モード1で“((A+B)+C)×D”という演算をチェイニングする場合について説明する。モード1では、上述のように、ADD、MUL、DIVの機能ユニット12の数は各々2つである。なお、図2及び後述の図3における各値(A,B,C,D)に対応するベクトルレジスタ幅は固定されており、例えば64bitや32bitである。
Next, as an example, with reference to FIG. 2, a case will be described in which the operation "((A+B)+C)×D" is chained in
モード1では、まず“A+B”の演算結果をレジスタ(中間レジスタ)へ書き出す処理(ADD命令)が発行される。ADD命令の発行時点では、何れの機能ユニット12も未だ命令を実行中でないので、全ての機能ユニット12のステートレジスタは“0”である。ここでADD命令を発行することにより、1つ目のADDに対応する機能ユニット12のステートレジスタを“1”に設定する。
In
そして、次の命令サイクルでは、最初のADD命令の完了を待たず、最初のADD命令の結果に対して“C”を加算するADD命令が発行される。2つ目のADDのステートレジスタは“0”なので、命令を実行中でないADDがあると判断され、2つ目のADDのステートレジスタを“1”に設定し、最初のADD命令とのチェイニングが行われる。 Then, in the next instruction cycle, an ADD instruction that adds "C" to the result of the first ADD instruction is issued without waiting for the completion of the first ADD instruction. Since the state register of the second ADD is "0", it is determined that there is an ADD that is not executing an instruction, so the state register of the second ADD is set to "1" and chaining with the first ADD instruction is performed. will be held.
さらに、次の命令サイクルでは先行の2つのADD命令の終了を待たずに、“(A+B)+C”に対する“D”の乗算命令が発行される。このときMULのステートレジスタは“0”なので、1つ目のMULのステートレジスタを“1”に設定し、先行の2つのADD命令とのチェイニングが行われる。 Furthermore, in the next instruction cycle, a multiplication instruction of "D" for "(A+B)+C" is issued without waiting for the completion of the two preceding ADD instructions. At this time, the MUL state register is "0", so the first MUL state register is set to "1", and chaining with the previous two ADD instructions is performed.
次に、図3を参照して“(A+B)×(C+D)”という演算をモード1でチェイニングする場合について説明する。まず“(A+B)”と“(C+D)”との演算は各々独立して実行が可能である。このため“(A+B)”の演算を一つのADDが行うと共に、“(C+D)”の演算命令は、もう他のADDによって演算が行われる。すなわち、これらの2つのADD命令は互いの終了を待つことなく同時に発行される。従って、モード1の場合にはハードウエアのリソースとしてこれら2つのADD命令を同時に割り当て可能である。
Next, with reference to FIG. 3, a case will be described in which the calculation "(A+B)×(C+D)" is chained in
図3の例では、MULの機能ユニット12が一つ空きとなる。ここで次の命令(後続命令)に上記のチェイニング演算とは依存関係のないMUL命令がある場合には、そのMUL命令を同時実行できる。結果として演算機能ユニットの稼働率をディフォルトモードよりも高くすることができ、従来と同じハードウエアリソース(演算器の数)でもより高い実効性能を発揮することが可能となる。
In the example of FIG. 3, one MUL
また、本実施形態の機能ユニット12は、命令の実行状態を示すマスクレジスタ30(図2,3参照)を備える。そして、複数の他の機能ユニット12による演算結果を用いて次の命令を実行する機能ユニット12は、複数の他の機能ユニット12のマスクレジスタ30が命令の実行終了を示した後に次の命令を実行する。
Further, the
より具体的にはマスクレジスタ30は、ベクトルレジスタ長に対応して設けられており、演算の進行度合いに応じて“0”が“1”に書き換えられる。各機能ユニット12における演算が完了すると、マスクレジスタ30は全て“1”とされる。そして、先の命令を実行した複数の機能ユニット12のマスクレジスタ30のAND(論理積)によって、当該複数の機能ユニット12による演算が完了したか否かが判定される。すなわち、先の命令を実行する複数の機能ユニット12による演算が終了するまで、次の命令を実行する機能ユニット12は演算を行わない。
More specifically, the
すなわち、図3の例では、“A+B”の演算が完了するとレジスタ領域が全て“1”となり、“C+D”の演算が完了するとレジスタ領域が全て“1”となる。そして、“A+B”の演算及び“C+D”の演算が完了した場合に、“(A+B)×(C+D)”の演算が開始される。 That is, in the example of FIG. 3, when the operation "A+B" is completed, all the register areas become "1", and when the operation "C+D" is completed, all the register areas become "1". Then, when the calculation of "A+B" and the calculation of "C+D" are completed, the calculation of "(A+B)×(C+D)" is started.
これにより、複数の機能ユニット12が先の命令を非同期で行っても、次の命令を実行する機能ユニット12は、複数の機能ユニット12による命令の実行完了を待って演算を行うことになるので、エラーを生じさせることなく次の命令の実行が可能となる。
As a result, even if multiple
なお、先の命令を実行するパイプラインの段数よりも次の命令を実行するパイプラインの段数が多い場合、例えば先のパイプラインが2段であり、後のパイプラインが4段の場合にも、上述と同様にマスクレジスタ30によって先のパイプラインによる命令(演算)の進行度合いが判定される。このため、異なる段数のパイプラインの組み合わせによってチェイニングによる演算が行われる場合であっても、エラーを生じさせることなく命令の実行が可能となる。
Note that if the number of stages in the pipeline that executes the next instruction is greater than the number of stages in the pipeline that executes the previous instruction, for example, if the first pipeline has two stages and the second pipeline has four stages, , as described above, the degree of progress of the previous pipeline instruction (operation) is determined by the
このように、本実施形態の演算装置10は、4段のパイプラインをそれよりも段数の小さいパイプライン(2段のパイプライン)に再構成することによって、パイプラインの立ち上げ、立ち下がりのオーバーヘッドを少なくできる。このとき、2段のパイプラインでは、同じ機能を有する機能ユニット12を複数(少なくとも2つ)備えることになる。
In this way, the
具体的には、上述の4段のパイプラインによって“((A+B)+C)×D”という演算を行う場合、“A+B=E”の演算をチェイニングで行った後に、“(E+C)×D”を新たなチェイニングで行う必要がある。このため、4段のパイプラインでは、パイプラインの立ち上げと立ち下がりとを2度行う必要があり、オーバーヘッドが2回分必要となる。また、“A+B=E”の演算結果を一旦メモリに記憶(ストア)させ、“(E+C)×D”の演算を行う場合に、演算結果である“E”をメモリから読み出す必要があり、処理が非効率であった。 Specifically, when performing the operation “((A+B)+C)×D” using the four-stage pipeline described above, after performing the operation “A+B=E” by chaining, “(E+C)×D” ” needs to be performed with new chaining. Therefore, in a four-stage pipeline, it is necessary to start and fall the pipeline twice, which requires overhead for two times. In addition, when the calculation result of "A + B = E" is temporarily stored in memory and the calculation of "(E + C) x D" is performed, it is necessary to read out the calculation result "E" from the memory and process it. was inefficient.
一方、2段のパイプラインでは、同じ機能を有する機能ユニット12(ADD、MUL、DIV)を2つずつ有することとなる。そして、ある機能ユニット12が命令を実行している際に、命令を実行中でない他の機能ユニット12の有無を判定し(Out-of-Order機能)、命令を実行中でない他の機能ユニット12に対して、ある機能ユニット12による命令実行と並行して実行可能な命令を実行させる。
On the other hand, a two-stage pipeline has two functional units 12 (ADD, MUL, DIV) each having the same function. When a certain
これにより、2段のパイプラインでは、“((A+B)+C)×D”の演算を一度のチェイニングによって行うことができ、パイプラインの立ち上げと立ち下がりと(オーバーヘッド)が1度で済む。また、2段のパイプラインでは、4段のパイプラインで行ったような演算結果を一旦メモリに記憶させるという処理は不要なため、より効率的な処理が可能となる。 As a result, in a two-stage pipeline, the operation "((A+B)+C)×D" can be performed by chaining once, and the pipeline startup and fall (overhead) can be done only once. . In addition, the two-stage pipeline does not require the process of temporarily storing the calculation results in memory, as is the case with the four-stage pipeline, so more efficient processing is possible.
このことから、本実施形態のようにパイプラインの段数を少なくし、同じ機能を有する複数の機能ユニット12を含むパイプラインとすることで、パイプラインの立ち上げと立ち下がりとに要するオーバーヘッドの時間を削減でき、演算の効率化が可能となる。
Therefore, by reducing the number of pipeline stages and creating a pipeline that includes a plurality of
このようなパイプラインによるチェイニングを実行するために、図1に示されるように本実施形態の演算装置10は、実行判定部22と制御部24とを備える。
In order to execute such pipeline chaining, the
実行判定部22は、Out-of-Order機能を実行する構成要素であり、命令を実行中でない機能ユニット12の有無を判定する。なお、実行判定部22は、ステートレジスタに基づいて、命令を実行中でない機能ユニット12を判定する。
The execution determination unit 22 is a component that executes an Out-of-Order function, and determines whether there is a
制御部24は、命令を実行中でない機能ユニット12に対して実行可能な命令を実行させる。本実施形態の制御部24は、何れかの機能ユニット12が命令を実行している際に、命令を実行中でない機能ユニット12に対して、何れかの機能ユニット12による命令実行と並行して実行可能な命令を実行させる。
The
なお、演算装置10は、パイプラインの段数に応じた、換言するとモードに応じた制御を行う。例えば、4段のパイプライン(ディフォルトモード)では、Out-of-Order機能を実行せずに、2段又は1段のパイプラン(モード1又はモード2)ではOut-of-Order機能を実行する。換言すると、Out-of-Order機能は、同じ機能を有する複数の機能ユニット12を備えるパイプラインに対して実行される。なお、モードは、ベクトル演算器20に実行させる一連の演算に応じて適宜選択される。
Note that the
また、これに限らず、ディフォルトモードであってもOut-of-Order機能を実行するとしてもよい。すなわち、同じ機能を有する機能ユニット12だけでなく、異なる機能ユニット12(LD、ST、MUL、ADD、DIV)全てにおいて依存関係にない機能ユニット12は同時に実行可能としてもよい。
Further, the present invention is not limited to this, and the Out-of-Order function may be executed even in the default mode. That is, not only the
なお、本実施形態の演算装置10は、機能ユニット12による実行待ちの命令を命令待機バッファ14に記憶させる。そして、命令待機バッファ14に記憶された命令を実行可能な機能ユニット12が有った場合に、命令待機バッファ14から命令が順次読み出されて機能ユニット12によって実行される。これにより、命令を実行中でない機能ユニット12へ命令を効率的に割り当てることを可能とする。
Note that the
図4は、Out-of-Order機能を実行するチェイニング演算処理の流れを示すフローチャートである。このチェイニング演算処理は、演算装置10が備える記録媒体に格納されたプログラムによって実行される。このプログラムが実行されることで、プログラムに対応する方法が実行される。
FIG. 4 is a flowchart showing the flow of chaining calculation processing for executing the Out-of-Order function. This chaining calculation process is executed by a program stored in a recording medium included in the
なお、図4に示されるチェイニング演算処理はOut-of-Order機能を実行するものであるため、このチェイニング演算処理の実行前にモードレジスタを確認することで、Out-of-Order機能を実行可能なモードであるか否かが判定される。Out-of-Order機能を実行可能なモードでない場合は、Out-of-Order機能を実行しない通常のチェイニング演算処理が実行される。または、Out-of-Order機能を実行可能なモードに再構成される。 Note that the chaining calculation process shown in Figure 4 executes the Out-of-Order function, so by checking the mode register before executing the chaining calculation process, the Out-of-Order function can be executed. It is determined whether the mode is executable. If the mode is not one in which the Out-of-Order function can be executed, normal chaining calculation processing that does not execute the Out-of-Order function is executed. or reconfiguring the Out-of-Order functionality into a viable mode.
まず、ステップS100では、実行判定部22が各機能ユニット12のステートレジスタを確認し、命令を実行中でない機能ユニット12の有無を判定する(Out-of-Order機能)。なお、ここでいう機能ユニット12の有無とは、与えられた命令を実行可能な機能ユニット12である。例えば与えられた命令がADD命令である場合には、このADD命令を実行可能な機能ユニット12の有無が実行判定部22によって判定される。
First, in step S100, the execution determination unit 22 checks the state register of each
次のステップS102では、命令を実行中でない機能ユニット12が有る場合は、ステップS106へ移行する一方、命令を実行しないない機能ユニット12が無い場合は、ステップS104へ移行する。
In the next step S102, if there is a
ステップS104では、命令を実行できる機能ユニット12が無いため、当該命令を実行待ちの命令として命令待機バッファ14へキューイングし、ステップS100へ戻る。
In step S104, since there is no
ステップS106では、制御部24が、命令を実行中でない機能ユニット12へ命令の割り当てを行う。
In step S106, the
次のステップS108では、制御部24が、命令が割り当てられた機能ユニット12のステートレジスタを“1”に設定する。
In the next step S108, the
次のステップS110では、機能ユニット12が割り当てられた命令を実行する。
In the next step S110, the
次のステップS112では、制御部24が、割り当てられた命令の実行を機能ユニット12が完了したか否かを判定し、肯定判定の場合はステップS114へ移行し、否定判定の場合はステップS116へ移行する。なお、命令を実行している機能ユニット12が複数有る場合、ステップS112では各々の機能ユニット12毎に命令の実行が完了したか否かを判定する。
In the next step S112, the
ステップS114では、制御部24が、命令を完了した機能ユニット12のステートレジスタを“0”に設定し、ステップS116へ移行する。
In step S114, the
ステップS116では、次の命令の有無を制御部24が判定し、次の命令がある場合にはステップS100へ戻り、次の命令に対応させて各ステップを実行する。
In step S116, the
一方、ステップS116において次の命令がないと判定された場合には、入力された一連の演算命令の全てが完了したことになるので、本チェイニングを終了する。 On the other hand, if it is determined in step S116 that there is no next instruction, this means that all of the input series of arithmetic instructions have been completed, and the main chaining ends.
このように、本実施形態の演算装置10は、何れかの機能ユニット12が命令を実行している際に、命令を実行中でない機能ユニット12に対して、何れかの機能ユニット12による命令実行と並行して実行可能な命令を実行させる。これにより、本実施形態の演算装置10は、パイプラインを用いたチェイニングによる演算をより効率的に行える。
In this way, the
以上、本開示を、上記実施形態を用いて説明したが、本開示の技術的範囲は上記実施形態に記載の範囲には限定されない。開示の要旨を逸脱しない範囲で上記実施形態に多様な変更又は改良を加えることができ、該変更又は改良を加えた形態も本開示の技術的範囲に含まれる。 Although the present disclosure has been described above using the above embodiments, the technical scope of the present disclosure is not limited to the range described in the above embodiments. Various changes or improvements can be made to the embodiments described above without departing from the gist of the disclosure, and forms with such changes or improvements are also included within the technical scope of the present disclosure.
例えば、上記実施形態では、4段のパイプラインを2段のパイプラインや1段のパイプラインに再構成する形態について説明したが、本開示は、これに限定されるものではない。例えば、5段やそれ以上の段数のパイプラインをより少ない段数のパイプラインに再構成してもよい。また、パイプラインの再構成という概念を有さず、ベクトル演算器20は、例えば、2段で固定されたパイプラインで構成されてもよい。
For example, in the embodiment described above, a four-stage pipeline is reconfigured into a two-stage pipeline or a one-stage pipeline, but the present disclosure is not limited thereto. For example, a pipeline with five or more stages may be reconfigured into a pipeline with fewer stages. Further, without the concept of pipeline reconfiguration, the
Claims (5)
命令を実行中でない前記機能ユニットの有無を判定する判定部(22)と、
前記何れかの機能ユニットが命令を実行している際に、前記命令を実行中でない前記機能ユニットに対して、前記何れかの機能ユニットによる命令実行と並行して実行可能な前記命令を実行させることで、より段数の小さいパイプラインに再構成する制御部(24)と、
を備える、演算装置。 An arithmetic device (10) comprising a pipeline each comprising a plurality of functional units (12) of a plurality of types and performing arithmetic operations by chaining,
a determination unit (22) that determines the presence or absence of the functional unit that is not executing an instruction;
When any of the functional units is executing an instruction, causing the functional unit that is not executing the instruction to execute the instruction that can be executed in parallel with the execution of the instruction by any of the functional units. A control unit (24) that reconfigures the pipeline to have a smaller number of stages;
A calculation device comprising:
複数の他の前記機能ユニットによる演算結果を用いて次の前記命令を実行する前記機能ユニットは、複数の他の前記機能ユニットのマスクレジスタが前記命令の実行終了を示した後に次の前記命令を実行する、請求項1記載の演算装置。 The functional unit includes a mask register (30) that indicates the execution state of the instruction,
The functional unit that executes the next instruction using the operation results of the plurality of other functional units executes the next instruction after the mask registers of the plurality of other functional units indicate completion of execution of the instruction. The arithmetic device according to claim 1, which executes the arithmetic operation.
前記判定部は、前記識別子に基づいて、前記命令を実行中でない前記機能ユニットを判定する、
請求項1又は請求項2記載の演算装置。 The functional unit is set with an identifier that identifies whether or not the instruction is being executed;
The determination unit determines the functional unit that is not executing the instruction based on the identifier.
The arithmetic device according to claim 1 or claim 2.
前記記憶媒体に記憶された前記命令を実行可能な前記機能ユニットが有った場合に、前記記憶媒体から前記命令が順次読み出されて前記機能ユニットによって実行される、
請求項1から請求項3記載の演算装置。 the instructions awaiting execution by the functional unit are stored in a storage medium (14);
If there is a functional unit capable of executing the instructions stored in the storage medium, the instructions are sequentially read from the storage medium and executed by the functional unit;
An arithmetic device according to any one of claims 1 to 3.
命令を実行中でない前記機能ユニットの有無を判定する第1工程と、
前記何れかの機能ユニットが命令を実行している際に、前記命令を実行中でない前記機能ユニットに対して、前記何れかの機能ユニットによる命令実行と並行して実行可能な前記命令を実行させることで、より段数の小さいパイプラインに再構成する第2工程と、
を有する、演算方法。 An arithmetic method using chaining using a pipeline each comprising a plurality of functional units each having a plurality of types of functions, the method comprising:
a first step of determining the presence or absence of the functional unit that is not executing an instruction;
When any of the functional units is executing an instruction, causing the functional unit that is not executing the instruction to execute the instruction that can be executed in parallel with the execution of the instruction by any of the functional units. The second step is to reconfigure the pipeline to have a smaller number of stages.
A calculation method having.
Applications Claiming Priority (3)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2020042169 | 2020-03-11 | ||
JP2020042169 | 2020-03-11 | ||
PCT/JP2021/008131 WO2021182222A1 (en) | 2020-03-11 | 2021-03-03 | Computation device and computation method |
Publications (2)
Publication Number | Publication Date |
---|---|
JPWO2021182222A1 JPWO2021182222A1 (en) | 2021-09-16 |
JP7393519B2 true JP7393519B2 (en) | 2023-12-06 |
Family
ID=77671646
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2022505966A Active JP7393519B2 (en) | 2020-03-11 | 2021-03-03 | Arithmetic device and method |
Country Status (2)
Country | Link |
---|---|
JP (1) | JP7393519B2 (en) |
WO (1) | WO2021182222A1 (en) |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2006040254A (en) | 2004-06-21 | 2006-02-09 | Sanyo Electric Co Ltd | Reconfigurable circuit and processor |
JP2007166535A (en) | 2005-12-16 | 2007-06-28 | Matsushita Electric Ind Co Ltd | Digital filter |
JP2016103240A (en) | 2014-11-28 | 2016-06-02 | キヤノン株式会社 | Data processor and data processing method |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP3614646B2 (en) * | 1998-03-12 | 2005-01-26 | 富士通株式会社 | Microprocessor, operation processing execution method, and storage medium |
-
2021
- 2021-03-03 JP JP2022505966A patent/JP7393519B2/en active Active
- 2021-03-03 WO PCT/JP2021/008131 patent/WO2021182222A1/en active Application Filing
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2006040254A (en) | 2004-06-21 | 2006-02-09 | Sanyo Electric Co Ltd | Reconfigurable circuit and processor |
JP2007166535A (en) | 2005-12-16 | 2007-06-28 | Matsushita Electric Ind Co Ltd | Digital filter |
JP2016103240A (en) | 2014-11-28 | 2016-06-02 | キヤノン株式会社 | Data processor and data processing method |
Non-Patent Citations (1)
Title |
---|
吉見 真聡 他,FPGAを用いた確率モデル生化学シミュレータ,情報処理学会論文誌,社団法人情報処理学会,2007年02月15日, 第48巻 No.SIG3(ACS17),第45頁-第58頁,ISSN:0387-5806 |
Also Published As
Publication number | Publication date |
---|---|
WO2021182222A1 (en) | 2021-09-16 |
JPWO2021182222A1 (en) | 2021-09-16 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP3555140B2 (en) | Semiconductor floorplan and method for register rename circuit | |
KR102413832B1 (en) | vector multiply add instruction | |
JP3442225B2 (en) | Arithmetic processing unit | |
US8296746B2 (en) | Optimum code generation method and compiler device for multiprocessor | |
US9355061B2 (en) | Data processing apparatus and method for performing scan operations | |
US8417918B2 (en) | Reconfigurable processor with designated processing elements and reserved portion of register file for interrupt processing | |
JP2006338616A (en) | Compiler device | |
JPH04172533A (en) | Electronic computer | |
JP2002333978A (en) | Vliw type processor | |
JP2010532063A (en) | Method and system for extending conditional instructions to unconditional instructions and selection instructions | |
KR100663709B1 (en) | Apparatus and method of exception handling for reconfigurable architecture | |
JPWO2012105593A1 (en) | Data flow graph processing apparatus, data flow graph processing method, and data flow graph processing program | |
JP4776571B2 (en) | Execution control program, execution control method, and execution control apparatus | |
JPH11272474A (en) | Plural execution devices which can interrupt during processing of operation using allocation of plural registers | |
JP7393519B2 (en) | Arithmetic device and method | |
KR101756820B1 (en) | Reconfigurable processor and method for processing nested loop | |
US10459725B2 (en) | Execution of load instructions in a processor | |
JP2004038751A (en) | Processor and instruction control method | |
EP3690639B1 (en) | Information processing apparatus, program, and information processing method | |
JP7383390B2 (en) | Information processing unit, information processing device, information processing method and program | |
JP5786719B2 (en) | Vector processor | |
GB2523805A (en) | Data processing apparatus and method for performing vector scan operation | |
TW200302982A (en) | Context execution in a pipelined computer processor | |
JP6307975B2 (en) | Arithmetic processing device and control method of arithmetic processing device | |
JP3743155B2 (en) | Pipeline controlled computer |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20220722 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20230404 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20230519 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20230905 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20231017 |
|
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: 20231031 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20231124 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 7393519 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
S111 | Request for change of ownership or part of ownership |
Free format text: JAPANESE INTERMEDIATE CODE: R313115 |
|
R350 | Written notification of registration of transfer |
Free format text: JAPANESE INTERMEDIATE CODE: R350 |