JPS63158653A - Dma transfer control system - Google Patents

Dma transfer control system

Info

Publication number
JPS63158653A
JPS63158653A JP30718186A JP30718186A JPS63158653A JP S63158653 A JPS63158653 A JP S63158653A JP 30718186 A JP30718186 A JP 30718186A JP 30718186 A JP30718186 A JP 30718186A JP S63158653 A JPS63158653 A JP S63158653A
Authority
JP
Japan
Prior art keywords
transfer
bytes
data
fifo
remaining
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
JP30718186A
Other languages
Japanese (ja)
Other versions
JPH0568732B2 (en
Inventor
Masako Maruyama
丸山 昌子
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
NEC Corp
Original Assignee
NEC Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by NEC Corp filed Critical NEC Corp
Priority to JP30718186A priority Critical patent/JPS63158653A/en
Publication of JPS63158653A publication Critical patent/JPS63158653A/en
Publication of JPH0568732B2 publication Critical patent/JPH0568732B2/ja
Granted legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/14Handling requests for interconnection or transfer
    • G06F13/20Handling requests for interconnection or transfer for access to input/output bus
    • G06F13/28Handling requests for interconnection or transfer for access to input/output bus using burst mode transfer, e.g. direct memory access DMA, cycle steal

Abstract

PURPOSE:To efficiently execute a DMA transfer by setting the number of the transfer bytes of transferred data and the memory address of the transfer destination of the data, instructing a DMA controller to activate and writing the transferred data in an FIFO. CONSTITUTION:A main control part 1 sets the number 17 of the block transfer bytes to a comparator 6 in the DMA controller 2 at the time of the initialization of the entirety of a device. Thereafter, at the time of using the controller 2 and transferring the data from the FIFO 3 to a memory 5, the control part 1 applies the number of the transfer bytes 18 and the memory address 21 of the data transfer destination to the controller 2, activates a starting instructing line 20 and writes the transferred data in the FIFO 3. At that time, when the number of the bytes applied to the controller 2 is larger than the number of the bytes which can be accumulated on the FIFO 3, the control part 1 recognizes that a writing permission line 28 from the FIFO 3 is activated and then it writes the data 11.

Description

【発明の詳細な説明】 〔産業上の利用分野〕 本発明はDMA転送制御方式に関し、特に高速処理が可
能なりMA転送制御方弐に関する。
DETAILED DESCRIPTION OF THE INVENTION [Field of Industrial Application] The present invention relates to a DMA transfer control method, and particularly to an MA transfer control method that enables high-speed processing.

〔従来の技術〕[Conventional technology]

DMAコントローラを用いてFIFO(ファーストイン
ファーストアウトメモリ)がらRA’M等のメモリへデ
ータを転送する場合、従来は、先ず、主副qrH部がF
IF6に転送データを全て書込み、この後、DMAコン
トローラにデータ転送先のメモリアドレス及び転送デー
タのバイト数(転送バイト数)を含む起動指示を加え、
DMAコントローラを起動させるようにしている。また
、FIFOが蓄積することができるバイト数(蓄積可能
バイト数)以上のデータをメモリに転送する場合は、F
IFOに蓄積可能バイト数以下のデータを書込んだ後、
DMAコントローラに転送先のメモリアドレス及び転送
バイト数を含む起動指示を加える処理をデータの転送が
終了するまで、繰返し行なうようにしている。
Conventionally, when transferring data from FIFO (first-in-first-out memory) to memory such as RAM'M using a DMA controller, first, the main/sub qrH section is
Write all the transfer data to IF6, then add a startup instruction to the DMA controller including the memory address of the data transfer destination and the number of bytes of transfer data (transfer byte number),
I am trying to start up the DMA controller. Also, if you want to transfer more data to memory than the number of bytes that FIFO can store (the number of bytes that can be stored),
After writing data that is less than the number of bytes that can be stored in the IFO,
The process of adding a startup instruction including the transfer destination memory address and the number of transfer bytes to the DMA controller is repeated until the data transfer is completed.

〔発明が解決しようとする問題点〕[Problem that the invention seeks to solve]

上述した従来方式は、主制御部がFIFOに転送データ
を書込んでからDMAコントローラに起動指示を加える
ようにしており、また、一般に、DMAコントローラに
は起動指示が加えられてからデータの転送を開始するま
でにハード的な待ち時間が存在するため、起動指示を加
えた後、データの転送が開始されるまでの間、全く処理
が行なわれないこととなり、無駄時間が多くなる問題が
ある。また、蓄積可能バイト数以上のデータを転送する
場合は、FIFOに蓄積可能バイト数以下のデータを書
込んだ後、DMAコントローラに転送先のメモリアドレ
ス及び転送バイト数を含む起動指示を加える処理をデー
タの転送が終了するまで、繰返し行なうものであるから
、効率が悪い問題もある。
In the conventional method described above, the main control unit writes the transfer data to the FIFO and then adds a start instruction to the DMA controller, and generally, the DMA controller does not transfer data after the start instruction is applied. Since there is a hardware waiting time before the start, no processing is performed at all after the activation instruction is given until the data transfer starts, resulting in a problem of a large amount of wasted time. In addition, when transferring data that exceeds the number of bytes that can be stored, write the data that is less than the number of bytes that can be stored to the FIFO, and then add a startup instruction to the DMA controller that includes the memory address of the transfer destination and the number of bytes to be transferred. Since the process is repeated until the data transfer is completed, there is also the problem of inefficiency.

本発明は前述の如き問題点を解決したものであり、その
目的はDMA転送を効率良く行なえるようにすることに
ある。
The present invention solves the above-mentioned problems, and its purpose is to enable efficient DMA transfer.

〔問題点を解決するための手段〕[Means for solving problems]

本発明は前述の如き問題点を解決するため、主制御部が
FTFOに書込んだデータをDMAコントローラを用い
てメモリに転送するDMA転送制御方式に於いて、 前記11FOに蓄積されているデータのバイト数を示す
バイトカウンタを設けると共に、前記DMAコントロー
ラに、 前記主制御部によって予め設定されているブロック転送
バイト数と前記バイトカウンタに示されているバイト数
とを比較し、前記バイトカウンタが示すバイト数が前記
ブロック転送バイト数以上となることにより前記ブロッ
ク転送バイト数と同数の読出し信号を前記FrFOに加
える第1の比較器と、 データの転送時に前記主制御部によって設定された転送
バイト数と前記FIFOに対する読出し信号とに基づい
て残留転送バイト数を求める転送完了検索回路と、 該転送完了検索回路で求めた残留転送バイト数と前記ブ
ロック転送バイト数とを比較すると共に前記転送完了検
索回路で求めた残留転送バイト数と前記バイトカウンタ
が示すバイト数とを比較し、前記転送完了検索回路で求
めた残留転送バイト数と前記バイトカウンタが示すバイ
ト数とが−敗し、且つ前記転送完了検索回路で求めた残
留転送バイト数が前記ブロック転送バイト数未満となる
ことにより前記転送完了検索回路で求めた残留転送バイ
ト数と同数の読出し信号を前記FIFOに加える第2の
比較器と、 前記FIFOから読出されたデータをデータ転送時に前
記主制御部により設定されたメモリアドレスから順次に
前記メモリに書込む書込み手段とを設け、 前記主制御部は前記メモリにデータを転送する際、転送
するデータの転送バイト数及びデータの転送先のメモリ
アドレスを設定し、前記DMAコントローラに起動を指
示してから前記FIF○に転送データを書込む。
In order to solve the above-mentioned problems, the present invention uses a DMA transfer control method in which data written by a main control unit to an FTFO is transferred to a memory using a DMA controller. A byte counter indicating the number of bytes is provided, and the DMA controller compares the number of block transfer bytes preset by the main control unit with the number of bytes indicated in the byte counter, and determines the number of bytes indicated by the byte counter. a first comparator that applies a read signal equal to the number of block transfer bytes to the FrFO when the number of bytes exceeds the number of block transfer bytes; and a number of transfer bytes set by the main control unit at the time of data transfer. a transfer completion search circuit that calculates the number of remaining transfer bytes based on the read signal for the FIFO; and a transfer completion search circuit that compares the number of remaining transfer bytes obtained by the transfer completion search circuit with the block transfer byte number. The number of remaining transfer bytes obtained by the above is compared with the number of bytes indicated by the byte counter, and the number of remaining transfer bytes obtained by the transfer completion search circuit and the number of bytes indicated by the byte counter are negative, and the transfer is completed. a second comparator that applies read signals of the same number as the number of remaining transfer bytes obtained by the transfer completion search circuit to the FIFO when the number of remaining transfer bytes obtained by the search circuit becomes less than the block transfer byte number; write means for sequentially writing data read from the FIFO into the memory starting from a memory address set by the main control unit during data transfer; The number of data transfer bytes and the memory address of the data transfer destination are set, the DMA controller is instructed to start, and the transfer data is written to the FIF◯.

〔作 用〕[For production]

主制御部はDMAコントローラに起動を指示してからF
IFOに対する転送データの書込みを開始するものであ
り、従来は全く処理が行なわれていなかったDMAコン
トローラに起動指示を加えてから実際にデータ転送が開
始されるまでのハードウェア的な待ち時間中にFIFO
に対する転送データの書込みを行なうことができるので
、データの転送時間を短縮することが可能となる。
The main control unit instructs the DMA controller to start, and then
This starts the writing of transfer data to the IFO, and is performed during the hardware-related waiting time between when a startup instruction is given to the DMA controller and when data transfer actually starts, which previously had not been processed at all. FIFO
Since the transfer data can be written to, the data transfer time can be shortened.

第1の比較器はFIFOに蓄積された転送データのバイ
ト数がブロック転送バイト数以上となる毎にブロック転
送バイト数と同数の読出し信号をFIFOに加える。こ
れにより、ブロック転送バイト数分のデータがブロック
転送される。第2の比較器は転送データの残留転送バイ
ト数がブロック転送バイト数未満となり、且つFIFO
に残留転送バイト数が全て格納されることにより、残留
転送バイト数と同数の続出し信号をFIFOに加える。
The first comparator applies the same number of read signals as the number of block transfer bytes to the FIFO every time the number of bytes of transfer data stored in the FIFO exceeds the number of block transfer bytes. As a result, data corresponding to the number of block transfer bytes is transferred in blocks. The second comparator detects that the remaining number of transfer bytes of the transfer data is less than the number of block transfer bytes, and the FIFO
By storing the entire number of remaining transfer bytes, the same number of continuation signals as the number of remaining transfer bytes are added to the FIFO.

これにより、残留転送データが転送される。As a result, the remaining transfer data is transferred.

ここで、第1の比較器は主副;J部により予め設定され
ているブロック転送バイト数とバイトカウンタが示すバ
イト数とに基づいて読出し信号を作成し、第2の比較器
は主制御部により予め設定されているブロック転送バイ
ト数、バイトカウンタが示すバイト数及び残留転送バイ
ト数とに基づいて読出し信号を作成し、残留転送バイト
数はデータ転送時に主制御部により設定された転送バイ
ト数と読出し信号とにより求められるものであるから、
FIFOの蓄積可能バイト数以上のデータを転送する場
合であっても、起動にかかる処理を1回にすることが可
能となる。
Here, the first comparator creates a read signal based on the number of block transfer bytes preset by the main/sub/J section and the number of bytes indicated by the byte counter, and the second comparator creates a read signal based on the number of bytes indicated by the byte counter. A read signal is created based on the number of block transfer bytes set in advance by the block transfer byte number, the number of bytes indicated by the byte counter, and the remaining transfer byte number, and the remaining transfer byte number is the transfer byte number set by the main control unit at the time of data transfer. and the read signal, so
Even when transferring data that exceeds the number of bytes that can be stored in the FIFO, it is possible to perform startup processing only once.

〔実施例〕〔Example〕

次に本発明の実施例について図面を参照して説明する。 Next, embodiments of the present invention will be described with reference to the drawings.

第1図は本発明の実施例のブロック図であり、主制御部
1と、DMAコントローラ2と、バイトカウンタ4を有
するFIFO3と、メモリ5とから構成されている。
FIG. 1 is a block diagram of an embodiment of the present invention, which is composed of a main control section 1, a DMA controller 2, a FIFO 3 having a byte counter 4, and a memory 5.

バイトカウンタ4を有するFIFO3は主制御部Iから
データ11が1バイト加えられる毎に加算信号線12を
活性化してバイトカウンタ4をカウントアツプさせ、デ
ータ16が1バイト読出される毎に減算信号WI3を活
性化してバイトカウンタ4をカウントダウンさせる。即
ち、バイトカウンタ40カウント値14はFIFO3に
蓄積されているデータのバイト数を示すことになる。ま
た、FIFO3は内部に蓄積されているデータのバイト
数が蓄積可能バイト数と等しくなった時、書込み許可信
号線28を不活性化する。
The FIFO 3 having a byte counter 4 activates the addition signal line 12 to count up the byte counter 4 every time one byte of data 11 is added from the main control unit I, and activates the subtraction signal WI3 every time one byte of data 16 is read out. is activated to count down the byte counter 4. That is, the count value 14 of the byte counter 40 indicates the number of bytes of data stored in the FIFO 3. Furthermore, when the number of bytes of data stored therein becomes equal to the number of storable bytes, the FIFO 3 deactivates the write permission signal line 28.

DMAコントローラ2は第1.第2の比較器6゜7と、
転送完了検索回路8と、バッファ9,10と、オアゲー
ト29とから構成されている。比較器6は初期設定時に
主制御部1により設定されたブロック転送バイト数17
(1回のブロック転送により転送するデータのバイト数
)とバイトカウンタ4のカウント値14とを比較し、比
較結果がカウント値14≧ブロック転送バイト数17と
なった時、プロ。
The DMA controller 2 is the first DMA controller. a second comparator 6°7;
It consists of a transfer completion search circuit 8, buffers 9 and 10, and an OR gate 29. The comparator 6 receives the number of block transfer bytes (17) set by the main control unit 1 at the time of initial setting.
(Number of bytes of data to be transferred in one block transfer) is compared with count value 14 of byte counter 4, and when the comparison result is count value 14 ≧ number of block transfer bytes 17, the pro.

り転送バイト数17と同数の読出し信号22を出力する
。転送完了検索回路8はその内部に読出し信号15を入
力クロノクとして実際に転送されたデータのバイト数を
カウントするカウンタ(図示せず)を有し、主制御部1
によって設定された転送バイト数18からこのカウンタ
のカウント値を’41’lした値を残留転送バイト数2
3として比較器7に加えると共に残留転送バイト数23
が「0」になった時、DMA完了信号19を主制御部1
に加える。尚、上記カウンタは転送バイト数18の設定
時にリセントされるものである。比較器7はカウント値
14と残留転送バイト数23とを比較すると共にブロッ
ク転送バイト数17と残留転送バイト数23とを比較し
、比較結果がカウント値14−残留転送バイト数23で
あり、且つ残留転送バイト数23〈ブロック転送バイト
数17となった時、残留転送バイト数23と同数の読出
し信号24を出力する。
It outputs the same number of read signals 22 as the number of transferred bytes (17). The transfer completion search circuit 8 has a counter (not shown) for counting the number of bytes of data actually transferred using the read signal 15 as an input clock.
The count value of this counter is '41'l from the number of transferred bytes set by 18, and the remaining number of transferred bytes is 2.
3 to the comparator 7 and the remaining number of transferred bytes is 23.
becomes “0”, the DMA completion signal 19 is sent to the main control unit 1.
Add to. Note that the above counter is reset when the number of transferred bytes is set to 18. The comparator 7 compares the count value 14 and the number of remaining transfer bytes 23 and also compares the number of block transfer bytes 17 and the number of remaining transfer bytes 23, and the comparison result is count value 14 - the number of remaining transfer bytes 23, and When the number of remaining transfer bytes reaches 23 (the number of block transfer bytes is 17), the same number of read signals 24 as the number of remaining transfer bytes 23 are output.

次に第1図の動作を説明する。Next, the operation shown in FIG. 1 will be explained.

主制御部lは装置全体の初期設定時にD MAコントロ
ーラ2内の比較器6にブロック転送バイト数17を設定
する。そして、この後、DMAコントローラ2を使用し
てFIFO3からメモリ5ヘデータ転送を行なう場合、
主制御部1は先ず、DMAコントローラ2に転送バイト
数18及びデータ転送先のメモリアドレス21を加える
と共に起動指示線20を活性化し、この後、転送データ
11をFIFO3に書込む。この時、DMAコントロー
ラ2に加えた転送バイト数18がF I FO3の蓄積
可能バイト数よりも大きい場合は、主制御部lはFIF
O3からのS込み許可線28が活性化されていることを
確認してからデータIIの書込みを行なう。また、DM
Aコントローラ2は起動指示線20が活性化されたこと
を確認すると、主制御部1からのメモリアドレス21を
バッファlOに格納すると共に転送バイト数18を転送
完了検索回路8に設定する。
The main control unit 1 sets the number of block transfer bytes, 17, in the comparator 6 in the DMA controller 2 when initializing the entire device. After this, when data is transferred from FIFO 3 to memory 5 using DMA controller 2,
First, the main control unit 1 adds the number of transfer bytes 18 and the memory address 21 of the data transfer destination to the DMA controller 2, activates the activation instruction line 20, and then writes the transfer data 11 to the FIFO 3. At this time, if the number of transfer bytes 18 added to the DMA controller 2 is larger than the number of bytes that can be stored in the FIFO3, the main control unit
Data II is written after confirming that the S write permission line 28 from O3 is activated. Also, DM
When the A controller 2 confirms that the activation instruction line 20 has been activated, it stores the memory address 21 from the main control unit 1 in the buffer IO and sets the number of transfer bytes 18 in the transfer completion search circuit 8.

FIFO3への転送データ11の書込みが開始されると
、バイトカウンタ4のカウント値14は次第に増加する
。そして、カウント値14がブロック転送バイト数17
に達すると、即ちカウント値14≧ブロック転送バイト
数17の関係が満たされると、比較器6は前述したよう
にブロック転送バイト数17と同数の続出し信号22を
出力する。この読出し信号22はオアゲート29を介し
てFIFO3に加えられ、FIFO3はオアゲート29
から出力される続出し信号15に従って1ブロック分の
転送データ16ヲ出力する。DMAコントローラ2は、
FIFO3から出力されたデータ16をバッファ9に順
次格納し、従来と同様にこのバッファ9に格納されたデ
ータ27を書込み信号26のタイミングに従ってバッフ
ァ10に格納されているアドレス25から順にメモリ5
に書込む。尚、このとき、バッファIOに格納されてい
るメモリアドレスは従来と同様にして書込み信号26に
従って順次変更されるものである。
When writing of the transfer data 11 to the FIFO 3 is started, the count value 14 of the byte counter 4 gradually increases. Then, the count value 14 is the block transfer byte number 17
When the count value 14≧number of block transfer bytes 17 is satisfied, the comparator 6 outputs the same number of successive signals 22 as the number of block transfer bytes 17 as described above. This read signal 22 is applied to FIFO3 via OR gate 29, and FIFO3 is applied to FIFO3 via OR gate 29.
One block of transfer data 16 is output in accordance with the continuation signal 15 output from the transfer signal 15. DMA controller 2 is
The data 16 output from the FIFO 3 is sequentially stored in the buffer 9, and the data 27 stored in the buffer 9 is sequentially stored in the memory 5 from the address 25 stored in the buffer 10 according to the timing of the write signal 26, as in the conventional case.
write to. Incidentally, at this time, the memory addresses stored in the buffer IO are sequentially changed in accordance with the write signal 26 in the same manner as in the conventional case.

メモリ5へのデータの書込みが行なわれている間に於い
ても、FIFO3への転送データの書込みは行なわれて
おり、カウント値14≧ブロック転送バイト数17とな
ると上記したと同様の動作が行なわれ、またカウント値
り4=残留転送バイト数23であり、且つ残留転送バイ
ト数23<ブロック転送バイト数17となると、下記の
動作が行なわれる。
Even while data is being written to memory 5, transfer data is being written to FIFO 3, and when the count value 14≧block transfer byte number 17, the same operation as described above is performed. If the count value 4=remaining transfer byte number 23, and the remaining transfer byte number 23<block transfer byte number 17, the following operation is performed.

上記した条件が成立すると、即ち、転送データの残留転
送バイト数23がブロック転送バイト数17以下となり
、且つFIFO3に残留データが全て書込まれると、比
較器7は前述したように残留転送バイト数23と同数の
読出し信号24を出力する。
When the above-mentioned conditions are met, that is, when the number of remaining transfer bytes 23 of the transfer data becomes less than or equal to the number of block transfer bytes 17, and when all the remaining data is written to the FIFO 3, the comparator 7 detects the number of remaining transfer bytes as described above. 23 and the same number of read signals 24 are output.

この読出し信号24はオアゲート29を介してFIFO
3に加えられ、FIFO3はオアゲート29から出力さ
れる読出し信号15に従って転送データを1バイトずつ
順次出力する。FIFO3から出力されたデータはバッ
ファ9に一時格納され、バッファ9に格納されたデータ
27は書込み信号26のタイミングに従ってメモリ5の
バッファ10に格納されているアドレス25から順に書
込まれる。即ち、残留データのバイト数がブロック転送
バイト数17以上ある場合は、ブロック転送バイト数単
位でデータの転送が行なわれ、ブロック転送バイト数1
7以下である場合は、そのバイト数単位でデータの転送
が行なわれる。そして、データの転送が完了し、残留転
送データ数23が「0」となると、DMAコントローラ
2はDMA完了信号19により主制御部1にDMA転送
の終了を通知する。
This read signal 24 is sent to the FIFO via an OR gate 29.
The FIFO 3 sequentially outputs transfer data one byte at a time in accordance with the read signal 15 output from the OR gate 29. The data output from the FIFO 3 is temporarily stored in the buffer 9, and the data 27 stored in the buffer 9 is sequentially written from the address 25 stored in the buffer 10 of the memory 5 according to the timing of the write signal 26. In other words, if the number of remaining data bytes is 17 or more, the number of block transfer bytes is 17, the data is transferred in units of block transfer bytes, and the number of block transfer bytes is 1.
If the number is 7 or less, data is transferred in units of that number of bytes. When the data transfer is completed and the remaining transfer data count 23 becomes "0", the DMA controller 2 notifies the main control unit 1 of the end of the DMA transfer using the DMA completion signal 19.

尚、第1図の一点鎖線で囲んだ部分を集積化することも
可能である。
Note that it is also possible to integrate the portion surrounded by the dashed line in FIG.

〔発明の効果〕〔Effect of the invention〕

以上説明したように、本発明は、D M Aコントロー
ラに起動を指示してからFIFOに対するデータの書込
みを行なうものであり、従来は全く処理が行なわれてい
なかったDMAコントローラに起動指示を加えてから実
際にデータ転送が開始されるまでのハードウェア的な待
ち時間中にFIFOに対する転送データの書込みを行な
うことができるので、データの転送時間の短縮を図るこ
とができる効果がある。
As explained above, the present invention writes data to the FIFO after instructing the DMA controller to start up. Conventionally, this invention instructs the DMA controller to start up and then writes data to the FIFO. Since the transfer data can be written to the FIFO during the hardware-based waiting time from the time to when the data transfer actually starts, there is an effect that the data transfer time can be shortened.

また、更に、本発明は、FIFOに蓄積された転送デー
タのバイト数がブロック転送バイト数以上となる毎にブ
ロック転送バイト数と同数の読出し信号をFIFOに加
える第1の比較回路と、転送データの残留転送バイト数
がブロック転送バイト数未満となり、且つFIFOに残
留転送バイト数が全て格納されることにより、残留転送
バイト数と同数の読出し信号をFIFOに加える第2の
比較回路とを備えたものであるから、FIFOの蓄積可
能バイト数以上のデータを転送する場合であってもDM
Aコントローラの起動にかかる処理を1回にすることが
でき、従って、データの転送効率を向上させることがで
きる効果がある。
Further, the present invention further provides a first comparator circuit that applies read signals of the same number as the number of block transfer bytes to the FIFO every time the number of bytes of transfer data accumulated in the FIFO exceeds the number of block transfer bytes; a second comparator circuit that applies read signals of the same number as the number of remaining transfer bytes to the FIFO when the number of remaining transfer bytes becomes less than the number of block transfer bytes and all the remaining transfer bytes are stored in the FIFO. Therefore, even when transferring data that exceeds the number of bytes that can be stored in the FIFO, DM
The processing required to start up the A controller can be reduced to one time, which has the effect of improving data transfer efficiency.

【図面の簡単な説明】[Brief explanation of the drawing]

第1図は本発明の実施例のブロック図である。 図に於いて、1・・・主制御部、2・・・DMAコント
ローラ、3・・・FIFo、4・・・バイトカウンタ、
5・・・メモリ、6.7・・・比較器、8・・・転送完
了検索回路、9.10・・・バッファ。
FIG. 1 is a block diagram of an embodiment of the invention. In the figure, 1... Main control unit, 2... DMA controller, 3... FIFo, 4... Byte counter,
5...Memory, 6.7...Comparator, 8...Transfer completion search circuit, 9.10...Buffer.

Claims (1)

【特許請求の範囲】 主制御部がFIFOに書込んだデータをDMAコントロ
ーラを用いてメモリに転送するDMA転送制御方式に於
いて、 前記FIFOに蓄積されているデータのバイト数を示す
バイトカウンタを設けると共に、 前記DMAコントローラに、 前記主制御部によって予め設定されているブロック転送
バイト数と前記バイトカウンタに示されているバイト数
とを比較し、前記バイトカウンタが示すバイト数が前記
ブロック転送バイト数以上となることにより前記ブロッ
ク転送バイト数と同数の読出し信号を前記FIFOに加
える第1の比較器と、 データの転送時に前記主制御部によって設定された転送
バイト数と前記FIFOに対する読出し信号とに基づい
て残留転送バイト数を求める転送完了検索回路と、 該転送完了検索回路で求めた残留転送バイト数と前記ブ
ロック転送バイト数とを比較すると共に前記転送完了検
索回路で求めた残留転送バイト数と前記バイトカウンタ
が示すバイト数とを比較し、前記転送完了検索回路で求
めた残留転送バイト数と前記バイトカウンタが示すバイ
ト数とが一致し、且つ前記転送完了検索回路で求めた残
留転送バイト数が前記ブロック転送バイト数未満となる
ことにより前記転送完了検索回路で求めた残留転送バイ
ト数と同数の読出し信号を前記FIFOに加える第2の
比較器と、 前記FIFOから読出されたデータをデータ転送時に前
記主制御部により設定されたメモリアドレスから順次に
前記メモリに書込む書込み手段とを設け、 前記主制御部は前記メモリにデータを転送する際、転送
するデータの転送バイト数及びデータの転送先のメモリ
アドレスを設定し、前記DMAコントローラに起動を指
示してから前記FIFOに転送データを書込むことを特
徴とするDMA転送制御方式。
[Scope of Claims] In a DMA transfer control method in which data written by a main control unit in a FIFO is transferred to a memory using a DMA controller, a byte counter indicating the number of bytes of data stored in the FIFO is provided. and the DMA controller is configured to compare the number of block transfer bytes preset by the main control unit with the number of bytes indicated in the byte counter, and to determine whether the number of bytes indicated by the byte counter is the block transfer byte number. a first comparator that applies a read signal of the same number as the number of block transfer bytes to the FIFO when the number of block transfer bytes is greater than or equal to the number of block transfer bytes; a transfer completion search circuit that calculates the number of remaining transfer bytes based on the transfer completion search circuit; and a transfer completion search circuit that compares the remaining transfer byte number obtained by the transfer completion search circuit with the block transfer byte number, and also compares the remaining transfer byte number obtained by the transfer completion search circuit. and the number of bytes indicated by the byte counter, and if the number of remaining transfer bytes determined by the transfer completion search circuit matches the number of bytes indicated by the byte counter, and the remaining transfer bytes determined by the transfer completion search circuit a second comparator that applies to the FIFO the same number of read signals as the number of remaining transfer bytes determined by the transfer completion search circuit when the number of remaining transfer bytes becomes less than the number of block transfer bytes; write means for sequentially writing into the memory from a memory address set by the main control unit during transfer, and the main control unit, when transferring data to the memory, determines the number of transfer bytes of the data to be transferred and the data size. A DMA transfer control method characterized in that a memory address of a transfer destination is set, the DMA controller is instructed to start, and then transfer data is written to the FIFO.
JP30718186A 1986-12-23 1986-12-23 Dma transfer control system Granted JPS63158653A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP30718186A JPS63158653A (en) 1986-12-23 1986-12-23 Dma transfer control system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP30718186A JPS63158653A (en) 1986-12-23 1986-12-23 Dma transfer control system

Publications (2)

Publication Number Publication Date
JPS63158653A true JPS63158653A (en) 1988-07-01
JPH0568732B2 JPH0568732B2 (en) 1993-09-29

Family

ID=17966009

Family Applications (1)

Application Number Title Priority Date Filing Date
JP30718186A Granted JPS63158653A (en) 1986-12-23 1986-12-23 Dma transfer control system

Country Status (1)

Country Link
JP (1) JPS63158653A (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS5293243A (en) * 1976-01-31 1977-08-05 Nec Corp Data processing unit performing preceding control
JPS6059432A (en) * 1983-09-10 1985-04-05 Fujitsu Ltd Data buffer control method of input and output device

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS5293243A (en) * 1976-01-31 1977-08-05 Nec Corp Data processing unit performing preceding control
JPS6059432A (en) * 1983-09-10 1985-04-05 Fujitsu Ltd Data buffer control method of input and output device

Also Published As

Publication number Publication date
JPH0568732B2 (en) 1993-09-29

Similar Documents

Publication Publication Date Title
JPS63158653A (en) Dma transfer control system
JP2003281074A (en) Direct access memory device
JPS61150055A (en) Dma data transfer system
JP3096382B2 (en) DMA circuit
JPH03134732A (en) Buffer controller
JP2747154B2 (en) I / O processor
JPS62221059A (en) Central processing unit
JPH034348A (en) Control adapter for input/output device
JPH1011388A (en) Direct memory access controller
JPH06348644A (en) Dma circuit
JPS5938827A (en) Microprocessor ipl system
JPH0355642A (en) Memory control system
JPH05193203A (en) Image rectangular dma system
JPH0567035A (en) Data alignment system for dma transfer
JP2001005636A (en) Buffer memory control circuit
JPS59189433A (en) Data erasing system by direct memory access
JPH06302181A (en) Fifo storage for look-ahead system
JPH08241268A (en) Input/output controller
JPS62296278A (en) Image memory control system
JPS63244274A (en) Image processing system
JPH03208152A (en) Dma transfer system
JPH06259229A (en) Addition processor
JPH01142851A (en) Data transfer device
JPH01282940A (en) Memory clear system
JPS6033648A (en) Serial data transfer control device