JP4071225B2 - Transfer circuit - Google Patents

Transfer circuit Download PDF

Info

Publication number
JP4071225B2
JP4071225B2 JP2004251832A JP2004251832A JP4071225B2 JP 4071225 B2 JP4071225 B2 JP 4071225B2 JP 2004251832 A JP2004251832 A JP 2004251832A JP 2004251832 A JP2004251832 A JP 2004251832A JP 4071225 B2 JP4071225 B2 JP 4071225B2
Authority
JP
Japan
Prior art keywords
transfer
address
data
circuit
memory
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
JP2004251832A
Other languages
Japanese (ja)
Other versions
JP2006072449A (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.)
Schneider Electric Japan Holdings Ltd
Original Assignee
Digital Electronics Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Digital Electronics Corp filed Critical Digital Electronics Corp
Priority to JP2004251832A priority Critical patent/JP4071225B2/en
Publication of JP2006072449A publication Critical patent/JP2006072449A/en
Application granted granted Critical
Publication of JP4071225B2 publication Critical patent/JP4071225B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Controls And Circuits For Display Device (AREA)
  • Image Input (AREA)
  • Digital Computer Display Output (AREA)
  • Memory System (AREA)

Description

本発明は、メモリ構成の異なるメモリ間で、データ転送毎およびライン毎に指示を出すことなく、矩形領域のデータを転送可能な転送回路に関するものである。   The present invention relates to a transfer circuit capable of transferring data in a rectangular area between memories having different memory configurations without giving an instruction for each data transfer and for each line.

従来から、情報処理装置において、画像処理や画像表示にあたって、メインメモリと他のメモリ(例えば、バッファやビデオメモリなど)との間で、画面のデータを転送することが広く行われている。   2. Description of the Related Art Conventionally, in image processing and image display in information processing apparatuses, screen data is widely transferred between a main memory and another memory (for example, a buffer or a video memory).

例えば、後述する特許文献1では、図19に示すように、作業領域として、1次元的なアドレスによってアクセス可能なバッファ515を複数設けておき、ALU511が、バッファ515(1)の画像データにアクセスしてフィルタリングなどの処理をしている間に、DMAC516が、他方のバッファ515(2)へメインメモリ502の画像データを持ってくる情報処理装置が開示されている。さらに、当該情報処理装置は、バッファ515(1)の画像データに対するフィルタリングなどの処理が終わると、DMAC516の動作によって、処理終了後のバッファ515(1)の画像データをメインメモリ502に格納させることができ、この格納と同時に、ALU511はバッファ515(2)に対する画像処理を行うことができる。つまり、データ処理とデータ転送を並行して行うことができる。   For example, in Patent Document 1 described later, as shown in FIG. 19, a plurality of buffers 515 accessible by one-dimensional addresses are provided as work areas, and the ALU 511 accesses the image data in the buffer 515 (1). Thus, an information processing apparatus is disclosed in which the DMAC 516 brings the image data of the main memory 502 to the other buffer 515 (2) while performing processing such as filtering. Further, when processing such as filtering on the image data in the buffer 515 (1) is completed, the information processing apparatus stores the image data in the buffer 515 (1) after the processing in the main memory 502 by the operation of the DMAC 516. Simultaneously with this storage, the ALU 511 can perform image processing on the buffer 515 (2). That is, data processing and data transfer can be performed in parallel.

上記情報処理装置では、メインメモリ502の画像データをバッファ515の1つへ転送する場合に、以下の処理が行われる。すなわち、メインメモリ502のプログラムデータに基づき、ALU511は、2次元アドレスを生成してDMAC516に供給する。DMAC516内のアドレス変換回路661は、2次元アドレスからメインメモリ502の画像データをアクセスするための1次元アドレスに変換してメインメモリ502に供給する。メインメモリ502から読み出された画像データは、バッファ515に与えられる。ALU511は、プログラムデータに基づき、バッファ515に画像データを格納するための2次元アドレスを生成してアドレス変換回路514に与える。アドレス変換回路514は、1次元アドレスに変換してバッファ515に与えてメインメモリ502からの画像データを格納する。
特開平6−231035号公報(公開日:1994年8月19日)
In the information processing apparatus, when image data in the main memory 502 is transferred to one of the buffers 515, the following processing is performed. That is, based on the program data in the main memory 502, the ALU 511 generates a two-dimensional address and supplies it to the DMAC 516. An address conversion circuit 661 in the DMAC 516 converts the two-dimensional address into a one-dimensional address for accessing the image data in the main memory 502 and supplies the converted data to the main memory 502. The image data read from the main memory 502 is given to the buffer 515. The ALU 511 generates a two-dimensional address for storing the image data in the buffer 515 based on the program data, and gives it to the address conversion circuit 514. The address conversion circuit 514 converts the image data into a one-dimensional address, gives it to the buffer 515, and stores the image data from the main memory 502.
Japanese Patent Laid-Open No. 6-231035 (Publication date: August 19, 1994)

しかしながら、上記従来の構成では、データ転送の度にALUがアドレスを生成する構成であり、ALUの負担が大きくなってしまう。特に、汎用のコンピュータなどにおいて、転送の対象とするデータをCPUが指定する構成において、CPUが、この処理を行おうとすると、CPUの負担が重くなるだけではなく、メモリの転送速度に間に合わなくなり、データ転送速度が低下してしまう。さらに、上記従来の構成では、バッファには、データが連続して格納されており、他のメモリ構成(他のデータの格納方法)のメモリに転送することができない。   However, in the above conventional configuration, the ALU generates an address every time data is transferred, which increases the burden on the ALU. In particular, in a general-purpose computer or the like in which the CPU designates data to be transferred, if the CPU tries to perform this processing, it not only increases the burden on the CPU but also fails to meet the memory transfer speed, Data transfer speed will decrease. Furthermore, in the above conventional configuration, data is continuously stored in the buffer, and cannot be transferred to a memory having another memory configuration (another data storage method).

本発明は、上記の問題点に鑑みてなされたものであり、その目的は、メモリ構成の互いに異なるメモリ間で、任意の矩形領域内のデータを高速にデータ転送可能な転送回路を実現することにある。   The present invention has been made in view of the above problems, and an object thereof is to realize a transfer circuit capable of transferring data in an arbitrary rectangular area at high speed between memories having different memory configurations. It is in.

本発明に係る転送回路は、上記課題を解決するために、転送元メモリにて、隣接するライン間の開始アドレス同士の差を示すアドレス差情報を格納する転送元アドレス差レジスタと、転送先メモリにて、隣接するライン間の開始アドレス同士の差を示すアドレス差情報を格納する転送先アドレス差レジスタと、上記転送元メモリの指示されたアドレスから、上記転送先メモリの指示されたアドレスへとデータを転送する転送処理回路と、上記転送処理回路によるデータ転送毎に、次にデータ転送すべき転送元メモリのアドレスを算出して、上記転送処理回路へ指示する転送元アドレス算出回路と、上記転送処理回路によるデータ転送毎に、次にデータ転送すべき転送先メモリのアドレスを算出して、上記転送処理回路へ指示する転送先アドレス算出回路と、上記転送処理回路によるデータ転送毎に、現ラインにおける矩形領域の転送が終了したか否かを判定する判定回路とを備え、上記各アドレス算出回路は、上記判定回路が現ラインの矩形領域の転送が終了したと判断した場合、上記各アドレス差レジスタのうち、それぞれに対応するアドレス差レジスタに格納されたアドレス差情報を参照して、上記矩形領域の次のラインにおける開始アドレスを算出し、次にデータ転送すべきアドレスとして出力することを特徴としている。なお、上記ラインとしては、水平ラインまたは垂直ラインなどが挙げられる。   In order to solve the above problems, a transfer circuit according to the present invention includes a transfer source address difference register for storing address difference information indicating a difference between start addresses between adjacent lines and a transfer destination memory in the transfer source memory. And a transfer destination address difference register for storing address difference information indicating a difference between start addresses between adjacent lines, and from an address specified by the transfer source memory to an address specified by the transfer destination memory. A transfer processing circuit for transferring data, a transfer source address calculating circuit for calculating an address of a transfer source memory to be next transferred for each data transfer by the transfer processing circuit, and instructing the transfer processing circuit; Each time data is transferred by the transfer processing circuit, the address of the transfer destination memory to which data is to be transferred next is calculated and the transfer destination address for instructing the transfer processing circuit is calculated. A calculation circuit; and a determination circuit for determining whether or not the transfer of the rectangular area in the current line is completed for each data transfer by the transfer processing circuit, and each of the address calculation circuits includes the determination circuit of the current line. If it is determined that the transfer of the rectangular area has been completed, the address difference information stored in the address difference register corresponding to each of the address difference registers is referred to, and the start address in the next line of the rectangular area is determined. It is characterized in that it is calculated and output as an address to be transferred next. Examples of the line include a horizontal line and a vertical line.

上記構成では、各アドレス算出回路は、上記判定回路が現ラインの矩形領域の転送が終了したと判断した場合、それぞれのアドレス差情報を参照して、次のラインの開始アドレスを算出し、次にデータ転送すべきアドレスとして出力する。したがって、矩形領域を構成するライン毎、および、データ処理部によるデータ転送毎に、転送回路の外部に設けられた外部回路(例えば、CPUなど)が指示する構成とは異なって、転送回路は、何ら支障なく、転送元のメモリから転送先のメモリへと、矩形領域のデータを転送できる。この結果、上記ライン毎あるいはデータ転送毎に外部回路が転送回路へ指示することに起因するオーバーヘッドの発生を防止できる。   In the above configuration, each address calculation circuit calculates the start address of the next line by referring to the respective address difference information when the determination circuit determines that the transfer of the rectangular area of the current line is completed. Is output as an address to which data is to be transferred. Therefore, unlike the configuration instructed by an external circuit (for example, a CPU) provided outside the transfer circuit for each line constituting the rectangular area and for each data transfer by the data processing unit, the transfer circuit includes: The rectangular area data can be transferred from the transfer source memory to the transfer destination memory without any problem. As a result, it is possible to prevent the overhead caused by the external circuit instructing the transfer circuit for each line or each data transfer.

また、上記転送元アドレス差レジスタと転送先アドレス差レジスタとが別々に設けられているので、各レジスタに予め値を設定しておくことで、転送元のメモリ構成(隣接するライン間の開始アドレス差)が互いに異なる転送元メモリから転送先メモリへ、任意の矩形領域のデータを転送できる。   In addition, since the transfer source address difference register and the transfer destination address difference register are provided separately, by setting a value in each register in advance, the memory configuration of the transfer source (the start address between adjacent lines) Data in an arbitrary rectangular area can be transferred from a transfer source memory having a different difference) to a transfer destination memory.

これらの結果、メモリ構成の互いに異なるメモリ間で、任意の矩形領域内のデータを高速にデータ転送可能な転送回路を実現できる。特に、各レジスタが上記外部回路から設定可能であれば、動作中にメモリ構成が変化して、隣接するライン間の開始アドレス差が変化する場合であっても、上記各アドレス差レジスタの値を適切に設定し直すことによって、転送回路は、何ら支障なく、任意の矩形領域内のデータを高速にデータ転送できる。   As a result, a transfer circuit capable of transferring data in an arbitrary rectangular area at high speed between memories having different memory configurations can be realized. In particular, if each register can be set from the external circuit, even if the memory configuration changes during operation and the start address difference between adjacent lines changes, the value of each address difference register is changed. By appropriately resetting, the transfer circuit can transfer data in an arbitrary rectangular area at high speed without any trouble.

さらに、上記構成に加えて、上記転送処理回路は、上記転送元および転送先の少なくとも一方のメモリの複数アドレスのデータを一括して転送してもよい。なお、一括転送の方法としては、例えば、バースト転送などが挙げられる。   Further, in addition to the above configuration, the transfer processing circuit may collectively transfer data at a plurality of addresses in at least one of the transfer source memory and the transfer destination memory. An example of the batch transfer method is burst transfer.

上記構成では、転送処理回路が、複数アドレスのデータを一括転送するので、アドレス毎にデータ転送する構成と比較して、転送処理回路がメモリにアドレスを指定する回数を削減できる。したがって、アドレス毎にデータ転送する構成よりも、高速に転送可能な転送回路を実現できる。   In the above configuration, since the transfer processing circuit collectively transfers data at a plurality of addresses, the number of times the transfer processing circuit designates an address in the memory can be reduced as compared with a configuration in which data is transferred for each address. Therefore, it is possible to realize a transfer circuit that can transfer data at a higher speed than a configuration in which data is transferred for each address.

さらに、上記構成に加えて、上記転送処理回路は、上記転送元メモリから転送先メモリへデータ転送可能であってもよい。上記構成では、転送元メモリから転送先メモリにもデータ転送できる。したがって、例えば、基本的には、メインメモリからビデオメモリにデータ転送する構成ではあるが、ビデオキャプチャ回路など、ビデオメモリに直接データを書き込む回路によって書き込まれたデータを、メインメモリに転送して、当該データを、外部回路が参照する用途などにも使用できる。   Further, in addition to the above configuration, the transfer processing circuit may be capable of transferring data from the transfer source memory to the transfer destination memory. In the above configuration, data can be transferred from the transfer source memory to the transfer destination memory. Therefore, for example, although it is basically configured to transfer data from the main memory to the video memory, data written by a circuit that directly writes data to the video memory, such as a video capture circuit, is transferred to the main memory, The data can also be used for applications that are referred to by an external circuit.

本発明によれば、メモリ構成の互いに異なるメモリ間で、任意の矩形領域内のデータを高速にデータ転送可能な転送回路を実現できるので、例えば、メインメモリとビデオメモリとの間のデータ転送をはじめとして、種々のメモリ間のデータ転送を行う転送回路として、広く好適に使用できる。   According to the present invention, a transfer circuit capable of transferring data in an arbitrary rectangular area at high speed between memories having different memory configurations can be realized. For example, data transfer between a main memory and a video memory can be performed. First, it can be used widely and suitably as a transfer circuit for transferring data between various memories.

〔第1の実施形態〕
本発明の一実施形態について図1ないし図12に基づいて説明すると以下の通りである。すなわち、本実施形態に係る情報処理装置1は、複数の互いに異なる蓄積方法で、画像のデータを蓄積しているメモリ間で、画像の任意の矩形領域のデータを高速に転送可能な装置であって、図2に示すように、上記画像のデータを蓄積するメモリとして、メインメモリ2と、ビデオメモリ3とを備えている。
[First Embodiment]
An embodiment of the present invention will be described below with reference to FIGS. That is, the information processing apparatus 1 according to the present embodiment is an apparatus that can transfer data in an arbitrary rectangular area of an image at high speed between memories that store image data using a plurality of different storage methods. As shown in FIG. 2, a main memory 2 and a video memory 3 are provided as memories for storing the image data.

