JP2723843B2 - Dual port memory control circuit - Google Patents

Dual port memory control circuit

Info

Publication number
JP2723843B2
JP2723843B2 JP7190329A JP19032995A JP2723843B2 JP 2723843 B2 JP2723843 B2 JP 2723843B2 JP 7190329 A JP7190329 A JP 7190329A JP 19032995 A JP19032995 A JP 19032995A JP 2723843 B2 JP2723843 B2 JP 2723843B2
Authority
JP
Japan
Prior art keywords
address
port memory
dual
data
read
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Lifetime
Application number
JP7190329A
Other languages
Japanese (ja)
Other versions
JPH0945073A (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.)
NEC Platforms Ltd
NEC Corp
Original Assignee
Nippon Electric Co Ltd
NEC Shizuoca Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Nippon Electric Co Ltd, NEC Shizuoca Ltd filed Critical Nippon Electric Co Ltd
Priority to JP7190329A priority Critical patent/JP2723843B2/en
Publication of JPH0945073A publication Critical patent/JPH0945073A/en
Application granted granted Critical
Publication of JP2723843B2 publication Critical patent/JP2723843B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】本発明はデュアルポートメモ
リ制御回路に関し、特にデュアルポートメモリをファー
ストインファーストアウトメモリとして使用する際の書
き込みアドレスと読み出しアドレスとが一致した場合の
各種障害を防止する制御回路に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a dual-port memory control circuit, and more particularly to a control circuit for preventing various failures when a write address and a read address match when a dual-port memory is used as a first-in first-out memory. About.

【0002】[0002]

【従来の技術】指定された書き込みアドレスに指定され
た書き込みデータを書き込みながら指定された読み出し
アドレスから読み出しデータを求めるデュアルポートメ
モリでは、一般的に書き込みアドレスと読み出しアドレ
スが一致した場合、書き込みデータにより読み出しデー
タが破壊されたり、読み出し時間が極端に遅くなったり
するため、書き込みアドレスと読み出しアドレスが一致
することを禁止している。
2. Description of the Related Art In a dual port memory for obtaining read data from a specified read address while writing the specified write data to a specified write address, generally, when the write address and the read address match, the write data is used. Since the read data is destroyed or the read time is extremely slow, it is prohibited that the write address matches the read address.

【0003】そのため、従来、デュアルポートメモリを
ファーストインファーストアウトメモリとして使用する
際には、書き込みアドレスと読み出しアドレスの一致を
回避するための制御回路を備えていた。図2に示すよう
に、従来のデュアルポートメモリ制御回路は、デュアル
ポートメモリ10と、書き込みアドレスと読み出しアド
レスとを比較する比較回路90と、読み出しアドレスを
変更するアドレス変更制御回路80とから構成されてい
る。本従来例の動作は、比較回路90で入力される書き
込みアドレスと読み出しアドレスとを比較し、アドレス
の差がある一定の値以内になった場合、アドレス制御回
路80で読み出しアドレスを書き込みアドレスに対し一
定のアドレス差以上になるように変更してデュアルポー
トメモリ10に供給し、同一アドレスへの書き込み及び
読み出しを回避していた。
For this reason, conventionally, when a dual-port memory is used as a first-in first-out memory, a control circuit for avoiding a coincidence between a write address and a read address has been provided. As shown in FIG. 2, the conventional dual-port memory control circuit includes a dual-port memory 10, a comparison circuit 90 that compares a write address with a read address, and an address change control circuit 80 that changes a read address. ing. In the operation of this conventional example, the write address and the read address input by the comparison circuit 90 are compared, and when the address difference falls within a certain value, the read address is compared with the write address by the address control circuit 80. The address is changed so as to be equal to or larger than a certain address difference and supplied to the dual port memory 10 to avoid writing and reading to the same address.

【0004】[0004]

【発明が解決しようとする課題】上述した従来のデュア
ルポートメモリ制御回路では、書き込みアドレスと読み
出しアドレスとが互いに近づいてきた場合に、読み出し
アドレスを変更して書き込みアドレスと読み出しアドレ
スの一致を回避しているため、変更対象となったアドレ
スに書き込まれたデータを使用することができなくな
り、再度書き込み直さなければならず、このデュアルポ
ートメモリ制御回路を用いたデータ処理システムや装置
としての処理速度や、特性が劣化するという問題点があ
った。
In the conventional dual port memory control circuit described above, when the write address and the read address approach each other, the read address is changed to avoid the coincidence between the write address and the read address. As a result, the data written to the address to be changed cannot be used, and must be rewritten again, and the processing speed and the processing speed of a data processing system and device using this dual port memory control circuit However, there is a problem that characteristics are deteriorated.

