JPH0223439A - Data processor - Google Patents

Data processor

Info

Publication number
JPH0223439A
JPH0223439A JP17420688A JP17420688A JPH0223439A JP H0223439 A JPH0223439 A JP H0223439A JP 17420688 A JP17420688 A JP 17420688A JP 17420688 A JP17420688 A JP 17420688A JP H0223439 A JPH0223439 A JP H0223439A
Authority
JP
Japan
Prior art keywords
area
cpu
address
circular buffer
areas
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.)
Pending
Application number
JP17420688A
Other languages
Japanese (ja)
Inventor
Akira Watanabe
晃 渡辺
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.)
Mitsubishi Electric Corp
Original Assignee
Mitsubishi Electric 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 Mitsubishi Electric Corp filed Critical Mitsubishi Electric Corp
Priority to JP17420688A priority Critical patent/JPH0223439A/en
Publication of JPH0223439A publication Critical patent/JPH0223439A/en
Pending legal-status Critical Current

Links

Abstract

PURPOSE:To eliminate the overhead of a CPU by providing a calculating circuit to beforehand store the peak address of a circulating buffer, area length and the number of areas, operate the address of an area processed by a CPU and deliver it to the CPU. CONSTITUTION:A CPU 1 writes the information such as the peak address of a circulating buffer 4, the length of an area and the number of areas beforehand to an address calculating circuit 6. Next, the CPU 1 receives the address of an area to be processed from the circuit 6 and processes the contents of the area corresponding to it. When this is completed, the CPU 1 gives the instruction of the processing completion to the circuit 6, the circuit 6 calculates the address of the area to be next processed by the CPU 1 and outputs it to the CPU 1 based on the peak address of the buffer 4, the length of the area and the number of the areas. Thus, the burden of the CPU 1 is decreased, and the overhead of the CPU can be eliminated.

Description

【発明の詳細な説明】 〔産業上の利用分野〕 この発明はRAMのエリアの一部を循環バッファとして
使用しているデータ処理装置に関するものである。
DETAILED DESCRIPTION OF THE INVENTION [Field of Industrial Application] The present invention relates to a data processing device that uses part of a RAM area as a circular buffer.

〔従来の技術〕[Conventional technology]

第3図は従来の一般的なデータ処理装置の構成図で、図
において、■はCPU、2はプログラムを内蔵している
ROM、3はプログラムのワークエリアとしであるいは
CPUIが外部とデータのやりとりを行う時、上記デー
タを一時保持しておくためのバッファとして使用される
データの読み出しとデータの書き込みができるRAM、
4はRAMa内の一部のエリアである循環バッファであ
る。この循環バッファ4は複数の一定長のエリア5で区
切られている。
Figure 3 is a configuration diagram of a conventional general data processing device. A RAM that can read and write data is used as a buffer to temporarily hold the above data when performing
4 is a circular buffer which is a part of the area within RAMa. This circular buffer 4 is divided into a plurality of areas 5 having a constant length.

次に動作について第4図を参照しつつ説明を行う。Next, the operation will be explained with reference to FIG.

まずCPUIは、RAMa内の固定エリアに待゛避され
ているネクスト(次の)エリアアドレス(NA)を読み
込む(S21)。
First, the CPUI reads the next area address (NA) saved in a fixed area in RAMa (S21).

ネクストエリアアドレス(NA)を読み込んだらCPU
1は、このネクストエリアアドレス(NA)から始まる
エリアの内容を処理する(S22)。
After reading the next area address (NA), the CPU
1 processes the contents of the area starting from this next area address (NA) (S22).

この処理が終わると、CPU1はネクストエリアアドレ
ス(NA)が循環バッファ4の最後のエリアのアドレス
か否か調べる(S23)。
When this process is completed, the CPU 1 checks whether the next area address (NA) is the address of the last area of the circular buffer 4 (S23).

ここでネクストエリアアドレス(NA)が最後のエリア
のアドレスでなかったらネクストエリアアドレス(NA
)に固定&(X)を足し、次のネクストエリアアドレス
(N A)としてRAMa内の固定エリアに待避させて
おく(S24)。
Here, if the next area address (NA) is not the address of the last area, the next area address (NA)
) is added with fixed & (X) and saved in a fixed area in RAMa as the next next area address (NA) (S24).