上記ビデオメモリ3は、グラフィックコントローラ4が表示装置5へ出力する映像信号を生成するために参照するものであって、比較的小規模な回路で、高速に各画素のデータを読み出すことができるようにするため、例えば、図3に示すように、画像の各ラインのデータは、互いに隣接する2つのラインのデータの開始アドレス同士の差が2n で表現できるように配置されている。なお、このように各ラインのデータを配置すると、画素の解像度(画素数)によっては、次のラインの最初の画素のデータを格納したアドレス(次のラインの開始アドレス)が、あるラインの末尾の画素のデータを格納したアドレスに連続しなくなることもあるが、この場合、当該アドレス(末尾のアドレス)の次のアドレスから、次のラインの開始アドレスの直前までの記憶領域は、使用されない。 The video memory 3 is referred to by the graphic controller 4 to generate a video signal to be output to the display device 5, and can read data of each pixel at high speed with a relatively small circuit. Therefore, for example, as shown in FIG. 3, the data of each line of the image is arranged so that the difference between the start addresses of the data of two adjacent lines can be expressed by 2 n . If the data of each line is arranged in this way, depending on the pixel resolution (number of pixels), the address (start address of the next line) storing the data of the first pixel of the next line is the end of a certain line. However, in this case, the storage area from the address next to the address (end address) to immediately before the start address of the next line is not used.

例えば、図3は、水平解像度が800画素の画像をビデオメモリ3に格納している状態を示している。図3では、互いに隣接する2つのラインのデータの開始アドレス同士の差が210で表現できるように、各ラインのデータが配置され、1ワード(1アドレス分の記憶領域)に、1画素分のデータが格納されている場合を例示している。したがって、ある水平ライン分の画像データは、ビデオメモリ3のA001h〜A320hに格納され、次の水平ライン分の画像データは、A401h〜A720hに格納されている。 For example, FIG. 3 shows a state where an image having a horizontal resolution of 800 pixels is stored in the video memory 3. In FIG. 3, the data of each line is arranged so that the difference between the start addresses of the data of two adjacent lines can be represented by 2 10 , and one pixel (one address storage area) corresponds to one pixel. The case where the data of this is stored is illustrated. Accordingly, image data for a certain horizontal line is stored in A001h to A320h of the video memory 3, and image data for the next horizontal line is stored in A401h to A720h.

当該構成では、基準とするラインの次のラインの開始アドレスを算出する際、基準とするラインの開始アドレスのうち、予め定められた上位ビットをインクリメントし、残余の下位ビットを連結すれば、次のラインの開始アドレスを算出できる。したがって、グラフィックコントローラ4が所定の周期(例えば、1フレーム期間毎など)毎に、画像の各画素の輝度を示す映像信号をそれぞれ出力する場合のように、高速なアクセスが必要な場合であっても、グラフィックコントローラ4を、比較的小規模な回路で実現できる。   In this configuration, when calculating the start address of the next line of the reference line, the next higher bit is incremented and the remaining lower bits of the reference line start address are concatenated. The start address of the line can be calculated. Therefore, when the graphic controller 4 outputs a video signal indicating the luminance of each pixel of the image every predetermined cycle (for example, every one frame period), it is a case where high-speed access is necessary. However, the graphic controller 4 can be realized with a relatively small circuit.

一方、本実施形態に係るメインメモリ2は、主として、情報処理装置1のCPU6によりアクセスされるメモリであって、図4に示すように、ある水平ラインの画像データは、その前の水平ラインの画像データが格納されているアドレスに連続するアドレスに格納されている。   On the other hand, the main memory 2 according to the present embodiment is a memory that is mainly accessed by the CPU 6 of the information processing apparatus 1. As shown in FIG. 4, image data of a certain horizontal line is stored in the previous horizontal line. It is stored at an address continuous to the address where the image data is stored.

例えば、図4は、図3と同様に、水平解像度が800画素で、1画素のデータが1ワードで表現されている場合を例示しているが、図3とは異なって、ある水平ライン分の画像データは、メインメモリ2のA001h〜A320hに格納され、次の水平ライン分の画像データはA321h〜A640hに格納されている。   For example, FIG. 4 exemplifies the case where the horizontal resolution is 800 pixels and the data of one pixel is expressed by one word, as in FIG. 3. Is stored in A001h to A320h of the main memory 2, and the image data for the next horizontal line is stored in A321h to A640h.

さらに、本実施形態に係る情報処理装置1には、図2に示すように、メインメモリ2とビデオメモリ3との双方にアクセス可能な転送回路11が設けられており、当該転送回路11は、CPU6などの外部回路からの指示に従って、画像中の指示された矩形領域A(図5参照)のデータを、メインメモリ2からビデオメモリ3へ、あるいは、ビデオメモリ3からメインメモリ2へ転送することができる。   Further, as shown in FIG. 2, the information processing apparatus 1 according to the present embodiment includes a transfer circuit 11 that can access both the main memory 2 and the video memory 3. In accordance with an instruction from an external circuit such as the CPU 6, the data of the designated rectangular area A (see FIG. 5) in the image is transferred from the main memory 2 to the video memory 3 or from the video memory 3 to the main memory 2. Can do.

本実施形態に係る転送回路11は、予め転送指示として、矩形領域の幅(画素数)および高さ(ライン数)と、転送元のメモリにおける開始アドレス、および、転送元のメモリにおける各ラインの開始アドレスの差と、転送先のメモリにおける開始アドレス、および、転送先のメモリにおける各ラインの開始アドレスの差とを受け取っており、矩形領域を構成する水平ライン毎に転送指示を受け取らなくても、矩形領域を構成する各水平ライン毎に、以下の処理、すなわち、転送元および転送先のメモリの双方における当該ラインの開始アドレスの算出処理と、当該ラインを構成する各画素のデータの転送処理とを繰り返すことができる。これにより、転送回路11は、矩形領域の位置および大きさ、並びに、転送元および転送先のメモリにおける各ラインの開始アドレスの差に拘わらず、矩形領域を構成する水平ライン毎に転送指示を受け取ることなく、矩形領域のデータを転送することができる。   The transfer circuit 11 according to the present embodiment, as a transfer instruction in advance, has a rectangular area width (number of pixels) and height (number of lines), a start address in the transfer source memory, and each line in the transfer source memory. The start address difference, the start address in the transfer destination memory, and the start address difference of each line in the transfer destination memory are received, and it is not necessary to receive a transfer instruction for each horizontal line constituting the rectangular area. For each horizontal line constituting the rectangular area, the following processing, that is, calculation processing of the start address of the line in both the transfer source memory and the transfer destination memory, and transfer processing of the data of each pixel constituting the line Can be repeated. As a result, the transfer circuit 11 receives a transfer instruction for each horizontal line constituting the rectangular area regardless of the position and size of the rectangular area and the difference in the start address of each line in the transfer source and transfer destination memories. The data in the rectangular area can be transferred without any problem.

具体的には、本実施形態に係る転送回路11は、図1に示すように、矩形領域の幅(画素数)および高さ(ライン数)をそれぞれ格納する幅および高さレジスタ21・22と、メインメモリ2における矩形領域の開始アドレス、および、メインメモリ2における隣接する水平ラインの開始アドレス同士の差を、それぞれ格納する開始アドレスおよびアドレス差レジスタ23・24と、ビデオメモリ3における矩形領域の開始アドレス、および、ビデオメモリ3における隣接する水平ラインの開始アドレス同士の差を、それぞれ格納する開始アドレスおよびアドレス差レジスタ25・26とを備えている。なお、上記各アドレス差レジスタ24・26が特許請求の範囲に記載の転送元および転送先アドレス差レジスタにそれぞれ対応する。   Specifically, as shown in FIG. 1, the transfer circuit 11 according to the present embodiment includes width and height registers 21 and 22 for storing the width (number of pixels) and height (number of lines) of a rectangular area, respectively. The difference between the start address of the rectangular area in the main memory 2 and the start address of the adjacent horizontal line in the main memory 2 is stored, and the start address and address difference registers 23 and 24, respectively, There are provided start address and address difference registers 25 and 26 for storing the start address and the difference between the start addresses of adjacent horizontal lines in the video memory 3, respectively. The address difference registers 24 and 26 correspond to the transfer source and transfer destination address difference registers described in the claims.

ここで、上記各開始アドレスレジスタ23・25に格納される値(矩形領域の開始アドレス)は、メインメモリ2およびビデオメモリ3において、矩形領域のデータ転送全体の開始アドレスであって、本実施形態では、一例として、矩形領域の左上を基点にしてデータ転送を開始しているので、上記矩形領域の開始アドレスは、矩形領域の左上の画素のデータが格納されるアドレスになる。   Here, the value (starting address of the rectangular area) stored in each of the starting address registers 23 and 25 is the starting address of the entire data transfer in the rectangular area in the main memory 2 and the video memory 3, and this embodiment Then, as an example, since data transfer is started with the upper left corner of the rectangular area as a base point, the start address of the rectangular area is an address in which the data of the upper left pixel of the rectangular area is stored.

さらに、上記転送回路11には、メインメモリ2の指示されたアドレスとビデオメモリ3の指示されたアドレスとの間で、データ転送を行う転送処理部(転送処理回路)31と、上記幅および高さレジスタ21・22の値を参照して、当該転送処理部31によるデータ転送が終了する毎に、転送対象となる画素の位置している水平ラインにおいて当該画素が矩形領域の終端(この例では、右端)に到達したか否かと、矩形領域全体のデータ転送が終了したか否かとを判定し、判定結果を制御信号S1として出力すると共に、矩形領域のデータ転送が終了していないと判定した場合は、上記転送処理部31へ次のデータ転送を指示する転送制御部(判定回路)32と、上記開始アドレスおよびアドレス差レジスタ23・24に格納された値と矩形領域の転送(BitBlt)が指示されたか否かと上記制御信号S1と上記転送処理部31からの制御信号S5が転送元となるメモリ(この場合は、メインメモリ2)からの読み出し終了を示しているか否かとに基づいて、メインメモリ2において次にデータを転送するアドレスを算出し、当該アドレスを示すアドレス信号A1を上記転送処理部31へ出力するメインメモリアドレス算出部(転送元アドレス算出回路)33と、上記開始アドレスおよびアドレス差レジスタ25・26に格納された値と矩形領域の転送が指示されたか否かと上記制御信号S1とに基づいて、ビデオメモリ3において次にデータを転送するアドレスを算出し、当該アドレスを示すアドレス信号A2を上記転送処理部31へ出力するビデオメモリアドレス算出部(転送先アドレス算出回路)34とを備えている。   Furthermore, the transfer circuit 11 includes a transfer processing unit (transfer processing circuit) 31 that performs data transfer between the specified address of the main memory 2 and the specified address of the video memory 3, and the width and height. Each time the data transfer by the transfer processing unit 31 is completed with reference to the values of the registers 21 and 22, the pixel is located at the end of the rectangular area (in this example, in the horizontal line where the pixel to be transferred is located). , Right end) and whether or not the data transfer of the entire rectangular area is completed, and the determination result is output as the control signal S1, and it is determined that the data transfer of the rectangular area is not completed. In this case, the transfer control unit (determination circuit) 32 instructing the transfer processing unit 31 to transfer the next data, and the values stored in the start address and address difference registers 23 and 24 and the Whether the area transfer (BitBlt) has been instructed, and whether the control signal S1 and the control signal S5 from the transfer processing unit 31 indicate the end of reading from the transfer source memory (in this case, the main memory 2). The main memory 2 calculates a next data transfer address in the main memory 2 and outputs an address signal A1 indicating the address to the transfer processing unit 31. Based on the start address and the value stored in the address difference registers 25 and 26, whether or not the transfer of the rectangular area is instructed, and the control signal S1, the address for the next data transfer in the video memory 3 is calculated. And a video memory address calculation unit that outputs an address signal A2 indicating the address to the transfer processing unit 31. And a transfer destination address calculating circuit) 34.

なお、上記各アドレス算出部33・34は、矩形領域の転送開始指示を直接受け取ってもよいが、本実施形態では、転送制御部32は、矩形領域の転送開始指示を受け取り、制御信号S2によって、上記各アドレス算出部33・34へ伝えている。また、転送制御部32は、上記転送制御部32への転送指示を、各アドレス算出部33・34を介して通知してもよいが、本実施形態では、転送制御部32は、転送処理部31への制御信号S3によってデータ転送を指示している。また、転送制御部32は、転送処理部31の入出力信号を監視したり、予め定められた時間が経過したか否かを判定したりして、当該転送処理部31によるデータ転送が終了したか否かを検出してもよいが、本実施形態では、データ転送を終了する度に、転送処理部31が転送終了を示す制御信号S4を出力しており、転送制御部32は、当該制御信号S4に基づいて、転送処理部31によるデータ転送が終了したか否かを検出している。なお、本実施形態では、後述する制御部43が制御信号S2およびS3を生成している。   The address calculation units 33 and 34 may directly receive a rectangular area transfer start instruction. However, in this embodiment, the transfer control unit 32 receives the rectangular area transfer start instruction and receives a control signal S2. To the address calculation units 33 and 34. Further, the transfer control unit 32 may notify the transfer instruction to the transfer control unit 32 via each of the address calculation units 33 and 34. However, in this embodiment, the transfer control unit 32 uses the transfer processing unit. Data transfer is instructed by a control signal S3 to 31. Further, the transfer control unit 32 monitors the input / output signal of the transfer processing unit 31 or determines whether or not a predetermined time has elapsed, and the data transfer by the transfer processing unit 31 is completed. In this embodiment, every time data transfer ends, the transfer processing unit 31 outputs a control signal S4 indicating transfer end, and the transfer control unit 32 performs the control. Based on the signal S4, it is detected whether or not the data transfer by the transfer processing unit 31 is completed. In the present embodiment, a control unit 43 described later generates control signals S2 and S3.

上記転送制御部32は、図6に示すように、転送対象となる画素の位置している水平ライン(現水平ライン)において、これまでに転送した画素数を記憶する幅カウンタ41と、これまでに転送した水平ライン数を記憶するライン数カウンタ42と、当該両カウンタ41・42のカウント値、矩形領域のデータ転送が指示されたか否かを示す制御、および、転送処理部31によるデータ転送が終了したことを示す信号(この例では、制御信号S4)に基づいて、当該転送処理部31によるデータ転送が終了する毎に、上記制御信号S1を生成すると共に、各カウンタ41・42を制御する制御部43とを備えている。   As shown in FIG. 6, the transfer control unit 32 includes a width counter 41 for storing the number of pixels transferred so far in the horizontal line (current horizontal line) where the pixel to be transferred is located, The line number counter 42 for storing the number of horizontal lines transferred to the counter, the count values of the counters 41 and 42, the control indicating whether or not the data transfer of the rectangular area is instructed, and the data transfer by the transfer processing unit 31 Based on a signal indicating the completion (in this example, the control signal S4), the control signal S1 is generated and the counters 41 and 42 are controlled each time the data transfer by the transfer processing unit 31 is completed. And a control unit 43.