【0005】[0005]

【課題を解決するための手段】本発明のデュアルポート
メモリ制御回路は、互いに同一の機能,構成を有し指定
された書き込みアドレス及び指定された書き込みデータ
を互いに同一タイミングで入力する第1のデュアルポー
トメモリ及び第2のデュアルポートメモリと、指定され
た読み出しアドレスの前記第1のデュアルポートメモリ
に対する入力タイミングを前記第2のデュアルポートメ
モリに対する入力タミングよりも所定遅延タイミング分
遅延させるアドレス遅延回路と、前記指定された読み出
しアドレスに基づいて前記第2のデュアルポートメモリ
から読み出されたデータの出力タイミングを前記アドレ
ス遅延回路と同等の所定遅延タイミング分遅延させるデ
ータ遅延回路と、前記第1のデュアルポートメモリに入
力される前記指定された書き込みアドレスと前記遅延さ
れた読み出しアドレスとが一致するか比較する比較回路
と、前記比較回路よりアドレス一致を示す比較結果が出
力されないときは前記第1のデュアルポートメモリから
読み出されるデータを選択し、前記比較回路よりアドレ
ス一致を示す比較結果が出力されたときは前記データ遅
延回路を通して遅延された前記第2のデュアルポートメ
モリから読み出されたデータを選択する選択回路とを備
えている。
A dual-port memory control circuit according to the present invention has a first dual-port memory control circuit which has the same function and configuration and inputs a designated write address and designated write data at the same timing. A port memory, a second dual port memory, and an address delay circuit for delaying an input timing of a designated read address to the first dual port memory by a predetermined delay timing with respect to an input timing to the second dual port memory. A data delay circuit for delaying an output timing of data read from the second dual-port memory based on the designated read address by a predetermined delay timing equivalent to the address delay circuit; The designation specified in the port memory A comparison circuit for comparing whether the read write address matches the delayed read address, and selecting data read from the first dual-port memory when a comparison result indicating an address match is not output from the comparison circuit. A selection circuit for selecting data read from the second dual-port memory delayed through the data delay circuit when a comparison result indicating an address match is output from the comparison circuit.

【0006】[0006]

【発明の実施の形態】次に本発明について図面を参照し
て説明する。図1は本発明の一実施の形態を示すブロッ
ク図である。図1において、デュアルポートメモリ制御
回路は、互いに同一機能,構成を有し書き込み(入力)
データ,書き込みアドレス,及び読み出しアドレスを入
力し読み出し(出力)データを出力する第1及びその補
助を行う第2の2つのデュアルポートメモリ10,20
と、シフトレジスタから成り第1のデュアルポートメモ
リ10への読み出しアドレスを所定サイクル分遅延させ
るアドレス遅延回路30と、第1のデュアルポートメモ
リ10の書き込みアドレスと読み出しアドレスとを比較
する比較回路50と、シフトレジスタから成り第2のデ
ュアルポートメモリ20の出力データをアドレス遅延回
路30と同一の所定サイクル分遅延させるデータ遅延回
路60と、比較回路50の比較結果に基づき第1のデュ
アルポートメモリ10の出力データかデータ遅延回路6
0を通した第2のデュアルポートメモリ20の出力デー
タかのいずれかを選択する選択回路70と、外部との間
で各種データ,情報の入出力を行う入力端子101〜1
03及び出力端子111とを備えている。書き込みデー
タを入力するための入力端子101及び書き込みアドレ
スを入力するための入力端子102はそれぞれ、第1お
よび第2のデュアルポートメモリ10,20に直接接続
されている。読み出しアドレスを入力するための入力端
子103は第2のデュアルポートメモリ20には直接接
続されているが、第1のデュアルポートメモリ10には
アドレス遅延回路30を通して接続されている。出力端
子111には選択回路70の出力が接続されている。本
回路に供給される書き込みアドレス及び読み出しアドレ
スはそれぞれ一定サイクル数で連続的に変化しながら繰
り返しており、アドレス遅延回路30及びデータ遅延回
路60の遅延サイクル値はこれらのサイクル数より十分
小さな任意の値とする。
DESCRIPTION OF THE PREFERRED EMBODIMENTS Next, the present invention will be described with reference to the drawings. FIG. 1 is a block diagram showing one embodiment of the present invention. In FIG. 1, the dual port memory control circuits have the same function and configuration as each other, and write (input).
A first dual-port memory for inputting data, a write address, and a read address and outputting read (output) data;
An address delay circuit 30 comprising a shift register and delaying a read address to the first dual-port memory 10 by a predetermined cycle; a comparing circuit 50 for comparing a write address and a read address of the first dual-port memory 10; A data delay circuit 60 comprising a shift register and delaying output data of the second dual-port memory 20 by the same predetermined cycle as that of the address delay circuit 30; Output data or data delay circuit 6
0, a selection circuit 70 for selecting any of the output data of the second dual port memory 20 and input terminals 101 to 1 for inputting and outputting various data and information to and from the outside.
03 and an output terminal 111. An input terminal 101 for inputting write data and an input terminal 102 for inputting a write address are directly connected to the first and second dual-port memories 10 and 20, respectively. An input terminal 103 for inputting a read address is directly connected to the second dual-port memory 20, but is connected to the first dual-port memory 10 through the address delay circuit 30. The output of the selection circuit 70 is connected to the output terminal 111. The write address and the read address supplied to the present circuit are repeated while continuously changing at a constant cycle number, and the delay cycle values of the address delay circuit 30 and the data delay circuit 60 are arbitrary smaller than these cycle numbers. Value.

