JP3821198B2 - Signal processing device - Google Patents

Signal processing device Download PDF

Info

Publication number
JP3821198B2
JP3821198B2 JP31480699A JP31480699A JP3821198B2 JP 3821198 B2 JP3821198 B2 JP 3821198B2 JP 31480699 A JP31480699 A JP 31480699A JP 31480699 A JP31480699 A JP 31480699A JP 3821198 B2 JP3821198 B2 JP 3821198B2
Authority
JP
Japan
Prior art keywords
data
processor
memory
processor element
transfer
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP31480699A
Other languages
Japanese (ja)
Other versions
JP2001134538A (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.)
Ricoh Co Ltd
Original Assignee
Ricoh Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ricoh Co Ltd filed Critical Ricoh Co Ltd
Priority to JP31480699A priority Critical patent/JP3821198B2/en
Publication of JP2001134538A publication Critical patent/JP2001134538A/en
Application granted granted Critical
Publication of JP3821198B2 publication Critical patent/JP3821198B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

  • Advance Control (AREA)

Description

【0001】
【産業上の利用分野】
この発明は一つの演算命令により複数の画像データ等を並列処理するSIMD(Single Instruction Stream Multiple Data Stream)型プロセッサを用いた信号処理装置に関し、例えばデジタルコピーなどの画像処理に用いて好適な信号処理装置に関するものである。
【0002】
【従来の技術】
近年、デジタル複写機やファクリミリ装置等において、画素数を増加させたり、或いはカラー対応にするなど画像の向上が図られている。そして、この画像の向上に伴い、処理すべきデータ数が増加している。ところで、複写機などにおけるデータ処理は全ての画素に対して同じ演算処理を施すことが多い。そこで、1つの命令で複数のデータに対して同時に同じ演算処理を行うSIMD方式のプロセッサが用いられるようになっている。
【0003】
通常、SIMD方式のプロセッサを用いて画像処理を行う場合、主走査方向にプロセッサエレメント(PE)を展開する。このため、フィルター処理などの画像処理を行う場合、注目画素の上下の参照画素が必要になり、前のラインの画素データをラインディレイさせて、ラインメモリに格納しておくことが考えられる。
【0004】
図16に、SIMD方式を用いた画像処理装置の概略ブロック図を示す。図に示すように、この画像処理装置は、画像データが格納される外部画像メモリ(RAM)101、例えば、1024個のプロセッサエレメントからなるプロセッサエレメントブロック103、グローバルプロセッサ104を備える。
【0005】
各プロセッサエレメント(PE)は、n個の汎用レジスタ(R0〜Rn−1)と演算アレイを有し、汎用レジスタは、通常演算アレイの外部にレジスタファイルとして持つ形を取っている。それぞれのレジスタはシフトレジスタとしてシリアルポートを介して外部とアクセス可能となっている。図において、斜線部が単位プロセッサエレメントになる。
【0006】
グローバルプロセッサ104はプログラムメモリ(PRAM)105のアドレス生成手段を有し、PRAM105よりプロセッサエレメントブロック103のプロセッサエレメントに与える命令コードをリードし、演算アレイ及びレジスタファイルの制御を行っている。
【0007】
各PEの汎用レジスタのシリアルポートに接続されるデバイスはシステム構成によって異なるが、2ライン分のラインディレイのみが必要なシステムでは、例えば、R0に2ライン前の画素データ、R1に1ライン前の画素データ、R2に現ライン画素データを配置するとして、R0とR1のシリアルポートにシリアルパラレル変換器102を配置して、外部RAM101に接続するといった構成をとっている。
【0008】
上記のような構成をもち、画像処理装置を実現している例としては、例えばSVP(SERIAL VIDEO PROCESSOR)が知られている。
【0009】
従来のSIMD方式のプロセッサは、殆どが主走査方向の画素数以上のプロセッサエレメントを持っているため、外部メモリ(RAM)101に対する制御には難しい処理を必要としない。また、デジタルコピーなど画像処理において拡大、縮小などの変倍機能を実現するためには、別途ASICを外付けするか、特開平08−123683号公報(IPC:G06F 9/38)に記載されているようなSIMD方式のプロセッサ内部に変倍制御用のフラグを持つといった構成を取ることで実現できる。
【0010】
【発明が解決しようとする課題】
しかしながら、画像処理の精度は近年ますます向上しており、主走査方向の画素数は増加する傾向にある。また、従来のSIMD型プロセッサにおいて、プロセッサエレメント数の多いものは1ビットの演算アレイを使用するなど、小規模の回路を用いて回路規模の増大を防止しているのが普通である。
【0011】
デジタルコピーなどにSIMD型プロセッサを応用しようとした場合に、例えば600DPI(Dot Per Inch)の精度でA4のサイズの画像を扱う場合、7000画素以上のプロセッサエレメント数が必要となり、単純にプロセッサエレメント数を増やすのは現実的ではない。そこで、これを解決するために、主走査方向を分割して処理を行うことが考えられるが、ラインメモリとしてデュアルポートメモリ(RAM)が必要になり回路規模が増加するという難点がある。
【0012】
一方、特開平10−326258号公報(IPC:G06F 15/16)においては、主走査方向の画素を2分割して、全プロセッサエレメント数を半分に分割してパイプライン処理を行うことで処理時間の短縮を可能にしたデータ演算システムが提案されている。しかしながら、この方法では、プロセッサエレメントとアクセス可能なデータメモリのサイズを越えるような画素数の処理を行うことが出来ない。
【0013】
さらに、プロセッサエレメントに変倍制御用のフラグを持つ構成では、分割数が増加した場合に処理が複雑になるため、SIMD型プロセッサの外部で変倍処理を実現するほうが望ましい。しかし、別途ASICを用いて変倍機能を実現すると、プロセッサの汎用性を減少させてしまうことになる。
【0014】
そこで、本発明では、シングルポートメモリ(RAM)を用いることで回路規模の増加を抑えながら、同時に変倍機能も内蔵可能な簡単な構成のSIMD型プロセッサを用いた信号処理装置を提供することを目的とする。
【0015】
【課題を解決するための手段】
この発明は、データを演算処理する演算手段及び当該演算手段で演算処理されるデータを保持するとともに当該演算手段で演算処理されたデータを保持するデータ保持手段を備えるSIMD型プロセッサのプロセッサエレメントと、複数の前記プロセッサエレメントそれぞれに接続されるデータ転送バスと、前記複数のプロセッサエレメントに割り付けられるアドレスに基づき、所定のプロセッサエレメントを指定する指定手段と、この指定手段にアドレスを供給するアドレスバスと、前記複数のプロセッサエレメントが内蔵しているデータ保持手段にプロセッサ外部からアクセスするためのデータ転送用インタフェースと、このデータ転送インタフェースに接続され、前記アドレスバスに供給される前記所定のプロセッサエレメントを指定するためのアドレスを生成するとともに、外部メモリに格納されたデータを読み出して、プロセッサエレメントへデータの書き込みを行うと共に前記プロセッサエレメントからデータを読み出して、前記メモリにデータの書き込みを行うメモリコントローラと、を備え、前記メモリコントローラは、前記データ転送用インタフェースを介して、各プロセッサエレメントのデータ保持手段から前記メモリにデータ転送する場合に、転送を開始するプロセッサエレメントのアドレスと転送を終了するプロセッサエレメントのアドレスを指定し、所定数のデータを除いて、各プロセッサエレメントから演算済みのデータの読み出しを行い、転送を開始するプロセッサエレメントのアドレスに対応するポインタ値を設定し、このポインタ値に基づき前記メモリにこのデータの書き込みを行うと共に、前記メモリからデータ転送用インタフェースを介して各プロセッサエレメントのデータ保持手段にデータ転送する場合に、前段の処理において除いた所定数のデータ数に相当する分のアドレスを戻したポインタ値を設定し、このポインタ値に基づき、前記メモリからデータを読み出し、前記ポインタ値に対応して前記アドレスバスに供給される前記所定のプロセッサエレメントを指定するためのアドレスを生成して前記プロセッサエレメントへデータの書き込みを行い、データを分割してSIMD型プロセッサで演算処理を行うことを特徴とする。
【0016】
上記のように構成することで、プロセッサエレメントの数が主走査方向の画素数より少ない場合においても、容易にSIMDプロセッサでの演算が行え、フィルタ処理などの重み付け演算を行う場合に有効な画素のみを転送できる。
【0017】
前記メモリコントローラは、メモリへの書き込み転送と読み込み転送とを時分割で行うように制御するとよい。
【0018】
このように構成することで、シングルポートメモリをFIFOもしくはLIFOメモリとして用いることが可能となり、シングルポートメモリを用いながらラインメモリを実現できる。
【0019】
また、前記メモリコントローラは、データ転送用インタフェースを介して、各プロセッサエレメントのデータ保持手段から前記メモリにデータ転送する場合に、転送を開始するプロセッサエレメントのアドレスと転送を終了するプロセッサエレメントのアドレスを指定するレジスタを備えるように構成すればよい。たとえば、プロセッサエレメントのアドレスカウンタに初期値ロード機能を付加し、プロセッサエレメントのアドレスを基準としたオフセット値の設定ができるように構成すればよい。
【0020】
さらに、前記メモリコントローラは、前記メモリからデータ転送用インタフェースを介して各プロセッサエレメントのデータ保持手段にデータ転送する場合に、転送を終了するプロセッサエレメントのアドレスと、転送終了後にメモリのリードポインタを戻すためのプロセッサエレメントのアドレスを指定するレジスタを備えるように構成することができる。例えば、プロセッサエレメントのアドレスと設定値との比較器を設け、設定値と等しいプロセッサエレメントアドレスのレジスタに転送されたデータが格納されていたメモリのリードポインタをリロードするように構成すればよい。
【0021】
上記のように構成することで、主査方向の画素数よりも少ないプロセッサエレメント数のSIMD型プロセッサを用いた場合に、フィルタ処理などの重み付け演算を行う場合に有効な画素のみを転送できる。
【0022】
また、前記メモリコントローラは、メモリの任意のアドレス領域の下限値と上限値をレジスタで設定して、その領域をリング状に使用するように構成することができる。例えば、メモリのポインタの下限値、上限値レジスタを設け、それぞれ比較器を持ち、条件が揃った場合にそれぞれのレジスタの値をアドレスバスに出力できるように構成すればよい。
【0023】
上記のように構成することで、複数のステップを持つような画像処理の場合に、処理ステップごとにデータを保管することができる。
【0024】
また、前記データ転送用インタフェースは、偶数のアドレスを持つプロセッサエレメントと奇数のアドレスを持つプロセッサエレメントのデータ保持手段に同時にアクセスすることが可能になるように構成するとよい。たとえば、SIMD型プロセッサのデータ転送ポートを偶数のアドレスを持つプロセッサエレメントと奇数のアドレスを持つプロセッサエレメントのデータ保持手段にアクセスするための2つの独立したポートを持つ構成とし、1サイクルで2プロセッサエレメント分のデータを処理できるように構成すればよい。
【0025】
さらに、メモリとの入出力バスのビット幅がプロセッサエレメントとのデータ転送ビット幅よりも広くするとよい。たとえば、メモリとの入出力バッファを4プロセッサエレメント分持つことでメモリのビット幅を4プロセッサエレメント分の幅に構成すればよい。
【0026】
上記のように構成することで、全プロセッサエレメントのデータ保持手段へデータ転送する時間を半分にすることができる。また、メモリのアクセスタイムに余裕を持たせることができる。
【0027】
また、この発明は、各プロセッサエレメントのデータ保持手段からデータ転送用インタフェースを介してメモリにデータ転送する場合に、このデータ転送と同期を取った外部からのライト制御信号が”0”である場合にデータを書き込み、”1”である場合にデータの書き込みを禁止するように構成することができる。たとえば、同期信号を外部よりシーケンスユニットに入力し、ライト転送を開始するタイミングを制御することで、ライト制御信号とライト転送との同期を取ることができるようにし、またライト制御信号の値によって、プロセッサエレメントのデータ転送ポートからリードされたデータを整形してRAMにライトするためのライトバッファ部の制御を変えることによって、ライト制御信号に応じた転送を行えるように構成すればよい。
【0028】
さらに、前記メモリからデータ転送用インタフェースを介して各プロセッサエレメントのデータ保持手段にデータ転送する場合に、このデータ転送と同期を取った外部からのリード制御信号が”0”である場合には、メモリからデータリードした値をデータ転送用インタフェースに書き込み、”1”の場合には、その転送の前で最後に外部信号が”0”であった場合に転送されたデータと同じ値をデータ転送用インタフェースに書き込むように構成することができる。たとえば、同期信号を外部よりシーケンスユニットに入力し、リード転送を開始するタイミングを制御することで、リード制御信号とリード転送との同期を取ることができるようにし、またリード制御信号の値によって、RAMからリードされたデータを整形してプロセッサエレメントのデータ転送ポートにライトするためのリードバッファ部の制御を変えることによって、リード制御信号に応じた転送を行えるように構成すればよい。
【0029】
上記のように構成することで、デジタル画像処理における変倍処理をメモリコントローラで実現できるため、SIMD型プロセッサ自体の汎用性と回路規模を保つことができる。
【0030】
また、この発明は、前記メモリには画像データが格納され、前記SIMD型プロセッサのプロセッサエレメントの数は主走査方向の画素数よりも少なく構成され、前記メモリコントローラは主走査方向の全画素を2つ以上に分割して処理を行うように、データの書き込み及び読み込みの処理の制御を行うように構成することができる。
【0031】
上記のように構成することで、デジタルコピーなどの主走査方向の画素数が極めて多い画像処理装置を実現する場合に、プロセッサエレメント数を増減するなどのSIMD型プロセッサのアーキテクチャそのものを変更することなく画像処理装置を構築することができる。
【0032】
【発明の実施の形態】
以下、この発明に係るSIMD型プロセッサ1の実施の形態を図面を参照して説明する。
【0033】
まず、この発明にかかるSIMD型プロセッサの全体構成について、図1に従い説明する。この発明のSIMD型プロセッサ1は、図1に示すように、グローバルプロセッサ2、本実施形態では1024組の後述するプロセッサエレメント3aからなるプロセッサエレメントブロック3、メモリコントローラ5と接続される外部インターフェース4から構成される。メモリコントローラ5はグローバルプロセッサ2の命令に基づき、シングルポートメモリ(RAM)で構成された外部画像メモリ6から演算対象となる画像データをプロセッサ内部の入出力用のレジスタフィル31に与えるとともに、演算処理されたデータをレジスタファイル31から画像メモリ(RAM)6へ転送するものである。
【0034】
グローバルプロセッサ2は、図2に示すように、プロセッサエレメントブロック3、外部インタフェース4及びメモリコントローラ5を制御するためのプログラムが格納されたプログラムRAM21、及びこのプログラムRAM21に基づきグローバルプロセッサ2、プロセッサエレメントブロック3、外部インタフェース4、メモリコントローラ5を制御するシーケンスユニット22を備える。具体的には、このシーケンスユニット22は、グローバルプロセッサ2に備えられている後述する算術論理演算器23(以下、「ALU23」という。)等を制御する。
【0035】
また、このシーケンスユニット22は、プロセッサエレメントブロック3を構成するレジスタファイル31、及び演算アレイ36を制御する。この演算アレイ36は、マルチプレクサ32、シフト拡張回路33、算術論理演算器34(以下、「ALU34」という)、及びレジスタ35を備える。なお、このグローバルプロセッサ2は、いわゆるSISD型であり、一つの演算命令に対して一つの演算処理を行うものである。
【0036】
さらに、このシーケンスユニット22は、メモリコントローラ5に対してデータ転送のための動作設定用データ及びコマンド等を送る。メモリコントローラ5は、シーケンスユニット22の動作設定用データ及びコマンドに基づき、プロセッサエレメント3aのアドレス指定のためのアドレス制御信号、プロセッサエレメント3aを構成するレジスタ31bにデータのリード/ライトを指示するためのリード/ライト制御信号、クロック信号を与えるためのクロック制御信号を外部インタフェース4に与える。
【0037】
ここで、リード/ライト制御信号のうちライト制御信号とは、演算処理されるデータをデータバス46a(46b)より取得して、プロセッサエレメント3aのレジスタ31bに保持させるための信号をいう。一方、リード/ライト制御信号のうちリード制御信号とは、プロセッサエレメント3aのレジスタ31bが保持している演算処理されたデータを、データバス46a(46b)へ与えるようにレジスタ31bに指示するための信号をいう。
【0038】
この実施の形態におけるプロセッサエレメントブロック3は、隣り合う2つのプロセッサエレメント3aに偶数番号、奇数番号を割り付けて1組とすると共に、この1組のプロセッサエレメント3aには同一のアドレスを割り付けている。
【0039】
メモリコントローラ5は、グローバルプロセッサ2からのコマンドを受けて、プロセッサエレメントブロック3を構成するプロセッサエレメント3aのアドレスを指定する信号(以下、「アドレス指定信号」という。)を作成し、外部インターフェース4からアドレスバス41aを介してプロセッサエレメント3aのレジスタコントローラ31aヘ送る。また、メモリコントローラ5は、後述するように、プロセッサエレメント3aを構成するレジスタ31bに対して、データのリード/ライトを指示するための信号(以下、「リード/ライト指示信号」という。)を、リード/ライト信号線45a(45b)を介してプロセッサエレメント3aの後述するレジスタコントローラ31aヘリード/ライト信号が与えられる。偶数用リード/ライト信号線45aは、偶数のプロセッサエレメント3aにリード/ライト信号を与え、奇数用リード/ライト信号線45bは、奇数のプロセッサエレメント3aにリード/ライト信号を与える。
【0040】
また、メモリコントローラ5は、外部インタフェース4からクロック信号線41cを介してプロセッサエレメント3aの後述するレジスタコントローラ31aへクロック信号を与える。
【0041】
さらに、メモリコントローラ5は、上述したように、SIMD型プロセッサ1の外部に設けられた画像メモリ6に格納されているデータを、本実施形態では16ビットのパラレルデータとして、外部インタフェース4に与える。この16ビットのデータは、偶数番号が割り付けられたプロセッサエレメント3aに与えられる8ビットと、奇数番号が割り付けられたプロセッサエレメント3aに与えられる8ビットとから構成されている。それぞれ8ビットデータは偶数用データバス46a及び奇数用データバス46bに与えられる。この8ビットのパラレルデータについては、データに応じて適宜変更しても問題ない。このデータバス46a,46bは、レジスタ31bに保持されている演算処理されたデータが、SIMD型プロセッサ1の外部に設けられた画像メモリ6に送られる時にも使用される。
【0042】
なお、画像メモリ6は演算処理されるデータを格納するとともに、演算処理されたデータを格納するものであり、これらの画像メモリ6はSIMD型プロセッサ1の内部に設けても問題ない。また、メモリコントローラ5と画像メモリ6との間のデータ転送についても、本実施の形態では、後述するように、32ビットのパラレルデータとして転送されるものとして扱うが、データに応じて適宜変更しても問題ない。なお、メモリコントローラ5が行うその他の動作については後述する。
【0043】
また、グローバルプロセッサ2は、上記シーケンスユニット22からの命令により、算術論理演算を行うALU23、演算データを格納するデータRAM24を備える。さらに、グローバルプロセッサ2は、演算処理されるデータ等を保持するためのレジスタ群25を備える。
【0044】
このレジスタ群25は、プログラムのアドレスを保持するプログラムカウンタPC、演算処理のデータ格納のための汎用レジスタであるG0〜G3レジスタ、レジスタ待避、復帰時に待避先データRAMのアドレスを保持しているスタックポインタ(SP)、サブルーチンコール時にコール元のアドレスを保持するリンクレジスタ(LS)、同じくIRQ時とNMI時の分岐元アドレスを保持するLI、LNレジスタ、プロセッサの状態を保持しているプロセッサステータスレジスタ(P)を内蔵している。
【0045】
また、レジスタ群25は、プロセッサエレメントブロック3の後述するレジスタ35に接続されており、このレジスタ35との間でシーケンスユニット22の制御によりデータの交換が行われる。
【0046】
プロセッサエレメントブロック3は、図1及び図2に示すように、レジスタファイル31、マルチプレクサ32、シフト・拡張回路33、算術論理演算器34(以下、「ALU34」という。)、レジスタ35、を一単位とする複数のプロセッサエレメント3aを備える。レジスタファイル31には、1つのプロセッサエレメント3a単位に8ビットのレジスタが32本内蔵されており、本実施形態では1024のプロセッサエレメント分の組がアレイ構成になっている。レジスタファイル31は1つのプロセッサエレメント(PE)3aごとにR0、R1、R2、...R31と呼ばれているレジスタが内蔵されている。それぞれのレジスタファイル31は演算アレイ36に対して1つの読み出しポートと1つの書き込みポートを備えており、8ビットのリード/ライト兼用のバスで演算アレイ36からアクセスされる。32本のレジスタの内、24本はプロセッサ外部からアクセス可能であり、外部からクロックとアドレス、リード/ライト制御を入力することで任意のレジスタを読み書きできる。
【0047】
レジスタの外部からのアクセスは1つの外部ポートで各プロセッサエレメント3aの1つのレジスタがアクセス可能であり、外部から入力されたアドレスでプロセッサエレメントの番号(0〜1023)を指定する。したがって、レジスタアクセスの外部ポートは全部で24組搭載されている。また、外部からのアクセスされるデータは上述したように、偶数のプロセッサエレメント3aと奇数のプロセッサエレメント3aの1組で16ビットデータとなっており、1回のアクセスで2つのレジスタを同時にアクセスしている。
【0048】
本実施形態では、プロセッサエレメント3aの数を1024個として説明するが、これに限定されるものでなく適宜変更して使用してもよい。このプロセッサエレメント3aには、グローバルプロセッサ2のシーケンスユニット22により、外部インタフェース4に近い順に0から1023までのアドレスが割り付けられる。
【0049】
プロセッサエレメント3aのレジスタファイル31は、レジスタコントローラ31a、2種類のレジスタ31b、31cを備える。本実施形態では、図3に示すように、一単位のプロセッサエレメント3a毎に、レジスタコントローラ31aとレジスタ31bとを24組備え、さらにレジスタ31cを8個備えている。なお、図3では2組のプロセッサエレメント3aにおけるレジスタファイル31の一部を表しており、図3中の1プロセッサエレメントとは1つのプロセッサエレメント3aを表している。ここで、本実施形態では、レジスタ31b、31cを8ビットのものとして扱うが、これに限定されるものでなく適宜変更して使用してもよい。
【0050】
レジスタコントローラ31aは、図3に示すように、外部インタフェース4と、上述したアドレスバス41a、偶数用リード/ライト信号線45a、奇数用リード/ライト信号線45b、クロック信号線41cを介して接続されている。
【0051】
外部インタフェース4は、メモリコントローラ5からアドレス制御信号を受けると、アドレス指定信号をアドレスバス41aを介してプロセッサエレメントブロック3ヘ送る。これにより、一組のプロセッサエレメント3a、即ち2つのプロセッサエレメント3aが同時にアドレス指定される。レジスタコントローラ31aは、送られてきたアドレス指定信号をデコードし、デコードしたアドレスと、自己に割り付けられたアドレスとが一致する場合には、メモリコントローラ5からクロック信号41cを介して送られてきたクロック信号に同期して、リード/ライト信号45a或いは45bを介してメモリコントローラ5から送られてきたリード/ライト指示信号を得る。具体的には、偶数番号が割り付けられているレジスタコントローラ31aは、偶数用リード/ライト信号45aを介してメモリコントローラ5から送られてきたリード/ライト指示信号を得る。一方、奇数番号が割り付けられているレジスタコントローラ31aは、奇数用リード/ライト信号45bを介してメモリコントローラ5から送られてきたリード/ライト指示信号を得る。このとき一組を構成するプロセッサエレメント3aのレジスタコントローラ31aへ送られるリード/ライト指示信号はそれぞれ異なるものであってもよい。即ち、偶数番号が割り付けられているレジスタコントローラ31aへ送られる指示信号がリード指示であるとき、奇数番号が割り付けられているレジスタコントローラ31aへ送られる指示信号はライト指示であってもよい。そして、このリード/ライト指示信号はレジスタ31bに与えられる。
【0052】
レジスタコントローラ31aから双方のプロセッサエレメント3aに対し、ライト指示信号が送られてきた場合には、偶数番号が割り付けられたプロセッサエレメント3aのレジスタ31bは、演算処理されるデータ(8ビット)を偶数用データバス46aより取得して保持する。また、奇数番号が割り付けられたプロセッサエレメント3aのレジスタ31bは、演算処理されるデータ(8ビット)を奇数用データバス46bより取得して保持する。一方、レジスタコントローラ31aから双方のプロセッサエレメント3aに対し、リード指示信号が送られてきた場合には、偶数番号が割り付けられたプロセッサエレメント3aのレジスタ31bは、演算処理されたデータ(8ビット)を偶数用データバス46aへ送る。また、奇数番号が割り付けられたプロセッサエレメント3aのレジスタ31bは、演算処理されたデータ(8ビット)を奇数用データバス46bへ送る。
【0053】
このように、一度のアドレス指定により、偶数番号が割り付けられたプロセッサエレメント3aにデータ転送できるとともに、奇数番号が割り付けられたプロセッサエレメント3aにもデータ転送できる。このため、データの転送回数を少なくすることができ、データ転送を高速にできる。
【0054】
レジスタ31bは、後述するALU34でこれから演算される外部から入力されたデータを保持したり、或いはALU34で演算処理されたデータを外部へ出力するために保持するものであり、いわゆる入力レジスタとしても、或いは出力レジスタとしても機能する。また、演算処理されるデータ、或いは演算されたデータを一時的に保持するといった、後述するレジスタ31cとしての機能も有する。なお、本実施形態では、レジスタ31bは8ビットのデータを保持できるものとして扱うが、データに応じて適宜変更しても問題ない。上述したレジスタコントローラ31aからライト指示信号が与えられると、レジスタ31bは演算処理されるデータをデータバス46aまたはデータバス46bより取得して保持する。一方、レジスタコントローラ31aからリード指示信号が送られてくると、レジスタ31bは保持している演算処理されたデータをデータバス46aまたはデータバス46bへ与える。このデータは外部インタフェース4からメモリコントローラ5のライトバッファ部54に与えられ、ライトバッファ部54から画像メモリ6へ格納される。
【0055】
また、レジスタ31bは、本実施形態においては8ビットデータをパラレルで転送するデータバス37を介してマルチプレクサ32に接続されている。ALU34で演算処理されるデータ、或いはALU34で演算処理されたデータは、このデータバス37を介して、レジスタ31bとの間で転送される。この転送は、グローバルプロセッサ2のシーケンスユニット22からの指示によって、グローバルプロセッサ2に接続されたリード信号線26a、ライト信号線26bを介して行われる。具体的には、グローバルプロセッサ2のシーケンスユニット22から、リード信号線26aを介してリード指示信号が送られてくると、レジスタ31bは保持している演算処理されるデータをデータバスへ置く。このデータはALU34へ送られ演算処理される。一方、グローバルプロセッサ2のシーケンスユニット22から、ライト信号線26bを介してライト指示信号が送られてくると、レジスタ31bはデータバス37を介して送られてきたALU34で演算処理されたデータを保持する。
【0056】
レジスタ31cは、レジスタ31bより与えられた演算処理されるデータ、或いは演算されたデータがレジスタ31bに与えられる前に、そのデータを一時的に保持するものである。このレジスタ31cは、上述したレジスタ31bと異なり、メモリコントローラ5を介して、画像メモリ6との間においてデータ転送はしない。
【0057】
演算アレイ36は、マルチプレクサ32、シフト/拡張回路33、16ビットALU34及び16ビットのレジスタ35を備えている。このレジスタ35には、16ビットAレジスタ、Fレジスタを内蔵している。
【0058】
プロセッサエレメント3aの命令による演算は、基本的にレジスタファイル31から読み出されたデータをALU34の片側の入力としてもう片側にはレジスタ35のAレジスタの内容を入力として結果をAレジスタに格納する。したがって、Aレジスタとレジスタファイル31のR0〜R31レジスタとの演算が行われることとなる。レジスタファイル31と演算アレイ36との接続に(7to1)のマルチプレクサ32を置いており、プロセッサエレメント方向で左に1、2、3つ離れたデータと右に1、2、3つ離れたデータ、中央のデータを演算対象として選択している。また、レジスタファイル31の8ビットのデータはシフト/拡張回路33により任意ビットの左シフトしてALU34に入力される。さらに、図示していない8ビットの条件レジスタ(T)により、プロセッサエレメント3aごとに演算実行の無効/有効の制御をしており、特定のプロセッサエレメント3aだけを演算対象として選択できるように構成している。
【0059】
上記したように、マルチプレクサ32は、自己のプロセッサエレメント3aに備えられた上記データバス37に接続されるとともに、両隣3つのプロセッサエレメント3aに備えられたデータバス37にも接続されている。このマルチプレクサ32は7つのプロセッサエレメント3aから1つを選択し、その選択したプロセッサエレメント3aにおけるレジスタ31b、31cで保持されているデータをALU34へ送る。或いはALU34で演算処理されたデータを、選択したプロセッサエレメント3aにおけるレジスタ31b、31cへ送る。これによって、隣のプロセッサエレメント3aにおけるレジスタ31b、31cで保持されているデータを利用した演算処理が可能になり、SIMD型プロセッサ1の演算処理能力を高めることができる。
【0060】
シフト/拡張回路33は、マルチプレクサ32から送られてきたデータを所定ビットシフトしてALU34へ送る。或いはALU34から送られてきた演算処理されたデータを所定ビットシフトしてマルチプレクサ32へ送る。
【0061】
ALU34は、シフト/拡張回路33から送られてきたデータと、レジスタ35に保持されているデータとに基づき算術論理演算を行う。なお、本実施形態では、ALU34は16ビットのデータに対応できるものとして扱うが、データに応じて適宜変更しても問題ない。演算処理されたデータは、レジスタ35に保持され、シフト/拡張回路33へ転送されたり、或いはグローバルプロセッサ2の汎用レジスタ25へ転送される。
【0062】
グローバルプロセッサ2からメモリコントローラ5へはI/O用のアドレス、データ、コントロール信号がバスを介して与えられる。グローバルプロセッサ2がメモリコントローラ5のいくつかの動作設定レジスタ(図示せず)へ動作方法等のコマンドを設定している。最後にグローバルプロセッサ2は、メモリコントローラ5のスタートレジスタ(図示せず)にスタートコードを書き込むことで、メモリコントローラ5は自動的に設定に従った動作を行う。このように構成することで、プロセッサの命令制御による演算と同時にレジスタファイル31のデータを入出力させることができる。
【0063】
図4は、この発明に用いられるメモリコントローラ5の構成を示したものである。メモリコントローラ5は、画像メモリ6にデータライトを行うライトバッファ部54と、画像メモリ6からデータリードを行うリードバッファ部55と、プロセッサエレメントのレジスタファイル31への制御を行っているPE制御部52、画像メモリ6への制御を行うRAM制御部53、及びシーケンスユニット(SCU)51より構成されている。
【0064】
メモリコントローラ5は、SIMD型プロセッサ1のレジスタファイル31と外部インタフェース4内のデータ転送ポートを介して接続されていて、レジスタファイル31から画像メモリ6へのデータ転送、画像メモリ6からレジスタファイル31へのデータ転送を行っている。このデータ転送ポートは、出力ポートと入力ポートを備える。また、この実施の形態におけるメモリコントローラ5が制御するレジスタは、上述したように、I/O空間にマッピングされており、グローバルプロセッサ2からの指示に従い、アドレス、クロック、及びリード・ライト制御を出力することでリード、ライト可能となっている。
【0065】
ライトバッファ部54にはSIMD方式プロセッサ1の外部インタフェース4の出力ポートが接続され、リードバッファ部55には外部インタフェース4の入力ポートが接続される。データ転送ポートはそれぞれ偶数プロセッサエレメント用と奇数プロセッサエレメント用の入力、出力ポートを独立して有しており、1サイクルで一度に偶数、奇数の1組のプロセッサエレメント分のデータがアクセス可能に構成されている。また、ライトバッファ部54、リードバッファ部55と画像メモリ6間のデータバスは、それぞれ4プロセッサエレメント分のデータ幅で構成されており、1サイクルで一度に4プロセッサエレメント分のデータをアクセスできる。尚、この実施の形態においては、1プロセッサエレメント分のデータは8ビットとしている。また、外部インタフェース4とライトバッファ54部及びリードバッファ部55とのデータバスのビット幅は16ビットで構成される。従って、メモリコントローラ5と画像メモリ6間のビット幅は32ビットで構成される。
【0066】
この結果、外部インターフェース4の外部インタフェース4のデータ転送ポートとメモリコントローラ5間の転送を2回行う間に、画像メモリ6とメモリコントローラ5間の転送を1回実行すればよいことになる。
【0067】
メモリコントローラ5のライトバッファ部54はSIMD型プロセッサ1の外部インタフェース4より出力された画素データを2回取り込み、4個のプロセッサエレメント分のデータに整形した後、画像メモリ6に転送する動作を行っている。また、リードバッファ部55は、画像メモリ6から読み出した4個のプロセッサエレメント分のデータを2回に分けて、SIMD型プロセッサ1の外部インタフェース4に転送する動作を行っている。
【0068】
図5にプロセッサエレメント(PE)制御部52の実施形態の概略ブロック図を示す。
【0069】
図5に示すように、PE制御部52はSIMDプロセッサ1の外部インタフェース4にプロセッサエレメント3aのアドレス、クロック、リード/ライト制御信号を出力するものであり、SIMDプロセッサ1における各プロセッサエレメント3aのレジスタファイル31のデータを読み書きすることを可能にしている。
【0070】
このPE制御部52は、プロセッサエレメント(PE)アドレスカウンタ521、転送数カウンタ522、523、有効データ数カウンタ524とからなる。PEアドレスカウンタ521はライト転送(プロセッサエレメント34aのレジスタファイル31から画像メモリ6への転送)の場合は、転送開始時に”0”が初期ロードされ、リード転送(画像メモリ6からプロセッサエレメント34aのレジスタファイル31への転送)の場合は、転送開始時に転送開始PEアドレスレジスタ525に格納されている値が初期ロードされるアップカウンタであり、データ転送するプロセッサエレメントのアドレスを生成する。転送数カウンタ522,523は転送するデータ数を初期ロードできるダウンカウンタであり、転送数を管理するのに使用される。転送カウンタ522はライトするデータ数がセットされ、転送カウンタ523にはリードするデータ数がそれぞれ初期ロードされる。
【0071】
有効データ数カウンタ524は、画像メモリ6に格納済みの有効なデータ数を管理するカウンタであり、画像メモリ6からプロセッサエレメント3aのレジスタファイル31にデータ転送する時に、転送数よりも有効データ数の方が多い時にのみ転送が実施されるようになっている。このように構成することで、データの欠落を防止している。
【0072】
図6にメモリ(RAM)制御部53の第1の実施形態の概略ブロック図を示す。
【0073】
図6に示すように、RAM制御部53は、ライトバッファ部54、リードバッファ部55からの制御線によって制御され、シングルポートメモリで構成される画像メモリ(RAM)6へのクロック、アドレス、リード/ライト制御、バイトセレクトを出力する。
【0074】
RAM制御部53は、RAMアドレス加減器531、ライトポインタレジスタ532、リードポインタレジスタ533、マルチプレクサ534とからなる。各ブロックはアドレス設定用バス(以降、ABと略す)を介して接続されている。
【0075】
ライトポインタレジスタ532は次に画像メモリ6にライトすべきポインタを格納しているレジスタであり、リードポインタレジスタ533は同様に次に画像メモリ6からリードすべきポインタを格納しているレジスタである。
【0076】
ライトポインタレジスタ532、リードポインタレジスタ533は、そのポインタへの画像メモリ6のアクセスの後、RAMアドレス加減器531で更新されたポインタがAB535から入力され格納される。RAMアドレス加減器531は、ライトアクセス時にはライトポインタ、リードアクセス時にはリードポインタの値にRAMアクセスサイズに応じた数を、FIFO動作モード時は加算、LIFO動作モード時は減算した値をAB535に出力する。
【0077】
シーケンスユニット51は、アドレスデコーダ、制御レジスタとからなり、グローバルプロセッサ2からI/O空間にマッピングされた制御レジスタをアクセスすることで、メモリコントローラ5全体の制御を行ったり、グローバルプロセッサ2からメモリコントローラ5の内部状態を監視することが可能になっている。また、ライト転送とリード転送の時分割もこのシーケンスユニット51のブロックで行われる。また、ライトバッファ部54へのクロックとリードバッファ部55へのクロックとの2系統のクロックを生成することによってライト転送とリード転送を同時に行うことを可能にしている。
【0078】
次に、主走査方向の画素数よりもプロセッサエレメント3aの数が少ないSIMD型プロセッサを用いた場合の画素データの転送方法について説明する。図7は主走査方向の画素数よりもプロセッサエレメント3aの数が少ないSIMD方式のプロセッサを用いた場合の画素データの転送方法についての説明図を示している。
【0079】
主走査方向の画素数よりプロセッサエレメント3aが少ない場合には、主走査方向の画素データを分割して、メモリコントローラ5は、SIMDプロセッサ1のプロセッサエレメント3aのレジスタファイル31に画素データを画像メモリ6より与え、この処理を繰り返し実行している。すなわち、主走査方向の画素数よりもプロセッサエレメント数が少ない場合には、主走査方向の画素データを分割してSIMDプロセッサ1で演算処理を繰り返し実行している。
【0080】
通常、SIMD型プロセッサを用いた画像処理ではフィルター処理などのように、注目画素前後の画素のデータを参照した処理を含む処理を実施するとSIMDの両端のデータに無効なデータが残る。このため、プロセッサエレメント3aのレジスタファイルから画像メモリ6にデータを格納する際には、両端のデータを除いて格納する必要がある。また、画像メモリ6からプロセッサエレメント3aのレジスタファイル31にデータを転送する際には、注目画素前後の参照用の画素データも併せて転送する必要がある。つまり、フィルター処理などの重み付け処理における画素データの転送は以下の順序で行われることになる。ここでは、参照用画素の個数をa個とする。
【0081】
1.処理前画素データを画像メモリ6からSIMDプロセッサ1のプロセッサエレメント3aの対応するレジスタファイル31へ転送する。
【0082】
2.SIMDプロセッサ1による画像処理を行う。このとき、SIMDプロセッサエレメント3aの前後a個のデータは参照画素不在により無効にする。すなわち、図7における斜線部を施した部分が有効画素数になる。
【0083】
3.処理後画素データをSIMDプロセッサ1から画像メモリ6に転送する。このとき、両端の前後a個分の画素を除いた有効画素が画像メモリ6に転送される。
【0084】
図7を参照して、画像メモリ6とSIMDプロセッサ1間の画素データの転送につき説明する。SIMDプロセッサ1のプロセッサエレメント(PE)3aは、n個、すなわち、PE0からPEn−1を備え、これらプロセッサエレメント3a…に画像メモリ6から画素データを送り、画像処理を行った後、これらプロセッサエレメント3a…から画像メモリ6に画素データが転送される。
【0085】
まず、最初の転送、すなわち、図中1SIMD目の転送では、SIMDプロセッサ1のプロセッサエレメント3a…前後に参照画素a個を併せて転送している。図7に示す例では、RAM制御部53は、まず、リードポインタ533に0を格納し、RAMアクセスサイズに応じた数、この実施の形態においては、32ビット分のデータを画像メモリ6より読み出し、リードバッファ部55へ格納する。そして、アドレス加減器531は、リードポインタの値にRAMアクセスサイズに応じた数を、FIFO動作モード時は加算、LIFO動作モード時は減算した値をAB535に出力し、その値がリードポインタ533に格納される。そして、PE制御部52のPEアドレスカウンタ521により、アドレスが生成され、そのアドレスに基づき、外部インターフェース4から該当するプロセッサエレメント3a…にデータが書き込みされる。転送数カウンタ522は画像データの書き込みの度にRAMサイズに応じた数、この実施の形態では4ずつデクリメントしてゆく。上記の処理はこの転送カウンタ522の値が0になるまで繰り返し実行され、SIMDプロセッサ1のPE0からPEn−1に画像メモリ6からの画素データが転送される。
【0086】
処理後の画素データを画像メモリ6に転送する場合、前後それぞれa個の画素データは無効なので、転送する画素データはPE0からPEn−1までのn画素の内、a〜(n−a−1)までの(n−2×a)画素である。このため、PE制御部52のPEアドレスカウンタ521には、転送開始時に転送開始PEアドレスレジスタ525の値がロードされ、そのアドレスに基づき、該当するプロセッサエレメント3a…からデータが読み出され、外部インタフェース4からライトバッファ部54に画像データが書き込みまれる。転送数カウンタ523には読み出される度にRAMアクセスサイズに応じた数、この実施の形態では4ずつデクリメントされる。ライトバッファ部54に32ビット分のデータが格納されると、画像メモリ6に画像データが転送される。RAM制御部53は、まず、ライトポインタ532にaを格納し、ライトバッファ部54に格納された画像データ、この実施の形態においては、32ビット分のデータを画像メモリ6に転送する。アドレス加減器531は、リードポインタの値にRAMアクセスサイズに応じた数を、FIFO動作モード時は加算、LIFO動作モード時は減算した値をAB535に出力し、その値がライトポインタ532に格納される。このようにして、SIMDプロセッサ1のPEaからPEn−2×aまでの画像データが画像メモリ6に転送される。
【0087】
続いて、2番目の転送が同様にして行われる。図中2SIMD目の転送では、(n−a)〜(2n−3×a)までの画素を注目画素として処理を行うため、参照画素として(n−2×a)〜(n−a−1)及び、(2n−3×a)〜(2n−2×a−1)の画素データを併せて送っている。データ処理後、(n−a)〜(n−2×a)の(n−3×a)画素が画像メモリ6に格納される。主走査方向のSIMD分割数が多い場合も同様の処理を繰り返すだけである。
【0088】
以上の処理を実現するには、画像メモリ6へのデータライトの場合には、本発明のプロセッサエレメント(PE)制御部52の実施形態において、転送開始PEアドレスレジスタ525に”a”を設定し、転送数カウンタ522に”(n−2×a)を設定すればよい。
【0089】
設定数は全てPEアドレスを基準としているため、SIMDごとに設定を変更する必要がない。また、画像メモリ6からのデータリードの場合には、リードポインタ533を転送終了後に戻すという操作が必要である。上記の例では(n−2×a)に戻すことになる。RAM制御部53の打愛1の実施形態においては、転送が終了した後に、リードポインタ533の値をグローバルプロセッサ2から設定する必要がある。
【0090】
また、画像メモリ6へのデータライトの場合には、ライトポインタ532の操作を行う必要はない。
【0091】
図8は本発明におけるRAM制御部53の第2の実施形態を示す概略ブロック図である。
【0092】
図8に示すRAM制御部53は、図6に示したRAM制御部53に、さらにリードオフセット生成器536を設けたものである。このRAM制御部53は、リードオフセット生成器536によりメモリ6からSIMDプロセッサ1のプロセッサエレメント3aの各レジスタファイルへのデータ転送の際に、プロセッサエレメント3aへの転送終了後にリードポインタ533の値を戻すことができるように変更している。
【0093】
リードオフセット生成器536は、PE制御部52より入力されたPEアドレスを監視し、PEアドレスが設定された値と等しくなると、その時のリードポインタ533の値を保持し、設定された転送数を送り終えるまで転送を継続する。転送が終了すると、保持しておいた値をリードポインタ533にリロードする。上記図7で示す例では(n−2×a−1)を設定することになる。設定値は全てPEアドレスを基準としているため、RAM制御部53の第1の実施形態のようにSIMDごとに設定を変更する必要がない。
【0094】
図9は本発明におけるRAM制御部53の第3の実施の形態を示す概略ブロック図である。
【0095】
図9に示すRAM制御部53は、上記処理に加えて、画像メモリ6の特定の領域のみをリング状に使用することを可能にしたものである。
【0096】
このRAM制御部53は、図8に示したRAM制御部にさらに、2つのレジスタ537、538及び比較器539を設けたものである。レジスタ(LADDR)537は画像メモリ6のアドレスの下限値を設定し、レジスタ(UADDR)538は画像メモリ6のアドレスの上限値を設定する。そして、比較器539はそれぞれ現在のポインタ532(533)とLADDR537、UADDR538に設定された値との比較を行う。
【0097】
FIFOモード時に、UADDR538とポインタ532(533)が一致していて、かつアドレス加減器531より出力される値がUADDR538を越える場合に、アドレス加減器531よりAB535への出力をネゲートし、LADDR537よりAB535への出力をアサートする。
【0098】
LIFOモード時は逆に、LADDR537とポインタ532(533)が一致し、かつアドレス加減器531より出力される値がLADDR537を下回る場合に、アドレス加減器531よりスAB535への出力をネゲートし、UADDR538よりAB535への出力をアサートする。上記のように構成することで、画像メモリ6のメモリ空間の特定空間だけを用いることができるようになる。
【0099】
図10にこの発明の実施の形態にかかるライトバッファ部54及びリードバッファ部55の概略ブロック図を示す。
【0100】
この実施の形態におけるライトバッファ部54及びリードバッファ部55は、偶数プロセッサエレメント3a、奇数プロセッサエレメント3aの専用のポートを持っていて、それぞれ1サイクルで2プロセッサエレメント分のデータをアクセス可能に構成され、全プロセッサエレメント数の半分のサイクル数でデータ転送することが可能となっている。
【0101】
ライトバッファ部54は4プロセッサエレメント分のデータがバッファに格納されると、画像メモリ6にライトアクセスを行うように構成されている。
【0102】
外部インタフェース4の転送ポートからライトバッファ部54に与えられる2プロセッサエレメント分のデータは、まずフリップフロップ541,542に格納された後、次段のフリップフロップ543,544に転送される。続いて、与えられる2プロセッサエレメント分はフリップフロップ541,542に格納される。そして、フリップフロップ541〜544に格納された4プロセッサエレメント分のデータがそれぞれラッチ545〜548に格納される。ライトバッファ部54は、4プロセッサエレメント分のデータをラッチ545〜548に格納されると、画像メモリ6にライトアクセスを行う。
【0103】
リードバッファ部55は、画像メモリ6から4プロセッサエレメント分読み出されたデータをバッファとしてのフリップフロップ551〜554に格納する。4プロセッサエレメント分のデータから2プロセッサエレメント分がマルチプレクサ555により選択され、ラッチ556,557に格納される。このラッチ556,557に格納された画像データが外部インタフェース4を介してSIMDプロセッサ1のレジスタファイル31に転送される。
【0104】
4プロセッサエレメント分のデータの転送が終わると再び画像メモリ6にリードアクセスを行う。画像メモリ6は一度に4プロセッサエレメント分のデータをアクセスできるので、2サイクルで一度のアクセスを実現できればSIMDプロセッサ1とのインタフェースが取れることとなり、画像メモリ6のアクセスタイムの制限を緩和できる。
【0105】
図11はデジタルコピーやファクシミリなどでよく行われる変倍処理の内、縮小を実現するための間引きライト動作について図示したものである。
【0106】
図11ではプロセッサエレメント(0)、プロセッサエレメント(2)などの画素データはそのまま画像メモリ6に格納され、プロセッサエレメント(1)、プロセッサエレメント(3)などの画素データが画像メモリ6に格納されずに間引かれている。
【0107】
メモリコントローラ5は偶数側のプロセッサエレメント3aと奇数側のプロセッサエレメント3aのそれぞれのデータを間引くかどうかを決定する外部ライト制御信号を2本有している。また、メモリコントローラ5とライト制御信号との同期を取るために転送を開始するタイミングをメモリコントローラ5に通知する外部端子を有している。転送を開始する外部同期信号はシーケンスユニットに入力されており、同期信号がアサートされるとシーケンスユニット51は転送を開始させる。
【0108】
シーケンスユニット51は、上記ライト制御信号の値を検出して、外部からのライト制御信号が”0”である場合には、そのデータをライトバッファ部54内のバッファに書き込む。また、シーケンスユニット51は、上記ライト制御信号の値を検出して、”1”が立っている場合は、そのデータをライトバッファ部54内のバッファに格納することを抑止する。
【0109】
ライトバッファ部54は転送開始時及び転送終了時の例外を除き、4プロセッサエレメント分のデータが格納されるまで、画像メモリ6への転送要求をRAM制御部53に対して出力しないため、アドレスポインタの更新と画像メモリ6へのクロック、リード・ライト制御、バイトセレクトの出力は4プロセッサエレメント分のデータがライトバッファ部54に格納されるまで行われない。SIMDプロセッサ1のデータ転送ポートからのデータリードはライト制御信号によらず継続する。
【0110】
図12は上記変倍処理の内、拡大を実現するための重複リード動作について図示したものである。図12ではプロセッサエレメント(0)、プロセッサエレメント(2)などのレジスタにはリードポインタの位置から順番に画像メモリ6のデータが書き込まれ、プロセッサエレメント(1)、プロセッサエレメント(3)などのレジスタには1つ前のプロセッサエレメントのレジスタに書き込まれた値が重複して書き込まれている。
【0111】
メモリコントローラ5は偶数側のプロセッサエレメント3aと奇数側のプロセッサエレメント3aのそれぞれのデータを書き込む際に前と同じデータを重複して書き込むかどうかを決定する外部リード制御信号を2本有している。
【0112】
メモリコントローラ5と重複制御信号との同期を取るために転送を開始するタイミングをメモリコントローラ5に通知する外部端子を有している。転送を開始する外部同期信号はシーケンスユニット51に入力されており、同期信号がアサートされるとシーケンスユニット51は転送を開始させる。
【0113】
シーケンスユニット51は、上記リード制御信号の値を検出して、”1”が立っている場合は、リードバッファ部55のマルチプレクサを制御して、1つ前にPEアドレスを持つプロセッサエレメントのレジスタに転送すべきデータを再度出力できるようにしている。リードバッファ部55は転送開始時と転送終了時の例外を除き、画像メモリ6からリードされた4プロセッサエレメント分のデータが全て不必要になるまで、RAM制御部53に対して画像メモリ6へのリードデータ転送要求を出力しないため、(たとえばリード制御が常に”0”であれば2回のデータ転送ポートへのアクセスがあるまでであり、リード制御信号に1がたっている間はデータが不必要になることはない。)アドレスポインタの更新と画像メモリ6へのクロック、リード・ライト制御、バイトセレクトの出力は4プロセッサエレメント分のデータが全て不必要になるまで行われない。SIMDプロセッサ1の外部インタフェース4へのデータライトはリード制御信号によらず継続する。
【0114】
上記した実施の形態においては、一度のアドレス指定により、SIMDプロセッサ1の偶数番号が割り付けられたプロセッサエレメント3aにデータ転送できるとともに、奇数番号が割り付けられたプロセッサエレメント3aにもデータ転送できるように構成しているが、SIMDプロセッサ1への画像データの転送はこの方式に限られるものではない。たとえば、図13に示すように、SIMDプロセッサ1のプロセッサエレメント3aに、奇数、偶数の区別を付けずに、アドレス指定により順次データを転送するように構成したものにおいても、この発明は適用できる。すなわち、図11に示すように、レジスタコントローラ31aは、外部インタフェース4と、アドレスバス41a、リード/ライト信号45c、クロック信号41cを介して接続されている。このレジスタコントローラ31aは、メモリコントローラ5から外部インタフェース4に与えられ、アドレスバス41aを介してアドレス指定信号が送られてくると、そのアドレス指定信号をデコードする。そして、デコードしたアドレスと、自己のプロセッサエレメント3aに割り付けられたアドレスとが一致する場合には、メモリコントローラ5から外部インタフェース4に与えられ、クロック信号41cからのクロック信号に同期して、リード/ライト信号41bを介してメモリコントローラ5から送られてきたリード/ライト指示信号を得る。このリード/ライト指示信号は、レジスタ31bへ与えられる。
【0115】
SIMD型プロセッサ1の外部に設けられた画像メモリ6に格納されているデータを、この実施形態では8ビットのパラレルデータとして、データバス46cに置く。このデータバス46cは、レジスタ31bに保持されている演算処理されたデータが、SIMD型プロセッサ1の外部に設けられた画像メモリ6に送られる時にも使用される。
【0116】
外部インタフェース4から与えられるアドレス、リード/ライト、クロック、データの信号はレジスタファイル31の各レジスタに供給される。そして、各プロセッサエレメント3a…ごとにアドレスをデコードして各プロセッサエレメント3a…を示すアドレスと一致したプロセッサエレメント3aだけがリード/ライトの動作をおこなう。
【0117】
このように構成されるSIMD型プロセッサ1は、メモリコントローラ5が、画像メモリ6に格納されているデータをプロセッサエレメント3aに送る場合、プロセッサエレメント3aに割り付けられたアドレスを指定することにより、1回のクロック信号が入力されるだけで、その指定したプロセッサエレメント3aにデータが送られる。なお、この例では、偶数、奇数のプロセッサエレメント3aに同時にデータは送られないので、第1の実施の形態に比べると、データ転送に時間はかかるが、回路構成は簡略化できる。
【0118】
上述した実施形態においては、プロセッサエレメント3aをアドレス指定しているが、プロセッサエレメント3aの指定をアドレス指定する方式ではなく、ポインタ指定する方式、即ちシリアルアクセスメモリ方式においても、この発明は適用できる。この例につき図14に従い説明する。なお、ここでは上述した第1の実施形態と異なる点について説明することとし、同じ点については説明を省略する。また、上述した第1実施形態と同じ構成部分については、同一の符号を付する。
【0119】
まず、グローバルプロセッサ2からメモリコントローラ5へはI/O用のアドレス、データ、コントロール信号がバスを介して与えられる。グローバルプロセッサ2がメモリコントローラ5のいくつかの動作設定レジスタ(図示せず)へ動作方法等のコマンドを設定している。最後にグローバルプロセッサ2は、メモリコントローラ5のスタートレジスタ(図示せず)にスタートコードを書き込むことで、メモリコントローラ5は自動的に設定に従った動作を行う。メモリコントローラ5は、グローバルプロセッサ2のコマンドに基づき、このリセット信号を生成し、外部インタフェース4からリセット信号47を介してプロセッサエレメントブロック3ヘ送る。これにより、レジスタコントローラ31aは、リセットされる。そして、外部インタフェース4に最も近いレジスタコントローラ31aへメモリコントローラ5から外部インタフェース4、クロック信号41cを介してクロック信号が送られる。このクロック信号に同期して、レジスタコントローラ31a’は、リード/ライト信号45a或いは45bを介してメモリコントローラ5から送られてきたリード/ライト指示信号を得る。このリード/ライト指示信号は、偶数番号が割り付けられたプロセッサエレメント3aのレジスタ31b、及び奇数番号が割り付けられたプロセッサエレメント3aのレジスタ31bにそれぞれ与えられる。このとき一組を構成するプロセッサエレメント3aのレジスタコントローラ31a’へ送られるリード/ライト指示信号は、上記第1実施形態の場合と同様それぞれ異なるものであってもよい。
【0120】
これにより、上述した第1実施形態の場合と同様、一度のポインタ指定により、偶数番号が割り付けられたプロセッサエレメント3aにデータ転送できるとともに、奇数番号が割り付けられたプロセッサエレメント3aにもデータ転送できる。
【0121】
図15に示すものは、上記したこの発明のメモリコントローラ5を含んだ画像処理装置の他の実施形態の構成を示すブロック図である。この図15に示すものは、独立した2つのレジスタファイル3のデータ転送ポートの間にメモリコントローラ5を配置したものである。このような構成のものにおいても、本発明は適用することができる。
【0122】
【発明の効果】
上述したように、この発明の請求項1の記載の発明によれば、プロセッサエレメントの数が主走査方向の画素数より少ない場合においても、容易にSIMDプロセッサでの演算が行え、フィルタ処理などの重み付け演算を行う場合に有効な画素のみを転送できる。
【0123】
また、請求項2に記載の発明によれば、SIMD型プロセッサを用いた画像処理システムにおいて、シングルポートメモリを用いながらラインメモリを実現できる。
【0124】
請求項3に記載の発明によれば、主走査方向の画素数よりも少ないプロセッサエレメント数のSIMD型プロセッサを用いた場合に、フィルタ処理などの重み付け演算を行う場合に、有効な画素のみを転送することができる。
【0125】
また、請求項4に記載の発明によれば、主走査方向の画素数よりも少ないプロセッサエレメント数のSIMD方式プロセッサを用いた場合に、フィルタ処理などの重み付け演算を行う場合に、参照用画素データを併せて転送することができる。
【0126】
請求項5に記載の発明によれば、複数の処理ステップを持つような画像処理の場合に、処理ステップごとにデータを保管することが可能になる。
【0127】
また、請求項6及び7に記載の発明によれば、全プロセッサエレメントの汎用レジスタのデータを転送する時間を半分にすることができること。また、RAMのアクセスタイムに余裕を持たせることができる。
【0128】
請求項8及び9に記載の発明によれば、デジタル画像処理における変倍処理をメモリコントローラで実現しているため、SIMD型プロセッサ自体の汎用性と回路規模を保つことが可能になる。
【0129】
また、請求項10に記載の発明によれば、デジタルコピーなど主走査方向の画素が極めて多い画像処理装置を実現する場合に、プロセッサエレメント数を増減するなどのSIMD方式プロセッサのアーキテクチャそのものを変更することなく画像処理装置を構築することが可能になる。
【図面の簡単な説明】
【図1】この発明の実施形態におけるSIMD型プロセッサを示すブロック図である。
【図2】この発明の第1の実施形態におけるSIMD型プロセッサの内部構成を示すブロック図である。
【図3】この発明の第1の実施形態におけるプロセッサエレメントの内部構成を示すブロック図である。
【図4】この発明に用いられるメモリコントローラ5の構成を示すブロック図である。
【図5】この発明に用いられるメモリコントローラ5のプロセッサエレメント(PE)制御部52の実施形態の概略ブロック図である。
【図6】この発明に用いられるメモリコントローラ5のメモリ(RAM)制御部53の第1の実施形態の概略ブロック図である。
【図7】主走査方向の画素数よりもプロセッサエレメント3aの数が少ないSIMD方式のプロセッサを用いた場合の画素データの転送方法についての説明図である。
【図8】この発明に用いられるメモリコントローラ5のRAM制御部53の第2の実施形態を示す概略ブロック図である。
【図9】この発明に用いられるメモリコントローラ5のRAM制御部53の第3の実施形態を示す概略ブロック図である。
【図10】この発明に用いられるメモリコントローラ5のライトバッファ部54及びリードバッファ部55の概略ブロック図である。
【図11】変倍処理の内、縮小を実現するための間引きライト動作の説明図である。
【図12】変倍処理の内、重複リード動作の説明図である。
【図13】この発明の他の実施形態におけるSIMD型プロセッサの内部構成を示すブロック図である。
【図14】この発明のさらに異なる実施形態におけるSIMD型プロセッサの内部構成を示すブロック図である。
【図15】この発明の他の実施の形態を示す概略ブロック図である。
【図16】従来のSIMD方式を用いた画像処理装置の概略ブロック図である。
【符号の説明】
1 SIMD型プロセッサ
2 グローバルプロセッサ
4 外部インタフェース
5 メモリコントローラ
6 画像メモリ
51 シーケンスユニット
52 PE制御部
53 RAM制御部
54 ライトバッファ部
55 リードバッファ部
[0001]
[Industrial application fields]
The present invention relates to a signal processing apparatus using a single instruction stream multiple data stream (SIMD) type processor that processes a plurality of image data and the like in parallel by a single operation instruction, and is suitable for use in image processing such as digital copying. It relates to the device.
[0002]
[Prior art]
In recent years, in digital copying machines, facsimile machines, and the like, improvement of images has been attempted by increasing the number of pixels or making it compatible with color. As the image is improved, the number of data to be processed has increased. By the way, data processing in a copying machine or the like often performs the same arithmetic processing on all pixels. Therefore, a SIMD processor that performs the same arithmetic processing on a plurality of data simultaneously with one instruction is used.
[0003]
Normally, when image processing is performed using a SIMD processor, processor elements (PE) are developed in the main scanning direction. For this reason, when performing image processing such as filter processing, reference pixels above and below the target pixel are required, and it is conceivable that pixel data of the previous line is delayed in line and stored in the line memory.
[0004]
FIG. 16 shows a schematic block diagram of an image processing apparatus using the SIMD method. As shown in the figure, the image processing apparatus includes an external image memory (RAM) 101 in which image data is stored, for example, a processor element block 103 including 1024 processor elements, and a global processor 104.
[0005]
Each processor element (PE) has n general-purpose registers (R0 to Rn-1) and an operation array, and the general-purpose registers are in the form of having a register file outside the normal operation array. Each register is accessible as a shift register to the outside through a serial port. In the figure, the shaded area is a unit processor element.
[0006]
The global processor 104 has an address generation means for a program memory (PRAM) 105, reads an instruction code given to the processor element of the processor element block 103 from the PRAM 105, and controls the operation array and the register file.
[0007]
The device connected to the serial port of the general-purpose register of each PE differs depending on the system configuration. However, in a system that requires only a line delay of two lines, for example, pixel data of two lines before in R0 and one line before in R1 Assuming that the current line pixel data is arranged in the pixel data R2, the serial-parallel converter 102 is arranged in the serial ports R0 and R1, and is connected to the external RAM 101.
[0008]
For example, SVP (SERIAL VIDEO PROCESSOR) is known as an example of the image processing apparatus having the above-described configuration.
[0009]
Since most conventional SIMD processors have processor elements larger than the number of pixels in the main scanning direction, difficult processing is not required for controlling the external memory (RAM) 101. In order to realize a scaling function such as enlargement or reduction in image processing such as digital copying, a separate ASIC is attached or described in Japanese Patent Laid-Open No. 08-123683 (IPC: G06F 9/38). This can be realized by adopting a configuration in which a flag for zooming control is provided inside the SIMD processor.
[0010]
[Problems to be solved by the invention]
However, the accuracy of image processing has been increasing in recent years, and the number of pixels in the main scanning direction tends to increase. Further, in a conventional SIMD type processor, an increase in the circuit scale is usually prevented by using a small-scale circuit, for example, a processor having a large number of processor elements uses a 1-bit arithmetic array.
[0011]
When trying to apply a SIMD type processor to digital copying, for example, when handling an A4 size image with an accuracy of 600 DPI (Dot Per Inch), the number of processor elements of 7000 pixels or more is required. It is not realistic to increase In order to solve this problem, it is conceivable to perform processing by dividing the main scanning direction. However, a dual port memory (RAM) is required as a line memory, which increases the circuit scale.
[0012]
On the other hand, in Japanese Patent Laid-Open No. 10-326258 (IPC: G06F 15/16), the processing time is obtained by dividing the pixels in the main scanning direction into two and dividing the total number of processor elements in half to perform pipeline processing. There has been proposed a data operation system that can shorten the time. However, with this method, it is not possible to perform processing with the number of pixels exceeding the size of the data memory accessible to the processor element.
[0013]
Furthermore, in a configuration in which a processor element has a scaling control flag, the processing becomes complicated when the number of divisions increases, so it is desirable to implement scaling processing outside the SIMD type processor. However, if the scaling function is realized separately using an ASIC, the versatility of the processor is reduced.
[0014]
Therefore, the present invention provides a signal processing device using a SIMD processor having a simple configuration that can suppress the increase in circuit scale by using a single port memory (RAM) and at the same time incorporate a zoom function. Objective.
[0015]
[Means for Solving the Problems]
The present invention relates to a processor element of a SIMD type processor comprising a computing means for computing data and data holding means for holding data computed by the computing means and holding data computed by the computing means; A data transfer bus connected to each of the plurality of processor elements; designation means for designating a predetermined processor element based on addresses assigned to the plurality of processor elements; and an address bus for supplying an address to the designation means; A data transfer interface for accessing the data holding means incorporated in the plurality of processor elements from outside the processor, and the predetermined processor element connected to the data transfer interface and supplied to the address bus is designated A memory controller that generates an address for reading data, reads data stored in an external memory, writes data to the processor element, reads data from the processor element, and writes data to the memory; And when the memory controller transfers data from the data holding means of each processor element to the memory via the data transfer interface, the address of the processor element that starts the transfer and the processor element that ends the transfer Specify the address, and a predetermined number De The calculated data is read from each processor element. The pointer value corresponding to the address of the processor element that starts the transfer is set, and the previous value is set based on this pointer value. When writing this data to the memory and transferring data from the memory to the data holding means of each processor element via the data transfer interface, The amount corresponding to the predetermined number of data excluded in the previous processing Returned address A pointer value is set, data is read from the memory based on the pointer value, and an address for designating the predetermined processor element to be supplied to the address bus corresponding to the pointer value is generated. The data is written into the processor element, the data is divided, and the arithmetic processing is performed by the SIMD type processor.
[0016]
With the configuration described above, even when the number of processor elements is smaller than the number of pixels in the main scanning direction, the SIMD processor can easily perform calculations and only effective pixels when performing weighting calculations such as filter processing. Can be transferred.
[0017]
The memory controller may control to perform write transfer and read transfer to the memory in a time-sharing manner.
[0018]
With this configuration, the single port memory can be used as a FIFO or LIFO memory, and a line memory can be realized using the single port memory.
[0019]
The memory controller starts a transfer when transferring data from the data holding means of each processor element to the memory via the data transfer interface. Address And the processor element that ends the transfer Address May be provided with a register for designating. For example, an initial value loading function may be added to the address counter of the processor element so that an offset value can be set based on the address of the processor element.
[0020]
Furthermore, the memory controller terminates the transfer when transferring data from the memory to the data holding means of each processor element via the data transfer interface. Address And a processor element to return the memory read pointer after the transfer ends Address Can be provided with a register for designating. For example, a comparator between the processor element address and the set value may be provided so as to reload the read pointer of the memory in which the data transferred to the register having the processor element address equal to the set value is stored.
[0021]
With the configuration described above, when a SIMD processor having a smaller number of processor elements than the number of pixels in the main scanning direction is used, only effective pixels can be transferred when performing weighting operations such as filter processing.
[0022]
Further, the memory controller can be configured so that a lower limit value and an upper limit value of an arbitrary address area of the memory are set by a register and the area is used in a ring shape. For example, a lower limit value and an upper limit value register for memory pointers may be provided, each having a comparator, and configured so that the value of each register can be output to the address bus when the conditions are met.
[0023]
With the above configuration, in the case of image processing having a plurality of steps, data can be stored for each processing step.
[0024]
The data transfer interface may be configured to be able to simultaneously access data holding means of processor elements having even addresses and processor elements having odd addresses. For example, a data transfer port of a SIMD type processor has a configuration having two independent ports for accessing a data holding means of a processor element having an even address and a processor element having an odd address, and two processor elements in one cycle. What is necessary is just to comprise so that the data of a minute can be processed.
[0025]
Furthermore, the bit width of the input / output bus with the memory may be wider than the data transfer bit width with the processor element. For example, the bit width of the memory may be configured to be 4 processor elements wide by having input / output buffers for the memory for 4 processor elements.
[0026]
With the above configuration, the time for transferring data to the data holding means of all the processor elements can be halved. Further, it is possible to provide a margin for memory access time.
[0027]
Further, according to the present invention, when data is transferred from the data holding means of each processor element to the memory via the data transfer interface, the write control signal from the outside synchronized with the data transfer is “0”. The data can be written in, and when it is “1”, the data writing can be prohibited. For example, by inputting a synchronization signal to the sequence unit from the outside and controlling the timing to start the write transfer, the write control signal and the write transfer can be synchronized, and depending on the value of the write control signal, What is necessary is just to comprise so that transfer according to a write control signal can be performed by changing the control of the write buffer part for shaping the data read from the data transfer port of the processor element and writing it to the RAM.
[0028]
Further, when data is transferred from the memory to the data holding means of each processor element via the data transfer interface, when an external read control signal synchronized with the data transfer is “0”, The value read from the memory is written to the data transfer interface. If it is “1”, the same value as the data transferred when the external signal was “0” last before the transfer is transferred. Can be configured to write to the interface. For example, by inputting a synchronization signal from the outside to the sequence unit and controlling the timing of starting the read transfer, the read control signal and the read transfer can be synchronized, and depending on the value of the read control signal, What is necessary is just to comprise so that transfer according to a read control signal can be performed by changing the control of the read buffer part for shaping the data read from RAM, and writing in the data transfer port of a processor element.
[0029]
With the configuration described above, the scaling process in the digital image processing can be realized by the memory controller, so that the versatility and circuit scale of the SIMD type processor itself can be maintained.
[0030]
Further, according to the present invention, image data is stored in the memory, the number of processor elements of the SIMD type processor is configured to be smaller than the number of pixels in the main scanning direction, and the memory controller sets all the pixels in the main scanning direction to 2 It can be configured to control the processing of writing and reading data so that the processing is divided into two or more.
[0031]
By configuring as described above, when realizing an image processing apparatus having a very large number of pixels in the main scanning direction, such as digital copying, without changing the SIMD processor architecture itself, such as increasing or decreasing the number of processor elements. An image processing apparatus can be constructed.
[0032]
DETAILED DESCRIPTION OF THE INVENTION
Embodiments of a SIMD type processor 1 according to the present invention will be described below with reference to the drawings.
[0033]
First, the overall configuration of the SIMD type processor according to the present invention will be described with reference to FIG. As shown in FIG. 1, the SIMD type processor 1 of the present invention includes a global processor 2, a processor element block 3 including 1024 sets of processor elements 3a described later in this embodiment, and an external interface 4 connected to a memory controller 5. Composed. Based on instructions from the global processor 2, the memory controller 5 provides image data to be calculated from an external image memory 6 composed of a single port memory (RAM) to an input / output register file 31 inside the processor, and performs arithmetic processing. The processed data is transferred from the register file 31 to the image memory (RAM) 6.
[0034]
As shown in FIG. 2, the global processor 2 includes a processor element block 3, a program RAM 21 in which a program for controlling the external interface 4 and the memory controller 5 is stored, and a global processor 2 and a processor element block based on the program RAM 21. 3, a sequence unit 22 for controlling the external interface 4 and the memory controller 5 is provided. Specifically, the sequence unit 22 controls an arithmetic logic unit 23 (hereinafter referred to as “ALU 23”), which will be described later, provided in the global processor 2.
[0035]
The sequence unit 22 controls the register file 31 and the arithmetic array 36 that constitute the processor element block 3. The arithmetic array 36 includes a multiplexer 32, a shift extension circuit 33, an arithmetic logic unit 34 (hereinafter referred to as “ALU 34”), and a register 35. The global processor 2 is a so-called SISD type, and performs one arithmetic process for one arithmetic instruction.
[0036]
Further, the sequence unit 22 sends operation setting data and commands for data transfer to the memory controller 5. Based on the operation setting data and command of the sequence unit 22, the memory controller 5 is an address control signal for addressing the processor element 3a, and instructs the register 31b constituting the processor element 3a to read / write data. A clock control signal for supplying a read / write control signal and a clock signal is supplied to the external interface 4.
[0037]
Here, the write control signal among the read / write control signals refers to a signal for acquiring data to be processed from the data bus 46a (46b) and holding it in the register 31b of the processor element 3a. On the other hand, of the read / write control signals, the read control signal means that the processed data held in the register 31b of the processor element 3a is given to the data bus 46a (46b). In A signal for instructing the register 31b.
[0038]
In the processor element block 3 in this embodiment, an even number and an odd number are assigned to two adjacent processor elements 3a to form one set, and the same address is assigned to this set of processor elements 3a.
[0039]
Upon receiving a command from the global processor 2, the memory controller 5 creates a signal (hereinafter referred to as “address designation signal”) that designates the address of the processor element 3 a that constitutes the processor element block 3, and the external controller 4 The data is sent to the register controller 31a of the processor element 3a via the address bus 41a. As will be described later, the memory controller 5 sends a signal for instructing the register 31b constituting the processor element 3a to read / write data (hereinafter referred to as “read / write instruction signal”). A read / write signal is supplied to a register controller 31a (to be described later) of the processor element 3a through a read / write signal line 45a (45b). The even read / write signal line 45a provides a read / write signal to the even number processor element 3a, and the odd read / write signal line 45b provides a read / write signal to the odd number processor element 3a.
[0040]
Further, the memory controller 5 gives a clock signal from the external interface 4 to a register controller 31a (to be described later) of the processor element 3a through the clock signal line 41c.
[0041]
Further, as described above, the memory controller 5 gives the data stored in the image memory 6 provided outside the SIMD type processor 1 to the external interface 4 as 16-bit parallel data in this embodiment. The 16-bit data is composed of 8 bits given to the processor element 3a assigned with the even number and 8 bits given to the processor element 3a assigned with the odd number. The 8-bit data is applied to the even data bus 46a and the odd data bus 46b. The 8-bit parallel data can be appropriately changed according to the data. The data buses 46 a and 46 b are also used when the processed data held in the register 31 b is sent to the image memory 6 provided outside the SIMD type processor 1.
[0042]
The image memory 6 stores data to be subjected to arithmetic processing and stores data subjected to arithmetic processing. These image memories 6 may be provided inside the SIMD type processor 1 without any problem. Also, in this embodiment, data transfer between the memory controller 5 and the image memory 6 is treated as being transferred as 32-bit parallel data, as will be described later. However, the data transfer is appropriately changed according to the data. There is no problem. Other operations performed by the memory controller 5 will be described later.
[0043]
In addition, the global processor 2 includes an ALU 23 that performs arithmetic logic operations and a data RAM 24 that stores operation data in accordance with instructions from the sequence unit 22. Further, the global processor 2 includes a register group 25 for holding data to be processed.
[0044]
The register group 25 includes a program counter PC that holds a program address, G0 to G3 registers that are general-purpose registers for storing data for arithmetic processing, and a stack that holds the address of the save destination data RAM at the time of register save and return. Pointer (SP), link register (LS) that holds the address of the caller at the time of a subroutine call, LI and LN registers that hold branch source addresses at the time of IRQ and NMI, and a processor status register that holds the state of the processor (P) is incorporated.
[0045]
The register group 25 is connected to a later-described register 35 of the processor element block 3, and data is exchanged with the register 35 under the control of the sequence unit 22.
[0046]
As shown in FIGS. 1 and 2, the processor element block 3 includes a register file 31, a multiplexer 32, a shift / expansion circuit 33, an arithmetic logic unit 34 (hereinafter referred to as “ALU 34”), and a register 35 as one unit. A plurality of processor elements 3a. The register file 31 includes 32 8-bit registers in one processor element 3a. In this embodiment, a set of 1024 processor elements has an array configuration. The register file 31 stores R0, R1, R2,... For each processor element (PE) 3a. . . A register called R31 is incorporated. Each register file 31 has one read port and one write port for the arithmetic array 36 and is accessed from the arithmetic array 36 by an 8-bit read / write bus. Of the 32 registers, 24 are accessible from outside the processor, and any register can be read and written by inputting a clock, an address, and read / write control from the outside.
[0047]
Access from the outside of the register allows one register of each processor element 3a to be accessed by one external port, and the processor element number (0 to 1023) is designated by an address inputted from the outside. Therefore, a total of 24 external ports for register access are installed. As described above, externally accessed data is 16-bit data for one set of even-numbered processor elements 3a and odd-numbered processor elements 3a, and two registers are accessed simultaneously by one access. ing.
[0048]
In the present embodiment, the number of processor elements 3a is described as 1024. However, the number of processor elements 3a is not limited to this, and may be changed as appropriate. Addresses 0 to 1023 are assigned to the processor element 3a in the order of closeness to the external interface 4 by the sequence unit 22 of the global processor 2.
[0049]
The register file 31 of the processor element 3a includes a register controller 31a and two types of registers 31b and 31c. In the present embodiment, as shown in FIG. 3, each unit of processor element 3a includes 24 sets of register controller 31a and register 31b, and further includes 8 registers 31c. 3 shows a part of the register file 31 in the two sets of processor elements 3a, and one processor element in FIG. 3 represents one processor element 3a. Here, in the present embodiment, the registers 31b and 31c are handled as 8-bit registers, but the present invention is not limited to this and may be used with appropriate modifications.
[0050]
As shown in FIG. 3, the register controller 31a is connected to the external interface 4 via the address bus 41a, the even read / write signal line 45a, the odd read / write signal line 45b, and the clock signal line 41c. ing.
[0051]
When receiving the address control signal from the memory controller 5, the external interface 4 sends an address designation signal to the processor element block 3 via the address bus 41a. Thereby, a set of processor elements 3a, ie two processor elements 3a, are addressed simultaneously. The register controller 31a decodes the address designation signal sent, and if the decoded address matches the address assigned to itself, the register controller 31a sends the clock sent from the memory controller 5 via the clock signal 41c. In synchronization with the signal, a read / write instruction signal sent from the memory controller 5 is obtained via the read / write signal 45a or 45b. Specifically, the register controller 31a to which the even number is assigned obtains the read / write instruction signal sent from the memory controller 5 through the even read / write signal 45a. On the other hand, the register controller 31a to which the odd number is assigned obtains the read / write instruction signal sent from the memory controller 5 via the odd read / write signal 45b. At this time, the read / write instruction signals sent to the register controller 31a of the processor element 3a constituting the set may be different. That is, when the instruction signal sent to the register controller 31a assigned with the even number is a read instruction, the instruction signal sent to the register controller 31a assigned with the odd number may be a write instruction. The read / write instruction signal is given to the register 31b.
[0052]
When a write instruction signal is sent from the register controller 31a to both processor elements 3a, the register 31b of the processor element 3a to which the even number is assigned uses the data (8 bits) to be processed for an even number. Obtained from the data bus 46a and held. The register 31b of the processor element 3a to which the odd number is assigned acquires the data (8 bits) to be processed from the odd data bus 46b and holds it. On the other hand, when a read instruction signal is sent from the register controller 31a to both processor elements 3a, the register 31b of the processor element 3a to which the even number is assigned receives the processed data (8 bits). The data is sent to the even data bus 46a. In addition, the register 31b of the processor element 3a to which the odd number is assigned sends the processed data (8 bits) to the odd data bus 46b.
[0053]
As described above, data can be transferred to the processor element 3a to which the even number is assigned, and can be transferred to the processor element 3a to which the odd number is assigned. For this reason, the number of times of data transfer can be reduced, and data transfer can be performed at high speed.
[0054]
The register 31b holds data input from the outside that will be calculated in the ALU 34, which will be described later, or holds the data processed in the ALU 34 for output to the outside. Alternatively, it functions as an output register. Further, it also has a function as a register 31c, which will be described later, such as temporarily holding data to be processed or calculated data. In this embodiment, the register 31b is handled as one that can hold 8-bit data, but there is no problem even if it is appropriately changed according to the data. When the write instruction signal is given from the register controller 31a described above, the register 31b acquires and holds data to be processed from the data bus 46a or the data bus 46b. On the other hand, when a read instruction signal is sent from the register controller 31a, the register 31b gives the data processed and held to the data bus 46a or the data bus 46b. This data is given from the external interface 4 to the write buffer unit 54 of the memory controller 5 and stored in the image memory 6 from the write buffer unit 54.
[0055]
In the present embodiment, the register 31b is connected to the multiplexer 32 via a data bus 37 for transferring 8-bit data in parallel. Data processed by the ALU 34 or data processed by the ALU 34 is transferred to the register 31b via the data bus 37. This transfer is performed via a read signal line 26 a and a write signal line 26 b connected to the global processor 2 in accordance with an instruction from the sequence unit 22 of the global processor 2. Specifically, when a read instruction signal is sent from the sequence unit 22 of the global processor 2 via the read signal line 26a, the register 31b puts the data to be processed and held in the data bus. This data is sent to the ALU 34 and processed. On the other hand, when a write instruction signal is sent from the sequence unit 22 of the global processor 2 via the write signal line 26b, the register 31b holds the data processed by the ALU 34 sent via the data bus 37. To do.
[0056]
The register 31c temporarily holds the data to be processed by the register 31b or before the calculated data is supplied to the register 31b. Unlike the register 31b described above, the register 31c does not transfer data to or from the image memory 6 via the memory controller 5.
[0057]
The arithmetic array 36 includes a multiplexer 32. , Ft / extension circuit 33, 16-bit ALU 34, and 16-bit register 35. The register 35 includes a 16-bit A register and an F register.
[0058]
In the calculation by the instruction of the processor element 3a, basically, the data read from the register file 31 is input to one side of the ALU 34 and the content of the A register of the register 35 is input to the other side, and the result is stored in the A register. Therefore, the operation between the A register and the R0 to R31 registers of the register file 31 is performed. A (7 to 1) multiplexer 32 is placed in the connection between the register file 31 and the arithmetic array 36, and the data 1, 2, 3 away to the left and the data 1, 2, 3 away to the right in the processor element direction, The center data is selected as the calculation target. The 8-bit data in the register file 31 is shifted to the left by an arbitrary bit by the shift / extension circuit 33 and input to the ALU 34. In addition, the execution / invalidation control of each processor element 3a is controlled by an 8-bit condition register (T) (not shown) so that only a specific processor element 3a can be selected as an operation target. ing.
[0059]
As described above, the multiplexer 32 is connected to the data bus 37 provided in its own processor element 3a, and is also connected to the data bus 37 provided in the three adjacent processor elements 3a. The multiplexer 32 selects one of the seven processor elements 3 a and sends the data held in the registers 31 b and 31 c in the selected processor element 3 a to the ALU 34. Alternatively, the data processed by the ALU 34 is sent to the registers 31b and 31c in the selected processor element 3a. As a result, arithmetic processing using data held in the registers 31b and 31c in the adjacent processor element 3a becomes possible, and the arithmetic processing capability of the SIMD type processor 1 can be increased.
[0060]
The shift / extension circuit 33 shifts the data sent from the multiplexer 32 by a predetermined bit and sends it to the ALU 34. Alternatively, the arithmetically processed data sent from the ALU 34 is shifted by a predetermined bit and sent to the multiplexer 32.
[0061]
The ALU 34 performs arithmetic logic operations based on the data sent from the shift / expansion circuit 33 and the data held in the register 35. In this embodiment, the ALU 34 is handled as being capable of handling 16-bit data, but there is no problem even if it is appropriately changed according to the data. The processed data is held in the register 35 and transferred to the shift / expansion circuit 33 or transferred to the general-purpose register 25 of the global processor 2.
[0062]
An I / O address, data, and control signal are given from the global processor 2 to the memory controller 5 via a bus. The global processor 2 sets commands such as an operation method in some operation setting registers (not shown) of the memory controller 5. Finally, the global processor 2 writes a start code in a start register (not shown) of the memory controller 5 so that the memory controller 5 automatically performs an operation according to the setting. With this configuration, the data in the register file 31 can be input / output simultaneously with the calculation based on the instruction control of the processor.
[0063]
FIG. 4 shows the configuration of the memory controller 5 used in the present invention. The memory controller 5 includes a write buffer unit 54 that writes data to the image memory 6, a read buffer unit 55 that reads data from the image memory 6, and a PE control unit 52 that controls the register file 31 of the processor element. A RAM control unit 53 that controls the image memory 6 and a sequence unit (SCU) 51 are included.
[0064]
The memory controller 5 is connected to the register file 31 of the SIMD type processor 1 via a data transfer port in the external interface 4, transfers data from the register file 31 to the image memory 6, and transfers from the image memory 6 to the register file 31. Data transfer. This data transfer port includes an output port and an input port. In addition, as described above, the registers controlled by the memory controller 5 in this embodiment are mapped to the I / O space, and output addresses, clocks, and read / write controls in accordance with instructions from the global processor 2. By doing so, it is possible to read and write.
[0065]
An output port of the external interface 4 of the SIMD processor 1 is connected to the write buffer unit 54, and an input port of the external interface 4 is connected to the read buffer unit 55. Each data transfer port has independent input and output ports for even processor elements and odd processor elements, and can be configured to access data for one set of even and odd processor elements at a time in one cycle. Has been. The data buses between the write buffer unit 54, the read buffer unit 55, and the image memory 6 are each configured with a data width for four processor elements, and data for four processor elements can be accessed at one time in one cycle. In this embodiment, the data for one processor element is 8 bits. The bit width of the data bus between the external interface 4 and the write buffer 54 and read buffer 55 is 16 bits. Accordingly, the bit width between the memory controller 5 and the image memory 6 is 32 bits.
[0066]
As a result, the transfer between the image memory 6 and the memory controller 5 only needs to be executed once while the transfer between the data transfer port of the external interface 4 and the memory controller 5 of the external interface 4 is performed twice.
[0067]
The write buffer unit 54 of the memory controller 5 takes in the pixel data output from the external interface 4 of the SIMD type processor 1 twice, shapes it into data for four processor elements, and transfers it to the image memory 6. ing. The read buffer unit 55 performs an operation of dividing the data for the four processor elements read from the image memory 6 into two times and transferring them to the external interface 4 of the SIMD type processor 1.
[0068]
FIG. 5 shows a schematic block diagram of an embodiment of the processor element (PE) control unit 52.
[0069]
As shown in FIG. 5, the PE control unit 52 outputs the address, clock, and read / write control signal of the processor element 3 a to the external interface 4 of the SIMD processor 1, and registers the processor elements 3 a in the SIMD processor 1. Data in the file 31 can be read and written.
[0070]
The PE control unit 52 includes a processor element (PE) address counter 521, transfer number counters 522 and 523, and a valid data number counter 524. In the case of write transfer (transfer from the register file 31 of the processor element 34a to the image memory 6), the PE address counter 521 is initially loaded with “0” at the start of transfer, and read transfer (register from the image memory 6 to the processor element 34a). In the case of (transfer to file 31), the value stored in the transfer start PE address register 525 is initially loaded at the start of transfer, and generates the address of the processor element to which data is transferred. The transfer number counters 522 and 523 are down counters that can initially load the number of data to be transferred, and are used to manage the transfer number. The transfer counter 522 is set with the number of data to be written, and the transfer counter 523 is initially loaded with the number of data to be read.
[0071]
The valid data number counter 524 is a counter that manages the number of valid data stored in the image memory 6. When data is transferred from the image memory 6 to the register file 31 of the processor element 3 a, the valid data number counter 524 has a valid data number that is larger than the transfer number. The transfer is performed only when there are more people. With this configuration, data loss is prevented.
[0072]
FIG. 6 shows a schematic block diagram of the first embodiment of the memory (RAM) control unit 53.
[0073]
As shown in FIG. 6, the RAM control unit 53 is controlled by control lines from the write buffer unit 54 and the read buffer unit 55, and clocks, addresses, and reads to the image memory (RAM) 6 composed of a single port memory / Write control and byte select are output.
[0074]
The RAM control unit 53 includes a RAM address adjuster 531, a write pointer register 532, a read pointer register 533, and a multiplexer 534. Each block is connected via an address setting bus (hereinafter abbreviated as AB).
[0075]
The write pointer register 532 is a register that stores a pointer to be written to the image memory 6 next, and the read pointer register 533 is a register that similarly stores a pointer to be read from the image memory 6 next.
[0076]
In the write pointer register 532 and the read pointer register 533, the pointer updated by the RAM address adder / subtractor 531 is input from the AB 535 and stored after accessing the pointer in the image memory 6. The RAM address adder / subtractor 531 outputs a value corresponding to the RAM access size to the value of the write pointer at the time of write access and the read pointer at the time of read access, and adds the subtracted value to the AB 535 in the FIFO operation mode and subtraction in the LIFO operation mode. .
[0077]
The sequence unit 51 includes an address decoder and a control register. By accessing a control register mapped to the I / O space from the global processor 2, the sequence unit 51 controls the entire memory controller 5, or the global processor 2 controls the memory controller. 5 can be monitored. Further, the time division of the write transfer and the read transfer is also performed in the block of the sequence unit 51. Further, by generating two clocks, a clock to the write buffer unit 54 and a clock to the read buffer unit 55, write transfer and read transfer can be performed simultaneously.
[0078]
Next, a description will be given of a pixel data transfer method in the case of using an SIMD type processor in which the number of processor elements 3a is smaller than the number of pixels in the main scanning direction. FIG. 7 shows an explanatory diagram of a pixel data transfer method when a SIMD processor having a smaller number of processor elements 3a than the number of pixels in the main scanning direction is used.
[0079]
When the number of processor elements 3a is smaller than the number of pixels in the main scanning direction, the pixel data in the main scanning direction is divided and the memory controller 5 stores the pixel data in the register file 31 of the processor element 3a of the SIMD processor 1 in the image memory 6 This process is repeatedly executed. That is, when the number of processor elements is smaller than the number of pixels in the main scanning direction, pixel data in the main scanning direction is divided and the arithmetic processing is repeatedly executed by the SIMD processor 1.
[0080]
Usually, in image processing using a SIMD type processor, when processing including processing referring to pixel data before and after a pixel of interest is performed, such as filter processing, invalid data remains in data at both ends of the SIMD. For this reason, when data is stored in the image memory 6 from the register file of the processor element 3a, it is necessary to store the data excluding the data at both ends. Further, when data is transferred from the image memory 6 to the register file 31 of the processor element 3a, it is necessary to transfer reference pixel data before and after the target pixel. That is, transfer of pixel data in weighting processing such as filter processing is performed in the following order. Here, the number of reference pixels is a.
[0081]
1. The pre-processing pixel data is transferred from the image memory 6 to the corresponding register file 31 of the processor element 3a of the SIMD processor 1.
[0082]
2. Image processing by the SIMD processor 1 is performed. At this time, the a data before and after the SIMD processor element 3a are invalidated due to the absence of the reference pixel. That is, the hatched portion in FIG. 7 is the number of effective pixels.
[0083]
3. The processed pixel data is transferred from the SIMD processor 1 to the image memory 6. At this time, effective pixels excluding a pixels before and after both ends are transferred to the image memory 6.
[0084]
The transfer of pixel data between the image memory 6 and the SIMD processor 1 will be described with reference to FIG. The processor element (PE) 3a of the SIMD processor 1 includes n, that is, PE0 to PEn-1, and sends pixel data from the image memory 6 to the processor elements 3a. Pixel data is transferred from 3a to the image memory 6.
[0085]
First, in the first transfer, that is, the 1st SIMD transfer in the figure, a reference pixel a is transferred before and after the processor element 3a of the SIMD processor 1. In the example shown in FIG. 7, the RAM control unit 53 first stores 0 in the read pointer 533, and reads the number corresponding to the RAM access size, in this embodiment, 32 bits of data from the image memory 6. And stored in the read buffer unit 55. The address adder / subtractor 531 outputs a value corresponding to the RAM access size to the read pointer value in the FIFO operation mode, and outputs the subtracted value to the AB 535 in the LIFO operation mode. Stored. Then, an address is generated by the PE address counter 521 of the PE control unit 52, and data is written from the external interface 4 to the corresponding processor element 3a... Based on the address. The transfer number counter 522 is decremented by a number corresponding to the RAM size each time image data is written, ie, 4 in this embodiment. The above processing is repeatedly executed until the value of the transfer counter 522 becomes 0, and the pixel data from the image memory 6 is transferred from PE0 to PEn-1 of the SIMD processor 1.
[0086]
When the processed pixel data is transferred to the image memory 6, the a pixel data before and after the pixel data are invalid, and therefore, the pixel data to be transferred is a to (na-1) among n pixels from PE0 to PEn-1. ) Pixels up to (n−2 × a). For this reason, the value of the transfer start PE address register 525 is loaded into the PE address counter 521 of the PE control unit 52 at the start of transfer, and data is read from the corresponding processor element 3a. The image data is written from 4 to the write buffer unit 54. Each time data is read, the transfer number counter 523 is decremented by a number corresponding to the RAM access size, ie, 4 in this embodiment. When 32-bit data is stored in the write buffer unit 54, the image data is transferred to the image memory 6. First, the RAM control unit 53 Write pointer 532 A is stored, and the image data stored in the write buffer unit 54, in this embodiment, 32 bits of data is transferred to the image memory 6. The address adder / subtractor 531 outputs the value corresponding to the RAM access size to the value of the read pointer, adds the value in the FIFO operation mode, and subtracts the value in the LIFO operation mode to the AB 535, and the value is stored in the write pointer 532. The In this manner, image data from PEa to PEn-2 × a of the SIMD processor 1 is transferred to the image memory 6.
[0087]
Subsequently, the second transfer is performed in the same manner. In the second SIMD transfer in the figure, since the pixels from (n−a) to (2n−3 × a) are processed as the target pixel, (n−2 × a) to (n−a−1) are used as reference pixels. ) And (2n−3 × a) to (2n−2 × a−1) pixel data are sent together. After the data processing, (n−3 × a) pixels (n−a) to (n−2 × a) are stored in the image memory 6. Similar processing is only repeated when the number of SIMD divisions in the main scanning direction is large.
[0088]
In order to realize the above processing, in the case of data write to the image memory 6, “a” is set in the transfer start PE address register 525 in the embodiment of the processor element (PE) control unit 52 of the present invention. In this case, “(n−2 × a)” may be set in the transfer number counter 522.
[0089]
Since all the setting numbers are based on the PE address, there is no need to change the setting for each SIMD. In the case of reading data from the image memory 6, an operation of returning the read pointer 533 after the transfer is completed is necessary. In the above example, the value is returned to (n−2 × a). In the embodiment of the hitting 1 of the RAM control unit 53, it is necessary to set the value of the read pointer 533 from the global processor 2 after the transfer is completed.
[0090]
In the case of data writing to the image memory 6, it is not necessary to operate the write pointer 532.
[0091]
FIG. 8 is a schematic block diagram showing a second embodiment of the RAM control unit 53 according to the present invention.
[0092]
The RAM control unit 53 shown in FIG. 8 is obtained by adding a read offset generator 536 to the RAM control unit 53 shown in FIG. The RAM control unit 53 returns the value of the read pointer 533 after the transfer to the processor element 3a is completed when data is transferred from the memory 6 to each register file of the processor element 3a of the SIMD processor 1 by the read offset generator 536. It has changed to be able to.
[0093]
The read offset generator 536 monitors the PE address input from the PE control unit 52. When the PE address becomes equal to the set value, the read offset generator 536 holds the value of the read pointer 533 at that time and sends the set transfer number. Continue forwarding until finished. When the transfer is completed, the held value is reloaded into the read pointer 533. In the example shown in FIG. 7, (n−2 × a−1) is set. Since all setting values are based on the PE address, it is not necessary to change the setting for each SIMD as in the first embodiment of the RAM control unit 53.
[0094]
FIG. 9 is a schematic block diagram showing a third embodiment of the RAM control unit 53 according to the present invention.
[0095]
In addition to the above processing, the RAM control unit 53 shown in FIG. 9 can use only a specific area of the image memory 6 in a ring shape.
[0096]
The RAM control unit 53 is obtained by adding two registers 537 and 538 and a comparator 539 to the RAM control unit shown in FIG. The register (LADDR) 537 sets the lower limit value of the address of the image memory 6, and the register (UADDR) 538 sets the upper limit value of the address of the image memory 6. The comparator 539 compares the current pointer 532 (533) with the values set in the LADDR 537 and UADDR 538, respectively.
[0097]
In the FIFO mode, when the UADDR 538 and the pointer 532 (533) coincide with each other and the value output from the address adjuster 531 exceeds the UADDR 538, the output from the address adjuster 531 to the AB 535 is negated, and the LADDR 537 receives the AB 535. Assert the output to
[0098]
Conversely, in the LIFO mode, when the LADDR 537 matches the pointer 532 (533) and the value output from the address adjuster 531 is lower than the LADDR 537, the output from the address adjuster 531 to the bus AB 535 is negated, and the UADDR 538 Assert the output to AB535. By configuring as described above, only a specific space of the memory space of the image memory 6 can be used.
[0099]
FIG. 10 is a schematic block diagram of the write buffer unit 54 and the read buffer unit 55 according to the embodiment of the present invention.
[0100]
The write buffer unit 54 and the read buffer unit 55 in this embodiment have dedicated ports for the even-numbered processor element 3a and the odd-numbered processor element 3a, and are configured to be able to access data for two processor elements in one cycle. It is possible to transfer data with the number of cycles that is half of the total number of processor elements.
[0101]
The write buffer unit 54 is configured to perform write access to the image memory 6 when data for four processor elements is stored in the buffer.
[0102]
Data for two processor elements supplied from the transfer port of the external interface 4 to the write buffer unit 54 is first stored in the flip-flops 541 and 542 and then transferred to the flip-flops 543 and 544 in the next stage. Subsequently, the given two processor elements are stored in flip-flops 541 and 542. Then, the data for four processor elements stored in the flip-flops 541 to 544 are stored in the latches 545 to 548, respectively. When the data for four processor elements is stored in the latches 545 to 548, the write buffer unit 54 performs write access to the image memory 6.
[0103]
The read buffer unit 55 stores data read from the image memory 6 for four processor elements in flip-flops 551 to 554 as buffers. Two processor elements are selected from the data for four processor elements by the multiplexer 555 and stored in the latches 556 and 557. The image data stored in the latches 556 and 557 is transferred to the register file 31 of the SIMD processor 1 via the external interface 4.
[0104]
When the transfer of data for four processor elements is completed, read access to the image memory 6 is performed again. Since the image memory 6 can access data for four processor elements at a time, if the access can be realized once in two cycles, the interface with the SIMD processor 1 can be taken, and the access time limit of the image memory 6 can be relaxed.
[0105]
FIG. 11 illustrates a thinning write operation for realizing reduction among the scaling processes often performed in digital copying, facsimile, and the like.
[0106]
In FIG. 11, the pixel data of the processor element (0), the processor element (2), etc. are stored in the image memory 6 as they are, and the pixel data of the processor element (1), the processor element (3), etc. are not stored in the image memory 6. Is thinned out.
[0107]
The memory controller 5 has two external write control signals for determining whether to thin out the data of the even-numbered processor element 3a and the odd-numbered processor element 3a. The memory controller 5 has an external terminal for notifying the memory controller 5 of the timing for starting transfer in order to synchronize the write control signal. The external synchronization signal for starting the transfer is input to the sequence unit, and when the synchronization signal is asserted, the sequence unit 51 starts the transfer.
[0108]
The sequence unit 51 detects the value of the write control signal, and when the external write control signal is “0”, writes the data in the buffer in the write buffer unit 54. Further, the sequence unit 51 detects the value of the write control signal, and when “1” is set, the sequence unit 51 suppresses storing the data in the buffer in the write buffer unit 54.
[0109]
Since the write buffer unit 54 does not output a transfer request to the image memory 6 to the RAM control unit 53 until data for four processor elements is stored, except for exceptions at the start and end of transfer, the address pointer The update of the data, the output to the image memory 6, the read / write control, and the byte select are not performed until the data for four processor elements is stored in the write buffer unit 54. Data reading from the data transfer port of the SIMD processor 1 continues regardless of the write control signal.
[0110]
FIG. 12 illustrates an overlapping read operation for realizing enlargement in the above scaling process. In FIG. 12, the data of the image memory 6 is written into the registers such as the processor element (0) and the processor element (2) sequentially from the position of the read pointer, and the registers such as the processor element (1) and the processor element (3) are written. The value written in the register of the previous processor element is written in duplicate.
[0111]
The memory controller 5 has two external read control signals for deciding whether or not the same data as before is written when the data of the even-numbered processor element 3a and the odd-numbered processor element 3a is written. .
[0112]
In order to synchronize the memory controller 5 and the overlap control signal, an external terminal for notifying the memory controller 5 of the timing for starting the transfer is provided. The external synchronization signal for starting the transfer is input to the sequence unit 51. When the synchronization signal is asserted, the sequence unit 51 starts the transfer.
[0113]
The sequence unit 51 detects the value of the read control signal. When “1” is set, the sequence unit 51 controls the multiplexer of the read buffer unit 55 to store the register of the processor element having the previous PE address. The data to be transferred can be output again. The read buffer unit 55 transfers the data to the image memory 6 to the RAM control unit 53 until all the data for the four processor elements read from the image memory 6 are unnecessary, except for exceptions at the start and end of the transfer. Since the read data transfer request is not output (for example, if the read control is always “0”, the data transfer port is accessed twice, and no data is required while the read control signal is 1). The updating of the address pointer and the output of the clock, read / write control, and byte select to the image memory 6 are not performed until all the data for the four processor elements are unnecessary. Data writing to the external interface 4 of the SIMD processor 1 continues regardless of the read control signal.
[0114]
In the above-described embodiment, the data can be transferred to the processor element 3a to which the even number of the SIMD processor 1 is assigned, and the data can be transferred to the processor element 3a to which the odd number is assigned. However, the transfer of image data to the SIMD processor 1 is not limited to this method. For example, as shown in FIG. 13, the present invention can also be applied to a configuration in which the processor element 3a of the SIMD processor 1 is configured to sequentially transfer data by address designation without distinguishing between odd and even. That is, as shown in FIG. 11, the register controller 31a is connected to the external interface 4 via the address bus 41a, the read / write signal 45c, and the clock signal 41c. When the register controller 31a is supplied from the memory controller 5 to the external interface 4 and receives an address designation signal via the address bus 41a, the register controller 31a decodes the address designation signal. If the decoded address matches the address assigned to its own processor element 3a, it is given from the memory controller 5 to the external interface 4 and read / read in synchronization with the clock signal from the clock signal 41c. A read / write instruction signal sent from the memory controller 5 is obtained via the write signal 41b. This read / write instruction signal is applied to the register 31b.
[0115]
In this embodiment, data stored in the image memory 6 provided outside the SIMD type processor 1 is placed on the data bus 46c as 8-bit parallel data. The data bus 46c is also used when the processed data held in the register 31b is sent to the image memory 6 provided outside the SIMD type processor 1.
[0116]
Address, read / write, clock, and data signals given from the external interface 4 are supplied to each register of the register file 31. Then, the address is decoded for each processor element 3a..., And only the processor element 3a that matches the address indicating each processor element 3a.
[0117]
When the memory controller 5 sends the data stored in the image memory 6 to the processor element 3a, the SIMD processor 1 configured as described above designates the address assigned to the processor element 3a once. Is input to the designated processor element 3a. In this example, since data is not simultaneously sent to the even and odd processor elements 3a, the data transfer takes time compared to the first embodiment, but the circuit configuration can be simplified.
[0118]
In the above-described embodiment, the processor element 3a is addressed. However, the present invention can be applied not only to a method of addressing the designation of the processor element 3a but also to a method of specifying a pointer, that is, a serial access memory method. This example will be described with reference to FIG. Here, the points different from the first embodiment described above will be described, and the description of the same points will be omitted. Moreover, the same code | symbol is attached | subjected about the same component as 1st Embodiment mentioned above.
[0119]
First, an I / O address, data, and control signal are given from the global processor 2 to the memory controller 5 via a bus. The global processor 2 sets commands such as an operation method in some operation setting registers (not shown) of the memory controller 5. Finally, the global processor 2 writes a start code in a start register (not shown) of the memory controller 5 so that the memory controller 5 automatically performs an operation according to the setting. The memory controller 5 generates this reset signal based on the command of the global processor 2 and sends it to the processor element block 3 from the external interface 4 via the reset signal 47. As a result, the register controller 31a is reset. Then, a clock signal is sent from the memory controller 5 to the register controller 31a closest to the external interface 4 via the external interface 4 and the clock signal 41c. In synchronization with this clock signal, the register controller 31a ′ obtains a read / write instruction signal sent from the memory controller 5 via the read / write signal 45a or 45b. This read / write instruction signal is applied to the register 31b of the processor element 3a to which the even number is assigned and to the register 31b of the processor element 3a to which the odd number is assigned. At this time, the read / write instruction signals sent to the register controller 31a ′ of the processor element 3a constituting one set may be different from those in the first embodiment.
[0120]
As a result, as in the case of the first embodiment described above, data can be transferred to the processor element 3a to which the even number is assigned by one pointer designation, and can also be transferred to the processor element 3a to which the odd number is assigned.
[0121]
FIG. 15 is a block diagram showing the configuration of another embodiment of the image processing apparatus including the memory controller 5 of the present invention described above. In FIG. 15, a memory controller 5 is arranged between data transfer ports of two independent register files 3. The present invention can also be applied to such a configuration.
[0122]
【The invention's effect】
As described above, according to the first aspect of the present invention, even when the number of processor elements is smaller than the number of pixels in the main scanning direction, the SIMD processor can easily perform calculations, and filter processing and the like. Only effective pixels can be transferred when performing the weighting calculation.
[0123]
According to the second aspect of the present invention, a line memory can be realized using a single port memory in an image processing system using a SIMD type processor.
[0124]
According to the third aspect of the present invention, when a SIMD type processor having a smaller number of processor elements than the number of pixels in the main scanning direction is used, when performing a weighting operation such as filter processing, only effective pixels are transferred. can do.
[0125]
According to the fourth aspect of the present invention, when a SIMD processor having a smaller number of processor elements than the number of pixels in the main scanning direction is used, when performing a weighting operation such as filter processing, the reference pixel data Can be transferred together.
[0126]
According to the invention described in claim 5, in the case of image processing having a plurality of processing steps, data can be stored for each processing step.
[0127]
According to the sixth and seventh aspects of the present invention, the time for transferring the data in the general-purpose registers of all the processor elements can be halved. Further, it is possible to provide a margin for the RAM access time.
[0128]
According to the inventions described in claims 8 and 9, since the scaling process in the digital image processing is realized by the memory controller, the versatility and circuit scale of the SIMD type processor itself can be maintained.
[0129]
According to the invention described in claim 10, when an image processing apparatus such as a digital copy having a very large number of pixels in the main scanning direction is realized, the architecture of the SIMD processor, such as increasing or decreasing the number of processor elements, is changed. It is possible to construct an image processing apparatus without any problems.
[Brief description of the drawings]
FIG. 1 is a block diagram showing a SIMD type processor according to an embodiment of the present invention.
FIG. 2 is a block diagram showing an internal configuration of a SIMD type processor according to the first embodiment of the present invention.
FIG. 3 is a block diagram showing an internal configuration of a processor element according to the first embodiment of the present invention.
FIG. 4 is a block diagram showing a configuration of a memory controller 5 used in the present invention.
FIG. 5 is a schematic block diagram of an embodiment of a processor element (PE) control unit 52 of the memory controller 5 used in the present invention.
FIG. 6 is a schematic block diagram of a first embodiment of a memory (RAM) control unit 53 of the memory controller 5 used in the present invention.
FIG. 7 is an explanatory diagram of a pixel data transfer method in the case of using a SIMD type processor having a smaller number of processor elements 3a than the number of pixels in the main scanning direction.
FIG. 8 is a schematic block diagram showing a second embodiment of a RAM controller 53 of the memory controller 5 used in the present invention.
FIG. 9 is a schematic block diagram showing a third embodiment of a RAM control unit 53 of the memory controller 5 used in the present invention.
10 is a schematic block diagram of a write buffer unit 54 and a read buffer unit 55 of the memory controller 5 used in the present invention. FIG.
FIG. 11 is an explanatory diagram of a thinning write operation for realizing reduction in the scaling process.
FIG. 12 is an explanatory diagram of an overlapping read operation in the scaling process.
FIG. 13 is a block diagram showing an internal configuration of a SIMD type processor according to another embodiment of the present invention.
FIG. 14 is a block diagram showing an internal configuration of a SIMD type processor in still another embodiment of the present invention.
FIG. 15 is a schematic block diagram showing another embodiment of the present invention.
FIG. 16 is a schematic block diagram of an image processing apparatus using a conventional SIMD system.
[Explanation of symbols]
1 SIMD type processor
2 Global processor
4 External interface
5 Memory controller
6 Image memory
51 Sequence unit
52 PE controller
53 RAM controller
54 Write buffer
55 Read buffer section