上記制御部43は、例えば、CPU6などの外部回路から、矩形領域のデータ転送が指示された場合、上記各カウンタ41・42をリセットできる。また、上記制御部43は、制御信号S4を受け取る度に、上記各カウンタ41・42のカウント値と、上記両レジスタ21・22の値とをそれぞれ比較して、現水平ラインにおいて矩形領域の終端に到達したか否かと、矩形領域全体のデータ転送が終了したか否かとを示す制御信号S1を生成できる。   The control unit 43 can reset the counters 41 and 42 when, for example, an external circuit such as the CPU 6 instructs data transfer in a rectangular area. Each time the control unit 43 receives the control signal S4, the control unit 43 compares the count values of the counters 41 and 42 with the values of the registers 21 and 22, respectively, and ends the rectangular area on the current horizontal line. A control signal S1 indicating whether or not the data transfer of the entire rectangular area has been completed can be generated.

さらに、上記制御部43は、終端に到達していないと判定した場合、上記幅カウンタ41のカウント値をデータ転送した画素数だけインクリメントすると共に、終端に到達したと判定した場合は、上記幅カウンタ41をリセットできる。なお、本実施形態では、転送処理部31は、1画素ずつ、データ転送しているので、制御部43は、幅カウンタ41を1インクリメントする。   Further, when the control unit 43 determines that the end has not been reached, the control unit 43 increments the count value of the width counter 41 by the number of pixels to which data has been transferred. 41 can be reset. In this embodiment, since the transfer processing unit 31 transfers data pixel by pixel, the control unit 43 increments the width counter 41 by one.

また、上記制御部43は、終端に到達したと判定し、しかも、矩形領域全体のデータ転送が終了していないと判定した場合は、上記ライン数カウンタ42のカウント値を1インクリメントできる。   The control unit 43 can increment the count value of the line number counter 42 by 1 when determining that the end has been reached and determining that the data transfer of the entire rectangular area has not ended.

一方、上記メインメモリアドレス算出部33は、図7に示すように、現水平ラインにおける矩形領域の始端(この例では、左端)のアドレス(ライン開始アドレス)を記憶するライン開始アドレスレジスタ51と、転送対象とする画素のメインメモリ2におけるアドレス(現アドレス)を記憶すると共に、記憶されたアドレスを上記アドレス信号A1として出力する現アドレスカウンタ52と、これらの部材51・52および上記各レジスタ23・24の値、転送制御部32からの制御信号S1・S2、並びに、転送処理部31からの制御信号S5に基づき、上記各部材51・52を制御する制御部53とを備えている。   On the other hand, as shown in FIG. 7, the main memory address calculation unit 33 includes a line start address register 51 for storing an address (line start address) of the start end (left end in this example) of the rectangular area in the current horizontal line; The address (current address) in the main memory 2 of the pixel to be transferred is stored, and the current address counter 52 that outputs the stored address as the address signal A1, the members 51 and 52, and the registers 23 and The control unit 53 controls the members 51 and 52 based on the value 24, the control signals S1 and S2 from the transfer control unit 32, and the control signal S5 from the transfer processing unit 31.

上記制御部53は、上記制御信号S2によって、矩形領域の転送が指示された場合、上記開始アドレス23の値を、上記ライン開始アドレスレジスタ51および現アドレスカウンタ52に格納できる。   The control unit 53 can store the value of the start address 23 in the line start address register 51 and the current address counter 52 when the transfer of the rectangular area is instructed by the control signal S2.

また、上記制御信号S1が、現水平ラインの終端に到達し、しかも、矩形領域の転送が終了していないことを示している場合、上記制御部53は、上記ライン開始アドレスレジスタ51に格納されている値を、アドレス差レジスタ24に格納されている値の分だけ増加させると共に、現アドレスカウンタ52に、増加後の値を格納できる。   When the control signal S1 reaches the end of the current horizontal line and indicates that the transfer of the rectangular area is not completed, the control unit 53 is stored in the line start address register 51. The incremented value can be increased by the value stored in the address difference register 24, and the increased value can be stored in the current address counter 52.

さらに、上記制御部53は、転送処理部31からの制御信号S5が転送元となるメモリ(この場合は、メインメモリ2)からの読み出し終了を示している場合、上記現アドレスカウンタ52のカウント値を、転送処理部31によってデータ転送されたアドレスの分だけ、インクリメントさせることができる。なお、本実施形態では、転送処理部31がメインメモリ2の1アドレス分ずつデータ転送しているので、上記制御部53は、現アドレスカウンタ52のカウント値を1ずつインクリメントする。   Further, when the control signal S5 from the transfer processing unit 31 indicates the end of reading from the transfer source memory (in this case, the main memory 2), the control unit 53 counts the count value of the current address counter 52. Can be incremented by the amount of the data transferred by the transfer processing unit 31. In the present embodiment, since the transfer processing unit 31 transfers data by one address of the main memory 2, the control unit 53 increments the count value of the current address counter 52 by one.

なお、上記現アドレスカウンタ52は、転送処理部31によるデータ転送の度に、インクリメントできればよいので、上記制御部53は、転送処理部31からの制御信号S5を参照せず、転送制御部32からの制御信号S1が、そのラインの終端への未到達と、矩形領域全体の転送の未終了とを示している場合に、現アドレスカウンタ52をインクリメントしてもよい。ただし、本実施形態では、現アドレスカウンタ52の動作時間をより長く確保するため、転送処理部31は、転送元となるメインメモリ2からの読み出し終了を示す制御信号S5を出力し、制御部53は、制御信号S5が真になった時点で、現アドレスカウンタ52をインクリメントしている。   Since the current address counter 52 only needs to be incremented every time data is transferred by the transfer processing unit 31, the control unit 53 does not refer to the control signal S5 from the transfer processing unit 31 and from the transfer control unit 32. The current address counter 52 may be incremented when the control signal S1 indicates that the end of the line has not been reached and transfer of the entire rectangular area has not been completed. However, in this embodiment, in order to ensure a longer operating time of the current address counter 52, the transfer processing unit 31 outputs a control signal S5 indicating the end of reading from the main memory 2 serving as the transfer source, and the control unit 53 Is incrementing the current address counter 52 when the control signal S5 becomes true.

同様に、上記ビデオメモリアドレス算出部34は、図8に示すように、現水平ラインのライン開始アドレスを記憶するライン開始アドレスレジスタ61と、ビデオメモリ3における現アドレスを記憶すると共に、記憶されたアドレスを上記アドレス信号A2として出力する現アドレスカウンタ62と、これらの部材61・62および上記各レジスタ25・26の値、および、転送制御部32からの制御信号S1・S2に基づいて、上記各部材61・62を制御する制御部63とを備えている。   Similarly, as shown in FIG. 8, the video memory address calculation unit 34 stores the line start address register 61 for storing the line start address of the current horizontal line and the current address in the video memory 3 as well as stored. Based on the current address counter 62 that outputs the address as the address signal A2, the values of the members 61 and 62 and the registers 25 and 26, and the control signals S1 and S2 from the transfer control unit 32, And a control unit 63 that controls the members 61 and 62.

上記制御部63は、上記制御信号S2によって、矩形領域の転送が指示された場合、上記開始アドレス25の値を、上記ライン開始アドレスレジスタ61および現アドレスカウンタ62に格納できる。   The control unit 63 can store the value of the start address 25 in the line start address register 61 and the current address counter 62 when the transfer of the rectangular area is instructed by the control signal S2.

また、上記制御信号S1が、現水平ラインの終端に到達し、しかも、矩形領域の転送が終了していないことを示している場合、上記制御部63は、上記ライン開始アドレスレジスタ61に格納されている値を、アドレス差レジスタ26に格納されている値の分だけ増加させると共に、現アドレスカウンタ62に、増加後の値を格納できる。   When the control signal S1 reaches the end of the current horizontal line and indicates that the transfer of the rectangular area is not completed, the control unit 63 is stored in the line start address register 61. The incremented value can be increased by the value stored in the address difference register 26, and the increased value can be stored in the current address counter 62.

さらに、上記制御部63は、転送制御部32からの制御信号S1が、そのラインの終端への未到達と、矩形領域全体の転送の未終了とを示している場合、上記現アドレスカウンタ62のカウント値を、転送処理部31によってデータ転送されたアドレスの分だけ、インクリメントさせることができる。なお、本実施形態では、転送処理部31がビデオメモリ3の1アドレス分ずつデータ転送しているので、上記制御部63は、現アドレスカウンタ62のカウント値を1ずつインクリメントする。   Further, when the control signal S1 from the transfer control unit 32 indicates that the end of the line has not been reached and the transfer of the entire rectangular area has not been completed, the control unit 63 determines that the current address counter 62 The count value can be incremented by the address of the data transferred by the transfer processing unit 31. In this embodiment, since the transfer processing unit 31 transfers data for each address of the video memory 3, the control unit 63 increments the count value of the current address counter 62 by one.

上記構成では、CPU6は、矩形領域の転送に先立って、上記幅および高さレジスタ21・22に、矩形領域の幅および高さを格納する。さらに、CPU6は、矩形領域の転送に先立って、メインメモリ2およびビデオメモリ3における矩形領域の開始アドレスを、各開始アドレスレジスタ23・25に格納する。また、アドレス差レジスタ24・26の値は、予め定められた固定値であってもよいが、本実施形態では、CPU6が、矩形領域の転送に先立って、メインメモリ2およびビデオメモリ3のメモリマップに合わせて、アドレス差レジスタ24・26の値を設定する。   In the above configuration, the CPU 6 stores the width and height of the rectangular area in the width and height registers 21 and 22 prior to transfer of the rectangular area. Further, the CPU 6 stores the start addresses of the rectangular areas in the main memory 2 and the video memory 3 in the start address registers 23 and 25 prior to the transfer of the rectangular areas. The values of the address difference registers 24 and 26 may be predetermined fixed values. In this embodiment, the CPU 6 stores the memory of the main memory 2 and the video memory 3 prior to the transfer of the rectangular area. The values of the address difference registers 24 and 26 are set according to the map.

各レジスタ21〜26に値が設定され、CPU6が矩形領域のデータ転送の開始を指示すると、転送制御部32は、各アドレス算出部33・34へ、転送開始が指示されたことを示す制御信号S2を出力する。これに応じて、各アドレス算出部33・34は、次にデータを転送するアドレスとして、開始アドレス23・25の値をそれぞれ示すアドレス信号A1・A2を出力する。   When a value is set in each of the registers 21 to 26 and the CPU 6 instructs the start of data transfer in the rectangular area, the transfer control unit 32 controls each address calculation unit 33 and 34 to indicate that the transfer start is instructed. S2 is output. In response to this, the address calculation units 33 and 34 output address signals A1 and A2 indicating the values of the start addresses 23 and 25, respectively, as addresses to which data is transferred next.

さらに、転送処理部31は、転送制御部32からの制御信号S3に応じて、メインメモリ2のうち、メインメモリアドレス算出部33からのアドレス信号A1の示すアドレスに格納されたデータを読み出すと共に、読み出しが終了すると、読み出し終了を示す制御信号S5をメインメモリアドレス算出部33へ出力する。また、転送処理部31は、読み出したデータを、ビデオメモリ3のうち、ビデオメモリアドレス算出部34からのアドレス信号A2の示すアドレスへ当該データを書き込むと共に、書き込みが終了すると、書き込み終了を示す制御信号S4を転送制御部32へ出力する。   Furthermore, the transfer processing unit 31 reads out data stored in the address indicated by the address signal A1 from the main memory address calculation unit 33 in the main memory 2 in response to the control signal S3 from the transfer control unit 32, and When the reading is completed, a control signal S5 indicating the completion of reading is output to the main memory address calculation unit 33. In addition, the transfer processing unit 31 writes the read data to the address indicated by the address signal A2 from the video memory address calculation unit 34 in the video memory 3, and when the writing is completed, the transfer processing unit 31 indicates that the writing is completed. The signal S4 is output to the transfer control unit 32.

一方、転送処理部31からの制御信号S4によって、転送処理部31がデータの転送を出力したことを検出すると、転送制御部32は、現水平ラインの終端に到達したか否かと、矩形領域のデータ転送が終了したか否かを示す制御信号S1を出力する。   On the other hand, when it is detected by the control signal S4 from the transfer processing unit 31 that the transfer processing unit 31 has output the data transfer, the transfer control unit 32 determines whether the end of the current horizontal line has been reached or not. A control signal S1 indicating whether or not the data transfer is completed is output.

ここで、転送処理部31がデータを転送しても、現水平ラインの終端に到達しない場合は、上記転送制御部32は、転送処理部31がデータ転送する度に、終端への未到達と、矩形領域全体の転送の未終了とを示す制御信号S1を出力する。   Here, even if the transfer processing unit 31 transfers data, if the end of the current horizontal line is not reached, the transfer control unit 32 determines that the end has not been reached each time the transfer processing unit 31 transfers data. Then, the control signal S1 indicating that the transfer of the entire rectangular area is not completed is output.

したがって、各アドレス算出部33・34は、転送処理部31がデータ転送する度に、以下の処理、すなわち、転送したデータが各メモリ2・3に占めるアドレスの分だけ、各メモリ2・3の現アドレスを変更する処理を繰り返す。   Therefore, each time the transfer processing unit 31 transfers data, each address calculation unit 33 and 34 performs the following processing, that is, the address of each memory 2 and 3 by the amount of the address that the transferred data occupies in each memory 2 and 3. Repeat the process of changing the current address.

ここで、メインメモリ2とビデオメモリ3とのそれぞれに対応して、現アドレスカウンタ52・62が設けられており、各現アドレスカウンタ52・62のインクリメント量は、転送したデータが各メモリ2・3に占めるアドレスに合わせて設定されている。したがって、画素のデータをメインメモリ2に格納する際のデータ構造(メモリ構成;例えば、メインメモリ2において、各画素を示すデータが占有するアドレスの数など)と、画素のデータをビデオメモリ3に格納する際のデータ構造とが互いに異なっており、しかも、転送処理部31がデータ転送毎にCPU6からの指示を受けていないにも拘わらず、転送処理部31は、何ら支障なく、各画素のデータを、メインメモリ2からビデオメモリ3に転送できる。   Here, current address counters 52 and 62 are provided corresponding to the main memory 2 and the video memory 3, respectively. 3 is set according to the address occupied by 3. Therefore, the data structure (memory configuration; for example, the number of addresses occupied by data indicating each pixel in the main memory 2) and the pixel data are stored in the video memory 3 when the pixel data is stored in the main memory 2. Although the data structures used for storage are different from each other, and the transfer processing unit 31 has not received an instruction from the CPU 6 for each data transfer, the transfer processing unit 31 does not have any problem and does not have any trouble. Data can be transferred from the main memory 2 to the video memory 3.

現水平ラインに関するデータ転送が繰り返され、現水平ラインの終端に到達すると、上記転送制御部32は、終端への到達を示す制御信号S1を出力する。   When data transfer related to the current horizontal line is repeated and the end of the current horizontal line is reached, the transfer control unit 32 outputs a control signal S1 indicating arrival at the end.