またネクストエリアアドレス(NA)が最後のエリアの
アドレスならば、次のネクストエリアアドレス(NA)
は循環バッファ4の先頭アドレスとし、この先頭アドレ
スを固定エリアに待避させておく(S25)。
Also, if the next area address (NA) is the address of the last area, the next area address (NA)
is the starting address of the circular buffer 4, and this starting address is saved in a fixed area (S25).

このようにCPU1は循環バッファの先頭にあるエリア
からその内容を順番に処理し、エリアが循環バッファ4
の最後にくると、再び先頭のエリアに戻って処理する動
作を繰り返している。
In this way, CPU 1 processes the contents of the circular buffer in order starting from the first area, and the area becomes circular buffer 4.
When it reaches the end, it returns to the first area and repeats the process.

〔発明が解決しようとする課題〕[Problem to be solved by the invention]

従来のデータ処理装置は以上説明したように、CPUが
循環バッファのエリアの内容を処理する都度、次に処理
するエリアのアドレスを演算しているので、CPUの負
担が大きくオーバヘッドを生じる問題があった。
As explained above, in conventional data processing devices, each time the CPU processes the contents of a circular buffer area, it calculates the address of the next area to be processed, which poses a problem in that it places a heavy burden on the CPU and causes overhead. Ta.

この発明は上記問題点を解決するためになされたもので
、次に処理するエリアのアドレス演算をCPUに負担さ
せないことにより、CPUの負担を軽くし、CPUのオ
ーバヘッドをなくすことを目的としている。
This invention was made to solve the above problems, and aims to lighten the load on the CPU and eliminate CPU overhead by not burdening the CPU with address calculation for the next area to be processed.

〔課剖を解決するための手段〕[Means to resolve the issue]

このため、この発明に係るデータ処理装置は、循環バッ
ファ4の先頭アドレス、エリアの長さ、エリアの個数を
予め記憶し、上記CPUIの指示を受けて、次にcpu
iが処理するエリアのアドレスを演算してCPUに渡す
専用のアドレス計算回路6を設けたことを特徴としてい
る。
For this reason, the data processing device according to the present invention stores the start address, area length, and number of areas of the circular buffer 4 in advance, and upon receiving instructions from the CPUI, the next CPU
It is characterized by the provision of a dedicated address calculation circuit 6 that calculates the address of the area processed by i and passes it to the CPU.

〔作用〕[Effect]

この発明に係るアドレス計算回路6は、予め循環バッフ
ァ4の先頭アドレス、エリアの長さ、エリアの個数の情
報を格納している。
The address calculation circuit 6 according to the present invention stores in advance information on the start address of the circular buffer 4, the length of the area, and the number of areas.

ここでCPUIが指令をアドレス計算回路6に出すと、
アドレス計算回路6はCPtJlが次に処理するエリア
のアドレス・を計算する。そしてCPUIの読み出し動
作により、予め計算しておいたエリアのアドレスをCP
UIに渡す。
Here, when the CPUI issues a command to the address calculation circuit 6,
The address calculation circuit 6 calculates the address of the area to be processed next by CPtJl. Then, by the read operation of the CPUI, the address of the area calculated in advance is
Pass to UI.

〔実旌例〕[Actual example]

以下、この発明の一実施例を図について説明する。なお
、上記と同一の構成要素については同−又は相当する符
号を付してその説明を省略する。
An embodiment of the present invention will be described below with reference to the drawings. Note that the same components as those described above are given the same or corresponding numerals, and the explanation thereof will be omitted.

第1図はこの発明の一実施例を示す構成図で、図におい
て、6はCPUが処理するエリアのアドレスを計算する
ために新たに設けられた専用のアドレス計算回路である
FIG. 1 is a block diagram showing an embodiment of the present invention. In the figure, 6 is a dedicated address calculation circuit newly provided to calculate the address of the area processed by the CPU.