Claims (10)

データを演算処理する演算手段及び当該演算手段で演算処理されるデータを保持するとともに当該演算手段で演算処理されたデータを保持するデータ保持手段を備えるSIMD型プロセッサのプロセッサエレメントと、複数の前記プロセッサエレメントそれぞれに接続されるデータ転送バスと、前記複数のプロセッサエレメントに割り付けられるアドレスに基づき、所定のプロセッサエレメントを指定する指定手段と、この指定手段にアドレスを供給するアドレスバスと、前記複数のプロセッサエレメントが内蔵しているデータ保持手段にプロセッサ外部からアクセスするためのデータ転送用インタフェースと、このデータ転送インタフェースに接続され、前記アドレスバスに供給される前記所定のプロセッサエレメントを指定するためのアドレスを生成するとともに、外部メモリに格納されたデータを読み出して、プロセッサエレメントへデータの書き込みを行うと共に前記プロセッサエレメントからデータを読み出して、前記メモリにデータの書き込みを行うメモリコントローラと、を備え、前記メモリコントローラは、前記データ転送用インタフェースを介して、各プロセッサエレメントのデータ保持手段から前記メモリにデータ転送する場合に、転送を開始するプロセッサエレメントのアドレスと転送を終了するプロセッサエレメントのアドレスを指定し、所定数のデータを除いて、各プロセッサエレメントから演算済みのデータの読み出しを行い、転送を開始するプロセッサエレメントのアドレスに対応するポインタ値を設定し、このポインタ値に基づき前記メモリにこのデータの書き込みを行うと共に、前記メモリからデータ転送用インタフェースを介して各プロセッサエレメントのデータ保持手段にデータ転送する場合に、前段の処理において除いた所定数のデータ数に相当する分のアドレスを戻したポインタ値を設定し、このポインタ値に基づき前記メモリからデータを読み出し、前記ポインタ値に対応して前記アドレスバスに供給される前記所定のプロセッサエレメントを指定するためのアドレスを生成して前記プロセッサエレメントへデータの書き込みを行い、データを分割してSIMD型プロセッサで演算処理を行うことを特徴とする信号処理装置。A processor element of a SIMD type processor having a computing means for computing data, a data holding means for holding data computed by the computing means and holding data computed by the computing means, and a plurality of the processors A data transfer bus connected to each of the elements; designation means for designating a predetermined processor element based on an address assigned to the plurality of processor elements; an address bus for supplying an address to the designation means; and the plurality of processors A data transfer interface for accessing the data holding means incorporated in the element from outside the processor, and an interface for specifying the predetermined processor element connected to the data transfer interface and supplied to the address bus A memory controller that reads data stored in the external memory, writes data to the processor element, reads data from the processor element, and writes data to the memory, and The memory controller specifies the address of the processor element that starts the transfer and the address of the processor element that ends the transfer when transferring data from the data holding means of each processor element to the memory via the data transfer interface. and, except for a predetermined number of data, it has row reading of operation data already from each processor element, and sets a pointer value corresponding to the address of the processor elements to initiate a transfer, before on the basis of this pointer value Symbol Memory Performs writing of data, when said from memory through the interface for data transfer to the data transfer to the data holding means of each processor element, returns the minutes of the address corresponding to the number of data of a predetermined number excluding the preceding processing set the pointer value, it reads data from the memory on the basis of this pointer value, prior to generating the address for specifying the predetermined processor element to be supplied to the address bus in response to said pointer value Symbol A signal processing apparatus, wherein data is written to a processor element, data is divided, and arithmetic processing is performed by a SIMD type processor. 前記メモリコントローラは、前記メモリへの書き込み転送と読み込み転送とを時分割で行い、シングルポートメモリをFIFOもしくはLIFOメモリとして制御することを特徴とする請求項1に記載の信号処理装置。  The signal processing apparatus according to claim 1, wherein the memory controller performs write transfer and read transfer to the memory in a time-sharing manner, and controls the single port memory as a FIFO or LIFO memory. 前記メモリコントローラは、データ転送用インタフェースを介して、各プロセッサエレメントのデータ保持手段から前記メモリにデータ転送する場合に、転送を開始するプロセッサエレメントのアドレスと転送を終了するプロセッサエレメントのアドレスを指定するレジスタを備えることを特徴とする請求項1または2に記載の信号処理装置。  The memory controller designates the address of the processor element that starts the transfer and the address of the processor element that ends the transfer when transferring data from the data holding means of each processor element to the memory via the data transfer interface. The signal processing apparatus according to claim 1, further comprising a register. 前記メモリコントローラは、前記メモリからデータ転送用インタフェースを介して各プロセッサエレメントのデータ保持手段にデータ転送する場合に、転送を終了するプロセッサエレメントのアドレスと、転送終了後にメモリのリードポインタを戻すためのプロセッサエレメントのアドレスを指定するレジスタを備えることを特徴とする請求項1ないし3のいずれかに記載の信号処理装置。  When transferring data from the memory to the data holding means of each processor element via the data transfer interface, the memory controller returns the address of the processor element that ends the transfer and the read pointer of the memory after the transfer ends. 4. The signal processing apparatus according to claim 1, further comprising a register for designating an address of the processor element. 前記メモリコントローラは、メモリの任意のアドレス領域の下限値と上限値をレジスタで設定して、その領域をリング状に使用することを特徴とする請求項1ないし4のいずれかに記載の信号処理装置。  5. The signal processing according to claim 1, wherein the memory controller sets a lower limit value and an upper limit value of an arbitrary address area of the memory by using a register and uses the area in a ring shape. apparatus. 前記データ転送用インタフェースは、偶数のアドレスを持つプロセッサエレメントと奇数のアドレスを持つプロセッサエレメントのデータ保持手段に同時にアクセスすることが可能であることを特徴とする請求項1ないし5のいずれかに記載の信号処理装置。  6. The data transfer interface according to claim 1, wherein the data transfer interface can simultaneously access data holding means of a processor element having an even address and a processor element having an odd address. Signal processing equipment. 前記メモリとの入出力バスのビット幅が前記プロセッサエレメントとのデータ転送ビット幅よりも広く、プロセッサエレメントのデータ転送に対して、メモリとのデータ転送のアクセス時間が長いことを特徴とする請求項1ないし6のいずれかに記載の信号処理装置。  The bit width of the input / output bus with the memory is wider than the data transfer bit width with the processor element, and the access time for data transfer with the memory is longer than the data transfer with the processor element. The signal processing device according to any one of 1 to 6. 前記各プロセッサエレメントのデータ保持手段からデータ転送用インタフェースを介してメモリにデータ転送する場合に、このデータ転送と同期を取った外部からのライト制御信号が”0”である場合にデータを書き込み、”1”である場合にデータの書き込みを禁止することを特徴とする請求項1ないし7のいずれかに記載の信号処理装置。  When data is transferred from the data holding means of each processor element to the memory via the data transfer interface, the data is written when the external write control signal synchronized with the data transfer is “0”. 8. The signal processing apparatus according to claim 1, wherein data writing is prohibited when “1”. 前記メモリからデータ転送用インタフェースを介して各プロセッサエレメントのデータ保持手段にデータ転送する場合に、このデータ転送と同期を取った外部からのリード制御信号が”0”である場合には、前記メモリからデータリードした値をデータ転送用インタフェースに書き込み、”1”の場合には、その転送の前で最後に外部信号が”0”であった場合に転送されたデータと同じ値を前記データ転送用インタフェースに書き込むことを特徴とする請求項1ないし7のいずれかに記載の信号処理装置。  When data is transferred from the memory to the data holding means of each processor element via the data transfer interface, if the external read control signal synchronized with the data transfer is "0", the memory The data read value is written to the data transfer interface, and when it is “1”, the same value as the data transferred when the external signal was “0” last before the transfer is transferred to the data transfer interface. The signal processing apparatus according to claim 1, wherein the signal processing apparatus writes the data into an interface. 前記メモリには画像データが格納され、前記SIMD型プロセッサのプロセッサエレメントの数は主走査方向の画素数よりも少なく構成され、前記メモリコントローラは主走査方向の全画素を2つ以上に分割して処理を行うように、データの書き込み及び読み込みの処理の制御を行うことを特徴とする請求項1ないし7のいずれかに記載の信号処理装置。  Image data is stored in the memory, the number of processor elements of the SIMD processor is configured to be smaller than the number of pixels in the main scanning direction, and the memory controller divides all pixels in the main scanning direction into two or more. The signal processing apparatus according to claim 1, wherein control of data writing and reading processing is performed so as to perform processing.
JP31480699A 1999-11-05 1999-11-05 Signal processing device Expired - Fee Related JP3821198B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP31480699A JP3821198B2 (en) 1999-11-05 1999-11-05 Signal processing device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP31480699A JP3821198B2 (en) 1999-11-05 1999-11-05 Signal processing device