この場合、各アドレス算出部33・34は、それぞれに対応するアドレス差レジスタ24・26を参照して、次の水平ラインのライン開始アドレスを決定すると共に、各ライン開始アドレスをそれぞれ示すアドレス信号A1・A2を出力する。   In this case, each of the address calculation units 33 and 34 refers to the corresponding address difference registers 24 and 26 to determine the line start address of the next horizontal line, and address signal A1 indicating each line start address.・ Output A2.

ここで、上述したように、本実施形態に係る転送回路11では、メインメモリ2に対応するアドレス差レジスタ24およびライン開始アドレスレジスタ51とは別に、ビデオメモリ3に対応するアドレス差レジスタ26およびライン開始アドレスレジスタ61が設けられている。したがって、画素のデータをメインメモリ2に格納する際のデータ構造(メモリ構成;例えば、隣接する水平ラインの開始アドレス同士の差など)と、画素のデータをビデオメモリ3に格納する際のデータ構造とが互いに異なっており、しかも、転送処理部31が各水平ラインのデータ転送毎にCPU6からの指示を受けていないにも拘わらず、転送処理部31は、何ら支障なく、各画素のデータを、メインメモリ2からビデオメモリ3に転送できる。   Here, as described above, in the transfer circuit 11 according to the present embodiment, the address difference register 26 and the line corresponding to the video memory 3 are separated from the address difference register 24 and the line start address register 51 corresponding to the main memory 2. A start address register 61 is provided. Therefore, a data structure for storing pixel data in the main memory 2 (memory configuration; for example, a difference between start addresses of adjacent horizontal lines) and a data structure for storing pixel data in the video memory 3 Are different from each other, and even though the transfer processing unit 31 does not receive an instruction from the CPU 6 for each data transfer of each horizontal line, the transfer processing unit 31 transfers the data of each pixel without any trouble. The video data can be transferred from the main memory 2 to the video memory 3.

上記各水平ラインのデータ転送は、矩形領域の高さ分の水平ラインが転送されるまで繰り返され、矩形領域の高さ分の水平ラインのデータ転送が終了すると、転送制御部32は、例えば、矩形領域全体のデータ転送が終了したことを示す制御信号をCPU6へ出力するなどして、矩形領域全体のデータ転送が終了したことをCPU6に通知する。   The data transfer of each horizontal line is repeated until the horizontal line corresponding to the height of the rectangular area is transferred, and when the data transfer of the horizontal line corresponding to the height of the rectangular area is completed, the transfer control unit 32, for example, The CPU 6 is notified of the completion of the data transfer of the entire rectangular area by, for example, outputting to the CPU 6 a control signal indicating that the data transfer of the entire rectangular area has been completed.

このように、本実施形態に係る転送回路11では、メインメモリ2に対応するアドレス差レジスタ24、ライン開始アドレスレジスタ51および現アドレスカウンタ52とは別に、ビデオメモリ3に対応するアドレス差レジスタ26、ライン開始アドレスレジスタ61および現アドレスカウンタ62が設けられているので、両メモリ2・3に画素のデータを格納する際のデータ構造が互いに異なっており、しかも、矩形領域のデータ転送を開始してから終了するまでの間に、CPU6が転送回路11に指示をしていないにも拘わらず、任意の矩形領域内の画素のデータを、メインメモリ2とビデオメモリ3との間で転送できる。したがって、CPU6の負担を軽減できる。   As described above, in the transfer circuit 11 according to the present embodiment, the address difference register 26 corresponding to the video memory 3, in addition to the address difference register 24 corresponding to the main memory 2, the line start address register 51, and the current address counter 52, Since the line start address register 61 and the current address counter 62 are provided, the data structures for storing pixel data in the memories 2 and 3 are different from each other, and the data transfer of the rectangular area is started. The data of the pixels in an arbitrary rectangular area can be transferred between the main memory 2 and the video memory 3 even though the CPU 6 has not instructed the transfer circuit 11 between the main memory 2 and the video memory 3. Therefore, the burden on the CPU 6 can be reduced.

さらに、例えば、各水平ラインの終了時点など、矩形領域のデータ転送中の時点に、CPU6が転送回路11へ指示する構成とは異なり、CPU6が転送回路11へ指示することに起因するオーバーヘッドの発生を防止できる。この結果、メモリ構成の互いに異なるメモリ2・3間で、任意の矩形領域内のデータを高速にデータ転送できる。   Further, for example, unlike the configuration in which the CPU 6 instructs the transfer circuit 11 at the time when the data in the rectangular area is being transferred, such as the end time of each horizontal line, the overhead caused by the CPU 6 instructing the transfer circuit 11 is generated. Can be prevented. As a result, data in an arbitrary rectangular area can be transferred at high speed between the memories 2 and 3 having different memory configurations.

加えて、本実施形態に係る転送回路11では、上記アドレス差レジスタ24・26は、CPU6から値を設定可能に構成されている。したがって、メモリ構成が変化して、隣接する水平ライン間の開始アドレス差が変化する場合であっても、各レジスタ24・26の値を適切に設定し直すことによって、転送回路11は、何ら支障なく、任意の矩形領域内のデータを高速にデータ転送できる。   In addition, in the transfer circuit 11 according to the present embodiment, the address difference registers 24 and 26 are configured such that values can be set from the CPU 6. Therefore, even when the memory configuration changes and the start address difference between the adjacent horizontal lines changes, the transfer circuit 11 does not have any trouble by setting the values of the registers 24 and 26 appropriately. The data in an arbitrary rectangular area can be transferred at high speed.

以下では、図9〜図12を参照しながら、転送回路11の各部材31〜34の詳細な回路構成例について説明する。   Hereinafter, a detailed circuit configuration example of each member 31 to 34 of the transfer circuit 11 will be described with reference to FIGS. 9 to 12.

すなわち、図9に示す構成例では、メインメモリ2およびビデオメモリ3が、DRAM(Dynamic Randam Acess Memory )によって実現されており、転送処理部31には、それぞれの読み書きを制御するためのDRAMコントローラ101および102と、メインメモリ2のデータ端子に出力されたデータをラッチし、ビデオメモリ3のデータ端子へ出力するバッファ103と、バッファ103がメインメモリ2の出力したデータをラッチするまでの間、DRAMコントローラ102がバッファ103のデータをビデオメモリ3への書き込みを遅延させるタイミング制御回路104とを備えている。   That is, in the configuration example shown in FIG. 9, the main memory 2 and the video memory 3 are realized by a DRAM (Dynamic Randam Access Memory), and the transfer processing unit 31 includes a DRAM controller 101 for controlling each reading and writing. And a buffer 103 that latches the data output to the data terminal of the main memory 2 and outputs the data to the data terminal of the video memory 3, and the DRAM until the buffer 103 latches the data output from the main memory 2 The controller 102 includes a timing control circuit 104 that delays writing data in the buffer 103 to the video memory 3.

また、本構成例に係る転送回路11は、矩形領域の転送中、メインメモリ2およびビデオメモリ3へのアクセス権を占有し続けるのではなく、CPU6等の外部回路がメインメモリ2またはビデオメモリ3にアクセスする際には、矩形領域のデータ転送中であっても、適切なタイミングで、データ転送を中断し、メインメモリ2またはビデオメモリ3へのアクセスを許可するように構成されている。   In addition, the transfer circuit 11 according to this configuration example does not continue to occupy the right to access the main memory 2 and the video memory 3 during the transfer of the rectangular area. When accessing the video data, even during the data transfer of the rectangular area, the data transfer is interrupted and access to the main memory 2 or the video memory 3 is permitted at an appropriate timing.

具体的には、上記転送処理部31は、メインメモリ2へのアクセス権を調停する調停回路111と、当該調停回路111からの制御信号REQ1_OKが転送回路11へアクセス権を与えていること(矩形領域のデータ転送を許可していること)を示している間は、上記メインメモリアドレス算出部33からのアドレス信号A1を選択し、残余の間は、外部バスからのアドレス信号を選択すると共に、選択した方を、DRAMコントローラ101のAddress端子へ出力するマルチプレクサ112とを備えている。さらに、上記転送処理部31には、上記外部バスからメインメモリ2のデータ端子までの間に配され、DRAMコントローラ101への書き込み制御信号Write_Lが読み出しを指示している間にのみ、データの通過を遮断する3ステート・バッファ113と、調停回路111からの制御信号REQ1_OKが転送回路11へアクセス権を与えていないことを示しており、しかも、上記外部バスからの制御信号が書き込みを指示している場合にのみ、DRAMコントローラ101へ書き込みを指示する書き込み制御信号Write_Lを出力し、残余の場合は、読み出しを指示する書き込み制御信号Write_Lを出力する論理回路114とが設けられている。なお、本実施形態では、転送回路11へアクセス権を与えている場合、制御信号REQ1_OKが真であり、外部からの制御信号および書き込み制御信号Write_Lが偽の場合は、読み出しを意味している。したがって、上記論理回路114は、OR素子によって実現されている。   Specifically, the transfer processing unit 31 arbitrates an access right to the main memory 2, and the control signal REQ1_OK from the arbitration circuit 111 gives the transfer circuit 11 an access right (rectangular shape). The address signal A1 from the main memory address calculation unit 33 is selected while the data transfer of the area is permitted), and the address signal from the external bus is selected during the remainder, And a multiplexer 112 that outputs the selected one to the address terminal of the DRAM controller 101. Further, the transfer processing unit 31 is arranged between the external bus and the data terminal of the main memory 2 and passes data only while the write control signal Write_L to the DRAM controller 101 instructs reading. The control signal REQ1_OK from the arbitration circuit 111 indicates that the access right is not given to the transfer circuit 11, and the control signal from the external bus instructs the writing. A logic circuit 114 is provided that outputs a write control signal Write_L instructing writing to the DRAM controller 101 only in the case of remaining data, and outputs a write control signal Write_L instructing reading in the remaining case. In this embodiment, when the access right is given to the transfer circuit 11, the control signal REQ1_OK is true, and when the external control signal and the write control signal Write_L are false, it means reading. Therefore, the logic circuit 114 is realized by an OR element.

また、本構成例に係る転送回路11は、矩形領域の転送中、メインメモリ2およびビデオメモリ3へのアクセス権を占有し続けるのではなく、CPU6等の外部回路がメインメモリ2またはビデオメモリ3にアクセスする際には、矩形領域のデータ転送中であっても、適切なタイミングで、データ転送を中断し、メインメモリ2またはビデオメモリ3へのアクセスを許可するように構成されている。   In addition, the transfer circuit 11 according to this configuration example does not continue to occupy the right to access the main memory 2 and the video memory 3 during the transfer of the rectangular area. When accessing the video data, even during the data transfer of the rectangular area, the data transfer is interrupted and access to the main memory 2 or the video memory 3 is permitted at an appropriate timing.

同様に、上記転送処理部31は、ビデオメモリ3へのアクセス権を調停する調停回路121と、当該調停回路121からの制御信号REQ1_OKが転送回路11へアクセス権を与えていること(矩形領域のデータ転送を許可していること)を示している間は、上記ビデオメモリアドレス算出部34からのアドレス信号A2を選択し、残余の間は、外部バスからのアドレス信号を選択すると共に、選択した方を、DRAMコントローラ102のAddress端子へ出力するマルチプレクサ122とを備えている。さらに、上記転送処理部31には、上記外部バスからビデオメモリ3のデータ端子までの間に配され、DRAMコントローラ102への書き込み制御信号Write_Lが読み出しを指示している間にのみ、データの通過を遮断する3ステート・バッファ123と、調停回路121からの制御信号REQ1_OKが転送回路11へアクセス権を与えていないことを示しており、しかも、上記外部バスからの制御信号が読み出しを指示している場合にのみ、DRAMコントローラ102へ読み出しを指示する書き込み制御信号Write_Lを出力し、残余の場合は、書き込みを指示する書き込み制御信号Write_Lを出力する論理回路124とが設けられている。   Similarly, the transfer processing unit 31 arbitrates an access right to the video memory 3, and the control signal REQ1_OK from the arbitration circuit 121 gives the transfer circuit 11 an access right (in the rectangular area). The address signal A2 from the video memory address calculation unit 34 is selected while the data transfer is permitted), and the address signal from the external bus is selected and selected during the remainder. And a multiplexer 122 that outputs the signal to the address terminal of the DRAM controller 102. Further, the transfer processing unit 31 is arranged between the external bus and the data terminal of the video memory 3 and passes data only while the write control signal Write_L to the DRAM controller 102 instructs reading. The control signal REQ1_OK from the arbitration circuit 121 indicates that the right to access the transfer circuit 11 is not given, and the control signal from the external bus instructs reading. A logic circuit 124 is provided that outputs a write control signal Write_L for instructing reading to the DRAM controller 102 only in the case of remaining data, and outputs a write control signal Write_L for instructing writing in the remaining case.

なお、本実施形態では、転送回路11へアクセス権を与えている場合、制御信号REQ1_OKが真であり、外部からの制御信号および書き込み制御信号Write_Lが偽の場合は、読み出しを意味している。また、外部からの制御信号は、インバータによって反転された後、論理回路124に印加されている。したがって、上記論理回路124は、NOR素子によって実現されている。   In this embodiment, when the access right is given to the transfer circuit 11, the control signal REQ1_OK is true, and when the external control signal and the write control signal Write_L are false, it means reading. An external control signal is inverted by an inverter and then applied to the logic circuit 124. Therefore, the logic circuit 124 is realized by a NOR element.

さらに、上記転送処理部31には、当該調停回路121からの制御信号REQ1_OKが転送回路11へアクセス権を与えていることを示している間は、上記バッファ103からのデータ信号を選択し、残余の間は、外部バスからのデータ信号を選択すると共に、選択した方を、上記3ステート・バッファ123へ出力するマルチプレクサ125も設けられている。   Further, while the control signal REQ1_OK from the arbitration circuit 121 indicates that the transfer circuit 11 is given access right, the transfer processing unit 31 selects the data signal from the buffer 103 and stores the remainder. In addition, a multiplexer 125 is provided for selecting a data signal from the external bus and outputting the selected signal to the three-state buffer 123.

また、本構成例に係るタイミング制御回路104は、調停回路111からの制御信号REQ1_OKを反転および遅延させることによって、転送回路11へのアクセス権要求の有無を示すREQ1を生成し、上記調停回路121へ印加している。   Further, the timing control circuit 104 according to the present configuration example generates REQ1 indicating whether or not there is an access right request to the transfer circuit 11 by inverting and delaying the control signal REQ1_OK from the arbitration circuit 111, and the arbitration circuit 121. Is applied.