【0007】次に動作を説明する。第1のデュアルポー
トメモリ10及び第2のデュアルポートメモリ20の同
一アドレスに同一データが書き込まれる。第1のデュア
ルポートメモリ10に対する読み出しアドレスは所定サ
イクル分遅延されているがこの遅延された読み出しアド
レスが書き込みアドレスと一致していない間は、比較回
路50は一致を示す比較結果を出力しておらず、選択回
路70は第1のデュアルポートメモリ10側の出力デー
タを出力端子111に出力させる。第1のデュアルポー
トメモリ10における遅延された読み出しアドレスが書
き込みアドレスと一致すると、比較回路50は一致を示
す比較結果を出力し、選択回路70はデータ遅延回路6
0で遅延された第2のデュアルポートメモリ20側の出
力データを出力端子111に出力させる。つまり、主メ
モリである第1のデュアルポートメモリ10側の遅延さ
れた読み出しアドレスで読み出されるはずのデータは、
補助メモリである第2のデュアルポートメモリ20側の
対応する遅延なしの読み出しアドレスですでに読み出さ
れており、データ遅延回路60でアドレス遅延回路30
と同一の遅延を与えられてタイミングを合わせて入れ替
えられる。
Next, the operation will be described. The same data is written to the same address of the first dual port memory 10 and the second dual port memory 20. The read address for the first dual port memory 10 is delayed by a predetermined cycle, but while the delayed read address does not match the write address, the comparing circuit 50 outputs a comparison result indicating a match. Instead, the selection circuit 70 outputs the output data of the first dual port memory 10 to the output terminal 111. When the delayed read address in the first dual-port memory 10 matches the write address, the comparison circuit 50 outputs a comparison result indicating the match, and the selection circuit 70 outputs the data delay circuit 6
The output data of the second dual port memory 20 delayed by 0 is output to the output terminal 111. That is, the data to be read at the delayed read address on the first dual-port memory 10 which is the main memory is
The data has already been read at the corresponding read address without delay on the side of the second dual-port memory 20 which is the auxiliary memory, and the data delay circuit 60 has
And the same delay is given, and the timing is replaced.

【0008】アドレス遅延回路30及びデータ遅延回路
60でそれぞれ書き込み及び読み出しを3サイクル分遅
延させる場合の動作を説明するためのタイミング表を表
1に示す。
Table 1 shows a timing chart for explaining the operation when the write and read operations are delayed by three cycles in the address delay circuit 30 and the data delay circuit 60, respectively.

【0009】[0009]

【表1】 [Table 1]