Related Child Applications (1)

Application Number Title Priority Date Filing Date
JP2006001390A Division JP4408113B2 (en) 2006-01-06 2006-01-06 Signal processing method

Publications (2)

Publication Number Publication Date
JP2001134538A JP2001134538A (en) 2001-05-18
JP3821198B2 true JP3821198B2 (en) 2006-09-13

Family

ID=18057836

Family Applications (1)

Application Number Title Priority Date Filing Date
JP31480699A Expired - Fee Related JP3821198B2 (en) 1999-11-05 1999-11-05 Signal processing device

Country Status (1)

Country Link
JP (1) JP3821198B2 (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4403009B2 (en) * 2004-04-30 2010-01-20 株式会社リコー Microprocessor
US7697169B2 (en) * 2004-10-29 2010-04-13 Marvell International Technology Ltd. Laser print apparatus with toner explosion compensation
JP4537420B2 (en) * 2007-04-02 2010-09-01 株式会社リコー SIMD type microprocessor
JP2009238132A (en) * 2008-03-28 2009-10-15 Nec Corp Data processing apparatus
JP5760532B2 (en) * 2011-03-14 2015-08-12 株式会社リコー PROCESSOR DEVICE AND ITS OPERATION METHOD

Also Published As

Publication number Publication date
JP2001134538A (en) 2001-05-18

Similar Documents

Publication Publication Date Title
US5581778A (en) Advanced massively parallel computer using a field of the instruction to selectively enable the profiling counter to increase its value in response to the system clock
AU747283B2 (en) Data processing system for logically adjacent data samples such as image data in a machine vision system
JP3971535B2 (en) SIMD type processor
JPH10187661A (en) Method for entering scalar value of computer into vector
JP2009223758A (en) Image processing apparatus
JP3821198B2 (en) Signal processing device
JP2008077590A (en) Data transfer device
JP4408113B2 (en) Signal processing method
JP2006350907A (en) Simd type microprocessor, data transfer unit, and data conversion unit
JP2007073010A (en) Simd processor and image processing method using the simd method processor and image processor
JP4442905B2 (en) Image data processing method
JP4451433B2 (en) Parallel processor
JP4413905B2 (en) SIMD type processor
JP3971543B2 (en) SIMD type processor
JP3971559B2 (en) Parallel processor and image processing apparatus using the same
JP4294190B2 (en) Parallel processor and image processing apparatus using the same
JP2007206924A (en) Arithmetic processing system
JP2003216950A (en) Simd type microprocessor for performing pattern matching or the like
US20230409323A1 (en) Signal processing apparatus and non-transitory computer-readable storage medium
JP2004206387A (en) Image processing method, processor, and image processor
JP2004252825A (en) Simd type microprocessor capable of transferring data even when fault is occurred in pe
JP2002298135A (en) Thinning device and enlarging device in simd type microprocessor
JP2005148899A (en) Simd-type processor
JPH10334038A (en) Data transfer device
JP2013161325A (en) Simd (single instruction-stream multiple data-stream) type microprocessor, processor system and data processing method for simd type microprocessor

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20040426

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20050317

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20050510

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20050711

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20051108

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20060106

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: 20060613

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20060613

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090630

Year of fee payment: 3

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20100630

Year of fee payment: 4

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110630

Year of fee payment: 5

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110630

Year of fee payment: 5

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120630

Year of fee payment: 6

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130630

Year of fee payment: 7

LAPS Cancellation because of no payment of annual fees