さらに、本構成例では、上述した転送制御部32からの制御信号S3は、転送回路11へのアクセス権要求の有無を示すREQ1として、上記調停回路121へ印加されている。また、転送処理部31に設けられたタイミング制御回路126は、上記調停回路121からの制御信号REQ1_OKを、反転および遅延した後、転送処理部31によるデータ転送の終了を示す、パルス状の制御信号S4として出力する。なお、制御信号S4を受け取った転送制御部32は、新たな制御信号S3を出力するので、当該制御信号S3を受け付けた調停回路111は、DRAMコントローラ101へ指示して、バッファ103のデータを書き換える。この結果、上記タイミング制御回路126の遅延時間が短いと、調停回路121がDRAMコントローラ102へ矩形領域のためのデータ転送を指示してから、DRAMコントローラ102がビデオメモリ3にバッファ103のデータを書き込むまでの間に、バッファ103のデータが書き換えられてしまう。したがって、上記遅延時間は、調停回路121がDRAMコントローラ102へ矩形領域のためのデータ転送を指示してから、DRAMコントローラ102がビデオメモリ3にバッファ103のデータを書き込むまでの間に、バッファ103のデータが変更されないように設定されている。   Further, in the present configuration example, the control signal S3 from the transfer control unit 32 described above is applied to the arbitration circuit 121 as REQ1 indicating the presence or absence of an access right request to the transfer circuit 11. In addition, the timing control circuit 126 provided in the transfer processing unit 31 inverts and delays the control signal REQ1_OK from the arbitration circuit 121, and then indicates a pulse-like control signal indicating the end of data transfer by the transfer processing unit 31. Output as S4. Since the transfer control unit 32 that has received the control signal S4 outputs a new control signal S3, the arbitration circuit 111 that has received the control signal S3 instructs the DRAM controller 101 to rewrite the data in the buffer 103. . As a result, when the delay time of the timing control circuit 126 is short, the arbitration circuit 121 instructs the DRAM controller 102 to transfer data for the rectangular area, and then the DRAM controller 102 writes the data in the buffer 103 to the video memory 3. Until then, the data in the buffer 103 is rewritten. Therefore, the delay time is determined between the time when the arbitration circuit 121 instructs the DRAM controller 102 to transfer data for the rectangular area and the time when the DRAM controller 102 writes the data in the buffer 103 to the video memory 3. The data is set not to change.

また、上記外部バスからの信号であって、メインメモリ2またはビデオメモリ3へのアクセス権の要求を示す信号は、それぞれ、ワンショット・マルチバイブレータによって遅延された後、調停回路111・121に、REQ0として入力されている。また、DRAMコントローラ101・102からのBusy信号は、それぞれ対応する調停回路111・121のBusy端子に入力されており、各調停回路111・121から出力された、アクセス許可を示すAccess信号は、それぞれ対応するDRAMコントローラ101・102のAccess端子に入力されている。   Further, signals from the external bus, which indicate a request for access right to the main memory 2 or the video memory 3, are respectively delayed by the one-shot multivibrator and then sent to the arbitration circuits 111 and 121. It is input as REQ0. The Busy signals from the DRAM controllers 101 and 102 are input to the Busy terminals of the corresponding arbitration circuits 111 and 121, respectively. The Access signals indicating the access permission output from the arbitration circuits 111 and 121 are respectively It is input to the Access terminal of the corresponding DRAM controller 101/102.

これにより、調停回路111は、転送制御部32からの制御信号S3と、外部バスからREQ0端子へ入力されている信号とに基づいて、転送制御部32と外部バスとのそれぞれがメインメモリ2へのアクセスを要求しているか否かを判定できる。   Thus, the arbitration circuit 111 causes the transfer control unit 32 and the external bus to each of the main memory 2 based on the control signal S3 from the transfer control unit 32 and the signal input from the external bus to the REQ0 terminal. It can be determined whether or not access is requested.

また、調停回路111は、DRAMコントローラ101からのBusy信号が偽である期間に(DRAMコントローラ101が空いている期間)に、REQ0・REQ1端子の少なくとも一方が真である場合(アクセスを要求している場合)は、予め定められた手順で、アクセスを要求しているものうちのいずれか1つにアクセス権を与え、転送回路11にアクセス権を与えているか否かを示す制御信号REQ1_OKを出力できる。また、転送回路11または外部バスに接続された回路の一方にアクセス権を与えた場合は、アクセスを許可することを示すAccess信号をDRAMコントローラ101へ出力できる。   Further, the arbitration circuit 111 determines that at least one of the REQ0 and REQ1 terminals is true during the period when the Busy signal from the DRAM controller 101 is false (the period when the DRAM controller 101 is free) (requesting access). In the case where the access right is given to one of the ones requesting access in accordance with a predetermined procedure, and the control signal REQ1_OK indicating whether the access right is given to the transfer circuit 11 is output. it can. Further, when an access right is given to one of the transfer circuit 11 and the circuit connected to the external bus, an Access signal indicating that access is permitted can be output to the DRAM controller 101.

同様に、調停回路121は、タイミング制御回路104からREQ1端子へ入力されている信号と、外部バスからREQ0端子へ入力されている信号とに基づいて、転送制御部32と外部バスとのそれぞれがビデオメモリ3へのアクセスを要求しているか否かを判定できる。   Similarly, the arbitration circuit 121 determines whether each of the transfer control unit 32 and the external bus is based on a signal input from the timing control circuit 104 to the REQ1 terminal and a signal input from the external bus to the REQ0 terminal. It can be determined whether or not access to the video memory 3 is requested.

また、調停回路121は、DRAMコントローラ102からのBusy信号が偽である期間に(DRAMコントローラ102が空いている期間)に、REQ0・REQ1端子の少なくとも一方が真である場合(アクセスを要求している場合)は、予め定められた手順で、アクセスを要求しているものうちのいずれか1つにアクセス権を与え、転送回路11にアクセス権を与えているか否かを示す制御信号REQ1_OKを出力できる。また、転送回路11または外部バスに接続された回路の一方にアクセス権を与えた場合は、アクセスを許可することを示すAccess信号をDRAMコントローラ102へ出力できる。   Further, the arbitration circuit 121 determines that at least one of the REQ0 and REQ1 terminals is true during the period when the Busy signal from the DRAM controller 102 is false (the period when the DRAM controller 102 is free) (requesting access). In the case where the access right is given to one of the ones requesting access in accordance with a predetermined procedure, and the control signal REQ1_OK indicating whether the access right is given to the transfer circuit 11 is output. it can. Further, when an access right is given to one of the transfer circuit 11 and the circuit connected to the external bus, an Access signal indicating permission of access can be output to the DRAM controller 102.

上記構成では、外部からのアクセス要求がない場合、調停回路111は、転送制御部32からの制御信号S3が真になると、DRAMコントローラ101が空いている期間に、転送回路11にアクセス権を与えていることを示すAccess信号およびREQ1_OK信号を出力する。これにより、マルチプレクサ112は、アドレス信号A1をDRAMコントローラ101へ出力し、論理回路114は、DRAMコントローラ101へ読み出しを指示すると共に、3ステート・バッファ113は、外部バスからメインメモリ2へのデータを遮断する。この結果、メインメモリ2から、アドレス信号A1の示すアドレスに格納されたデータが出力され、バッファ103にラッチされる。   In the above configuration, when there is no external access request, the arbitration circuit 111 gives an access right to the transfer circuit 11 when the DRAM controller 101 is idle when the control signal S3 from the transfer control unit 32 becomes true. An Access signal and a REQ1_OK signal indicating that the Thereby, the multiplexer 112 outputs the address signal A1 to the DRAM controller 101, the logic circuit 114 instructs the DRAM controller 101 to read, and the three-state buffer 113 receives the data from the external bus to the main memory 2. Cut off. As a result, the data stored at the address indicated by the address signal A 1 is output from the main memory 2 and latched in the buffer 103.

当該バッファ103にデータがラッチされた後、調停回路111からの制御信号REQ1_OKは、調停回路121のREQ1端子に入力される。したがって、調停回路121は、転送回路11にアクセス権を与えていることを示すAccess信号およびREQ1_OK信号を出力する。これにより、マルチプレクサ122は、アドレス信号A2をDRAMコントローラ102へ出力し、論理回路124は、DRAMコントローラ102へ書き込みを指示すると共に、マルチプレクサ125および3ステート・バッファ123は、バッファ103からのデータをビデオメモリ3のデータ端子へ入力する。この結果、メインメモリ2からのデータは、ビデオメモリ3のうち、アドレス信号A2の示すアドレスに格納される。さらに、タイミング制御回路126は、上記調停回路121からの制御信号REQ1_OKを遅延および反転させ、パルス状の制御信号S4として出力する。   After the data is latched in the buffer 103, the control signal REQ1_OK from the arbitration circuit 111 is input to the REQ1 terminal of the arbitration circuit 121. Accordingly, the arbitration circuit 121 outputs an Access signal and a REQ1_OK signal indicating that the access right is given to the transfer circuit 11. Thereby, the multiplexer 122 outputs the address signal A2 to the DRAM controller 102, the logic circuit 124 instructs the DRAM controller 102 to write, and the multiplexer 125 and the 3-state buffer 123 video data from the buffer 103. Input to the data terminal of the memory 3. As a result, the data from the main memory 2 is stored in the video memory 3 at the address indicated by the address signal A2. Further, the timing control circuit 126 delays and inverts the control signal REQ1_OK from the arbitration circuit 121 and outputs it as a pulsed control signal S4.

一方、図10に示すように、本構成例に係る転送制御部32の制御部43は、幅レジスタ21の値と幅カウンタ41のカウント値とを比較して、一致/不一致を判定するコンパレータ201と、高さレジスタ22値とライン数カウンタ42のカウント値とを比較して、一致/不一致を判定するコンパレータ202と、コンパレータ201の出力および転送処理部31からの制御信号S4に基づいて、現水平ラインにおける矩形領域の終端へ到達したか否かを示す制御信号S11を生成する論理回路203と、上記両コンパレータ201・202の出力および上記制御信号S4に基づいて、上記終端への到達および矩形領域全体の転送の未終了の双方が成立しているか否かを示す制御信号S12を生成する論理回路204と、上記両コンパレータ201・202の出力および上記制御信号S4に基づいて、上記終端への到達および矩形領域全体の転送の終了の双方が成立しているか否かを示す制御信号S13を生成する論理回路205とを備えている。   On the other hand, as shown in FIG. 10, the control unit 43 of the transfer control unit 32 according to the present configuration example compares the value of the width register 21 with the count value of the width counter 41 and determines the match / mismatch. Are compared with the value of the height register 22 and the count value of the line number counter 42 to determine coincidence / non-coincidence, based on the output of the comparator 201 and the control signal S4 from the transfer processing unit 31. Based on the logic circuit 203 for generating the control signal S11 indicating whether or not the end of the rectangular area in the horizontal line has been reached, the outputs of the comparators 201 and 202 and the control signal S4, the end of the rectangle and the rectangle A logic circuit 204 for generating a control signal S12 indicating whether or not both unfinished transfers of the entire area are established; And a logic circuit 205 that generates a control signal S13 indicating whether or not both the arrival at the end and the end of the transfer of the entire rectangular area are established based on the outputs of 201 and 202 and the control signal S4. ing.

これにより、制御部43は、転送処理部31がデータ転送をする度に、制御信号S1としての制御信号S11およびS12を出力できる。なお、当該制御信号S12は、上述の制御信号S1の一部として、各アドレス算出部33・34と転送制御部32とで共用されている回路221・222(いずれも後述)へ入力されている。   Accordingly, the control unit 43 can output the control signals S11 and S12 as the control signal S1 every time the transfer processing unit 31 performs data transfer. The control signal S12 is input as a part of the control signal S1 to circuits 221 and 222 (both described later) shared by the address calculation units 33 and 34 and the transfer control unit 32. .

上記論理回路203は、コンパレータ201の出力が不一致を示しているか否かを、転送処理部31から制御信号S4のパルスが印加されている期間中、出力する回路であって、論理回路203の出力する制御信号S11は、上述の制御信号S1の一部として、ビデオメモリアドレス算出部34へ出力される。また、上記制御信号S11は、幅カウンタ41のインクリメント端子INCへ入力されている。   The logic circuit 203 is a circuit that outputs whether or not the output of the comparator 201 indicates inconsistency during a period in which the pulse of the control signal S4 is applied from the transfer processing unit 31, and the output of the logic circuit 203 The control signal S11 to be output is output to the video memory address calculation unit 34 as a part of the control signal S1 described above. The control signal S11 is input to the increment terminal INC of the width counter 41.

また、上記論理回路204は、コンパレータ201の出力が一致を示すという条件と、コンパレータ202の出力が不一致を示すという条件との双方が成立しているか否かを、転送処理部31から制御信号S4のパルスが印加されている期間中、出力する回路であって、論理回路204の出力する制御信号S12は、ライン数カウンタ42のインクリメント端子INCへ入力されている。   Further, the logic circuit 204 determines whether or not both the condition that the output of the comparator 201 indicates coincidence and the condition that the output of the comparator 202 indicates disagreement are established from the transfer processing unit 31 by the control signal S4. The control signal S12 output from the logic circuit 204 is input to the increment terminal INC of the line number counter 42.

さらに、上記論理回路205は、コンパレータ201・202の出力の双方が一致を示しているか否かを、転送処理部31から制御信号S4のパルスが印加されている期間中、出力する回路であって、論理回路205の出力する制御信号S13は、後述する転送状態レジスタ211へリセット端子Rに入力されている。   Further, the logic circuit 205 is a circuit that outputs whether or not both outputs of the comparators 201 and 202 indicate coincidence during a period in which the pulse of the control signal S4 is applied from the transfer processing unit 31. The control signal S13 output from the logic circuit 205 is input to the reset terminal R to the transfer status register 211 described later.

一方、上記転送制御部32の制御部43は、CPU6などの外部回路から、外部バスを介してアクセス可能な転送状態レジスタ211を備えており、上記外部回路は、当該転送状態レジスタ211をセットすることによって、転送回路11へ矩形領域の転送を指示できる。   On the other hand, the control unit 43 of the transfer control unit 32 includes a transfer status register 211 that can be accessed from an external circuit such as the CPU 6 via an external bus, and the external circuit sets the transfer status register 211. Thus, the transfer circuit 11 can be instructed to transfer the rectangular area.

また、上記論理回路205は、矩形領域の転送が終了した場合、上記転送状態レジスタ211をリセットすると共に、転送状態レジスタ211の出力は、バッファを介して外部バスへ出力されている。これにより、上記外部回路は、転送状態レジスタ211の出力を読み出すことによって、矩形領域の転送が終了したか否かを確認することができる。   Further, when the transfer of the rectangular area is completed, the logic circuit 205 resets the transfer status register 211, and the output of the transfer status register 211 is output to the external bus via the buffer. Thus, the external circuit can confirm whether or not the transfer of the rectangular area is completed by reading the output of the transfer status register 211.

さらに、上記転送状態レジスタ211の出力信号は、例えば、ワンショット・マルチバイブレータなどによって実現されるタイミング制御回路212によって遅延された後、パルス状の制御信号S2として、上述した各アドレス算出部33・34へ出力される。これにより、制御部43は、矩形領域の転送が指示された場合に制御信号S2を出力できる。また、当該制御信号S12は、インバータによって反転された後、ライン数カウンタ42のローアクティブなリセット端子に入力される。   Further, the output signal of the transfer state register 211 is delayed by a timing control circuit 212 realized by, for example, a one-shot multivibrator or the like, and then, as the pulse-like control signal S2, the above-described address calculation units 33. 34. Thereby, the control unit 43 can output the control signal S2 when the transfer of the rectangular area is instructed. The control signal S12 is inverted by an inverter and then input to a low active reset terminal of the line number counter 42.

