JPH11134256A - Address conversion circuit - Google Patents
Address conversion circuitInfo
- Publication number
- JPH11134256A JPH11134256A JP9301067A JP30106797A JPH11134256A JP H11134256 A JPH11134256 A JP H11134256A JP 9301067 A JP9301067 A JP 9301067A JP 30106797 A JP30106797 A JP 30106797A JP H11134256 A JPH11134256 A JP H11134256A
- Authority
- JP
- Japan
- Prior art keywords
- address
- conversion
- signal
- output
- holding
- 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
Links
- 238000006243 chemical reaction Methods 0.000 title claims abstract description 179
- 230000015654 memory Effects 0.000 claims abstract description 47
- 238000000034 method Methods 0.000 claims description 21
- 230000008569 process Effects 0.000 claims description 19
- 230000004044 response Effects 0.000 claims description 9
- 230000014759 maintenance of location Effects 0.000 claims 2
- 230000000717 retained effect Effects 0.000 claims 1
- 230000011664 signaling Effects 0.000 claims 1
- 238000010586 diagram Methods 0.000 description 11
- 230000007246 mechanism Effects 0.000 description 4
- 230000009467 reduction Effects 0.000 description 2
- 230000003068 static effect Effects 0.000 description 2
- 230000007704 transition Effects 0.000 description 2
- 101100118004 Arabidopsis thaliana EBP1 gene Proteins 0.000 description 1
- 101150052583 CALM1 gene Proteins 0.000 description 1
- 102100025580 Calmodulin-1 Human genes 0.000 description 1
- 101100459256 Cyprinus carpio myca gene Proteins 0.000 description 1
- 101150091339 cam-1 gene Proteins 0.000 description 1
- 238000010276 construction Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 230000006870 function Effects 0.000 description 1
- 239000004065 semiconductor Substances 0.000 description 1
Classifications
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D10/00—Energy efficient computing, e.g. low power processors, power management or thermal management
Landscapes
- Memory System Of A Hierarchy Structure (AREA)
Abstract
Description
【0001】[0001]
【発明の属する技術分野】本発明は、連想メモリなどを
使用し、第1のアドレスを第2のアドレスに変換して出
力するアドレス変換回路に関する。BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an address conversion circuit for converting a first address into a second address using a content addressable memory or the like and outputting the converted address.
【0002】[0002]
【従来の技術】連想メモリ(CAM; Content Addressa
ble Memory)などを使用し、与えられた第1のアドレス
を第2のアドレスに高速に変換して出力するアドレス変
換回路は、例えば、仮想記憶を採用したコンピュータシ
ステムにおいて、CPU(中央処理装置)が出力する仮
想アドレスを実際のメモリのアクセスに使用される物理
アドレスに変換する際に使用される。以下、説明を分か
りやすくするため、アドレス変換回路として、仮想アド
レスを物理アドレスに変換するTLB(Table Lockasid
e Buffer)によるアドレス変換回路について説明する。
図8は、TLBによるアドレス変換回路の構成を示すブ
ロック図である。2. Description of the Related Art Content addressable memories (CAMs)
For example, an address conversion circuit that converts a given first address to a second address at high speed and outputs the second address using a CPU (Central Processing Unit) in a computer system employing virtual memory Is used to convert the virtual address output by the to a physical address used for actual memory access. Hereinafter, in order to make the description easy to understand, a TLB (Table Lockasid) for converting a virtual address to a physical address is used as an address conversion circuit.
e Buffer) will be described.
FIG. 8 is a block diagram showing a configuration of an address conversion circuit based on TLB.
【0003】図8に示すTLB81は、仮想アドレス8
2の上位ビットをタグとして、物理アドレス83の上位
ビットを出力するものであり、物理アドレスの上位ビッ
トを格納するRAM(ランダム・アクセス・メモリ)で
あるPFN(物理フレーム番号; Physical Frame Numbe
r)用RAM84と、PFN用RAM84に格納された
物理アドレスに対応する仮想アドレスの上位ビットを保
持するとともに外部からの入力する仮想アドレス82の
上位ビットと比較するVPN(仮想ページ番号)用CA
M(連想メモリ)85と、から構成されている。VPN
用CAM85のエントリとPFN用RAM84のエント
リとは1対1に対応して組を構成し、このような組がT
LB81内に複数設けられ、入力する仮想アドレス82
の上位ビットに応じ、VPN用CAM85で一致するエ
ントリに対応するPFN用RAM84の内容が、TLB
81から出力される。この出力が物理アドレス83の上
位ビットとなる。なお、仮想記憶を採用したコンピュー
タシステムでは、メモリアドレスにおけるページの概念
も採用されていることが一般的であり、仮想アドレスか
ら物理アドレスへの対応関係は、ページごとに定まって
いる。したがって、仮想アドレス82のうち各ページに
対応する上位ビット部分が上述したようにTLB81に
入力してアドレス変換の対象となり、仮想アドレス82
の下位ビットは、そのまま物理アドレス83の下位ビッ
トとして使用される。[0003] The TLB 81 shown in FIG.
The upper bits of the physical address 83 are output using the upper 2 bits as a tag, and a PFN (Physical Frame Number) which is a RAM (random access memory) for storing the upper bits of the physical address.
r) a VPN (virtual page number) CA that holds the upper bits of the virtual address corresponding to the physical address stored in the RAM 84 for PFN and compares with the upper bits of the virtual address 82 input from the outside.
M (associative memory) 85. VPN
The CAM 85 entry and the PFN RAM 84 entry form a set in one-to-one correspondence.
A plurality of virtual addresses 82 provided and input in the LB 81
Of the RAM 84 for PFN corresponding to the entry that matches in the CAM 85 for VPN,
81. This output is the upper bits of the physical address 83. It is to be noted that a computer system employing virtual memory generally employs the concept of a page in a memory address, and the correspondence between a virtual address and a physical address is determined for each page. Therefore, the high-order bit portion corresponding to each page in the virtual address 82 is input to the TLB 81 as described above, and is subjected to address conversion.
Are used as they are as the lower bits of the physical address 83.
【0004】連想メモリであるVPN用CAM85は、
それぞれ1ヒット分のデータを格納するとともに入力ビ
ットとの比較を行う複数の連想メモリセルを有してい
る。そしてVPN用CAM85は、各エントリごとに、
そのエントリに属する連想メモリセルにおいて保持して
いるビットと入力ビットとが全て一致した場合に一致信
号を出力する。この一致信号に応じて、PFN用RAM
84から物理アドレス(の上位ビット)が出力すること
になる。A CAM 85 for VPN, which is an associative memory,
It has a plurality of associative memory cells each storing data for one hit and comparing with input bits. Then, the CAM 85 for VPN, for each entry,
When all the bits held in the associative memory cell belonging to the entry match the input bits, a match signal is output. In response to the coincidence signal, the PFN RAM
From 84, the physical address (upper bits of the physical address) is output.
【0005】図9は、VPN用CAMとして使用される
連想メモリの構成の一例を示す回路図である。ここで
は、連想メモリの1エントリ分の構成が示されている。FIG. 9 is a circuit diagram showing an example of the configuration of an associative memory used as a VPN CAM. Here, the configuration for one entry of the associative memory is shown.
【0006】この連想メモリは、それぞれ1ビット分の
データを格納するとともに入力ビットとの比較を行う複
数の連想メモリセル911〜91nを有し、各連想メモリ
セル911〜91nに共通に、ワード線92、比較制御線
96及び一致信号線97が備えられている。これらワー
ド線92、比較制御線96及び一致信号線97は、図示
横方向(行方向)に延びている。仮想アドレスの上位ビ
ットのそれぞれのビットに対応して、これらの連想メモ
リセル911〜91nが設けられている。一致信号線97
は、プリチャージ制御線94によってゲート制御がなさ
れるトランジスタT0を介して、電源に接続されてい
る。各連想メモリセル911〜91nでは、2つのインバ
ータI0,I1をたすきがけに接続して1ビット分のス
タティック型の記憶素子が構成されるとともに、この記
憶素子部分へのデータ入出力のために8個のトランジス
タT1〜T8が設けられている。また各連想メモリセル
91 1〜91nに対して、保持すべきビットデータを入力
するためのビット線93,93'と、比較対象のビットデ
ータを入力するための比較ビット線95,95'が設けら
れている。ビット線93'上のデータは、ビット線93
上のデータをインバータI2で反転させたものであり、
比較ビット線95'上のデータは、比較ビット線95上
のデータをインバータI3で反転させたものである。This associative memory has a capacity of one bit.
A function that stores data and compares it with input bits.
Number of associative memory cells 911~ 91nAnd each associative memory
Cell 911~ 91n, A word line 92, a comparison control line
96 and a coincidence signal line 97 are provided. These words
Line 92, comparison control line 96 and match signal line 97 are shown
It extends in the horizontal direction (row direction). Top address of virtual address
These associative notes correspond to each bit of the
Recell 911~ 91nIs provided. Match signal line 97
Indicates that gate control is not performed by the precharge control line 94.
Connected to the power supply via the transistor T0
You. Each associative memory cell 911~ 91nThen, two inva
Data I0 and I1 are connected to each other,
With the construction of a static type storage element,
8 transistors for input / output of data to storage device
Terminals T1 to T8 are provided. Each associative memory cell
91 1~ 91nInput bit data to be held
Bit lines 93, 93 'for comparison and the bit data to be compared.
Bit lines 95 and 95 'for inputting data
Have been. The data on the bit line 93 'is
The above data is inverted by the inverter I2,
The data on the comparison bit line 95 ′ is
Is inverted by the inverter I3.
【0007】各連想メモリセル911〜91nにおいて、
トランジスタT1は、比較ビット線93'とインバータ
I0の入力(インバータI1の出力)との間に挿入さ
れ、トランジスタT2は、比較ビット線93とインバー
タI0の出力(インバータI1の入力)との間に挿入さ
れ、これらトランジスタT1,T2のゲートは、ワード
線92に接続している。また、トランジスタT3,T5,
T7はチャネルが直列に接続し、トランジスタT3が一
致信号線97側になるように、一致信号線97と接地電
位との間に挿入されている。同様に、トランジスタT
4,T6,T8はチャネルが直列に接続し、トランジスタ
T4が一致信号線97側になるように、一致信号線97
と接地電位との間に挿入されている。トランジスタT
3,T4のベースはそれぞれインバータI0の入力と出
力に接続し、トランジスタT5,T6のベースはそれぞ
れ比較ビット線95,95'に接続している。トランジス
タT7,T8のベースは比較制御線96に接続してい
る。In each of the associative memory cells 91 1 to 91 n ,
The transistor T1 is inserted between the comparison bit line 93 'and the input of the inverter I0 (output of the inverter I1), and the transistor T2 is inserted between the comparison bit line 93 and the output of the inverter I0 (input of the inverter I1). The gates of these transistors T1 and T2 are connected to a word line 92. Also, transistors T3, T5,
T7 is connected between the match signal line 97 and the ground potential so that the channel is connected in series and the transistor T3 is on the match signal line 97 side. Similarly, the transistor T
4, T6 and T8 are connected in series, and the matching signal line 97 is set so that the transistor T4 is on the matching signal line 97 side.
And ground potential. Transistor T
The bases of T3 and T4 are connected to the input and output of the inverter I0, respectively, and the bases of the transistors T5 and T6 are connected to comparison bit lines 95 and 95 ', respectively. The bases of the transistors T7 and T8 are connected to the comparison control line 96.
【0008】このような連想メモリセルにおいて、ワー
ド線92がハイレベル(以下、単にハイという)になる
と、トランジスタT1,T2がオン状態となり、ビット
線93,93'が記憶素子部分に接続することになって、
データの書き込みや読み出しが可能になる。また、記憶
素子部分に記憶された内容(メモリセルに記憶された
値)にしたがって、トランジスタT3またはトランジス
タT4のどちらか一方だけがオン状態となる。In such an associative memory cell, when the word line 92 goes high (hereinafter simply referred to as high), the transistors T1 and T2 are turned on, and the bit lines 93 and 93 'are connected to the storage element. become,
Data can be written or read. In addition, only one of the transistor T3 and the transistor T4 is turned on in accordance with the content stored in the storage element portion (the value stored in the memory cell).
【0009】実際の連想メモリ動作は、比較制御線96
をロウレベル(以下、単にロウという)にしたまま、ま
ず、プリチャージ信号線94をハイにしてトランジスタ
T0をオン状態とし、一致信号線97を電源線に接続し
て電荷を蓄え、一致信号線97の電位をハイ状態とする
動作(プリチャージ動作)から開始する。プリチャージ
が終わると、プリチャージ信号線94がロウとなり、ト
ランジスタT0がオフに遷移して、一致信号線97への
電荷の供給が停止する。電荷の供給が止まっても、一致
信号線97は、リーク以外の放電経路がないため、ハイ
の状態を一定時間保持することができる。The actual associative memory operation is performed by comparing control line 96
At a low level (hereinafter simply referred to as low), first, the precharge signal line 94 is set high to turn on the transistor T0, and the match signal line 97 is connected to the power supply line to store electric charges. The operation is started from an operation (precharge operation) for setting the potential of the high state to a high state. When the precharge ends, the precharge signal line 94 goes low, the transistor T0 transitions to off, and the supply of charges to the match signal line 97 stops. Even when the supply of the electric charge is stopped, the coincidence signal line 97 can maintain the high state for a certain period of time because there is no discharge path other than the leakage.
【0010】次に、比較ビット線95によって、比較す
べきアドレスを設定する。すると、比較ビット線95,
95'上の信号により、トランジスタT5またはトラン
ジスタT6のどちらか一方だけがオンとなる。この状態
で、比較制御線96をハイにすると、トランジスタT
7,T8がいずれもオンとなり、記憶素子部分での記憶
内容と、比較ビット線95,95'上のデータ内容にした
がって、一致信号線97と接地電位との間に電流経路
(トランジスタT3,T5,T7による経路とトランジス
タT4,T6,T8による経路)が開かれたり閉じたりす
る。電流経路が形成された場合、一致信号線97に蓄積
されていた電荷が放電し、一致信号線97の電位がロウ
ヘ変化する。電流経路が遮断された状態では、一致信号
線97は、当然、ハイの状態を保っている。Next, an address to be compared is set by the comparison bit line 95. Then, the comparison bit line 95,
The signal on 95 'turns on only one of the transistors T5 or T6. In this state, when the comparison control line 96 is set high, the transistor T
7 and T8 are both turned on, and a current path (transistors T3 and T5) is provided between the coincidence signal line 97 and the ground potential according to the storage content of the storage element portion and the data content on the comparison bit lines 95 and 95 '. , T7 and transistors T4, T6, T8) are opened or closed. When the current path is formed, the charge stored in the match signal line 97 is discharged, and the potential of the match signal line 97 changes to low. When the current path is cut off, the coincidence signal line 97 keeps a high state.
【0011】このような連想メモリセル911〜91
nが、図示横方向(行方向)に、比較すべきビット数、
すなわち仮想アドレスの上位ビットのビット数の分だけ
設置されており、すべてのビットでの比較が一致した場
合のみ、一致信号線97の放電経路が遮断され、その電
位がハイとなる。1ビットでも不一致があると、その不
一致の連想メモリセルの放電経路から電荷が放電するの
で、一致信号線97の電位がロウとなる。Such associative memory cells 91 1 to 91
n is the number of bits to be compared in the horizontal direction (row direction)
That is, the number of bits is set corresponding to the number of higher-order bits of the virtual address, and only when the comparisons of all the bits match, the discharge path of the match signal line 97 is cut off, and the potential becomes high. If there is a mismatch even in one bit, the charge is discharged from the discharge path of the mismatched associative memory cell, and the potential of the match signal line 97 becomes low.
【0012】上述したTLB81では、比較ビット線9
5に仮想アドレス(の上位ビット)を入力し、通常の半
導体メモリで構成されるPFN用RAM84のワード線
をVPN用CAM85の一致信号線97に接続すること
により、仮想アドレスから物理アドレスへの変換を簡単
に行うことができる。In the above-described TLB 81, the comparison bit line 9
5, the virtual address is converted from the virtual address to the physical address by connecting the word line of the RAM 84 for PFN composed of a normal semiconductor memory to the match signal line 97 of the CAM 85 for VPN. Can be done easily.
【0013】ところで以上説明した従来のTLB81
は、マルチタスク処理を行うコンピュータに適用した場
合、このままではタスクの別を識別することができない
ため、コンテクストスイッチが生じたときに、TLB8
1の内容を全て無効にし、新しいタスクでの仮想アドレ
スと物理アドレスとをTLB81内にロードする必要が
生じることがある。そこで、特開昭63−81548号
公報などには、タスク識別子(プロセス番号すなわちプ
ロセスID)を導入し、各タスクごとにタスクを特定す
るためのプロセスIDを付与するとともに、このプロセ
スIDと仮想アドレスとをタグにして物理アドレスを発
生する技術が開示されている。The above-described conventional TLB 81
Is applied to a computer that performs multi-task processing, the task cannot be identified as it is. Therefore, when a context switch occurs, the TLB8
In some cases, it is necessary to invalidate all the contents of 1 and load the virtual address and the physical address in the new task into the TLB 81. Therefore, in Japanese Patent Application Laid-Open No. 63-81548, a task identifier (process number, that is, a process ID) is introduced, a process ID for specifying a task is assigned to each task, and the process ID and the virtual address are assigned. A technology for generating a physical address using tags as tags has been disclosed.
【0014】[0014]
【発明が解決しようとする課題】上述したようなアドレ
ス変換回路は、多数の連想メモリセルから構成された連
想メモリを使用するが、この連想メモリは、SRAM
(スタティック・ランダム・アクセス・メモリ)やDR
AM(ダイナミック・ランダム・アクセス・メモリ)と
異なって比較のための回路を有し、そのため、格納され
た記憶内容を単に保持するために必要な消費電力はSR
AMなどと同じようなものであるものの、アドレス変換
のために比較動作まで行わせた場合には、例えば一致信
号線の充放電などを伴うため、消費電力はかなり大きく
なる。これによって、アドレス変換回路自体の消費電力
も大きくなり、アドレス変換回路を他の回路とともに組
み込んだLSI(大規模集積回路)を構成する際の不都
合ともなっている。The above-described address conversion circuit uses an associative memory composed of a large number of associative memory cells.
(Static random access memory) or DR
Unlike an AM (Dynamic Random Access Memory), it has a circuit for comparison, so that the power consumption required to simply hold the stored contents is SR
Although it is similar to AM and the like, if the comparison operation is performed for address conversion, for example, the charge / discharge of the coincidence signal line is involved, so that the power consumption becomes considerably large. As a result, the power consumption of the address conversion circuit itself increases, which is a disadvantage when configuring an LSI (large-scale integrated circuit) in which the address conversion circuit is incorporated together with other circuits.
【0015】本発明の目的は、消費電力を削減すること
ができるアドレス変換回路を提供することにある。An object of the present invention is to provide an address conversion circuit capable of reducing power consumption.
【0016】[0016]
【課題を解決するための手段】本発明のアドレス変換回
路は、第1のアドレスを第2のアドレスに変換するアド
レス変換回路であって、変換開始信号に応じてアドレス
比較動作を行い、第2のアドレスである出力情報に第1
のアドレスを変換するアドレス変換手段と、前回の変換
時の第1のアドレスを保持するアドレス保持手段と、現
在の第1のアドレスとアドレス保持手段に保持されてい
る第1のアドレスとを比較する比較手段と、アドレス変
換手段が出力する出力情報を書込信号に応じて取り込
み、保持する出力情報保持手段と、アドレス変換手段か
らの現在の出力情報と出力情報保持手段に保持されてい
る出力情報のいずれかを選択信号に応じて選択し出力す
る選択手段と、変換要求があったときに比較手段におい
て一致と判別されているときには、変換開始信号を出力
することなく出力情報保持手段に保持されている出力情
報が選択手段から出力するように選択信号によって制御
し、変換要求があったときに比較手段において不一致と
判別されているときには、変換開始信号及び書込信号を
出力し、アドレス変換手段からの現在の出力情報が選択
手段から出力するように選択信号によって制御する制御
手段と、を有する。An address conversion circuit according to the present invention is an address conversion circuit for converting a first address into a second address. The address conversion circuit performs an address comparison operation in accordance with a conversion start signal. Output information which is the address of
Address conversion means for converting the first address, an address holding means for holding the first address at the time of the previous conversion, and a comparison between the current first address and the first address held in the address holding means. A comparison unit, an output information holding unit that captures and holds output information output by the address conversion unit in response to a write signal, and a current output information from the address conversion unit and an output information held by the output information holding unit. And selecting means for selecting and outputting any of them according to the selection signal, and when the conversion means determines that they match, the conversion information is held in the output information holding means without outputting a conversion start signal. When the output signal is controlled by the selection signal so that the output information is output from the selection means, and when the conversion means requests, the comparison means determines that they do not match. Outputs a conversion start signal and a write signal, and a control means for controlling the selection signals as the current output information from the address translation means is output from the selecting means.
【0017】すなわち本発明では、典型的には連想メモ
リで構成されているアドレス変換手段によって例えば仮
想アドレスである第1のアドレスを例えば物理アドレス
である第2のアドレスに変換する際に、アドレス変換手
段でのアドレス比較動作の回数を減らすことにより、ア
ドレス変換回路全体としての消費電力を削減する。具体
的には、変換要求が変換要求信号として入力するとし
て、仮想アドレスレジスタなどのアドレス保持手段に前
回の変換時の比較アドレス(第1のアドレス)を保持し
ておき、比較器などの比較手段により、前回の仮想アド
レスと今回の仮想アドレスとを比較する。そして両者が
一致しているとき、すなわち前回のアドレス変換結果を
流用可能なときには、連想メモリでのアドレス比較を抑
止し、その代わり、物理アドレスレジスタなどの出力情
報保持手段(または第2のアドレス保持手段)に格納さ
れている前回の変換結果(物理アドレス)をセレクタな
どの選択手段で選択してこのアドレス変換回路からの出
力としている。このような処理を実行するために、制御
回路(制御手段)が、変換要求信号と一致信号とに応じ
て、変換開始信号、レジスタ書込信号及び選択信号を生
成するようにする。That is, in the present invention, when the first address, which is, for example, a virtual address, is converted into the second address, which is, for example, a physical address, by an address conversion means typically constituted by an associative memory, the address conversion is performed. The power consumption of the entire address conversion circuit is reduced by reducing the number of address comparison operations by the means. Specifically, assuming that the conversion request is input as a conversion request signal, the comparison address (first address) at the time of the previous conversion is held in an address holding unit such as a virtual address register, and the comparison unit such as a comparator is stored. To compare the previous virtual address with the current virtual address. When they match, that is, when the previous address conversion result can be used, address comparison in the associative memory is suppressed, and instead, output information holding means such as a physical address register (or second address holding means) is used. Means), the previous conversion result (physical address) stored in the address conversion circuit is selected by a selection means such as a selector and output from the address conversion circuit. In order to execute such processing, the control circuit (control means) generates a conversion start signal, a register write signal, and a selection signal according to the conversion request signal and the coincidence signal.
【0018】[0018]
【発明の実施の形態】次に、本発明の実施の形態につい
て、図面を参照して説明する。Next, an embodiment of the present invention will be described with reference to the drawings.
【0019】《第1の実施形態》図1は、本発明の第1
の実施形態のアドレス変換回路の構成を示すブロック図
である。ここでは、仮想記憶システムにおいてCPU
(不図示)側から出力される仮想アドレスを物理アドレ
スに変換するために使用されるアドレス変換回路を例に
挙げて説明する。このアドレス変換回路は、CPUから
変換要求信号が出力されたときに、仮想アドレスから物
理アドレスの変換を行うものとする。図においては、単
に「仮想アドレス」、「物理アドレス」と記載されてい
るが、当然のことながら、これらはそれぞれ、仮想アド
レスの上位ビット、物理アドレスの上位ビットのことで
ある。またこの種のアドレス変換回路では、入力する仮
想アドレスと一致するエントリがない場合の制御や、予
めアドレス変換回路内にアドレスデータを格納するため
の制御が必要であって、そのための制御機構が設けられ
ているが、ここでは説明を分かりやすくするため、その
ような制御機構については図示していない。<< First Embodiment >> FIG. 1 shows a first embodiment of the present invention.
FIG. 3 is a block diagram illustrating a configuration of an address conversion circuit according to the embodiment. Here, CPU in the virtual storage system
An address conversion circuit used to convert a virtual address output from a (not shown) side into a physical address will be described as an example. This address conversion circuit converts a virtual address to a physical address when a conversion request signal is output from the CPU. In the figure, although they are simply described as “virtual address” and “physical address”, these are, of course, the upper bits of the virtual address and the upper bits of the physical address, respectively. In this type of address conversion circuit, control when there is no entry matching the input virtual address and control for storing address data in the address conversion circuit in advance are necessary, and a control mechanism for this is provided. However, such a control mechanism is not shown here for the sake of simplicity.
【0020】図8に示した従来のアドレス変換回路と同
様に、TLB11が設けられ、TLB11内にはVPN
用CAM12とPFN用RAM13が設けられている。
ここでVPN用CAM12とPFN用RAM13として
は、従来のものと同様のものが使用されるが、このうち
VPN用CAM12については、変換開始信号の入力に
よって初めてアドレス比較動作を行い、変換開始信号の
入力がないうちはアドレス比較動作を行わずに記憶内容
の保持動作のみを行うものが使用される。このようなV
PN用CAM12として、例えば、上述の図9に示した
連想メモリを使用することができる。図9に示す連想メ
モリを使用する場合であれば、変換開始信号の入力前に
はワード線92やプリチャージ制御線94、比較制御線
96をいずれもロウレベルに保持して各連想メモリセル
がその記憶内容の保持動作のみを行い、変換開始信号の
入力に応じて上述の手順にしたがいワード線92やプリ
チャージ制御線94、比較制御線96のレベルを変化さ
れアドレス比較動作が行われるようにすればよい。As in the conventional address conversion circuit shown in FIG. 8, a TLB 11 is provided.
CAM 12 and PFN RAM 13 are provided.
Here, the same as the conventional one is used as the VPN CAM 12 and the PFN RAM 13. Among them, the VPN CAM 12 performs an address comparison operation for the first time upon input of the conversion start signal, and outputs the conversion start signal. As long as there is no input, one that performs only the operation of retaining the stored contents without performing the address comparison operation is used. Such a V
As the PN CAM 12, for example, the above-described associative memory shown in FIG. 9 can be used. If the associative memory shown in FIG. 9 is used, before the conversion start signal is input, the word line 92, the precharge control line 94, and the comparison control line 96 are all held at a low level so that each associative memory cell Only the operation of retaining the stored contents is performed, and the levels of the word line 92, the precharge control line 94, and the comparison control line 96 are changed according to the above-described procedure according to the input of the conversion start signal, so that the address comparison operation is performed. I just need.
【0021】さらにこのアドレス変換回路には、CPU
側から入力する変換要求信号に応じて仮想アドレスをラ
ッチする仮想アドレスレジスタ14と、現在の仮想アド
レスと仮想アドレスレジスタ14が保持している仮想ア
ドレスとを比較し、両者が一致しているときに一致信号
を出力する比較器15と、変換要求信号と一致信号とを
入力として変換終了信号、変換開始信号、レジスタ書込
信号及び選択信号を出力する制御回路16と、PFN用
RAM13から出力される物理アドレスをレジスタ書込
信号に応じてラッチする物理アドレスレジスタ17と、
PFN用RAM13が現在出力している物理アドレスと
物理アドレスレジスタ17に保持されている物理アドレ
スとを選択信号に応じて選択するセレクタ18とを備え
ている。セレクタ18から、このアドレス変換回路の出
力としての物理アドレスが出力する。セレクタ18は、
選択信号が出力された場合("1"の場合)に、物理アド
レスレジスタ17の方を選択する。Further, the address conversion circuit includes a CPU
The virtual address register 14 that latches the virtual address in response to the conversion request signal input from the side and the current virtual address and the virtual address held by the virtual address register 14 are compared. A comparator 15 that outputs a coincidence signal, a control circuit 16 that receives a conversion request signal and a coincidence signal as input, and outputs a conversion end signal, a conversion start signal, a register write signal, and a selection signal, and outputs from the PFN RAM 13 A physical address register 17 for latching a physical address according to a register write signal;
A selector 18 is provided for selecting a physical address currently output by the PFN RAM 13 and a physical address held in the physical address register 17 in accordance with a selection signal. The selector 18 outputs a physical address as an output of the address conversion circuit. The selector 18
When the selection signal is output (in the case of “1”), the physical address register 17 is selected.
【0022】このアドレス変換回路では、外部のCPU
などから出力される仮想アドレスは、VPN用CAM1
2、仮想アドレスレジスタ14及び比較器15に供給さ
れている。そして、変換要求信号に応じて仮想アドレス
が仮想アドレスレジスタ14にラッチされることによ
り、仮想アドレスレジスタ14の内容は前回の変換要求
信号の出力時の仮想アドレスである。そこで、比較器1
5によって前回の仮想アドレスと今回の仮想アドレスと
を比較し、一致しているとき、すなわち前回のアドレス
変換結果を流用可能なときには、VPN用CAM12で
のアドレス比較を抑止し、その代わり、物理アドレスレ
ジスタ17に格納されている前回の変換結果(物理アド
レス)をセレクタ18で選択してこのアドレス変換回路
からの出力としている。このような処理を実行するため
に、制御回路16は、変換要求信号と一致信号とに応じ
て、変換開始信号、レジスタ書込信号及び選択信号を生
成する。なお、制御回路16は変換終了信号も生成する
が、この変換終了信号は、アドレス変換が終了したこと
をCPU側に通知するために使用される。In this address conversion circuit, an external CPU
The virtual address output from such as CAM1 for VPN
2. It is supplied to the virtual address register 14 and the comparator 15. Then, the virtual address is latched in the virtual address register 14 in response to the conversion request signal, so that the content of the virtual address register 14 is the virtual address at the time of the previous output of the conversion request signal. Therefore, the comparator 1
5, the previous virtual address is compared with the current virtual address, and when they match, that is, when the previous address conversion result can be used, the address comparison in the VPN CAM 12 is suppressed, and the physical address is replaced. The previous conversion result (physical address) stored in the register 17 is selected by the selector 18 and output from the address conversion circuit. To execute such a process, the control circuit 16 generates a conversion start signal, a register write signal, and a selection signal according to the conversion request signal and the coincidence signal. The control circuit 16 also generates a conversion end signal. This conversion end signal is used to notify the CPU that the address conversion has been completed.
【0023】図2は、制御回路16の内部構成を示す回
路図である。以下の説明では、回路は正論理にしたがっ
て動作し、ハイレベルが"1"に、ロウレベルが"0"に対
応するものとする。FIG. 2 is a circuit diagram showing the internal configuration of the control circuit 16. In the following description, it is assumed that the circuit operates according to positive logic, and the high level corresponds to "1" and the low level corresponds to "0".
【0024】制御回路16は、一致信号を反転するイン
バータ21と、変換要求信号とインバータ21の出力の
論理積を求めてこれを変換開始信号として出力する第1
のAND(アンド)ゲート22と、変換要求信号と一致
信号の出力の論理積を求める第2のANDゲート23
と、所定のクロック信号CLKに基づいて変換開始信号
をラッチしレジスタ書込信号として出力する第1のD型
フリップフロップ24と、クロック信号CLKに基づい
て第2のANDゲート23の出力をラッチし選択信号と
して出力する第2のD型フリップフロップ25と、レジ
スタ書込信号及び選択信号の論理和を求めて変換終了信
号として出力するOR(オア)ゲート26と、から構成
されている。The control circuit 16 calculates the logical product of the inverter 21 for inverting the coincidence signal and the conversion request signal and the output of the inverter 21 and outputs the logical product as the conversion start signal.
Gate 22 and a second AND gate 23 for calculating the logical product of the conversion request signal and the output of the coincidence signal
And a first D-type flip-flop 24 for latching a conversion start signal based on a predetermined clock signal CLK and outputting it as a register write signal, and latching an output of a second AND gate 23 based on the clock signal CLK. It comprises a second D-type flip-flop 25 that outputs as a selection signal, and an OR (or) gate 26 that obtains a logical sum of the register write signal and the selection signal and outputs it as a conversion end signal.
【0025】このように制御回路16を構成することに
よって、変換要求信号が入力しても、一致信号が"1"、
すなわち前回と今回とで仮想アドレスが同じときには、
変換開始信号は出力されず、VPN用CAM12でのア
ドレス比較動作は行われない。その代わり、1クロック
遅れて選択信号が"1"となって出力され、それにより、
物理アドレスレジスタ17の内容が物理アドレスとして
セレクタ18から出力されることになる。一方、一致信
号が"0"、すなわち前回と今回とで仮想アドレスが異な
るときは、変換要求信号が入力すると、第1のANDゲ
ート22から変換開始信号が出力され、これによってV
PN用CAM12でのアドレス比較動作が行われ、1ク
ロック(TBL11での入力から出力までの遅延時間)
ののちに、変換後の物理アドレスがPFN用RAM13
から出力する。このとき、選択信号は出力されていない
のでこの物理アドレスがそのままセレクタ18から外部
に出力されるとともに、レジスタ書込信号が発生し、次
回の仮想アドレスが今回のものと一致したときに物理ア
ドレスを出力するために、この物理アドレスは、物理ア
ドレスレジスタ17にラッチされる。By configuring the control circuit 16 in this manner, even if the conversion request signal is input, the coincidence signal is "1",
That is, when the virtual address is the same in the previous time and this time,
The conversion start signal is not output, and the address comparison operation in the VPN CAM 12 is not performed. Instead, the selection signal is output as "1" with a delay of one clock,
The content of the physical address register 17 is output from the selector 18 as a physical address. On the other hand, when the match signal is “0”, that is, when the virtual address is different between the previous time and the current time, when the conversion request signal is input, the conversion start signal is output from the first AND gate 22, whereby the V
An address comparison operation is performed in the PN CAM 12, and one clock (delay time from input to output in the TBL 11)
After that, the converted physical address is stored in the PFN RAM 13.
Output from At this time, since the selection signal has not been output, this physical address is output as it is from the selector 18 to the outside, and a register write signal is generated, and the physical address is changed when the next virtual address matches the current one. This physical address is latched in the physical address register 17 for output.
【0026】以上の動作をまとめたタイミングチャート
を図3に示す。図3において、「不一致時」、「一致
時」とは、それぞれ、今回の仮想アドレスと仮想アドレ
スレジスタ14に格納されている前回の仮想アドレスと
が不一致のとき、一致しているときを表している。ま
た、仮想アドレスAに対応する物理アドレスをA'で表
している。FIG. 3 is a timing chart summarizing the above operation. In FIG. 3, “at the time of non-match” and “at the time of match” represent the time when the current virtual address does not match and the time when the previous virtual address stored in the virtual address register 14 matches, respectively. I have. A physical address corresponding to the virtual address A is represented by A '.
【0027】以上説明した本実施形態のアドレス変換回
路では、前回の仮想アドレスと今回の仮想アドレスとを
比較し、一致しているときにはVPN用CAM12での
アドレス比較を抑止し、その代わり、物理アドレスレジ
スタ17に格納されている前回の変換結果(物理アドレ
ス)を選択する。その結果、仮想アドレスにおける同じ
ページの中で連続してアドレス変換を行うような場合に
は、最初の1回だけはVPN用CAM12でのアドレス
比較動作を必要とするが、2回目以降はアドレス比較動
作を必要とせず、VPN用CAM12を低消費電力状態
(記憶内容の保持のみを行う状態)とすることできる。
一般にソフトウェアプログラムの局所参照性は大きいの
で、ページサイズを適正に設計し、適切なプログラミン
グを行うことにより、異なるページへのアドレスの遷移
を著しく減らすことができる。そのような場合には、本
実施形態のアドレス変換回路の構成とすることによっ
て、従来のアドレス変換回路に比べ、大幅な消費電力の
削減が達成される。In the address conversion circuit of the present embodiment described above, the previous virtual address is compared with the current virtual address, and when they match, the address comparison in the VPN CAM 12 is suppressed. The previous conversion result (physical address) stored in the register 17 is selected. As a result, when address conversion is performed continuously in the same page of the virtual address, the address comparison operation in the VPN CAM 12 is required only once, but the address comparison operation is performed after the second time. Operation is not required, and the VPN CAM 12 can be set to a low power consumption state (a state in which only stored contents are held).
In general, since the local referability of a software program is large, by appropriately designing the page size and performing appropriate programming, the transition of addresses to different pages can be significantly reduced. In such a case, the configuration of the address conversion circuit according to the present embodiment achieves a significant reduction in power consumption as compared with the conventional address conversion circuit.
【0028】またこのアドレス変換回路では、前回の仮
想アドレスと今回の仮想アドレスとが一致しているとき
にはVPN用CAM12やPFN用RAM13を使用し
ないため、従来のアドレス変換回路に比べ、より早く物
理アドレスを得ることができる。Also, in this address conversion circuit, when the previous virtual address and the current virtual address match, the CAM 12 for VPN and the RAM 13 for PFN are not used, so that the physical address is faster than in the conventional address conversion circuit. Can be obtained.
【0029】《第2の実施形態》図4は、本発明の第2
の実施形態のアドレス変換回路の構成を示している。こ
こではコンテクストスイッチ(タスク切替え)に伴うT
LBの無効化を防止するために、TLB自体にプロセス
ID(プロセス番号)を保持させ、プロセスIDと仮想
アドレスとをタグにして物理アドレスへの変換を行うよ
うにしている。<< Second Embodiment >> FIG. 4 shows a second embodiment of the present invention.
3 shows a configuration of an address conversion circuit according to the embodiment. Here, T associated with a context switch (task switching)
In order to prevent invalidation of the LB, a process ID (process number) is held in the TLB itself, and conversion to a physical address is performed using the process ID and the virtual address as tags.
【0030】TLB31として、VPN用CAM12及
びPFN用RAM13の他に、タグとしてのプロセスI
Dに対する連想メモリであるPRID用CAM32を備
えるものを使用する。PRID用CAM32は、VPN
用CAM12と一体となってアドレス比較動作を行うも
のであるが、VPN用CAM12とは別個に変換開始信
号が与えられ、またVPN用CAM12でのアドレス変
換動作よりも1クロック早くアドレス変換動作を行うよ
うに構成されている。具体的には、上述の図9に示すよ
うな連想メモリにおいて、複数の連想メモリセルが接続
した1本のワード線の領域をPRID用CAM32用の
部分とVPN用CAM12用の部分とに分割し、一致信
号線においては両者の境界部分にラッチ回路を設けると
ともに、比較制御線は両者で別個に設けられるような構
成とすればよい。PRID用CAM32には、CPU内
に設けられたプロセスIDレジスタ33からプロセスI
Dが供給されている。またこのアドレス変換回路では、
PRID用CAM32とVPN用CAM12とに別個に
変換開始信号(それぞれ、PRID変換開始信号、VP
N変換開始信号とする)を与えるため、制御回路の内部
構成が図1に示すアドレス変換回路の場合(図2参照)
と異なっている。制御回路34の内部構成を図5に示
す。その他の点ではこのアドレス変換回路は図1に示す
アドレス変換回路と同一である。As the TLB 31, in addition to the VPN CAM 12 and the PFN RAM 13, a process I as a tag is performed.
A memory having a PRID CAM 32 which is an associative memory for D is used. The CAM for PRID 32 is a VPN
Address comparison operation is performed integrally with the CAM 12 for use, a conversion start signal is provided separately from the CAM 12 for VPN, and the address conversion operation is performed one clock earlier than the address conversion operation in the CAM 12 for VPN. It is configured as follows. Specifically, in the associative memory as shown in FIG. 9 described above, one word line region to which a plurality of associative memory cells are connected is divided into a portion for the CAM 32 for PRID and a portion for the CAM 12 for VPN. In addition, a latch circuit may be provided at the boundary between the coincidence signal lines, and the comparison control line may be separately provided for both. The PRID CAM 32 stores a process ID from a process ID register 33 provided in the CPU.
D is supplied. In this address conversion circuit,
The conversion start signals (PRID conversion start signal, VP respectively) are separately provided for the CAM 32 for PRID and the CAM 12 for VPN.
In the case where the internal configuration of the control circuit is the address conversion circuit shown in FIG. 1 (see FIG. 2)
Is different. FIG. 5 shows the internal configuration of the control circuit 34. In other respects, this address conversion circuit is the same as the address conversion circuit shown in FIG.
【0031】制御回路34は、一致信号を反転するイン
バータ41と、変換要求信号とインバータ41の出力の
論理積を求める第1のANDゲート42と、変換要求信
号と一致信号の出力の論理積を求める第2のANDゲー
ト43と、所定のクロック信号CLKに基づいて第1の
ANDゲート42の出力をラッチしVPN変換開始信号
として出力する第1のD型フリップフロップ44と、ク
ロック信号CLKに基づいて第2のANDゲート43の
出力をラッチし選択信号として出力する第2のD型フリ
ップフロップ45と、クロック信号CLKに基づいてV
PN変換開始信号をラッチしレジスタ書込信号として出
力する第3のD型フリップフロップ46と、クロック信
号CLKに基づいて第2のD型フリップフロップ45の
出力をラッチし選択信号として出力する第4のD型フリ
ップフロップ47と、レジスタ書込信号及び選択信号の
論理和を求めて変換終了信号として出力するORゲート
48と、から構成されている。また、変換要求信号は、
そのままで、PRID変換開始信号としても出力する。The control circuit 34 inverts the coincidence signal, an AND gate 42 for calculating the logical product of the conversion request signal and the output of the inverter 41, and calculates the logical product of the conversion request signal and the output of the coincidence signal. A second AND gate 43 to be obtained, a first D-type flip-flop 44 for latching an output of the first AND gate 42 based on a predetermined clock signal CLK and outputting the same as a VPN conversion start signal, and a clock signal CLK A second D-type flip-flop 45 that latches the output of the second AND gate 43 and outputs the selected signal as a selection signal;
A third D-type flip-flop 46 that latches the PN conversion start signal and outputs the same as a register write signal, and a fourth D-type flip-flop 45 that latches the output of the second D-type flip-flop 45 based on the clock signal CLK and outputs the same as a selection signal. D-type flip-flop 47, and an OR gate 48 that calculates the logical sum of the register write signal and the selection signal and outputs the result as a conversion end signal. The conversion request signal is
As it is, it is also output as a PRID conversion start signal.
【0032】このように制御回路34を構成することに
よって、変換要求信号が入力した場合にそれが直ちにP
RID変換開始信号としてPRID用CAM32に出力
する。したがって、変換要求信号の発生のたびにPRI
D用CAM32においてアドレス比較動作が行われるこ
とになるが、PRID用CAM32のビット幅(プロセ
スIDのビット幅)は、VPN用CAM12の入力ビッ
ト幅すなわち仮想アドレス(の上位ビット)のビット幅
に比べて小さく、変換要求信号の発生のたびにPRID
用CAM32がアドレス比較動作を行ったとしても、消
費電力の上昇は小さい。なお、プロセスIDでのアドレ
ス比較動作を仮想アドレスでのアドレス比較動作に先行
して実行するのは、コンテクストスイッチ時の動作を保
証するためにCPUからプロセスIDが仮想アドレスに
先行して出力されるためである。By configuring the control circuit 34 in this manner, when a conversion request signal is input, it immediately
The signal is output to the PRID CAM 32 as a RID conversion start signal. Therefore, each time a conversion request signal is generated, the PRI
The address comparison operation is performed in the D CAM 32. The bit width of the PRID CAM 32 (the bit width of the process ID) is smaller than the input bit width of the VPN CAM 12, that is, the bit width of the virtual address (upper bit of the virtual address). And the PRID is generated every time a conversion request signal is generated.
Even if the CAM 32 performs the address comparison operation, the increase in power consumption is small. The reason why the address comparison operation using the process ID is performed prior to the address comparison operation using the virtual address is that the CPU outputs the process ID prior to the virtual address in order to guarantee the operation during the context switch. That's why.
【0033】また、この制御回路34は、VPN変換開
始信号(図2の制御回路における変換開始信号に相
当)、レジスタ書込信号、選択信号及び変換終了信号の
発生に関しては、変換要求信号の入力から数えて1クロ
ック余計に遅延するものの、図2に示す制御回路と同じ
である。したがって、前回の変換時の仮想アドレスと今
回の仮想アドレスとが一致するかしないかに応じて、仮
想アドレス部分のアドレス比較は行わずに物理アドレス
レジスタ17内の物理アドレスを出力するか、仮想アド
レス部分のアドレス比較を行ってその結果を出力する
か、が決定する。このアドレス変換回路の動作タイミン
グを図5のタイミングチャートに示す。The control circuit 34 generates a VPN conversion start signal (corresponding to the conversion start signal in the control circuit of FIG. 2), a register write signal, a selection signal, and a conversion end signal. It is the same as the control circuit shown in FIG. Therefore, depending on whether or not the virtual address at the time of the previous conversion matches the current virtual address, the physical address in the physical address register 17 is output without performing the address comparison of the virtual address portion, or the virtual address is output. It is determined whether to compare the addresses of the parts and output the result. The operation timing of this address conversion circuit is shown in the timing chart of FIG.
【0034】本実施形態においても、仮想アドレスにお
ける同じページの中で連続してアドレス変換を行うよう
な場合に、大幅な消費電力の削減を達成することができ
る。Also in the present embodiment, when address conversion is continuously performed in the same page of the virtual address, a significant reduction in power consumption can be achieved.
【0035】《第3の実施形態》次に、本発明の第3の
実施形態について、図7を用いて説明する。上述の各実
施形態は、TLBによって仮想アドレスから物理アドレ
スに変換する場合を示したものであったが、ここでは、
2ウェイ・セットアソシアティブ方式によるキャッシュ
メモリに本発明を適用した例を説明する。<< Third Embodiment >> Next, a third embodiment of the present invention will be described with reference to FIG. Each of the embodiments described above shows a case where a virtual address is converted into a physical address by TLB.
An example in which the present invention is applied to a cache memory using the two-way set associative method will be described.
【0036】このアドレス変換回路は、セットアソシア
ティブ方式のキャッシュ動作を実現するため、図1に示
すアドレス変換回路においてTLBを設ける代わりに、
仮想アドレスをデコードするデコーダ51と、セット#
0及びセット#1のVPN用仮想アドレスRAM52,
53と、PFN用物理アドレスRAM54と、セット#
0のVPN用仮想アドレスRAM52が出力するアドレ
スと入力した仮想アドレスとを比較しセット#0一致信
号を出力する比較器55と、セット#1のVPN用仮想
アドレスRAM53が出力するアドレスと入力した仮想
アドレスとを比較しセット#1一致信号を出力する比較
器56と、セット#0一致信号及びセット#1一致信号
によって制御されるセレクタ57とを設けた構成となっ
ている。なお、説明を分かりやすくするため、各RAM
52〜54にデータを書込むための機構やキャッシュミ
スがあったときの処理を行う機構は、図示していない。This address conversion circuit realizes a set associative cache operation, instead of providing a TLB in the address conversion circuit shown in FIG.
A decoder 51 for decoding a virtual address, and a set #
0 and set # 1 VPN virtual address RAM 52,
53, PFN physical address RAM 54, and set #
The comparator 55 compares the address output from the virtual address RAM 52 for VPN with the input virtual address and outputs a set # 0 match signal, and the virtual address input from the virtual address RAM 53 for set # 1 and the input virtual address. The configuration includes a comparator 56 that compares an address and outputs a set # 1 coincidence signal, and a selector 57 controlled by the set # 0 coincidence signal and the set # 1 coincidence signal. In order to make the explanation easy to understand, each RAM
A mechanism for writing data to 52 to 54 and a mechanism for performing processing when a cache miss occurs are not shown.
【0037】デコーダ51のデコード結果は、VPN用
仮想アドレスRAM52,53及びPFN用物理アドレ
スRAM54に与えられる。また、PFN用物理アドレ
スRAM54は、セット#0用の記憶領域とセット#1
用の記憶領域とに分かれており、それぞれから物理アド
レスが出力してセレクタ57に入力する。セレクタ57
は、セット#0一致信号が出力されているときにはPF
N用物理アドレスRAM54のセット#0用の記憶領域
側を選択し、セット#1一致信号が出力されているとき
にはPFN用物理アドレスRAM54のセット#1用の
記憶領域側を選択し、選択された物理アドレスを物理ア
ドレスレジスタ17及びセレクタ18に出力する。制御
回路16が出力する変換開始信号は、各VPN用仮想ア
ドレスRAM52,53及びPFN用物理アドレスRA
M54の各記憶領域に与えられている。The decoding result of the decoder 51 is given to the virtual address RAMs 52 and 53 for VPN and the physical address RAM 54 for PFN. The PFN physical address RAM 54 has a storage area for set # 0 and a storage area for set # 1.
And a physical address is output from each of them and input to the selector 57. Selector 57
Is equal to PF when the set # 0 coincidence signal is output.
The storage area for the set # 0 of the physical address RAM 54 for N is selected, and when the set # 1 coincidence signal is output, the storage area for the set # 1 of the physical address RAM 54 for PFN is selected and selected. The physical address is output to the physical address register 17 and the selector 18. The conversion start signal output from the control circuit 16 includes the virtual address RAMs 52 and 53 for VPN and the physical address RA for PFN.
It is provided to each storage area of M54.
【0038】このアドレス変換回路では、上述の各実施
形態のアドレス変換回路と同様に、前回の仮想アドレス
と今回の仮想アドレスとが一致するときに各RAMへの
変換開始信号の供給が抑止される。各RAM52〜54
としてスリープモードなどの低消費電力モードを備えた
ものを使用することにより、前回の仮想アドレスと今回
の仮想アドレスとが一致するときには各RAM52〜5
4を低消費電力モードのままとすることができるので、
変換要求信号の出力のたびに各RAMを動作モードとす
る従来のアドレス変換回路に比べ、大幅な消費電力削減
を図ることができる。In this address conversion circuit, the supply of the conversion start signal to each RAM is suppressed when the previous virtual address matches the current virtual address, as in the address conversion circuits of the above-described embodiments. . Each RAM 52-54
When a virtual address corresponding to the previous virtual address coincides with the current virtual address, the RAMs 52 to 5 are used.
4 can remain in the low power consumption mode,
Compared with the conventional address conversion circuit in which each RAM is set to the operation mode each time a conversion request signal is output, it is possible to significantly reduce power consumption.
【0039】[0039]
【発明の効果】以上説明したように本発明では、連想メ
モリなどを用いて第1のアドレス(例えば仮想アドレ
ス)から第2のアドレス(例えば物理アドレス)へのア
ドレス変換を行う際に、前回の変換時の第1のアドレス
及び第2のアドレスを保持するととももに、前回と今回
とで第1のアドレスが一致しているかどうかを判別し、
一致している場合には、連想メモリなどでのアドレス比
較動作を行うことなく、保持してある前回の変換時の第
2のアドレスをそのまま出力するようにしている。その
結果、前回のアドレス変換結果を流用できるときにはア
ドレス比較動作が行われず、その分、アドレス変換回路
の消費電力を削減できる。ソフトウェアプログラムの場
合、一般に局所参照性が大きいとされているから、アド
レス変換を要求される場面のうちの大多数の場合におい
て、前回の変換時と今回とで第1のアドレスが一致して
いると考えられ、本発明によれば、アドレス変換回路の
消費電力を大幅に削減できる。さらに本発明では、前回
と今回とで第1のアドレスが同じであった場合には連想
メモリなどを経由しないため、より早く第2のアドレス
を得ることができるという効果がある。As described above, according to the present invention, when performing address conversion from a first address (for example, a virtual address) to a second address (for example, a physical address) using an associative memory or the like, While holding the first address and the second address at the time of conversion, it is determined whether the first address is the same between the previous time and the current time,
If they match, the stored second address at the previous conversion is output as it is without performing the address comparison operation in the associative memory or the like. As a result, when the previous address conversion result can be used, the address comparison operation is not performed, and the power consumption of the address conversion circuit can be reduced accordingly. In the case of a software program, the local addressability is generally considered to be large, so that in the majority of scenes requiring address translation, the first address is the same between the previous translation and the current translation. According to the present invention, it is possible to greatly reduce the power consumption of the address conversion circuit. Further, according to the present invention, if the first address is the same between the previous time and the present time, the first address is not passed through the associative memory or the like, so that the second address can be obtained more quickly.
【図1】本発明の第1の実施形態のアドレス変換回路の
構成を示すブロック図である。FIG. 1 is a block diagram illustrating a configuration of an address conversion circuit according to a first embodiment of the present invention.
【図2】図1のアドレス変換回路における制御回路の構
成を示す回路図である。FIG. 2 is a circuit diagram showing a configuration of a control circuit in the address conversion circuit of FIG.
【図3】図1のアドレス変換回路の動作を説明するタイ
ミングチャートである。FIG. 3 is a timing chart illustrating an operation of the address conversion circuit of FIG. 1;
【図4】本発明の第2の実施形態のアドレス変換回路の
構成を示すブロック図である。FIG. 4 is a block diagram illustrating a configuration of an address conversion circuit according to a second embodiment of the present invention.
【図5】図2のアドレス変換回路における制御回路の構
成を示す回路図である。FIG. 5 is a circuit diagram showing a configuration of a control circuit in the address conversion circuit of FIG. 2;
【図6】図2のアドレス変換回路の動作を説明するタイ
ミングチャートである。FIG. 6 is a timing chart illustrating the operation of the address conversion circuit of FIG. 2;
【図7】セットアソシアティブ方式のキャッシュメモリ
として構成された本発明の第3の実施形態のアドレス変
換回路の構成を示すブロック図である。FIG. 7 is a block diagram illustrating a configuration of an address conversion circuit according to a third embodiment of the present invention configured as a set associative cache memory;
【図8】従来のアドレス変換回路の構成を示すブロック
図である。FIG. 8 is a block diagram showing a configuration of a conventional address conversion circuit.
【図9】VPN用CAMの構成の一例を示す回路図であ
る。FIG. 9 is a circuit diagram showing an example of a configuration of a VPN CAM.
11,31 TLB 12 VPN用CAM 13 PFN用RAM 14 仮想アドレスレジスタ 15,55,56 比較器 16,34 制御回路 17 物理アドレスレジスタ 18,57 セレクタ 21,41 インバータ 22,23,42,43 ANDゲート 24,25,44〜47 D型フリップフロップ 26,48 ORゲート 32 PRID用CAM 33 プロセスIDレジスタ 51 デコーダ 52,53 VPN用仮想アドレスRAM 54 PFN用物理アドレスRAM 11,31 TLB 12 CAM for VPN 13 RAM for PFN 14 Virtual address register 15,55,56 Comparator 16,34 Control circuit 17 Physical address register 18,57 Selector 21,41 Inverter 22,23,42,43 AND gate 24 , 25,44-47 D-type flip-flop 26,48 OR gate 32 CAM for PRID 33 Process ID register 51 Decoder 52,53 Virtual address RAM for VPN 54 Physical address RAM for PFN
Claims (7)
するアドレス変換回路であって、 変換開始信号に応じてアドレス比較動作を行い、前記第
2のアドレスである出力情報に前記第1のアドレスを変
換するアドレス変換手段と、 前回の変換時の前記第1のアドレスを保持するアドレス
保持手段と、 現在の前記第1のアドレスと前記アドレス保持手段に保
持されている前記第1のアドレスとを比較する比較手段
と、 前記アドレス変換手段が出力する前記出力情報を書込信
号に応じて取り込み、保持する出力情報保持手段と、 前記アドレス変換手段からの現在の前記出力情報と前記
出力情報保持手段に保持されている前記出力情報のいず
れかを選択信号に応じて選択し出力する選択手段と、 変換要求があったときに前記比較手段において一致と判
別されているときには、前記変換開始信号を出力するこ
となく、前記出力情報保持手段に保持されている前記出
力情報が前記選択手段から出力するように前記選択信号
によって制御し、変換要求があったときに前記比較手段
において不一致と判別されているときには、前記変換開
始信号及び前記書込信号を出力し、前記アドレス変換手
段からの現在の前記出力情報が前記選択手段から出力す
るように前記選択信号によって制御する制御手段と、を
有するアドレス変換回路。1. An address conversion circuit for converting a first address into a second address, performing an address comparison operation in response to a conversion start signal, and adding the first address to the output information as the second address. Address translation means for translating an address; address retention means for retaining the first address at the time of previous translation; current first address; and the first address retained in the address retention means. Comparing means for comparing the output information output from the address conversion means with a write signal in accordance with a write signal, and holding the output information; and holding the current output information and the output information from the address conversion means. Selecting means for selecting and outputting any of the output information held in the means in accordance with a selection signal, and matching in the comparing means when there is a conversion request When it is determined that the conversion start signal is not output, the output information held by the output information holding means is controlled by the selection signal so that the output information is output from the selection means. When the comparison means determines that there is no match, the conversion start signal and the write signal are output, and the selection is made so that the current output information from the address conversion means is output from the selection means. Control means for controlling with a signal.
アティブ型のキャッシュメモリである請求項1に記載の
アドレス変換回路。2. The address conversion circuit according to claim 1, wherein said address conversion means is a set associative cache memory.
するアドレス変換回路であって、 連想メモリを有して変換開始信号に応じてアドレス比較
動作を行い、前記第1のアドレスを前記第2のアドレス
に変換するアドレス変換手段と、 前回の変換時の前記第1のアドレスを保持する第1のア
ドレス保持手段と、 現在の前記第1のアドレスと前記アドレス保持手段に保
持されている前記第1のアドレスとを比較する比較手段
と、 前記アドレス変換手段が出力する前記第2のアドレスを
書込信号に応じて取り込み、保持する第2のアドレス保
持手段と、 前記アドレス変換手段からの現在の前記第2のアドレス
と前記第2のアドレス保持手段に保持されている前記第
2のアドレスのいずれかを選択信号に応じて選択し出力
する選択手段と、 変換要求があったときに前記比較手段において一致と判
別されているときには、前記変換開始信号を出力するこ
となく、前記第2のアドレス保持手段に保持されている
前記第2のアドレスが前記選択手段から出力するように
前記選択信号によって制御し、変換要求があったときに
前記比較手段において不一致と判別されているときに
は、前記変換開始信号及び前記書込信号を出力し、前記
アドレス変換手段からの現在の前記第2のアドレスが前
記選択手段から出力するように前記選択信号によって制
御する制御手段と、を有するアドレス変換回路。3. An address conversion circuit for converting a first address to a second address, comprising an associative memory, performing an address comparison operation in response to a conversion start signal, and converting the first address to the first address. Address conversion means for converting the first address and the second address, the first address holding means for holding the first address at the time of the previous conversion, and the current first address and the address held by the address holding means. Comparing means for comparing the first address with the first address; second address holding means for receiving and holding the second address output by the address conversion means in accordance with a write signal; Selecting means for selecting and outputting any one of the second address and the second address held in the second address holding means in accordance with a selection signal; If it is determined by the comparing means that there is a match, the second address held in the second address holding means is output from the selecting means without outputting the conversion start signal. The output of the address is controlled by the selection signal, and when it is determined by the comparing means that there is no match when there is a conversion request, the conversion start signal and the write signal are output. And control means for controlling the second address according to the selection signal so as to output the second address from the selection means.
る一致信号を反転するインバータと、変換要求信号と前
記インバータの出力の論理積を求めてこれを前記変換開
始信号として出力する第1のアンドゲートと、前記変換
要求信号と前記一致信号の出力の論理積を求める第2の
アンドゲートと、所定のクロック信号に基づいて前記変
換開始信号をラッチし前記レジスタ書込信号として出力
する第1のD型フリップフロップと、前記クロック信号
に基づいて前記第2のアンドゲートの出力をラッチし前
記選択信号として出力する第2のD型フリップフロップ
と、を備える請求項3に記載のアドレス変換回路。4. The first control means for calculating an AND of a conversion request signal and an output of the inverter, wherein the control means obtains a logical product of a conversion request signal and the output of the inverter, and outputs the result as the conversion start signal. An AND gate, a second AND gate for obtaining the logical product of the conversion request signal and the output of the coincidence signal, and a first AND gate for latching the conversion start signal based on a predetermined clock signal and outputting the conversion start signal as the register write signal 4. The address conversion circuit according to claim 3, further comprising: a D-type flip-flop that latches an output of the second AND gate based on the clock signal and outputs the selected signal as the selection signal. .
ドレスをタグとして複数のエントリを有する前記連想メ
モリと、前記各エントリごとに対応する第2のアドレス
を保持するランダムアクセスメモリとからなり、前記連
想メモリにおける前記アドレス比較動作において一致し
たエントリに対応する前記第2のアドレスが前記アドレ
ス変換手段から出力される、請求項3または4に記載の
アドレス変換回路。5. The address conversion means comprises: the associative memory having a plurality of entries using the first address as a tag; and a random access memory holding a second address corresponding to each of the entries. 5. The address conversion circuit according to claim 3, wherein the second address corresponding to an entry that matches in the address comparison operation in the associative memory is output from the address conversion unit. 6.
グにして前記第1のアドレスを第2のアドレスに変換す
るアドレス変換回路であって、 前記第1のアドレスについて第1の変換開始信号に応じ
てアドレス比較動作を行う第1の連想メモリと、前記プ
ロセス番号について第2の変換開始信号に応じてアドレ
ス比較動作を行う第2の連想メモリとを有し、前記第1
のアドレス及び前記プロセス番号とをタグにして前記第
1のアドレスを前記第2のアドレスに変換するアドレス
変換手段と、 前回の変換時の前記第1のアドレスを保持する第1のア
ドレス保持手段と、現在の前記第1のアドレスと前記ア
ドレス保持手段に保持されている前記第1のアドレスと
を比較する比較手段と、 前記アドレス変換手段が出力する前記第2のアドレスを
書込信号に応じて取り込み、保持する第2のアドレス保
持手段と、 前記アドレス変換手段からの現在の前記第2のアドレス
と前記第2のアドレス保持手段に保持されている前記第
2のアドレスのいずれかを選択信号に応じて選択し出力
する選択手段と、 変換要求があったときに前記比較手段において一致と判
別されているときには、前記第1の変換開始信号を出力
することなく、前記第2のアドレス保持手段に保持され
ている前記第2のアドレスが前記選択手段から出力する
ように前記選択信号によって制御し、変換要求があった
ときに前記比較手段において不一致と判別されていると
きには、前記第1の変換開始信号及び前記書込信号を出
力し、前記アドレス変換手段からの現在の前記第2のア
ドレスが前記選択手段から出力するように前記選択信号
によって制御する制御手段と、を有するアドレス変換回
路。6. An address conversion circuit for converting the first address into a second address using a first address and a process number as tags, wherein the first address is converted to a first conversion start signal. A first associative memory that performs an address comparison operation in response to the process number, and a second associative memory that performs an address comparison operation in accordance with a second conversion start signal for the process number.
Address conversion means for converting the first address to the second address by using the address and the process number as tags, and first address holding means for holding the first address at the time of the previous conversion. Comparing means for comparing the current first address with the first address held in the address holding means; and changing the second address output by the address conversion means in response to a write signal. A second address holding unit that captures and holds, and any one of the current second address from the address conversion unit and the second address held by the second address holding unit is used as a selection signal. Selecting means for selecting and outputting the first conversion start signal in response to a request for conversion when the comparison means determines that they match. The selection signal is controlled by the selection signal so that the second address held in the second address holding means is output from the selection means, and when there is a conversion request, the comparison means determines that they do not match. Control is performed by outputting the first conversion start signal and the write signal, and controlling the selection signal so that the current second address from the address conversion means is output from the selection means. And an address conversion circuit.
として前記第2の連想メモリに供給されるとともに、前
記制御手段が、前記比較手段が出力する一致信号を反転
するインバータと、前記変換要求信号と前記インバータ
の出力の論理積を求める第1のアンドゲートと、前記変
換要求信号と前記一致信号の出力の論理積を求める第2
のアンドゲートと、所定のクロック信号に基づいて前記
第1のアンドゲートの出力をラッチし前記第1の変換開
始信号として出力する第1のD型フリップフロップと、
前記クロック信号に基づいて前記第2のアンドゲートの
出力をラッチし前記選択信号として出力する第2のD型
フリップフロップと、前記クロック信号に基づいて前記
第1の変換開始信号をラッチし前記レジスタ書込信号と
して出力する第3のD型フリップフロップと、前記クロ
ック信号に基づいて前記第2のD型フリップフロップの
出力をラッチし前記選択信号として出力する第4のD型
フリップフロップと、を有する請求項6に記載のアドレ
ス変換回路。7. A conversion request signal is supplied to the second associative memory as the second conversion start signal, and the control means inverts a coincidence signal output from the comparison means; A first AND gate for calculating the logical product of the request signal and the output of the inverter; and a second AND gate for calculating the logical product of the conversion request signal and the output of the coincidence signal
An AND gate, and a first D-type flip-flop that latches an output of the first AND gate based on a predetermined clock signal and outputs the latched output as the first conversion start signal,
A second D-type flip-flop for latching an output of the second AND gate based on the clock signal and outputting the output as the selection signal; and a register for latching the first conversion start signal based on the clock signal. A third D-type flip-flop that outputs as a write signal, and a fourth D-type flip-flop that latches an output of the second D-type flip-flop based on the clock signal and outputs the same as the selection signal. 7. The address conversion circuit according to claim 6, comprising:
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP9301067A JPH11134256A (en) | 1997-10-31 | 1997-10-31 | Address conversion circuit |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP9301067A JPH11134256A (en) | 1997-10-31 | 1997-10-31 | Address conversion circuit |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JPH11134256A true JPH11134256A (en) | 1999-05-21 |
Family
ID=17892477
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP9301067A Pending JPH11134256A (en) | 1997-10-31 | 1997-10-31 | Address conversion circuit |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPH11134256A (en) |
Cited By (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US6895492B2 (en) | 2002-07-05 | 2005-05-17 | Fujitsu Limited | Method of and apparatus for performing two-layer address translation |
| US7185171B2 (en) | 2002-07-25 | 2007-02-27 | Hitachi, Ltd. | Semiconductor integrated circuit |
| WO2007089927A2 (en) | 2006-02-01 | 2007-08-09 | Sun Microsystems, Inc. | Collapsible front-end translation for instruction fetch |
| JP2012119006A (en) * | 2005-03-03 | 2012-06-21 | Qualcomm Inc | Electric power saving method and device for selectively enabling comparator for a cam renaming register file based upon a known processor state |
-
1997
- 1997-10-31 JP JP9301067A patent/JPH11134256A/en active Pending
Cited By (6)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US6895492B2 (en) | 2002-07-05 | 2005-05-17 | Fujitsu Limited | Method of and apparatus for performing two-layer address translation |
| US7185171B2 (en) | 2002-07-25 | 2007-02-27 | Hitachi, Ltd. | Semiconductor integrated circuit |
| JP2012119006A (en) * | 2005-03-03 | 2012-06-21 | Qualcomm Inc | Electric power saving method and device for selectively enabling comparator for a cam renaming register file based upon a known processor state |
| WO2007089927A2 (en) | 2006-02-01 | 2007-08-09 | Sun Microsystems, Inc. | Collapsible front-end translation for instruction fetch |
| WO2007089927A3 (en) * | 2006-02-01 | 2007-09-20 | Sun Microsystems Inc | Collapsible front-end translation for instruction fetch |
| US7509472B2 (en) | 2006-02-01 | 2009-03-24 | Sun Microsystems, Inc. | Collapsible front-end translation for instruction fetch |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US5617348A (en) | Low power data translation circuit and method of operation | |
| US6327188B1 (en) | Synchronous random access memory | |
| US6678786B2 (en) | Timing execution of compare instructions in a synchronous content addressable memory | |
| EP0213395B1 (en) | Semiconductor memory with static column decode and page mode addressing capability | |
| CA2313275C (en) | Searchline control circuit and power reduction method | |
| EP0364110B1 (en) | Semiconductor memory device having a serial access memory | |
| KR100228339B1 (en) | Multi-port access memory for sharing read port and write port | |
| US6958925B1 (en) | Staggered compare architecture for content addressable memory (CAM) device | |
| JPH09128977A (en) | Static random access memory | |
| US7113415B1 (en) | Match line pre-charging in a content addressable memory having configurable rows | |
| US5982675A (en) | Cache memory and microprocessor having the same | |
| US5754463A (en) | Multi-ported content addressable memory with precharge "non match" | |
| US10373684B2 (en) | Semiconductor device | |
| JPH06349284A (en) | Content address memory system and its operating | |
| US6393514B1 (en) | Method of generating an almost full flag and a full flag in a content addressable memory | |
| US6236585B1 (en) | Dynamic, data-precharged, variable-entry-length, content addressable memory circuit architecture with multiple transistor threshold voltage extensions | |
| JPH0863975A (en) | Static RAM and processing device having the static RAM | |
| JPH11134256A (en) | Address conversion circuit | |
| US6230237B1 (en) | Content addressable memory with an internally-timed write operation | |
| US7187570B2 (en) | Content addressable memory architecture providing improved speed | |
| US6072746A (en) | Self-timed address decoder for register file and compare circuit of a multi-port CAM | |
| US6353548B2 (en) | Method and data processing system for data lookups | |
| JP5337247B2 (en) | Semiconductor memory device | |
| JP2000163318A (en) | Address translation buffer | |
| JP3923642B2 (en) | Semiconductor memory device |