次に動作について第2図を参照しつつ説明を行う。まず
CPUIはアドレス計算回路6に予め循環バッファの先
頭アドレス、エリアの長す、エリアの個数の情報を書き
込んでおく。
Next, the operation will be explained with reference to FIG. First, the CPUI writes information on the starting address of the circular buffer, the length of the area, and the number of areas into the address calculation circuit 6 in advance.

CPUIが循環バッファ亭のエリアを順次処理する際、
最初にアドレス計算回路6から処理すべきエリアのアド
レスを受は取り(Sll)、受は取ったアドレスに対応
するエリアの内容を処理する(S12)。このエリアの
内容の処理を終了すると、CPUIはアドレス計算回路
6に処理完了の指示を出す(s+a)。
When the CPUI sequentially processes the circular buffer area,
First, the address of the area to be processed is received from the address calculation circuit 6 (Sll), and the contents of the area corresponding to the received address are processed (S12). When the processing of the contents of this area is completed, the CPUI issues an instruction to the address calculation circuit 6 to complete the processing (s+a).

アドレス計算回路6は、この処理完了の指示を受け、予
めCPUIにより書き込まれた循環バッファ5の先頭ア
ドレス、エリアの長さ、エリアの個数の基にしてCPU
Iが次に処理するエリアのアドレスを計算する。
The address calculation circuit 6 receives this processing completion instruction and calculates the CPU number based on the starting address of the circular buffer 5, the area length, and the number of areas written in advance by the CPUI.
I calculates the address of the next area to process.

そしてCPUIの読み出し動作があれば、計算しておい
たアドレスをCPUIに出力する。
If there is a read operation from the CPUI, the calculated address is output to the CPUI.

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

以上説明したように、この発明によれば、循環バッファ
の先頭アドレス、エリアの長さ、エリアの個数を予め記
憶し、上記CPUの指示を受けて、次にCPUが処理す
るエリアのアドレスを演算してCPUに渡す専用のアド
レス計算回路を設けたので、CPUの負担を軽くし、C
PUのオーバヘラドをな(すことが可能となる。
As explained above, according to the present invention, the starting address of the circular buffer, the length of the area, and the number of areas are stored in advance, and upon receiving instructions from the CPU, the address of the area to be processed next by the CPU is calculated. A dedicated address calculation circuit is provided to pass the address to the CPU, reducing the load on the CPU and reducing the burden on the CPU.
It becomes possible to override the PU.

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

第1図はこの発明の一実施例を示す構成図、第2図はこ
の発明の動作を示す動作フロー図、第3図は従来のデー
タ処理装置の構成図、第4図は従来のデータ処理装置の
動作を示す動作フロー図である。 1・・・CPU、2・・・ROM、3・RAM、4・・
・循環バッファ、5・・・エリア、6・・・アドレス計
算回路。 なお、図中、同一符号は同一、又は相当する構成要素を
示す。 代理人  大  岩  増  雄(ばか2名)第]菖 82図 手 続 補 正 書(自発) 1、事件の表示 特願昭 63−17420CS号 2、発明の名称 ア タ 処 理 装 置 3、補正をする者 代表者 士 Iじ1 岐 守 哉 補正の対象 発明の詳細な説明の欄。 補正の内容 明細書第6頁第10行目 「個数の基にして」 と あるのを r個数を基にして」 と補正する。 以上
FIG. 1 is a block diagram showing an embodiment of the present invention, FIG. 2 is an operation flow diagram showing the operation of the present invention, FIG. 3 is a block diagram of a conventional data processing device, and FIG. 4 is a block diagram of a conventional data processing device. FIG. 3 is an operation flow diagram showing the operation of the device. 1...CPU, 2...ROM, 3...RAM, 4...
- Circular buffer, 5...area, 6...address calculation circuit. In addition, in the figures, the same reference numerals indicate the same or corresponding components. Agent: Masuo Oiwa (2 idiots) No. 82 Iris 82 procedural amendment (voluntary) 1. Indication of the case Patent Application No. 17420CS No. 1988 2. Name of the invention Atta processing device 3. Representative of the person making the amendment Shi Iji 1 Column for detailed explanation of the invention subject to the Kimoriya amendment. In the 10th line of page 6 of the statement of contents of the amendment, the phrase ``Based on the number of pieces'' is amended to read ``Based on the number of pieces.''that's all