また、上記制御部43は、上記制御信号S2と上記制御信号S12との論理和を算出するOR回路221と、OR回路221の出力を反転して、上記幅カウンタ41のローアティブなリセット端子に入力するインバータ222とを備えている。これらの回路221・222は、図1に示す両アドレス算出部33・34の一部でもあって、インバータ222の出力信号S14は、各アドレス算出部33・34のライン開始アドレスレジスタ51・61および現アドレスカウンタ52・62へ、負論理のLoad信号として入力されている。   Further, the control unit 43 inverts the output of the OR circuit 221 that calculates the logical sum of the control signal S2 and the control signal S12, and inputs the input to the low reset terminal of the width counter 41. And an inverter 222. These circuits 221 and 222 are also part of both the address calculation units 33 and 34 shown in FIG. 1, and the output signal S14 of the inverter 222 is sent to the line start address registers 51 and 61 and the address calculation units 33 and 34, respectively. A negative logic load signal is input to the current address counters 52 and 62.

さらに、上記制御部43には、例えば、ワンショット・マルチバイブレータなどによって実現され、上記OR回路221の出力信号を遅延するタイミング制御回路231と、当該タイミング制御回路231の出力信号と、上記制御信号S11との論理和を算出し、制御信号S3として出力するOR回路232とが設けられている。   Further, the control unit 43 includes, for example, a timing control circuit 231 that is realized by a one-shot multivibrator or the like and delays an output signal of the OR circuit 221, an output signal of the timing control circuit 231, and the control signal. An OR circuit 232 that calculates a logical sum with S11 and outputs it as a control signal S3 is provided.

これにより、制御部43は、矩形領域のデータ転送が指示された場合、および、転送処理部31がデータ転送を終了する度に、転送処理部31へ新たな転送を指示する制御信号S3を出力できる。   Thus, the control unit 43 outputs a control signal S3 instructing the transfer processing unit 31 to perform a new transfer when the data transfer of the rectangular area is instructed and every time the transfer processing unit 31 ends the data transfer. it can.

一方、図11に示すように、本構成例に係るメインメモリアドレス算出部33の制御部53は、ライン開始アドレスレジスタ51の値とアドレス差レジスタ24の値とを加算する加算器301と、上記転送制御部32からの制御信号S2に基づいて、当該加算器301の出力値と開始アドレスレジスタ23の出力値との一方を選択して、ライン開始アドレスレジスタ51および現アドレスカウンタ52へ入力するマルチプレクサ302とを備えている。   On the other hand, as shown in FIG. 11, the control unit 53 of the main memory address calculation unit 33 according to this configuration example includes an adder 301 that adds the value of the line start address register 51 and the value of the address difference register 24, A multiplexer that selects one of the output value of the adder 301 and the output value of the start address register 23 based on the control signal S 2 from the transfer control unit 32 and inputs the selected value to the line start address register 51 and the current address counter 52. 302.

上記構成において、矩形領域の転送が開始された場合、転送制御部32から制御信号S2が真になる。これに応じて、上記マルチプレクサ302は、開始アドレスレジスタ23の値を上記両回路51・52に入力する。   In the above configuration, when the transfer of the rectangular area is started, the control signal S2 from the transfer control unit 32 becomes true. In response to this, the multiplexer 302 inputs the value of the start address register 23 to both the circuits 51 and 52.

また、制御信号S2が真になった後、図10に示すOR回路221・223およびタイミング制御回路231の遅延時間だけ遅延して、負論理の制御信号S14が真(Low)になる。この時点では、上記両回路51・52の入力端子Dには、開始アドレスレジスタ23の値が入力されているので、上記両回路51・52は、当該値を記憶する。なお、制御信号S2のパルス幅は、少なくとも、制御信号S2が真になってから、開始アドレスレジスタ23の値が上記両回路51・52に格納されるまでの間、制御信号S2が真であり続けるように設定されている。   Further, after the control signal S2 becomes true, the negative logic control signal S14 becomes true (Low) after being delayed by the delay time of the OR circuits 221 and 223 and the timing control circuit 231 shown in FIG. At this time, since the value of the start address register 23 is input to the input terminal D of both the circuits 51 and 52, the circuits 51 and 52 store the values. The pulse width of the control signal S2 is at least true from the time when the control signal S2 becomes true until the value of the start address register 23 is stored in both the circuits 51 and 52. It is set to continue.

また、上記現アドレスカウンタ52には、転送処理部31から制御信号S5が入力されているので、制御信号S5が入力される度に、上記現アドレスカウンタ52の値は、インクリメントされる。   Further, since the control signal S5 is input from the transfer processing unit 31 to the current address counter 52, the value of the current address counter 52 is incremented each time the control signal S5 is input.

一方、矩形領域の転送開始が指示され、パルス状の制御信号S2が出力された後は、制御信号S2は、常時、偽に保たれている。この状態では、マルチプレクサ301は、加算器301の出力を選択しているので、上記両回路51・52の入力端子Dには、ライン開始アドレスレジスタ51の値とアドレス差レジスタ24の値とを加算した結果が入力されている。   On the other hand, after the start of transfer of the rectangular area is instructed and the pulsed control signal S2 is output, the control signal S2 is always kept false. In this state, since the multiplexer 301 selects the output of the adder 301, the value of the line start address register 51 and the value of the address difference register 24 are added to the input terminals D of both the circuits 51 and 52. The result is entered.

この状態で、転送制御部32の論理回路203が、現水平ラインにおいて矩形領域の終端に到達したと判断し、制御信号S12を真にすると、制御信号S14が真になる。したがって、上記両回路51・52は、新たに、上記記加算結果を記憶する。   In this state, when the logic circuit 203 of the transfer control unit 32 determines that the end of the rectangular area has been reached in the current horizontal line and the control signal S12 is set to true, the control signal S14 becomes true. Therefore, both the circuits 51 and 52 newly store the addition result.

同様に、本構成例に係るビデオメモリアドレス算出部34の制御部63は、図12に示すように、ライン開始アドレスレジスタ61の値とアドレス差レジスタ26の値とを加算する加算器401と、上記転送制御部32からの制御信号S2に基づいて、当該加算器401の出力値と開始アドレスレジスタ25の出力値との一方を選択して、ライン開始アドレスレジスタ61および現アドレスカウンタ12へ入力するマルチプレクサ402とを備えている。   Similarly, the control unit 63 of the video memory address calculating unit 34 according to this configuration example includes an adder 401 that adds the value of the line start address register 61 and the value of the address difference register 26, as shown in FIG. Based on the control signal S2 from the transfer control unit 32, one of the output value of the adder 401 and the output value of the start address register 25 is selected and input to the line start address register 61 and the current address counter 12. And a multiplexer 402.

なお、ビデオメモリアドレス算出部34に関連する各部材25・26・61・62・301・302の動作は、以下の点、すなわち、現アドレスカウンタ62のインクリメント端子INCに、制御信号S5に代えて、制御信号S11が入力されており、当該現アドレスカウンタ62のカウント値が、制御信号S11が真になる度にインクリメントされる点を除けば、メインメモリアドレス算出部33に関連する各部材23・24・51・52・401・402の動作と同一なので、これらの説明を省略する。   The operations of the members 25, 26, 61, 62, 301, and 302 related to the video memory address calculating unit 34 are as follows, in place of the control signal S5 at the increment terminal INC of the current address counter 62. , Except that the control signal S11 is input and the count value of the current address counter 62 is incremented every time the control signal S11 becomes true. Since the operation is the same as 24, 51, 52, 401, and 402, the description thereof is omitted.

〔第2の実施形態〕
ところで、上記第1の実施形態では、転送処理部31が画素のデータを1ワードずつ伝送する場合を例にして説明した。これに対して、本実施形態では、メインメモリ2およびビデオメモリ3がバースト転送可能であり、転送処理部が複数ワードずつバースト転送する構成について説明する。
[Second Embodiment]
In the first embodiment, the case where the transfer processing unit 31 transmits pixel data one word at a time has been described as an example. On the other hand, in the present embodiment, a configuration in which the main memory 2 and the video memory 3 are capable of burst transfer and the transfer processing unit performs burst transfer for each of a plurality of words will be described.

なお、後述するように、転送処理部が複数画素分のデータをバースト転送してもよいが、以下では、1画素分のデータが、メインメモリ2およびビデオメモリ3では、複数ワードのデータに対応している場合を例にして説明する。   As will be described later, the transfer processing unit may perform burst transfer of data for a plurality of pixels, but in the following, data for one pixel corresponds to data for a plurality of words in the main memory 2 and the video memory 3. This will be described as an example.

すなわち、図1に示すように、本実施形態に係るメインメモリ2aおよびビデオメモリ3aは、第1の実施形態に係るメインメモリ2およびビデオメモリ3と略同様であるが、1画素分のデータが、複数のアドレスに渡って書き込まれている。   That is, as shown in FIG. 1, the main memory 2a and the video memory 3a according to the present embodiment are substantially the same as the main memory 2 and the video memory 3 according to the first embodiment. , Written across multiple addresses.

また、本実施形態に係る転送回路11aは、図1に示す転送回路11と略同様であるが、各アドレス算出部33a・34aの現アドレスカウンタ52a・52aの増分が、それぞれ、メインメモリ2aにおいて1画素のデータが占めるアドレスの数、および、ビデオメモリ3aにおいて1画素のデータが占めるアドレスの数に設定されている。   The transfer circuit 11a according to the present embodiment is substantially the same as the transfer circuit 11 shown in FIG. 1, except that the increments of the current address counters 52a and 52a of the address calculators 33a and 34a are respectively increased in the main memory 2a. The number of addresses occupied by data of one pixel and the number of addresses occupied by data of one pixel in the video memory 3a are set.

さらに、本実施形態に係る転送処理部31aでは、バッファ103aが、FIFO(First In First Out)バッファによって実現されており、1画素分のデータを蓄積できる。また、DRAMコントローラ101aは、バースト転送によって、メインメモリ2のデータをバッファ103aに書き込み、DRAMコントローラ102aは、バースト転送によって、バッファ103aのデータを、ビデオメモリ3に書き込むように構成されている。ここで、DRAMコントローラ101a・102aがバースト転送する際のバースト長は、メインメモリ2aにおいて1画素のデータが占めるアドレスの数、および、ビデオメモリ3aにおいて1画素のデータが占めるアドレスの数になるように設定されている。   Furthermore, in the transfer processing unit 31a according to the present embodiment, the buffer 103a is realized by a FIFO (First In First Out) buffer, and can store data for one pixel. The DRAM controller 101a is configured to write the data in the main memory 2 to the buffer 103a by burst transfer, and the DRAM controller 102a is configured to write the data in the buffer 103a to the video memory 3 by burst transfer. Here, the burst length when the DRAM controllers 101a and 102a perform burst transfer is set to the number of addresses occupied by one pixel data in the main memory 2a and the number of addresses occupied by one pixel data in the video memory 3a. Is set to

なお、転送回路11aの部材のうち、上記で説明しなかった部材、並びに、上記で説明した部材の機能および動作であっても、説明しなかった機能および動作は、第1の実施形態に係る転送回路11の各部材、あるいは、対応する部材(参照符号の末尾のaを除いた部材)と同じなので、説明を省略する。   Note that, among the members of the transfer circuit 11a, the members that have not been described above and the functions and operations that have not been described are the functions and operations of the members described above according to the first embodiment. Since it is the same as each member of the transfer circuit 11 or a corresponding member (a member excluding “a” at the end of the reference numeral), description thereof is omitted.

上記構成では、1画素分のデータが複数のアドレスに渡ってメインメモリ2aおよびビデオメモリ3aに書き込まれているにも拘わらず、バースト転送によって、各画素のデータが転送元のメモリ(この場合は、メインメモリ2a)から転送先のメモリ(この場合は、ビデオメモリ3a)に転送される。したがって、1ワードずつ転送する場合よりも、より短い時間で、矩形領域内のデータを転送できる。   In the above configuration, although data for one pixel is written to the main memory 2a and the video memory 3a over a plurality of addresses, the data of each pixel is transferred to the transfer source memory (in this case, by burst transfer). The main memory 2a) is transferred to the destination memory (in this case, the video memory 3a). Therefore, the data in the rectangular area can be transferred in a shorter time than when transferring one word at a time.

この場合であっても、CPU6などの外部回路は、転送処理部31aによるデータ転送毎、あるいは、転送処理部31aによる1水平ライン分のデータ転送毎に、転送処理部31aへ指示する必要がないので、外部回路が転送回路11aへ指示することに起因するオーバーヘッドの発生を防止できる。この結果、メモリ構成の互いに異なるメモリ2a・3a間で、任意の矩形領域内のデータを高速にデータ転送できる。   Even in this case, the external circuit such as the CPU 6 does not need to give an instruction to the transfer processing unit 31a for each data transfer by the transfer processing unit 31a or for each data transfer for one horizontal line by the transfer processing unit 31a. Therefore, it is possible to prevent the occurrence of overhead due to the external circuit instructing the transfer circuit 11a. As a result, data in an arbitrary rectangular area can be transferred at high speed between the memories 2a and 3a having different memory configurations.

なお、両メモリ2・3において、1画素分のデータが占めるアドレスの数は、互いに同一であってもよいし、互いに異なっていてもよい。読み出しの単位(1ワード分のデータ量)と書き込みの単位とが異なっている場合、FIFOバッファ103aは、書き込もうとするDRAMコントローラ(この場合は、101a)から見れば、そのDRAMコントローラの単位での書き込みを受け付け、読み出そうとするDRAMコントローラ(この場合は、102a)から見れば、そのDRAMコントローラの単位での読み出しを受け付けることができるように構成されていればよい。また、上記では、メインメモリ2およびビデオメモリ3の双方に対して、バースト転送する場合を例にして説明したが、一方のみがバースト転送しても、同様の効果が得られる。   In both memories 2 and 3, the number of addresses occupied by data for one pixel may be the same or different from each other. When the read unit (data amount for one word) is different from the write unit, the FIFO buffer 103a is in the unit of the DRAM controller as viewed from the DRAM controller (in this case, 101a) to be written. From the viewpoint of the DRAM controller (in this case, 102a) that accepts and reads data, it suffices if it is configured to be able to accept data read in units of the DRAM controller. In the above description, the case of performing burst transfer to both the main memory 2 and the video memory 3 has been described as an example, but the same effect can be obtained even when only one of them is burst transferred.