【0010】表1において、a〜zはアドレス、D
(a)〜D(z)は( )内に示すアドレスのデータを
示す。1番目のサイクルの入力端子103の読み出しア
ドレスaがアドレス遅延回路30で3サイクル遅延され
4番目のサイクルに第1のデュアルポートメモリ10に
入力されるが、これと入力端子102の書き込みアドレ
スaとが一致している。この場合、第2のデュアルポー
トメモリ20では、すでに1番目のサイクルで読み出し
アドレスaによりデータD(a)が読み出されており、
このデータD(a)がデータ遅延回路60で3サイクル
遅延され4番目のサイクルで選択回路70に入力され選
択される。
In Table 1, a to z are addresses, D
(A) to D (z) indicate the data of the address shown in parentheses. The read address a of the input terminal 103 in the first cycle is delayed by three cycles in the address delay circuit 30 and is input to the first dual port memory 10 in the fourth cycle. Matches. In this case, in the second dual-port memory 20, the data D (a) has already been read by the read address a in the first cycle,
The data D (a) is delayed by three cycles in the data delay circuit 60 and is input to the selection circuit 70 and selected in the fourth cycle.

【0011】[0011]

【発明の効果】以上説明したように本発明によれば、デ
ュアルポートメモリとして主メモリとなる第1のデュア
ルポートメモリと補助メモリとなる第2のデュアルポー
トメモリとの2つ設け、指定されたアドレスに対する指
定された書き込みデータの書き込みをそれぞれ同一タイ
ミングで行い、第1のデュアルポートメモリ側では指定
され読み出しアドレスを所定遅延タイミング分遅延させ
て読み出したデータを出力し、第2のデュアルポートメ
モリ側では指定された読み出しアドレスで読み出された
データを所定遅延タイミグ分遅延させて出力し、通常時
は第1のデュアルポートメモリ側のデータを出力データ
として選択しているが、第1のデュアルポートメモリの
書き込みアドレスを読み出しアドレスが一致したときは
書き込みアドレスと読み出しアドレスが一致してないと
きに先行して読み出されていた第2のデュアルポートメ
モリ側のデータを出力データとして選択するので、デュ
アルポートメモリに対する指定された書き込みアドレス
と遅延された指定された読み出しアドレスとが一致して
もデュアルポートメモリに正常なデータを書き込み、か
つデュアルポートメモリから正常なデータを読み出すこ
とが可能となり、本発明を適用した装置として再度書き
込み動作を行う必要が無くなり、処理速度や特性劣化を
防ぐことが可能となる。
As described above, according to the present invention, two dual port memories, a first dual port memory serving as a main memory and a second dual port memory serving as an auxiliary memory, are provided and designated. Writing of the specified write data to the address is performed at the same timing, and the first dual-port memory outputs the read data with the specified read address delayed by a predetermined delay timing, and outputs the read data to the second dual-port memory. Outputs the data read at the specified read address with a delay of a predetermined delay timing, and normally selects the data on the first dual port memory side as output data. When the read address matches the write address of the memory, the write address When the read addresses do not match, the data of the second dual-port memory that has been read earlier is selected as output data, so that the specified write address for the dual-port memory and the delayed specified Even if the read address matches, normal data can be written to the dual-port memory and normal data can be read from the dual-port memory. This eliminates the need to perform a write operation again as an apparatus to which the present invention is applied, and Speed and characteristic deterioration can be prevented.

【図面の簡単な説明】[Brief description of the drawings]

【図1】本発明の一実施の形態を示すブロック図であ
る。
FIG. 1 is a block diagram showing an embodiment of the present invention.

【図2】従来のデュアルポートメモリ制御回路を示すブ
ロック図である。
FIG. 2 is a block diagram showing a conventional dual port memory control circuit.

【符号の説明】 10,20 第1,第2のデュアルポートメモリ 30 アドレス遅延回路 40 読み出し動作制御回路 50 比較回路 60 データ遅延回路 70 選択回路 101 書き込みデータの入力端子 102 書き込みアドレスの入力端子 103 読み出しアドレスの入力端子 111 読み出しデータの出力端子[Description of Signs] 10, 20 First and second dual-port memories 30 Address delay circuit 40 Read operation control circuit 50 Comparison circuit 60 Data delay circuit 70 Selection circuit 101 Input terminal for write data 102 Input terminal for write address 103 Read Address input terminal 111 Read data output terminal