Claims (1)

【特許請求の範囲】 CPUと、プログラムを格納しているROMと、プログ
ラムのワークエリア及びCPUが外部とデータのやりと
りを行う際の上記データのバッファ用として使用される
RAMとを有し、上記RAMの一部を複数の一定長のエ
リアからなる循環バッファとして用い、CPUが循環バ
ッファの先頭のエリアからその内容を順番に処理し、エ
リアが循環バッファの最後になると、再び先頭のエリア
に戻って処理するデータ処理装置において、 循環バッファの先頭アドレス、エリアの長さ、エリアの
個数を予め記憶し、上記CPUの指示を受けて、次にC
PUが処理するエリアのアドレスを演算してCPUに渡
す専用のアドレス計算回路を設けたことを特徴とするデ
ータ処理装置。
[Scope of Claims] The above-mentioned system comprises a CPU, a ROM storing a program, and a RAM used as a work area for the program and a buffer for the data when the CPU exchanges data with the outside. A part of the RAM is used as a circular buffer consisting of multiple areas of a fixed length, and the CPU processes the contents in order starting from the first area of the circular buffer, and when the area reaches the end of the circular buffer, it returns to the first area again. In a data processing device that processes a circular buffer, the start address, area length, and number of areas of a circular buffer are stored in advance, and upon receiving instructions from the CPU, the data processing device
A data processing device comprising a dedicated address calculation circuit that calculates an address of an area processed by a PU and passes it to a CPU.
JP17420688A 1988-07-13 1988-07-13 Data processor Pending JPH0223439A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP17420688A JPH0223439A (en) 1988-07-13 1988-07-13 Data processor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP17420688A JPH0223439A (en) 1988-07-13 1988-07-13 Data processor

Publications (1)

Publication Number Publication Date
JPH0223439A true JPH0223439A (en) 1990-01-25

Family

ID=15974579

Family Applications (1)

Application Number Title Priority Date Filing Date
JP17420688A Pending JPH0223439A (en) 1988-07-13 1988-07-13 Data processor

Country Status (1)

Country Link
JP (1) JPH0223439A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5573143A (en) * 1994-09-21 1996-11-12 Colgate-Palmolive Company Blow molded multi-chamber containers with dispenser/doser
US5765187A (en) * 1991-04-05 1998-06-09 Fujitsu Limited Control system for a ring buffer which prevents overrunning and underrunning

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5765187A (en) * 1991-04-05 1998-06-09 Fujitsu Limited Control system for a ring buffer which prevents overrunning and underrunning
US5573143A (en) * 1994-09-21 1996-11-12 Colgate-Palmolive Company Blow molded multi-chamber containers with dispenser/doser

Similar Documents

Publication Publication Date Title
JPS59154564A (en) Programmable controller
JPH01181163A (en) Graphic display system
JPH0223439A (en) Data processor
JPH02148223A (en) Register saving and restoring device
JPH0385632A (en) Computer and arithmetic operation method for the same computer
JPS61267135A (en) Data processor
JPH0241522A (en) Function arithmetic processor
JPH01222328A (en) Data processing system
JPS61151745A (en) Interruption processing system
JPH0442328A (en) Interruption control system for information processor
JPH0421127A (en) Calculating device
JPS58169236A (en) Control system for character font
JPH02247758A (en) Control system for terminal information
JPH01251235A (en) Data processing system
JPH04177452A (en) Information processor
JPS61109145A (en) Calculation system for memory address
JPH04111149A (en) Circuit system for dma device
JPH01193948A (en) System for controlling data transfer
JPS61221829A (en) Instruction reading circuit
JPH01291358A (en) Multiple language processing system
JPS63271665A (en) Clearing processing system for bit map memory
JPH02294752A (en) Storage address conversion control system
JPH0333954A (en) Information processor
JPH0661039B2 (en) Memory access control circuit
JPH0433142U (en)