ところで、上記では、バースト転送の例として、1画素分のデータがメインメモリ2およびビデオメモリ3では、複数ワードのデータに対応しており、転送処理部31aが1画素分のデータを転送する場合について説明した。これに対して、以下では、複数画素のデータをバースト転送する場合について説明する。なお、以下の構成は、1画素分のデータが複数ワードに対応している場合にも適用できるが、以下では、説明の便宜上、第1の実施形態と同様に、1画素分のデータが1ワードに対応している場合について説明する。   By the way, in the above, as an example of burst transfer, data for one pixel corresponds to data of a plurality of words in the main memory 2 and the video memory 3, and the transfer processing unit 31a transfers data for one pixel. Explained. In contrast, a case where data of a plurality of pixels is burst transferred will be described below. The following configuration can also be applied to a case where data for one pixel corresponds to a plurality of words, but in the following, for convenience of explanation, data for one pixel is 1 as in the first embodiment. The case where it corresponds to a word will be described.

すなわち、本変形例に係る転送回路11bは、図13に示すように、転送回路11と略同様に構成されているが、転送処理部31bは、複数画素分のデータを、バースト転送可能に構成されており、各アドレス算出部33b・34bの現アドレスカウンタ52b・52bの増分が、それぞれ、メインメモリ2またはビデオメモリ3において上記複数画素分のデータが占めるアドレスの数に設定されている。また、本変形例に係る転送制御部32bでは、幅カウンタ41bの増分が、一括転送する画素数に設定されている。   That is, the transfer circuit 11b according to this modification is configured in substantially the same manner as the transfer circuit 11 as shown in FIG. 13, but the transfer processing unit 31b is configured to be capable of burst transfer of data for a plurality of pixels. The increments of the current address counters 52b and 52b of the address calculation units 33b and 34b are set to the number of addresses occupied by the data for the plurality of pixels in the main memory 2 or the video memory 3, respectively. In addition, in the transfer control unit 32b according to this modification, the increment of the width counter 41b is set to the number of pixels to be transferred in a batch.

さらに、本変形例に係る転送制御部32bは、転送制御部32の判定に加えて、現水平ラインの終端へ到達せず、しかも、矩形領域全体の転送が終了していない場合は、次に転送すべき画素数を算出し、制御信号S6として、転送処理部31bに出力できる。上記制御信号S6を出力する回路は、例えば、幅レジスタ21に格納されている値から、幅カウンタ41のカウント値を減算する回路などによって実現できる。   Furthermore, in addition to the determination of the transfer control unit 32, the transfer control unit 32b according to the present modification example does not reach the end of the current horizontal line, and if the transfer of the entire rectangular area is not completed, The number of pixels to be transferred can be calculated and output to the transfer processing unit 31b as the control signal S6. The circuit that outputs the control signal S6 can be realized by, for example, a circuit that subtracts the count value of the width counter 41 from the value stored in the width register 21.

また、転送処理部31bは、例えば、DRAMコントローラ101b・102bへ、上記制御信号S6の画素数に対応するワード数を、各DRAMコントローラ101b・102bのバースト長として出力する回路を設けるなどして、上記制御信号S6の示す画素数に対応するワード数のデータを、バースト転送できるように構成されている。   In addition, the transfer processing unit 31b includes, for example, a circuit that outputs the number of words corresponding to the number of pixels of the control signal S6 to the DRAM controllers 101b and 102b as the burst length of each DRAM controller 101b and 102b. Data of the number of words corresponding to the number of pixels indicated by the control signal S6 can be burst transferred.

一例として、1画素分のデータが各メモリ2・3での1ワードに対応し、転送処理部31bが、4画素分のデータをバースト転送可能に構成されている場合、上記各アドレス算出部33b・34bの現アドレスカウンタ52b・52bの増分は、4ワードに設定されている。   As an example, when the data for one pixel corresponds to one word in each of the memories 2 and 3, and the transfer processing unit 31b is configured to be capable of burst transfer of data for four pixels, each address calculation unit 33b The increment of the current address counter 52b / 52b of 34b is set to 4 words.

また、この場合、上記転送制御部32bは、現水平ラインの終端へ到達せず、しかも、矩形領域全体の転送が終了していない場合、現水平ラインの矩形領域が4画素以上残っていれば、制御信号S6として、4を出力し、3、2または1画素しか残っていない場合は、制御信号S6として、3、2または1を出力する。   In this case, if the transfer control unit 32b does not reach the end of the current horizontal line and the transfer of the entire rectangular area has not been completed, the transfer area 32b has to remain at least 4 pixels in the rectangular area of the current horizontal line. 4 is output as the control signal S6, and when only 3, 2 or 1 pixel remains, 3, 2 or 1 is output as the control signal S6.

さらに、転送処理部31bは、現水平ラインの矩形領域が4画素以上残っていれば、メインメモリ2のデータを4ワード、バースト転送によって読み出し、4ワードのバースト転送によって、当該データをビデオメモリ3に書き込む。   Furthermore, if the rectangular area of the current horizontal line remains in 4 pixels or more, the transfer processing unit 31b reads the data in the main memory 2 by 4 words and burst transfer, and transfers the data to the video memory 3 by burst transfer of 4 words. Write to.

一方、現水平ラインの矩形領域が3画素しか残っていない場合は、メインメモリ2のデータを、それに対応するワード(この場合は、3ワード)、バースト転送によって読み出し、残っている画素数に応じたワード(この場合は、3ワード)のバースト転送によって、当該データをビデオメモリ3に書き込む。   On the other hand, when only 3 pixels remain in the rectangular area of the current horizontal line, the data in the main memory 2 is read out by the corresponding word (in this case, 3 words) by burst transfer, and the number of remaining pixels is determined. The data is written into the video memory 3 by burst transfer of another word (in this case, 3 words).

なお、転送回路11bの部材のうち、上記で説明しなかった部材、並びに、上記で説明した部材の機能および動作であっても、説明しなかった機能および動作は、上記転送回路11の各部材、あるいは、対応する部材(参照符号の末尾のbを除いた部材)と同じなので、説明を省略する。   Of the members of the transfer circuit 11b, the members not described above and the functions and operations of the members described above are the same as those described above. Or, since it is the same as a corresponding member (a member excluding b at the end of the reference numeral), the description thereof is omitted.

上記構成でも、バースト転送によって、各画素のデータが転送元のメモリ(この場合は、メインメモリ2)から転送先のメモリ(この場合は、ビデオメモリ3)に転送される。したがって、転送回路11aと同様に、メモリ構成の互いに異なるメモリ2・3間で、任意の矩形領域内のデータを高速にデータ転送できる。   Even in the above configuration, the data of each pixel is transferred from the transfer source memory (in this case, the main memory 2) to the transfer destination memory (in this case, the video memory 3) by burst transfer. Therefore, similarly to the transfer circuit 11a, data in an arbitrary rectangular area can be transferred at high speed between the memories 2 and 3 having different memory configurations.

〔第3の実施形態〕
ところで、上記第1および第2の実施形態では、一例として、転送回路がメインメモリからビデオメモリへ矩形領域のデータを転送する構成について説明した。これに対して、本実施形態では、転送回路が双方向にデータを転送する構成について説明する。なお、本構成は、第2の実施形態にも適用できるが、以下では、一例として、第1の実施形態に適用した場合について説明する。
[Third Embodiment]
In the first and second embodiments, as an example, the configuration in which the transfer circuit transfers the rectangular area data from the main memory to the video memory has been described. In contrast, in the present embodiment, a configuration in which the transfer circuit transfers data bidirectionally will be described. Although this configuration can be applied to the second embodiment, a case where it is applied to the first embodiment will be described below as an example.

すなわち、本実施形態に係る転送回路11cは、図14に示すように、CPU6などの外部回路からの指示に応じて、転送方向を、メインメモリ2からビデオメモリ3への方向だけではなく、その逆方向に変更できるように構成されている。   That is, the transfer circuit 11c according to the present embodiment, as shown in FIG. 14, in accordance with an instruction from an external circuit such as the CPU 6, the transfer direction is not limited to the direction from the main memory 2 to the video memory 3. It is configured so that it can be changed in the reverse direction.

具体的には、図15に示すように、転送回路11cには、CPU6などの外部回路からアクセス可能な転送方向レジスタ241が設けられており、転送方向レジスタ241に設定された値を、制御信号S7として、転送処理部31cに出力できる。なお、本実施形態では、一例として、転送方向レジスタ241が転送制御部32cに設けられている構成について説明するが、転送処理部31cが上記外部回路から直接転送方向の指示を受け取ってもよい。   Specifically, as shown in FIG. 15, the transfer circuit 11 c is provided with a transfer direction register 241 that can be accessed from an external circuit such as the CPU 6, and the value set in the transfer direction register 241 is set as a control signal. As S7, the data can be output to the transfer processing unit 31c. In the present embodiment, a configuration in which the transfer direction register 241 is provided in the transfer control unit 32c will be described as an example. However, the transfer processing unit 31c may receive an instruction of the transfer direction directly from the external circuit.

一方、転送処理部31cには、図9に示す転送処理部31の構成に加えて、図16に示すように、バッファ103と同様の構成のバッファ105が設けられている。ただし、当該バッファ105は、バッファ103と逆方向の転送用のバッファであり、入力端子Dには、ビデオメモリ3からのデータが、バッファを介して入力されている。また、バッファ105の出力は、外部バスと3ステート・バッファ113との間に設けられたマルチプレクサ106を介して、3ステート・バッファ113に入力されている。当該マルチプレクサ106は、制御信号S7がビデオメモリ3からメインメモリ2への転送を指示している間、バッファ105の出力を選択し、それ以外の場合は、外部バスを選択するように構成されている。   On the other hand, in addition to the configuration of the transfer processing unit 31 illustrated in FIG. 9, the transfer processing unit 31 c includes a buffer 105 having the same configuration as the buffer 103 as illustrated in FIG. 16. However, the buffer 105 is a buffer for transfer in the reverse direction to the buffer 103, and data from the video memory 3 is input to the input terminal D through the buffer. The output of the buffer 105 is input to the 3-state buffer 113 via a multiplexer 106 provided between the external bus and the 3-state buffer 113. The multiplexer 106 is configured to select the output of the buffer 105 while the control signal S7 instructs the transfer from the video memory 3 to the main memory 2, and to select the external bus otherwise. Yes.

さらに、転送処理部31cには、図16に示す回路だけではなく、図17に示す回路も追加されている。すなわち、制御信号S3が図9に示す調停回路111のREQ1端子へ入力されるまでの間には、制御信号S7に応じて、入力の一方を選択するマルチプレクサ151が設けられている。当該マルチプレクサ151は、制御信号S7がビデオメモリ3への転送を指示している場合は、上記制御信号S3をREQ1端子へ入力すると共に、メインメモリ2への転送を指示している場合は、制御信号S3に代えて、図9に示すタイミング制御回路126の出力を、上記REQ1端子に入力できる。   Furthermore, not only the circuit shown in FIG. 16 but also the circuit shown in FIG. 17 are added to the transfer processing unit 31c. That is, until the control signal S3 is input to the REQ1 terminal of the arbitration circuit 111 shown in FIG. 9, the multiplexer 151 that selects one of the inputs according to the control signal S7 is provided. The multiplexer 151 inputs the control signal S3 to the REQ1 terminal when the control signal S7 instructs the transfer to the video memory 3, and controls the transfer when the control signal S7 instructs the transfer to the main memory 2. Instead of the signal S3, the output of the timing control circuit 126 shown in FIG. 9 can be input to the REQ1 terminal.

また、転送処理部31cにおいて、図9に示すタイミング制御回路104と調停回路121のREQ1端子との間には、制御信号S7に応じて、入力の一方を選択するマルチプレクサ152が設けられている。当該マルチプレクサ152は、制御信号S7がビデオメモリ3への転送を指示している場合は、タイミング制御回路104の出力を、調停回路121のREQ1端子へ入力すると共に、メインメモリ2への転送を指示している場合は、タイミング制御回路104の出力に代えて、上記制御信号S3を、調停回路121のREQ1端子に入力できる。   In the transfer processing unit 31c, a multiplexer 152 that selects one of the inputs according to the control signal S7 is provided between the timing control circuit 104 illustrated in FIG. 9 and the REQ1 terminal of the arbitration circuit 121. When the control signal S7 instructs the transfer to the video memory 3, the multiplexer 152 inputs the output of the timing control circuit 104 to the REQ1 terminal of the arbitration circuit 121 and instructs the transfer to the main memory 2. In this case, the control signal S 3 can be input to the REQ 1 terminal of the arbitration circuit 121 instead of the output of the timing control circuit 104.

さらに、図9に示すタイミング制御回路104および126の出力が制御信号S5およびS4として出力されるまでの間には、制御信号S7に応じて、両者を入れ換える置換回路153が設けられている。当該置換回路153は、制御信号S7がビデオメモリ3への転送を指示している場合は、図9と同様に、タイミング制御回路104および126の出力を制御信号S5およびS4として出力できる。一方、制御信号S7がメインメモリ2への転送を指示している場合は、図9とは異なり、タイミング制御回路104の出力を、制御信号S4として出力すると共に、タイミング制御回路126の出力を、制御信号S5として出力できる。   Further, a replacement circuit 153 that replaces both in accordance with the control signal S7 is provided until the outputs of the timing control circuits 104 and 126 shown in FIG. 9 are output as the control signals S5 and S4. The replacement circuit 153 can output the outputs of the timing control circuits 104 and 126 as the control signals S5 and S4, as in FIG. 9, when the control signal S7 instructs the transfer to the video memory 3. On the other hand, when the control signal S7 instructs transfer to the main memory 2, unlike FIG. 9, the output of the timing control circuit 104 is output as the control signal S4, and the output of the timing control circuit 126 is It can be output as the control signal S5.

また、各アドレス算出部33c・34cには、両者に共通の回路として、図18に示す置換回路311が設けられている。当該置換回路311は、転送制御部32cからの制御信号S11と、転送処理部31cからの制御信号S5との一方を、メインメモリアドレス算出部33cの現アドレスカウンタ52に入力すると共に、他方を、ビデオメモリアドレス算出部34cの現アドレスカウンタ62に入力する回路であって、制御信号S7がビデオメモリ3への転送を示している場合は、制御信号S5を現アドレスカウンタ52へ入力すると共に、メインメモリ2への転送を示している場合は、制御信号S5を現アドレスカウンタ62へ入力できる。   Each address calculation unit 33c / 34c is provided with a replacement circuit 311 shown in FIG. 18 as a circuit common to both. The replacement circuit 311 inputs one of the control signal S11 from the transfer control unit 32c and the control signal S5 from the transfer processing unit 31c to the current address counter 52 of the main memory address calculation unit 33c, and the other to When the control signal S7 indicates a transfer to the video memory 3, the circuit is input to the current address counter 52 of the video memory address calculation unit 34c. When transfer to the memory 2 is indicated, the control signal S5 can be input to the current address counter 62.

上記構成では、制御信号S7がビデオメモリ3への転送を示している場合、転送回路11cの各部材は、第1の実施形態の転送回路11と同様に動作して、メインメモリ2のデータをビデオメモリ3へ転送する。   In the above configuration, when the control signal S7 indicates the transfer to the video memory 3, each member of the transfer circuit 11c operates in the same manner as the transfer circuit 11 of the first embodiment, and the data of the main memory 2 is transferred. Transfer to the video memory 3.