Claims (1)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】 互いに同一の機能,構成を有し指定され
た書き込みアドレス及び指定された書き込みデータを互
いに同一タイミングで入力する第1のデュアルポートメ
モリ及び第2のデュアルポートメモリと、指定された読
み出しアドレスの前記第1のデュアルポートメモリに対
する入力タイミングを前記第2のデュアルポートメモリ
に対する入力タミングよりも所定遅延タイミング分遅延
させるアドレス遅延回路と、前記指定された読み出しア
ドレスに基づいて前記第2のデュアルポートメモリから
読み出されたデータの出力タイミングを前記アドレス遅
延回路と同等の所定遅延タイミング分遅延させるデータ
遅延回路と、前記第1のデュアルポートメモリに入力さ
れる前記指定された書き込みアドレスと前記遅延された
読み出しアドレスとが一致するか比較する比較回路と、
前記比較回路よりアドレス一致を示す比較結果が出力さ
れないときは前記第1のデュアルポートメモリから読み
出されるデータを選択し、前記比較回路よりアドレス一
致を示す比較結果が出力されたときは前記データ遅延回
路を通して遅延された前記第2のデュアルポートメモリ
から読み出されたデータを選択する選択回路とを備える
ことを特徴とするデュアルポートメモリ制御回路。
1. A first dual-port memory and a second dual-port memory having the same function and configuration and inputting a designated write address and designated write data at the same timing. An address delay circuit for delaying the input timing of the read address to the first dual-port memory by a predetermined delay timing from the input timing to the second dual-port memory; and the second delay circuit based on the specified read address. A data delay circuit for delaying the output timing of the data read from the dual port memory by a predetermined delay timing equivalent to the address delay circuit, the specified write address input to the first dual port memory, and Delayed read address and A comparison circuit for comparing whether or not
When the comparison result indicating the address match is not output from the comparison circuit, the data read from the first dual-port memory is selected, and when the comparison result indicating the address match is output from the comparison circuit, the data delay circuit is selected. A selection circuit for selecting data read from the second dual-port memory delayed through the second dual-port memory.
JP7190329A 1995-07-26 1995-07-26 Dual port memory control circuit Expired - Lifetime JP2723843B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP7190329A JP2723843B2 (en) 1995-07-26 1995-07-26 Dual port memory control circuit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP7190329A JP2723843B2 (en) 1995-07-26 1995-07-26 Dual port memory control circuit

Publications (2)

Publication Number Publication Date
JPH0945073A JPH0945073A (en) 1997-02-14
JP2723843B2 true JP2723843B2 (en) 1998-03-09

Family

ID=16256384

Family Applications (1)

Application Number Title Priority Date Filing Date
JP7190329A Expired - Lifetime JP2723843B2 (en) 1995-07-26 1995-07-26 Dual port memory control circuit

Country Status (1)

Country Link
JP (1) JP2723843B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100475093B1 (en) * 2002-09-13 2005-03-10 삼성전자주식회사 Integrated circuit device with two write ports or more and system thereof

Also Published As

Publication number Publication date
JPH0945073A (en) 1997-02-14

Similar Documents

Publication Publication Date Title
US7103702B2 (en) Memory device
JP2723843B2 (en) Dual port memory control circuit
US7080191B2 (en) Method and system for accessing memory devices
US6795874B2 (en) Direct memory accessing
JPS6334795A (en) Semiconductor storage device
US5745427A (en) Phase-shifted embedded ram apparatus and method
US6625711B1 (en) Method and/or architecture for implementing queue expansion in multiqueue devices
US6202187B1 (en) Pattern generator for use in a semiconductor test device
JPH05134007A (en) Semiconductor integrated logic circuit
JP2751822B2 (en) Memory control method for FIFO memory device
US6405293B1 (en) Selectively accessible memory banks for operating in alternately reading or writing modes of operation
JP2908331B2 (en) List vector processing system
JP2743051B2 (en) Image processing device
JP2868038B2 (en) Test circuit for semiconductor integrated circuit device
JPH0520474A (en) One chip microcomputer
JPH04321993A (en) Storage control device
JPH0290795A (en) Time divisional switch control system
JPH10162567A (en) Memory-discriminating device
JPH0587881A (en) Data log circuit
JPH0289300A (en) Semiconductor memory element
JPH10312356A (en) Data transfer device
JPH0719221B2 (en) Memory control method
JPH05128327A (en) Ic card
JPH02118722A (en) Fifo memory
JPH07141254A (en) Memory controller

Legal Events

Date Code Title Description
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 19971028