一方、制御信号S7がメインメモリ2への転送を示している場合は、メインメモリ2とビデオメモリ3との役割が入れ替わり、ビデオメモリ3のデータがバッファ105を介してメインメモリ2へ書き込まれる。   On the other hand, when the control signal S 7 indicates transfer to the main memory 2, the roles of the main memory 2 and the video memory 3 are switched, and data in the video memory 3 is written into the main memory 2 via the buffer 105.

いずれの場合であっても、上記各実施形態と同様に、CPU6などの外部回路は、転送処理部31cによるデータ転送毎、あるいは、転送処理部31cによる1水平ライン分のデータ転送毎に、転送処理部31cへ指示する必要がないので、外部回路が転送回路11へ指示することに起因するオーバーヘッドの発生を防止できる。この結果、メモリ構成の互いに異なるメモリ2・3間で、任意の矩形領域内のデータを高速にデータ転送できる。   In any case, as in the above embodiments, the external circuit such as the CPU 6 transfers the data every time the data is transferred by the transfer processing unit 31c or every time the data is transferred for one horizontal line by the transfer processing unit 31c. Since there is no need to give an instruction to the processing unit 31c, it is possible to prevent the occurrence of overhead due to the instruction from the external circuit to the transfer circuit 11. As a result, data in an arbitrary rectangular area can be transferred at high speed between the memories 2 and 3 having different memory configurations.

また、本実施形態では、ビデオメモリ3からメインメモリ2への方向にもデータを転送できるので、例えば、図示しないビデオキャプチャ回路など、ビデオメモリ3に直接データを書き込む回路によって書き込まれたデータを、メインメモリ2に転送することができ、当該データを、CPU6などの外部回路が把握することができる。   In this embodiment, since data can be transferred in the direction from the video memory 3 to the main memory 2, for example, data written by a circuit that directly writes data to the video memory 3, such as a video capture circuit (not shown), The data can be transferred to the main memory 2, and the data can be grasped by an external circuit such as the CPU 6.

なお、上記各実施形態では、各レジスタ21〜26に、幅、高さ、開始アドレスあるいはアドレス差自体が格納される場合を例にして説明したが、これに限るものではなく、例えば、複数の値から演算によって、これらの値を特定可能な情報(例えば、幅および高さに代えて、左上および右下の座標など)を格納し、演算によって、上記各値を算出してもよい。ただし、上記各実施形態のように、各値を直接格納した方が、転送回路(11〜11c)での演算が不要になるので、転送回路の回路構成を簡略化できる。   In each of the above embodiments, the case where the width, height, start address, or address difference itself is stored in each of the registers 21 to 26 has been described as an example. However, the present invention is not limited to this. Information that can identify these values by calculation from the values (for example, upper left and lower right coordinates instead of the width and height) may be stored, and the above values may be calculated by calculation. However, when each value is stored directly as in each of the above embodiments, the operation in the transfer circuit (11 to 11c) is not required, so that the circuit configuration of the transfer circuit can be simplified.

本発明によれば、メモリ構成の互いに異なるメモリ間で、任意の矩形領域内のデータを高速にデータ転送可能な転送回路を実現できるので、例えば、メインメモリとビデオメモリとの間のデータ転送をはじめとして、種々のメモリ間のデータ転送を行う転送回路として、広く好適に使用できる。   According to the present invention, a transfer circuit capable of transferring data in an arbitrary rectangular area at high speed between memories having different memory configurations can be realized. For example, data transfer between a main memory and a video memory can be performed. First, it can be used widely and suitably as a transfer circuit for transferring data between various memories.

本発明の実施形態を示すものであり、転送回路の要部構成を示すブロック図である。1, showing an embodiment of the present invention, is a block diagram showing a main configuration of a transfer circuit. FIG. 上記転送回路を含む情報処理装置の要部構成を示すブロック図である。It is a block diagram which shows the principal part structure of the information processing apparatus containing the said transfer circuit. 上記情報処理装置に設けられたビデオメモリのメモリ構成を示す図面である。It is drawing which shows the memory structure of the video memory provided in the said information processing apparatus. 上記情報処理装置に設けられたメインメモリのメモリ構成を示す図面である。It is drawing which shows the memory structure of the main memory provided in the said information processing apparatus. 上記情報処理装置の表示画面を示す図面である。It is drawing which shows the display screen of the said information processing apparatus. 上記転送回路に設けられた転送制御部の要部構成を示すブロック図である。It is a block diagram which shows the principal part structure of the transfer control part provided in the said transfer circuit. 上記転送回路に設けられたメインメモリアドレス算出部の要部構成を示すブロック図である。It is a block diagram which shows the principal part structure of the main memory address calculation part provided in the said transfer circuit. 上記転送回路に設けられたビデオメモリアドレス算出部の要部構成を示すブロック図である。It is a block diagram which shows the principal part structure of the video memory address calculation part provided in the said transfer circuit. 上記転送回路に設けられた転送処理部の構成例を示す回路図である。It is a circuit diagram which shows the structural example of the transfer process part provided in the said transfer circuit. 上記転送制御部の構成例を示す回路図である。It is a circuit diagram which shows the structural example of the said transfer control part. 上記メインメモリアドレス算出部の構成例を示す回路図である。It is a circuit diagram which shows the structural example of the said main memory address calculation part. 上記ビデオメモリアドレス算出部の構成例を示す回路図である。It is a circuit diagram which shows the structural example of the said video memory address calculation part. 本発明の他の実施形態を示すものであり、転送回路の要部構成を示すブロック図である。FIG. 29, showing another embodiment of the present invention, is a block diagram showing a main configuration of a transfer circuit. 上記転送回路の変形例を示すものであり、転送回路の要部構成を示すブロック図である。It is a block diagram which shows the modification of the said transfer circuit, and shows the principal part structure of a transfer circuit. 本発明のさらに他の実施形態を示すものであり、転送回路に設けられた転送方向レジスタを示すブロック図である。FIG. 24 is a block diagram illustrating a transfer direction register provided in a transfer circuit according to still another embodiment of the present invention. 上記転送回路の転送処理部の構成例を示すものであり、追加されたバッファおよびマルチプレクサを示す回路図である。It is a circuit diagram which shows the example of a structure of the transfer process part of the said transfer circuit, and shows the added buffer and multiplexer. 上記転送回路の転送処理部の構成例を示すものであり、両調停回路近傍に追加された回路を示す回路図である。It is a circuit diagram which shows the example of a structure of the transfer process part of the said transfer circuit, and shows the circuit added to both arbitration circuit vicinity. 上記転送回路の両アドレス算出部の構成例を示すものであり、追加された置換回路を示すブロック図である。It is a block diagram which shows the structural example of both the address calculation parts of the said transfer circuit, and shows the added substitution circuit. 従来技術を示すものであり、情報処理装置の要部構成を示すブロック図である。It is a block diagram which shows a prior art and shows the principal part structure of information processing apparatus.

符号の説明Explanation of symbols

11〜11c 転送回路
24 アドレス差レジスタ(転送元アドレス差レジスタ)
26 アドレス差レジスタ(転送先アドレス差レジスタ)
31〜31c 転送処理部(転送処理回路)
32〜32c 転送制御部(判定回路)
33〜33c メインメモリアドレス算出部(転送元アドレス算出回路)
34〜34c ビデオメモリアドレス算出部(転送先アドレス算出回路)
11 to 11c Transfer circuit 24 Address difference register (transfer source address difference register)
26 Address difference register (transfer destination address difference register)
31-31c Transfer processing unit (transfer processing circuit)
32 to 32c Transfer control unit (determination circuit)
33-33c Main memory address calculation unit (transfer source address calculation circuit)
34 to 34c Video memory address calculation unit (transfer destination address calculation circuit)

Claims (3)

転送元メモリから転送先メモリへ、複数のラインから構成される矩形領域画像のデータを転送する転送回路であって、
上記転送元メモリにて、上記矩形領域画像の隣接するラインに対応するデータ間の開始アドレス同士の差を示すアドレス差情報を格納する転送元アドレス差レジスタと、
上記転送先メモリにて、上記矩形領域画像の隣接するラインに対応するデータ間の開始アドレス同士の差を示すアドレス差情報を格納する転送先アドレス差レジスタと、
上記転送元メモリの指示されたアドレスから、上記転送先メモリの指示されたアドレスへとデータを転送する転送処理回路と、
上記転送処理回路によるデータ転送毎に、次にデータ転送すべき転送元メモリのアドレスを算出して、上記転送処理回路へ指示する転送元アドレス算出回路と、
上記転送処理回路によるデータ転送毎に、次にデータ転送すべき転送先メモリのアドレスを算出して、上記転送処理回路へ指示する転送先アドレス算出回路と、
上記転送処理回路によるデータ転送毎に、現ラインにおける矩形領域の転送が終了したか否かを判定する判定回路とを備え、
上記転送元メモリに格納されたアドレス差情報と上記転送先メモリに格納されたアドレス差情報とは、共に任意に設定可能であり、
上記各アドレス算出回路は、上記判定回路が現ラインの矩形領域の転送が終了したと判断した場合、上記各アドレス差レジスタのうち、それぞれに対応するアドレス差レジスタに格納されたアドレス差情報を参照して、上記矩形領域の次のラインにおける開始アドレスを算出し、次にデータ転送すべきアドレスとして出力することを特徴とする転送回路。
A transfer circuit for transferring data of a rectangular area image composed of a plurality of lines from a transfer source memory to a transfer destination memory,
At the transfer source memory, the transfer source address difference register for storing the address difference information indicating the difference between the start address each other between data corresponding to adjacent lines of the rectangular region image,
At the destination memory, and the transfer destination address difference register for storing an address difference information indicating the difference between the start address each other between data corresponding to adjacent lines of the rectangular region image,
A transfer processing circuit for transferring data from the designated address of the transfer source memory to the designated address of the transfer destination memory;
For each data transfer by the transfer processing circuit, calculate the address of the transfer source memory to be transferred next, and instruct the transfer processing circuit, a transfer source address calculation circuit;
For each data transfer by the transfer processing circuit, a transfer destination address calculating circuit that calculates an address of a transfer destination memory to which data is transferred next and instructs the transfer processing circuit;
A determination circuit for determining whether or not the transfer of the rectangular area in the current line is completed for each data transfer by the transfer processing circuit,
Both the address difference information stored in the transfer source memory and the address difference information stored in the transfer destination memory can be arbitrarily set,
When each of the address calculation circuits determines that the transfer of the rectangular area of the current line is completed, the address calculation circuit refers to the address difference information stored in the corresponding address difference register among the address difference registers. A transfer circuit which calculates a start address in the next line of the rectangular area and outputs it as an address to which data is to be transferred next.
上記転送処理回路は、上記転送元および転送先の少なくとも一方のメモリの複数アドレスのデータを一括して転送することを特徴とする請求項1記載の転送回路。   2. The transfer circuit according to claim 1, wherein the transfer processing circuit collectively transfers data of a plurality of addresses in at least one of the transfer source memory and the transfer destination memory. 上記転送元アドレス差レジスタおよび上記転送先アドレス差レジスタは、それぞれに対応するアドレス差レジスタに格納されたアドレス差情報を、上記転送処理回路によるデータ転送中に変更可能であることを特徴とする請求項1または2記載の転送回路。 The transfer source address difference register and the transfer destination address difference register can change the address difference information stored in the corresponding address difference register during the data transfer by the transfer processing circuit. Item 3. The transfer circuit according to Item 1 or 2.
JP2004251832A 2004-08-31 2004-08-31 Transfer circuit Active JP4071225B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2004251832A JP4071225B2 (en) 2004-08-31 2004-08-31 Transfer circuit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2004251832A JP4071225B2 (en) 2004-08-31 2004-08-31 Transfer circuit

Publications (2)

Publication Number Publication Date
JP2006072449A JP2006072449A (en) 2006-03-16
JP4071225B2 true JP4071225B2 (en) 2008-04-02

Family

ID=36153052

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2004251832A Active JP4071225B2 (en) 2004-08-31 2004-08-31 Transfer circuit

Country Status (1)

Country Link
JP (1) JP4071225B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4987364B2 (en) 2006-06-23 2012-07-25 株式会社東芝 Line memory mounting apparatus and television receiving apparatus
WO2008114322A1 (en) * 2007-03-20 2008-09-25 Fujitsu Limited Semiconductor integrated circuit and semiconductor memory access control method

Also Published As

Publication number Publication date
JP2006072449A (en) 2006-03-16

Similar Documents

Publication Publication Date Title
US10241721B2 (en) Image processing device and image processing method
JP3573614B2 (en) Image processing apparatus and image processing system
US6754786B2 (en) Memory control circuit and method for arbitrating memory bus
JP2000276127A (en) Information processor and display controller
JP2000047974A (en) Bus arbitrating method of bus controller, bus controller, and system of electronic equipment
JP5217786B2 (en) Request arbitration apparatus and request arbitration method
US9070201B2 (en) Image processing apparatus
JP2006301724A (en) Memory controller, image processing controller and electronic equipment
US5530458A (en) Image memory control device
JP4071225B2 (en) Transfer circuit
JP2007018222A (en) Memory access control circuit
US5627968A (en) Data transfer apparatus which allows data to be transferred between data devices without accessing a shared memory
JP4193746B2 (en) Matrix bus connection system
JP4446968B2 (en) Data processing device
US20060047866A1 (en) Computer system having direct memory access controller
JP4477380B2 (en) Multi-layer system and clock control method
JP6210742B2 (en) Data processing device and data transfer control device
JP2005165592A (en) Data transfer device
JPH10326342A (en) Memory control circuit
JP4335327B2 (en) Arbitration apparatus and method
JP2005107873A (en) Semiconductor integrated circuit
JP2008305215A (en) Bus system
JP3959407B2 (en) Image processing apparatus and image processing system
US20050060453A1 (en) Instruction supply control unit and semiconductor device
JP2010086401A (en) Microcomputer, system including same, and data transfer device

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20061017

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20070830

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20070904

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20071102

RD02 Notification of acceptance of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7422

Effective date: 20071102

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20080116

R150 Certificate of patent or registration of utility model

Ref document number: 4071225

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

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

Free format text: PAYMENT UNTIL: 20110125

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20110125

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20120125

Year of fee payment: 4

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

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

Free format text: PAYMENT UNTIL: 20120125

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20130125

Year of fee payment: 5

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

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

Free format text: PAYMENT UNTIL: 20130125

Year of fee payment: 5

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

Free format text: PAYMENT UNTIL: 20140125

Year of fee payment: 6

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

S531 Written request for registration of change of domicile

Free format text: JAPANESE INTERMEDIATE CODE: R313531

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

S111 Request for change of ownership or part of ownership

Free format text: JAPANESE INTERMEDIATE CODE: R313111

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250